How to obtain debug logs from FDK? Enabling debug mode

The Freshworks Developer Kit (FDK) can be run in debug mode to aid app troubleshooting. Since the FDK simulates the production environment, it is often easier to catch bugs by analyzing the output of the debug mode.

if it is Windows - Powershell

$env:NODE_DEBUG='fdk'; fdk run`


If it is Windows - Command Prompt

set NODE_DEBUG=fdk
fdk run

If it is Mac/Ubuntu/Linux/WSL - Terminal

NODE_DEBUG=fdk fdk run

The debug logs are also automatically saved in the app directory at /logs to troubleshoot the app. Ensure the version of your Freshworks CLI (FDK) is 6.12.0 or greater for the availability of an automatic debug log storage feature.

9 Likes

Is it possible to have an example of adding this to an NPM script?

2 Likes

Interesting, Rob.

Our team is working on a feature where a log file will be generated automatically. I suppose that might lower the need for an npm script to be added in the package.json.

Meanwhile, could you please describe how this can be of help to you? Do you have any system to check the logs occasionally for any thing?

3 Likes