Create a new API key with the specified roles and/or capabilities. The response includes the raw token value, which is only shown once - make sure to store it securely. At least one role or capability must be provided.
API key authentication. Pass your API key as a Bearer token in the Authorization header.
Human-readable name for the API key
1 - 255"My API Key"
List of role IDs to assign to the API key. At least one role or capability is required
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$List of granular capabilities to assign. At least one role or capability is required
ISO 8601 timestamp when the API key should expire. Omit for no expiration
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$"2025-12-31T23:59:59Z"