Skip to main content

Resolving validation errors - "Not available for deploy for this API version" on GenAiPlanner metadata type

Cause and solution to this Salesforce validation error surfaced on GenAiPlanner metadata type

Mateusz Kochanowicz avatar
Written by Mateusz Kochanowicz
Updated this week

Error overview

You may run into this validation error "Not available for deploy for this API version", when deploying an agent (via GenAiPlanner metadata) while running your Gearset comparison (or a CI job) on API version 64 or above.

An example of the error message in our app would look as below.
​

Explanation of the error

It's important to note that GenAiPlanner metadata is available for deployments only on API versions from 60 to version 63.

You won't be able to deploy it when your Gearset comparison, or a CI job is configured to run on API v64 or higher.
​
Take a look at our documentation on:

Both of the articles explain that GenAiPlanner was released by Salesforce and is supported in versions 60-63. However, from API v64 GenAiPlanner is actually replaced by a new metadata type called GenAIPlannerBundle.

Resolution

For deployments made via Compare and deploy

Are you making a simple org t org (or branch to org) deployment?

You'd need to amend the API version used in your comparison. Make sure you're using API version between 60 to 63, and then re-validate your deployment package.

Detailed guidelines on how to amend the API version your comparisons uses are in this documentation.

For deployments made via Gearset Pipelines

Is your PR failing the validation in the Gearset Pipeline?

Follow below steps to fix the issue:

  • Navigate to the CI jobs page in our app, find the CI job in question, select Edit settings > Metadata filters, and follow these instructions to amend the API version to one between 60-63.

  • This ensures that your CI job won't be using API version higher than 63 to validate your PR against the target org.

  • Once done, you can re-validate your PR in the Pipeline.

  • After the PR has been merged and the CI job deployed GenAiPlanner metadata to the org, you can amend the CI job setting back to its previous API configuration (if needed).

Disclaimer: This error is returned by Salesforce directly, rather than Gearset. Even so, we offer guidance based on our combined experience with the Metadata API. Where possible, we try to help guide you to fix or avoid this error. In the case that this isn't possible, we may need to direct you to Salesforce support for further clarification.

Did this answer your question?