curl -X POST '/crypto-gateway/payments' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"amount": 49.99,
"currency": "USD",
"description": "Pro Plan - Monthly",
"metadata": {
"order_id": "ord_123",
"customer_email": "alice@example.com"
}
}'
{
"success": true,
"data": {
"payment_id": "pi_01abc123",
"amount": 49.99,
"currency": "USD",
"status": "pending",
"checkout_url": "https://crypto-api.yativo.com/api/v1/crypto-gateway/pay/pi_01abc123",
"description": "Pro Plan - Monthly",
"metadata": { "order_id": "ord_123", "customer_email": "alice@example.com" },
"expires_at": "2026-04-01T12:00:00Z",
"created_at": "2026-04-01T11:00:00Z"
}
}
Create a new payment intent with a hosted checkout URL
curl -X POST '/crypto-gateway/payments' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"amount": 49.99,
"currency": "USD",
"description": "Pro Plan - Monthly",
"metadata": {
"order_id": "ord_123",
"customer_email": "alice@example.com"
}
}'
{
"success": true,
"data": {
"payment_id": "pi_01abc123",
"amount": 49.99,
"currency": "USD",
"status": "pending",
"checkout_url": "https://crypto-api.yativo.com/api/v1/crypto-gateway/pay/pi_01abc123",
"description": "Pro Plan - Monthly",
"metadata": { "order_id": "ord_123", "customer_email": "alice@example.com" },
"expires_at": "2026-04-01T12:00:00Z",
"created_at": "2026-04-01T11:00:00Z"
}
}
Bearer YOUR_ACCESS_TOKENUSD, EUR).order_id, customer_email).curl -X POST '/crypto-gateway/payments' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"amount": 49.99,
"currency": "USD",
"description": "Pro Plan - Monthly",
"metadata": {
"order_id": "ord_123",
"customer_email": "alice@example.com"
}
}'
{
"success": true,
"data": {
"payment_id": "pi_01abc123",
"amount": 49.99,
"currency": "USD",
"status": "pending",
"checkout_url": "https://crypto-api.yativo.com/api/v1/crypto-gateway/pay/pi_01abc123",
"description": "Pro Plan - Monthly",
"metadata": { "order_id": "ord_123", "customer_email": "alice@example.com" },
"expires_at": "2026-04-01T12:00:00Z",
"created_at": "2026-04-01T11:00:00Z"
}
}