3.4 Curl Examples
curl examples for interacting with the JSONAir API.
Step 1 — Get a Bearer Token
curl -s -X POST https://jsonair.example.com/api/v1/jsonair/auth/token \
-H "Content-Type: application/json" \
-d '{"token": "your-plain-text-pat"}'{
"access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"expires_in": 3600
}TOKEN=$(curl -s -X POST https://jsonair.example.com/api/v1/jsonair/auth/token \
-H "Content-Type: application/json" \
-d '{"token": "your-plain-text-pat"}' | jq -r '.access_token')Step 2 — Fetch Configuration Data
Fetch the Reload Key
Fetch the Debug Level
Handling an Expired Token
Last updated