sndev.io / docs

Environment Setup

Connect to your ServiceNow instance

The CLI reads SN_INSTANCE, SN_USER, and SN_PASS from a .env file in the current directory. This file should never be committed to version control.
Use a sub-production (dev/test) instance for learning. The CLI creates real records on your instance.

Tasks

1

Create a `.env` file with your instance credentials.

cat > .env << 'EOF'
SN_INSTANCE=https://your-instance.service-now.com
SN_USER=admin
SN_PASS=your-password
EOF
2

Test the connection by fetching a system property.

sn get sys_properties "name=glide.servlet.uri" --fields value
[
{ "value": "https://your-instance.service-now.com/" }
]
Next Level
First Schema Query

Explore table structures on your instance