---
title: "Stop Search"
method: GET
path: "/stops:search"
tags: ["Stops"]
---

# Stop Search

`GET /stops:search`

## Request

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

See the [Stops Search docs](/api/v1#section/Using-the-API/Stop-Search-API) for more information on formatting the filter string.
  The following fields are filterable:
  - `planId` - The ID of the plan stop is linked to in PlanId format (e.g. `plans/{planId}`)
  - `routeId` - The ID of the route stop is linked to in RouteId format (e.g. `routes/{routeId}`)
  - `type` - The type of the stop (e.g. `start`, `stop`, `end`)
  - `activity` - The activity performed at the stop (`delivery` or `pickup`)
  - `notes` - Notes associated with the stop
  - `orderInfo.sellerOrderId` - The order ID from the seller
  - `orderInfo.invoiceNumber` - The invoice number of the order
  - `orderInfo.sellerWebsite` - The website URL of the seller
  - `address.address` - The full address of the stop
  - `address.addressLineOne` - The first line of the stop address
  - `address.addressLineTwo` - The second line of the stop address
  - `address.latitude` - The latitude of the stop address in decimal degrees
  - `address.longitude` - The longitude of the stop address in decimal degrees
  - `address.placeId` - The Google Places identifier for the address
  - `address.countryCode` - The ISO country code for the address
  - `createdAt` - The timestamp when the stop was created (ISO 8601)
  - `arrivalAt` - The timestamp of the (estimated) arrival at the stop (ISO 8601)
  - `packageCount` - The number of packages to be delivered or picked up
  - `estimatedTravelDuration` - The estimated travel time to this stop from the previous one, in seconds
  - `estimatedTravelDistance` - The estimated travel distance to this stop from the previous one, in meters
  - `timing.estimatedAttemptDuration` - The estimated time spent at the stop to perform the activity, in seconds
  - `recipient.name` - The name of the recipient at the stop
  - `recipient.email` - The email address of the recipient
  - `recipient.phone` - The phone number of the recipient
  - `recipient.externalId` - An external identifier for the recipient
  - `deliveryInfo.state` - The current state of the delivery. See [DeliveryState](/docs/models/stop#deliverystate) for all supported values.
  - `deliveryInfo.attempted` - Whether a delivery attempt has been made
  - `deliveryInfo.succeeded` - Whether the delivery was successful
  - `deliveryInfo.recipientProvidedNotes` - Notes provided by the recipient for the driver
  - `deliveryInfo.driverProvidedInternalNotes` - Internal notes provided by the driver
  - `deliveryInfo.driverProvidedRecipientNotes` - Notes for the recipient provided by the driver
  - `deliveryInfo.signeeName` - The name of the person who signed for the delivery
  - `deliveryInfo.attemptedAt` - The timestamp when the delivery was attempted (ISO 8601)
  - `orderInfo.products` - The list of products included in the order
  - `orderInfo.sellerName` - The name of the seller
  - `paymentOnDelivery.amount` - The amount to be collected on delivery, in original units
  - `barcodes` - The list of barcodes associated with the stop
  - `packageLabel` - The label applied to the package(s)
  - `customProperties.*` - A custom property of the stop. Replace `*` with the custom property ID.

  The following fields are sortable:
  - `address.latitude`
  - `address.longitude`
  - `createdAt`
  - `arrivalAt`
  - `packageCount`
  - `estimatedTravelDuration`
  - `estimatedTravelDistance`
  - `timing.estimatedAttemptDuration`
  - `deliveryInfo.attemptedAt`
  - `paymentOnDelivery.amount`

## Query parameters

- `keyword` string
- `filter` string
- `pageToken` string
- `maxPageSize` integer
- `sortField` string
- `sortOrder` 'asc' | 'desc'

## Response `200`

Success

- object: Success
  - `stops` union[], required: The stops list.
    - union
      - object
        - `type` 'stop', required: The type of the stop.
        - `stop` StopSchema, required: A stop of a plan, can be related to a route.
          - `id` string, required
          - `address` object, required: The address of the stop.
            - `address` string, required: The address of the stop.
            - `addressLineOne` string, required: The first line of the address.
            - `addressLineTwo` string, required: The second line of the address.
            - `latitude` number, nullable, required: The latitude of the address in decimal degrees.
            - `longitude` number, nullable, required: The longitude of the address in decimal degrees.
            - `placeId` string, nullable, required: The identifier of the place corresponding to this stop on Google Places
            - `placeTypes` string[], required: Array of strings that is provided by the Google AutoCompleteAPI
          - `barcodes` string[], required: List of Barcode IDs associated with the stop.
          - `allowedDrivers` string[], required: The driver IDs that can be assigned to this stop
          - `estimatedTravelDuration` number, nullable, required: Estimated time that the driver will take to arrive at this stop from the previous stop in seconds.
          - `estimatedTravelDistance` number, nullable, required: The distance in meters between the previous stop and this stop.
          - `notes` string, nullable, required: Notes for the stop.
          - `packageCount` number, nullable, required: The number of packages.
          - `weight` object, nullable, required: Weight information for the stop.
            - `amount` number, required: The weight amount for this stop.
            - `unit` 'kilogram' | 'pound' | 'metric-ton', required: The weight unit in which the amount is specified (defined at team's capacity unit).
          - `type` 'start' | 'stop' | 'end', required: The type of the stop. `start` is the first stop of the route, `stop` is a stop in the middle of the route, and `end` is the last stop of the route.
          - `packageLabel` string, nullable, required: The label of the package.
          - `stopPosition` number, nullable, required: The position of the stop in the route.
          - `trackingLink` string, nullable, required: The recipient tracking link.
          - `webAppLink` string, required: The web app link.
          - `orderInfo` object, required: The order information of the stop.
            - `products` string[], required: The products of the stop.
            - `invoiceNumber` string, nullable, required: Invoice number associated with the order.
            - `sellerName` string, nullable, required: Name of the seller where the order is from.
            - `sellerOrderId` string, nullable, required: Id of the seller where the order is from.
            - `sellerWebsite` string, nullable, required: Website of the seller where the order is from.
          - `placeInVehicle` object, nullable, required: The position of the package in the vehicle.
            - `x` 'left' | 'right', nullable, required: The x position of the package.
            - `y` 'front' | 'back' | 'middle', nullable, required: The y position of the package.
            - `z` 'floor' | 'shelf', nullable, required: The z position of the package.
          - `recipient` object, required: The recipient of the stop.
            - `name` string, nullable, required: The name of the recipient.
            - `email` string, nullable, required: The email of the recipient.
            - `phone` string, nullable, required: The phone of the recipient.
            - `externalId` string, nullable, required: The external id of the recipient.
          - `activity` 'delivery' | 'pickup'
          - `deliveryInfo` object, nullable, required: The delivery information of the stop.
            - `attempted` boolean, required: Whether the stop was attempted.
            - `attemptedAt` number, nullable, required: When the stop was attempted in seconds since epoch.
            - `timeAtStopInfo` union, required
              - …
            - `attemptedLocation` object, nullable, required: A location.
              - …
            - `driverProvidedInternalNotes` string, nullable, required: Internal notes provided by the driver.
            - `driverProvidedRecipientNotes` string, nullable, required: Recipient notes provided by the driver.
            - `photoUrls` string[], required: URLs of proof of delivery photos.
            - `recipientProvidedNotes` string, nullable, required: Notes from recipient
            - `signatureUrl` string, nullable, required: URL of the signature.
            - `signeeName` string, nullable, required: Name of the signee.
            - `succeeded` boolean, required: Whether the stop was succeeded.
            - `state` 'delivered_to_recipient' | 'delivered_to_third_party' | 'delivered_to_mailbox' | 'delivered_to_safe_place' | 'delivered_to_pickup_point' | 'delivered_other' | 'picked_up_from_customer' | 'picked_up_unmanned' | 'picked_up_from_locker' | 'picked_up_other' | 'failed_not_home' | 'failed_cant_find_address' | 'failed_no_parking' | 'failed_no_time' | 'failed_package_not_available' | 'failed_other' | 'failed_missing_required_proof' | 'failed_payment_not_received' | 'unattempted', required: The state of the delivery.
          - `paymentOnDelivery` object, nullable, required: The payment due upon delivery also known as "Cash on Delivery".
            - `amount` integer, nullable, required: The amount *in minor units* (e.g. cents) to be collected upon delivery.
            - `currency` string, required: The payment's currency in ISO 4217 standard.
          - `proofOfAttemptRequirements` object, required: The proof of attempt requirements of the stop.
            - `enabled` boolean, nullable, required: Whether the proof of attempt is enabled.This only works if the team subscription has access to proof of delivery
          - `plan` string, required
          - `route` RouteSchema, required: A route.
            - `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.
              - …
            - `plan` string, required
          - `eta` union, required
            - object
              - …
            - object
              - …
            - object
              - …
          - `timing` object, required: The timing data of the stop.
            - `timeWindows` object[], required: Ordered arrival windows for this stop.
              - …
            - `estimatedAttemptDuration` number, nullable, required: Time that the driver estimates to spend on the stop to do his job (deliver a parcel, visit a client, etc) in seconds.
            - `earliestAttemptTime` TimeOfDaySchema, required: Time of day in hours and minutes. Uses a 24 hour clock.
              - …
            - `latestAttemptTime` TimeOfDaySchema, required: Time of day in hours and minutes. Uses a 24 hour clock.
              - …
          - `optimizationOrder` 'first' | 'last' | 'default'
          - `customProperties` object, nullable, required: Custom properties of the stop, can be used to store additional information.
          - `clientId` string, nullable, required: The associated Client ID of the Spoke Connect
          - `serviceInfo` union, required: Service offering data for this stop.
            - object
              - …
            - object
              - …
            - object
              - …
      - object
        - `type` 'unassignedStop', required: The type of the stop.
        - `unassignedStop` UnassignedStopSchema, required: An unassigned stop.
          - `id` string, required
          - `depot` string, required: The depot that this unassigned stop belongs to.
          - `address` object, required: The address of the stop.
            - `address` string, required: The address of the stop.
            - `addressLineOne` string, required: The first line of the address.
            - `addressLineTwo` string, required: The second line of the address.
            - `latitude` number, nullable, required: The latitude of the address in decimal degrees.
            - `longitude` number, nullable, required: The longitude of the address in decimal degrees.
            - `placeId` string, nullable, required: The identifier of the place corresponding to this stop on Google Places
            - `placeTypes` string[], required: Array of strings that is provided by the Google AutoCompleteAPI
          - `barcodes` string[], required: List of Barcode IDs associated with the stop.
          - `allowedDrivers` string[], required: The driver IDs that can be assigned to this stop.
          - `notes` string, nullable, required: Notes for the stop.
          - `packageCount` number, nullable, required: The number of packages.
          - `weight` object, nullable, required: Weight information for the stop.
            - `amount` number, required: The weight amount for this stop.
            - `unit` 'kilogram' | 'pound' | 'metric-ton', required: The weight unit in which the amount is specified (defined at team's capacity unit).
          - `orderInfo` object, required: The order information of the stop.
            - `products` string[], required: The products of the stop.
            - `invoiceNumber` string, nullable, required: Invoice number associated with the order.
            - `sellerName` string, nullable, required: Name of the seller where the order is from.
            - `sellerOrderId` string, nullable, required: Id of the seller where the order is from.
            - `sellerWebsite` string, nullable, required: Website of the seller where the order is from.
          - `recipient` object, required: The recipient of the stop.
            - `name` string, nullable, required: The name of the recipient.
            - `email` string, nullable, required: The email of the recipient.
            - `phone` string, nullable, required: The phone of the recipient.
            - `externalId` string, nullable, required: The external id of the recipient.
          - `activity` 'delivery' | 'pickup'
          - `trackingLink` string, nullable, required: The recipient tracking link.
          - `timing` object, required: The timing data of the stop.
            - `timeWindows` object[], required: Ordered arrival windows for this stop.
              - …
            - `estimatedAttemptDuration` number, nullable, required: Time that the driver estimates to spend on the stop to do his job (deliver a parcel, visit a client, etc) in seconds.
            - `earliestAttemptTime` TimeOfDaySchema, required: Time of day in hours and minutes. Uses a 24 hour clock.
              - …
            - `latestAttemptTime` TimeOfDaySchema, required: Time of day in hours and minutes. Uses a 24 hour clock.
              - …
          - `optimizationOrder` 'first' | 'last' | 'default'
          - `paymentOnDelivery` object, nullable, required: The payment due upon delivery also known as "Cash on Delivery".
            - `amount` integer, nullable, required: The amount *in minor units* (e.g. cents) to be collected upon delivery.
            - `currency` string, required: The payment's currency in ISO 4217 standard.
          - `proofOfAttemptRequirements` object, required: The proof of attempt requirements of the stop.
            - `enabled` boolean, nullable, required: Whether the proof of attempt is enabled.This only works if the team subscription has access to proof of delivery
          - `customProperties` object, nullable, required: Custom properties of the stop, can be used to store additional information.
          - `clientId` string, nullable, required: The associated Client ID of the Spoke Connect
  - `nextPageToken` string, nullable, required: The next page token.

## Other responses

- `400`: The request was 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)
