There may be some cases of the schema in the API Reference being mismatched with what is returned. For example user says it returns this schema:
curl https://www.beeminder.com/api/v1/users/alice.json?auth_token=abc123
{ "username": "alice",
"timezone": "America/Los_Angeles",
"updated_at": 1343449880,
"goals": ["gmailzero", "weight"] }
curl https://www.beeminder.com/api/v1/users/alice.json?diff_since=1352561989&auth_token=abc123
{ "username": "alice",
"timezone": "America/Los_Angeles",
"updated_at": 1343449880,
"goals": [ {"slug": "weight", ...,
"datapoints": [{"timestamp": 1325523600,
"value": 70.45,
"comment": "blah blah",
"id": "4f9dd9fd86f22478d3"},
{"timestamp": 1325610000,
"value": 70.85,
"comment": "blah blah",
"id": "5f9d79fd86f33468d4"}],
"title": "Weight Loss", ...},
{ another goal }, ... ],
"deleted_goals": [{ "id": "519279fd86f33468ne"}, ... ] }
"""
username = username or self.default_user
if not username:
raise ValueError("Username must be provided either in arguments or as default.")
params = {
'redirect_to_url': redirect_to_url
}
return self._get(f"/users/{username}.json", params)
When I try it the response format is pretty different.
{
"username": "example_user",
"timezone": "America/New_York",
"goals": ["goal1", "goal2", "goal3", "goal4", "goal5"],
"created_at": 1729548032,
"updated_at": 1730048622,
"urgency_load": 24,
"deadbeat": false,
"has_authorized_fitbit": false,
"default_leadtime": 0,
"default_alertstart": 34200,
"default_deadline": 0,
"subscription": "plan_type",
"subs_downto": "plan_type",
"subs_freq": 12,
"subs_lifetime": null,
"remaining_subs_credit": 0,
"id": "dummy_id_123"
}