Troubleshooting
Use the following solutions to resolve common issues with App Management.
Configuration validation errors
app.commerce.config is validated against its schema every time the config is loaded. This happens during the postinstall and pre-app-build hooks, and whenever you run an npx aio-commerce-lib-app generate … command manually. If validation fails, check:
Required properties. Fields must have
name,label, andtype.Type-matched defaults. Default values must match the field type.
Valid metadata. App metadata must include
id,displayName,description, andversion.
App not appearing in App Management
Verify app is deployed:
Copied to your clipboardaio app get-url# Only if you don't see listed the `app-management` actionsaio app deploy --force-build --force-deployCheck runtime actions are generated in
.generatedfolders.Ensure your commerce app configuration is valid.
Verify correct organization in Developer Console.
Runtime actions
Code generation is a mandatory step for App Management to work. The pre-app-build hook only regenerates the commerce app manifest (a snapshot of your config), and the configuration schema, so runtime actions must be generated manually with the following command (idempotent):
Copied to your clipboardnpx aio-commerce-lib-app generate all
Copied to your clipboardyarn exec aio-commerce-lib-app generate all
Copied to your clipboardpnpm exec aio-commerce-lib-app generate all
Copied to your clipboardbun x aio-commerce-lib-app generate all
Encryption key errors
Generate an encryption key
Ensure your encryption key is present in the .env by running the command below. It only creates a new key if one does not already exist.
Copied to your clipboardnpx aio-commerce-lib-config encryption setup
Copied to your clipboardyarn exec aio-commerce-lib-config encryption setup
Copied to your clipboardpnpm exec aio-commerce-lib-config encryption setup
Copied to your clipboardbun x aio-commerce-lib-config encryption setup
Validate your encryption key configuration.
If it's already there, validate it has the expected format:
Copied to your clipboardnpx aio-commerce-lib-config encryption validate
Copied to your clipboardyarn exec aio-commerce-lib-config encryption validate
Copied to your clipboardpnpm exec aio-commerce-lib-config encryption validate
Copied to your clipboardbun x aio-commerce-lib-config encryption validate

