Mint an API key
Creates an API key (minted scope storage:vector_stores:{id} -
the knowledge_bases rename is deferred with the platform
allowlist). The secret is returned ONCE in this response and
never again. expires_at is required - the platform key
service rejects a key with no expiry. Requires admin+ (or owner).
Authorizations
User session JWT or instance API key (iak_*). Send as Authorization: Bearer <token>.
Path Parameters
Knowledge base id. Legacy physical prefix vs_ (the kb_ rename is deferred).
128^vs_[A-Za-z0-9-]+$Body
Response
Key created; secret present (once).
Per-knowledge-base API key metadata (no secret).
The key slug (also exposed as slug).
^kb-[A-Za-z0-9_-]+$knowledge_base.api_key ^vs_[A-Za-z0-9-]+$Currently storage:vector_stores:{knowledge_base_id} (the
storage:knowledge_bases:{id} rename is deferred with the
platform allowlist change).
256Path-safe key identifier (kb-{knowledge_base_id}-{uuid}, or
caller-supplied at mint). Equal to id.
The storage:-prefixed permission strings the key grants
(caller-provided at mint, else config.api_key_default_permissions).
Non-secret leading characters, for identification in lists.