Keys
Create, list and revoke API keys under /v1/account/keys.
View as MarkdownAPI keys are managed in the portal at platform.simular.ai. The endpoints below are what the portal calls. They accept a Firebase session only: an API key cannot manage keys.
Limits
Free accounts must verify a phone number first.
Create a key
POST /v1/account/keys{ "name": "ci" }name is optional, up to 100 characters.
201 Created:
{ "key": "sapi_...", "keyId": "k_8Hq", "name": "ci" }key is returned once. It is not stored in plaintext and cannot be shown again.
The phone check reads the phone claim on the sign-in token, so the number must be verified before the current sign-in. If you verified it during this session, sign out and back in, then create the key. It is the same verified number the free computer's claim checks.
List keys
GET /v1/account/keys{
"keys": [
{ "keyId": "k_8Hq", "name": "ci", "createdAt": 1790000000000, "lastUsedAt": 1790003600000 },
{ "keyId": "k_2Zp", "name": null, "createdAt": 1789000000000, "lastUsedAt": null }
]
}Newest first. Secrets are never listed.
Revoke a key
DELETE /v1/account/keys/{keyId}204 No Content. A revoked key fails with 401 on its next use.
From the CLI
The sai CLI wraps the same endpoints:
sai key generate --name ci
sai key list
sai key revoke <keyId>Note
Free-account keys and the
phone_verification_requiredanswer are available from October 1.