fluent_sdk_query
Resolve sys_ids, inspect table schemas, and check existing records by running read-only ServiceNow queries via the SDK CLI while authoring Fluent code.
Instructions
Run now-sdk query <table> — a read-only Table REST API query executed via the ServiceNow SDK CLI against your authenticated instance (no browser). New in @servicenow/sdk 4.8. Ideal while authoring Fluent code: resolve sys_ids, inspect table schemas, check existing records, read choice values. Example: { table: "sys_user_role", query: "name=admin", fields: ["sys_id","name"], limit: 1 }
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"table": "<table>"
},
"name": "fluent_sdk_query"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max rows to return | |
| query | No | Encoded query string (e.g., "name=admin^active=true") | |
| table | Yes | Table to query (e.g., "incident", "sys_dictionary") | |
| fields | No | Fields to return (e.g., ["sys_id","name"]) |