Skip to content

Retrieve Outbound Package Dependencies

Outbound packages only include configuration details for the included components. Sometimes, a configuration for one component depends on another component which you may not have explicitly specified.

With this API, you can retrieve all outstanding component dependencies for an outbound package. You can then add these missing dependencies to the package with the Create Object Records API.

GET/api/{version}/vobjects/outbound_package__v/{package_id}/dependencies
NameDescription
Acceptapplication/json (default) or application/xml
NameDescription
{package_id}The ID of the outbound_package__v record from which to retrieve dependencies.
curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v26.1/vobjects/outbound_package__v/0PO000000001001/dependencies
{ "responseStatus": "SUCCESS", "responseDetails": { "total_dependencies": 1, "target_vault_id": 1000486, "package_name": "PKG-0001", "package_id": "0PO000000001001", "package_summary": "Outbound Package", "package_description": "Package for deployment", "url": "https://myvault.veevavault.com/api/v26.1/vobjects/package_component__v" }, "package_dependencies": [ { "id": "0CD000000000M70", "name__v": "Product Label", "component_name__v": "product_label__c", "component_type__v": "Object", "referenced_component_name": "product__v", "referenced_component_type": "Object" } ] }
curl -X POST -H "Authorization: {SESSION_ID}" \ --data-raw '[ { "outbound_package__v": "0PO000000001001", "vault_component__v": "0CD000000002810" } ]' \ https://myvault.veevavault.com/api/v26.1/vobjects/package_component__v
{ "responseStatus": "SUCCESS", "data": [ { "responseStatus": "SUCCESS", "data": { "id": "0PO000000001001", "url": "api/v26.1/vobjects/package_component__v/0PO000000001001", "event": "created__sys" } } ] }

On SUCCESS, the response includes the following information:

NameDescription
total_dependenciesThe total number of outstanding component dependencies.
target_vault_idThe ID of the target Vault for the outbound package.
package_nameThe name__v value of the outbound package.
package_idThe ID of the outbound_package__v record with these outstanding dependencies.
urlThe Vault API request to add missing dependencies to this outbound package. Learn more about adding dependencies.
package_dependenciesThis array contains information about each of the total_dependencies. If there are no outstanding dependencies, this array is not returned.

From the url in the response, you can add missing dependencies using the Create Object Records API with the following body parameters:

NameDescription
outbound_package__vThe ID of the outbound_package__v record with these outstanding dependencies. In the retrieve dependencies response body, this is the package_id value.
vault_component__vThe ID of the component to add. This is the value returned for the dependency in the array. In the retrieve dependencies response body, this is the id value of the component within the package_dependencies array.