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

# List customer activities

Retrieves a paginated list of loyalty activities for a customer — including points earned, rewards redeemed, tier changes, and manual adjustments. Results are sorted by `created_at` in descending order.

**GET /public/customers/activities**

#### **Authorizations**

**Authorization**

**string**

**header**

**required**

Bearer authentication header of the form `Bearer <token>`, where `<token>` is your REST API token.

#### **Required Scope**

**`activities:read`**

This endpoint requires the `activities` scope with **Read Access**. Configure token scopes in Settings → Integrations → REST API.

#### **Query Parameters**

**customer\_id**

**string**

**required**

The platform customer ID (e.g. Shopify customer ID)

Example:

`"9049402769586"`

#### **Query Parameters**

**source\_type**

**enum\<string>**

Filter results to activities from the specified source.

Available options:

`loyalty_campaigns`,

`loyalty_rewards`,

`loyalty_customer_rewards`,

`loyalty_tiers`,

`loyalty_tier_benefits`,

`users`,

`loyalty_transactions`,

`referral_transactions`

**activity\_type**

**string**

Filter results to a specific activity type (e.g. `purchase`, `point_adjustment`, `reward_used`).

Example:

`"purchase"`

**per\_page**

**integer**

**default: 20**

The number of results per page.

Required range: `1 <= x <= 100`

**page**

**integer**

**default: 1**

The page number to retrieve.

#### **Response**

**200 - application/json**

**data**

**object\[]**

Hide child attributes

**data.id**

**string\<uuid>**

Unique UUID identifier for the activity.

Example:

`"f7a8b9c0-d1e2-3456-fabc-d01234567890"`

**data.customer\_id**

**string\<uuid>**

The UUID of the customer this activity belongs to.

Example:

`"63a2c89a-9936-4bc0-9d5f-93db46110b76"`

**data.activity\_type**

**string**

The type of action that occurred.

Example:

`"purchase"`

**data.source\_type**

**string**

The module or entity that generated this activity.

Example:

`"loyalty_campaigns"`

**data.source\_id**

**string\<uuid> | null**

The UUID of the source record (e.g. campaign, reward) that triggered this activity.

Example:

`"a1b2c3d4-e5f6-7890-abcd-ef1234567890"`

**data.entry\_type**

**enum\<string> | null**

Whether the activity resulted in a points credit or debit.

Available options:

`credit`,

`debit`

Example:

`"credit"`

**data.points**

**integer**

The number of points involved in this activity.

Example:

`100`

**data.earning\_type**

**string | null**

The type of earning (e.g. `points`, `store_credit`).

Example:

`"points"`

**data.metadata**

**object**

Additional details about the activity. Structure varies by `activity_type`.

**data.created\_at**

**string\<date-time>**

Example:

`"2026-02-15T08:30:00.000Z"`

**meta**

**object**

Hide child attributes

**meta.pagination**

**object**

Hide child attributes

**meta.pagination.current\_page**

**integer**

Example:

`1`

**meta.pagination.per\_page**

**integer**

Example:

`20`

**meta.pagination.total**

**integer**

Example:

`12`

**meta.pagination.last\_page**

**integer**

Example:

`1`

**meta.pagination.has\_more**

**boolean**

Example:

`false`

<RequestExample>
  ```bash cURL theme={null}
  curl --request GET \
    --url "https://api.yukoapp.com/api/v1/public/customers/activities?customer_id=9049402769586?per_page=20" \
    --header "Authorization: Bearer py_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  ```

  ```javascript JavaScript theme={null}
  const customerId = "9049402769586";
  const params = new URLSearchParams({ per_page: 20 });

  const response = await fetch(
    `https://api.yukoapp.com/api/v1/public/customers/activities?customer_id=${customerId}?${params}`,
    {
      method: "GET",
      headers: {
        Authorization: "Bearer py_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
      },
    }
  );

  const data = await response.json();
  ```

  ```php PHP theme={null}
  $customerId = "9049402769586";
  $query = http_build_query(["per_page" => 20]);

  $ch = curl_init();
  curl_setopt($ch, CURLOPT_URL, "https://api.yukoapp.com/api/v1/public/customers/activities?customer_id={$customerId}?{$query}");
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  curl_setopt($ch, CURLOPT_HTTPHEADER, [
      "Authorization: Bearer py_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
  ]);

  $response = curl_exec($ch);
  curl_close($ch);

  $data = json_decode($response, true);
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "data": [
      {
        "id": "f7a8b9c0-d1e2-3456-fabc-d01234567890",
        "customer_id": "63a2c89a-9936-4bc0-9d5f-93db46110b76",
        "activity_type": "purchase",
        "source_type": "loyalty_campaigns",
        "source_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
        "entry_type": "credit",
        "points": 100,
        "earning_type": "points",
        "metadata": {
          "earning_value": 100,
          "earning_type": "points",
          "entry_type": "credit"
        },
        "created_at": "2026-02-15T08:30:00.000Z"
      },
      {
        "id": "e6b7c8d9-e0f1-2345-efab-c01234567890",
        "customer_id": "63a2c89a-9936-4bc0-9d5f-93db46110b76",
        "activity_type": "point_adjustment",
        "source_type": "users",
        "source_id": null,
        "entry_type": "credit",
        "points": 50,
        "earning_type": "points",
        "metadata": {
          "description": "Bonus for completing a survey",
          "source": "rest_api"
        },
        "created_at": "2026-02-10T12:00:00.000Z"
      }
    ],
    "meta": {
      "pagination": {
        "current_page": 1,
        "per_page": 20,
        "total": 2,
        "last_page": 1,
        "has_more": false
      }
    }
  }
  ```

  ```json 404 theme={null}
  {
    "error": {
      "code": "not_found",
      "message": "Customer not found"
    }
  }
  ```

  ```json 401 theme={null}
  {
    "error": {
      "code": "invalid_token",
      "message": "Invalid or revoked API token"
    }
  }
  ```
</ResponseExample>
