Token Transfer with Memo

Attach memo data to SPL token transfers

Request

const response = await fetch(
  'https://arrow-api.yatori.io/v1/token-transfer-memo',
  {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
      'Authorization': 'Bearer <insert API key here>'
    },
    body: JSON.stringify({
      from_address: 'G8RtxPyG2pdrAhrNRMgg7Hia8imCofdCYxvyWiNG14hx',
      to_address: 'gmDexz3AyHdgCyHrbYUrGUvodYE953oGKmywiNzgtGK',
      token_mint_address: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
      amount: '1000',
      yid: 'inventory restock 428'
    })
  }
)

Response

response.json
{
  "data": [
    1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 9, 224, 198, 132, 241, 33, 60, 165, 69, 165, 137, 249, 56, 14, 189, 194, 57, 107, 230, 202, 36, 126, 45, 186, 41, 133, 233, 0, 160, 254, 107, 105, 131, 114, 209, 25, 121, 139, 14, 220, 248, 44, 176, 117, 159, 14, 254, 214, 6, 151, 36, 118, 109, 236, 203, 32, 120, 192, 61, 6, 179, 173, 45, 218, 45, 127, 137, 237, 247, 130, 56, 74, 134, 204, 67, 191, 123, 166, 91, 79, 41, 161, 140, 76, 123, 201, 155, 45, 37, 32, 35, 97, 191, 124, 46, 38, 180, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 2, 0, 1, 12, 2, 0, 0, 0, 160, 134, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 4, 2, 0, 2, 6, 8, 3, 5, 1, 0, 5, 4, 0, 2, 0, 0, 9, 3, 232, 3, 0, 0, 0, 0, 0, 0, 4, 0, 152, 1, 97, 114, 114, 111, 119, 45, 97, 112, 105, 124, 109, 105, 110, 116, 58, 69, 80, 106, 70, 87, 100, 100, 53, 65, 117, 102, 113, 83, 83, 113, 101, 77, 50, 113, 78, 49, 120, 122, 121, 98, 97, 112, 67, 56, 71, 52, 119, 69, 71, 71, 107, 90, 119, 121, 84, 68, 116, 49, 118, 124, 102, 58, 71, 56, 82, 116, 120, 80, 121, 71, 50, 112, 100, 114, 65, 104, 114, 78, 82, 77, 103, 103, 55, 72, 105, 97, 56, 105, 109, 67, 111, 102, 100, 67, 89, 120, 118, 121, 87, 105, 78, 71, 49, 52, 104, 120, 124, 109, 58, 73, 110, 118, 101, 110, 116, 111, 114, 121, 32, 114, 101, 115, 116, 111, 99, 107, 32, 35, 52, 50, 56
  ],
  "status": "Token transfer with memo created successfully"
}

Endpoint

POST
https://arrow-api.yatori.io/v1/token-transfer-memo

Headers

Auth Bearer Token

Include your Arrow API key as a Bearer token in the Authorization header

stringrequired

Parameters

from_address

The wallet address sending the tokens

stringrequired

to_address

The wallet address receiving the tokens

stringrequired

token_mint_address

The mint address of the SPL token being transferred

stringrequired

amount

The amount to transfer in base units

stringrequired

yid

Unique identifier (YID) to embed in the transaction memo

stringrequired

fee_des (optional)

The destination address for the fee

string addressoptional

fee_amount (optional)

The fee amount in base units

base unit stringoptional