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

# App rewards

> Pilot guide: connect your app to a business's rewards program, report activity and display gifts.

Connect your app to a business's rewards program. You report confirmed member
activity from your backend; Hydra records points, checks campaign goals and awards
the configured retailer gift. You display progress and gifts in your app, where
members can find the details they need to redeem at the retailer.

Follow the steps below to connect one business's program with automatic rewards
and no points deduction.

> [!WARNING]
>
> **Pilot guide.** Confirm your API access, base URL and test environment with us
> before making calls.

## Build your integration

1. [Set up access and actions](https://docs.usehydra.co.za/integrations/app-rewards/setup.md): agree the program,
   store your credential and map the merchant's actions.
2. [Link members](https://docs.usehydra.co.za/integrations/app-rewards/members.md): capture consent and save each
   account's Hydra member ID.
3. [Report activities](https://docs.usehydra.co.za/integrations/app-rewards/activities.md): submit confirmed events
   and retry them safely.
4. [Display progress and gifts](https://docs.usehydra.co.za/integrations/app-rewards/rewards.md): show campaign
   progress, gift status and voucher details.
5. [Handle support and recovery](https://docs.usehydra.co.za/integrations/app-rewards/support.md): manage delayed
   gifts, account changes and credential renewal.
6. [Test your integration](https://docs.usehydra.co.za/integrations/app-rewards/testing.md): run the pilot checks
   with us and prepare for live use.

## How it works

```mermaid theme={null}
flowchart TD
    A[Member accepts rewards consent] --> B[App links the member]
    B --> C[App confirms and reports an activity]
    C --> D[Hydra records fixed points and checks campaigns]
    D --> E[App displays current progress]
    D --> F{Campaign goal reached?}
    F -->|Yes, issuance can proceed| G[Hydra prepares the retailer gift]
    F -->|Yes, issuance is blocked| H[App shows delayed gift]
    H --> I[Hydra ops resolves the block and resumes saved work]
    I --> G
    G --> J[App displays confirmed saved voucher]
    J --> K[Member redeems at retailer]
    K --> L[App reads the recorded outcome]
```

## The five API operations

| Operation | When your backend calls it |
| - | - |
| `GET /v1/integration/actions` | Read the merchant's active action definitions and versions. |
| `POST /v1/integration/members` | Link a verified, consenting app account to a member. |
| `POST /v1/integration/activities` | Report one confirmed occurrence of a configured action. |
| `GET /v1/integration/members/{memberId}/rewards` | Read current business points, campaign progress and gift summaries. |
| `GET /v1/integration/rewards/{rewardId}` | Open an existing gift and its confirmed saved voucher details. |

## API limits

| If you need to… | What to expect |
| - | - |
| Choose or claim a gift in the app | Awards are automatic under the merchant's campaigns; there is no member claim or gift-choice operation here. |
| Award a different point amount for each order | Actions have configured fixed points. The activity request cannot supply a transaction amount or arbitrary points. |
| Spend/reverse points, undo an activity or import old events | These operations are outside this API. Agree appropriate support/event qualification rules before reporting; do not simulate a correction with another positive activity. |
| Create campaigns or change gift delivery from the integration | Configure campaigns in Hydra and contact us to change integration delivery. These five calls do not manage the program. |
| Receive Hydra event callbacks | No integration webhook is provided in this version. Use the bounded reads and agreed request budget. |
| Check whether a code will work at the till right now | Reads return saved evidence. The retailer validates redemption; the live exercise establishes the supported redemption procedure. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.