Skip to main content
POST
Create a machine credential

Body

application/json
name
string
required

Descriptive name for this credential

Minimum string length: 1
permissions
string[] | null
required

Granular permission codes e.g. ["spaces:read", "events:write"]

expires_at
string<date-time>

Expiry timestamp; omit for no expiry

role
string

Optional pre-defined token role bundle (e.g. token:read_only). When set, permissions are derived from policy.Roles[role] and unioned with any explicit permissions in this request.

Response

Created

raw_token
string
required

One-time secret token — store it now, it will never be shown again

$schema
string<uri>
read-only

A URL to the JSON Schema for this object.

Example:

"https://api.linebundle.com/schemas/NewCredentialView.json"

Last modified on June 11, 2026