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

> Change Sort Order. Zoho CRM Custom Views Change Sort reference includes SDK V2 and CLI requests, input constraints, response fields, and Deepline cost.

Change Sort Order.

<Info>
  Tool ID: `zoho_crm_custom_views_change_sort`
</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_custom_views_change_sort',
  {
    "module": "example",
    "custom_views": [
      {
        "sort_by": {
          "api_name": "Example",
          "id": "id_123"
        },
        "sort_order": "asc"
      }
    ]
  },
);

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

### CLI

```bash theme={null}
deepline tools execute zoho_crm_custom_views_change_sort --input '{
  "module": "example",
  "custom_views": [
    {
      "sort_by": {
        "api_name": "Example",
        "id": "id_123"
      },
      "sort_order": "asc"
    }
  ]
}' --json
```

## Example response

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

```json theme={null}
{
  "data": {
    "custom_views": [
      {
        "status": "success",
        "code": "SUCCESS",
        "message": "Example message"
      }
    ]
  }
}
```

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

## Input reference

Request body for changing the sort order of a custom view

| Name                   | Type     | Required | Default | Details                                                       |
| ---------------------- | -------- | -------- | ------- | ------------------------------------------------------------- |
| `payload.module`       | `string` | Yes      | —       | module name Maximum length: 25.                               |
| `payload.custom_views` | `array`  | Yes      | —       | List of custom views to update sort order Maximum items: 200. |

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

  ### Input JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Request body for changing the sort order of a custom view",
    "properties": {
      "module": {
        "type": "string",
        "description": "module name",
        "maxLength": 25
      },
      "custom_views": {
        "type": "array",
        "description": "List of custom views to update sort order",
        "maxItems": 200,
        "items": {
          "type": "object",
          "description": "Custom view sort order details",
          "properties": {
            "sort_by": {
              "type": "object",
              "description": "field of customview",
              "properties": {
                "api_name": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "API name of the field"
                },
                "id": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "field id"
                }
              },
              "additionalProperties": false
            },
            "sort_order": {
              "type": "string",
              "description": "Order of sorting",
              "enum": [
                "asc",
                "desc"
              ]
            },
            "id": {
              "type": "string",
              "description": "ID of the custom view to update",
              "maxLength": 25
            }
          },
          "required": [
            "sort_by",
            "sort_order"
          ],
          "additionalProperties": false
        }
      }
    },
    "required": [
      "module",
      "custom_views"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

Standard tool result payload.

| Name                                    | Type        | Required | Default | Details                                                         |
| --------------------------------------- | ----------- | -------- | ------- | --------------------------------------------------------------- |
| `result.data`                           | `object`    | Yes      | —       | Bulk update success response schema                             |
| `result.data.custom_views`              | `array`     | Yes      | —       | Array of custom views with success details Maximum items: 200.  |
| `result.data.custom_views[].status`     | `"success"` | No       | —       | Indicates the operation was successful. Allowed: `success`.     |
| `result.data.custom_views[].code`       | `"SUCCESS"` | No       | —       | Success code for the operation. Allowed: `SUCCESS`.             |
| `result.data.custom_views[].message`    | `string`    | No       | —       | Human readable message indicating success. Maximum length: 255. |
| `result.data.custom_views[].details`    | `object`    | No       | —       | Extra details                                                   |
| `result.data.custom_views[].details.id` | `string`    | No       | —       | ID of the Custom View Maximum length: 20.                       |
| `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": "Bulk update success response schema",
        "properties": {
          "custom_views": {
            "type": "array",
            "description": "Array of custom views with success details",
            "maxItems": 200,
            "items": {
              "type": "object",
              "description": "Response schema for successful custom view update operation.",
              "properties": {
                "status": {
                  "type": "string",
                  "description": "Indicates the operation was successful.",
                  "enum": [
                    "success"
                  ]
                },
                "code": {
                  "type": "string",
                  "description": "Success code for the operation.",
                  "enum": [
                    "SUCCESS"
                  ]
                },
                "message": {
                  "type": "string",
                  "description": "Human readable message indicating success.",
                  "maxLength": 255
                },
                "details": {
                  "type": "object",
                  "description": "Extra details",
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "ID of the Custom View",
                      "maxLength": 20
                    }
                  },
                  "additionalProperties": false
                }
              },
              "additionalProperties": false
            }
          }
        },
        "required": [
          "custom_views"
        ],
        "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)
