> ## Documentation Index
> Fetch the complete documentation index at: https://docs.gameball.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Fetch Order Details

> Retrieve order transaction history and customer activities

Retrieve detailed information about orders and customer activities to display purchase history, verify transactions, support customers, or feed analytics. Two endpoints cover this: one scoped to a single order, the other to a customer's full activity log.

## Order Transactions

Get all transactions associated with a specific order:

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET 'https://api.gameball.co/api/v4.0/integrations/orders/{orderId}/transactions' \
    -H 'APIKey: YOUR_API_KEY' \
    -H 'SecretKey: YOUR_SECRET_KEY'
  ```
</RequestExample>

<ResponseExample>
  ```json Success theme={null}
  {
    "orderId": "ORD000123",
    "transactions": [
      {
        "transactionId": "TXN001",
        "type": "points_earned",
        "points": 9.5,
        "timestamp": "2025-10-19T12:10:00Z"
      },
      {
        "transactionId": "TXN002",
        "type": "points_redeemed",
        "points": 100,
        "timestamp": "2025-10-19T12:10:00Z"
      }
    ]
  }
  ```
</ResponseExample>

## Customer Activities

Get the complete purchase history and activities for a customer:

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET 'https://api.gameball.co/api/v4.0/integrations/customers/{customerId}/activities' \
    -H 'APIKey: YOUR_API_KEY' \
    -H 'SecretKey: YOUR_SECRET_KEY'
  ```
</RequestExample>

<ResponseExample>
  ```json Success theme={null}
  {
    "customerId": "12345",
    "activities": [
      {
        "activityId": "ACT001",
        "type": "order",
        "orderId": "ORD000123",
        "pointsEarned": 9.5,
        "pointsRedeemed": 100,
        "date": "2025-10-19T12:10:00Z"
      },
      {
        "activityId": "ACT002",
        "type": "order",
        "orderId": "ORD000122",
        "pointsEarned": 15.0,
        "date": "2025-10-18T14:30:00Z"
      }
    ]
  }
  ```
</ResponseExample>

## When to Use Each

* **Display purchase history**: show customers their recent orders and points earned (customer activities).
* **Transaction verification**: confirm a specific order's point breakdown (order transactions).
* **Customer support**: resolve disputes about transactions.
* **Analytics**: track behavior and program engagement.

## Tips & Gotchas

* Use the **order transactions** endpoint for a detailed breakdown of one order.
* Use the **customer activities** endpoint for a complete purchase history.
* Both endpoints support pagination for large result sets.

## Related Resources

<Card title="Order Transactions API" icon="receipt" href="/api-reference/order/order-transactions">
  Complete API reference for order transactions
</Card>

<Card title="Customer Activities API" icon="clock-rotate-left" href="/api-reference/customers/progress/get-customer-activities">
  Complete API reference for customer activities
</Card>
