# `PolarExpress.Services.OrdersService`
[🔗](https://github.com/jeffhuen/polar_express/blob/main/lib/polar_express/services/orders_service.ex#L2)

Orders

Orders API operations.

# `export_orders`

```elixir
@spec export_orders(PolarExpress.Client.t(), map(), keyword()) ::
  {:ok, term()} | {:error, PolarExpress.Error.t()}
```

Export Orders

Export orders as a CSV file.

**Scopes**: `orders:read`

See `PolarExpress.Params.OrdersExportOrdersParams` for parameter details.

# `generate_order_invoice`

```elixir
@spec generate_order_invoice(PolarExpress.Client.t(), String.t(), map(), keyword()) ::
  {:ok, term()} | {:error, PolarExpress.Error.t()}
```

Generate Order Invoice

Trigger generation of an order's invoice.

**Scopes**: `orders:read`

See `PolarExpress.Params.OrdersGenerateOrderInvoiceParams` for parameter details.

# `get_order`

```elixir
@spec get_order(PolarExpress.Client.t(), String.t(), map(), keyword()) ::
  {:ok, PolarExpress.Schemas.Order.t()} | {:error, PolarExpress.Error.t()}
```

Get Order

Get an order by ID.

**Scopes**: `orders:read`

See `PolarExpress.Params.OrdersGetOrderParams` for parameter details.

# `get_order_invoice`

```elixir
@spec get_order_invoice(PolarExpress.Client.t(), String.t(), map(), keyword()) ::
  {:ok, PolarExpress.Schemas.OrderInvoice.t()}
  | {:error, PolarExpress.Error.t()}
```

Get Order Invoice

Get an order's invoice data.

**Scopes**: `orders:read`

See `PolarExpress.Params.OrdersGetOrderInvoiceParams` for parameter details.

# `list_orders`

```elixir
@spec list_orders(PolarExpress.Client.t(), map(), keyword()) ::
  {:ok, PolarExpress.ListObject.t()} | {:error, PolarExpress.Error.t()}
```

List Orders

List orders.

**Scopes**: `orders:read`

See `PolarExpress.Params.OrdersListOrdersParams` for parameter details.

# `update_order`

```elixir
@spec update_order(PolarExpress.Client.t(), String.t(), map(), keyword()) ::
  {:ok, PolarExpress.Schemas.Order.t()} | {:error, PolarExpress.Error.t()}
```

Update Order

Update an order.

**Scopes**: `orders:write`

See `PolarExpress.Params.OrdersUpdateOrderParams` for parameter details.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
