> ## Documentation Index
> Fetch the complete documentation index at: https://learn.nexudus.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Bookings During Pause Period

# Get Bookings During Pause Period

Returns a summary of the customer's bookings that fall within a proposed pause period. Use this endpoint in the pause flow to warn the customer about any existing bookings that will be affected — specifically those that have not yet been charged, invoiced, or paid.

## Authentication

This endpoint requires an authenticated customer session.

## Query Parameters

<ParamField query="start" type="string" required>
  ISO 8601 datetime string for the start of the proposed pause period. This is typically the earliest pause date returned by the pause metadata
  endpoint.
</ParamField>

<ParamField query="end" type="string" required>
  ISO 8601 datetime string for the end of the proposed pause period. This is computed from the selected number of pause cycles.
</ParamField>

## Response

Returns a `PauseBooking` object summarising booking counts within the date range.

<ResponseField name="Total" type="number">
  Total number of bookings within the proposed pause period.
</ResponseField>

<ResponseField name="NotCharged" type="number">
  Number of bookings that have not yet been charged.
</ResponseField>

<ResponseField name="NotInvoiced" type="number">
  Number of bookings that have not yet been invoiced.
</ResponseField>

<ResponseField name="NotPaid" type="number">
  Number of bookings whose invoices have not yet been paid.
</ResponseField>

## Example Response

```json theme={null}
{
  "Total": 3,
  "NotCharged": 1,
  "NotInvoiced": 2,
  "NotPaid": 3
}
```

## Usage in Portal

Called inside the pause modal each time the customer changes the number of pause cycles, so the warning counts stay in sync with the selected date range.

* File: `src/views/user/plans/components/PauseContractModal.tsx`

### Typical integration pattern

```ts theme={null}
// From src/api/endpoints.ts
// endpoints.billing.contracts.pauseBookings = (start: string, end: string) => ({
//   url: `/api/public/billing/coworkerContracts/pause/bookings?start=${start}&end=${end}`,
//   type: null as unknown as PauseBooking,
// })

// Usage in React (recalculated on every cycle selection change)
const endDate = earliestPauseDate.plus({ months: selectedCycles })
const bookingsEndpoint = endpoints.billing.contracts.pauseBookings(earliestPauseDateISO, endDate.toUTC().toISO() ?? earliestPauseDateISO)
const { resource: bookings } = useData<typeof bookingsEndpoint.type>(httpClient, bookingsEndpoint.url)
```

## Related Endpoints

* `GET /api/public/billing/coworkerContracts/{contractId}/pause/meta` – Get pause eligibility and available date options
* `PUT /api/public/billing/coworkerContracts/v2/{contractId}/pause` – Submit the pause request

## Error Responses

<ResponseField name="401 Unauthorized" type="error">
  The current user is not authenticated.
</ResponseField>

<ResponseField name="400 Bad Request" type="error">
  Missing or invalid `start`/`end` parameters.
</ResponseField>
