Transfers
API reference
Transfer Funds is used to effect a book transfer within Cross River system.
Endpoint: /core/v1/transfers
POST
https://sandbox.crbcos.com/core/v1/transfers
Body Parameters
- debitAccountNumberstringrequiredDescription
- creditAccountNumberstringrequiredDescription
- amountstringrequiredDescription
- currencystringDescription
- clientIdentifierstringDescription
Response
- idstringDescription
- traceNumberstringDescription
- statusstringDescription
- debitobject
- transactionTypestringDescription
- accountTypestringDescription
- masterAccountNumberstringDescription
- subAccountNumberstringDescription
- partnerIdstringDescription
- activityIdstring
- resultobject
- successstring
- codestring
- messagestring
- creditobject
- transactionTypestring
- accountTypestring
- masterAccountNumberstring
- subAccountNumberstring
- partnerIdstringDescription
- productIdstring
- activityIdstring
- resultobject
- successstring
- codestring
- messagestring
- transactionCodestring
- amountstring
- currencystring
- descriptionstring
- railstringDescription
- railIdstring
- clientIdentifierstring
- flagsarray
- schedulestring
- proposedAtstring
- executedAtstring
- canceledAtstring
- effectiveAtstring
- lastModifiedAtstringDescription
curl
curl --location 'https://sandbox.crbcos.com/core/v1/transfers' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-key: d0cc197f-0a68-4d39-9a10-7d24aabb2ae5' \
--data '{
"debitAccountNumber": "2151546989",
"creditAccountNumber": "2207975570",
"amount": 2300,
"currency": "usd",
"clientIdentifier": "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5",
"flags": []
}'nodejs
var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
'method': 'POST',
'hostname': 'sandbox.crbcos.com',
'path': '/core/v1/transfers',
'headers': {
'Authorization': 'Bearer <token>',
'Content-Type': 'application/json',
'Idempotency-key': 'd0cc197f-0a68-4d39-9a10-7d24aabb2ae5'
},
'maxRedirects': 20
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"debitAccountNumber": "2151546989",
"creditAccountNumber": "2207975570",
"amount": 2300,
"currency": "usd",
"clientIdentifier": "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5",
"flags": []
});
req.write(postData);
req.end();python
import requests
import json
url = "https://sandbox.crbcos.com/core/v1/transfers"
payload = json.dumps({
"debitAccountNumber": "2151546989",
"creditAccountNumber": "2207975570",
"amount": 2300,
"currency": "usd",
"clientIdentifier": "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5",
"flags": []
})
headers = {
'Authorization': 'Bearer <token>',
'Content-Type': 'application/json',
'Idempotency-key': 'd0cc197f-0a68-4d39-9a10-7d24aabb2ae5'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
ruby
require "uri"
require "json"
require "net/http"
url = URI("https://sandbox.crbcos.com/core/v1/transfers")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = "Bearer <token>"
request["Content-Type"] = "application/json"
request["Idempotency-key"] = "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5"
request.body = JSON.dump({
"debitAccountNumber": "2151546989",
"creditAccountNumber": "2207975570",
"amount": 2300,
"currency": "usd",
"clientIdentifier": "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5",
"flags": []
})
response = https.request(request)
puts response.read_body
go
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.crbcos.com/core/v1/transfers"
method := "POST"
payload := strings.NewReader(`{
"debitAccountNumber": "2151546989",
"creditAccountNumber": "2207975570",
"amount": 2300,
"currency": "usd",
"clientIdentifier": "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5",
"flags": []
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Idempotency-key", "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := io.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}200
{
"id": "8a0e057d-b30b-4bae-9d82-b18c012905f2",
"traceNumber": "T241631401257I2I1",
"status": "Pending",
"debit": {
"transactionType": "Debit",
"accountType": "Deposit",
"masterAccountNumber": "2151546989",
"subAccountNumber": "2151546989",
"partnerId": "1e5d3f04-ae24-4af6-9e30-aecf012b99dd",
"productId": "cc62e17f-5912-483e-9e42-aed30112fbb6",
"activityId": "f428c44b-efe8-4b35-8d37-b18c012905f2"
},
"credit": {
"transactionType": "Credit",
"accountType": "Deposit",
"masterAccountNumber": "2207975570",
"subAccountNumber": "2207975570",
"partnerId": "1e5d3f04-ae24-4af6-9e30-aecf012b99dd",
"productId": "cc62e17f-5912-483e-9e42-aed30112fbb6",
"activityId": "d269b783-5e84-4b46-beba-b18c012905f2"
},
"transactionCode": "Account Transfer",
"amount": 2300,
"currency": "usd",
"description": "Internal Transfer from 2151546989 to 2207975570",
"rail": "Internal",
"railId": "0",
"clientIdentifier": "d0cc197f-0a68-4d39-9a10-7d24aabb2ae5",
"flags": [],
"schedule": [],
"proposedAt": "2024-06-11T14:01:25.70982-04:00",
"lastModifiedAt": "2024-06-11T14:01:25.70982-04:00"
}