Skip to content

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}
NameDescription
Acceptapplication/json (default) or application/xml
NameDescription
{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.
curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/mdl/components/Picklist.color__c
RECREATE 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) ) );

On 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.