Get all user rewards by projectId
GET/userRewards/by/project/:projectId
Get all user rewards by projectId
Request
Path Parameters
The unique identifier for the project
Query Parameters
Possible values: [pending
, redeemed
, cancelled
]
The state to filter by
Search by start date since claimedAt
Search by end date until claimedAt
Possible values: >= 1
Default value: 1
Specify the page number for pagination (default is 1).
Default value: 10
Specify the number of projects per page (default is 10, 0 gets all results).
Possible values: [createdAt
, claimedAt
]
Field to order the results by (e.g., 'createdAt', 'numMonthlyUsers'). Default is 'createdAt'.
Possible values: [asc
, desc
]
Default value: desc
'asc' for ascending or 'desc' for descending order. Default is 'desc'.
Responses
- 200
- 403
- 404
- 500
UserRewards retrieved successfully
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
Possible values: [pending
, redeemed
, cancelled
]
Unique identifier for UserReward
[
{
"userId": "83688660-e49e-4b3c-9ad2-22fa1ee69288",
"id": "URdef4567",
"rewardId": "r135HCrJs",
"status": "redeemed",
"createdAt": "2024-10-30T12:00:00Z"
},
{
"userId": "83688660-e49e-4b3c-9ad2-22fa1ee69288",
"id": "UR0123abc",
"status": "redeemed",
"rewardId": "rJLy6qcRz",
"createdAt": "2024-10-29T09:30:00Z"
}
]
Forbidden
- application/json
- Schema
- Example (from schema)
- Example
Schema
{
"error": "string"
}
{
"error": "Forbidden access"
}
NotFound
- application/json
- Schema
- Example (from schema)
- Example
Schema
{
"error": "string"
}
{
"error": "A mandatory item was not found"
}
Internal Server Error
- application/json
- Schema
- Example (from schema)
- Example
Schema
{
"error": "string"
}
{
"error": "Internal Server Error"
}