Create a service account
Creates a non-interactive member of the organization for automation, such as CI. Its identity is ORG/NAME (acme/ci). It never signs in, and it starts with no API keys and no Box grants.
namemust be unique among the organization's live service accounts; a deleted account's name can be used again. Avoid UUID-shaped names:{account}reads a UUID as an ID.roleismember(the default) oradmin, neverowner; Service accounts says what each allows. Running commands always needs a grant.
Next, create an API key for it and grant it access to the Boxes it should use. A Box it creates itself is granted to it automatically.
Only the organization's owners and admins may call this route, with a sign-in session; API keys are refused. See Run CI jobs in Boxes.
sessionAuthorizationBearer <token>A sign-in session token (jvs_…) from the Dashboard, cubicle login or the device authorization flow.
org*stringThe organization's ID or name. An organization where the caller is not an active member returns 404.
application/json- body
name*string^[a-z0-9][a-z0-9-]{0,62}$role?string"member""admin""member"The new service account.
application/json- response
A non-interactive member that one organization owns, identified as ORG/NAME. It receives Box grants like a person, holds the organization's API keys and never signs in.
id*stringThe service account's user ID: {account} in service account routes and {user} in grant and member routes.
name*stringThe service account's name, the part of identity after the slash.
identity*stringThe service account's identity, ORG/NAME, as member and grant lists show it.
role*stringThe service account's role in its organization: member or admin, never owner.
"admin""member"createdAt*stringWhen the service account was created (ISO 8601, UTC).
keys*array<>The service account's API keys that are not revoked, oldest first and without their tokens; expired keys stay listed until revoked.
curl -X POST 'https://api.cubicle.sh/v1/orgs/acme/service-accounts' \ -H 'Content-Type: application/json' \ -d '{ "name": "ci", "role": "member"}'{ "id": "8e0a2c4e-6b8d-4f1a-a3c5-9e1b3d5f7a9c", "name": "ci", "identity": "acme/ci", "role": "member", "createdAt": "2026-11-01T09:00:00.000Z", "keys": []}
