Zoho: get a picklist field option
Zoho pickListValues.getPickListValuesByPickListValueid: arguments, response, policy and SDK examples.
← Pick list values operations · Get started
Operation zoho.getpicklistvaluesbypicklistvalueid
Provider route: GET /crm/v8/settings/fields/{fieldId}/pick_list_values/{pickListValueId}. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/zoho with npm, or alter-sdk-zoho with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { ZohoIntegration } from "@alter-ai/zoho";
async function execute(input: Parameters<ZohoIntegration["pickListValues"]["getPickListValuesByPickListValueid"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new ZohoIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.pickListValues.getPickListValuesByPickListValueid(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_zoho import ZohoIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = ZohoIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.pick_list_values.get_pick_list_values_by_pick_list_valueid(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
path | object | Required within parent | Additional keys: not allowed |
path.fieldId | string | Required within parent | Format: int64 Minimum length: 1 |
path.pickListValueId | string | Required within parent | Format: int64 Maximum length: 255 |
query | object | Required within parent | Additional keys: not allowed |
query.module | string | Required within parent | Maximum length: 50 Minimum length: 1 |
Response
Section titled “Response”Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | Model | Alternative | Expand get a picklist field option — response body — pick list values |
$ (anyOf 2) | null | Alternative |
Referenced models: get a picklist field option — response body — pick list values
Schemas
Section titled “Schemas”get a picklist field option — response body — pick list values
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Successful response containing the list of picklist options that match the specified pick list value ID for the given field. Additional keys: not allowed |
pick_list_values | array | Required within parent | PickList option of the mention picklist unique Id Maximum items: 1 Minimum items: 1 |
pick_list_values[] | Model | Each item | Expand get a picklist field option — response body — pick list values pick list values item |
Referenced models: get a picklist field option — response body — pick list values pick list values item
get a picklist field option — response body — pick list values pick list values item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Full metadata for a picklist option, including unique ID, actual/reference/display values, sequence order, usage type (used/unused), optional color code, and associated layouts. Additional keys: not allowed |
actual_value | string | Required within parent | Actual value of the picklist option. Maximum length: 120 |
colour_code | JSON | Required within parent | |
colour_code (anyOf 1) | string | Alternative | Color code of the picklist option when the picklist field in color code enabled Maximum length: 9 |
colour_code (anyOf 2) | null | Alternative | Color code of the picklist option when the picklist field in color code enabled Maximum length: 9 |
display_value | string | Required within parent | Display value of the picklist option which are localised or translated Maximum length: 120 |
id | string | Required within parent | Unique Id of the picklist option Format: int64 |
layout_associations | JSON | Required within parent | |
layout_associations (anyOf 1) | array | Alternative | Layout Association of the picklist option Maximum items: 6 Minimum items: 0 |
layout_associations (anyOf 1)[] | Model | Each item | Expand get a picklist field option — response body — pick list values pick list values item layout associations Layout Association of the picklist option item |
layout_associations (anyOf 2) | null | Alternative | Layout Association of the picklist option Maximum items: 6 Minimum items: 0 |
layout_associations (anyOf 2)[] | Model | Each item | Expand get a picklist field option — response body — pick list values pick list values item layout associations Layout Association of the picklist option item |
reference_value | string | Required within parent | Reference value of the picklist option which are localised or updated Maximum length: 120 |
sequence_number | JSON | Required within parent | |
sequence_number (anyOf 1) | integer | Alternative | sort order of the option respective to field Format: int32 |
sequence_number (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
type | string | Required within parent | Presence of the option in layouts and in the module Known values: used, unused |
Referenced models: get a picklist field option — response body — pick list values pick list values item layout associations Layout Association of the picklist option item
get a picklist field option — response body — pick list values pick list values item layout associations Layout Association of the picklist option item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Identifies a layout where the picklist option is available, including the layout API name, display name, and unique association ID. Additional keys: not allowed |
api_name | string | Required within parent | Api Name of the layout Maximum length: 255 |
id | string | Required within parent | Unique Id of the picklist option Format: int64 |
name | string | Required within parent | Name of the layout Maximum length: 255 |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: zoho.getpicklistvaluesbypicklistvalueid. Catalog operation: getPickListValuesByPickListValueid. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.
Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.
No-content response statuses: [204]