Retrieve Component Record (MDL)
Retrieve metadata of a specific component record as MDL. To retrieve as JSON or XML, see Retrieve Component Record. Vault does not generate RECREATE statements for all component types. For details, see the Generate RECREATE row of the Supported Operations table in the Component Type Reference.
GET
/api/mdl/components/{component_type_and_record_name}Headers
Section link for Headers| Name | Description |
|---|---|
Accept | application/json (default) or application/xml |
URI Path Parameters
Section link for URI Path Parameters| Name | Description |
|---|---|
{component_type_and_record_name} | The component type name (Picklist, Docfield, Doctype, etc.) followed by the name of the record from which to retrieve metadata. The format is {Componenttype}.{record_name}. For example, Picklist.color__c. Find this with the Retrieve Component Record Collection endpoint. |
Request
Section link for Requestcurl -X GET -H "Authorization: {SESSION_ID}" \
https://myvault.veevavault.com/api/mdl/components/Picklist.color__cResponse
Section link for ResponseRECREATE Picklist color__c (
label('Color'),
active(true),
Picklistentry red__c(
value('Red'),
order(1),
active(true)
),
Picklistentry blue__c(
value('Blue'),
order(2),
active(true)
),
Picklistentry green__c(
value('Green'),
order(3),
active(true)
)
);Response Details
Section link for Response DetailsOn SUCCESS, the response contains a RECREATE MDL statement of metadata for the specified component record. Metadata returned varies based on component type. If a field returns as blank, it means the record currently has no value for that field. Execute this RECREATE with the Execute endpoint.