Create a KYB/KYC application
Supports both business (KYB) and individual (KYC) applications, in any corridor. Identity is verified from an uploaded government-ID document (photo_id): a business submits each director’s / applicant’s photo_id, an individual submits the applicant’s photo_id — uploaded via the /documents endpoints before /submit.
curl --request POST \
--url https://api.example.com/v2/applications \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"applicant": {
"applicantDateOfBirth": "1985-06-15",
"applicantFirstName": "<string>",
"applicantLastName": "<string>",
"applicantNationality": "<string>",
"applicantNationalId": "<string>",
"applicantPhone": "<string>"
},
"documents": [
{
"documentKey": "<string>"
}
],
"hasIndirectControl": true,
"indirectControlDetails": "<string>",
"individualActivity": {
"applicantAccountPurposes": [
"<string>"
],
"applicantEmploymentStatus": "<string>",
"applicantExpectedCounterpartyCountries": [
"<string>"
],
"applicantExpectedCryptoMonthlyVolume": "<string>",
"applicantExpectedFiatMonthlyVolume": "<string>",
"applicantSourceOfFunds": [
"<string>"
],
"applicantSourceOfWealth": [
"<string>"
]
},
"persons": [
{
"dateOfBirth": "1985-06-15",
"emailAddress": "jsmith@example.com",
"firstName": "<string>",
"lastName": "<string>",
"nationality": "<string>",
"phoneNumber": "<string>",
"residentialAddress": {
"city": "<string>",
"country": "<string>",
"postalCode": "<string>",
"state": "<string>",
"street": "<string>"
},
"title": "<string>",
"bvn": "<string>",
"middleName": "<string>",
"nationalId": "<string>",
"ownershipPercentage": 50
}
]
}
'import requests
url = "https://api.example.com/v2/applications"
payload = {
"applicant": {
"applicantDateOfBirth": "1985-06-15",
"applicantFirstName": "<string>",
"applicantLastName": "<string>",
"applicantNationality": "<string>",
"applicantNationalId": "<string>",
"applicantPhone": "<string>"
},
"documents": [{ "documentKey": "<string>" }],
"hasIndirectControl": True,
"indirectControlDetails": "<string>",
"individualActivity": {
"applicantAccountPurposes": ["<string>"],
"applicantEmploymentStatus": "<string>",
"applicantExpectedCounterpartyCountries": ["<string>"],
"applicantExpectedCryptoMonthlyVolume": "<string>",
"applicantExpectedFiatMonthlyVolume": "<string>",
"applicantSourceOfFunds": ["<string>"],
"applicantSourceOfWealth": ["<string>"]
},
"persons": [
{
"dateOfBirth": "1985-06-15",
"emailAddress": "jsmith@example.com",
"firstName": "<string>",
"lastName": "<string>",
"nationality": "<string>",
"phoneNumber": "<string>",
"residentialAddress": {
"city": "<string>",
"country": "<string>",
"postalCode": "<string>",
"state": "<string>",
"street": "<string>"
},
"title": "<string>",
"bvn": "<string>",
"middleName": "<string>",
"nationalId": "<string>",
"ownershipPercentage": 50
}
]
}
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({
applicant: {
applicantDateOfBirth: '1985-06-15',
applicantFirstName: '<string>',
applicantLastName: '<string>',
applicantNationality: '<string>',
applicantNationalId: '<string>',
applicantPhone: '<string>'
},
documents: [{documentKey: '<string>'}],
hasIndirectControl: true,
indirectControlDetails: '<string>',
individualActivity: {
applicantAccountPurposes: ['<string>'],
applicantEmploymentStatus: '<string>',
applicantExpectedCounterpartyCountries: ['<string>'],
applicantExpectedCryptoMonthlyVolume: '<string>',
applicantExpectedFiatMonthlyVolume: '<string>',
applicantSourceOfFunds: ['<string>'],
applicantSourceOfWealth: ['<string>']
},
persons: [
{
dateOfBirth: '1985-06-15',
emailAddress: 'jsmith@example.com',
firstName: '<string>',
lastName: '<string>',
nationality: '<string>',
phoneNumber: '<string>',
residentialAddress: {
city: '<string>',
country: '<string>',
postalCode: '<string>',
state: '<string>',
street: '<string>'
},
title: '<string>',
bvn: '<string>',
middleName: '<string>',
nationalId: '<string>',
ownershipPercentage: 50
}
]
})
};
fetch('https://api.example.com/v2/applications', 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.example.com/v2/applications",
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([
'applicant' => [
'applicantDateOfBirth' => '1985-06-15',
'applicantFirstName' => '<string>',
'applicantLastName' => '<string>',
'applicantNationality' => '<string>',
'applicantNationalId' => '<string>',
'applicantPhone' => '<string>'
],
'documents' => [
[
'documentKey' => '<string>'
]
],
'hasIndirectControl' => true,
'indirectControlDetails' => '<string>',
'individualActivity' => [
'applicantAccountPurposes' => [
'<string>'
],
'applicantEmploymentStatus' => '<string>',
'applicantExpectedCounterpartyCountries' => [
'<string>'
],
'applicantExpectedCryptoMonthlyVolume' => '<string>',
'applicantExpectedFiatMonthlyVolume' => '<string>',
'applicantSourceOfFunds' => [
'<string>'
],
'applicantSourceOfWealth' => [
'<string>'
]
],
'persons' => [
[
'dateOfBirth' => '1985-06-15',
'emailAddress' => 'jsmith@example.com',
'firstName' => '<string>',
'lastName' => '<string>',
'nationality' => '<string>',
'phoneNumber' => '<string>',
'residentialAddress' => [
'city' => '<string>',
'country' => '<string>',
'postalCode' => '<string>',
'state' => '<string>',
'street' => '<string>'
],
'title' => '<string>',
'bvn' => '<string>',
'middleName' => '<string>',
'nationalId' => '<string>',
'ownershipPercentage' => 50
]
]
]),
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.example.com/v2/applications"
payload := strings.NewReader("{\n \"applicant\": {\n \"applicantDateOfBirth\": \"1985-06-15\",\n \"applicantFirstName\": \"<string>\",\n \"applicantLastName\": \"<string>\",\n \"applicantNationality\": \"<string>\",\n \"applicantNationalId\": \"<string>\",\n \"applicantPhone\": \"<string>\"\n },\n \"documents\": [\n {\n \"documentKey\": \"<string>\"\n }\n ],\n \"hasIndirectControl\": true,\n \"indirectControlDetails\": \"<string>\",\n \"individualActivity\": {\n \"applicantAccountPurposes\": [\n \"<string>\"\n ],\n \"applicantEmploymentStatus\": \"<string>\",\n \"applicantExpectedCounterpartyCountries\": [\n \"<string>\"\n ],\n \"applicantExpectedCryptoMonthlyVolume\": \"<string>\",\n \"applicantExpectedFiatMonthlyVolume\": \"<string>\",\n \"applicantSourceOfFunds\": [\n \"<string>\"\n ],\n \"applicantSourceOfWealth\": [\n \"<string>\"\n ]\n },\n \"persons\": [\n {\n \"dateOfBirth\": \"1985-06-15\",\n \"emailAddress\": \"jsmith@example.com\",\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"nationality\": \"<string>\",\n \"phoneNumber\": \"<string>\",\n \"residentialAddress\": {\n \"city\": \"<string>\",\n \"country\": \"<string>\",\n \"postalCode\": \"<string>\",\n \"state\": \"<string>\",\n \"street\": \"<string>\"\n },\n \"title\": \"<string>\",\n \"bvn\": \"<string>\",\n \"middleName\": \"<string>\",\n \"nationalId\": \"<string>\",\n \"ownershipPercentage\": 50\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.example.com/v2/applications")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"applicant\": {\n \"applicantDateOfBirth\": \"1985-06-15\",\n \"applicantFirstName\": \"<string>\",\n \"applicantLastName\": \"<string>\",\n \"applicantNationality\": \"<string>\",\n \"applicantNationalId\": \"<string>\",\n \"applicantPhone\": \"<string>\"\n },\n \"documents\": [\n {\n \"documentKey\": \"<string>\"\n }\n ],\n \"hasIndirectControl\": true,\n \"indirectControlDetails\": \"<string>\",\n \"individualActivity\": {\n \"applicantAccountPurposes\": [\n \"<string>\"\n ],\n \"applicantEmploymentStatus\": \"<string>\",\n \"applicantExpectedCounterpartyCountries\": [\n \"<string>\"\n ],\n \"applicantExpectedCryptoMonthlyVolume\": \"<string>\",\n \"applicantExpectedFiatMonthlyVolume\": \"<string>\",\n \"applicantSourceOfFunds\": [\n \"<string>\"\n ],\n \"applicantSourceOfWealth\": [\n \"<string>\"\n ]\n },\n \"persons\": [\n {\n \"dateOfBirth\": \"1985-06-15\",\n \"emailAddress\": \"jsmith@example.com\",\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"nationality\": \"<string>\",\n \"phoneNumber\": \"<string>\",\n \"residentialAddress\": {\n \"city\": \"<string>\",\n \"country\": \"<string>\",\n \"postalCode\": \"<string>\",\n \"state\": \"<string>\",\n \"street\": \"<string>\"\n },\n \"title\": \"<string>\",\n \"bvn\": \"<string>\",\n \"middleName\": \"<string>\",\n \"nationalId\": \"<string>\",\n \"ownershipPercentage\": 50\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v2/applications")
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 \"applicant\": {\n \"applicantDateOfBirth\": \"1985-06-15\",\n \"applicantFirstName\": \"<string>\",\n \"applicantLastName\": \"<string>\",\n \"applicantNationality\": \"<string>\",\n \"applicantNationalId\": \"<string>\",\n \"applicantPhone\": \"<string>\"\n },\n \"documents\": [\n {\n \"documentKey\": \"<string>\"\n }\n ],\n \"hasIndirectControl\": true,\n \"indirectControlDetails\": \"<string>\",\n \"individualActivity\": {\n \"applicantAccountPurposes\": [\n \"<string>\"\n ],\n \"applicantEmploymentStatus\": \"<string>\",\n \"applicantExpectedCounterpartyCountries\": [\n \"<string>\"\n ],\n \"applicantExpectedCryptoMonthlyVolume\": \"<string>\",\n \"applicantExpectedFiatMonthlyVolume\": \"<string>\",\n \"applicantSourceOfFunds\": [\n \"<string>\"\n ],\n \"applicantSourceOfWealth\": [\n \"<string>\"\n ]\n },\n \"persons\": [\n {\n \"dateOfBirth\": \"1985-06-15\",\n \"emailAddress\": \"jsmith@example.com\",\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"nationality\": \"<string>\",\n \"phoneNumber\": \"<string>\",\n \"residentialAddress\": {\n \"city\": \"<string>\",\n \"country\": \"<string>\",\n \"postalCode\": \"<string>\",\n \"state\": \"<string>\",\n \"street\": \"<string>\"\n },\n \"title\": \"<string>\",\n \"bvn\": \"<string>\",\n \"middleName\": \"<string>\",\n \"nationalId\": \"<string>\",\n \"ownershipPercentage\": 50\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"createdAt": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"editableSections": [
"<string>"
],
"moreInfoReason": "<string>"
}{
"error": "BAD_REQUEST",
"message": "Bad Request",
"path": "/v1/beneficiaries",
"statusCode": 400,
"timestamp": "2024-01-15T10:30:00.000Z"
}{
"error": "BAD_REQUEST",
"message": "Bad Request",
"path": "/v1/beneficiaries",
"statusCode": 400,
"timestamp": "2024-01-15T10:30:00.000Z"
}{
"error": "BAD_REQUEST",
"message": "Bad Request",
"path": "/v1/beneficiaries",
"statusCode": 400,
"timestamp": "2024-01-15T10:30:00.000Z"
}Authorizations
Enter Auth0 JWT token
Headers
Optional. Names an owned sub-account (UUID) to act on. Omit to act on the account the API key resolves to (self). A non-owned id returns 403.
Body
Show child attributes
Show child attributes
business, individual Show child attributes
Show child attributes
Show child attributes
Show child attributes
Accepted but ignored on create; upload documents via the /documents endpoints after the application exists.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
sme, large_corp, licensed_fi Create-time sugar only. Decomposed to one per-person create. After creation, manage persons via the /persons sub-resource.
Show child attributes
Show child attributes
Response
The account this application belongs to (self or sub-account).
business, individual draft, under_review, approved, more_info_requested, rejected When status is more_info_requested, the sections you may edit and resubmit. applicant / businessInfo / businessActivity / individualActivity are edited via PATCH; persons via the /persons sub-resource (and covers that person’s own documents); documents is company-level documents via the /documents sub-resource. Empty otherwise.
When status is more_info_requested, the reviewer’s notes describing what needs to change. Null otherwise.
low, medium, high, prohibited pending, in_progress, clear, flagged, failed, timed_out curl --request POST \
--url https://api.example.com/v2/applications \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"applicant": {
"applicantDateOfBirth": "1985-06-15",
"applicantFirstName": "<string>",
"applicantLastName": "<string>",
"applicantNationality": "<string>",
"applicantNationalId": "<string>",
"applicantPhone": "<string>"
},
"documents": [
{
"documentKey": "<string>"
}
],
"hasIndirectControl": true,
"indirectControlDetails": "<string>",
"individualActivity": {
"applicantAccountPurposes": [
"<string>"
],
"applicantEmploymentStatus": "<string>",
"applicantExpectedCounterpartyCountries": [
"<string>"
],
"applicantExpectedCryptoMonthlyVolume": "<string>",
"applicantExpectedFiatMonthlyVolume": "<string>",
"applicantSourceOfFunds": [
"<string>"
],
"applicantSourceOfWealth": [
"<string>"
]
},
"persons": [
{
"dateOfBirth": "1985-06-15",
"emailAddress": "jsmith@example.com",
"firstName": "<string>",
"lastName": "<string>",
"nationality": "<string>",
"phoneNumber": "<string>",
"residentialAddress": {
"city": "<string>",
"country": "<string>",
"postalCode": "<string>",
"state": "<string>",
"street": "<string>"
},
"title": "<string>",
"bvn": "<string>",
"middleName": "<string>",
"nationalId": "<string>",
"ownershipPercentage": 50
}
]
}
'import requests
url = "https://api.example.com/v2/applications"
payload = {
"applicant": {
"applicantDateOfBirth": "1985-06-15",
"applicantFirstName": "<string>",
"applicantLastName": "<string>",
"applicantNationality": "<string>",
"applicantNationalId": "<string>",
"applicantPhone": "<string>"
},
"documents": [{ "documentKey": "<string>" }],
"hasIndirectControl": True,
"indirectControlDetails": "<string>",
"individualActivity": {
"applicantAccountPurposes": ["<string>"],
"applicantEmploymentStatus": "<string>",
"applicantExpectedCounterpartyCountries": ["<string>"],
"applicantExpectedCryptoMonthlyVolume": "<string>",
"applicantExpectedFiatMonthlyVolume": "<string>",
"applicantSourceOfFunds": ["<string>"],
"applicantSourceOfWealth": ["<string>"]
},
"persons": [
{
"dateOfBirth": "1985-06-15",
"emailAddress": "jsmith@example.com",
"firstName": "<string>",
"lastName": "<string>",
"nationality": "<string>",
"phoneNumber": "<string>",
"residentialAddress": {
"city": "<string>",
"country": "<string>",
"postalCode": "<string>",
"state": "<string>",
"street": "<string>"
},
"title": "<string>",
"bvn": "<string>",
"middleName": "<string>",
"nationalId": "<string>",
"ownershipPercentage": 50
}
]
}
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({
applicant: {
applicantDateOfBirth: '1985-06-15',
applicantFirstName: '<string>',
applicantLastName: '<string>',
applicantNationality: '<string>',
applicantNationalId: '<string>',
applicantPhone: '<string>'
},
documents: [{documentKey: '<string>'}],
hasIndirectControl: true,
indirectControlDetails: '<string>',
individualActivity: {
applicantAccountPurposes: ['<string>'],
applicantEmploymentStatus: '<string>',
applicantExpectedCounterpartyCountries: ['<string>'],
applicantExpectedCryptoMonthlyVolume: '<string>',
applicantExpectedFiatMonthlyVolume: '<string>',
applicantSourceOfFunds: ['<string>'],
applicantSourceOfWealth: ['<string>']
},
persons: [
{
dateOfBirth: '1985-06-15',
emailAddress: 'jsmith@example.com',
firstName: '<string>',
lastName: '<string>',
nationality: '<string>',
phoneNumber: '<string>',
residentialAddress: {
city: '<string>',
country: '<string>',
postalCode: '<string>',
state: '<string>',
street: '<string>'
},
title: '<string>',
bvn: '<string>',
middleName: '<string>',
nationalId: '<string>',
ownershipPercentage: 50
}
]
})
};
fetch('https://api.example.com/v2/applications', 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.example.com/v2/applications",
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([
'applicant' => [
'applicantDateOfBirth' => '1985-06-15',
'applicantFirstName' => '<string>',
'applicantLastName' => '<string>',
'applicantNationality' => '<string>',
'applicantNationalId' => '<string>',
'applicantPhone' => '<string>'
],
'documents' => [
[
'documentKey' => '<string>'
]
],
'hasIndirectControl' => true,
'indirectControlDetails' => '<string>',
'individualActivity' => [
'applicantAccountPurposes' => [
'<string>'
],
'applicantEmploymentStatus' => '<string>',
'applicantExpectedCounterpartyCountries' => [
'<string>'
],
'applicantExpectedCryptoMonthlyVolume' => '<string>',
'applicantExpectedFiatMonthlyVolume' => '<string>',
'applicantSourceOfFunds' => [
'<string>'
],
'applicantSourceOfWealth' => [
'<string>'
]
],
'persons' => [
[
'dateOfBirth' => '1985-06-15',
'emailAddress' => 'jsmith@example.com',
'firstName' => '<string>',
'lastName' => '<string>',
'nationality' => '<string>',
'phoneNumber' => '<string>',
'residentialAddress' => [
'city' => '<string>',
'country' => '<string>',
'postalCode' => '<string>',
'state' => '<string>',
'street' => '<string>'
],
'title' => '<string>',
'bvn' => '<string>',
'middleName' => '<string>',
'nationalId' => '<string>',
'ownershipPercentage' => 50
]
]
]),
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.example.com/v2/applications"
payload := strings.NewReader("{\n \"applicant\": {\n \"applicantDateOfBirth\": \"1985-06-15\",\n \"applicantFirstName\": \"<string>\",\n \"applicantLastName\": \"<string>\",\n \"applicantNationality\": \"<string>\",\n \"applicantNationalId\": \"<string>\",\n \"applicantPhone\": \"<string>\"\n },\n \"documents\": [\n {\n \"documentKey\": \"<string>\"\n }\n ],\n \"hasIndirectControl\": true,\n \"indirectControlDetails\": \"<string>\",\n \"individualActivity\": {\n \"applicantAccountPurposes\": [\n \"<string>\"\n ],\n \"applicantEmploymentStatus\": \"<string>\",\n \"applicantExpectedCounterpartyCountries\": [\n \"<string>\"\n ],\n \"applicantExpectedCryptoMonthlyVolume\": \"<string>\",\n \"applicantExpectedFiatMonthlyVolume\": \"<string>\",\n \"applicantSourceOfFunds\": [\n \"<string>\"\n ],\n \"applicantSourceOfWealth\": [\n \"<string>\"\n ]\n },\n \"persons\": [\n {\n \"dateOfBirth\": \"1985-06-15\",\n \"emailAddress\": \"jsmith@example.com\",\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"nationality\": \"<string>\",\n \"phoneNumber\": \"<string>\",\n \"residentialAddress\": {\n \"city\": \"<string>\",\n \"country\": \"<string>\",\n \"postalCode\": \"<string>\",\n \"state\": \"<string>\",\n \"street\": \"<string>\"\n },\n \"title\": \"<string>\",\n \"bvn\": \"<string>\",\n \"middleName\": \"<string>\",\n \"nationalId\": \"<string>\",\n \"ownershipPercentage\": 50\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.example.com/v2/applications")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"applicant\": {\n \"applicantDateOfBirth\": \"1985-06-15\",\n \"applicantFirstName\": \"<string>\",\n \"applicantLastName\": \"<string>\",\n \"applicantNationality\": \"<string>\",\n \"applicantNationalId\": \"<string>\",\n \"applicantPhone\": \"<string>\"\n },\n \"documents\": [\n {\n \"documentKey\": \"<string>\"\n }\n ],\n \"hasIndirectControl\": true,\n \"indirectControlDetails\": \"<string>\",\n \"individualActivity\": {\n \"applicantAccountPurposes\": [\n \"<string>\"\n ],\n \"applicantEmploymentStatus\": \"<string>\",\n \"applicantExpectedCounterpartyCountries\": [\n \"<string>\"\n ],\n \"applicantExpectedCryptoMonthlyVolume\": \"<string>\",\n \"applicantExpectedFiatMonthlyVolume\": \"<string>\",\n \"applicantSourceOfFunds\": [\n \"<string>\"\n ],\n \"applicantSourceOfWealth\": [\n \"<string>\"\n ]\n },\n \"persons\": [\n {\n \"dateOfBirth\": \"1985-06-15\",\n \"emailAddress\": \"jsmith@example.com\",\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"nationality\": \"<string>\",\n \"phoneNumber\": \"<string>\",\n \"residentialAddress\": {\n \"city\": \"<string>\",\n \"country\": \"<string>\",\n \"postalCode\": \"<string>\",\n \"state\": \"<string>\",\n \"street\": \"<string>\"\n },\n \"title\": \"<string>\",\n \"bvn\": \"<string>\",\n \"middleName\": \"<string>\",\n \"nationalId\": \"<string>\",\n \"ownershipPercentage\": 50\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v2/applications")
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 \"applicant\": {\n \"applicantDateOfBirth\": \"1985-06-15\",\n \"applicantFirstName\": \"<string>\",\n \"applicantLastName\": \"<string>\",\n \"applicantNationality\": \"<string>\",\n \"applicantNationalId\": \"<string>\",\n \"applicantPhone\": \"<string>\"\n },\n \"documents\": [\n {\n \"documentKey\": \"<string>\"\n }\n ],\n \"hasIndirectControl\": true,\n \"indirectControlDetails\": \"<string>\",\n \"individualActivity\": {\n \"applicantAccountPurposes\": [\n \"<string>\"\n ],\n \"applicantEmploymentStatus\": \"<string>\",\n \"applicantExpectedCounterpartyCountries\": [\n \"<string>\"\n ],\n \"applicantExpectedCryptoMonthlyVolume\": \"<string>\",\n \"applicantExpectedFiatMonthlyVolume\": \"<string>\",\n \"applicantSourceOfFunds\": [\n \"<string>\"\n ],\n \"applicantSourceOfWealth\": [\n \"<string>\"\n ]\n },\n \"persons\": [\n {\n \"dateOfBirth\": \"1985-06-15\",\n \"emailAddress\": \"jsmith@example.com\",\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"nationality\": \"<string>\",\n \"phoneNumber\": \"<string>\",\n \"residentialAddress\": {\n \"city\": \"<string>\",\n \"country\": \"<string>\",\n \"postalCode\": \"<string>\",\n \"state\": \"<string>\",\n \"street\": \"<string>\"\n },\n \"title\": \"<string>\",\n \"bvn\": \"<string>\",\n \"middleName\": \"<string>\",\n \"nationalId\": \"<string>\",\n \"ownershipPercentage\": 50\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"createdAt": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"editableSections": [
"<string>"
],
"moreInfoReason": "<string>"
}{
"error": "BAD_REQUEST",
"message": "Bad Request",
"path": "/v1/beneficiaries",
"statusCode": 400,
"timestamp": "2024-01-15T10:30:00.000Z"
}{
"error": "BAD_REQUEST",
"message": "Bad Request",
"path": "/v1/beneficiaries",
"statusCode": 400,
"timestamp": "2024-01-15T10:30:00.000Z"
}{
"error": "BAD_REQUEST",
"message": "Bad Request",
"path": "/v1/beneficiaries",
"statusCode": 400,
"timestamp": "2024-01-15T10:30:00.000Z"
}