Generate Travel Address
Generate a new Travel Address for receiving cryptocurrency transactions with embedded Travel Rule compliance information.
Endpoint
POST https://api.trpcontinuum.com/trp/travel-address
Authentication
Requires API key and secret key authentication.
Headers
| Header | Type | Required | Description |
|---|---|---|---|
x-api-key | string | Yes | Your API key for authentication |
x-secret-key | string | Yes | Your secret key for authentication |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
userId | string | Yes | User ID for the beneficiary |
label | string | Yes | Label or description for the travel address |
email | string | Yes | Email address associated with the beneficiary |
Example Request
{
"userId": "{{userId}}",
"label": "Travel Address for Transaction",
"email": "user@example.com"
}
Response
Success (200 OK)
{
"success": true,
"data": {
"id": "cf7d27fb-75f9-4ea1-b65a-bd9050bba9db",
"travelAddress": "taN2raFk3zy7RvbLqAmHJ2kDTbSFrDoMhwLdPPzysxhXnGRqgnsfbqktRpoTssSVBXa9XS7nMjGA2Xqb8AH7eGTZx9cyr85KxZr"
},
"message": "Travel address generated successfully"
}
Error (400 Bad Request)
{
"success": false,
"error": "Invalid request data",
"code": "VALIDATION_ERROR",
"details": {
"beneficiaryVaspId": "VASP ID is required",
"walletAddress": "Invalid wallet address format",
"currency": "Unsupported currency for specified network"
}
}
Error (401 Unauthorized)
{
"success": false,
"error": "Authentication required",
"code": "AUTH_REQUIRED"
}
Error (403 Forbidden)
{
"success": false,
"error": "Insufficient permissions to generate travel addresses",
"code": "INSUFFICIENT_PERMISSIONS"
}
Error (422 Unprocessable Entity)
{
"success": false,
"error": "VASP not found or not enabled for Travel Rule compliance",
"code": "VASP_NOT_ELIGIBLE"
}
Error (500 Internal Server Error)
{
"success": false,
"error": "Failed to generate travel address",
"code": "GENERATION_FAILED"
}
Travel Address Format
Travel Addresses follow the bech32 encoding format:
- Prefix:
ta1(Travel Address version 1) - Length: 104 characters
- Contains embedded beneficiary VASP information
- Includes checksum for validation
Status Values
| Status | Description |
|---|---|
active | Address is active and can receive transactions |
expired | Address has passed its expiration time |
used | Address has been used for a transaction |
revoked | Address has been manually revoked |
QR Code
The response includes a base64-encoded PNG QR code image containing the travel address for easy sharing and scanning.
Usage Example
curl -X POST "{{baseUrl}}/trp/travel-address" \
-H "x-api-key: {your-api-key}" \
-H "x-secret-key: {your-secret-key}" \
-H "Content-Type: application/json" \
-d '{
"userId": "{{userId}}",
"label": "Travel Address for Transaction",
"email": "user@example.com"
}'
Best Practices
- Address Reuse: Generate unique addresses for each transaction
- Expiration: Set appropriate expiration times based on use case
- Validation: Always validate wallet addresses before generation
- Storage: Store travel address mappings for audit purposes
- Monitoring: Track address usage and expiration status