expires_in_days is optional — omit it and the key defaults to a 90-day lifetime (API_KEY_DEFAULT_TTL_DAYS).
name is optional too — a label to help you recognise the key in the list.
Security
HTTPBearer
- Mock serverhttps://docs.vanda-analytics.com/_mock/apis/auth/vanda-msvc-auth/auth/api-keys
- Production serverhttps://api.vanda-analytics.com/auth/api-keys
curl -i -X POST \
https://docs.vanda-analytics.com/_mock/apis/auth/vanda-msvc-auth/auth/api-keys \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"expires_in_days": 90,
"name": "string"
}'Response
{ "id": 0, "api_key": "string", "name": "string", "expires_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z" }