Beta API. See the stability policy.
Rate limits
The API limits how fast you can send requests, and a few other things as well. If you go over a limit, you get a 429 response. This article lists the limits and says what to do when you hit one.
Every 429 has a Retry-After header. It tells you how many seconds to wait. Wait that long, then try again. The code in the error body says which limit you hit.
| Code | Which limit |
|---|---|
rate_limit_exceeded | Too many requests in a minute. |
create_rate_limited | Too many new runs started in a minute. |
too_many_streams | Too many live progress streams open at once. |
account_queue_full | Too many runs of your account are waiting or running. See Runs at the same time. |
public_runs_waiting | Your network address already has the most anonymous runs it may have waiting. Wait for one to finish or sign in. |
Requests per minute
Each API key can make 1,000 requests a minute, with a burst of up to 50 at once. Think of it as a bucket that holds 50 requests and refills steadily. Quick bursts are fine as long as the bucket doesn't run dry.
Every response to a request with a key tells you where you stand:
| Header | What it tells you |
|---|---|
X-RateLimit-Limit | Your limit per minute. |
X-RateLimit-Remaining | How many requests are left in the bucket. |
X-RateLimit-Reset | When the limit resets, as a Unix timestamp. |
Two keys on the same account get a separate bucket each.
The Python library waits and tries again for you when it gets a 429.
Starting runs
You can start a limited number of runs each minute, counted per account:
| What you start | Limit per minute |
|---|---|
A simulation (POST /v1/simulations) | 120 |
A sweep (POST /v1/sweeps) | 30 |
A flight over time (POST /v1/flights) | 30 |
A part test (POST /v1/component_analyses) | 10 |
Only the start of a run counts. A run you queue counts the same as one that starts right away.
The error body of a create_rate_limited response has retry_after_s, limit_per_minute and kind. If you have a long list of runs to start, send them at a steady pace and don't wait for the error.
If you want to try many parts, you don't need hundreds of requests. One sweep can step through a list of motors or propellers in a single request. See Run a sweep with the Python library.
Runs at the same time
Starting a run and running it are two different things. Your plan decides how many runs go at once, and how many may wait. The Pricing page lists both numbers for each plan. The limit covers the whole account, so the website and all your API keys share it.
If you start more runs than that, the extra ones wait with the status queued and start when a place frees up. You don't get an error until the number of waiting runs passes the limit of your plan; then the request fails with account_queue_full. GET /v1/users/me shows concurrency with the limit, how many runs are active and how many are queued.
Live progress streams
You can watch a run's progress live. An account can have 20 streams open at once. Open a 21st and you get too_many_streams. A stream stays open for at most 30 minutes. If the run isn't done by then, open a new stream. A stream ends by itself when the run finishes.
Without an account
Some endpoints need no key. These are the ones under /v1/public/. They count requests per IP address instead of per key.
- Reading the public parts catalog and saved runs: 60 requests a minute per IP address.
- Starting an anonymous run (
POST /v1/public/simulate): 20 a minute per IP address.
Over the limit you get rate_limit_exceeded and a Retry-After header.
For the error body format, see Errors. Compute units, which measure how much work a run uses, are a different thing from rate limits. See Compute units.