Check a document
curl --request POST \
--url https://robust-parakeet-542.convex.site/v1/verify/document \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"documentKind": "proof_of_address",
"documentFrontBase64": "JVBERi0xLjcK…",
"expectedName": "Wanjiku Mwangi",
"expectedAddress": "Kilimani, Nairobi",
"maxDocumentAgeDays": 90,
"externalRef": "CUST-1001"
}
'import requests
url = "https://robust-parakeet-542.convex.site/v1/verify/document"
payload = {
"documentKind": "proof_of_address",
"documentFrontBase64": "JVBERi0xLjcK…",
"expectedName": "Wanjiku Mwangi",
"expectedAddress": "Kilimani, Nairobi",
"maxDocumentAgeDays": 90,
"externalRef": "CUST-1001"
}
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({
documentKind: 'proof_of_address',
documentFrontBase64: 'JVBERi0xLjcK…',
expectedName: 'Wanjiku Mwangi',
expectedAddress: 'Kilimani, Nairobi',
maxDocumentAgeDays: 90,
externalRef: 'CUST-1001'
})
};
fetch('https://robust-parakeet-542.convex.site/v1/verify/document', 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://robust-parakeet-542.convex.site/v1/verify/document",
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([
'documentKind' => 'proof_of_address',
'documentFrontBase64' => 'JVBERi0xLjcK…',
'expectedName' => 'Wanjiku Mwangi',
'expectedAddress' => 'Kilimani, Nairobi',
'maxDocumentAgeDays' => 90,
'externalRef' => 'CUST-1001'
]),
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://robust-parakeet-542.convex.site/v1/verify/document"
payload := strings.NewReader("{\n \"documentKind\": \"proof_of_address\",\n \"documentFrontBase64\": \"JVBERi0xLjcK…\",\n \"expectedName\": \"Wanjiku Mwangi\",\n \"expectedAddress\": \"Kilimani, Nairobi\",\n \"maxDocumentAgeDays\": 90,\n \"externalRef\": \"CUST-1001\"\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://robust-parakeet-542.convex.site/v1/verify/document")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"documentKind\": \"proof_of_address\",\n \"documentFrontBase64\": \"JVBERi0xLjcK…\",\n \"expectedName\": \"Wanjiku Mwangi\",\n \"expectedAddress\": \"Kilimani, Nairobi\",\n \"maxDocumentAgeDays\": 90,\n \"externalRef\": \"CUST-1001\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://robust-parakeet-542.convex.site/v1/verify/document")
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 \"documentKind\": \"proof_of_address\",\n \"documentFrontBase64\": \"JVBERi0xLjcK…\",\n \"expectedName\": \"Wanjiku Mwangi\",\n \"expectedAddress\": \"Kilimani, Nairobi\",\n \"maxDocumentAgeDays\": 90,\n \"externalRef\": \"CUST-1001\"\n}"
response = http.request(request)
puts response.read_body{
"id": "ver_3f9a1c0b7d2e4a51c8e0f6a29b4d7c13",
"type": "idp",
"status": "queued",
"verdict": "pass",
"sandbox": true,
"monitoringId": "<string>"
}{
"error": "Missing required fields: subjectName",
"details": {
"subjectName": "string of at most 200 characters"
}
}{
"error": "Invalid API key"
}{
"error": "Insufficient credits"
}{
"error": "This API key can't call POST /v1/verify/aml. Give it the \"verify:aml\" scope or use another key."
}{
"error": "<string>",
"details": {}
}{
"error": "Rate limit exceeded"
}Documents
Check a document
Verifies an identity document, a proof of address or a KRA PIN
certificate with vision, OCR and forensic checks, and optionally
matches it to what the customer declared. Scope verify:document.
POST
/
v1
/
verify
/
document
Check a document
curl --request POST \
--url https://robust-parakeet-542.convex.site/v1/verify/document \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"documentKind": "proof_of_address",
"documentFrontBase64": "JVBERi0xLjcK…",
"expectedName": "Wanjiku Mwangi",
"expectedAddress": "Kilimani, Nairobi",
"maxDocumentAgeDays": 90,
"externalRef": "CUST-1001"
}
'import requests
url = "https://robust-parakeet-542.convex.site/v1/verify/document"
payload = {
"documentKind": "proof_of_address",
"documentFrontBase64": "JVBERi0xLjcK…",
"expectedName": "Wanjiku Mwangi",
"expectedAddress": "Kilimani, Nairobi",
"maxDocumentAgeDays": 90,
"externalRef": "CUST-1001"
}
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({
documentKind: 'proof_of_address',
documentFrontBase64: 'JVBERi0xLjcK…',
expectedName: 'Wanjiku Mwangi',
expectedAddress: 'Kilimani, Nairobi',
maxDocumentAgeDays: 90,
externalRef: 'CUST-1001'
})
};
fetch('https://robust-parakeet-542.convex.site/v1/verify/document', 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://robust-parakeet-542.convex.site/v1/verify/document",
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([
'documentKind' => 'proof_of_address',
'documentFrontBase64' => 'JVBERi0xLjcK…',
'expectedName' => 'Wanjiku Mwangi',
'expectedAddress' => 'Kilimani, Nairobi',
'maxDocumentAgeDays' => 90,
'externalRef' => 'CUST-1001'
]),
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://robust-parakeet-542.convex.site/v1/verify/document"
payload := strings.NewReader("{\n \"documentKind\": \"proof_of_address\",\n \"documentFrontBase64\": \"JVBERi0xLjcK…\",\n \"expectedName\": \"Wanjiku Mwangi\",\n \"expectedAddress\": \"Kilimani, Nairobi\",\n \"maxDocumentAgeDays\": 90,\n \"externalRef\": \"CUST-1001\"\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://robust-parakeet-542.convex.site/v1/verify/document")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"documentKind\": \"proof_of_address\",\n \"documentFrontBase64\": \"JVBERi0xLjcK…\",\n \"expectedName\": \"Wanjiku Mwangi\",\n \"expectedAddress\": \"Kilimani, Nairobi\",\n \"maxDocumentAgeDays\": 90,\n \"externalRef\": \"CUST-1001\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://robust-parakeet-542.convex.site/v1/verify/document")
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 \"documentKind\": \"proof_of_address\",\n \"documentFrontBase64\": \"JVBERi0xLjcK…\",\n \"expectedName\": \"Wanjiku Mwangi\",\n \"expectedAddress\": \"Kilimani, Nairobi\",\n \"maxDocumentAgeDays\": 90,\n \"externalRef\": \"CUST-1001\"\n}"
response = http.request(request)
puts response.read_body{
"id": "ver_3f9a1c0b7d2e4a51c8e0f6a29b4d7c13",
"type": "idp",
"status": "queued",
"verdict": "pass",
"sandbox": true,
"monitoringId": "<string>"
}{
"error": "Missing required fields: subjectName",
"details": {
"subjectName": "string of at most 200 characters"
}
}{
"error": "Invalid API key"
}{
"error": "Insufficient credits"
}{
"error": "This API key can't call POST /v1/verify/aml. Give it the \"verify:aml\" scope or use another key."
}{
"error": "<string>",
"details": {}
}{
"error": "Rate limit exceeded"
}Authorizations
Your API key: gt_live_… or gt_test_…
Body
application/json
Available options:
identity, proof_of_address, kra_pin Base64 JPEG, PNG, WebP or PDF.
Identity documents only.
Proof of address only.
Identity documents only: YYYY-MM-DD.
KRA PIN certificates only.
Proof of address: oldest acceptable issue date, in days (default 90).
Response
The check was accepted. Live keys start queued; test keys finish at once.
Example:
"ver_3f9a1c0b7d2e4a51c8e0f6a29b4d7c13"
Available options:
idp, aml, document, kyb Available options:
queued, completed Test keys only.
Allowed value:
"pass"Test keys only.
AML only, when monitor: true was sent: the monitored subject's id (null with a test key).

