The fix for me was to not deploy as a test, but to actually publish the app, that resolved the issue.
https://community.freshworks.dev/t/platform-error-on-custom-app-when-running-on-server-but-no-error-in-local-dev-environment/11497/5