Screen a borrower and open an application
curl --request POST \
--url https://api.example.com/v1/applications \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"partner_account_id": "<string>"
}
'import requests
url = "https://api.example.com/v1/applications"
payload = { "partner_account_id": "<string>" }
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({partner_account_id: '<string>'})
};
fetch('https://api.example.com/v1/applications', 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.example.com/v1/applications",
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([
'partner_account_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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.example.com/v1/applications"
payload := strings.NewReader("{\n \"partner_account_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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.example.com/v1/applications")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"partner_account_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/applications")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"partner_account_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"partner_account_id": "<string>",
"step": "screening",
"status": "in_progress",
"is_first_loan": true,
"expires_at": "2023-11-07T05:31:56Z",
"offer": {
"offer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "prequalified",
"currency": "USD",
"max_amount_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"installment_count": 123,
"credit_level": 123,
"income_base_cents": 123,
"max_payment_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_cents": 123,
"interest_cents": 123
}
],
"income_verification": {
"platforms": [
"<string>"
]
}
},
"decline": {
"reasons": [
{
"code": "<string>",
"borrower_message": "<string>",
"how_to_improve": "<string>"
}
]
},
"loan": {
"loan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"currency": "USD",
"principal_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"outstanding_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_due_cents": 123,
"interest_due_cents": 123,
"amount_paid_cents": 123,
"due_date": "2023-12-25",
"provisional_due_date": "2023-12-25",
"paid_at": "2023-11-07T05:31:56Z",
"status": "<string>"
}
],
"instructions": [
{
"instruction_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "place_hold",
"amount_cents": 123,
"currency": "USD",
"issued_at": "2023-11-07T05:31:56Z"
}
],
"deduction": {
"instruction_version": 2,
"status": "active",
"installment_seq": 123,
"amount_cents": 123,
"currency": "USD",
"deposit_filter": "inbound_bank_transfer_from_outside",
"max_deposit_pct": 100
}
}
}{
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"partner_account_id": "<string>",
"step": "screening",
"status": "in_progress",
"is_first_loan": true,
"expires_at": "2023-11-07T05:31:56Z",
"offer": {
"offer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "prequalified",
"currency": "USD",
"max_amount_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"installment_count": 123,
"credit_level": 123,
"income_base_cents": 123,
"max_payment_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_cents": 123,
"interest_cents": 123
}
],
"income_verification": {
"platforms": [
"<string>"
]
}
},
"decline": {
"reasons": [
{
"code": "<string>",
"borrower_message": "<string>",
"how_to_improve": "<string>"
}
]
},
"loan": {
"loan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"currency": "USD",
"principal_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"outstanding_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_due_cents": 123,
"interest_due_cents": 123,
"amount_paid_cents": 123,
"due_date": "2023-12-25",
"provisional_due_date": "2023-12-25",
"paid_at": "2023-11-07T05:31:56Z",
"status": "<string>"
}
],
"instructions": [
{
"instruction_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "place_hold",
"amount_cents": 123,
"currency": "USD",
"issued_at": "2023-11-07T05:31:56Z"
}
],
"deduction": {
"instruction_version": 2,
"status": "active",
"installment_seq": 123,
"amount_cents": 123,
"currency": "USD",
"deposit_filter": "inbound_bank_transfer_from_outside",
"max_deposit_pct": 100
}
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}API Reference
Screen a borrower and open an application
Takes the borrower's data from the inline `data` block. `data` and `consent` are required, and a
missing one is a 400 with details [{"field": "data"}] or [{"field": "consent"}].
Runs the screening rules and stores the decision. Returns 201 with an offer, or 200 with a decline.
A body that does not parse is a 400 with a fixed message and no details.
The body is limited to 1 MiB, which is about 2,500 entries in `data.transactions` with every field filled
(more when optional fields are left out); a larger body is a 413 PAYLOAD_TOO_LARGE.
POST
/
v1
/
applications
Screen a borrower and open an application
curl --request POST \
--url https://api.example.com/v1/applications \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"partner_account_id": "<string>"
}
'import requests
url = "https://api.example.com/v1/applications"
payload = { "partner_account_id": "<string>" }
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({partner_account_id: '<string>'})
};
fetch('https://api.example.com/v1/applications', 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.example.com/v1/applications",
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([
'partner_account_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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.example.com/v1/applications"
payload := strings.NewReader("{\n \"partner_account_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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.example.com/v1/applications")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"partner_account_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/applications")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"partner_account_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"partner_account_id": "<string>",
"step": "screening",
"status": "in_progress",
"is_first_loan": true,
"expires_at": "2023-11-07T05:31:56Z",
"offer": {
"offer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "prequalified",
"currency": "USD",
"max_amount_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"installment_count": 123,
"credit_level": 123,
"income_base_cents": 123,
"max_payment_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_cents": 123,
"interest_cents": 123
}
],
"income_verification": {
"platforms": [
"<string>"
]
}
},
"decline": {
"reasons": [
{
"code": "<string>",
"borrower_message": "<string>",
"how_to_improve": "<string>"
}
]
},
"loan": {
"loan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"currency": "USD",
"principal_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"outstanding_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_due_cents": 123,
"interest_due_cents": 123,
"amount_paid_cents": 123,
"due_date": "2023-12-25",
"provisional_due_date": "2023-12-25",
"paid_at": "2023-11-07T05:31:56Z",
"status": "<string>"
}
],
"instructions": [
{
"instruction_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "place_hold",
"amount_cents": 123,
"currency": "USD",
"issued_at": "2023-11-07T05:31:56Z"
}
],
"deduction": {
"instruction_version": 2,
"status": "active",
"installment_seq": 123,
"amount_cents": 123,
"currency": "USD",
"deposit_filter": "inbound_bank_transfer_from_outside",
"max_deposit_pct": 100
}
}
}{
"application_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"partner_account_id": "<string>",
"step": "screening",
"status": "in_progress",
"is_first_loan": true,
"expires_at": "2023-11-07T05:31:56Z",
"offer": {
"offer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "prequalified",
"currency": "USD",
"max_amount_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"installment_count": 123,
"credit_level": 123,
"income_base_cents": 123,
"max_payment_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_cents": 123,
"interest_cents": 123
}
],
"income_verification": {
"platforms": [
"<string>"
]
}
},
"decline": {
"reasons": [
{
"code": "<string>",
"borrower_message": "<string>",
"how_to_improve": "<string>"
}
]
},
"loan": {
"loan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"currency": "USD",
"principal_cents": 123,
"interest_cents": 123,
"hold_cents": 123,
"outstanding_cents": 123,
"installments": [
{
"seq": 123,
"amount_due_cents": 123,
"principal_due_cents": 123,
"interest_due_cents": 123,
"amount_paid_cents": 123,
"due_date": "2023-12-25",
"provisional_due_date": "2023-12-25",
"paid_at": "2023-11-07T05:31:56Z",
"status": "<string>"
}
],
"instructions": [
{
"instruction_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "place_hold",
"amount_cents": 123,
"currency": "USD",
"issued_at": "2023-11-07T05:31:56Z"
}
],
"deduction": {
"instruction_version": 2,
"status": "active",
"installment_seq": 123,
"amount_cents": 123,
"currency": "USD",
"deposit_filter": "inbound_bank_transfer_from_outside",
"max_deposit_pct": 100
}
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
"<unknown>"
]
},
"request_id": "<string>"
}Headers
Body
application/json
Response
Screened and declined
