**Source URL:** https://limited.veevavault.dev/quality/vault-api/api-reference/26.2/configuration-migration/validate-package.md

# Validate Package



Validate a VPK package attached to this request. The validation response will include the same information on dependent components as [validation logs](https://platform.veevavault.help/en/lr/36919#validation-logs) generated through the UI.

For packages that include Vault Java SDK code, this operation recompiles source code against the target Vault's libraries and dependencies and checks for compilation errors and restrictions. For example, `new` is not allowed for non-allowlisted classes. When compilation errors are detected, Vault assigns the code step a status of *Blocked*. Learn more about [Vault Java SDK limits and restrictions](/vault-sdk/references/limits-restrictions).

This endpoint does not import your package.

<Endpoint path="/api/{version}/services/package/actions/validate" method="POST"></Endpoint>

## Headers {#headers}

<FieldTable>
| Name | Description |
| --- | --- |
| `Accept` | `application/json` (default) |
</FieldTable>

## Body Parameters {#body-parameters}

To upload the VPK file, use the multi-part attachment with the file component `”file={filename}”`. The maximum allowed file size is 2GB.

## Request {#request}

<CodeExample title="">
```
curl -L -X POST  -H 'Authorization: {Session_ID}' \
-H 'Accept: application/json' \
-F 'file=myFile`.vpk`' \
https://myvault.veevavault.com/api/v20.2/services/package/actions/validate

```
</CodeExample>

## Response {#response}

<CodeExample title="">
```
{
    "responseStatus": "SUCCESS",
    "responseDetails": {
        "summary": "Auto Claims Linking Config",
        "author": "jennie@veepharm.com",
        "package_name": "PKG-0004-2",
        "package_id": "N/A",
        "source_vault": "51577",
        "package_status": "Blocked",
        "total_steps": 4,
        "total_steps_blocked": 1,
        "total_component_steps_blocked": 1,
        "total_data_steps_blocked": 0,
        "total_code_steps_blocked": 0,
        "start_time": "07:05:2020 06:24:15",
        "end_time": "07:05:2020 06:24:15",
        "package_error": "",
        "package_steps": [
            {
                "name__v": "00010",
                "step_type__v": "Component",
                "step_name__v": "annotation_keyword_targets__sys",
                "type__v": "Object",
                "deployment_status__v": "Verified",
                "deployment_action": "Update",
                "dependencies": [
                    {
                        "component_name": "annotation_keyword_targets__sys.base__v",
                        "component_type": "Objecttype",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "In Target"
                    },
                    {
                        "component_name": "default_status__v",
                        "component_type": "Picklist",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "In Target"
                    }
                ]
            },
            {
                "name__v": "00020",
                "step_type__v": "Component",
                "step_label__v": "Claims Document",
                "step_name__v": "claims_document__c",
                "type__v": "Doctype",
                "deployment_status__v": "Blocked",
                "deployment_action": "Add (missing in Vault)",
                "dependencies": [
                    {
                        "component_name": "document_creation_date__v",
                        "component_type": "Docfield",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "In Target"
                    },
                    {
                        "component_name": "reference_documents__c",
                        "component_type": "Doclifecycle",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "In Target"
                    },
                    {
                        "component_name": "product__v",
                        "component_type": "Docfield",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "In Target"
                    },
                    {
                        "component_name": "air_bulk_03__c",
                        "component_type": "Renditiontype",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "Missing - Block"
                    },
                    {
                        "component_name": "country__v",
                        "component_type": "Docfield",
                        "subcomponent_name": "",
                        "subcomponent_type": "",
                        "status": "In Target"
                    }
                ]
            },
            {
                "id": "0IS000000002003",
                "name__v": "00030",
                "step_type__v": "Code",
                "step_label__v": "Vault Java SDK Code",
                "step_name__v": "Vault Java SDK Code",
                "type__v": "Code",
                "deployment_status__v": "Verified",
                "deployment_action": "Incremental",
                "validation_response": "SUCCESS",
                "validation_message": "Source code in (SDK-HELLO-WORLD) validated successfully."
            },
            {
                "id": "0IS000000001002",
                "name__v": "00040",
                "step_type__v": "Data",
                "step_label__v": "DSET-00001-marketing_campaign__c",
                "step_name__v": "marketing_campaign__c",
                "type__v": "Object",
                "deployment_status__v": "Verified",
                "deployment_action": "Create (add 5 records)",
                "record_migration_mode__sys": false,
                "include_object_record_attachments__sys": false
            }
        ]
    }
}

```
</CodeExample>

## Response Details {#response-details}

On `SUCCESS`, the response includes the following information about the VPK package:

<FieldTable>
| Name | Description |
| --- | --- |
| `summary` | The summary of the package. |
| `author` | The user who created the package. |
| `package_name` | The `name__v` value of the package. |
| `package_id` | This value is `N/A` because the package is not yet imported into Vault. |
| `source_vault` | The ID of the source Vault where the package originated. |
| `package_status` | The status of the package. For example, `Verified` or `Blocked`. |
| `total_steps` | The total number of package steps. |
| `total_steps_blocked` | The total number of package steps that have a status of *Blocked*. |
| `total_component_steps_blocked` | The total number of component steps that have a status of *Blocked*. |
| `total_data_steps_blocked` | The total number of data steps that have a status of *Blocked*. |
| `total_code_steps_blocked` | The total number of code steps that have a status of *Blocked*. |
| `package_steps` | This array contains information about each of the package steps. |
</FieldTable>
The response includes additional information about each step depending on whether the step type is `Component`, `Code`, or `Data`. For example, a code step includes a `validation_message` verifying the code, or a `validation_error` message if code fails to compile correctly.



---

**Previous:** [Vault Configuration Report](/quality/vault-api/api-reference/26.2/configuration-migration/vault-configuration-report)  
**Next:** [Validate Inbound Package](/quality/vault-api/api-reference/26.2/configuration-migration/validate-inbound-package)