Pre-Deployment Checklist
Before runningnpx @deploxy/cli deploy, ensure your project is ready for publishing. Deploxy deploys your project as-is, so it must be fully built and configured correctly.
- Project is Built: You must run your build command (e.g.,
npm run buildortsc) to compile your code before deploying. Deploxy does not run your build script. It only installs production dependencies (e.g.,npm install --production) on the server. package.jsonis Correct:- The
nameandversionare set for publishing to NPM. - The
mainfield points to the entry file of your built code (e.g.,dist/index.js). - The
filesarray includes your build output directory (e.g.,["dist"]). This ensures your compiled code is included in the deployment.
- The
- Dependencies are Production-Ready: Your
dependenciesshould contain only what’s needed to run your server in production. Build tools liketypescript,eslint, and bundlers should be indevDependencies.
Think of
npx @deploxy/cli deploy as a direct replacement for npm publish. Just as you would build your project before publishing to NPM, you must build your project before deploying with Deploxy.Deployment Issues
These issues occur when running thenpx @deploxy/cli deploy command.
Deployment Fails with “Unauthorized”
Symptom: The deploy command fails with a401 Unauthorized error.
Solution:
- Verify
authToken: Ensure theauthTokenin your.deploxy.jsonis correct and has not expired. - Regenerate Token: Go to the Tokens page on your dashboard, generate a new token, and update your configuration file.
- Check for Typos: Make sure there are no extra spaces or characters in the token string.
Deployment Fails Due to Missing Files or Entry Point Error
Symptom: The deployment fails, and the logs on the Deploxy dashboard indicate that the entry point specified inpackage.json could not be found, or other necessary files are missing.
Solution:
This almost always means your project was not built before deployment, or your package.json is not configured to include the built files.
- Build Your Project: Run your project’s build script locally (e.g.,
npm run build). - Check
package.jsonmainfield: Themainfield must point to the main file of your compiled output, not your source TypeScript or JavaScript file.package.json - Check
package.jsonfilesfield: Thefilesarray tells Deploxy which files and folders to include in the deployment. It must include your build output directory.package.json
Deployment Package Too Large
Symptom: The deployment fails with a message related to the package size limit. Solution: The total unzipped size of your project, includingnode_modules, must be under 250MB.
- Check
devDependencies: Ensure that build-time tools (liketypescript,@types/*,eslint, bundlers) are indevDependenciesand notdependencies. Onlydependenciesare installed on the server. - Analyze Dependencies: Use a tool like
npm-whyoryarn whyto find and remove unnecessary packages from yourdependencies. - Prune
devDependencieslocally: Before deploying, you can simulate a production install to see the true size of yournode_modules. Create a temporary directory, copy yourpackage.jsonandpackage-lock.jsoninto it, and runnpm install --production.
NPM Publishing Fails
Symptom: The deployment process succeeds until the “Publishing to NPM…” step. Solution:- Check NPM Authentication: Ensure your
.npmrcfile is present in the project root and contains a valid NPM token with publish permissions. TheNPM_TOKENenvironment variable must be available in your shell. - Check Package Version: NPM requires a unique version for every publish. Before deploying, you must increment the
versionin yourpackage.json. - Check Package Name: Ensure the
namein yourpackage.jsonis available on NPM and that you have permission to publish to that scope (e.g.,@your-username/my-package).
Runtime Issues
These issues occur after your MCP server has been successfully deployed.Server Not Responding or Timing Out
Symptom: Your deployed MCP server does not respond to requests, or requests time out. Solution:- Check Runtime Logs: This is the most critical step. Go to your project’s Logs tab on the Deploxy Dashboard to see real-time logs from your server. Look for any startup errors or exceptions.
- Verify Environment Variables: A missing or incorrect
injectedEnvvariable is a common cause of runtime failure. Go to your project’s Settings tab to verify the environment variables for each region. Remember that any changes require a new deployment to take effect. - Run a Health Check: Use the health check feature on the Settings tab to confirm your serverless function is live.
Environment Variables are undefined
Symptom: Your server crashes because process.env.MY_VARIABLE is undefined.
Solution:
- Check
.deploxy.json: Verify that the variable is defined in theinjectedEnvsection and that its value is a string. - Redeploy: Your server only receives new
injectedEnvvalues after you runnpx @deploxy/cli deployagain.
Getting Help
If you’re still stuck, we’re here to help.- Community Support: Join our Discord Community for help from the community and the Deploxy team.
- GitHub Issues: If you believe you’ve found a bug in the CLI or platform, please open an issue on our GitHub repository.
- The command you ran.
- The full output from the CLI (with any secrets redacted).
- Your (redacted)
.deploxy.jsonandpackage.jsonfiles. - Relevant snippets from your server code.

