v1

latestOpenAPI 3.0.22026-07-17191121.5 KB
users

Send payment to an account. Note that even though this is a user-only endpoint, node operators have access to server secrets, meaning that they could issue payments from any account if they wished to.

post/accounts/{username}/payments

Headers

authorizationstring required

Bearer token with the account's authorization

Request body

receiverstring required
source_amountinteger required

Example request

{
  "receiver": "$payment-pointer.example.com",
  "source_amount": 100000
}

Response

The receipt of delivery to the receiver

source_asset_scaleinteger
source_asset_codestring
sent_amountinteger

Amount fulfilled or currently in-flight, in source units

source_amountinteger

Total amount intended to be sent, in source units

in_flight_amountinteger

Amount in-flight (yet to be fulfilled or rejected), in source units

delivered_amountnumber

Amount fulfilled and received by the recipient, in destination units

destination_asset_scaleinteger
destination_asset_codestring
fromstring
tostring

Example response

{
  "source_asset_scale": 9,
  "source_asset_code": "XYZ",
  "sent_amount": 1000000,
  "delivered_amount": 1000000,
  "destination_asset_scale": 9,
  "destination_asset_code": "ABC",
  "from": "example.node_a.alice",
  "to": "example.node_b.bob.-p3zU4tXsDRCBLg8vt_U6iiyQ5pgZk4MfoCaG1wZDW8"
}