# Get Line Items

Get all line items for an order.
**Resolving product names**
Line items contain product references but not human-readable names. To resolve the name, use the `product_type` and `details` fields to determine which endpoint to call.
**• `TICKET` and `TICKET_ADDON`:** Extract `experience_id` from `details`, call [Get ticket variants](/apis/experience/getticketvariantsforexperience), and match `product_id` to a ticket variant or add-on.
**• `GIFTCARD`:** Use `gift_card_id` from `details` to call [Get gift card by ID](/apis/gift-card/getgiftcardbyid).
**• `PRODUCT`:** Use `name` from `details`. It is the product's name at the time of sale, so a later rename in the catalogue does not change it.
A booking order can hold `PRODUCT` lines next to its tickets and add-ons. Every line is listed, so the line totals add up to the order total.

Endpoint: GET /v1/orders/{orderId}/line-items
Security: OAuth2

## Security:

  - `OAuth2` (unknown)
    oauth2 scopes: order.read

## Path parameters:

  - `orderId` (string, required)
    The unique identifier of the order.

## Response 200:

  - `200` (unknown)
    OK

## Response 200 fields (application/json):

  - `items` (array)

  - `items.quantity` (integer, required)
    The quantity of the line item.

  - `items.unit_price` (object, required)

  - `items.unit_price.currency` (string, required)
    The ISO 4217 currency code.
    Example: USD

  - `items.unit_price.value` (integer, required)
    The price in the smallest currency unit (e.g. cents for USD).
    Example: 2500

  - `items.unit_price.exponent` (integer, required)
    The number of decimal places for the currency.
    Example: 2

  - `items.discounts` (array)
    The discounts applied to the line item.

  - `items.discounts.type` (string, required)
    The type of discount.
    Enum: "DISCOUNT_CODE"

  - `items.discounts.code` (string, required)
    The discount code applied to the line item.

  - `items.product_type` (string, required)
    The type of product for a line item.
- `TICKET` — a ticket variant of an experience.
- `TICKET_ADDON` — an add-on attached to a ticket variant.
- `GIFTCARD` — a gift card purchase.
- `PRODUCT` — a product from the company's catalogue, such as a drink
or merchandise, sold together with a booking.
    Enum: "TICKET", "GIFTCARD", "TICKET_ADDON", "PRODUCT"

  - `items.product_id` (string, required)
    The unique identifier of the product. Maps to `ticket_variant.id` when product type is `TICKET`, `addon.id` when product type is `TICKET_ADDON`, a giftcard identifier when product type is `GIFTCARD`, or the catalogue item's identifier when product type is `PRODUCT`. Ticket variant and addon IDs can be found via the "Get ticket variants" endpoint.

  - `items.details` (any, required)
    Product-specific details based on the product type.

  - `items.details.type` (string, required)
    The type discriminator for ticket details.
    Enum: "TICKET"

  - `items.details.experience_id` (string, required)
    The unique identifier of the experience.

  - `items.details.type` (string, required)
    The type discriminator for giftcard details.
    Enum: "GIFTCARD"

  - `items.details.gift_card_id` (string, required)
    The unique identifier of the gift card.

  - `items.details.type` (string, required)
    The type discriminator for addon details.
    Enum: "ADDON"

  - `items.details.ticket_id` (string, required)
    The unique identifier of the ticket.

  - `items.details.type` (string, required)
    The type discriminator for product details.
    Enum: "PRODUCT"

  - `items.details.name` (string, required)
    The name of the product at the time of sale.
    Example: Water 50 cl

  - `items.details.catalogue_item_id` (string, required)
    The unique identifier of the item in the company's catalogue.

## Response 400:

  - `400` (unknown)
    Bad request.

## Response 400 fields (application/json):

  - `code` (string, required)
    Machine-readable error code. Each code always comes with the same HTTP status:
`BAD_REQUEST` (400), `UNAUTHORIZED` (401), `FORBIDDEN` (403), `NOT_FOUND` (404),
`CONFLICT` (409), `PRECONDITION_FAILED` (412), `TOO_MANY_REQUESTS` (429),
`INTERNAL_SERVER_ERROR` (500), `NOT_IMPLEMENTED` (501), `SERVICE_UNAVAILABLE` (503)
and `GATEWAY_TIMEOUT` (504).
The list is extensible: handle an unknown code by its HTTP status.
    Example: BAD_REQUEST

  - `message` (string, required)
    Human-readable description of the error, and how to resolve it where possible.

## Response 404:

  - `404` (unknown)
    Not found.

## Response 404 fields (application/json):

  - `code` (string, required)
    Machine-readable error code. Each code always comes with the same HTTP status:
`BAD_REQUEST` (400), `UNAUTHORIZED` (401), `FORBIDDEN` (403), `NOT_FOUND` (404),
`CONFLICT` (409), `PRECONDITION_FAILED` (412), `TOO_MANY_REQUESTS` (429),
`INTERNAL_SERVER_ERROR` (500), `NOT_IMPLEMENTED` (501), `SERVICE_UNAVAILABLE` (503)
and `GATEWAY_TIMEOUT` (504).
The list is extensible: handle an unknown code by its HTTP status.
    Example: BAD_REQUEST

  - `message` (string, required)
    Human-readable description of the error, and how to resolve it where possible.

## Response default:

  - `default` (unknown)
    Unexpected error.
This will be a 5XX status code.

## Response default fields (application/json):

  - `code` (string, required)
    Machine-readable error code. Each code always comes with the same HTTP status:
`BAD_REQUEST` (400), `UNAUTHORIZED` (401), `FORBIDDEN` (403), `NOT_FOUND` (404),
`CONFLICT` (409), `PRECONDITION_FAILED` (412), `TOO_MANY_REQUESTS` (429),
`INTERNAL_SERVER_ERROR` (500), `NOT_IMPLEMENTED` (501), `SERVICE_UNAVAILABLE` (503)
and `GATEWAY_TIMEOUT` (504).
The list is extensible: handle an unknown code by its HTTP status.
    Example: BAD_REQUEST

  - `message` (string, required)
    Human-readable description of the error, and how to resolve it where possible.

