Payment Codes

Redeem Codes and Claim Links

One-time payments with two recipient experiences: standard redeem codes and private claim links

Payment Codes let a sender lock funds first and let the recipient choose when to complete the payout. Today RelAI supports classic 8-character codes and private claim links across EVM escrow networks and Solana vault networks.

Standard codes are redeemed by entering the code and a payout address. Private claim links keep the raw code hidden and require the recipient to connect a wallet, sign once, and either claim the code itself or claim USDC directly.

1-use
Familiar UX
Send a short code or a private claim link, then let the recipient finish the payout later
2 modes
Claim code or claim USDC
Private claim links support immediate payout or revealing the hidden code for later redeem
Locked
Claim links stay private
Claim-link escrow stays locked until expiry so the sender cannot cancel early after sharing it

How It Works

Standard 8-character code flow
1. Sender funds a code from the create UI or the facilitator API
↓ EVM uses escrow contracts on Base or SKALE, Solana uses program vaults
2. RelAI returns an 8-character code with an expiry time
↓ sender shares the code with the recipient
3. Recipient opens /redeem and enters the code
↓ recipient provides a payout address
4. RelAI redeems the locked funds and, when needed, bridges the payout to the requested destination network
Private claim link flow
1. Sender creates a code with Private claim link enabled
↓ RelAI returns a claim token link instead of exposing the raw 8-character code
2. Recipient opens /claim/<claimToken>
↓ link type decides which wallet signs: Solana for Solana links, EVM for EVM links
3. Recipient chooses Claim USDC or Claim code
↓ claim-usdc pays out immediately, claim-code reveals the hidden code for later redeem
4. Claim-link escrow stays cancel-locked until expiry

Security: Standard codes are bearer instruments, so anyone with the code can redeem it. Private claim links add a wallet signature step and keep the raw code hidden until the recipient explicitly claims it.

SKALE privacy: When the source settlement network is SKALE Base Sepolia, funding and settlement metadata can use BITE-encrypted flows while keeping the same redeem and claim UX.

Redeem and Claim UI

Recipients redeem standard codes at /redeem. Private claim links open directly at /claim/<claimToken>.

  1. 1Standard code: enter the 8-character code and the payout address
  2. 2EVM-backed standard codes redeem to an EVM address, while Solana-backed codes can redeem to Solana or EVM destinations
  3. 3Private claim link: connect the required wallet type and sign once
  4. 4Claim USDC pays out immediately, claim code reveals the hidden code for the normal redeem flow
  5. 5Success screens include source settlement and payout explorer links when available

Standard redeem does not require recipient wallet signatures. Private claim links do require a connected wallet, and the wallet type must match the claim-link source network.

API Endpoints

RelAI exposes different endpoints for EVM escrow-backed codes, Solana vault-backed codes, and private claim links. The exact source network determines which route family to use.

POST
/facilitator/payment-codes

Register an EVM-backed code after escrow funding. Supports claimLink for private claim links.

GET
/facilitator/payment-codes/:code

Read EVM-backed code status, funding tx info, claim-link metadata, and settlement status.

POST
/facilitator/payment-codes/:code/redeem

Redeem an EVM-backed standard code to an EVM address.

GET
/facilitator/payment-codes/claim-links/evm/:claimToken

Read the status of an EVM claim link.

POST
/facilitator/payment-codes/claim-links/evm/:claimToken/claim

Claim an EVM claim link with mode claim-usdc or claim-code.

POST
/facilitator/solana-payment-codes

Create a Solana-backed vault code or claim link.

POST
/facilitator/solana-payment-codes/:code/redeem

Redeem a Solana-backed standard code to Solana or EVM.

POST
/facilitator/solana-payment-codes/claim-links/:claimToken/claim

Claim a Solana claim link with mode claim-usdc or claim-code.

Register an EVM escrow-backed private claim link
curl -X POST https://api.relai.fi/facilitator/payment-codes   -H "X-Service-Key: sk_live_..."   -H "Content-Type: application/json"   -d '{
    "from": "0xSenderWallet",
    "code": "D92T5TPW",
    "value": 5000000,
    "validBefore": 1735000000,
    "settlementNetwork": "base-sepolia",
    "escrowMode": true,
    "claimLink": true,
    "fundingTxHash": "0xFundingTxHash..."
  }'

# Response
{
  "code": "D92T5TPW",
  "claimLink": true,
  "claimToken": "clm_2qY7...",
  "validBefore": 1735000000,
  "expiresIn": 300,
  "cancelLockedUntilExpiry": true
}
Successful claim-usdc response
{
  "success": true,
  "claimLink": true,
  "claimMode": "claim-usdc",
  "amount": "5000000",
  "settlementNetwork": "base-sepolia",
  "targetAddress": "0xRecipient...",
  "targetNetwork": "base-sepolia",
  "sourceSettlementTxHash": "0xsource...",
  "payoutTxHash": "0xpayout...",
  "explorerUrl": "https://sepolia.basescan.org/tx/0xpayout...",
  "private": false
}

Settlement Networks

The exact list depends on the deployed environment, but testnet and mainnet follow the same model: EVM escrow networks use EVM wallet signatures for claim links, and Solana vault networks use Solana wallet signatures.

NetworkIDSource modelClaim-link signerPrivacy
Base Sepoliabase-sepoliaEVM escrow-backed codeEVM walletPublic
SKALE Base Sepoliaskale-base-sepoliaEVM escrow-backed codeEVM walletBITE-enabled
Solana Devnetsolana-devnetSolana vault-backed codeSolana walletPublic

Error Handling

not_found- Code not found

The code or claim token does not exist. Check for typos or confirm the sender created it successfully.

expired- Code expired

The TTL elapsed. The issuer must generate a new code.

already_redeemed- Already redeemed

This code was already settled. Each code is single-use.

cancelled- Code cancelled

The issuer cancelled the code before it was redeemed.

already_claimed- Claim link already used

The claim link was already converted into a code or already paid out to a destination.

invalid_signature- Invalid claim signature

The connected wallet did not match the wallet type or the signed payload was stale or malformed.

target_network_required- Destination network required

When claiming to an EVM destination, provide the target settlement network as well as the address.

    Redeem Codes and Claim Links - Payment Codes | RelAI Documentation | RelAI