Create Account
POST /api/v2/directory/accounts
This endpoint is used to create a new account within the directory module. It can create 'individual' or 'entity' accounts.
Body
reference_id
string
Unique identifier for the account.
Example: 245352FA
True
account_type
string
Type of the account.
Accepted Values:
individualentity
True
account_category
string
Category of the account.
Accepted values:
customernon-customer.
Defaults to customer when not specified.
False
customer_id
string
Internal identifier of the account. Required if at least one of the following is not provided: For individual accounts:
date_of_birthandplace_of_birthor
addressor
national_id
For entity accounts:
addressor
national_id
Conditional
individual
object
The object that contains the fields specific for an individual account.
Refer to the Individual Data Type for the complete list of fields.
Required if account_type = individual
entity
object
The object that contains the fields specific for an entity account.
Refer to the Entity Data Type for the complete list of fields.
Required if account_type = entity
address
object
Object describing the address of the account.
Refer to the Address Data Type for the complete list of fields.
Required if at least one of the following are not provided:
For individual accounts:
date_of_birthandplace_of_birthor
customer_idor
national_id
For entity accounts:
customer_idor
national_id
Conditional
national_id
object
Object containing national ID details.
Refer to the National ID Data Type for the complete list of fields.
Required if at least one of the following are not provided:
For individual accounts:
date_of_birthandplace_of_birthor
addressor
customer_id
For entity accounts:
addressor
customer_id
Conditional
Sample Request
curl -X POST https://sandbox.ospree.io/api/v2/directory/accounts
-h 'Content-Type: application/json' \
-h 'Accept: application/json' \
-h 'Authorization: ••••••' \
-d '{
"reference_id": "80MBoQkMNS",
"account_type": "entity",
"account_category": "customer",
"email": "[email protected]",
"customer_id": "80MBoQkMNS",
"entity": {
"registration_country": "SG",
"entity_name": {
"name_type": "LEGL",
"name_legal": "Digital Capital",
"name_business": "Digital Capital Pte. Ltd."
},
"entity_localname": {
"name_type": "LEGL",
"name_legal": "Digital Capital",
"name_business": "Digital Capital Pte. Ltd."
}
},
"address": {
"address_type": "GEOG",
"address_line": "Apt 123",
"address_street_no": "456",
"address_street_name": "Elm Street",
"address_building_name": "Elmwood Apartments",
"address_floor": "15",
"address_room": "1503",
"address_postbox": "PO Box 789",
"address_city": "New York",
"address_region": "New York",
"address_district": "Manhattan",
"address_postcode": "10001",
"address_country_code": "US"
},
"national_id": {
"national_id_type": "RAID",
"national_id": "3523524",
"registration_authority": "RA999999"
}
}' {
"status": "success",
"data": {
"reference_id": "80MBoQkMNS",
"account_type": "entity",
"account_category": "customer",
"email": "[email protected]",
"customer_id": "80MBoQkMNS",
"entity": {
"entity_name": {
"name_type": "LEGL",
"name_legal": "Digital Capital",
"name_business": "Digital Capital Pte. Ltd."
},
"entity_localname": {
"name_type": "LEGL",
"name_legal": "Digital Capital",
"name_business": "Digital Capital Pte. Ltd."
},
"registration_country": "SG"
},
"address": {
"address_type": "GEOG",
"address_line": "Apt 123",
"address_street_no": "456",
"address_street_name": "Elm Street",
"address_building_name": "Elmwood Apartments",
"address_floor": "15",
"address_room": "1503",
"address_postbox": "PO Box 789",
"address_city": "New York",
"address_region": "New York",
"address_district": "Manhattan",
"address_postcode": "10001",
"address_country_code": "US"
},
"national_id": {
"national_id_type": "RAID",
"national_id": "3523524",
"registration_authority": "RA999999"
},
"created": "2025-04-14T23:29:38+00:00",
"last_modified": "2025-04-14T23:29:38+00:00"
}
}Sample Request
curl -X POST https://sandbox.ospree.io/api/v2/directory/accounts
-h 'Content-Type: application/json' \
-h 'Accept: application/json' \
-h 'Authorization: ••••••' \
-d '{
"reference_id": "qJu7298S4D",
"account_type": "individual",
"account_category": "non-customer",
"email": "[email protected]",
"customer_id": "qJu7298S4D",
"individual": {
"date_of_birth": "1988-06-27",
"place_of_birth": "Singapore",
"nationality_country": "SG",
"residence_country": "US",
"individual_name": {
"name_type": "LEGL",
"name_first": "John",
"name_middle": "Mark",
"name_last": "Doe"
},
"individual_localname": {
"name_type": "LEGL",
"name_first": "John",
"name_middle": "Mark",
"name_last": "Doe"
}
},
"address": {
"address_type": "GEOG",
"address_line": "Apt 123",
"address_street_no": "456",
"address_street_name": "Elm Street",
"address_building_name": "Elmwood Apartments",
"address_floor": "15",
"address_room": "1503",
"address_postbox": "PO Box 789",
"address_city": "New York",
"address_region": "New York",
"address_district": "Manhattan",
"address_postcode": "10001",
"address_country_code": "US"
}
}' {
"status": "success",
"data": {
"reference_id": "qJu7298S4D",
"account_type": "individual",
"account_category": "non-customer",
"email": "[email protected]",
"individual": {
"individual_name": {
"name_type": "LEGL",
"name_first": "John",
"name_middle": "Mark",
"name_last": "Doe"
},
"individual_localname": {
"name_type": "LEGL",
"name_first": "John",
"name_middle": "Mark",
"name_last": "Doe"
},
"date_of_birth": "1988-06-27",
"place_of_birth": "Singapore, Singapore"
},
"address": {
"address_type": "GEOG",
"address_line": "Apt 123",
"address_street_no": "456",
"address_street_name": "Elm Street",
"address_building_name": "Elmwood Apartments",
"address_floor": "15",
"address_room": "1503",
"address_postbox": "PO Box 789",
"address_city": "New York",
"address_region": "New York",
"address_district": "Manhattan",
"address_postcode": "10001",
"address_country_code": "US"
},
"created": "2025-04-14T13:18:31+00:00",
"last_modified": "2025-04-14T13:18:31+00:00"
}
}Last updated