# OptimoRoute — how to use (mcp.ai)

Connect your OptimoRoute account and use 17 tools for project management straight from your AI agent. Connect with your own API key. OptimoRoute is an online route optimization and planning solution for delivery, logistics, and field service companies.

## Option A — via MCP (recommended)
Remote MCP endpoint (HTTP, streamable): `https://api.mcp.ai/p_optimoroute?ms=1787293380000`
Add it as a custom/remote MCP connector in your client (Claude, Cursor, VS Code…), then authenticate when prompted. Once connected, ask the agent to use the server's tools (e.g. `optimoroute_create_or_update_orders`).

## Option B — via direct REST API
Base URL: `https://api.mcp.ai/api/optimoroute`
Auth: `Authorization: Bearer sk_live_…` — create a workspace API key at https://mcp.ai/settings/api-keys
Discover endpoints: `GET https://api.mcp.ai/api/optimoroute/_endpoints`

### Endpoints
- `POST https://api.mcp.ai/api/optimoroute/create/or/update/orders` — Tool to bulk create, update, or replace multiple orders at once without geocoding. Use when you need to add new orders or modify existing ones efficiently. Supports up to 500 orders per request.
  - body: { orders: object[] }
- `POST https://api.mcp.ai/api/optimoroute/create/order` — Tool to create a new order or update an existing order in OptimoRoute. Use when you need to add delivery, pickup, or task orders to the system with location, time windows, and other constraints.
  - body: { id?: string, date: string, load1?: number, load2?: number, load3?: number, load4?: number, notes?: string, skills?: string[], orderNo?: string, duration?: number, location: object, priority?: string, operation: string, orderType: string, timeWindows?: object[], customField1?: string, customField2?: string, customField3?: string, customField4?: string, customField5?: string, customFields?: object, vehicleFeatures?: string[], acceptDuplicateOrderNo?: boolean }
- `POST https://api.mcp.ai/api/optimoroute/delete/all/orders` — Tool to remove all orders and planned routes for a specified date. Use when you need to clear orders for a specific date or delete all orders system-wide if no date is provided.
  - body: { date?: string }
- `POST https://api.mcp.ai/api/optimoroute/delete/order` — Tool to remove a single order from the OptimoRoute system. Use when you need to delete a specific order by its orderNo.
  - body: { orderNo: string, forceDelete?: boolean }
- `POST https://api.mcp.ai/api/optimoroute/delete/orders` — Tool to delete one or more orders from the system in bulk (max 500 per request). Use when you need to remove orders, either individually or in batch operations.
  - body: { orders: object[], forceDelete?: boolean, deleteMultiple?: boolean }
- `POST https://api.mcp.ai/api/optimoroute/get/completion/details` — Tool to retrieve completion details for one or more orders including proof of delivery data. Use when you need to check order completion status, timing details, and form data.
  - body: { orders: object[] }
- `POST https://api.mcp.ai/api/optimoroute/get/drivers` — Tool to retrieve all drivers in the system. Use when you need up-to-date driver data including status and contact information.
- `POST https://api.mcp.ai/api/optimoroute/get/events` — Tool to retrieve mobile events from drivers' field operations. Use when you need to track order completions, status changes (success, failed, on_duty, off_duty), and other field events for the current
  - body: { after_tag?: string }
- `POST https://api.mcp.ai/api/optimoroute/get/orders` — Tool to retrieve one or more orders from OptimoRoute. Use when you need detailed order information including location, time windows, and assignment details.
  - body: { orders: object[] }
- `POST https://api.mcp.ai/api/optimoroute/get/planning/status` — Tool to retrieve the status of an active planning/optimization process. Use when you need to check the progress of a planning job by providing its ID.
  - body: { planning_id: integer }
- `POST https://api.mcp.ai/api/optimoroute/get/routes` — Tool to retrieve all planned routes for a given date. Use when you need a detailed view of routes including optional stops, route parameters, and unassigned orders.
  - body: { route_date: string, driver_serial?: string, driver_external_id?: string, vehicle_registration?: string, include_route_polyline?: boolean, include_route_start_end?: boolean }
- `POST https://api.mcp.ai/api/optimoroute/get/scheduling/info` — Tool to retrieve scheduling information for a specific order. Use when you need to check if an order is scheduled and get details like driver assignment, timing, and position.
  - body: { id?: string, orderNo?: string }
- `POST https://api.mcp.ai/api/optimoroute/search/orders` — Tool to search for orders in OptimoRoute based on criteria. Use when you need to find orders by date range, order identifiers, or order status. At least one of 'orders' or 'date_range' must be provide
  - body: { limit?: integer, orders?: object[], afterTag?: string, dateRange?: object, orderStatus?: string[], includeOrderData?: boolean, includeScheduleInformation?: boolean }
- `POST https://api.mcp.ai/api/optimoroute/start/planning` — Tool to start the planning/optimization process for a specified date or date range. Use when you need to generate optimized routes for orders and drivers. Requires orders to be created before planning
  - body: { date?: string, lockType?: string, balanceBy?: string, balancing?: string, dateRange?: object, startWith?: string, useOrders?: string[], clustering?: boolean, depotTrips?: boolean, useDrivers?: object[], balancingFactor?: number, useOrderObjects?: object[], depotVisitDuration?: integer, includeScheduledOrders?: boolean }
- `POST https://api.mcp.ai/api/optimoroute/stop/planning` — Tool to stop an active planning/optimization process. Use when you need to halt a running planning job by providing its ID.
  - body: { planning_id: integer }
- `POST https://api.mcp.ai/api/optimoroute/update/driver/parameters` — Tool to update driver parameters for a specific date including work times, vehicle assignment, and start/end locations. Use when you need to modify driver availability or routing constraints. Note tha
  - body: { date: string, enabled?: boolean, endAddress?: string, externalId: string, workTimeTo?: string, endLatitude?: number, endLongitude?: number, startAddress?: string, workTimeFrom?: string, startLatitude?: number, startLongitude?: number, assignedVehicle?: string, vehicleCapacity1?: integer, vehicleCapacity2?: integer, vehicleCapacity3?: integer, vehicleCapacity4?: integer }
- `POST https://api.mcp.ai/api/optimoroute/update/drivers/parameters` — Tool to update parameters of multiple drivers for specified dates in bulk (max 500 per request). Use when you need to modify driver configuration including work hours, vehicle assignments, and locatio
  - body: { updates: object[] }

## Example prompts
- "What can I do in OptimoRoute?"
- "Show me a summary of my OptimoRoute account"

## More
- Page: https://mcp.ai/optimoroute
- Agent spec (llms.txt): https://mcp.ai/optimoroute/llms.txt
- Postman collection: https://mcp.ai/optimoroute/postman.json
