TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/trailheadapps/lwc-recipes/llms.txt
Use this file to discover all available pages before exploring further.
getObjectInfo wire adapter retrieves metadata about a Salesforce object, including fields, record types, and child relationships.
Import
Parameters
The API name of the object to retrieve metadata for. Use
$ prefix for reactive properties.Basic Usage
Reactive Parameters
Use the$ prefix to make the object API name reactive:
objectApiName changes.
Using Schema References
Import object references from@salesforce/schema:
Response Data
The object info includes:- apiName - Object API name
- label - Object display label
- labelPlural - Plural label
- fields - Map of field metadata
- recordTypeInfos - Available record types
- childRelationships - Child object relationships
- themeInfo - UI theme information
Accessing Field Metadata
Source Examples
wireGetObjectInfo- Dynamic object metadata retrieval
