Skip to main content
All API requests must include the following parameters in the HTTP request headers (unless otherwise specified):

Usage Notes

Authentication Modes

  • Get Token: Only requires Api-Key + Timestamp; no Access-Token needed.
  • Other interfaces: All require Api-Key + Timestamp + Access-Token.

Timestamp Validation

  • Timestamp must be a Unix millisecond timestamp (13 digits).
  • Deviation from server time must be within 60 seconds, otherwise 1005 (timestamp invalid or expired) is returned.
  • Future timestamps are not accepted; excessive deviation returns 1005.

IP Whitelist

  • The requesting IP must be in the IP whitelist associated with the Api-Key.
  • Non-whitelisted IPs return 1003 (IP address not allowed).

Timezone and List Queries

  • List interfaces with start_time / end_time should include the Timezone header (defaults to UTC+8).
  • This affects day boundary calculation; use Language: zh_CN or en_US to control the language of error messages.

curl Examples

Basic example (Get Token):
Full example (with Access-Token):

Domain Replacement

Replace https://api.example.com in the curl examples below with the actual API domain:
  • Sandbox environment: https://sandbox-openplatform.keysecure.io
  • Production environment: https://openplatform.keysecure.io (contact your account manager to obtain)

Error Codes