---
title: "Earn Reward"
method: POST
path: "/api/gamification/rewards/earn"
tags: ["gamification"]
---

# Earn Reward

`POST /api/gamification/rewards/earn`

Award tokens to the user for completing a reward source.

- **reward_key**: The reward key identifier (e.g., 'quest_daily_reading', 'achievement_bible_read_10')

This endpoint is called when a user completes a quest, achievement, daily login, etc.
The token amount is determined by the reward configuration in the database.

## Headers

- `x-user-id` string, nullable

## Request body

- EarnRewardRequest — Request to earn tokens from a reward.
  - `reward_key` string, required — The reward key to earn tokens from (e.g., 'quest_daily_reading')

## Response `200`

Successful Response

- EarnTokensResponse — Response for earning tokens.
  - `success` boolean, required
  - `message` string, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/usecreed/apis/creed-api.md) · [All operations](https://skmtc.net/usecreed/apis/creed-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/usecreed/creed-api/versions/523833f9e819/schema)
