# Create Account

Creates an `Account` object. For more information on Organizations and
Accounts, refer to our
[Synqly Overview](https://docs.synqly.com/docs/synqly-overview).
If the request carries a `token` block, a token scoped to the new `Account` is
created in the same transaction and returned in `result.token`. The token secret
is returned exactly once and cannot be retrieved again; if the response is lost,
an organization administrator must issue a replacement token with
`POST /v1/tokens`.
**Operation ID:** `accounts_create`

Endpoint: POST /v1/accounts
Security: BearerAuth

## Security:

  - `BearerAuth` (unknown)
    http bearer

## Request fields (application/json):

  - `name` (string)
    Unique short name for this Account, 2 to 128 characters from [a-zA-Z0-9_-], usable in place of the AccountId in URLs. Names are case-sensitive, so duplicate name detection and `name` filters match the exact case. Also used for default sort order. Accounts in the `test` environment must have a name starting with `~`. Defaults to AccountId if both name and fullname are not specified.

  - `fullname` (string)
    Human friendly display name for this Account, will auto-generate 'name' field (if 'name' is not specified). Defaults to the same value as the 'name' field if not specified.

  - `environment` (string)
    Enum: "test", "prod"

  - `labels` (array)
    User defined labels that apply to this account. Labels are limited to 48 characters in length, must contain at least 1 character, and must contain only letters, numbers, underscores, hyphens, colons, and periods. The label values can be used in role bindings to limit the scope of permissions.

  - `token` (object)
    Request a token for the `Account` being created. Requires the `tokens: provision`
action, granted by the `account-provisioner` permission set. The token is scoped
by the server to the new `Account`; its scope cannot be set by the caller.

  - `token.permission_set` (string, required)
    Enum: "administrator", "viewer", "member", "account-manager", "connect-ui", "token-issuer", "mcp-integrations-use-only", "mcp-management", "account-provisioner"

  - `token.token_ttl` (string)
    Token time-to-live. If not provided, defaults to 24 hours. Use the format "1h", "1m", "1s" for hours, minutes, and seconds respectively, e.g., "720h" for 30 days.

  - `token.name` (string)
    Unique short name for this token (lowercase [a-z0-9_-], can be used in URLs). Defaults to the token id. Must not collide with an existing token in the organization.

  - `token.fullname` (string)
    Human friendly display name for this token, defaults to the same value as the 'name' field if not specified.

## Response 200 fields (application/json):

  - `result` (object, required)

  - `result.account` (object, required)

  - `result.account.name` (string, required)
    Human-readable name for this resource

  - `result.account.created_at` (string, required)
    Time object was originally created

  - `result.account.updated_at` (string, required)
    Last time object was updated

  - `result.token` (object)

## Response 400 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 401 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 402 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 403 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 404 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 405 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 409 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 415 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 429 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

## Response 500 fields (application/json):

  - `message` (string, required)
    A short, display-friendly summary of the problem.

  - `detail` (string)
    A display-friendly and more detailed explanation of the problem. It may offer additional contextual detail, but may also be just a generic description of the problem.

  - `remediation` (string)
    A display-friendly explanation for how to remediate the problem. This field may be omitted in case there are multiple problems, each with its own remediation, or if no remediation is possible.

  - `context` (object)

  - `context.parameter` (object)

  - `context.parameter.id` (string, required)
    If the `location` of the parameter is `body`, this value is always a JSON Pointer, otherwise it's the name of the parameter.

  - `context.parameter.location` (string, required)
    Enum: "header", "path", "query", "body"

  - `context.parameter.value` (any)
    The given value of the parameter.

  - `context.resources` (array)

  - `context.resources.type` (string, required)
    Enum: "account", "bridge", "credential", "integration_point", "integration", "member", "operation", "organization_webhook", "role", "sub_org", "token", "transform"

  - `context.resources.id` (string, required)
    ID of the related resource.

  - `context.resources.rel` (string, required)
    Enum: "affected", "cause"

  - `context.raw_error` (string)
    If available this represents the underlying raw error, for example an error response from a Provider.

  - `context.provider_details` (object)
    If available this represents the underlying details from the provider. May include the error message, status code, and other details.

