@jacebenson/jsn 3.1.1 → 3.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/skills/servicenow/SKILL.md +13 -0
- package/src/cli.js +1 -1
- package/src/output.js +5 -0
package/package.json
CHANGED
|
@@ -71,6 +71,19 @@ Pick the most specific tool for the job. **Never default to eval** — it's the
|
|
|
71
71
|
| **Config** | `setup`, `auth`, `profiles`, `updatesets`, `scopes` |
|
|
72
72
|
| **Developer** | `eval`, `rest`, `skill`, `version` |
|
|
73
73
|
|
|
74
|
+
### `jsn rest` examples
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
# Query any table by name
|
|
78
|
+
jsn rest --table incident --query "active=true" --limit 5 --json
|
|
79
|
+
|
|
80
|
+
# GET a single record
|
|
81
|
+
jsn rest --table incident --sys-id abc123... --json
|
|
82
|
+
|
|
83
|
+
# Raw endpoint access
|
|
84
|
+
jsn rest "/api/now/table/incident?sysparm_limit=3" --json
|
|
85
|
+
```
|
|
86
|
+
|
|
74
87
|
## Troubleshooting Field Behavior
|
|
75
88
|
|
|
76
89
|
Check order (priority):
|
package/src/cli.js
CHANGED
|
@@ -150,7 +150,7 @@ export function buildCLI() {
|
|
|
150
150
|
if (argv.styled) argv.format = 'styled';
|
|
151
151
|
if (argv.markdown) argv.format = 'markdown';
|
|
152
152
|
if (argv.format) {
|
|
153
|
-
app.output.
|
|
153
|
+
app.output.setFormat(argv.format);
|
|
154
154
|
}
|
|
155
155
|
if (argv.instance) {
|
|
156
156
|
app._overrideInstance = argv.instance;
|
package/src/output.js
CHANGED