Skip to content

Zoho: Search Records by Criteria, Word, Email, or Phone

Zoho moduleSearch.searchRecords: arguments, response, policy and SDK examples.

← Module search operations · Get started

Operation zoho.searchrecords

Provider route: GET /crm/v8/{module}/search. Alter supplies the connection’s credentials and routing.

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["moduleSearch"]["searchRecords"]>[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.moduleSearch.searchRecords(input);
const result = await call.wait();
return result.bodyJson();
} finally {
await app.close();
}
}
import os
from alter_sdk import App
from 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.module_search.search_records(arguments)
result = await call.wait()
return result.body_json()
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: not allowed
pathobjectRequired within parentAdditional keys: not allowed
path.modulestringRequired within parentMaximum length: 100
queryobjectOptionalAdditional keys: not allowed
query.approval_statestringOptionalOne of: approval_process_pending, webform_invalid, review_process_pending, webform_invalid_approval, zia_vision_validation, review_process_rejected, webform_unapproved, email_parser_waiting, approved, merge_pending, email_parser_rejected, zia_vision_rejected, zia_vision_pending, approval_process_rejected, webform_double_optin
Maximum length: 50
query.criteriastringOptionalMaximum length: 3000
query.convertedstringOptionalDefault: false
One of: true, false, both
Maximum length: 10
query.wordstringOptionalMaximum length: 100
Minimum length: 2
query.emailstringOptionalFormat: string
Maximum length: 255
query.phonestringOptionalMaximum length: 50
Minimum length: 3
Pattern: ^[+]?[0-9\s-().]+$
query.fieldsstringOptionalMaximum length: 2000
query.pageintegerOptionalDefault: 1
Format: int32
Minimum: 1
query.per_pageintegerOptionalDefault: 200
Format: int32
Maximum: 200
Minimum: 1
query.sort_bystringOptionalDefault: id
Maximum length: 100
query.sort_orderstringOptionalDefault: desc
One of: asc, desc
Maximum length: 10
query.typestringOptionalOne of: ActiveAndDeactive, CurrentUser, DeletedUsers, ParentRoleUsers, ChildRoleUsers, DeactiveUsers, NotConfirmedUsers, ConfirmedUsers, ActiveUsers, AdminUsers, ActiveConfirmedAdmins, ActiveConfirmedUsers, DeveloperUsers, SubordinateRoleUsers, AllUsers, AllActiveUsers
Maximum length: 50
query.include_lite_usersbooleanOptionalDefault: false
query.role_idstringOptionalFormat: int64
Maximum length: 20

Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.

FieldTypePresenceDescription and constraints
$JSONRoot
$ (anyOf 1)objectAlternativeRepresents the successful response returned by the search operation, containing the matched records and pagination metadata.
Additional keys: not allowed
$ (anyOf 1).dataarrayRequired within parentRepresents the list of records matching the search criteria.
Maximum items: 200
$ (anyOf 1).data[]objectEach itemRepresents a record that matches the search criteria. Contains standard system fields and module-specific fields for the matched record.
Additional keys: allowed
$ (anyOf 1).data[].Created_ByobjectOptionalRepresents the user who created the record.
Additional keys: not allowed
$ (anyOf 1).data[].Created_By.emailstringOptionalSearches for records using an email address. The API searches across all email fields in the specified module and returns matching records.
Format: email
$ (anyOf 1).data[].Created_By.idstringRequired within parentRepresents the unique ID of the user who created the record.
Maximum length: 50
$ (anyOf 1).data[].Created_By.namestringOptionalRepresents the name of the user who created the record.
Maximum length: 255
$ (anyOf 1).data[].Created_TimestringOptionalRepresents the creation timestamp of the record.
Format: date-time
$ (anyOf 1).data[].Modified_ByobjectOptionalRepresents the user who last modified the record.
Additional keys: not allowed
$ (anyOf 1).data[].Modified_By.emailstringOptionalSearches for records using an email address. The API searches across all email fields in the specified module and returns matching records.
Format: email
$ (anyOf 1).data[].Modified_By.idstringOptionalRepresents the unique ID of the user who last modified the record.
Maximum length: 50
$ (anyOf 1).data[].Modified_By.namestringOptionalRepresents the name of the user who last modified the record.
Maximum length: 255
$ (anyOf 1).data[].Modified_TimestringOptionalRepresents the date and time when the record was last modified.
Format: date-time
$ (anyOf 1).data[].OwnerobjectOptionalRepresents the owner of the record.
Additional keys: not allowed
$ (anyOf 1).data[].Owner.emailstringOptionalSearches for records using an email address. The API searches across all email fields in the specified module and returns matching records.
Format: email
$ (anyOf 1).data[].Owner.idstringOptionalRepresents the unique ID of the record owner.
Maximum length: 50
$ (anyOf 1).data[].Owner.namestringOptionalRepresents the name of the record owner.
Maximum length: 255
$ (anyOf 1).data[].idstringRequired within parentRepresents the unique ID of the record.
Maximum length: 50
$ (anyOf 1).infoobjectOptionalRepresents the pagination and sort metadata for the response.
Additional keys: not allowed
$ (anyOf 1).info.countJSONOptional
$ (anyOf 1).info.count (anyOf 1)integerAlternativeRepresents the number of records returned in the current page.
Format: int32
$ (anyOf 1).info.count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
$ (anyOf 1).info.more_recordsbooleanOptionalIndicates whether more records are available beyond the current page.
Possible values:
true - More records are available.
false - No more records are available.
$ (anyOf 1).info.pageJSONOptional
$ (anyOf 1).info.page (anyOf 1)integerAlternativeRepresents the current page number of the response.
Format: int32
$ (anyOf 1).info.page (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
$ (anyOf 1).info.per_pageJSONOptional
$ (anyOf 1).info.per_page (anyOf 1)integerAlternativeSpecify how many records to return per page. The default and the maximum possible value is 200.
Format: int32
$ (anyOf 1).info.per_page (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
$ (anyOf 1).info.sort_bystringOptionalRepresents the field used to sort the records in the response.
Maximum length: 100
$ (anyOf 1).info.sort_orderstringOptionalRepresents the sort direction applied to the records in the response.
Possible values:
asc - Ascending order.
desc - Descending order.
Known values: asc, desc
$ (anyOf 2)nullAlternative

SDK function policy ID: zoho.searchrecords. Catalog operation: searchRecords. 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]

Official provider source

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand which product and documentation features are useful.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

You can change these choices at any time from Cookie settings.