Get Rewards for User as Report
Deprecated: This endpoint is deprecated. Use the current rewards reporting endpoints for new integrations.
This endpoint retrieves rewards earned by the authenticated user, returned as a file content object suitable for download or export. The response includes the report file name, its raw content, and the content type. An optional reporting period filter allows scoping the report to a specific period.
Endpoint
GET /api/UsersReward/report
Authentication
Bearer token required. Obtain via:
POST https://api.banking.netevia.dev/api/auth/v2
Include in header: Authorization: Bearer {token}
Token lifetime: 10 minutes. Refresh via POST /api/auth/refresh.
When to use
Use this endpoint when you need to export a user's rewards history as a report file for a given period. This is useful for auditing, reconciliation, or providing customers with a downloadable summary of their rewards activity. Because this endpoint is deprecated, evaluate migrating to the current rewards reporting solution before building new integrations against it.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| reportPeriodId | integer (int32) | No | The identifier of the reporting period to scope the rewards report. If omitted, the report may cover all available periods. |
Response
200 OK
| Field | Type | Description |
|---|---|---|
| name | string (nullable) | The file name of the generated report (e.g., rewards-report-2024-Q1.csv). |
| content | string (nullable) | The raw file content, typically base64-encoded or plain text depending on the report format. |
| contentType | string (nullable) | The MIME type of the file content (e.g., text/csv, application/pdf). |
{
"name": "rewards-report-period-5.csv",
"content": "UGVyaW9kLFJld2FyZFR5cGUsTWVyY2hhbnQsUG9pbnRzLERhdGUKUTEsMjAyNCxDYXNoYmFjayxBbWF6b24sMTUwLDIwMjQtMDEtMTU=",
"contentType": "text/csv"
}Error Codes
| Code | When it happens |
|---|---|
| 400 | Invalid reportPeriodId value (e.g., non-integer or out-of-range value) |
| 401 | Token missing, expired, or invalid |
| 403 | Insufficient permissions to access rewards report data |
| 404 | No report found for the specified reportPeriodId |
| 500 | Internal server error |
Common Mistakes
- Passing a non-integer value for
reportPeriodIdwill result in a 400 error; ensure you supply a valid int32. - This endpoint is marked as deprecated. Do not build new features against it; migrate to the current rewards reporting endpoint instead.
- The
contentfield may be base64-encoded depending on the report format — decode it appropriately before displaying or saving the file. - Omitting
reportPeriodIdmay return a report spanning all periods; always specify the period if you need scoped data.
Related Endpoints
GET /api/UsersReward— Retrieve rewards for a user as structured JSON dataGET /api/UsersReward/{profileId}— Retrieve rewards for a specific user profilePOST /api/auth/v2— Obtain a Bearer token for authentication
Example
curl -X GET "https://api.banking.netevia.dev/api/UsersReward/report?reportPeriodId=5" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Accept: application/json"