Create a Wire Transfer
curl --request POST \
--url https://api.treasuryprime.com/wire \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"account_id": "acct_1234567890",
"amount": "10300.00",
"counterparty_id": "cp_0987654321"
}
'import requests
url = "https://api.treasuryprime.com/wire"
payload = {
"account_id": "acct_1234567890",
"amount": "10300.00",
"counterparty_id": "cp_0987654321"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
account_id: 'acct_1234567890',
amount: '10300.00',
counterparty_id: 'cp_0987654321'
})
};
fetch('https://api.treasuryprime.com/wire', 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.treasuryprime.com/wire",
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([
'account_id' => 'acct_1234567890',
'amount' => '10300.00',
'counterparty_id' => 'cp_0987654321'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$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.treasuryprime.com/wire"
payload := strings.NewReader("{\n \"account_id\": \"acct_1234567890\",\n \"amount\": \"10300.00\",\n \"counterparty_id\": \"cp_0987654321\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
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.treasuryprime.com/wire")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"account_id\": \"acct_1234567890\",\n \"amount\": \"10300.00\",\n \"counterparty_id\": \"cp_0987654321\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.treasuryprime.com/wire")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"account_id\": \"acct_1234567890\",\n \"amount\": \"10300.00\",\n \"counterparty_id\": \"cp_0987654321\"\n}"
response = http.request(request)
puts response.read_body{
"account_id": "acct_1234567890",
"amount": "10300.00",
"counterparty_id": "cp_0987654321",
"created_at": "2017-11-02T11:55:14Z",
"error": null,
"id": "wire_1029384756",
"imad": {
"parsed": {
"cycle_date": "20220719",
"input_sequence_number": "999999",
"input_source": "ABCDEFG"
},
"unparsed": "20220719ABCDEFG999999"
},
"instructions": null,
"intermediary": null,
"omad": {
"parsed": {
"cycle_date": "20220719",
"frb_application_id": "FT01",
"output_date": "0102",
"output_destination": "MMQFMPTQ",
"output_sequence_number": "000106",
"output_time": "1030"
},
"unparsed": "20170102MMQFMPTQ00010601021030FT01"
},
"status": "pending",
"uetr": "97ed4827-7b6f-4485-ad6c-2eb05c0e2a1c",
"updated_at": "2017-11-02T11:55:14Z",
"userdata": null
}Wire
Create a Wire Transfer
POST
/
wire
Create a Wire Transfer
curl --request POST \
--url https://api.treasuryprime.com/wire \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"account_id": "acct_1234567890",
"amount": "10300.00",
"counterparty_id": "cp_0987654321"
}
'import requests
url = "https://api.treasuryprime.com/wire"
payload = {
"account_id": "acct_1234567890",
"amount": "10300.00",
"counterparty_id": "cp_0987654321"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
account_id: 'acct_1234567890',
amount: '10300.00',
counterparty_id: 'cp_0987654321'
})
};
fetch('https://api.treasuryprime.com/wire', 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.treasuryprime.com/wire",
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([
'account_id' => 'acct_1234567890',
'amount' => '10300.00',
'counterparty_id' => 'cp_0987654321'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$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.treasuryprime.com/wire"
payload := strings.NewReader("{\n \"account_id\": \"acct_1234567890\",\n \"amount\": \"10300.00\",\n \"counterparty_id\": \"cp_0987654321\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
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.treasuryprime.com/wire")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"account_id\": \"acct_1234567890\",\n \"amount\": \"10300.00\",\n \"counterparty_id\": \"cp_0987654321\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.treasuryprime.com/wire")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"account_id\": \"acct_1234567890\",\n \"amount\": \"10300.00\",\n \"counterparty_id\": \"cp_0987654321\"\n}"
response = http.request(request)
puts response.read_body{
"account_id": "acct_1234567890",
"amount": "10300.00",
"counterparty_id": "cp_0987654321",
"created_at": "2017-11-02T11:55:14Z",
"error": null,
"id": "wire_1029384756",
"imad": {
"parsed": {
"cycle_date": "20220719",
"input_sequence_number": "999999",
"input_source": "ABCDEFG"
},
"unparsed": "20220719ABCDEFG999999"
},
"instructions": null,
"intermediary": null,
"omad": {
"parsed": {
"cycle_date": "20220719",
"frb_application_id": "FT01",
"output_date": "0102",
"output_destination": "MMQFMPTQ",
"output_sequence_number": "000106",
"output_time": "1030"
},
"unparsed": "20170102MMQFMPTQ00010601021030FT01"
},
"status": "pending",
"uetr": "97ed4827-7b6f-4485-ad6c-2eb05c0e2a1c",
"updated_at": "2017-11-02T11:55:14Z",
"userdata": null
}Authorizations
basicAuthapiKey
Body
application/json
The wire to create
Response
200 - application/json
The wire created
Was this page helpful?