Code Examples
bash
curl --location 'https://api.w2globaldata.com/kyc-check' \
--header 'Content-Type: application/json' \
--header 'Authorization: basic xxx' \
--data '{
"Bundle": "KYC_SIS",
"Data": {
"Forename": "Vladimir"
,"Surname": "Putin"
},
"Options": {
"Sandbox": "false"
},
"ClientReference": "Testing"
}'
python
import requests
import json
url = "https://api.w2globaldata.com/kyc-check"
payload = json.dumps({
"Bundle": "KYC_SIS",
"Data": {
"Forename": "Vladimir",
"Surname": "Putin"
},
"Options": {
"Sandbox": "false"
},
"ClientReference": "Testing"
})
headers = {
'Content-Type': 'application/json',
'Authorization': 'basic xxx'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
javascript
var unirest = require('unirest');
var req = unirest('POST', 'https://api.w2globaldata.com/kyc-check')
.headers({
'Content-Type': 'application/json',
'Authorization': 'basic xxx'
})
.send(JSON.stringify({
"Bundle": "KYC_SIS",
"Data": {
"Forename": "Vladimir",
"Surname": "Putin"
},
"Options": {
"Sandbox": "false"
},
"ClientReference": "Testing"
}))
.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.raw_body);
});
php
<?php
$client = new Client();
$headers = [
'Content-Type' => 'application/json',
'Authorization' => 'basic xxx'
];
$body = '{
"Bundle": "KYC_SIS",
"Data": {
"Forename": "Vladimir",
"Surname": "Putin"
},
"Options": {
"Sandbox": "false"
},
"ClientReference": "Testing"
}';
$request = new Request('POST', 'https://api.w2globaldata.com/kyc-check', $headers, $body);
$res = $client->sendAsync($request)->wait();
echo $res->getBody();
Ruby
require "uri"
require "json"
require "net/http"
url = URI("https://api.w2globaldata.com/kyc-check")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = "application/json"
request["Authorization"] = "basic xxx"
request.body = JSON.dump({
"Bundle": "KYC_SIS",
"Data": {
"Forename": "Vladimir",
"Surname": "Putin"
},
"Options": {
"Sandbox": "false"
},
"ClientReference": "Testing"
})
response = https.request(request)
puts response.read_body