Token
After acquiring API Key, you can generate a Token Fields according to the rules, and call the Open API interface with it.
For example: assuming the requested url is
"https://abc.api.com/todo"
, then the header is
access-key: 1d801c3346a97e25369abf5278118794
token: 378d387c2b61462cf4bc62b3949111f3
timestamp: 1471256697
Rules:
Fields | Type | Explanations | Examples |
---|---|---|---|
access-key | string | Your Access Key. You can get your access-key via “Account Management – Basic Information” | "1d801c3346a97e25369abf5278118794" |
token | string | Md5(API key.md5(timestamp)) | "378d387c2b61462cf4bc62b3949111f3" |
timestamp | int | Time stamp in seconds | 1471256697 |
PHP Example
php
<?php
$api_key = 'ce4f7c2b8edb173e2533d7a169080504';
$timestamp = time();
$token = md5($api_key.md5($timestamp));
?>