Skip to main content
POST
/
organizations
/
{organizationId}
/
service-accounts
Create Service Account
curl --request POST \
  --url https://{regionAndDomain}.com/api/app/organizations/{organizationId}/service-accounts \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "username": "<string>",
  "expires": "2023-11-07T05:31:56Z",
  "projects": [
    {
      "id": 123
    }
  ]
}
'
{
  "results": {
    "token": "<string>",
    "id": 123,
    "username": "<string>",
    "last_used": "2023-11-07T05:31:56Z",
    "expires": "2023-11-07T05:31:56Z",
    "creator": 123,
    "created": "2023-11-07T05:31:56Z",
    "user": 123
  },
  "status": "ok"
}

Authorizations

Authorization
string
header
required

Service Account

Path Parameters

organizationId
integer
required

Your organization id (eg: 12345)

Body

application/json
username
string
required

A descriptive name for the service account

role
enum<string>

The service account's role

Available options:
owner,
admin,
analyst,
consumer
expires
string<date-time>

The datetime that the service account should expire

projects
object[]

A list of projects to make this serivce account a member of

Response

Service account successfully created

results
object
status
enum<string>

"ok" if the request succeeded, "error" otherwise.

Available options:
ok
Example:

"ok"