Skip to main content

createApiKey

Mint a new API key scoped to a role in the caller's workspace. Only workspace admins may call this; an API-key session may only mint keys for its own role, an agent key may only mint agent keys, and a key that expires may only mint keys that expire no later than it does. Gated by accord.workspace.api_key.create.

createApiKey(
input: CreateApiKeyInput!
): CreateApiKeyPayload

Arguments​

createApiKey.input ● CreateApiKeyInput! non-null input​

The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields.

Type​

CreateApiKeyPayload object​