---
title: "Calculate a tour."
method: GET
path: "/tour/calculate"
tags: ["Disposition|Tour"]
---

# Calculate a tour.

`GET /tour/calculate`

This endpoint allows you to start a job to calculate a tour by providing its `id`.
A job in geoCapture is a task executed in the background that may take some time to complete. Jobs may require
several minutes to calculate. Upon a successful request, a `jobId` is provided in the response, which can be used
to inquire about the status of the job through the Miscellaneous|Job endpoint.
When calculating a tour, the arrival and departure times, along with the driving duration and distances, are
computed in the order they were assigned to the tour. If applicable, the calculation follows the arranged
sequence of the orders. To adjust the sequence of stops within a tour, utilize the `/tour/upsert_stop` endpoint
and specify the `beforeStopId` or `afterStopId`.
To hand a tour to its driver/team, it must be calculated. Optimization of the tour is optional. Please note that
a calculated tour is not optimized.

## Query parameters

- `id` integer, required

## Response `200`

Success Response:

- StandardDispoTourCalculateResponse
  - `jobId` integer — The id of the calculation job. (The status of the job can be queried via the job API)

---

[API](https://skmtc.net/geocapture/apis/geocapture-api.md) · [All operations](https://skmtc.net/geocapture/apis/geocapture-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/geocapture/geocapture-api/revisions/15839b24c497/schema)
