--- title: maintenance.setVisits | Doing Work API description: Change how many visits a plan covers each term, and what they are called (owner or office). Applies from the next term. Pass this_term true to also add the url: https://doingwork.work/docs/reference/maintenance-setvisits/ --- # maintenance.setVisits Change how many visits a plan covers each term, and what they are called (owner or office). Applies from the next term. Pass this_term true to also add them now to the current term when it has none yet. | | | |---|---| | Who | Agents can call this | | REST | `POST /v1/maintenance-plans/visits` | | MCP tool | `maintenance_setVisits` | | Writes | yes, send an Idempotency-Key | | Area | [Scheduling and visits](https://doingwork.work/docs/reference/#scheduling-and-visits) | ## When to use it Change how many visits a plan covers each term, and what they are called (owner or office). Applies from the next term. ## What to tell the owner Say what you did in plain words and what happens next. ## Input | Field | Type | Required | |---|---|---| | `plan_id` | string (uuid) | yes | | `visits_per_term` | integer | yes | | `visit_title` | string | no | | `this_term` | boolean | no | ## Example ```http POST https://doingwork.work/v1/maintenance-plans/visits content-type: application/json Idempotency-Key: 3f1c... { "plan_id": "00000000-0000-4000-8000-000000000000", "visits_per_term": 1 } ``` ## Output JSON. The response shape isn't published yet; read the fields you need and ignore the rest. Errors are `{code, message, status}`. ## Errors | Code | Status | What to do | |---|---|---| | `invalid_input`, `invalid_token`, `rate_limited` | | Can happen on any call. See [errors](https://doingwork.work/docs/errors/). |