Package the External Client App for Canvas
After you created the canvas app, tested it in the Canvas App Previewer, and deployed it
to Heroku, you’re ready to package and distribute it.
Package an external client app for your canvas integration by creating a second-generation managed package (managed 2GP) using Salesforce CLI commands from a Salesforce DX project.
- Configure default settings for a packaged external client. The default values display in the policies tab on a distributed external client app and can be edited by admins.
- Enable a Dev Hub org with a namespace prefix. The Dev hub org becomes the owner of your managed 2GP. A namespace is assigned to the package at the time that it’s created, and can’t be changed.
- Configure a Salesforce DX project for external client apps. With a Salesforce DX project, you use command-line interface (CLI) commands to work with your Salesforce org.
- Create a 2GP managed package using CLI commands. You can also create versions of the package to manage your changes and track what’s different each time you release or deploy.
- Install a managed 2GP in a scratch org to test the package. You can install or uninstall a managed 2GP using a Salesforce CLI command, or from the Setup page.
- Distribute and release the managed 2GP. A new managed 2GP version is marked as beta when you create it. You can create multiple versions before creating a version that’s ready to be released and distributed.
You can configure the canvas settings before or after creating the external client app.
After the canvas setting is created, it can only be disabled or enabled. The canvas setting
can’t be deleted from Setup. However, you can delete the setting from the package.