Twenty CRM icon

Twenty CRM

Interact with Twenty CRM - Open Source CRM

Custom Object → Get

AI-generated

Summary

Retrieve a single record of a specified custom object from Twenty CRM by its record ID, optionally including related records up to a specified depth.

Inputs

  • Object API Name (required) — The plural API name of the custom object to query (e.g., "customLeads", "myCustomObject"). You can find this in Twenty CRM Settings > Data Model > Your Object > API Name.
  • Record ID (required) — The unique ID of the custom object record to retrieve.
  • Options — Optional parameters including 'Depth' which controls how many levels of related records to include in the response, with a range of 0 to 2. Default is 1.

Output shape

a single object representing the requested custom object record, including specified depths of related records.

The response includes related objects embedded up to the 'Depth' level as specified by the option. If depth is 0, no related records are included. The operation throws an error if the record ID does not exist or if the API request fails.

Examples

Example 1: Get a custom object record named 'customLeads' with ID '12345', including relations one level deep.

Set Object API Name to 'customLeads', Record ID to '12345', and Depth option to 1.

Links

Discussion