---
title: "Get rewards and earnings in the back office"
---

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

# Get rewards and earnings in the back office

Path: Nicer API › backoffice

`GET /backoffice/rewards`

URL: `https://api.nicer.travel/backoffice/rewards`

Returns traveler rewards and every earning the platform has booked, over every date: each traveler's reward balance now, by agency and currency (at most 200, the most available first; an overdrawn bucket reads zero and its shortfall moves into receivable), and every earning ever booked by earning kind, beneficiary kind, status and currency, gross: reversals and clawbacks are not subtracted. Amounts are in each row's own currency, never converted. The agency is named by the x-nicer-company header and nothing else: with one named, that agency's ledger; with none, every agency's. Nicer staff only. Errors: 403 ERROR_DO_NOT_HAVE_PERMISSION for a caller who is not Nicer staff.

## Authentication

- `bearerAuth`, http bearer, header `Authorization`, format `JWT`

## Header parameters

- `x-nicer-company` (`backoffice.rewards.list.header.x-nicer-company`; string, optional) — Company context for an agency admin who belongs to several companies. Optional when the caller belongs to one.

## Code samples

### JavaScript SDK

```javascript
import { createClient } from "@nicertravel/sdk";

const nicer = createClient({
  baseUrl: "https://api.nicer.travel",
  token: process.env.NICER_TOKEN,
});

await nicer.backoffice.rewards.list();
```

### Nicer CLI

```bash
nicer backoffice rewards list
```

### cURL

```bash
curl --request GET \
  --url https://api.nicer.travel/backoffice/rewards \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://api.nicer.travel/backoffice/rewards';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.nicer.travel/backoffice/rewards"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

OK

#### Example

```json
{
  "balances": [
    {
      "availableMinor": 9007199254740991,
      "companyName": "string",
      "currency": "string",
      "pendingMinor": 9007199254740991,
      "receivableMinor": 9007199254740991,
      "travelerUserId": "string"
    }
  ],
  "earnings": [
    {
      "amountMinor": -9007199254740991,
      "beneficiaryKind": "ADVISOR",
      "currency": "string",
      "earningKind": "ADJUSTMENT",
      "entries": 9007199254740991,
      "status": "PENDING"
    }
  ]
}
```

- `balances` (`backoffice.rewards.list.response.200.balances`; array of object, required) — Traveler reward balances, the most available first. One row per agency, traveler and currency; at most 200.
  - `availableMinor` (`backoffice.rewards.list.response.200.balances.availableMinor`; integer, required) — The rewards available now, in minor units.
    - maximum: `9007199254740991` · minimum: `0`
  - `companyName` (`backoffice.rewards.list.response.200.balances.companyName`; string, required) — The agency whose ledger it is.
    - minLength: `1`
  - `currency` (`backoffice.rewards.list.response.200.balances.currency`; string, required) — The balance's currency.
    - pattern: `^[A-Z]{3}$`
  - `pendingMinor` (`backoffice.rewards.list.response.200.balances.pendingMinor`; integer, required) — The rewards earned but not available yet, in minor units.
    - maximum: `9007199254740991` · minimum: `0`
  - `receivableMinor` (`backoffice.rewards.list.response.200.balances.receivableMinor`; integer, required) — What the traveler owes back, in minor units, an overdrawn bucket included.
    - maximum: `9007199254740991` · minimum: `0`
  - `travelerUserId` (`backoffice.rewards.list.response.200.balances.travelerUserId`; string, required) — The traveler, as the ledger's beneficiary.
    - minLength: `1`
- `earnings` (`backoffice.rewards.list.response.200.earnings`; array of object, required) — Every earning ever booked, gross. One row per earning kind, beneficiary kind, status and currency, the largest amount first.
  - `amountMinor` (`backoffice.rewards.list.response.200.earnings.amountMinor`; integer, required) — The earnings' total, in minor units.
    - maximum: `9007199254740991` · minimum: `-9007199254740991`
  - `beneficiaryKind` (`backoffice.rewards.list.response.200.earnings.beneficiaryKind`; string, required) — Who earns: an advisor, the agency or a traveler.
    - one of `"ADVISOR"`, `"COMPANY"`, `"TRAVELER"`
  - `currency` (`backoffice.rewards.list.response.200.earnings.currency`; string, required) — The earnings' currency.
    - pattern: `^[A-Z]{3}$`
  - `earningKind` (`backoffice.rewards.list.response.200.earnings.earningKind`; string, required) — What the earnings are for.
    - one of `"ADJUSTMENT"`, `"ADVISOR_COMMISSION"`, `"AGENCY_COMMISSION"`, `"HOST_SHARE"`, `"PLANNING_FEE"`, `"REFERRAL_COMMISSION"`, `"TRAVELER_REWARD"`
  - `entries` (`backoffice.rewards.list.response.200.earnings.entries`; integer, required) — How many earnings.
    - maximum: `9007199254740991` · minimum: `0`
  - `status` (`backoffice.rewards.list.response.200.earnings.status`; string, required) — Whether the earnings are PENDING, AVAILABLE or REVERSED.
    - one of `"PENDING"`, `"AVAILABLE"`, `"REVERSED"`

### 400

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`backoffice.rewards.list.response.400.errorCode`; string, required)
- `errorMessage` (`backoffice.rewards.list.response.400.errorMessage`; string, required)

### 401

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`backoffice.rewards.list.response.401.errorCode`; string, required)
- `errorMessage` (`backoffice.rewards.list.response.401.errorMessage`; string, required)

### 403

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`backoffice.rewards.list.response.403.errorCode`; string, required)
- `errorMessage` (`backoffice.rewards.list.response.403.errorMessage`; string, required)


Source: https://docs.nicer.travel/api/backoffice/backoffice.rewards.list/index.md
