Object Info Response Body Includes Child Relationships

The Object Info response body, which contains an object’s metadata, has a new childRelationships property, which is a collection of the object’s child relationships. Relationships are connections between records. Use relationships to display data about related object records on a record’s detail page.
The Child Relationship response body contains these properties:
Property Name Type Description Filter Group and Version Available Version
childObjectApiName String The API name of the child object that contains the reference to the parent object. Medium, 40.0 40.0
fieldName String The field on the child object that contains the reference to the parent object.

Instead of defining relationships through primary keys and foreign keys, the Salesforce database uses relationship fields. A relationship field is a custom field that stores the ID of the related parent record.

Medium, 40.0 40.0
junctionIdListNames String[] A collection of fields of the type JunctionIdList. A JunctionIdList is a string array of referenced ID values that represent the many-to-many relationship of an underlying junction entity.

Each ID in a JunctionIdList is a polymorphic key, which is an ID that can refer to more than one type of object.

Medium, 40.0 40.0
junctionReferenceTo String[] A collection of object names that the polymorphic keys in the junctionIdListNames property can reference.

You can query these object names.

Medium, 40.0 40.0
relationshipName String The name of the relationship.

A name for the child relationship that is unique to the parent. The name is the plural form of the child object name. For example, Account has child relationships to Assets, Cases, and Contacts, among other objects. Account has a relationshipName for each object: Assets, Cases, and Contacts.

Medium, 40.0 40.0
Requests to these resources return a nested Child Relationship:
  • /ui-api/record-ui/{recordIds}
  • /ui-api/object-info/{objectApiName}
  • /ui-api/record-defaults/clone/{recordId}
  • /ui-api/record-defaults/create/{objectApiName}