---
title: "Get an import of bookings"
---

> 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 an import of bookings

Path: Nicer API › Commerce

`GET /commerce/commission-imports/{importId}`

URL: `https://api.nicer.travel/commerce/commission-imports/{importId}`

An import with a page of its rows (50 by default, at most 200, in file order; `status` keeps one kind of row): the cells as read (cleared once the import is committed), the values the mapping makes of them, and why a row is invalid or a duplicate. An advisor gets their own imports only, and of the emails mapped to members (`advisors`) only those mapped to them. Another company's import answers 404.

## Authentication

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

## Path parameters

- `importId` (`commerce.commissionImports.get.path.importId`; string, required)

## Query parameters

- `cursor` (`commerce.commissionImports.get.query.cursor`; string, optional)
  - maxLength: `2048` · minLength: `1`
- `limit` (`commerce.commissionImports.get.query.limit`; integer, optional)
  - maximum: `200` · minimum: `1`
- `status` (`commerce.commissionImports.get.query.status`; string, optional)
  - one of `"VALID"`, `"INVALID"`, `"DUPLICATE"`, `"COMMITTED"`, `"SKIPPED"`

## Header parameters

- `x-nicer-company` (`commerce.commissionImports.get.header.x-nicer-company`; string, required) — Company context. Authentication and tenant membership are validated by the API.

## Code samples

### JavaScript SDK

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

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

await nicer.commerce.commissionImports.get({
  "importId": "string"
});
```

### Nicer CLI

```bash
nicer commerce commission-imports get --import-id 'string' --company "$NICER_COMPANY"
```

### cURL

```bash
curl --request GET \
  --url 'https://api.nicer.travel/commerce/commission-imports/<importId>' \
  --header 'Authorization: Bearer <token>' \
  --header 'x-nicer-company: string'
```

### TypeScript

```typescript
const url = 'https://api.nicer.travel/commerce/commission-imports/<importId>';
const options = {
  method: 'GET',
  headers: {'x-nicer-company': 'string', 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/commerce/commission-imports/<importId>"

headers = {
    "x-nicer-company": "string",
    "Authorization": "Bearer <token>"
}

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

print(response.text)
```

## Responses

### 200

OK

#### Example

```json
{
  "import": {
    "committedAt": "2019-08-24T14:15:22Z",
    "companyName": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "createdByUserId": "string",
    "errorCode": "string",
    "fileName": "string",
    "format": "CSV",
    "headers": [
      "string"
    ],
    "jobId": "string",
    "presetId": "string",
    "sizeBytes": 9007199254740991,
    "source": "FILE_IMPORT",
    "status": "AWAITING_UPLOAD",
    "updatedAt": "2019-08-24T14:15:22Z",
    "advisorUserId": "string",
    "advisors": [
      {
        "email": "string",
        "userId": "string"
      }
    ],
    "counts": {
      "committed": 9007199254740991,
      "duplicate": 9007199254740991,
      "invalid": 9007199254740991,
      "rows": 9007199254740991,
      "valid": 9007199254740991
    },
    "importId": "string",
    "kind": "BOOKINGS",
    "mapping": {
      "columns": {
        "property1": "string",
        "property2": "string"
      },
      "defaults": {
        "property1": "string",
        "property2": "string"
      },
      "dateFormat": "ISO",
      "decimalSeparator": ".",
      "headerRow": 1,
      "sheet": "string"
    }
  },
  "nextCursor": "string",
  "rows": [
    {
      "cells": {
        "property1": "string",
        "property2": "string"
      },
      "commissionItemId": "string",
      "errors": [
        {
          "code": "REQUIRED",
          "field": "bookedOn"
        }
      ],
      "externalBookingId": "string",
      "rowNumber": 9007199254740991,
      "status": "VALID",
      "values": {
        "bookedOn": "2019-08-24",
        "category": "HOTEL",
        "clientName": "string",
        "commissionMinor": 9007199254740991,
        "confirmationNumber": "string",
        "currency": "string",
        "dueOn": "2019-08-24",
        "externalReference": "string",
        "grossMinor": 9007199254740991,
        "identifierNumber": "string",
        "kind": "SUPPLIER_COMMISSION",
        "note": "string",
        "paymentTermDays": 9007199254740991,
        "providerLocator": "string",
        "quantity": 9007199254740991,
        "rateBps": 10000,
        "supplierName": "string",
        "tags": [
          "string"
        ],
        "travelEnd": "2019-08-24",
        "travelStart": "2019-08-24",
        "advisorEmail": "string"
      }
    }
  ]
}
```

- `import` (`commerce.commissionImports.get.response.200.import`; object, required)
  - `committedAt` (`commerce.commissionImports.get.response.200.import.committedAt`; any of, required)
    - any of the following: `string`, `null`
  - `companyName` (`commerce.commissionImports.get.response.200.import.companyName`; string, required)
    - minLength: `1`
  - `createdAt` (`commerce.commissionImports.get.response.200.import.createdAt`; string, required)
    - format: `date-time` · pattern: `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$`
  - `createdByUserId` (`commerce.commissionImports.get.response.200.import.createdByUserId`; string, required)
    - minLength: `1`
  - `errorCode` (`commerce.commissionImports.get.response.200.import.errorCode`; any of, required)
    - any of the following: `string`, `null`
  - `fileName` (`commerce.commissionImports.get.response.200.import.fileName`; string, required)
    - minLength: `1`
  - `format` (`commerce.commissionImports.get.response.200.import.format`; string, required)
    - one of `"CSV"`, `"TSV"`, `"TXT"`, `"XLSX"`
  - `headers` (`commerce.commissionImports.get.response.200.import.headers`; array of string, required)
  - `jobId` (`commerce.commissionImports.get.response.200.import.jobId`; any of, required)
    - any of the following: `string`, `null`
  - `presetId` (`commerce.commissionImports.get.response.200.import.presetId`; any of, required)
    - any of the following: `string`, `null`
  - `sizeBytes` (`commerce.commissionImports.get.response.200.import.sizeBytes`; integer, required)
    - maximum: `9007199254740991`
  - `source` (`commerce.commissionImports.get.response.200.import.source`; string, required)
    - one of `"FILE_IMPORT"`
  - `status` (`commerce.commissionImports.get.response.200.import.status`; string, required)
    - one of `"AWAITING_UPLOAD"`, `"UPLOADED"`, `"PARSING"`, `"READY"`, `"COMMITTING"`, `"COMMITTED"`, `"UNDONE"`, `"DISCARDED"`, `"FAILED"`
  - `updatedAt` (`commerce.commissionImports.get.response.200.import.updatedAt`; string, required)
    - format: `date-time` · pattern: `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$`
  - `advisorUserId` (`commerce.commissionImports.get.response.200.import.advisorUserId`; any of, required)
    - any of the following: `string`, `null`
  - `advisors` (`commerce.commissionImports.get.response.200.import.advisors`; array of object, required)
    - `email` (`commerce.commissionImports.get.response.200.import.advisors.email`; string, required)
      - maxLength: `254` · pattern: `^[^\s@A-Z]+@[^\s@A-Z]+$`
    - `userId` (`commerce.commissionImports.get.response.200.import.advisors.userId`; string, required)
      - maxLength: `255` · minLength: `1`
  - `counts` (`commerce.commissionImports.get.response.200.import.counts`; object, required)
    - `committed` (`commerce.commissionImports.get.response.200.import.counts.committed`; integer, required)
      - maximum: `9007199254740991` · minimum: `0`
    - `duplicate` (`commerce.commissionImports.get.response.200.import.counts.duplicate`; integer, required)
      - maximum: `9007199254740991` · minimum: `0`
    - `invalid` (`commerce.commissionImports.get.response.200.import.counts.invalid`; integer, required)
      - maximum: `9007199254740991` · minimum: `0`
    - `rows` (`commerce.commissionImports.get.response.200.import.counts.rows`; integer, required)
      - maximum: `9007199254740991` · minimum: `0`
    - `valid` (`commerce.commissionImports.get.response.200.import.counts.valid`; integer, required)
      - maximum: `9007199254740991` · minimum: `0`
  - `importId` (`commerce.commissionImports.get.response.200.import.importId`; string, required)
    - minLength: `1`
  - `kind` (`commerce.commissionImports.get.response.200.import.kind`; string, required)
    - one of `"BOOKINGS"`
  - `mapping` (`commerce.commissionImports.get.response.200.import.mapping`; any of, required)
    - any of the following:
      - `BookingImportMapping`
        - `columns` (`BookingImportMapping.columns`; map of string, required)
        - `defaults` (`BookingImportMapping.defaults`; map of string, required)
        - `dateFormat` (`BookingImportMapping.dateFormat`; string, required)
          - one of `"ISO"`, `"US"`, `"EU"`
        - `decimalSeparator` (`BookingImportMapping.decimalSeparator`; string, required)
          - one of `"."`, `","`
        - `headerRow` (`BookingImportMapping.headerRow`; integer, required)
          - maximum: `50` · minimum: `1`
        - `sheet` (`BookingImportMapping.sheet`; any of, required)
          - any of the following: `string`, `null`
      - `null`
- `nextCursor` (`commerce.commissionImports.get.response.200.nextCursor`; any of, required)
  - any of the following: `string`, `null`
- `rows` (`commerce.commissionImports.get.response.200.rows`; array of object, required)
  - `cells` (`commerce.commissionImports.get.response.200.rows.cells`; map of string, required)
  - `commissionItemId` (`commerce.commissionImports.get.response.200.rows.commissionItemId`; any of, required)
    - any of the following: `string`, `null`
  - `errors` (`commerce.commissionImports.get.response.200.rows.errors`; array of object, required)
    - `code` (`commerce.commissionImports.get.response.200.rows.errors.code`; string, required)
      - one of `"REQUIRED"`, `"INVALID_DATE"`, `"INVALID_AMOUNT"`, `"INVALID_RATE"`, `"INVALID_VALUE"`, `"TRAVEL_END_BEFORE_START"`, `"NO_COMMISSION"`, `"UNKNOWN_IDENTIFIER"`, `"UNKNOWN_ADVISOR"`
    - `field` (`commerce.commissionImports.get.response.200.rows.errors.field`; string, required)
      - one of `"bookedOn"`, `"category"`, `"clientName"`, `"commission"`, `"confirmationNumber"`, `"currency"`, `"dueOn"`, `"externalReference"`, `"gross"`, `"identifierNumber"`, `"kind"`, `"note"`, `"paymentTermDays"`, `"providerLocator"`, `"quantity"`, `"rate"`, `"supplierName"`, `"tags"`, `"travelEnd"`, `"travelStart"`, `"advisorEmail"`
  - `externalBookingId` (`commerce.commissionImports.get.response.200.rows.externalBookingId`; any of, required)
    - any of the following: `string`, `null`
  - `rowNumber` (`commerce.commissionImports.get.response.200.rows.rowNumber`; integer, required)
    - maximum: `9007199254740991`
  - `status` (`commerce.commissionImports.get.response.200.rows.status`; string, required)
    - one of `"VALID"`, `"INVALID"`, `"DUPLICATE"`, `"COMMITTED"`, `"SKIPPED"`
  - `values` (`commerce.commissionImports.get.response.200.rows.values`; any of, required)
    - any of the following:
      - `ImportRowValues`
        - `bookedOn` (`ImportRowValues.bookedOn`; any of, required)
          - any of the following: `string`, `null`
        - `category` (`ImportRowValues.category`; string, required)
          - one of `"HOTEL"`, `"CRUISE"`, `"TOUR"`, `"DMC"`, `"FLIGHT"`, `"CAR_RENTAL"`, `"RAIL"`, `"INSURANCE"`, `"TRANSFER"`, `"CONCIERGE"`, `"FEE"`, `"OTHER"`
        - `clientName` (`ImportRowValues.clientName`; string, required)
          - minLength: `1`
        - `commissionMinor` (`ImportRowValues.commissionMinor`; any of, required)
          - any of the following: `integer`, `null`
        - `confirmationNumber` (`ImportRowValues.confirmationNumber`; any of, required)
          - any of the following: `string`, `null`
        - `currency` (`ImportRowValues.currency`; string, required)
          - pattern: `^[A-Z]{3}$`
        - `dueOn` (`ImportRowValues.dueOn`; any of, required)
          - any of the following: `string`, `null`
        - `externalReference` (`ImportRowValues.externalReference`; any of, required)
          - any of the following: `string`, `null`
        - `grossMinor` (`ImportRowValues.grossMinor`; any of, required)
          - any of the following: `integer`, `null`
        - `identifierNumber` (`ImportRowValues.identifierNumber`; any of, required)
          - any of the following: `string`, `null`
        - `kind` (`ImportRowValues.kind`; string, required)
          - one of `"SUPPLIER_COMMISSION"`, `"CLIENT_NET_MARKUP"`, `"CLIENT_FEE"`
        - `note` (`ImportRowValues.note`; any of, required)
          - any of the following: `string`, `null`
        - `paymentTermDays` (`ImportRowValues.paymentTermDays`; any of, required)
          - any of the following: `integer`, `null`
        - `providerLocator` (`ImportRowValues.providerLocator`; any of, required)
          - any of the following: `string`, `null`
        - `quantity` (`ImportRowValues.quantity`; integer, required)
          - maximum: `9007199254740991`
        - `rateBps` (`ImportRowValues.rateBps`; any of, required)
          - any of the following: `integer`, `null`
        - `supplierName` (`ImportRowValues.supplierName`; string, required)
          - minLength: `1`
        - `tags` (`ImportRowValues.tags`; array of string, required)
          - minLength: `1`
        - `travelEnd` (`ImportRowValues.travelEnd`; string, required)
          - format: `date` · pattern: `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$`
        - `travelStart` (`ImportRowValues.travelStart`; string, required)
          - format: `date` · pattern: `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$`
        - `advisorEmail` (`ImportRowValues.advisorEmail`; string, optional)
          - maxLength: `254` · pattern: `^[^\s@A-Z]+@[^\s@A-Z]+$`
      - `null`

### 400

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

#### Example

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

- `errorCode` (`commerce.commissionImports.get.response.400.errorCode`; string, required)
- `errorMessage` (`commerce.commissionImports.get.response.400.errorMessage`; string, required)

### 401

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

#### Example

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

- `errorCode` (`commerce.commissionImports.get.response.401.errorCode`; string, required)
- `errorMessage` (`commerce.commissionImports.get.response.401.errorMessage`; string, required)

### 403

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

#### Example

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

- `errorCode` (`commerce.commissionImports.get.response.403.errorCode`; string, required)
- `errorMessage` (`commerce.commissionImports.get.response.403.errorMessage`; string, required)


Source: https://docs.nicer.travel/api/Commerce/commerce.commissionImports.get/index.md
