Agent-first, agent-native
A CLI for exploring and managing ServiceNow instances. Works standalone or with any AI agent (Claude, Codex, Cursor, etc.).
# Install in seconds
curl -fsSL https://raw.githubusercontent.com/jacebenson/jsn/main/scripts/install.sh | bashjsn setup # Interactive first-time setup
jsn tables list # List all tables
jsn tables schema incident # Show incident table schema
jsn records list incident # List incident records
jsn rules list --table incident # Show business rulesI've been working with ServiceNow for years and trying to use tools that actually, you know, work. The Table API is "fine"—except these APIs were designed for systems integration, not for humans (or agents) trying to understand their instance.
If we want real innovation in this space, we have to stop hiding tools behind enterprise licensing agreements and convoluted setup processes. This is my attempt to build the CLI I actually want to use — and that my AI agent can use to help me.
ServiceNow's "Official" CLI – Last meaningful update: 2 years ago. Requires you to install a server-side application on your instance just to use it. Abandoned before it ever really lived.
ServiceNow Fluent SDK – Follow the link rabbit hole and you eventually hit the docs. I actually tried to use this. For YEARS this thing had dependency issues that made it break on different operating systems.
Then I spent a day migrating a global scope app to a "proper" scoped app using Fluent, only to discover it made everything WORSE. Why? Because once you ship an import, you can only fix it through the SDK—not in the instance UI. Oh, and the auth configuration? Completely baffling.
Before the SDK killed them (for scoped apps only), we had file syncers. Mostly VS Code extensions that have all rotted away:
- sn-filesync – Last updated 7 years ago
- codesync – Last updated 9 years ago
- now-sync – Last updated 6 years ago
Today there's basically one survivor: SNICH by Nate Anderson—and it's VS Code only.
Every tool either:
- Requires proprietary server-side components
- Locks you into specific IDEs or workflows
- Dies from complexity and maintenance burden
- Forces you to abandon the ServiceNow UI entirely
I'm tired of it.
Not "deploy a scoped app" useful—"explore and understand your instance" useful. The kind of tool that answers questions like:
- "What business rules fire on the Incident table?"
- "What flows are currently active?"
- "Show me the schema of this table without clicking through 12 UI screens"
One binary. No server-side plugins. No dependency hell. No auth configuration that requires a PhD.
Global scope? Scoped apps? Direct instance editing? Yes. I'm not forcing you to choose between the CLI and the ServiceNow UI. Use both. Fix things wherever it's faster.
This CLI is designed to be agent-native. Your AI assistant can:
- Explore: List tables, schemas, business rules, flows — understand your instance structure
- Query: Fetch records, analyze data patterns, check configurations
- Verify: Confirm changes, check dependencies, validate before deploying
- Document: Generate reports on instance configuration, security policies, automation logic
The command structure is predictable and machine-readable. JSON output available for everything.
Other installation methods
Go install:
go install github.com/jacebenson/jsn/cmd/jsn@latestGitHub Release: Download from Releases.
From source:
git clone https://github.com/jacebenson/jsn.git
cd jsn
go build -o jsn ./cmd/jsn/main.go# Explore your instance
jsn tables list # List all tables
jsn tables schema incident # Show table inheritance
jsn tables columns incident # Show all columns
# Query records
jsn records list incident # List records
jsn records list incident --query "priority=1" # Filter with encoded query
jsn records show incident <sys_id> # Show specific record
# Manage data
jsn records create incident --field short_description="Server down"
jsn records update incident <sys_id> --field priority=1
jsn records delete incident <sys_id> --force
# Business logic
jsn rules list --table incident # List business rules
jsn flows list # List flows
jsn script-includes list # List script includes
# Update sets
jsn updateset list # List update sets
jsn updateset use <name> # Set current update set
# Configuration
jsn config list # List profiles
jsn config switch <name> # Switch profile
jsn auth status # Check auth statusjsn tables list # Styled output in terminal
jsn tables list --json # JSON with envelope and breadcrumbs
jsn tables list --quiet # Raw JSON data only
jsn tables list --md # Markdown formatEvery command supports --json for structured output:
{
"ok": true,
"data": [...],
"summary": "5 tables",
"breadcrumbs": [
{"action": "show", "cmd": "jsn tables show incident", "description": "View table details"}
]
}Breadcrumbs suggest next commands, making it easy for humans and agents to navigate.
Supports two authentication methods:
Basic Auth (recommended for CI/CD):
jsn auth login # Enter username/passwordg_ck Token (browser cookie):
jsn auth login # Choose g_ck optionCredentials are stored securely using your system keyring (macOS Keychain, Windows Credential Manager, Linux Secret Service). Falls back to file storage with restricted permissions if keyring is unavailable.
| Variable | Purpose |
|---|---|
SERVICENOW_TOKEN |
Override stored token/password |
SERVICENOW_INSTANCE |
Override instance URL |
XDG_CONFIG_HOME |
Custom config directory |
~/.config/servicenow/ # Global configuration
├── config.json # Profiles and settings
└── credentials.json # Auth tokens (fallback when keyring unavailable)
.servicenow/ # Per-repo configuration (optional)
└── config.json # Project-specific settings
Use --help to explore all commands and flags:
jsn --help # List all top-level commands
jsn tables --help # Show tables subcommands
jsn records list --help # Show records list flagsOr use jsn with no arguments for an interactive command picker.
These flags work with any command:
--config <path> # Use specific config file
--profile <name> # Use specific profile
--json # Output as JSON
--quiet, -q # Output data only (no envelope)
--md # Output as Markdown
--agent # Agent mode (JSON + quiet + no interactive prompts)
make build # Build binary
make test # Run Go tests
make lint # Run linterSee CONTRIBUTING.md for development setup.