# Spoke Dispatch API Docs

> Learn how to integrate your systems with the Spoke Dispatch programmatic API

This index covers v1.0, the current version. Older versions are listed at the end.

- v1.0
  - API Reference: Every endpoint, request, and response.
    - [Spoke API](/api)
    - [v1 Migration Guide](/api/v1-migration-guide)
    - Using the API
      - [Using the API](/api/using-the-api)
      - [Address](/api/using-the-api/address)
      - [Authentication](/api/using-the-api/authentication)
      - [On resource types](/api/using-the-api/on-resource-types)
      - [On resource IDs](/api/using-the-api/on-resource-ids)
      - [On List endpoints](/api/using-the-api/on-list-endpoints)
      - [On Update endpoints (HTTP PATCH verb)](/api/using-the-api/on-update-endpoints-http-patch-verb)
      - [On Rate-Limiting](/api/using-the-api/on-rate-limiting)
      - [Stop Search API](/api/using-the-api/stop-search-api)
      - [On the models](/api/using-the-api/on-the-models)

    - **Endpoints**
    - Plans: Endpoints to operate on Plans resources.
      - [Plans](/api/plans)
      - [List plans](/api/plans/listPlans)
      - [Create a new plan](/api/plans/createPlan)
      - [Retrieve a plan](/api/plans/getPlan): Retrieve a plan
      - [Update an existing plan](/api/plans/updatePlan): Update an existing plan.
      - [Delete a plan](/api/plans/deletePlan): Delete a plan and related routes.
      - [Optimize a plan](/api/plans/optimizePlan): Optimize a plan.
      - [Distribute a plan](/api/plans/distributePlan): Distribute a plan to its drivers.
      - [List plan stops](/api/plans/listPlanStops)
    - Stops: Endpoints to operate on Stop resources.
      - [Stops](/api/stops)
      - [Create a new stop](/api/stops/createStop): Create a new stop with the given data.
      - [Batch import stops](/api/stops/importStops): Batch import stops.
      - [Retrieve a stop](/api/stops/getStop): Retrieve a stop
      - [Update an existing stop](/api/stops/updateStop): Does not support updating a stop's location, nor the clientId.
      - [Delete a stop](/api/stops/deleteStop): Delete a stop.
      - [Stop Search](/api/stops/searchStops): See the Stops Search docs for more information on formatting the filter string.
    - Unassigned Stops: Endpoints to operate on Unassigned Stop resources.
      - [Unassigned Stops](/api/unassigned-stops)
      - [Retrieve an unassigned stop](/api/unassigned-stops/getUnassignedStop): Retrieve an unassigned stop
      - [Update an existing unassigned stop](/api/unassigned-stops/updateUnassignedStop): Does not support updating a unassigned stop's location, nor the clientId.
      - [Delete an unassigned stop](/api/unassigned-stops/deleteUnassignedStop): Delete an unassigned stop.
      - [List unassigned stops](/api/unassigned-stops/listUnassignedStops)
      - [Create a new unassigned stop](/api/unassigned-stops/createUnassignedStop): Create a new unassigned stop with the given data.
      - [Batch import unassigned stops](/api/unassigned-stops/importUnassignedStops): Batch import unassigned stops.
    - Live Plans: Endpoints to operate on Plans resources when it's pending re-optimization and re-distribution.
      - [Live Plans](/api/live-plans)
      - [Re-optimize a plan](/api/live-plans/reoptimizePlan): Re-optimize a plan.
      - [Re-distribute a plan](/api/live-plans/redistributePlan): Re-distribute a plan to its drivers.
      - [Save the plan changes](/api/live-plans/savePlan): Save the plan changes after re-optimization without distributing it.
    - Live Stops: Endpoints to operate on Stop resources when the plan is already optimized and therefore not writable.
      - [Live Stops](/api/live-stops)
      - [Create a new stop](/api/live-stops/createLiveStop): Create a new stop with the given data on live plans.
      - [Update an existing stop](/api/live-stops/updateLiveStop): Update a stop on live plans.
      - [Batch import stops](/api/live-stops/importLiveStops): Import stops to live plans.
      - [Delete a stop](/api/live-stops/deleteLiveStop): Delete a stop on live plans.
    - Drivers: Endpoints to operate on Drivers resources.
      - [Drivers](/api/drivers)
      - [List Drivers](/api/drivers/listDrivers)
      - [Create a new driver](/api/drivers/createDriver): Create a driver with the given data in your team.
      - [Retrieve a driver](/api/drivers/getDriver)
      - [Update a driver](/api/drivers/updateDriver): Updates a driver from your team.
      - [Remove a driver](/api/drivers/deleteDriver): Removes a driver from your team.
      - [Batch import drivers](/api/drivers/importDrivers): Creates multiple drivers in your team.
    - Depots: Endpoints to operate on Depots resources.
      - [Depots](/api/depots)
      - [List Depots](/api/depots/listDepots)
      - [Create a depot](/api/depots/createDepot)
      - [Retrieve a depot](/api/depots/getDepot)
      - [Update a depot](/api/depots/updateDepot)
      - [Remove a depot](/api/depots/deleteDepot)
      - [Batch import depots](/api/depots/importDepots): Batch import depots.
      - [Set the main depot for the team](/api/depots/setMainDepot)
    - Routes: Endpoints to operate on Routes resources.
      - [Routes](/api/routes)
      - [Retrieve a route](/api/routes/getRoute)
      - [List Routes](/api/routes/listRoutes)
      - [List route stops](/api/routes/listRouteStops)
    - Operations: Endpoints to operate on Operations resources.
      - [Operations](/api/operations)
      - [Cancel an operation](/api/operations/cancelOperation): Cancel an operation that is not yet done.
      - [Retrieve an operation](/api/operations/getOperation)
      - [List operations](/api/operations/listOperations)
    - Team: Endpoints to retrieve Custom Stop Properties.
      - [Team](/api/team)
      - [List custom stop properties](/api/team/listCustomStopProperties): Returns a list of custom stop properties definitions.
      - [Retrieve a custom stop property](/api/team/getCustomStopProperty): Returns a custom stop property definition.
    - Members: Endpoints to operate on Members resources.
      - [Members](/api/members)
      - [Create a new member](/api/members/createMember): Create a member with the given data in your team.
      - [Update a member](/api/members/updateMember): Updates a member from your team.
      - [Remove a member](/api/members/deleteMember): Removes a member from your team.
      - [Import multiple members](/api/members/importMembers): Import multiple members at once.
  - API Usage Examples: Walkthroughs of common integration flows.
    - [API Usage Examples](/docs/api-examples)
    - [Build a delivery plan with the API](/docs/api-examples/dispatch-workflow): See how API v1 requests connect to build, optimize, and distribute a delivery plan.
    - [Adding multiple drivers to your team](/docs/api-examples/import-drivers)
    - [Creating a Plan and importing Stops](/docs/api-examples/create-import-plan-stops)
    - [Create a Plan with Drivers](/docs/api-examples/create-plan-with-drivers)
    - [Create a Plan for a Depot](/docs/api-examples/create-plan-with-depot)
    - [Optimize and distribute plan](/docs/api-examples/optimize-distribute-plan)
    - [Update Stops from a live Plan](/docs/api-examples/update-stops-from-live-plan)
    - [Create and delete Stops from a live Plan](/docs/api-examples/create-and-delete-stops-from-live-plan)
    - [Create unassigned stop with custom properties](/docs/api-examples/create-stops-with-custom-properties)
    - [Search for stops](/docs/api-examples/search-stops)
  - Webhooks: Notifications we send about your team's routes.
    - [Spoke Dispatch Webhook API](/docs/webhooks/webhook-api-intro)
    - Getting Started
      - [Getting started with the Spoke-webhook API](/docs/webhooks/enabling)
      - [Implementing the Endpoint](/docs/webhooks/getting-started/consuming-the-webhook-notifications)
      - [Securing the Endpoint](/docs/webhooks/getting-started/securing-the-endpoint)
      - [Best Practices](/docs/webhooks/getting-started/best-practices)
    - [Webhook Events](/docs/webhooks/webhook-events)
  - Models: What each resource and field means.
    - [Event Data](/docs/models): This section contains information on all of Spoke's API models.
    - [Models Descriptions](/docs/models/description): Description of each model
    - [Depot Schema](/docs/models/depot): Documentation of the Depot schema.
    - [Driver Schema](/docs/models/driver): Documentation of the Driver schema.
    - [Member Schema](/docs/models/member): Documentation of the Member schema.
    - [Plan Schema](/docs/models/plan): Documentation of the Plan schema.
    - [Operation Schema](/docs/models/operation): Documentation of the Operation schema.
    - [Route Schema](/docs/models/route): Documentation of the Route schema.
    - [Stop Schema](/docs/models/stop): Documentation of the Stop schema.
    - [Unassigned Stop Schema](/docs/models/unassignedStop): Documentation of the Unassigned Stop schema.
    - [Custom Stop Property Schema](/docs/models/customStopProperty): Documentation of the Custom Stop Property schema.
- About the API: Versioning policy and changelog.
  - [API Versioning](/versioning)
  - [API Changelog](/changelog)

## When to use

The Dispatch API is how a delivery team works with Spoke Dispatch programmatically: create and import plans and stops, add drivers and depots, optimize and distribute routes, follow live plans as drivers work through them, and receive webhook events as stops progress.

Call it over HTTPS at `https://api.spoke.com/public/v1` with an API key as HTTP Basic credentials ([Authentication](/api/using-the-api/authentication)). Spoke has no SDKs: call the endpoints directly or generate a client from the OpenAPI spec.

## OpenAPI and MCP

- [OpenAPI spec (v1)](/openapi-v1.json)
- [OpenAPI spec (v0.2b)](/openapi-v0.2b.json)
- [MCP server](/mcp): search and read these docs over MCP (streamable HTTP).

## Older versions

Still documented, no longer actively maintained:

- v0.2b: [API reference](/api/v0.2b), [webhooks](/docs/v0.2b/webhooks/webhook-api-intro)
- v0.1b: [API reference](/api/v0.1b), [webhooks](/docs/v0.1b/webhooks/webhook-api-intro)
