# Metadata API and Tooling API deployment behaviour

*Platform Development Lifecycle and Deployment Architect Study Guide · Deploying · Last updated October 26, 2026 · https://www.certifyforce.com/study-guide/platform-development-lifecycle-and-deployment-architect/deploying/metadata-api-and-tooling-api-deployment-behaviour*

What Metadata API and Tooling API each do in a deployment pipeline: payload limits, rollback and validation, quick deploy, the one-at-a-time deployment queue and cancellation, deploy permissions, source-tracked versus manifest deploys, and what a retrieve really returns.

- Certification: Salesforce Platform Development Lifecycle and Deployment Architect
- Exam section: Deploying
- Study guide: https://www.certifyforce.com/study-guide/platform-development-lifecycle-and-deployment-architect

**Official exam objective:**

> Given a scenario, describe the capabilities, limitations and considerations when using the Metadata and Tooling APIs for deployment.

## What the exam expects

- Choose Metadata API or Tooling API for a deployment, tooling or reporting requirement, and recognise when neither applies because the requirement is about records.
- Pick source-tracked or manifest-based deploys for each pipeline stage, knowing production never tracks source.
- Predict how payload size, rollbackOnError, `--ignore-errors`, validation, quick deploy and the default test behaviour shape a release.
- Explain the deployment queue and when cancelling still works; set least-privilege deploy permissions; predict what a profile or wildcard retrieve returns.

Key terms: **metadata component** (an instance of a metadata type, such as one custom tab), **validation** (a check-only deployment that runs tests but commits nothing), **quick deploy** (deploying a recent passing validation without rerunning tests), **MetadataContainer** (a Tooling API container of working copies such as ApexClassMember), **source tracking** (the CLI's record of changes between a project and an org).

## Key facts

| Fact | Detail | Source |
|---|---|---|
| Payload limits | About 39 MB compressed, 50 MB after base-64, about 600 MB uncompressed | [deploy()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy.htm) |
| Deploy permission | Modify Metadata Through Metadata API Functions or Modify All Data | [deploy()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy.htm) |
| Production rollback | rollbackOnError must be true; never `--ignore-errors` | [deploy()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy.htm), [project deploy start (CLI command reference)](https://developer.salesforce.com/docs/platform/salesforce-cli-reference/guide/cli_reference_project_deploy_start.html) |
| Concurrency | One deployment runs at a time; queue order not guaranteed | [deploy()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy.htm) |
| Quick deploy window | Validation passed for the same target within the last 10 days | [deployRecentValidation()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deployRecentValidation.htm) |
| No test level, no Apex | No tests run in production from API 34.0 | [Running Tests in a Deployment](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy_running_tests.htm) |
| Source tracking | Never allowed in production; select components with a manifest, directory or metadata list | [project deploy start (CLI command reference)](https://developer.salesforce.com/docs/platform/salesforce-cli-reference/guide/cli_reference_project_deploy_start.html) |
| Dependency API | Beta; Tooling API 2,000 records, no reports; Bulk API 2.0 100,000 | [MetadataComponentDependency (Beta)](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/tooling_api_objects_metadatacomponentdependency.htm) |
| Wildcard retrieve | Excludes standard objects and managed package components | [Sample package.xml Manifest Files](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/manifest_samples.htm) |

## Check yourself

- Why can a release with large binary static resources fail the size check well below 600 MB uncompressed?
- When does a passing validation stop qualifying for quick deploy?
- Why might a profile deployed from source leave a permission enabled that the file no longer grants?
- Which coverage rule must a validation meet for quick deploy when it ran RunSpecifiedTests?

## Sources

- [Understanding Metadata API](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_intro.htm)
- [deploy()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy.htm)
- [When to Use Tooling API](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/intro_tasks.htm)
- [Introducing Tooling API](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/intro_api_tooling.htm)
- [project deploy start (CLI command reference)](https://developer.salesforce.com/docs/platform/salesforce-cli-reference/guide/cli_reference_project_deploy_start.html)
- [Running Tests in a Deployment](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deploy_running_tests.htm)
- [deployRecentValidation()](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_deployRecentValidation.htm)
- [ContainerAsyncRequest](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/tooling_api_objects_containerasyncrequest.htm)
- [MetadataComponentDependency (Beta)](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/tooling_api_objects_metadatacomponentdependency.htm)
- [Profile](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_profile.htm)
- [Sample package.xml Manifest Files](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/manifest_samples.htm)
- [Enable Source Tracking in Sandboxes](https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_setup_enable_source_tracking_sandboxes.htm)

## About the full unit

The "Core concepts", "Exam traps" and "Worked scenario" sections of this unit, its 15 linked practice questions, and unlimited timed mock exams are included with the Platform Development Lifecycle and Deployment Architect pack (USD $19): https://www.certifyforce.com/practice-exams
