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
| Tech | Version |
|---|---|
| macOS | Sequoia 15.1.1 |
| ServiceNow | Xanadu Patch 3 |
| ServiceNow SDK | 2.2.2 |
| Visual Studio Code | 1.95.3 |
| Node.js | 22.11.0 |
| NPM | 10.9.0 |
Step by Step
- Check if Command Line Developer Tools are installed
- xcode-select -p
- If they are not installed, install them
- xcode-select –install
- Download and install Visual Studio Code
- Launch it once and close it
- Grant full disk access to Visual Studio Code in Settings > Privacy & Security
- Re-launch Visual Studio Code
- Download and install node.js (which includes npm)
- Create a folder for ServiceNow application and open that folder in Visual Studio Code
- Open terminal
- Check versions of node.js and npm:
- node -v
- npm -v
- Install ServiceNow SDK
- npm install –global @servicenow/sdk
- If errors: sudo npm install –global @servicenow/sdk
- Visual Studio Code > Extensions
- Extensions > ServiceNow Fluent Language
- Create authentication alias
- now-sdk auth save justin –type basic –default true
- 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
- Make some changes to your app or add new code / modules like I did in the video (/src/server/justin.js)
- Build your app
- now-sdk build
- Deploy your app
- now-sdk deploy –auth justin
