Skip to main content
POST
Record a transfer between your accounts

Authorizations

Authorization
string
header
required

A group API key, sent as Authorization: Bearer sw_live_…. Keys from staging and the demo start sw_test_ instead. A group admin creates keys in Settings → Integrations → API keys.

Scopes

accounting:write

Headers

Idempotency-Key
string
required

Unique per transfer: any printable text up to 255 characters. A retry with the same key and body within 24 hours answers with the first transfer instead of making another. Required.

Required string length: 1 - 255

Body

application/json

A field not listed here is refused with a 400.

fromBankAccountId
string<uuid>
required

One of the group’s open accounts: where the money left.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
toBankAccountId
string<uuid>
required

Another of the group’s open accounts: where it arrived.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
amount
string
required

Pounds, as a string with at most two decimal places: "12.50". Always positive: the type gives the direction.

Pattern: ^\d+(\.\d{1,2})?$
date
string<date>
required

The day the money left, as the statement shows it.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
description
string
required

What the transfer was, for example "Savings to current". Stored on both lines.

Required string length: 1 - 500
destinationDate
string<date>

The day it arrived, when that statement shows a different day. At most 7 days from date. Defaults to date.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
reference
string

The bank reference, if any.

Required string length: 1 - 200
{key}
any

Response

The transfer an earlier request with the same Idempotency-Key made.

data
object
required