Skip to main content

Handling Errors

Responses from the API use HTTP response codes are used to indicate general classes of success and error. Error responses contain more details about the error in the response body.

HTTP Status CodeDescription
400 - Bad RequestThe request was invalid (likely an argument-validation issue - see the response for details).
401 - UnauthorizedThe API key token is not valid.
404 - Not FoundThe target resource was not found.
429 - Rate LimitedThis request exceeds the number of requests allowed. Slow down and try again.
500 - Server ErrorAn unexpected error occurred. Please reach out to Mem support.

Request Limits#

To ensure a consistent developer experience for all API users, the Mem API is rate limited and basic size limits apply to request parameters.

Rate Limits#

Rate-limited requests will return a "Rate Limited" error code (HTTP response status 429).

The rate limit for incoming requests is 100 requests per minute.

Note that we provide some "batch" endpoints to help better support use cases which need to make many requests. Integrations should accommodate variable rate limits by handling HTTP 429 responses and backing off (or slowing down) the speed of future requests. A common way to implement this is using one or several queues for pending requests, which can be consumed by sending requests as long as Mem does not respond with an HTTP 429.

Size Limits#

Each endpoint should document its allowable parameters and limitations. Integrations should avoid sending requests beyond these limits proactively.