> ## 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

> Get Associated Groups for User. Includes SDK V2 and CLI requests, input constraints, response fields, and Deepline credit cost.

Get Associated Groups for User.

<Info>
  Tool ID: `zoho_crm_user_groups_get_associated_groups_for_user`
</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_user_groups_get_associated_groups_for_user',
  {
    "user": "3652397000000186017"
  },
);

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

### CLI

```bash theme={null}
deepline tools execute zoho_crm_user_groups_get_associated_groups_for_user --input '{
  "user": "3652397000000186017"
}' --json
```

## Example response

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

```json theme={null}
{
  "data": {
    "user_groups": [
      {
        "created_by": {
          "name": "Example",
          "id": "id_123"
        },
        "modified_by": {},
        "modified_time": {},
        "created_time": "2026-01-15T12:00:00Z",
        "description": {},
        "id": "id_123",
        "name": "Example"
      }
    ],
    "info": {
      "per_page": 123,
      "count": 123,
      "page": 123,
      "more_records": true
    }
  }
}
```

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

## Input reference

Get the list of user groups associated with the specified user.

| Name               | Type                           | Required | Default | Details                                                                         |
| ------------------ | ------------------------------ | -------- | ------- | ------------------------------------------------------------------------------- |
| `payload.user`     | `"3652397000000186017"`        | Yes      | —       | The unique identifier of the user Allowed: `3652397000000186017`.               |
| `payload.include`  | `"sources_count" \| "sources"` | No       | —       | Additional data to include in the response Allowed: `sources_count`, `sources`. |
| `payload.page`     | `integer`                      | No       | —       | Page number to retrieve Format: `int32`. Minimum: 1.                            |
| `payload.per_page` | `integer`                      | No       | —       | Number of items to return per page Format: `int32`. Minimum: 1. Maximum: 200.   |

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

  ### Input JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Get the list of user groups associated with the specified user.",
    "properties": {
      "user": {
        "type": "string",
        "description": "The unique identifier of the user",
        "enum": [
          "3652397000000186017"
        ]
      },
      "include": {
        "type": "string",
        "description": "Additional data to include in the response",
        "enum": [
          "sources_count",
          "sources"
        ]
      },
      "page": {
        "type": "integer",
        "description": "Page number to retrieve",
        "minimum": 1,
        "format": "int32"
      },
      "per_page": {
        "type": "integer",
        "description": "Number of items to return per page",
        "minimum": 1,
        "maximum": 200,
        "format": "int32"
      }
    },
    "required": [
      "user"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

Standard tool result payload.

| Name                                                     | Type                                              | Required | Default | Details                                                                |
| -------------------------------------------------------- | ------------------------------------------------- | -------- | ------- | ---------------------------------------------------------------------- |
| `result.data`                                            | `object`                                          | Yes      | —       | Response containing list of associated user groups                     |
| `result.data.user_groups`                                | `array`                                           | Yes      | —       | Array of user groups Maximum items: 200.                               |
| `result.data.user_groups[].created_by`                   | `object`                                          | Yes      | —       | User who created this group                                            |
| `result.data.user_groups[].created_by.name`              | `string`                                          | Yes      | —       | Name of the creator Maximum length: 512.                               |
| `result.data.user_groups[].created_by.id`                | `string`                                          | Yes      | —       | ID of the creator Maximum length: 19.                                  |
| `result.data.user_groups[].modified_by`                  | `record`                                          | Yes      | —       | User who last modified this group                                      |
| `result.data.user_groups[].modified_time`                | `record`                                          | Yes      | —       | Last modification timestamp                                            |
| `result.data.user_groups[].created_time`                 | `string`                                          | Yes      | —       | Creation timestamp Format: `date-time`.                                |
| `result.data.user_groups[].description`                  | `record`                                          | Yes      | —       | Group description                                                      |
| `result.data.user_groups[].id`                           | `string`                                          | Yes      | —       | Unique identifier for the group Maximum length: 19.                    |
| `result.data.user_groups[].name`                         | `string`                                          | Yes      | —       | Name of the group Maximum length: 250.                                 |
| `result.data.user_groups[].sources`                      | `array`                                           | No       | —       | Array of sources for the user group Maximum items: 200.                |
| `result.data.user_groups[].sources[].source`             | `object`                                          | Yes      | —       | Source information                                                     |
| `result.data.user_groups[].sources[].source.name`        | `string`                                          | Yes      | —       | Name of the source Maximum length: 250.                                |
| `result.data.user_groups[].sources[].source.id`          | `string`                                          | Yes      | —       | ID of the source Maximum length: 19.                                   |
| `result.data.user_groups[].sources[].type`               | `"users" \| "roles" \| "territories" \| "groups"` | Yes      | —       | Type of the source Allowed: `users`, `roles`, `territories`, `groups`. |
| `result.data.user_groups[].sources[].subordinates`       | `boolean`                                         | No       | —       | Include subordinates flag                                              |
| `result.data.user_groups[].sources[].sub_territories`    | `boolean`                                         | No       | —       | Include sub-territories flag                                           |
| `result.data.user_groups[].sources_count`                | `object`                                          | No       | —       | Count of sources by type                                               |
| `result.data.user_groups[].sources_count.territories`    | `integer`                                         | No       | —       | Number of territories Format: `int32`.                                 |
| `result.data.user_groups[].sources_count.roles`          | `integer`                                         | No       | —       | Number of roles Format: `int32`.                                       |
| `result.data.user_groups[].sources_count.groups`         | `integer`                                         | No       | —       | Number of groups Format: `int32`.                                      |
| `result.data.user_groups[].sources_count.users`          | `object`                                          | No       | —       | User count by status                                                   |
| `result.data.user_groups[].sources_count.users.inactive` | `integer`                                         | Yes      | —       | Number of inactive users Format: `int32`.                              |
| `result.data.user_groups[].sources_count.users.deleted`  | `integer`                                         | Yes      | —       | Number of deleted users Format: `int32`.                               |
| `result.data.user_groups[].sources_count.users.active`   | `integer`                                         | Yes      | —       | Number of active users Format: `int32`.                                |
| `result.data.info`                                       | `object`                                          | Yes      | —       | Information about pagination                                           |
| `result.data.info.per_page`                              | `integer`                                         | Yes      | —       | Number of records per page Format: `int32`.                            |
| `result.data.info.count`                                 | `integer`                                         | Yes      | —       | Number of records Format: `int32`.                                     |
| `result.data.info.page`                                  | `integer`                                         | Yes      | —       | Current page number Format: `int32`.                                   |
| `result.data.info.more_records`                          | `boolean`                                         | Yes      | —       | Indicates if there are more records available                          |
| `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": "Response containing list of associated user groups",
        "properties": {
          "user_groups": {
            "type": "array",
            "description": "Array of user groups",
            "maxItems": 200,
            "items": {
              "type": "object",
              "description": "User group details",
              "properties": {
                "created_by": {
                  "type": "object",
                  "description": "User who created this group",
                  "properties": {
                    "name": {
                      "type": "string",
                      "description": "Name of the creator",
                      "maxLength": 512
                    },
                    "id": {
                      "type": "string",
                      "description": "ID of the creator",
                      "maxLength": 19
                    }
                  },
                  "required": [
                    "name",
                    "id"
                  ],
                  "additionalProperties": false
                },
                "modified_by": {
                  "type": "object",
                  "description": "User who last modified this group",
                  "additionalProperties": true
                },
                "modified_time": {
                  "type": "object",
                  "description": "Last modification timestamp",
                  "additionalProperties": true
                },
                "created_time": {
                  "type": "string",
                  "description": "Creation timestamp",
                  "format": "date-time"
                },
                "description": {
                  "type": "object",
                  "description": "Group description",
                  "additionalProperties": true
                },
                "id": {
                  "type": "string",
                  "description": "Unique identifier for the group",
                  "maxLength": 19
                },
                "name": {
                  "type": "string",
                  "description": "Name of the group",
                  "maxLength": 250
                },
                "sources": {
                  "type": "array",
                  "description": "Array of sources for the user group",
                  "maxItems": 200,
                  "items": {
                    "type": "object",
                    "description": "Source details",
                    "properties": {
                      "source": {
                        "type": "object",
                        "description": "Source information",
                        "properties": {
                          "name": {
                            "type": "string",
                            "description": "Name of the source",
                            "maxLength": 250
                          },
                          "id": {
                            "type": "string",
                            "description": "ID of the source",
                            "maxLength": 19
                          }
                        },
                        "required": [
                          "name",
                          "id"
                        ],
                        "additionalProperties": false
                      },
                      "type": {
                        "type": "string",
                        "description": "Type of the source",
                        "enum": [
                          "users",
                          "roles",
                          "territories",
                          "groups"
                        ]
                      },
                      "subordinates": {
                        "type": "boolean",
                        "description": "Include subordinates flag"
                      },
                      "sub_territories": {
                        "type": "boolean",
                        "description": "Include sub-territories flag"
                      }
                    },
                    "required": [
                      "source",
                      "type"
                    ],
                    "additionalProperties": false
                  }
                },
                "sources_count": {
                  "type": "object",
                  "description": "Count of sources by type",
                  "properties": {
                    "territories": {
                      "type": "integer",
                      "description": "Number of territories",
                      "format": "int32"
                    },
                    "roles": {
                      "type": "integer",
                      "description": "Number of roles",
                      "format": "int32"
                    },
                    "groups": {
                      "type": "integer",
                      "description": "Number of groups",
                      "format": "int32"
                    },
                    "users": {
                      "type": "object",
                      "description": "User count by status",
                      "properties": {
                        "inactive": {
                          "type": "integer",
                          "description": "Number of inactive users",
                          "format": "int32"
                        },
                        "deleted": {
                          "type": "integer",
                          "description": "Number of deleted users",
                          "format": "int32"
                        },
                        "active": {
                          "type": "integer",
                          "description": "Number of active users",
                          "format": "int32"
                        }
                      },
                      "required": [
                        "inactive",
                        "deleted",
                        "active"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "additionalProperties": false
                }
              },
              "required": [
                "created_by",
                "modified_by",
                "modified_time",
                "created_time",
                "description",
                "id",
                "name"
              ],
              "additionalProperties": false
            }
          },
          "info": {
            "type": "object",
            "description": "Information about pagination",
            "properties": {
              "per_page": {
                "type": "integer",
                "description": "Number of records per page",
                "format": "int32"
              },
              "count": {
                "type": "integer",
                "description": "Number of records",
                "format": "int32"
              },
              "page": {
                "type": "integer",
                "description": "Current page number",
                "format": "int32"
              },
              "more_records": {
                "type": "boolean",
                "description": "Indicates if there are more records available"
              }
            },
            "required": [
              "per_page",
              "count",
              "page",
              "more_records"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "user_groups",
          "info"
        ],
        "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)
