Skip to content

Stellar ​

Stellar carries USDC and USDT. Payments settle in about five seconds for a fraction of a cent, and every one can be looked up on a public explorer.

Being released

The money rails described here are built and tested, and are being rolled out. Until a rail is switched on for the exchange, invoices are paid by bank transfer or mobile money and recorded by Finance, as today.

Network

The exchange runs on the Stellar test network until it is switched to the main network. USDC is Circle's; USDT on Stellar is a test coin until a main network issuer is confirmed. Do not send main network funds to a test address.

Two accounts ​

AccountReceivesPays out
ExchangeInvoice paymentsPayouts, freight, advances
EscrowEscrow fundingEscrow releases and refunds

Both accounts need two signatures for any payment, from two separate keys, so neither key alone can move money. See Approvals and transfers.

Paying in ​

A payment is matched by its memo, and only by its memo. The memo is the id of what is being paid: INV-0042 for an invoice, ESC-0007 for an escrow.

The public invoice page, and the escrow's funding instructions, show everything the payer needs:

FieldExample
AccountThe exchange's or the escrow account's G… address
CoinUSDT, with its issuer
Memo (text)INV-0042
Amount154500.00

and a QR code in the SEP-7 format (web+stellar:pay?...) that a Stellar wallet supporting SEP-7 payment links can scan to fill all of it in.

The exchange's poller sees the payment within seconds and:

  • applies it to the invoice; a part payment makes the invoice Part-paid, the rest makes it Paid. Anything paid over what is owed is noted on the transfer for Finance to return;
  • or marks the escrow Funded, if the amount and coin match exactly.

A payment the exchange cannot match is kept as not applied, with the reason, for Finance to return:

  • no memo, or a memo nothing on the exchange has;
  • a coin the invoice or escrow is not in;
  • an amount that is not a whole number of cents;
  • an escrow payment for the wrong amount (the escrow keeps waiting for the right one);
  • invoice money sent to the escrow account, or escrow money to the exchange account.

Paying out ​

To be paid on Stellar, a party needs:

  1. A Stellar address (G…) on their record in the registry (Global Buyers → Parties, the Stellar account field).
  2. A trustline for the coin on that account, so it can hold USDC or USDT. The exchange checks this before it asks for approvals, and says so if the trustline is missing (no_trustline).

The payment is built when the second approval comes in, signed with both keys, and sent with a five-minute time limit. If it has not landed in that window, it is rebuilt from the same approvals; the first can no longer land, so the money cannot go twice.

What Finance sees ​

Finance → Transfers lists every Stellar transfer with a link to the transaction on the explorer, and Held on Stellar shows the balances of both accounts, including the XLM that pays the network fees.

AgriTrade Exchange