SSeev PlusDocs
Stellar Anchor

Transactions

Query transaction status, understand the lifecycle, configure callbacks, and use the more_info page.

The SeevCash anchor tracks every deposit and withdrawal as a transaction with a defined lifecycle. This page covers querying transactions, understanding statuses, configuring callbacks, and using the more_info page.

Endpoints

MethodPathDescription
GET/sep6/transactionGet a single transaction by ID or external ID
GET/sep6/transactionsList transactions for an account

All endpoints require a valid SEP-10 JWT token.

Query a single transaction

curl -X GET "https://<your-anchor-domain>/sep6/transaction?id=txn_8f3a4b2c-1d5e-6f7a-8b9c-0d1e2f3a4b5c" \
  -H "Authorization: Bearer <sep10_jwt_token>"
import { Wallet, Keypair } from '@stellar/typescript-wallet-sdk';

const wallet = Wallet.TestNet();
const anchor = wallet.anchor({ homeDomain: '<your-anchor-domain>' });
const accountKp = Keypair.fromSecret('SCZANGBA5YHTNYVVV3C7CAZMCLXPJLNS2YFGXDNASLFTGBPFMRKCY6ML');

const sep10 = await anchor.sep10();
const authToken = await sep10.authenticate({ accountKp });

// Get a single transaction by ID
const sep6 = anchor.sep6();
const { transaction } = await sep6.getTransactionBy({
  authToken,
  id: 'txn_8f3a4b2c-1d5e-6f7a-8b9c-0d1e2f3a4b5c',
});
console.log("Status:", transaction.status);

Query parameters

ParameterDescription
idAnchor transaction ID
stellar_transaction_idStellar network transaction hash
external_transaction_idExternal (MoMo) transaction reference

Response:

{
  "transaction": {
    "id": "txn_8f3a4b2c-1d5e-6f7a-8b9c-0d1e2f3a4b5c",
    "kind": "deposit",
    "status": "completed",
    "status_eta": null,
    "amount_in": "100.00",
    "amount_in_asset": "iso4217:GHS",
    "amount_out": "6.50",
    "amount_out_asset": "stellar:USDC:GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5",
    "amount_fee": "0.10",
    "amount_fee_asset": "stellar:USDC:GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5",
    "started_at": "2026-08-05T01:15:00Z",
    "completed_at": "2026-08-05T01:19:30Z",
    "stellar_transaction_id": "abc123def456...",
    "external_transaction_id": "MOMO-REF-12345",
    "more_info_url": "https://<your-anchor-domain>/more-info/txn_8f3a4b2c",
    "message": null
  }
}

List transactions

curl -X GET "https://<your-anchor-domain>/sep6/transactions?\
asset_code=USDC&\
account=GCEXAMPLE4KEYPAIR7HERE2REPLACE5WITH5YOUR5ACTUAL5STELLAR5KEY&\
limit=10" \
  -H "Authorization: Bearer <sep10_jwt_token>"
import { Wallet, Keypair } from '@stellar/typescript-wallet-sdk';

const wallet = Wallet.TestNet();
const anchor = wallet.anchor({ homeDomain: '<your-anchor-domain>' });
const accountKp = Keypair.fromSecret('SCZANGBA5YHTNYVVV3C7CAZMCLXPJLNS2YFGXDNASLFTGBPFMRKCY6ML');

const sep10 = await anchor.sep10();
const authToken = await sep10.authenticate({ accountKp });

// Get all transactions for USDC
const sep6 = anchor.sep6();
const { transactions } = await sep6.getTransactionsForAsset({
  authToken,
  assetCode: 'USDC',
});

transactions.forEach((tx) => console.log(`${tx.id}: ${tx.status}`));

Query parameters

ParameterRequiredDescription
asset_codeYesFilter by asset code (USDC)
accountYesStellar account
no_older_thanNoISO 8601 date — exclude older transactions
limitNoMax results (default 10)
kindNoFilter by deposit or withdrawal
paging_idNoCursor for pagination

Response:

{
  "transactions": [
    {
      "id": "txn_8f3a4b2c-1d5e-6f7a-8b9c-0d1e2f3a4b5c",
      "kind": "deposit",
      "status": "completed",
      "amount_in": "100.00",
      "amount_out": "6.50",
      "started_at": "2026-08-05T01:15:00Z",
      "completed_at": "2026-08-05T01:19:30Z"
    },
    {
      "id": "txn_9a4b5c6d-7e8f-9a0b-1c2d-3e4f5a6b7c8d",
      "kind": "withdrawal",
      "status": "pending_anchor",
      "amount_in": "6.50",
      "amount_out": "100.00",
      "started_at": "2026-08-05T01:20:00Z"
    }
  ]
}

Transaction status lifecycle

Deposit statuses

incomplete


pending_user_transfer_start  ──► Customer must send/approve MoMo payment


pending_anchor               ──► Anchor received GHS, sending USDC

  ├──────────────────────────────────────────┐
  ▼                                          ▼
completed                                  error

Withdrawal statuses

incomplete


pending_user_transfer_start  ──► Customer must send USDC to anchor


pending_anchor               ──► Anchor received USDC, processing payout


pending_external             ──► GHS payout submitted to MoMo network

  ├──────────────────────────────────────────┐
  ▼                                          ▼
completed                                  error

All possible statuses

StatusMeaning
incompleteTransaction created but not ready for processing
pending_user_transfer_startWaiting for user to send/approve payment
pending_user_transfer_completeUser payment received, awaiting confirmation
pending_anchorAnchor is processing the transaction
pending_stellarWaiting for Stellar network confirmation
pending_externalWaiting for external (MoMo) network confirmation
completedTransaction finished successfully
expiredTransaction expired before completion
errorTransaction failed — see message field
refundedTransaction was refunded to the customer

Polling strategy

Poll every 5–10 seconds during active transactions. Back off to 30–60 seconds after 2 minutes. Stop polling once a terminal status is reached (completed, error, expired, refunded).

import { Wallet, Keypair } from '@stellar/typescript-wallet-sdk';

const wallet = Wallet.TestNet();
const anchor = wallet.anchor({ homeDomain: '<your-anchor-domain>' });
const accountKp = Keypair.fromSecret('SCZANGBA5YHTNYVVV3C7CAZMCLXPJLNS2YFGXDNASLFTGBPFMRKCY6ML');

const sep10 = await anchor.sep10();
const authToken = await sep10.authenticate({ accountKp });

// Use the built-in watcher for automatic polling with backoff
const sep6 = anchor.sep6();
const watcher = sep6.watcher();

const { stop, refresh } = watcher.watchOneTransaction({
  authToken,
  assetCode: 'USDC',
  id: 'txn_8f3a4b2c-1d5e-6f7a-8b9c-0d1e2f3a4b5c',
  onMessage: (txn) => {
    console.log(`Status: ${txn.status}`);
  },
  onSuccess: (txn) => {
    console.log('Transaction completed:', txn.stellar_transaction_id);
    stop();
  },
  onError: (err) => {
    console.error('Transaction failed:', err);
    stop();
  },
});

// Call refresh() to force an immediate poll
// Call stop() to stop watching

on_change_callback

When you provide an on_change_callback URL during deposit or withdrawal initiation, the anchor sends POST requests whenever the transaction status changes:

{
  "transaction": {
    "id": "txn_8f3a4b2c-1d5e-6f7a-8b9c-0d1e2f3a4b5c",
    "status": "pending_anchor",
    "amount_in": "100.00",
    "amount_out": "6.50"
  }
}

Callback requirements

  • Must be a publicly accessible HTTPS URL
  • Must respond with 200 OK within 5 seconds
  • Callbacks are best-effort — not guaranteed delivery
  • Always verify state by polling after receiving a callback

Do not use callbacks as your sole transaction monitoring mechanism. They supplement polling but may be delayed, retried, or missed entirely.

The more_info page

Every transaction includes a more_info_url — a web page hosted by the anchor showing full transaction details. This is useful for:

  • Customer-facing transaction receipts
  • Support and dispute resolution
  • Embedding in wallet UIs via iframe or link
https://<your-anchor-domain>/more-info/txn_8f3a4b2c

The page displays:

  • Transaction type, status, and timestamps
  • Amount in/out with exchange rate
  • Fee breakdown
  • Stellar transaction link (if completed)
  • MoMo transaction reference (if applicable)

Transaction response fields

FieldTypeDescription
idstringUnique transaction identifier
kindstringdeposit or withdrawal
statusstringCurrent status (see lifecycle above)
status_etanumberEstimated seconds until next status change
amount_instringAmount received by the anchor
amount_in_assetstringAsset identifier for amount_in
amount_outstringAmount sent to the customer
amount_out_assetstringAsset identifier for amount_out
amount_feestringFee charged
amount_fee_assetstringAsset the fee is denominated in
started_atstringISO 8601 timestamp when transaction started
completed_atstringISO 8601 timestamp when completed (null if pending)
stellar_transaction_idstringStellar network transaction hash
external_transaction_idstringExternal reference (MoMo transaction ID)
more_info_urlstringURL to the transaction detail page
messagestringHuman-readable status message or error detail

On this page