---
title: "Record Loyalty Customer Action"
method: POST
path: "/loyalty/v3/stores/{store_id}/custom_actions"
---

# Record Loyalty Customer Action

`POST /loyalty/v3/stores/{store_id}/custom_actions`

## Request

- Base URL: `https://developers.yotpo.com`
- URL: `https://developers.yotpo.com/loyalty/v3/stores/{store_id}/custom_actions`
- Auth: API key in header `X-Yotpo-Token`

This endpoint records an action performed by a customer. It will apply the action to all active custom action campaigns and award the necessary points and/or discounts.

## Path parameters

- `store_id` string, required

## Request body

- object
  - `custom_actions` object, required: The action the customer performed.
    - `type` string, required: The type of action. Almost always set this to `CustomAction`
    - `customer_email` string, required: The email address used to identify the customer who performed the action. Required if no customer_id is passed.
    - `customer_id` string: The unique identifier of the customer who performed the action in your system. Required if no customer_email is passed.
    - `action_name` string, required: The name of the action that was performed. This must match the name set for one of your Custom Action Campaigns.
    - `ip_address` string: The ip address of the user when the action was performed. This is required if this action completes a referral program requirement.
    - `user_agent` string: The browser user agent of the user when the action was performed. This is strongly recommended if this action completes a referral program requirements.
    - `created_at` string: The time the action was performed. This will default to the current time. Use this if you need to back date an action.
    - `reward_points` integer: Use this to override the normal amount of points awarded for performing the action. Will default to the rules of the campaign otherwise.
    - `history_title` string: Use this to override the normal description shown to the user in their history. Will default to the campaign settings otherwise.

## Response `200`

200

- object

## Other responses

- `400`: 400
- `401`: Missing or invalid access token. Send a valid token in the `X-Yotpo-Token` header.
- `422`: The request was read but can't be applied, for example because `action_name` doesn't match a Custom Action campaign in the store.

## Changes

- **2026-11-03** `5bcae8239b6e`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/yotpo/apis/app-developer-api/changes/loyalty/v3/stores/:store_id/custom_actions/post.md)

---

[API](https://skmtc.dev/yotpo/apis/app-developer-api.md) - [All operations](https://skmtc.dev/yotpo/apis/app-developer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/yotpo/apis/app-developer-api/revisions/5bcae8239b6e?raw)
