Skip to main content
POST
/
identity
/
accounts
Create Account
curl --request POST \
  --url https://api.paxos.com/v2/identity/accounts \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "account": {
    "identity_id": "82c338f4-3cb7-4d9b-be2a-4b077c82ee3a",
    "ref_id": "fec36070-4c23-48ac-9ee1-df338b8233fc",
    "description": "Individual account for John Doe",
    "metadata": {
      "custom_field": "custom_value"
    }
  }
}
'
import requests

url = "https://api.paxos.com/v2/identity/accounts"

payload = { "account": {
"identity_id": "82c338f4-3cb7-4d9b-be2a-4b077c82ee3a",
"ref_id": "fec36070-4c23-48ac-9ee1-df338b8233fc",
"description": "Individual account for John Doe",
"metadata": { "custom_field": "custom_value" }
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
account: {
identity_id: '82c338f4-3cb7-4d9b-be2a-4b077c82ee3a',
ref_id: 'fec36070-4c23-48ac-9ee1-df338b8233fc',
description: 'Individual account for John Doe',
metadata: {custom_field: 'custom_value'}
}
})
};

fetch('https://api.paxos.com/v2/identity/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.paxos.com/v2/identity/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'account' => [
'identity_id' => '82c338f4-3cb7-4d9b-be2a-4b077c82ee3a',
'ref_id' => 'fec36070-4c23-48ac-9ee1-df338b8233fc',
'description' => 'Individual account for John Doe',
'metadata' => [
'custom_field' => 'custom_value'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.paxos.com/v2/identity/accounts"

payload := strings.NewReader("{\n \"account\": {\n \"identity_id\": \"82c338f4-3cb7-4d9b-be2a-4b077c82ee3a\",\n \"ref_id\": \"fec36070-4c23-48ac-9ee1-df338b8233fc\",\n \"description\": \"Individual account for John Doe\",\n \"metadata\": {\n \"custom_field\": \"custom_value\"\n }\n }\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.paxos.com/v2/identity/accounts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"account\": {\n \"identity_id\": \"82c338f4-3cb7-4d9b-be2a-4b077c82ee3a\",\n \"ref_id\": \"fec36070-4c23-48ac-9ee1-df338b8233fc\",\n \"description\": \"Individual account for John Doe\",\n \"metadata\": {\n \"custom_field\": \"custom_value\"\n }\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.paxos.com/v2/identity/accounts")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"account\": {\n \"identity_id\": \"82c338f4-3cb7-4d9b-be2a-4b077c82ee3a\",\n \"ref_id\": \"fec36070-4c23-48ac-9ee1-df338b8233fc\",\n \"description\": \"Individual account for John Doe\",\n \"metadata\": {\n \"custom_field\": \"custom_value\"\n }\n }\n}"

response = http.request(request)
puts response.read_body
{
  "id": "e69e4e31-6dca-4a46-bb85-af40b5fe2d59",
  "identity_id": "82c338f4-3cb7-4d9b-be2a-4b077c82ee3a",
  "ref_id": "fec36070-4c23-48ac-9ee1-df338b8233fc",
  "description": "Individual account for John Doe",
  "metadata": {
    "custom_field": "custom_value"
  },
  "admin_disabled": false,
  "user_disabled": false
}
OAuth Scope
identity:write_account

Authorizations

Authorization
string
header
required

Paxos APIs use OAuth 2 with the client credentials grant flow.

Token URLs:

Learn more in the API credentials guide →

Body

application/json
account
object
required
create_profile
boolean

Create a new profile for this account. Set to true to track user balances at the Profile level for this account. See also Profiles.

Response

200 - application/json

A successful response.

id
string

The id used for all other interactions with this account. Required on update. Auto-generated on create; do not set.

identity_id
string

The primary identity associated with the account. Required on create. Not writable on update.

description
string

A free-text description of the account.

admin_disabled
boolean

true if the account has been disabled by a Paxos admin.

user_disabled
boolean

true if the account has been disabled by the API user.

metadata
object

API User-facing metadata.

ref_id
string

A user-facing ID to prevent duplicate account creation. Unique for all accounts created by the same API user.

members
object[]

Additional Identities with varying types of access to this account.

created_at
string<date-time>

The time this account was created.

summary_status
enum<string>
Available options:
PENDING,
ERROR,
APPROVED,
DENIED,
DISABLED
updated_at
string<date-time>

The time this account was updated.

profile_id
string

The ID of the profile created for the account when create_profile=true. The Profile type is NORMAL. The field is omitted when the account has no associated Profile.

type
enum<string>
Available options:
BROKERAGE,
TRADITIONAL_IRA,
ROTH_IRA,
SEP_IRA,
FINANCIAL_ADVISOR