Variable Management
Basics
- Base URL:
https://api.ticos.cn - Read variables:
GET /variables - Update variables:
POST /variables - Auth:
Authorization: Bearer <token>
1. Read variables (GET /variables)
Response example
{ "var1": "value1", "var2": "value2"}2. Update variables (POST /variables)
- Content-Type:
application/json - Optional query parameter
priority:low/medium/high
Rules
- New keys are added
- Existing keys are updated
- Keys with
nullare removed
Request example
{ "var1": "new value", "var2": null}Curl example
curl --location 'https://api.ticos.cn/variables?priority=high' \--header 'Authorization: Bearer <API_KEY>' \--header 'Content-Type: application/json' \--data '{"var1":"new value","var2":null}'Common status codes
200 OK: success400 Bad Request: malformed request401 Unauthorized: authentication failed500 Internal Server Error: server error