Send a payment
curl --request POST \
--url https://api.talescria.com/v1/transfers \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"fromAccountId": "acct_01M2P8GP7RSDXN81CXRFM2HFV7",
"recipientId": "rcp_9f2c1e4a7b8d4e0f9a1b2c3d4e5f6071",
"destinationId": "dst_4a7b8d4e0f9a1b2c3d4e5f60719f2c1e",
"minorUnits": "125000",
"currency": "GBP",
"narration": "July invoice",
"idempotencyKey": "form_7c1e4a7b8d4e"
}
'import requests
url = "https://api.talescria.com/v1/transfers"
payload = {
"fromAccountId": "acct_01M2P8GP7RSDXN81CXRFM2HFV7",
"recipientId": "rcp_9f2c1e4a7b8d4e0f9a1b2c3d4e5f6071",
"destinationId": "dst_4a7b8d4e0f9a1b2c3d4e5f60719f2c1e",
"minorUnits": "125000",
"currency": "GBP",
"narration": "July invoice",
"idempotencyKey": "form_7c1e4a7b8d4e"
}
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({
fromAccountId: 'acct_01M2P8GP7RSDXN81CXRFM2HFV7',
recipientId: 'rcp_9f2c1e4a7b8d4e0f9a1b2c3d4e5f6071',
destinationId: 'dst_4a7b8d4e0f9a1b2c3d4e5f60719f2c1e',
minorUnits: '125000',
currency: 'GBP',
narration: 'July invoice',
idempotencyKey: 'form_7c1e4a7b8d4e'
})
};
fetch('https://api.talescria.com/v1/transfers', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"transfer": {
"id": "<string>",
"fromAccountId": "<string>",
"destinationId": "<string>",
"minorUnits": "<string>",
"currency": "<string>",
"status": "pending",
"createdAt": 123,
"updatedAt": 123,
"recipientId": "<string>",
"narration": "<string>",
"reason": "<string>",
"failureReason": "<string>"
}
}{
"transfer": {
"id": "<string>",
"fromAccountId": "<string>",
"destinationId": "<string>",
"minorUnits": "<string>",
"currency": "<string>",
"status": "pending",
"createdAt": 123,
"updatedAt": 123,
"recipientId": "<string>",
"narration": "<string>",
"reason": "<string>",
"failureReason": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}Payments
Send a payment
Pays a recipient from one of your accounts. The amount is reserved first; if the payment network refuses, the reservation is released and your balance is as it was.
A 201 means the payment was accepted, not that it has arrived. Read status:
status | Meaning |
|---|---|
pending, processing | Accepted. The money hasn’t moved yet. |
successful | The money has left your account. |
failed | It didn’t go. The reserved amount is released. failureReason says why. |
reversed | It left and came back. |
A 200 means this idempotency key already named a payment, which is returned rather than sent again.
If the destination receives a different currency from the source account, create an FX quote first and pass fxQuoteId.
A 202 means one of your approval policies holds the payment. The money is set aside and nothing is sent until it is approved.
Requires the payments:write scope.
POST
/
v1
/
transfers
Send a payment
curl --request POST \
--url https://api.talescria.com/v1/transfers \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"fromAccountId": "acct_01M2P8GP7RSDXN81CXRFM2HFV7",
"recipientId": "rcp_9f2c1e4a7b8d4e0f9a1b2c3d4e5f6071",
"destinationId": "dst_4a7b8d4e0f9a1b2c3d4e5f60719f2c1e",
"minorUnits": "125000",
"currency": "GBP",
"narration": "July invoice",
"idempotencyKey": "form_7c1e4a7b8d4e"
}
'import requests
url = "https://api.talescria.com/v1/transfers"
payload = {
"fromAccountId": "acct_01M2P8GP7RSDXN81CXRFM2HFV7",
"recipientId": "rcp_9f2c1e4a7b8d4e0f9a1b2c3d4e5f6071",
"destinationId": "dst_4a7b8d4e0f9a1b2c3d4e5f60719f2c1e",
"minorUnits": "125000",
"currency": "GBP",
"narration": "July invoice",
"idempotencyKey": "form_7c1e4a7b8d4e"
}
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({
fromAccountId: 'acct_01M2P8GP7RSDXN81CXRFM2HFV7',
recipientId: 'rcp_9f2c1e4a7b8d4e0f9a1b2c3d4e5f6071',
destinationId: 'dst_4a7b8d4e0f9a1b2c3d4e5f60719f2c1e',
minorUnits: '125000',
currency: 'GBP',
narration: 'July invoice',
idempotencyKey: 'form_7c1e4a7b8d4e'
})
};
fetch('https://api.talescria.com/v1/transfers', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"transfer": {
"id": "<string>",
"fromAccountId": "<string>",
"destinationId": "<string>",
"minorUnits": "<string>",
"currency": "<string>",
"status": "pending",
"createdAt": 123,
"updatedAt": 123,
"recipientId": "<string>",
"narration": "<string>",
"reason": "<string>",
"failureReason": "<string>"
}
}{
"transfer": {
"id": "<string>",
"fromAccountId": "<string>",
"destinationId": "<string>",
"minorUnits": "<string>",
"currency": "<string>",
"status": "pending",
"createdAt": 123,
"updatedAt": 123,
"recipientId": "<string>",
"narration": "<string>",
"reason": "<string>",
"failureReason": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}Authorizations
Headers
Body
application/json