Stellar
Stellar uses memos for deposit identification at shared addresses and requires trustlines before an address can receive non-native tokens.
Memo-Based Deposits
Stellar supports deposit identification using text memos. This allows multiple customers to deposit to a shared address — the memo identifies which customer the deposit belongs to.
How It Works
- Create a Stellar address in your vault
- Assign a unique memo for each customer via the Memos API
- Share the address + memo with the customer
- Incoming deposits include the memo in the webhook payload — match it to the customer
Create a Memo
curl -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"addressId": "hN8qR2tVwX4yZ6aBcDeF3g",
"memo": "customer-12345",
"name": "Customer 12345 Deposits"
}' \
https://api.carabaas.com/api/v1/memos
Sending with Memo
curl -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"orderId": "d2e3f4a5-b6c7-4d8e-9f0a-1b2c3d4e5f6a",
"vaultId": "kR7mNpX2wQvL9sYhBjD4eT",
"destination": "GRecipientAddress...",
"network": "stellar-mainnet",
"asset": "c148",
"amount": "100.00",
"options": {
"memo": "payment-ref-456"
}
}' \
https://api.carabaas.com/api/v1/transactions
Many exchanges require a memo for Stellar deposits. Sending without the correct memo may result in lost funds.
Trustlines
Stellar requires an explicit trustline before an address can receive a non-native token. Without a trustline, incoming token transfers are rejected by the network.
Create a Trustline
curl -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"orderId": "e3f4a5b6-c7d8-4e9f-0a1b-2c3d4e5f6a7b",
"addressId": "gMP71sR5sNUnGdKFTsNzp6",
"network": "stellar-mainnet",
"asset": "USDC:GA5ZSEJYB37JRC5AVCIA5MOP4RHTM335X2KGX3IHOJAPP5RE34K4KZVN"
}' \
https://api.carabaas.com/api/v1/transactions/trustline
Create the trustline before sharing the deposit address for that token. Without it, the transfer will fail on-chain.
Check Existing Trustlines
curl -H "Authorization: Bearer $TOKEN" \
https://api.carabaas.com/api/v1/addresses/{addressId}/trustlines
Reserve Requirements
Each trustline locks 0.5 XLM as a base reserve. Ensure the address has sufficient XLM balance before creating trustlines.
Token Transfers
After the trustline is established, transfer tokens using the standard endpoint:
curl -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"orderId": "f4a5b6c7-d8e9-4f0a-1b2c-3d4e5f6a7b8c",
"vaultId": "kR7mNpX2wQvL9sYhBjD4eT",
"destination": "GRecipient...",
"network": "stellar-mainnet",
"asset": "USDC:GA5ZSEJYB37JRC5AVCIA5MOP4RHTM335X2KGX3IHOJAPP5RE34K4KZVN",
"amount": "500.00"
}' \
https://api.carabaas.com/api/v1/transactions