> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Zoho CRM: README

> Remove Territories To Record. Includes SDK V2 and CLI requests, input constraints, response fields, and Deepline credit cost.

Remove Territories To Record.

<Info>
  Tool ID: `zoho_crm_territories_remove_territories_to_record`
</Info>

## Run this action

Use the TypeScript SDK for a single call. Put `ctx.tools.execute(...)` inside a Play when the call should be durable, scheduled, or run across a CSV.

```ts theme={null}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'zoho_crm_territories_remove_territories_to_record',
  {
    "record": "example",
    "module": "Contacts",
    "data": [
      {
        "Territories": [
          {
            "id": "id_123"
          }
        ]
      }
    ]
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={null}
deepline tools execute zoho_crm_territories_remove_territories_to_record --input '{
  "record": "example",
  "module": "Contacts",
  "data": [
    {
      "Territories": [
        {
          "id": "id_123"
        }
      ]
    }
  ]
}' --json
```

## Example response

The SDK exposes this shape at `result.toolResponse.raw`. Values below are representative.

```json theme={null}
{
  "data": {
    "data": [
      {
        "code": "SCHEDULED",
        "details": {
          "id": "id_123",
          "job_id": "job_123"
        },
        "message": "Example message",
        "status": "success"
      }
    ]
  }
}
```

Use `deepline tools get zoho_crm_territories_remove_territories_to_record --json` for the latest machine-readable contract.

## Input reference

The `schema` field of type `object`.

| Name             | Type                                             | Required | Default | Details                                                                          |
| ---------------- | ------------------------------------------------ | -------- | ------- | -------------------------------------------------------------------------------- |
| `payload.record` | `string`                                         | Yes      | —       | Parameter `record` in `path`. Maximum length: 100.                               |
| `payload.module` | `"Contacts" \| "Leads" \| "Deals" \| "Accounts"` | Yes      | —       | Parameter `module` in `path`. Allowed: `Contacts`, `Leads`, `Deals`, `Accounts`. |
| `payload.data`   | `array`                                          | Yes      | —       | The `data` property. Maximum items: 100.                                         |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "The `schema` field of type `object`.",
    "properties": {
      "record": {
        "type": "string",
        "description": "Parameter `record` in `path`.",
        "maxLength": 100
      },
      "module": {
        "type": "string",
        "description": "Parameter `module` in `path`.",
        "enum": [
          "Contacts",
          "Leads",
          "Deals",
          "Accounts"
        ]
      },
      "data": {
        "type": "array",
        "description": "The `data` property.",
        "maxItems": 100,
        "items": {
          "type": "object",
          "description": "The `items` field of type `object`.",
          "properties": {
            "id": {
              "type": "string",
              "description": "The `id` property.",
              "maxLength": 100
            },
            "Territories": {
              "type": "array",
              "description": "The `Territories` property.",
              "maxItems": 100,
              "items": {
                "type": "object",
                "description": "The `items` field of type `object`.",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "The `id` property.",
                    "maxLength": 100
                  }
                },
                "required": [
                  "id"
                ],
                "additionalProperties": false
              }
            }
          },
          "required": [
            "Territories"
          ],
          "additionalProperties": false
        }
      }
    },
    "required": [
      "record",
      "module",
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

Standard tool result payload.

| Name                                | Type                                | Required | Default | Details                                                                                      |
| ----------------------------------- | ----------------------------------- | -------- | ------- | -------------------------------------------------------------------------------------------- |
| `result.data`                       | `object`                            | Yes      | —       | A `object` value.                                                                            |
| `result.data.data`                  | `array`                             | Yes      | —       | The `data` property. Maximum items: 100.                                                     |
| `result.data.data[].code`           | `"SCHEDULED"`                       | Yes      | —       | Status code indicating the result of the operation (e.g., SCHEDULED). Allowed: `SCHEDULED`.  |
| `result.data.data[].details`        | `object`                            | Yes      | —       | Additional information about the created territory.                                          |
| `result.data.data[].details.id`     | `string`                            | Yes      | —       | Unique identifier of the created territory. Format: `string`.                                |
| `result.data.data[].details.job_id` | `string`                            | Yes      | —       | Unique identifier of the scheduled job. Format: `string`.                                    |
| `result.data.data[].message`        | `string`                            | Yes      | —       | Human-readable message describing the outcome of the operation. Format: `string`.            |
| `result.data.data[].status`         | `"success" \| "failure" \| "error"` | Yes      | —       | Indicates whether the operation succeeded or failed. Allowed: `success`, `failure`, `error`. |
| `result.meta`                       | `object`                            | No       | —       | Additional response metadata (status, paging).                                               |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Standard tool result payload.",
    "properties": {
      "data": {
        "type": "object",
        "description": "A `object` value.",
        "properties": {
          "data": {
            "type": "array",
            "description": "The `data` property.",
            "maxItems": 100,
            "items": {
              "type": "object",
              "description": "Details of each territory operation.",
              "properties": {
                "code": {
                  "type": "string",
                  "description": "Status code indicating the result of the operation (e.g., SCHEDULED).",
                  "enum": [
                    "SCHEDULED"
                  ]
                },
                "details": {
                  "type": "object",
                  "description": "Additional information about the created territory.",
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "Unique identifier of the created territory.",
                      "format": "string"
                    },
                    "job_id": {
                      "type": "string",
                      "description": "Unique identifier of the scheduled job.",
                      "format": "string"
                    }
                  },
                  "required": [
                    "id",
                    "job_id"
                  ],
                  "additionalProperties": false
                },
                "message": {
                  "type": "string",
                  "description": "Human-readable message describing the outcome of the operation.",
                  "format": "string"
                },
                "status": {
                  "type": "string",
                  "description": "Indicates whether the operation succeeded or failed.",
                  "enum": [
                    "success",
                    "failure",
                    "error"
                  ]
                }
              },
              "required": [
                "code",
                "details",
                "message",
                "status"
              ],
              "additionalProperties": false
            }
          }
        },
        "required": [
          "data"
        ],
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "description": "Additional response metadata (status, paging).",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `fixed` (per call).
* Estimated Deepline credits: `0` per pricing unit.
* Provider-native pricing may still exist outside Deepline credit billing.

## Related documentation

* [SDK V2 quickstart](/docs/sdk-v2/quickstart)
* [SDK reference](/docs/sdk-v2/sdk-reference)
* [Run tools across a CSV](/docs/sdk-v2/batch-csv)
