Skip to main content

Overview

Transactions track all financial movements in the platform, including charges, credits, refunds, and withdrawals. They represent the atomic units of financial operations between users, orders, and trips.

List Transactions

Retrieve a paginated list of transactions with optional filtering.
page
number
default:"1"
Page number for pagination
limit
number
default:"10"
Number of items per page
type
string
Filter by transaction type (CHARGE, CREDIT, REFUND, WITHDRAWAL, TRANSFER)
status
string
Filter by transaction status (PENDING, PROCESSED, FAILED, CANCELLED)
fromUserId
string
Filter by source user UUID (debtor)
toUserId
string
Filter by destination user UUID (creditor)
startDate
string
Start date for date range filter (ISO format)
endDate
string
End date for date range filter (ISO format)
minAmount
number
Minimum gross amount
maxAmount
number
Maximum gross amount
Search by transaction ID or user email/name
curl -X GET "https://api.rodando.com/transactions?page=1&limit=10&type=CHARGE&status=PROCESSED" \
  -H "Authorization: Bearer YOUR_TOKEN"
{
  "success": true,
  "data": [
    {
      "id": "aa0e8400-e29b-41d4-a716-446655440000",
      "type": "CHARGE",
      "grossAmount": 100.00,
      "platformFeeAmount": 20.00,
      "netAmount": 80.00,
      "currency": "CUP",
      "status": "PROCESSED",
      "orderId": "550e8400-e29b-41d4-a716-446655440000",
      "tripId": "660e8400-e29b-41d4-a716-446655440000",
      "fromUserId": "770e8400-e29b-41d4-a716-446655440000",
      "toUserId": "880e8400-e29b-41d4-a716-446655440000",
      "description": "Charge for trip #1234",
      "processedAt": "2026-03-09T10:30:00.000Z",
      "createdAt": "2026-03-09T10:00:00.000Z"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 10,
    "total": 250
  }
}

Get Transaction Details

Retrieve detailed information about a specific transaction.
id
string
required
Transaction UUID
curl -X GET "https://api.rodando.com/transactions/aa0e8400-e29b-41d4-a716-446655440000" \
  -H "Authorization: Bearer YOUR_TOKEN"
{
  "success": true,
  "data": {
    "id": "aa0e8400-e29b-41d4-a716-446655440000",
    "type": "CHARGE",
    "grossAmount": 100.00,
    "platformFeeAmount": 20.00,
    "netAmount": 80.00,
    "currency": "CUP",
    "status": "PROCESSED",
    "orderId": "550e8400-e29b-41d4-a716-446655440000",
    "tripId": "660e8400-e29b-41d4-a716-446655440000",
    "fromUserId": "770e8400-e29b-41d4-a716-446655440000",
    "toUserId": "880e8400-e29b-41d4-a716-446655440000",
    "description": "Charge for trip #1234",
    "processedAt": "2026-03-09T10:30:00.000Z",
    "metadata": {
      "gateway": "stripe",
      "intentId": "pi_123456"
    },
    "createdAt": "2026-03-09T10:00:00.000Z",
    "updatedAt": "2026-03-09T10:30:00.000Z"
  }
}

Create Transaction

Create a new financial transaction.
type
string
required
Transaction type: CHARGE, CREDIT, REFUND, WITHDRAWAL, or TRANSFER
grossAmount
number
required
Gross amount before fees (decimal)
netAmount
number
required
Net amount after fees (decimal)
platformFeeAmount
number
Platform fee amount (decimal)
currency
string
default:"CUP"
ISO 4217 currency code (3 letters)
status
string
default:"PENDING"
Initial transaction status: PENDING, PROCESSED, FAILED, or CANCELLED
orderId
string
Associated order UUID (if applicable)
tripId
string
Associated trip UUID (if applicable)
fromUserId
string
Source user UUID (debtor)
toUserId
string
Destination user UUID (creditor)
processedAt
string
Processing timestamp (ISO format)
description
string
Human-readable description (max 250 characters)
metadata
object
Free-form metadata (e.g., gateway response, logs)
curl -X POST "https://api.rodando.com/transactions" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "CHARGE",
    "grossAmount": 100.00,
    "platformFeeAmount": 20.00,
    "netAmount": 80.00,
    "currency": "CUP",
    "status": "PENDING",
    "orderId": "550e8400-e29b-41d4-a716-446655440000",
    "tripId": "660e8400-e29b-41d4-a716-446655440000",
    "fromUserId": "770e8400-e29b-41d4-a716-446655440000",
    "toUserId": "880e8400-e29b-41d4-a716-446655440000",
    "description": "Charge for trip #1234"
  }'
{
  "success": true,
  "data": {
    "id": "aa0e8400-e29b-41d4-a716-446655440000",
    "type": "CHARGE",
    "grossAmount": 100.00,
    "platformFeeAmount": 20.00,
    "netAmount": 80.00,
    "currency": "CUP",
    "status": "PENDING",
    "orderId": "550e8400-e29b-41d4-a716-446655440000",
    "tripId": "660e8400-e29b-41d4-a716-446655440000",
    "fromUserId": "770e8400-e29b-41d4-a716-446655440000",
    "toUserId": "880e8400-e29b-41d4-a716-446655440000",
    "description": "Charge for trip #1234",
    "createdAt": "2026-03-09T10:00:00.000Z",
    "updatedAt": "2026-03-09T10:00:00.000Z"
  }
}

Update Transaction

Partially update a transaction’s fields.
id
string
required
Transaction UUID
status
string
Updated transaction status
processedAt
string
Processing timestamp (ISO format)
metadata
object
Updated metadata
curl -X PATCH "https://api.rodando.com/transactions/aa0e8400-e29b-41d4-a716-446655440000" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "status": "PROCESSED",
    "processedAt": "2026-03-09T10:30:00.000Z"
  }'
{
  "success": true,
  "data": {
    "id": "aa0e8400-e29b-41d4-a716-446655440000",
    "status": "PROCESSED",
    "processedAt": "2026-03-09T10:30:00.000Z",
    "updatedAt": "2026-03-09T10:35:00.000Z"
  }
}

Delete Transaction

Soft-delete a transaction. The transaction remains in the database but is marked as deleted.
id
string
required
Transaction UUID
curl -X DELETE "https://api.rodando.com/transactions/aa0e8400-e29b-41d4-a716-446655440000" \
  -H "Authorization: Bearer YOUR_TOKEN"
{
  "success": true,
  "message": "Transaction soft-deleted",
  "data": null
}

Transaction Types

  • CHARGE: Debit from user (e.g., payment for a trip)
  • CREDIT: Credit to user (e.g., refund, bonus)
  • REFUND: Return of previously charged amount
  • WITHDRAWAL: User withdraws funds from their wallet
  • TRANSFER: Transfer between user accounts

Transaction Status

  • PENDING: Transaction created but not yet processed
  • PROCESSED: Transaction successfully completed
  • FAILED: Transaction processing failed
  • CANCELLED: Transaction was cancelled before processing

Build docs developers (and LLMs) love