curl --request PATCH \
--url https://api.range.org/v3/risk/config \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"provider_order": [
"range"
],
"screening_provider": "range"
}
'import requests
url = "https://api.range.org/v3/risk/config"
payload = {
"provider_order": ["range"],
"screening_provider": "range"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({provider_order: ['range'], screening_provider: 'range'})
};
fetch('https://api.range.org/v3/risk/config', 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.range.org/v3/risk/config",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'provider_order' => [
'range'
],
'screening_provider' => 'range'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$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.range.org/v3/risk/config"
payload := strings.NewReader("{\n \"provider_order\": [\n \"range\"\n ],\n \"screening_provider\": \"range\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
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.patch("https://api.range.org/v3/risk/config")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"provider_order\": [\n \"range\"\n ],\n \"screening_provider\": \"range\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.range.org/v3/risk/config")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"provider_order\": [\n \"range\"\n ],\n \"screening_provider\": \"range\"\n}"
response = http.request(request)
puts response.read_body{
"provider_order": [
"range"
],
"screening_provider": "range",
"warnings": [],
"providers": [
{
"id": "range",
"name": "Range",
"connectable": true,
"maturity": "live_verified",
"key_check": null,
"credential_fields": [
{
"name": "api_key",
"label": "API key",
"secret": true,
"optional": true
}
],
"docs_url": null,
"connected": false
}
]
}{
"statusCode": 400,
"error": "Bad Request",
"message": "network is required for this address: its format does not name one chain",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"message": "network is required for this address: its format does not name one chain",
"error": "Bad Request",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"error": "Bad Request",
"message": "network is required for this address: its format does not name one chain",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"error": "Bad Request",
"message": "network is required for this address: its format does not name one chain",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"message": "network is required for this address: its format does not name one chain",
"error": "Bad Request",
"code": "network_required",
"retry_after_seconds": null
}Set Screening Routing
Set the order your workspace’s v3 address screens try providers in; every provider other than Range needs your own connection for it.
curl --request PATCH \
--url https://api.range.org/v3/risk/config \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"provider_order": [
"range"
],
"screening_provider": "range"
}
'import requests
url = "https://api.range.org/v3/risk/config"
payload = {
"provider_order": ["range"],
"screening_provider": "range"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({provider_order: ['range'], screening_provider: 'range'})
};
fetch('https://api.range.org/v3/risk/config', 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.range.org/v3/risk/config",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'provider_order' => [
'range'
],
'screening_provider' => 'range'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$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.range.org/v3/risk/config"
payload := strings.NewReader("{\n \"provider_order\": [\n \"range\"\n ],\n \"screening_provider\": \"range\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
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.patch("https://api.range.org/v3/risk/config")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"provider_order\": [\n \"range\"\n ],\n \"screening_provider\": \"range\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.range.org/v3/risk/config")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"provider_order\": [\n \"range\"\n ],\n \"screening_provider\": \"range\"\n}"
response = http.request(request)
puts response.read_body{
"provider_order": [
"range"
],
"screening_provider": "range",
"warnings": [],
"providers": [
{
"id": "range",
"name": "Range",
"connectable": true,
"maturity": "live_verified",
"key_check": null,
"credential_fields": [
{
"name": "api_key",
"label": "API key",
"secret": true,
"optional": true
}
],
"docs_url": null,
"connected": false
}
]
}{
"statusCode": 400,
"error": "Bad Request",
"message": "network is required for this address: its format does not name one chain",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"message": "network is required for this address: its format does not name one chain",
"error": "Bad Request",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"error": "Bad Request",
"message": "network is required for this address: its format does not name one chain",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"error": "Bad Request",
"message": "network is required for this address: its format does not name one chain",
"code": "network_required",
"retry_after_seconds": null
}{
"statusCode": 400,
"message": "network is required for this address: its format does not name one chain",
"error": "Bad Request",
"code": "network_required",
"retry_after_seconds": null
}provider_order: the providers to try, in order. A screen asks them one by one and stops at the first that answers. See how a screen follows the order.
curl -X PATCH https://api.range.org/v3/risk/config \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"provider_order": ["chainalysis", "range"]}'
| Rule | Error when broken |
|---|---|
range is in the order, at any position. | 400 provider_order_range_required |
| Each provider appears at most once. | 400 provider_order_duplicate |
| Every id is a provider from List Screening Providers you can screen with. | 400 invalid_request |
Every provider other than range has your workspace’s own connection. Create it with Create account connection. | 409 provider_connection_required |
Send provider_order or screening_provider, not both and not neither. | 400 provider_order_invalid |
screening_provider is deprecated but still accepted: a provider other than range means ["<provider>", "range"], and range means ["range"].
The response is the new setting, in the same shape as Get Screening Routing. The order applies to every screen your workspace makes after it, from any key.
Deleting a connection later does not change the order. Screens then skip that provider, its result reads outcome: provider-missing, and Get Screening Routing warns you.
This call is free. Screens on your own key still cost Range credits. See Credits.Authorizations
Body
Response
The order this workspace’s screens try providers in. The first provider that can answer does; the rest are not asked. range is always in the order.
A provider id, as listed by GET /v3/risk/providers. Open list: Range may add values without a new contract version. Handle a value you do not know, never reject the response.
["range"]
What callers must know for this order to work as expected: that a provider screens one network per call, so network must be passed whenever the address format does not name one chain; or that a provider in the order has no connection, so screens skip it. Empty when the order is Range alone.
[]
Was this page helpful?