How do pages, limits and errors work in the API?

Pages. Lists return 25 items at a time as data, newest first (folders and groups oldest first), with a next_cursor. Add ?limit= (1 to 100) for more at a time. For the next page, send ?cursor= with the next_cursor you were given; when it is null, you have them all.

Limits. Each key can make 120 requests a minute. Past that, Galley answers 429 with a Retry-After header: the seconds to wait.

Errors look like {"error": {"code": "invalid_request", "message": "…", "field": "email"}}. field is there when one part of the request is the problem, and the message is written so you can show it to a person.

CodeStatusWhat it means
unauthorized401The key is missing, wrong or revoked, or its maker is no longer an Owner.
plan_required403The company isn't on Pro.
not_found404There's no such investor, document, folder, group or address.
invalid_request400Something in the request isn't right; field says what.
conflict409It's already there, like inviting someone who already has an account.
file_too_large413The file is over 50 MB (200 MB for a video).
rate_limited429More than 120 requests in a minute.
server_error500Something went wrong on our side. Try again.

Still stuck? Write to hello@1936ai.com and a person will answer.