📘
TEOS User Guides
Contact CoreLedgerPrivacy Policy
TEOS API
TEOS API
  • 👋Welcome to TEOS API
  • Get started
  • TEOS API overview
    • Terms and concepts
      • Asset
      • Spark
      • Wallet
      • Supply
      • Warp
      • Invoice
      • Transaction
    • Architecture note
      • Tenant setup options
    • Authentication
    • Versioning
  • Using TEOS API
    • Postman examples
    • Rate limits
    • Dealing with blockchain transactions
      • How to get Ether for signing transactions
      • Transaction creation and submission
        • First transaction creation and submission for a new address on the private blockchain
    • Handling errors
      • 1xxxx codes
      • 2xxxx codes
      • 3xxxx codes
    • TEOS Events
    • Warp search
  • TEOS API references
    • TEOS API Swagger (OpenAPI)
  • Using additional APIs of TEOS Platform
    • User authentication flow with TEOS Authentication service and TMS
    • Device authorization flow with TxServer and TEOS Authentication service
    • Adding wallet to the TEOS Platform flow with TxServer and TEOS API
    • Using TxServer API
      • TxServer API (OpenAPI)
      • Key Pair Generation. Transaction Signing
      • Device Restoration
    • Using TEOS Authentication service
      • TEOS Authentication Service API
    • Using TMS API
      • TMS API Swagger (OpenAPI)
      • Handling errors
      • Changelog
    • Using Discovery Service
  • FAQ
  • Changelog
    • v0.9
    • Non-versioned changes
    • Previous versions (not supported)
  • Troubleshooting
Powered by GitBook
On this page

Was this helpful?

Edit on GitHub
  1. Using TEOS API

Rate limits

PreviousUsing TEOS APINextDealing with blockchain transactions

Last updated 1 year ago

Was this helpful?

A rate limit is the number of API calls a consumer can make within a given time period. If this limit is exceeded or if CPU or total time limits are exceeded, the consumer may be throttled. API requests made by a throttled consumer will fail.

All API requests are subject to rate limits. TEOS API requests are subject to .

Real-time rate limit usage statistics are described in headers that are included with most API responses once enough calls have been made to an endpoint. Once a rate limit is reached, any subsequent requests made by your app will fail and the API will return an error code until enough time has passed for the call count to drop below the limit.

Platform Rate Limits

TEOS API requests made with an or are counted against that tenant’s rate limit. A tenant’s call count is the number of calls it can make during a rolling twenty-four-hour window and is defined as follows:

Calls within twenty-four hours = 10000

To prevent the spikes in a short time, the default limit of 100 calls per minute is applied:

Calls within a minute = 100

Headers

Endpoints that receive enough requests from your app will include a X-Rate-Limit-Limit, X-Rate-Limit-Remaining and X-Rate-Limit-Reset HTTP headers in their responses. The headers will contain strings, describing current application rate limit usage.

Header Contents

Key
Value Description

X-Rate-Limit-Limit

The rate limit period (eg. 1m, 12h, 1d).

X-Rate-Limit-Remaining

Number of request remaining.

X-Rate-Limit-Reset

UTC date time (ISO 8601) when the limits resets.

A client can parse the X-Rate-Limit-Reset like this:

DateTime resetDate = DateTime.ParseExact(resetHeader, "o", 
    DateTimeFormatInfo.InvariantInfo);

Best Practices

  • When the limit has been reached, stop making API calls. Continuing to make calls will continue to increase your call count, which will increase the time before calls will be successful again.

  • Spread out queries evenly to avoid traffic spikes.

  • Use filters to limit the data response size and avoid calls that request overlapping data.

  • Check the X-Rate-Limit-Remaining HTTP header to see how close your app is to its limit and when you can resume making calls when the limit has been reached.

Platform Rate Limits
API key
user access token