After migrating a Connected App to an External Client App (ECA), the user was unable to save changes to the External Client App. Salesforce returned an error indicating that the Consumer Secret must be at least 32 bytes. The user was attempting to add an Apex Plugin Class to the External Client App, but the update could not be saved because the migrated Connected App had created the External Client App with a Consumer Secret that was shorter than the required 32-byte minimum.
Suggested Workaround
In your Sandbox org, enable the Allow access to External Client App consumer secrets via Metadata API setting before attempting to update the consumer secret of the migrated External Client App.
Retrieve the External Client App metadata in VS Code using a package.xml that includes the following metadata types:
ExternalClientApplication
ExtlClntAppOauthSettings
ExtlClntAppGlobalOauthSettings
ExtlClntAppOauthConfigurablePolicies
ExtlClntAppConfigurablePolicies
Sample of package.xml
<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
<types>
<members>ecaViaMetadata</members>
<name>ExternalClientApplication</name>
</types>
<types>
<members>*</members>
<name>ExtlClntAppOauthSettings</name>
</types>
<types>
<members>*</members>
<name>ExtlClntAppGlobalOauthSettings</name>
</types>
<types>
<members>*</members>
<name>ExtlClntAppOauthConfigurablePolicies</name>
</types>
<types>
<members>*</members>
<name>ExtlClntAppConfigurablePolicies</name>
</types>
<version>60.0</version>
</Package>
In the ExtlClntAppGlobalOauthSettings metadata, update the Consumer Secret to a value longer than 32 bytes and set the shouldRotateConsumerSecret tag to true.
Deploy the updated metadata using the following command:
sf project deploy start --metadata ExtlClntAppGlobalOauthSettings --target-org <target-org> --ignore-warnings
After the deployment completes, verify that the Consumer Secret has been updated successfully. Then, try adding the Apex plugin to the External Client App again.
If the workaround is successful in the Sandbox, you can repeat the same steps in your Production org.
https://help.salesforce.com/s/articleView?id=xcloud.branded_apps_eca_migration.htm&type=5
https://help.salesforce.com/s/articleView?id=005228017&type=1
005388151

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.