**Source URL:** https://limited.veevavault.dev/clinical/vault-api/api-reference/19.1/configuration-migration/vault-compare.md

# Vault Compare



Compare the configuration of two different Vaults. The Vault you make the request in is the source Vault, and the target Vault for the comparison is listed in the body. Learn more about [Vault Compare in Vault Help](https://platform.veevavault.help/en/lr/40902).

The user who makes the request must be a cross-domain user and must have access to the `vault_component__v` in both Vaults. Learn more about [cross-domain users in Vault Help](https://platform.veevavault.help/en/lr/38996).

<Endpoint path="/api/{version}/objects/vault/actions/compare" method="POST"></Endpoint>

## Headers {#headers}

<FieldTable>
| Name | Description |
| --- | --- |
| `Content-Type` | `application/json` (default) or `application/x-www-form-urlencoded` |
</FieldTable>

## Body Parameters {#body-parameters}

<FieldTable>
| Name | Description |
| --- | --- |
| `vault_id` | The target Vault `id` for the the comparison. |
| `results_type` | Optional: To include all configuration values, set this to `complete`. To only see the differences between Vaults, set to `differences`. If omitted, this defaults to `differences`. |
| `details_type` | Optional: To show component level details only, set to `none`. To include simple attribute-level details, set to `simple`. To show all attribute-level details, set to `complex`. If omitted, this defaults to `simple`. |
| `component_types` | Optional: Add a comma separated list of component types to include. For example, `Doclifecycle, Doctype, Workflow`. If omitted, this defaults to include all components. |
</FieldTable>

## Request {#request}

<CodeExample title="">
```
Curl -X POST -H "Authorization: {SESSION_ID}" \
- H "Content-Type: application/x-www-form-urlencoded" \
- d "vault_id=1234" \
- d "results_type=Complete" \
https://myveevavault.com/api/v17.2/objects/vault/actions/compare


```
</CodeExample>

## Response {#response}

<CodeExample title="">
```
{
  "responseStatus": "SUCCESS",
  "job_id": 16202,
  "url": "/api/v17.2/services/jobs/16202"
}

```
</CodeExample>

## Response Details {#response-details}

On SUCCESS, Vault returns the `job_id` of the comparison job. You can then [Retrieve the Job Status](/vault-api/api-reference/19.1/jobs). Once complete, you will receive an email with a download link to an Excel file of the comparison.



---

**Previous:** [Retrieve Package Deploy Results](/clinical/vault-api/api-reference/19.1/configuration-migration/retrieve-package-deploy-results)  
**Next:** [Vault Configuration Report](/clinical/vault-api/api-reference/19.1/configuration-migration/vault-configuration-report)