---
title: "List Routes"
method: GET
path: "/routes"
tags: ["Routes"]
---

# List Routes

`GET /routes`

## Request

- Base URL: `https://api.spoke.com/public/v1`
- URL: `https://api.spoke.com/public/v1/routes`
- Auth: HTTP basic
- TypeScript: <https://skmtc.dev/spoke/apis/spoke-api/docs/routes/get.ts> (a function with typed inputs; its response is checked against the schema)

## Query parameters

- `pageToken` string
- `maxPageSize` number
- `filter` object
  - `startsGte` string: Search for routes that start on or after this date, inclusive. The date must be in the format YYYY-MM-DD.
  - `startsLte` string: Search for routes that start on or before this date, inclusive. The date must be in the format YYYY-MM-DD.

## Response `200`

Success

- object: Success
  - `routes` RouteSchema[], required: The routes.
    - `id` string, required
    - `title` string, required: The title of the route.
    - `stopCount` number, required: The number of stops in the route.
    - `driver` string, required
    - `state` object, nullable, required: The state of a route.
      - `completed` boolean, required: Whether the route is completed.
      - `completedAt` number, nullable, required: The timestamp the route was completed at.
      - `distributed` boolean, required: Whether the route is distributed.
      - `distributedAt` number, nullable, required: The timestamp the route was distributed at.
      - `notifiedRecipients` boolean, required: Whether the recipients were notified.
      - `notifiedRecipientsAt` number, nullable, required: The timestamp the recipients were notified at.
      - `started` boolean, required: Whether the route is started.
      - `startedAt` number, nullable, required: The timestamp the route was started at.
    - `plan` string, required
  - `nextPageToken` string, nullable, required: The next page token.

## Other responses

- `400`: Query parameters are invalid
- `401`: Unauthorized
- `500`: An internal server error occurred
- `default`: The default error model

---

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