Create account

POST /accounts

Create a new currency account for a user

Headers

  • Workspace-ID integer Required

    The workspace ID - to identify the sub-user

application/json

Body Required

  • alias string

    Optional account alias/nickname

  • productID integer Required

    Product ID from /products endpoint

Responses

  • 200 application/json

    Account created successfully

    Hide response attributes Show response attributes object
    • alias string

      Account nickname

    • code string

      Core Banking System account code

    • createdAt string

      Creation timestamp

    • edges object
      Hide edges attributes Show edges attributes object
      • balances array[object] Required

        Account balance snapshot at a point in time

        Hide balances attributes Show balances attributes object
        • amount integer Required

          Balance amount in smallest currency unit (e.g., cents)

        • createdAt string

          Creation timestamp

        • id integer Required

          Balance ID

        • updatedAt string

          Last update timestamp

      • currency object Required

        Currency information including symbol, code, and decimal places

        Hide currency attributes Show currency attributes object
        • code string Required

          ISO currency code (e.g., USD, EUR)

        • createdAt string

          Creation timestamp

        • decimals integer

          Number of decimal places

        • id integer Required

          Currency ID

        • name string Required

          Currency full name

        • swiftMinimumWithdrawalAmount string

          Minimum SWIFT withdrawal amount

        • symbol string

          Currency symbol (e.g., $, €)

        • updatedAt string

          Last update timestamp

      • product object Required

        Banking product (currency account type) available for creation

        Hide product attributes Show product attributes object
        • createdAt string

          Creation timestamp

        • description string

          Product description

        • edges object
          Hide edges attribute Show edges attribute object
          • currency object Required

            Currency information including symbol, code, and decimal places

            Hide currency attributes Show currency attributes object
            • code string Required

              ISO currency code (e.g., USD, EUR)

            • createdAt string

              Creation timestamp

            • decimals integer

              Number of decimal places

            • id integer Required

              Currency ID

            • name string Required

              Currency full name

            • swiftMinimumWithdrawalAmount string

              Minimum SWIFT withdrawal amount

            • symbol string

              Currency symbol (e.g., $, €)

            • updatedAt string

              Last update timestamp

        • id integer Required

          Product ID

        • name string Required

          Product name

        • updatedAt string

          Last update timestamp

    • id integer Required

      Account ID

    • name string Required

      Account holder name

    • status string Required

      Account status (enabled/disabled)

    • type string Required

      Account type (e.g., CACC)

    • updatedAt string

      Last update timestamp

  • 400 application/json

    Invalid request or user not KYC completed

    Hide response attributes Show response attributes object
    • errorCode string Required

      Error code

    • message string Required

      Error message

  • 401 application/json

    Unauthorized

    Hide response attributes Show response attributes object
    • errorCode string Required

      Error code

    • message string Required

      Error message

POST /accounts
curl \
 --request POST 'https://auth.bank.place/accounts' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --header "Workspace-ID: 456" \
 --data '{"alias":"USD Account","productID":12}'
Request example
{
  "alias": "USD Account",
  "productID": 12
}
Response examples (200)
{
  "alias": "string",
  "code": "string",
  "createdAt": "string",
  "edges": {
    "balances": [
      {
        "amount": 42,
        "createdAt": "string",
        "id": 42,
        "updatedAt": "string"
      }
    ],
    "currency": {
      "code": "string",
      "createdAt": "string",
      "decimals": 42,
      "id": 42,
      "name": "string",
      "swiftMinimumWithdrawalAmount": "string",
      "symbol": "string",
      "updatedAt": "string"
    },
    "product": {
      "createdAt": "string",
      "description": "string",
      "edges": {
        "currency": {
          "code": "string",
          "createdAt": "string",
          "decimals": 42,
          "id": 42,
          "name": "string",
          "swiftMinimumWithdrawalAmount": "string",
          "symbol": "string",
          "updatedAt": "string"
        }
      },
      "id": 42,
      "name": "string",
      "updatedAt": "string"
    }
  },
  "id": 42,
  "name": "string",
  "status": "string",
  "type": "string",
  "updatedAt": "string"
}
Response examples (400)
{
  "message": "Invalid request parameters",
  "errorCode": "invalid_request"
}
Response examples (401)
{
  "message": "Invalid request parameters",
  "errorCode": "invalid_request"
}