curl --request POST \
--url https://api.next.orenda.finance/v1/applications/{applicationId}/kyc \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"step-1": [
{
"key": "employmentStatus",
"data": "Employed"
},
{
"key": "employmentSector",
"data": "Accountancy firm"
}
],
"step-2": [
{
"key": "countryOfBirth",
"data": "AFG"
},
{
"key": "confirmationOfResidence",
"data": "Yes"
},
{
"key": "confirmationOfResidenceDocument",
"data": "s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf"
}
]
}
'import requests
url = "https://api.next.orenda.finance/v1/applications/{applicationId}/kyc"
payload = {
"step-1": [
{
"key": "employmentStatus",
"data": "Employed"
},
{
"key": "employmentSector",
"data": "Accountancy firm"
}
],
"step-2": [
{
"key": "countryOfBirth",
"data": "AFG"
},
{
"key": "confirmationOfResidence",
"data": "Yes"
},
{
"key": "confirmationOfResidenceDocument",
"data": "s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf"
}
]
}
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({
'step-1': [
{key: 'employmentStatus', data: 'Employed'},
{key: 'employmentSector', data: 'Accountancy firm'}
],
'step-2': [
{key: 'countryOfBirth', data: 'AFG'},
{key: 'confirmationOfResidence', data: 'Yes'},
{
key: 'confirmationOfResidenceDocument',
data: 's3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf'
}
]
})
};
fetch('https://api.next.orenda.finance/v1/applications/{applicationId}/kyc', 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.next.orenda.finance/v1/applications/{applicationId}/kyc",
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([
'step-1' => [
[
'key' => 'employmentStatus',
'data' => 'Employed'
],
[
'key' => 'employmentSector',
'data' => 'Accountancy firm'
]
],
'step-2' => [
[
'key' => 'countryOfBirth',
'data' => 'AFG'
],
[
'key' => 'confirmationOfResidence',
'data' => 'Yes'
],
[
'key' => 'confirmationOfResidenceDocument',
'data' => 's3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf'
]
]
]),
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.next.orenda.finance/v1/applications/{applicationId}/kyc"
payload := strings.NewReader("{\n \"step-1\": [\n {\n \"key\": \"employmentStatus\",\n \"data\": \"Employed\"\n },\n {\n \"key\": \"employmentSector\",\n \"data\": \"Accountancy firm\"\n }\n ],\n \"step-2\": [\n {\n \"key\": \"countryOfBirth\",\n \"data\": \"AFG\"\n },\n {\n \"key\": \"confirmationOfResidence\",\n \"data\": \"Yes\"\n },\n {\n \"key\": \"confirmationOfResidenceDocument\",\n \"data\": \"s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf\"\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.next.orenda.finance/v1/applications/{applicationId}/kyc")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"step-1\": [\n {\n \"key\": \"employmentStatus\",\n \"data\": \"Employed\"\n },\n {\n \"key\": \"employmentSector\",\n \"data\": \"Accountancy firm\"\n }\n ],\n \"step-2\": [\n {\n \"key\": \"countryOfBirth\",\n \"data\": \"AFG\"\n },\n {\n \"key\": \"confirmationOfResidence\",\n \"data\": \"Yes\"\n },\n {\n \"key\": \"confirmationOfResidenceDocument\",\n \"data\": \"s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.next.orenda.finance/v1/applications/{applicationId}/kyc")
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 \"step-1\": [\n {\n \"key\": \"employmentStatus\",\n \"data\": \"Employed\"\n },\n {\n \"key\": \"employmentSector\",\n \"data\": \"Accountancy firm\"\n }\n ],\n \"step-2\": [\n {\n \"key\": \"countryOfBirth\",\n \"data\": \"AFG\"\n },\n {\n \"key\": \"confirmationOfResidence\",\n \"data\": \"Yes\"\n },\n {\n \"key\": \"confirmationOfResidenceDocument\",\n \"data\": \"s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"isComplete": true,
"message": "KYC process completed"
}
}{
"success": false,
"code": "VALIDATION_ERROR",
"message": "isCompany is required"
}{
"message": "Unauthorized"
}{
"success": false,
"code": "RESOURCE_NOT_FOUND",
"message": "Application not found"
}{
"success": false,
"code": "VALIDATION_ERROR",
"message": "isCompany is required"
}{
"success": false,
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal Server Error"
}Submit KYC data
Send the answers for one or more steps of the KYC form.
curl --request POST \
--url https://api.next.orenda.finance/v1/applications/{applicationId}/kyc \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"step-1": [
{
"key": "employmentStatus",
"data": "Employed"
},
{
"key": "employmentSector",
"data": "Accountancy firm"
}
],
"step-2": [
{
"key": "countryOfBirth",
"data": "AFG"
},
{
"key": "confirmationOfResidence",
"data": "Yes"
},
{
"key": "confirmationOfResidenceDocument",
"data": "s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf"
}
]
}
'import requests
url = "https://api.next.orenda.finance/v1/applications/{applicationId}/kyc"
payload = {
"step-1": [
{
"key": "employmentStatus",
"data": "Employed"
},
{
"key": "employmentSector",
"data": "Accountancy firm"
}
],
"step-2": [
{
"key": "countryOfBirth",
"data": "AFG"
},
{
"key": "confirmationOfResidence",
"data": "Yes"
},
{
"key": "confirmationOfResidenceDocument",
"data": "s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf"
}
]
}
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({
'step-1': [
{key: 'employmentStatus', data: 'Employed'},
{key: 'employmentSector', data: 'Accountancy firm'}
],
'step-2': [
{key: 'countryOfBirth', data: 'AFG'},
{key: 'confirmationOfResidence', data: 'Yes'},
{
key: 'confirmationOfResidenceDocument',
data: 's3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf'
}
]
})
};
fetch('https://api.next.orenda.finance/v1/applications/{applicationId}/kyc', 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.next.orenda.finance/v1/applications/{applicationId}/kyc",
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([
'step-1' => [
[
'key' => 'employmentStatus',
'data' => 'Employed'
],
[
'key' => 'employmentSector',
'data' => 'Accountancy firm'
]
],
'step-2' => [
[
'key' => 'countryOfBirth',
'data' => 'AFG'
],
[
'key' => 'confirmationOfResidence',
'data' => 'Yes'
],
[
'key' => 'confirmationOfResidenceDocument',
'data' => 's3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf'
]
]
]),
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.next.orenda.finance/v1/applications/{applicationId}/kyc"
payload := strings.NewReader("{\n \"step-1\": [\n {\n \"key\": \"employmentStatus\",\n \"data\": \"Employed\"\n },\n {\n \"key\": \"employmentSector\",\n \"data\": \"Accountancy firm\"\n }\n ],\n \"step-2\": [\n {\n \"key\": \"countryOfBirth\",\n \"data\": \"AFG\"\n },\n {\n \"key\": \"confirmationOfResidence\",\n \"data\": \"Yes\"\n },\n {\n \"key\": \"confirmationOfResidenceDocument\",\n \"data\": \"s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf\"\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.next.orenda.finance/v1/applications/{applicationId}/kyc")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"step-1\": [\n {\n \"key\": \"employmentStatus\",\n \"data\": \"Employed\"\n },\n {\n \"key\": \"employmentSector\",\n \"data\": \"Accountancy firm\"\n }\n ],\n \"step-2\": [\n {\n \"key\": \"countryOfBirth\",\n \"data\": \"AFG\"\n },\n {\n \"key\": \"confirmationOfResidence\",\n \"data\": \"Yes\"\n },\n {\n \"key\": \"confirmationOfResidenceDocument\",\n \"data\": \"s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.next.orenda.finance/v1/applications/{applicationId}/kyc")
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 \"step-1\": [\n {\n \"key\": \"employmentStatus\",\n \"data\": \"Employed\"\n },\n {\n \"key\": \"employmentSector\",\n \"data\": \"Accountancy firm\"\n }\n ],\n \"step-2\": [\n {\n \"key\": \"countryOfBirth\",\n \"data\": \"AFG\"\n },\n {\n \"key\": \"confirmationOfResidence\",\n \"data\": \"Yes\"\n },\n {\n \"key\": \"confirmationOfResidenceDocument\",\n \"data\": \"s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"isComplete": true,
"message": "KYC process completed"
}
}{
"success": false,
"code": "VALIDATION_ERROR",
"message": "isCompany is required"
}{
"message": "Unauthorized"
}{
"success": false,
"code": "RESOURCE_NOT_FOUND",
"message": "Application not found"
}{
"success": false,
"code": "VALIDATION_ERROR",
"message": "isCompany is required"
}{
"success": false,
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal Server Error"
}{ key, data } pairs, where key is a field’s key
and data is the answer:
{
"step-1": [
{ "key": "employmentStatus", "data": "Employed" },
{ "key": "employmentSector", "data": "Accountancy firm" }
],
"step-2": [
{ "key": "confirmationOfResidence", "data": "Yes" },
{
"key": "confirmationOfResidenceDocument",
"data": "s3://orenda-kyc-documents/kyc-documents/…/document/confirmationOfResidenceDocument/1767225600000.pdf"
}
]
}
{ "employmentStatus": "Employed" } is
rejected, because every top-level key is read as a step name: 400 VALIDATION_ERROR,
Step 'employmentStatus' does not exist in schema. You don’t need to send kyc_type, label or
any other schema property, only key and data.
Answer encodings
| Field | data |
|---|---|
text, textarea, email | The string typed. |
phone | The string, in the format the field’s validation.regex asks for (often + and digits, e.g. +447700900123). |
date | YYYY-MM-DD, e.g. 1990-01-31. |
number | A number, or a numeric string. |
dropdown | The chosen option’s value (not its label). With multiple: true, an array of values. |
document with kyc_type: "documentUrls" | The storage URL of a file you’ve uploaded: s3://<bucket>/<key> from the presign response. With multiple: true, an array of them. |
document with kyc_type: "documents" | Not currently supported through the API. See the note below. |
heading | Don’t submit. |
group | See Submit KYB data. |
kyc_type: "documents" can’t currently be submitted through the API, so don’t send them. Use documentUrls fields (presign, PUT, then submit the s3:// URL) for uploads.documentUrls field, the file extension at the end of the URL must be one of the
field’s formats. A URL that isn’t s3:// is rejected with
Field '<key>' document URLs must use the s3:// scheme. Base64 file contents in a
documentUrls field are also rejected this way.
Required fields and conditions
The server checks each step you send. Inside that step:- every field with
required: true, or whoserequired_ifholds, must be present with a non-empty answer (notnull, not a blank string, not an empty array); - every
keymust exist in that step of the schema, and every entry must have adataproperty; - answers must pass the field’s
validationrules and, for dropdowns, match an optionvalue.
show_if, hide_if or required_if_not, so apply those in your
form, and leave out answers for fields the user can’t see. See
Conditions.
Saving step by step
You can send one step at a time or several at once. Each step you send replaces the answers saved for that step, so always send a step’s full set of answers, not just the changed field. Steps you don’t send are left as they were. The response tells you where the form stands:isComplete | message | Meaning |
|---|---|---|
false | KYC step saved successfully | Saved. At least one step of the schema still has no saved answers. |
true | KYC process completed | Every step of the schema now has saved answers. The form is submitted for processing. |
isComplete only reports whether every step has been saved. Required fields are checked when
each step is submitted, not again at the end.
After a complete submission, keep polling GET /v2/applications.
Right after it, currentStep is PROCESSING with no requiredActions while we process the
form. Show a loader, and don’t show the form again. Then the application moves to the next
currentStep, usually IDENTITY_VERIFICATION. (On GET /v1/applications the form step stays
for those few seconds, so keep a loader up after a successful submit until currentStep
changes.)
Errors
A failed check returns400 with code: VALIDATION_ERROR. The message starts with
Request validation failed: and lists every problem, separated by commas, for example:
{
"success": false,
"code": "VALIDATION_ERROR",
"message": "Request validation failed: Required field 'employmentStatus' is missing, Field 'nationality' must be one of the valid options"
}
Step '<step>' does not exist in schema,
Required field '<key>' is missing, Field '<key>' does not exist in schema,
Field '<key>' must be one of the valid options, and a field’s own validation.errorMessage
when its regex fails. None of the answers in a failed request are saved, and previously
saved steps are kept.
A re-submission can also be refused with 409, with the code saying why:
KYC_RESUBMISSION_IN_REVIEW while a submission is still with the verification provider —
nothing is wrong, keep polling and it clears once the result arrives;
KYC_RESUBMISSION_RATE_LIMITED when the attempt limit has been reached, with
data.retryAfter giving the time it lifts; and KYC_RESUBMISSION_NOT_ALLOWED when
verification is finished and cannot be attempted again. Show the message and don’t retry
on a loop.
documentUrls fields before submitting the step: get a
presigned URL with documentType set to the field’s key
(for example confirmationOfResidenceDocument), PUT the file, then submit
s3://<bucket>/<key> as the answer, using the bucket and key from the presign response for
that field. For companies, the main submission goes to KYB submit
instead.Authorizations
The user's access_token from authentication. The program and environment (sandbox/prod) are read from the token.
Path Parameters
The application id from create / get.
Body
Answers keyed by step id (step-1, step-2, …, as in the schema). Each step is an array of { key, data } objects: key is the schema field's key, data is the answer. Dropdowns take the option value; dates are YYYY-MM-DD; multiple fields take an array. A documentUrls field takes the s3://<bucket>/<key> URL of a file uploaded through Document presign URL (or an array of them). A documents field can't currently be submitted through the API. A top-level key that isn't a step of the schema fails with Step '<key>' does not exist in schema. This example is shortened: a real step must include every required field of that step in your program's schema.
One answer: key is a field's key and data is the answer. Send only key and data, no other schema property.
- Answer
- Group entry
Show child attributes
Show child attributes