Watch the video on YouTube: https://youtu.be/xj9kzbJk_S4

In this video I show how to install and setup the ServiceNow (Now) SDK on macOS. And as usual with my videos, this did not go as planned. But it does work and I was able to successfully build and deploy an application back to a ServiceNow instance.

servicenow #nowsdk #vscode #developer #appdevelopment #nodejs #npm #servicenowfluent #macos #xanadu

Versions

TechVersion
macOSSequoia 15.1.1
ServiceNowXanadu Patch 3
ServiceNow SDK2.2.2
Visual Studio Code1.95.3
Node.js22.11.0
NPM10.9.0

Step by Step

  1. Check if Command Line Developer Tools are installed
    • xcode-select -p
  2. If they are not installed, install them
    • xcode-select –install
  3. Download and install Visual Studio Code
  4. Launch it once and close it
  5. Grant full disk access to Visual Studio Code in Settings > Privacy & Security
  6. Re-launch Visual Studio Code
  7. Download and install node.js (which includes npm)
  8. Create a folder for ServiceNow application and open that folder in Visual Studio Code
  9. Open terminal
  10. Check versions of node.js and npm:
    • node -v
    • npm -v
  11. Install ServiceNow SDK
    • npm install –global @servicenow/sdk
    • If errors: sudo npm install –global @servicenow/sdk
  12. Visual Studio Code > Extensions
  13. Extensions > ServiceNow Fluent Language
  14. Create authentication alias
    • now-sdk auth save justin –type basic –default true
  15. Convert application to build locally with ServiceNow SDK
    • now-sdk convert x_417399_justins_h justins-house –auth justin –projectType fluent
    • If you run into issues like I did with the company key (417399), this is the script I used to update the system property sn_appauthor.all_company_keys:
      • gs.setProperty(“sn_appauthor.all_company_keys”,”417399,404613″); // use your keys
  16. Make some changes to your app or add new code / modules like I did in the video (/src/server/justin.js)
  17. Build your app
    • now-sdk build
  18. Deploy your app
    • now-sdk deploy –auth justin