List API keys
Excludes the secret value (only visible once, at creation). Without `organization_id`, returns the current user's personal keys. With `organization_id`, returns that clinic's keys (requires membership) — not just the ones the caller personally created.
Authorization
HTTPBearer In: header
Query Parameters
Header Parameters
Response Body
application/json
application/json
curl -X GET "https://example.com/api/v1/api-keys"null{ "detail": [ { "loc": [ "string" ], "msg": "string", "type": "string" } ]}Create an API key POST
Generates a new API key for server-to-server integrations. The raw key is returned once in this response and cannot be retrieved again — store it securely. Pass `organization_id` to create a clinic-wide key instead of a personal one — requires owner/admin role in that organization, and the key is always forced to `read_granted` scope (clinic keys are read-only by design).
Revoke an API key DELETE
Deactivates an API key immediately. Requests using it will be rejected from then on.