Method Signature
align.transfers.getOfframpTransfer(
customerId: string,
transferId: string
): Promise<Transfer>
Parameters
The unique customer identifier (UUID format)
The unique offramp transfer identifier
Returns
Unique transfer identifier
Current status: pending, processing, completed, failed
Amount of cryptocurrency sent
Examples
import Align from "@tolbel/align";
const align = new Align({
apiKey: process.env.ALIGN_API_KEY!,
environment: "sandbox",
});
const transfer = await align.transfers.getOfframpTransfer(
"123e4567-e89b-12d3-a456-426614174000",
"tr_offramp_abc123"
);
console.log(`Status: ${transfer.status}`);
console.log(`Sent: ${transfer.source_amount} USDC`);
console.log(`Received: $${transfer.destination_amount} USD`);
const transfer = await align.transfers.getOfframpTransfer(
"123e4567-e89b-12d3-a456-426614174000",
"tr_offramp_abc123"
);
console.log("Status:", transfer.status);
Full Response Example
{
"id": "tr_offramp_abc123",
"status": "completed",
"type": "offramp",
"source_amount": "100.00",
"source_token": "usdc",
"source_network": "polygon",
"destination_amount": "98.50",
"destination_currency": "usd",
"fee_amount": "1.50",
"created_at": "2024-01-15T10:30:00Z",
"completed_at": "2024-01-15T10:45:00Z"
}