# Routines

6 tools. Generated from the MCP server: names, inputs and prices match the code.

Source: https://leverage.immo/docs/tools/routines/

## routines_create

**Create Deal Routine** · Write · Free

Create a routine; at most 3 per user. trigger "schedule" needs schedule_time_local; trigger "deal_arrived" needs a source: search_agent (search_agent_id: the id of a search profile from search_profiles_list), immometrica (external_search_id plus schedule_time_local as the poll time) or inbound_email (inbound_mailbox_id, one of the account inbound addresses from inbound_mailboxes_list; an address has at most one routine, a second one is refused with 409 inbound_mailbox_has_routine). actions is the ordered list of what to do: create_property, send_email (a prompt that writes the mail; it always goes to the account owner) and run_agent (prompt). A run_agent step is an agent that runs unattended with only the Leverage tools the owner’s plan includes, on the account’s data and Leverage’s listing search. On a run about one property (from a create_property step, or the property an inbound mail created) it is told to change only that property; otherwise it works across the account. It has no browser and no web search. Its one outside request is deals_url_extract, and only for a page on ImmoScout24, Immowelt, Immonet, Kleinanzeigen or Wohnungsbörse (any other host is refused with 403 url_not_a_listing_portal); it gets back only the deal extracted from it. The only mail it can send goes to the account owner. Its model use and the documents it processes spend the owner’s in-app AI credits, never API credits. An inactive routine may be incomplete; activating one requires the full shape. Over a connector, API key or OAuth grant: Max 5x plan and up.

Needs the plan feature `routines`.

REST: `POST /api/v1/routines`

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `name` | `string` | yes |  |
| `is_active` | `boolean` | no |  |
| `trigger` | `string` | no | Values: `schedule`, `deal_arrived` |
| `source` | `string \| null` | no | Values: `search_agent`, `inbound_email`, `immometrica` |
| `search_agent_id` | `integer \| null` | no |  |
| `external_search_id` | `string \| null` | no |  |
| `external_search_label` | `string \| null` | no |  |
| `inbound_mailbox_id` | `string \| null` | no | For source inbound_email: the id of one of the account inbound addresses (inbound_mailboxes_list). A mail to it triggers the routine. An address has at most one routine. |
| `schedule_time_local` | `string \| null` | no |  |
| `schedule_timezone` | `string \| null` | no |  |
| `actions` | `array<object>` | no |  |

## routines_delete

**Delete Deal Routine** · Write · Destructive · Free

Delete a routine by id. Over a connector, API key or OAuth grant: Max 5x plan and up.

Needs the plan feature `routines`.

REST: `DELETE /api/v1/routines/{id}`

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `integer` | yes |  |

## routines_get

**Get Deal Routine** · Read · Free

Get one routine by id: its trigger, its source configuration and its ordered actions. Over a connector, API key or OAuth grant: Max 5x plan and up.

Needs the plan feature `routines`.

REST: `GET /api/v1/routines/{id}`

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `integer` | yes |  |

## routines_list

**List Deal Routines** · Read · Free

List the user’s routines. A routine is WHEN (trigger, plus a source when the trigger is deal_arrived) THEN (ordered actions). Each item includes its trigger, source configuration and its action list in order. Over a connector, API key or OAuth grant: Max 5x plan and up.

Needs the plan feature `routines`.

REST: `GET /api/v1/routines`

No inputs.

## routines_patch

**Update Deal Routine** · Write · Destructive · Free

Update a routine by id. `actions` replaces the whole list in the given order, so send every step you want to keep. What a run_agent step can reach is stated on routines_create. Over a connector, API key or OAuth grant: Max 5x plan and up.

Needs the plan feature `routines`.

REST: `PATCH /api/v1/routines/{id}`

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `name` | `string` | no |  |
| `is_active` | `boolean` | no |  |
| `trigger` | `string` | no | Values: `schedule`, `deal_arrived` |
| `source` | `string \| null` | no | Values: `search_agent`, `inbound_email`, `immometrica` |
| `search_agent_id` | `integer \| null` | no |  |
| `external_search_id` | `string \| null` | no |  |
| `external_search_label` | `string \| null` | no |  |
| `inbound_mailbox_id` | `string \| null` | no | For source inbound_email: the id of one of the account inbound addresses (inbound_mailboxes_list). A mail to it triggers the routine. An address has at most one routine. |
| `schedule_time_local` | `string \| null` | no |  |
| `schedule_timezone` | `string \| null` | no |  |
| `actions` | `array<object>` | no |  |
| `id` | `integer` | yes |  |

## routines_run_now

**Run Deal Routine** · Write · AI credits

Start a one-off run of a routine that has a clock: trigger schedule, or source immometrica (a manual poll). Returns job_id to poll. A search_agent or inbound_email routine cannot be started this way: it runs when its source delivers. A run spends the person’s in-app AI credits, whoever starts it. Over a connector, API key or OAuth grant: Max 5x plan and up.

Always spends the in-app AI credits, never API credits.

Needs the plan feature `routines`.

REST: `POST /api/v1/routines/{id}/run`

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `integer` | yes |  |
