Onfleet Route Plans API

Create and manage route plans — ordered sequences of tasks assigned to a worker for a time window — and kick off asynchronous route optimization jobs (task-based, vehicle-based, or auto-dispatch). Optimization endpoints are an Enterprise plan feature; results delivered via the routeOptimizationJobCompleted webhook.

GitHub OpenAPI
Business capability
Last-Mile Delivery Operations Management BC-2420.40

Operations 6

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /routePlans List route plans for a time window · List Route Plans #
Ask an LLM
“How do I get the route plans for a team's drivers between two dates?”
“Can I list route plans for a single worker?”
Tell an agent
List route plans from {from} to {to}.
Show route plans for team {teams} between {from} and {to}.
POST /routePlans Create a route plan · Create Route Plan #
Ask an LLM
“How do I create a route plan for a worker?”
“Can I set a start and end time and vehicle type on a new route plan?”
Tell an agent
Create route plan {name} for worker {worker} starting {startTime}.
Create route plan {name} for worker {worker} on team {team} from {startTime} to {endTime}.
GET /routePlans/{routePlanId} Get a route plan · Get Route Plan By ID #
Ask an LLM
“What tasks are in a given route plan?”
“Can I look up one route plan by its ID?”
Tell an agent
Get route plan {routePlanId}.
Show the tasks in route plan {routePlanId}.
PUT /routePlans/{routePlanId} Update a route plan · Update Route Plan #
Ask an LLM
“How do I change the start time of an existing route plan?”
“Can I reassign a route plan to a different worker?”
Tell an agent
Update route plan {routePlanId} to start at {startTime} for worker {worker}, name {name}.
Set the end time of route plan {routePlanId} to {endTime}.
DELETE /routePlans/{routePlanId} Delete a route plan · Delete Route Plan #
Ask an LLM
“How do I delete a route plan?”
“Can I remove a route plan by its ID?”
Tell an agent destructive · confirm first
Delete route plan {routePlanId}.
Remove the route plan {routePlanId}.
PUT /routePlans/{routePlanId}/tasks Add tasks to a route plan · Add Tasks To Route Plan #
Ask an LLM
“How do I add tasks to an existing route plan?”
“Can I append tasks to a route plan without resending the whole thing?”
Tell an agent
Add tasks {tasks} to route plan {routePlanId}.
Append tasks {tasks} to existing route plan {routePlanId}.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/onfleet:onfleet-route-plans-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

onfleet-route-plans-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Onfleet Destinations Route Plans API
  description: 'The Destinations API manages physical addresses associated with tasks.

    Destinations include parsed address fields and a GeoJSON location, and can

    be reused across tasks. Onfleet geocodes addresses on creation; you can

    also supply an `unparsed` address.'
  version: '2.7'
  contact:
    name: Onfleet Support
    email: support@onfleet.com
  license:
    name: Onfleet Terms of Service
    url: https://onfleet.com/legal
servers:
- url: https://onfleet.com/api/v2
  description: Production
security:
- basicAuth: []
tags:
- name: Route Plans
paths:
  /routePlans:
    get:
      tags:
      - Route Plans
      summary: List Route Plans
      operationId: listRoutePlans
      parameters:
      - name: from
        in: query
        required: true
        schema:
          type: integer
          format: int64
      - name: to
        in: query
        schema:
          type: integer
          format: int64
      - name: teams
        in: query
        schema:
          type: string
      - name: workers
        in: query
        schema:
          type: string
      responses:
        '200':
          description: Route plans
          content:
            application/json:
              schema:
                type: object
                properties:
                  routePlans:
                    type: array
                    items:
                      $ref: '#/components/schemas/RoutePlan'
    post:
      tags:
      - Route Plans
      summary: Create Route Plan
      operationId: createRoutePlan
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RoutePlanCreate'
      responses:
        '200':
          description: Route plan created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RoutePlan'
  /routePlans/{routePlanId}:
    parameters:
    - name: routePlanId
      in: path
      required: true
      schema:
        type: string
    get:
      tags:
      - Route Plans
      summary: Get Route Plan By ID
      operationId: getRoutePlan
      responses:
        '200':
          description: Route plan
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RoutePlan'
    put:
      tags:
      - Route Plans
      summary: Update Route Plan
      operationId: updateRoutePlan
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RoutePlanCreate'
      responses:
        '200':
          description: Updated route plan
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RoutePlan'
    delete:
      tags:
      - Route Plans
      summary: Delete Route Plan
      operationId: deleteRoutePlan
      responses:
        '200':
          description: Deleted
  /routePlans/{routePlanId}/tasks:
    put:
      tags:
      - Route Plans
      summary: Add Tasks To Route Plan
      operationId: addTasksToRoutePlan
      parameters:
      - name: routePlanId
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                tasks:
                  type: array
                  items:
                    type: string
      responses:
        '200':
          description: Updated route plan
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RoutePlan'
components:
  schemas:
    RoutePlan:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        organization:
          type: string
        timeCreated:
          type: integer
          format: int64
        timeLastModified:
          type: integer
          format: int64
        startTime:
          type: integer
          format: int64
        endTime:
          type:
          - integer
          - 'null'
          format: int64
        team:
          type:
          - string
          - 'null'
        worker:
          type:
          - string
          - 'null'
        vehicleType:
          type:
          - string
          - 'null'
        startAt:
          type: string
          enum:
          - HUB
          - WORKER_LOCATION
          - WORKER_ADDRESS
        endAt:
          type: string
          enum:
          - HUB
          - WORKER_LOCATION
          - WORKER_ADDRESS
          - ANYWHERE
        startingHubId:
          type:
          - string
          - 'null'
        endingHubId:
          type:
          - string
          - 'null'
        color:
          type:
          - string
          - 'null'
        tasks:
          type: array
          items:
            type: string
        state:
          type: string
          enum:
          - DRAFT
          - ACTIVE
          - COMPLETED
    RoutePlanCreate:
      type: object
      required:
      - name
      - startTime
      - worker
      properties:
        name:
          type: string
        startTime:
          type: integer
          format: int64
        endTime:
          type: integer
          format: int64
        worker:
          type: string
        team:
          type: string
        vehicleType:
          type: string
          enum:
          - CAR
          - MOTORCYCLE
          - BICYCLE
          - TRUCK
        startAt:
          type: string
          enum:
          - HUB
          - WORKER_LOCATION
          - WORKER_ADDRESS
        endAt:
          type: string
          enum:
          - HUB
          - WORKER_LOCATION
          - WORKER_ADDRESS
          - ANYWHERE
        startingHubId:
          type: string
        endingHubId:
          type: string
        color:
          type: string
        tasks:
          type: array
          items:
            type: string
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic