Get Related Records API

This API will retrieve records based on lookup Record ID.

Request URL:

https://people.zoho.com/api/forms/exitinterview/getRelatedRecords?id=759415000000240001&parentModule=employee

Header:

Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxx9be93.9b8xxxxxxf

Scope:

ZOHOPEOPLE.forms.READ

Possible Operation Types:

READ - Read form data

Request Parameters:

PARAMETERSVALUES ALLOWEDDEFAULT VALUEPARAMETER DESCRIPTIONMANDATORY
formLinkName -To get formLinkName, you can use Fetch Forms API.Yes
slindex 1Starting indexNo
limit 200Number of records to be fetchedNo
parentModule -Related records to the parent module will be fetchedYes
id -Get related records based on record idYes
lookupfieldName -Records will be retrieved related to this lookup fieldNo

Note: If lookupfieldName is not given, primary lookup of the form will be taken as input.

Common Error Codes and Descriptions

ERROR CODEERROR DESCRIPTION
7011Form name '<formlinkname>' is invalid
7024No records found
7013Field name '<param value>' is invalid
7021Maximum record limit 200 is exceeded

Threshold Limit: 30 requests | Lock period: 5 minutes

Threshold Limit - Number of API calls allowed within a minute.
Lock Period - Wait time before consecutive API requests.

Sample Request

Copiedhttps://people.zoho.com/people/api/forms/employee/getRelatedRecords?parentModule=department&id=3000000032001

Sample Response

Copied{
    "response": {
        "result": [
            {
                "759415000001349009": [
                    {
                        "BooksSubmitted": "",
                        "CreatedTime": "1748320506467",
                        "AddedTime": "27-May-2025 10:05:06",
                        "Clearance": "",
                        "Security": "",
                        "ModifiedBy": "Jane Doe",
                        "NoticePeriod": "",
                        "ApprovalStatus": "Approval Not Enabled",
                        "StaffFWelfare": "",
                        "ModifiedTime": "1748320506467",
                        "LikedMost": "",
                        "Zoho_ID": 759415000001349009,
                        "CompanyVehicle": "",
                        "Resignation": "",
                        "AddedBy": "HRM13 - Navin 01 - 01",
                        "AllEquipments": "",
                        "SeparationDate": "31-May-2025",
                        "ReasonForLeaving.id": "759415000000040023",
                        "EmployeeID.ID": "759415000000240001",
                        "ReasonForLeaving": "Retirement",
                        "ModifiedBy.ID": "759415000000240001",
                        "Interviewer.ID": "759415000000240001",
                        "Interviewer": "Jane Doe",
                        "AddedBy.ID": "759415000000240001",
                        "ExitInterview": "",
                        "ShareWithus": "",
                        "EmployeeID": "HRM02",
                        "WorkingForThisOrganizationAgain": ""
                    }
                ]
            }
        ],
        "message": "Data fetched successfully",
        "uri": "/api/forms/exitinterview/getRelatedRecords",
        "status": 0
    }
}
CopiedOkHttpClient client = new OkHttpClient().newBuilder()
  .build();
MediaType mediaType = MediaType.parse("application/json");
Request request = new Request.Builder()
  .url("https://people.zoho.com/api/forms/exitinterview/getRelatedRecords?id=759415000000240001&parentModule=employee")
  .get()
  .addHeader("Content-Type", "application/json")
  .addHeader("Authorization", "••••••")
  .addHeader("Cookie", "CSRF_TOKEN=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zcsr_tmp=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zpsid=C9B0C2739FAE8B31975D2F7745237EFA; zalb_c7cb34e6ac=15579241ea20d8d7fa5eb5f3fb79c37a")
  .build();
Response response = client.newCall(request).execute();
Copiedconst myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");
myHeaders.append("Authorization", "••••••");
myHeaders.append("Cookie", "CSRF_TOKEN=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zcsr_tmp=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zpsid=C9B0C2739FAE8B31975D2F7745237EFA; zalb_c7cb34e6ac=15579241ea20d8d7fa5eb5f3fb79c37a");

const raw = JSON.stringify({});

const requestOptions = {
  method: "GET",
  headers: myHeaders,
  body: raw,
  redirect: "follow"
};

fetch("https://people.zoho.com/api/forms/exitinterview/getRelatedRecords?id=759415000000240001&parentModule=employee", requestOptions)
  .then((response) => response.text())
  .then((result) => console.log(result))
  .catch((error) => console.error(error));
Copiedcurl --location --request GET 'https://people.zoho.com/api/forms/exitinterview/getRelatedRecords?id=759415000000240001&parentModule=employee' \
--header 'Content-Type: application/json' \
--header 'Authorization: ••••••' \
--header 'Cookie: CSRF_TOKEN=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zcsr_tmp=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zpsid=C9B0C2739FAE8B31975D2F7745237EFA; zalb_c7cb34e6ac=15579241ea20d8d7fa5eb5f3fb79c37a' \
--data '{
    
}'
CopiedinputMap = Map();
inputMap.put("id","759415000000240001");
inputMap.put("parentModule","employee");
AuthMap = Collection();
AuthMap.insert("Authorization":"••••••");

response = invokeUrl
[
 	url: "https://people.zoho.com/api/forms/exitinterview/getRelatedRecords"
 	type: GET
 	parameters: inputMap
 	headers: AuthMap.toMap()
];
info response;
Copiedimport requests
import json

url = "https://people.zoho.com/api/forms/exitinterview/getRelatedRecords?id=759415000000240001&parentModule=employee"

payload = json.dumps({})
headers = {
  'Content-Type': 'application/json',
  'Authorization': '••••••',
  'Cookie': 'CSRF_TOKEN=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zcsr_tmp=790891fd-6d6f-40fd-8381-8e81176e2d2f; _zpsid=C9B0C2739FAE8B31975D2F7745237EFA; zalb_c7cb34e6ac=15579241ea20d8d7fa5eb5f3fb79c37a'
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)