---
title: "Create a tracked purchase link for a user"
method: POST
path: "/v1/cashback/activate"
tags: ["Cashback"]
---

# Create a tracked purchase link for a user

`POST /v1/cashback/activate`

## Request

- Base URL: `https://api.openstock.sh`
- URL: `https://api.openstock.sh/v1/cashback/activate`
- Auth: HTTP bearer

Use the live savings result’s id as store_id, and its program_id. The user ID belongs to your partner account; API key rotation keeps the same wallet. Retry with the same idempotency_key and identical purchase context. Follow the returned URL and complete checkout in the same browser context. Following the URL alone never credits money. Rates and eligibility are rechecked when activating.

## Request body

- CashbackActivationRequest
  - `store_id` string, required
  - `program_id` string, required
  - `user_id` string, required: Opaque user ID within your authenticated partner account. Do not send email addresses.
  - `country` string, required
  - `destination_url` string, uri
  - `idempotency_key` string, required

## Response `200`

Durably recorded click and real affiliate URL.

- CashbackActivationResponse
  - `click_id` string, required
  - `url` string, uri, required
  - `cashback` object, required
    - `type` 'percentage' | 'fixed', required
    - `value` number, required
    - `currency` string
    - `source` 'network' | 'example', required
    - `basis` 'up_to' | 'fixed' | 'example', required
  - `terms` string[], required
  - `commission_share` 1, required

## Other responses

- `400`: The request could not be completed. Retry temporary failures with the same idempotency key.
- `401`: The request could not be completed. Retry temporary failures with the same idempotency key.
- `403`: The request could not be completed. Retry temporary failures with the same idempotency key.
- `409`: The request could not be completed. Retry temporary failures with the same idempotency key.
- `503`: The request could not be completed. Retry temporary failures with the same idempotency key.

## Changes

- **2026-11-02** `e3af2bb31234`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/openstock/apis/openstock-api/changes/v1/cashback/activate/post.md)

---

[API](https://skmtc.dev/openstock/apis/openstock-api.md) - [All operations](https://skmtc.dev/openstock/apis/openstock-api/llms.txt) - [OpenAPI document](https://skmtc.dev/openstock/apis/openstock-api/revisions/e3af2bb31234?raw)
