curl --request POST \
--url https://rest.staging.nickel.com/nickelBanking/checkDeposits \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form front='@example-file' \
--form back='@example-file' \
--form 'accountId=<string>' \
--form amountCents=155055 \
--form 'payerName=Acme Corp' \
--form 'description=<string>' \
--form 'applications=[{"paymentLinkId":"cmq7ab3cd000gsf02e5f6g7h8","amountCents":100000}]'import requests
url = "https://rest.staging.nickel.com/nickelBanking/checkDeposits"
files = {
"front": ("example-file", open("example-file", "rb")),
"back": ("example-file", open("example-file", "rb"))
}
payload = {
"accountId": "<string>",
"amountCents": "155055",
"payerName": "Acme Corp",
"description": "<string>",
"applications": "[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]"
}
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('front', '<string>');
form.append('back', '<string>');
form.append('accountId', '<string>');
form.append('amountCents', '155055');
form.append('payerName', 'Acme Corp');
form.append('description', '<string>');
form.append('applications', '[{"paymentLinkId":"cmq7ab3cd000gsf02e5f6g7h8","amountCents":100000}]');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://rest.staging.nickel.com/nickelBanking/checkDeposits', 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://rest.staging.nickel.com/nickelBanking/checkDeposits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$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://rest.staging.nickel.com/nickelBanking/checkDeposits"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://rest.staging.nickel.com/nickelBanking/checkDeposits")
.header("Authorization", "Bearer <token>")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://rest.staging.nickel.com/nickelBanking/checkDeposits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{
"checkDeposit": {
"id": "cmf2dep0001qz8x4k2v7c9d3e",
"transferId": "cmf2nbt0001qz8x4k2v7c9d3e",
"accountId": "<string>",
"amountCents": 155055,
"status": "PROCESSING",
"payerName": "Acme Corp",
"description": "Q3 retainer",
"returnReason": "<string>",
"rejectionReason": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"depositedAt": "2023-11-07T05:31:56Z",
"unappliedAmountCents": 55055,
"applications": [
{
"id": "cmr9zx1bq000gsf02h1d5w4t8",
"amountCents": 100000,
"paymentLinkId": "cmq7ab3cd000gsf02e5f6g7h8",
"voided": true,
"voidReason": "DEPOSIT_RETURNED"
}
]
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Deposit a check
Deposits a check into one of your Nickel Banking accounts from photos of its front and back, sent as multipart/form-data. The deposit starts PROCESSING; the money is yours once it is DEPOSITED.
Pass applications to apply the check to the invoices it pays in the same request. If any application is refused, nothing is deposited.
Retrying is safe. The photos identify the check: sending the same two photos again returns the deposit they already made, and nothing is sent to the bank twice. applications sent with a repeat are not written, so check the returned deposit’s applications and apply any that are missing with Apply a check deposit to a payment link.
curl --request POST \
--url https://rest.staging.nickel.com/nickelBanking/checkDeposits \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form front='@example-file' \
--form back='@example-file' \
--form 'accountId=<string>' \
--form amountCents=155055 \
--form 'payerName=Acme Corp' \
--form 'description=<string>' \
--form 'applications=[{"paymentLinkId":"cmq7ab3cd000gsf02e5f6g7h8","amountCents":100000}]'import requests
url = "https://rest.staging.nickel.com/nickelBanking/checkDeposits"
files = {
"front": ("example-file", open("example-file", "rb")),
"back": ("example-file", open("example-file", "rb"))
}
payload = {
"accountId": "<string>",
"amountCents": "155055",
"payerName": "Acme Corp",
"description": "<string>",
"applications": "[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]"
}
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('front', '<string>');
form.append('back', '<string>');
form.append('accountId', '<string>');
form.append('amountCents', '155055');
form.append('payerName', 'Acme Corp');
form.append('description', '<string>');
form.append('applications', '[{"paymentLinkId":"cmq7ab3cd000gsf02e5f6g7h8","amountCents":100000}]');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://rest.staging.nickel.com/nickelBanking/checkDeposits', 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://rest.staging.nickel.com/nickelBanking/checkDeposits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$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://rest.staging.nickel.com/nickelBanking/checkDeposits"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://rest.staging.nickel.com/nickelBanking/checkDeposits")
.header("Authorization", "Bearer <token>")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://rest.staging.nickel.com/nickelBanking/checkDeposits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"front\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"back\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"accountId\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"amountCents\"\r\n\r\n155055\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"payerName\"\r\n\r\nAcme Corp\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"description\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"applications\"\r\n\r\n[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{
"checkDeposit": {
"id": "cmf2dep0001qz8x4k2v7c9d3e",
"transferId": "cmf2nbt0001qz8x4k2v7c9d3e",
"accountId": "<string>",
"amountCents": 155055,
"status": "PROCESSING",
"payerName": "Acme Corp",
"description": "Q3 retainer",
"returnReason": "<string>",
"rejectionReason": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"depositedAt": "2023-11-07T05:31:56Z",
"unappliedAmountCents": 55055,
"applications": [
{
"id": "cmr9zx1bq000gsf02h1d5w4t8",
"amountCents": 100000,
"paymentLinkId": "cmq7ab3cd000gsf02e5f6g7h8",
"voided": true,
"voidReason": "DEPOSIT_RETURNED"
}
]
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
A photo of the front of the check, with the payer, the amount and the MICR line along the bottom. JPEG, PNG or WebP, up to 25 MB.
A photo of the back of the check. JPEG, PNG or WebP, up to 25 MB.
The Nickel Banking account to deposit into (an id from List Nickel Banking accounts).
The check's amount in cents, exactly as written on it.
x >= 1155055
Who wrote the check, as printed on it.
"Acme Corp"
A note on the deposit, for example what the check is for.
A JSON array of the payment links the check pays, applied with the deposit: [{"paymentLinkId": "...", "amountCents": 100000}]. amountCents is optional on each and defaults to the smaller of what the check has left and what the link has left to pay. Together the amounts can't exceed the check.
"[{\"paymentLinkId\":\"cmq7ab3cd000gsf02e5f6g7h8\",\"amountCents\":100000}]"
Response
The deposit, as created or as these photos already made it
Show child attributes
Show child attributes
