---
title: "Retrieve a paginated list of guests"
method: GET
path: "/api/v1/restaurants/{restaurant_id}/guests"
tags: ["Guest"]
---

# Retrieve a paginated list of guests

`GET /api/v1/restaurants/{restaurant_id}/guests`

## Request

- Base URL: `https://gotable.app`
- URL: `https://gotable.app/api/v1/restaurants/{restaurant_id}/guests`
- Auth: HTTP bearer

## Path parameters

- `restaurant_id` integer, required

## Query parameters

- `page` integer
- `per_page` integer
- `query` string

## Response `200`

With a valid API token

- object
  - `guests` Guest[]
    - `id` integer: The unique ID of the guest
    - `restaurant_id` integer: The unique ID of the restaurant
    - `name` string, nullable: Guest's name
    - `email` string, nullable: Guest's email address
    - `subscribed` boolean: If the guest has subscribed to the newsletter
    - `telephone` string, nullable: Guest's telephone number
    - `visits` integer: Guest's number of visits
    - `reservations` integer: Guest's number of reservations
    - `last_visit` string, date, nullable: The date of the guest's last visit
    - `diets` string[]: Guest's diets
    - `allergies` string[]: Guest's allergies
    - `tags` string[]: Guest's generic tags
    - `links` Link[]: An array of links useful for this reservation
      - `href` string: The URL to the related resource.
      - `method` 'GET' | 'POST' | 'PUT' | 'DELETE': The HTTP method that should be used to follow the link.
      - `rel` string: The relationship of this link to the current resource.
  - `meta` Pagination
    - `current_page` integer
    - `per_page` integer
    - `total_pages` integer
    - `total_count` integer
    - `links` Link[]: An array of pagination links
      - `href` string: The URL to the related resource.
      - `method` 'GET' | 'POST' | 'PUT' | 'DELETE': The HTTP method that should be used to follow the link.
      - `rel` string: The relationship of this link to the current resource.

## Other responses

- `401`: With an invalid API token
- `403`: With an unauthorized API token
- `404`: With a non-existant Restaurant ID

---

[API](https://skmtc.dev/gotable/apis/gotable-api-v1.md) · [All operations](https://skmtc.dev/gotable/apis/gotable-api-v1/llms.txt) · [OpenAPI document](https://skmtc.dev/gotable/apis/gotable-api-v1/revisions/abe658488f5b?raw)
