Skip to main content
POST
Create Virtual Key

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

workspace_id
string<uuid>
required

Workspace identifier (UUID).

project_id
string<uuid>
required

Project identifier (UUID).

Body

application/json
user_id
string<uuid>

The user to issue the key to. Provide exactly one of user_id or service_account_id.

service_account_id
string<uuid>

The service account to issue the key to. Provide exactly one of user_id or service_account_id.

name
string

Display name of the virtual key.

Response

Created

virtual_key_id
string<uuid>

Virtual key identifier.

last_four
string

The last four characters of the virtual key. Use it to identify a key. The full secret is never returned after creation.

name
string | null

Display name of the virtual key.

key_type
enum<string>

The type of identity the key is issued to.

Available options:
user,
service_account
user_id
string<uuid> | null

The user the key is issued to. null when key_type is service_account.

service_account_id
string<uuid> | null

The service account the key is issued to. null when key_type is user.

workspace_id
string<uuid>

The workspace the key belongs to.

project_id
string<uuid>

The project the key is issued for.

status
enum<string>

Current state of the key. Revoked is permanent.

Available options:
active,
disabled,
revoked
created_at
string<date-time>

ISO 8601 UTC.

created_by
string<uuid>

ID of the caller that created the key.

revoked_at
string<date-time> | null

ISO 8601 UTC. null unless the key is revoked.

revoked_by
string<uuid> | null

ID of the caller that revoked the key. null unless the key is revoked.

key
string

The full virtual key secret. Returned only in the create response and cannot be retrieved again.

Last modified on November 5, 2026