Things to Note
1. Base URL
| Environment | Address |
|---|---|
| Development | https://openapi.test.fastmoss.com |
| Production | https://openapi.fastmoss.com |
2. Request Method
All API requests use the POST method.
3. Common Parameters
Except for the APIs to obtain or refresh access_token, all other APIs require the following parameters to be passed via the URL:
| Parameter Name | Type | Description |
|---|---|---|
client_id | string | Client ID |
access_token | string | Access Token |
timestamp | timestamp[integer] | Timestamp |
sign | string | Signature |
Example
bash
curl 'https://openapi.test.fastmoss.com/test?client_id=xxx&access_token=xxx×tamp=xxx&sign=xxx'4. Response Format
All API responses are returned in JSON object format. The data field contains the specific data, which is a Json object.
| Parameter Name | Type | Description |
|---|---|---|
code | integer | Status Code |
msg | string | Message |
data | object | Data |
request_id | string | request id |
timestamp | timestamp[integer] | server timestamp |
Example
json
{
"code": 0,
"msg": "success",
"data": {
"xxx": "xxx"
},
"request_id": "xxxx",
"timestamp": 1690351112
}5. Relationship Between HTTP Status Code and Code
HTTP Status CodeandCodedo not conflict.Coderepresents the specific business status code.- You should first check the
HTTP Status Code, then check theCode. - When the
HTTP Status Codeis200and theCodeis0, it indicates success.
Status Code Description
| Status Code | Type | Description |
|---|---|---|
0 | No Exception | Success |
10001 | Parameter Error | Parameter does not meet requirements |
20001 | Data Error | Resource not found |
30001 | Permission Error | No access permission |
30002 | Permission Error | Data limit exceeded |
30003 | Permission Error | Access frequency limit exceeded |
40001 | Service Error | Service exception |