Sanctions Check API
Overview
To run a sanctions check, use the following endpoint:
Endpoint
POST {BASEURL}/client/fibonacci/sanctions
Authentication
Each request must include a Bearer token in the Authorization header. The API key will always start with sk_. Below is an example of how to format the header:
Request Examples
- cURL
- Node.js
- Python
- PHP
- Ruby
curl -X POST {BASEURL}/client/fibonacci/sanctions \
-H "Authorization: Bearer sk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXX" \
-H "Content-Type: application/json" \
-d '{
"firstName": "John",
"lastName": "Doe",
"customerId": "12345",
"dob": "1990-01-01",
"gender": "male",
"country": "USA",
"type": "sanctions"
}'
const axios = require("axios");
const data = {
firstName: "John",
lastName: "Doe",
customerId: "12345",
dob: "1990-01-01",
gender: "male",
country: "USA",
type: "sanctions",
};
axios
.post("{BASEURL}/client/fibonacci/sanctions", data, {
headers: {
Authorization: "Bearer sk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXX",
"Content-Type": "application/json",
},
})
.then((response) => {
console.log(response.data);
})
.catch((error) => {
console.error(error);
});
import requests
url = "{BASEURL}/client/fibonacci/sanctions"
headers = {
"Authorization": "Bearer sk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXX",
"Content-Type": "application/json"
}
data = {
"firstName": "John",
"lastName": "Doe",
"customerId": "12345",
"dob": "1990-01-01",
"gender": "male",
"country": "USA",
"type": "sanctions"
}
response = requests.post(url, json=data, headers=headers)
print(response.json())
<?php
$ch = curl_init();
$data = json_encode([
"firstName" => "John",
"lastName" => "Doe",
"customerId" => "12345",
"dob" => "1990-01-01",
"gender" => "male",
"country" => "USA",
"type" => "sanctions"
]);
curl_setopt($ch, CURLOPT_URL, "{BASEURL}/client/fibonacci/sanctions");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
"Authorization: Bearer sk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXX",
"Content-Type: application/json"
));
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
require 'net/http'
require 'uri'
require 'json'
uri = URI.parse("{BASEURL}/client/fibonacci/sanctions")
request = Net::HTTP::Post.new(uri)
request["Authorization"] = "Bearer sk_test_XXXXXXXXXXXXXXXXXXXXXXXXXXX"
request["Content-Type"] = "application/json"
request.body = JSON.dump({
firstName: "John",
lastName: "Doe",
customerId: "12345",
dob: "1990-01-01",
gender: "male",
country: "USA",
type: "sanctions"
})
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) do |http|
http.request(request)
end
puts response.body
Request Parameters
| Field | Type | Required | Description |
|---|---|---|---|
| firstName | String | Yes | The first name of the customer |
| lastName | String | Yes | The last name of the customer |
| customerId | String | Yes | The unique ID of the customer |
| dob | String | No | The date of birth (YYYY-MM-DD) |
| gender | String | No | The gender of the customer (male/female) |
| country | String | Yes | The country of the customer |
| type | String | Yes | sanctions or PEP |
Response
A successful request will return a response similar to:
{
"message": "added to queue"
}