Fields Meta Data
Purpose
To get the field metadata for the specified module.
Request Details
Request URL
https://www.zohoapis.com/bigin/v1/settings/fields
Scope
scope=ZohoBigin.settings.fields.READ
(or)
scope=ZohoBigin.settings.fields.ALL
(or)
scope=ZohoBigin.settings.ALL
Parameters
- modulestring, mandatory
Specify the API name of the required module. For example Contacts, Accounts (Companies in Bigin), Deals, and so on.
Note
Use the api_name of the fields in all API inputs instead of field labels. This ensures that the label name changes in custom modules or fields won't affect your existing integrations.
Sample Request
Copiedcurl "https://www.zohoapis.com/bigin/v1/settings/fields?module=Contacts"
-X GET
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf"
CopiedZCRMModule module = ZCRMModule.getInstance("Products"); // module apiname
BulkAPIResponse response = module.getAllFields();
List<ZCRMField> fields = (List<ZCRMField>) response.getData();
Copiedtry{
$moduleIns=ZCRMModule::getInstance("Leads");
$apiResponse=$moduleIns->getAllFields();
$fields=$apiResponse->getData();
foreach ($fields as $field)
{
echo $field->getApiName().", ";
echo $field->getLength().", ";
echo $field->IsVisible().", ";
echo $field->getFieldLabel().", ";
echo $field->getCreatedSource().", ";
echo $field->isMandatory().", ";
echo $field->getSequenceNumber().", ";
echo $field->isReadOnly().", ";
echo $field->getDataType().", ";
echo $field->getId().", ";
echo $field->isCustomField().", ";
echo $field->isBusinessCardSupported().", ";
$fieldLayoutPerm=$field->getFieldLayoutPermissions();
foreach ($fieldLayoutPerm as $perm)
{
echo $perm.", ";
}
$lookupField=$field->getLookupField();
if($lookupField!=null)
{
echo $lookupField->getModule().", ";
echo $lookupField->getDisplayLabel().", ";
echo $lookupField->getId().", ";
}
$pickListFields=$field->getPickListFieldValues();
foreach ($pickListFields as $pickList)
{
echo $pickList->getDisplayValue().", ";
echo $pickList->getSequenceNumber().", ";
echo $pickList->getActualValue().", ";
echo $pickList->getMaps().", ";
}
echo $field->isUniqueField().", ";
echo $field->isCaseSensitive().", ";
echo $field->isCurrencyField().", ";
echo $field->getPrecision().", ";
echo $field->getRoundingOption().", ";
echo $field->isFormulaField().", ";
echo $field->getFormulaReturnType().", ";
echo $field->getFormulaExpression().", ";
echo $field->isAutoNumberField().", ";
echo $field->getPrefix().", ";
echo $field->getSuffix().", ";
echo $field->getStartNumber().", ";
echo $field->getDecimalPlace().", ";
$convertMap=$field->getConvertMapping();
if($convertMap!=null)
{
foreach ($convertMap as $key=>$value)
{
echo $key.":".$value;
}
}
}
}
catch (ZCRMException $e)
{
echo $e->getCode();
echo $e->getMessage();
echo $e->getExceptionCode();
}
Copieddef get_fields(self):
try:
module_ins = ZCRMModule.get_instance('Accounts') # module API Name
resp = module_ins.get_all_fields()
print(resp.status_code)
field_ins_arr = resp.data
for field_ins in field_ins_arr:
print(field_ins.api_name)
print(field_ins.id)
print(field_ins.is_custom_field)
print(field_ins.lookup_field)
print(field_ins.convert_mapping)
print(field_ins.is_visible)
print(field_ins.field_label)
print(field_ins.length)
print(field_ins.created_source)
print(field_ins.default_value)
print(field_ins.is_mandatory)
print(field_ins.sequence_number)
print(field_ins.is_read_only)
print(field_ins.is_unique_field)
print(field_ins.is_case_sensitive)
print(field_ins.data_type)
print(field_ins.is_formula_field)
print(field_ins.is_currency_field)
print(field_ins.picklist_values)
print(field_ins.is_auto_number)
print(field_ins.is_business_card_supported)
print(field_ins.field_layout_permissions)
print(field_ins.decimal_place)
print(field_ins.precision)
print(field_ins.rounding_option)
print(field_ins.formula_return_type)
print(field_ins.formula_expression)
print(field_ins.prefix)
print(field_ins.suffix)
print(field_ins.start_number)
print(field_ins.json_type)
print("\n\n")
except ZCRMException as ex:
print(ex.status_code)
print(ex.error_message)
print(ex.error_code)
print(ex.error_details)
print(ex.error_content)
CopiedZCRMModule moduleIns = ZCRMModule.GetInstance("Leads"); //module api name
BulkAPIResponse<ZCRMField> response = moduleIns.GetAllFields();
List<ZCRMField> fields = response.BulkData; //fields - list of ZCRMField instance
Copiedresponse = invokeurl
[
url: "https://www.zohoapis.com/crm/v2/settings/fields?module=Leads"
type: GET
connection:"crm_oauth_connection"
];
info response;
Sample Response
Copied{
"fields": [
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "First Name",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "First Name",
"read_only": false,
"association_details": null,
"quick_sequence_number": "1",
"currency": {},
"id": "529793000000000441",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 40,
"view_type": {
"view": false,
"edit": true,
"quick_create": true,
"create": true
},
"subform": null,
"external": null,
"api_name": "First_Name",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": true,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Last Name",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Last Name",
"read_only": false,
"association_details": null,
"quick_sequence_number": "2",
"currency": {},
"id": "529793000000000443",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 80,
"view_type": {
"view": false,
"edit": true,
"quick_create": true,
"create": true
},
"subform": null,
"external": null,
"api_name": "Last_Name",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "jsonobject",
"crypt": null,
"field_label": "Account Name",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Account Name",
"read_only": false,
"association_details": null,
"quick_sequence_number": "3",
"currency": {},
"id": "529793000000000445",
"custom_field": false,
"lookup": {
"display_label": "Contacts",
"api_name": "Contacts",
"module": "Accounts",
"id": "529793000000002740"
},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": true,
"quick_create": true,
"create": true
},
"subform": null,
"external": null,
"api_name": "Account_Name",
"unique": {},
"data_type": "lookup",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": false,
"json_type": "string",
"crypt": null,
"field_label": "Full Name",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Full Name",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000485",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Full_Name",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "jsonobject",
"crypt": null,
"field_label": "Contact Owner",
"tooltip": null,
"created_source": "default",
"field_read_only": true,
"display_label": "Contact Owner",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000437",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Owner",
"unique": {},
"data_type": "ownerlookup",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Email",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Email",
"read_only": false,
"association_details": null,
"quick_sequence_number": "4",
"currency": {},
"id": "529793000000000449",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 100,
"view_type": {
"view": true,
"edit": true,
"quick_create": true,
"create": true
},
"subform": null,
"external": null,
"api_name": "Email",
"unique": {},
"data_type": "email",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Title",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Title",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000453",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 100,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Title",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Phone",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Phone",
"read_only": false,
"association_details": null,
"quick_sequence_number": "5",
"currency": {},
"id": "529793000000000457",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 50,
"view_type": {
"view": true,
"edit": true,
"quick_create": true,
"create": true
},
"subform": null,
"external": null,
"api_name": "Phone",
"unique": {},
"data_type": "phone",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Mobile",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Mobile",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000465",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 30,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Mobile",
"unique": {},
"data_type": "phone",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Home Phone",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Home Phone",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000459",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 30,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Home_Phone",
"unique": {},
"data_type": "phone",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "boolean",
"crypt": null,
"field_label": "Email Opt Out",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Email Opt Out",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000473",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 5,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Email_Opt_Out",
"unique": {},
"data_type": "boolean",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Description",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Description",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000513",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 32000,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Description",
"unique": {},
"data_type": "textarea",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "jsonobject",
"crypt": null,
"field_label": "Created By",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Created By",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000477",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Created_By",
"unique": {},
"data_type": "ownerlookup",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "jsonobject",
"crypt": null,
"field_label": "Modified By",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Modified By",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000479",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Modified_By",
"unique": {},
"data_type": "ownerlookup",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Created Time",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Created Time",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000481",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Created_Time",
"unique": {},
"data_type": "datetime",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Modified Time",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Modified Time",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000483",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Modified_Time",
"unique": {},
"data_type": "datetime",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Last Activity Time",
"tooltip": null,
"created_source": "default",
"field_read_only": true,
"display_label": "Last Activity Time",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000034005",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Last_Activity_Time",
"unique": {},
"data_type": "datetime",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Unsubscribed Mode",
"tooltip": null,
"created_source": "default",
"field_read_only": true,
"display_label": "Unsubscribed Mode",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000378009",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Unsubscribed_Mode",
"unique": {},
"data_type": "picklist",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [
{
"display_value": "Consent form",
"actual_value": "Consent form"
},
{
"display_value": "Manual",
"actual_value": "Manual"
},
{
"display_value": "Unsubscribe link",
"actual_value": "Unsubscribe link"
},
{
"display_value": "Zoho campaigns",
"actual_value": "Zoho campaigns"
}
],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Unsubscribed Time",
"tooltip": null,
"created_source": "default",
"field_read_only": true,
"display_label": "Unsubscribed Time",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000378010",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 120,
"view_type": {
"view": true,
"edit": false,
"quick_create": false,
"create": false
},
"subform": null,
"external": null,
"api_name": "Unsubscribed_Time",
"unique": {},
"data_type": "datetime",
"formula": {},
"decimal_place": null,
"mass_update": false,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Mailing Street",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Mailing Street",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000493",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 250,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Mailing_Street",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Mailing City",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Mailing City",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000497",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 100,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Mailing_City",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Mailing State",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Mailing State",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000501",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 100,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Mailing_State",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Mailing Country",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Mailing Country",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000509",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 100,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Mailing_Country",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
},
{
"system_mandatory": false,
"webhook": true,
"json_type": "string",
"crypt": null,
"field_label": "Mailing Zip",
"tooltip": null,
"created_source": "default",
"field_read_only": false,
"display_label": "Mailing Zip",
"read_only": false,
"association_details": null,
"currency": {},
"id": "529793000000000505",
"custom_field": false,
"lookup": {},
"visible": true,
"length": 30,
"view_type": {
"view": true,
"edit": true,
"quick_create": false,
"create": true
},
"subform": null,
"external": null,
"api_name": "Mailing_Zip",
"unique": {},
"data_type": "text",
"formula": {},
"decimal_place": null,
"mass_update": true,
"multiselectlookup": {},
"pick_list_values": [],
"auto_number": {}
}
]
}