Skip to main content
Glama
par4987

@pired/sap-fiori-mcp-server

by par4987

Query OData data via destination, system or URL

query_odata_data
Read-onlyIdempotent

Run OData queries on SAP entity sets and get JSON rows. Supports $filter, $select, $expand, $top, $skip, $orderby, and $count across BTP destinations, SAP systems, or full service URLs.

Instructions

Executes an OData query (V2 or V4) against an entity set and returns the rows as JSON. Target: a BTP destination (destination + optional servicePath), a configured SAP system (systemName + servicePath from list_sap_systems), or a full serviceUrl. Supports $filter, $top, $skip, $select, $orderby, $expand and $count. This is the remote counterpart of query_cap_data.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topNo$top (max rows returned by the service, default 50)
skipNo$skip
countNoAsk the service for the total number of rows
expandNo$expand navigation properties, e.g. '_Travel,_Agency'
filterNoOData $filter, e.g. "Status eq 'A' and Price gt 100"
selectNo$select comma-separated fields
maxRowsNoMax rows included in the tool output (safety limit)
orderByNo$orderby, e.g. 'CreatedAt desc'
entitySetYesEntity set name, e.g. 'Travel' or 'Products'
serviceUrlNoFull service URL (used when no destination/system is given)
systemNameNoConfigured SAP system name (see list_sap_systems)
destinationNoBTP destination name (see list_btp_destinations)
servicePathNoService path relative to the destination/system URL, e.g. /sap/opu/odata4/sap/zui_travel_ov4/srv
odataVersionNoService OData version. Only affects how the total is requested: $count=true in V4, $inlinecount=allpages in V2. When omitted, V4 is tried first and V2 is retried automatically if the service rejects it.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
rowsYes
countYesRows in this response
totalNoTotal rows reported by the service (only when count:true was requested)
sourceYes
hasMoreYes
nextSkipYesValue to pass as skip on the next call, or null
rowCountYesDeprecated alias of count; use count
appliedUrlYes
destinationNo
inlineCountNoRaw $count value reported by the service
truncatedToNoSet when the service returned more rows than maxRows
odataVersionYesConvention used to request the total: '4.0' ($count) or '2.0' ($inlinecount)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.26.1

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, covering the safety profile. The description adds valuable behavioral details beyond annotations: supported OData query options ($filter, $top, $skip, etc.), the maxRows safety limit, and the odataVersion fallback (V4 tried first, V2 retried automatically if rejected). These disclose runtime behaviors not captured in annotations. No contradiction with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences with zero waste. The first sentence states the primary action and output. The second sentence efficiently covers three meaningful pieces of information: targeting modes, supported OData clauses, and the relationship to a sibling tool. All content earns its place; no filler or repetition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite the tool's complexity (14 parameters, multiple targeting modes, OData version handling), the description covers the essential decision points: how to choose among destination/system/URL, which query options are supported, the count behavior across versions, and the safety limit. The presence of an output schema covers return format details, so no additional information on that front is needed. Nothing critical for correct invocation is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% – every parameter includes a description in the schema. The tool description does add context about how the three targeting parameters (destination, systemName, serviceUrl) relate and that servicePath is optional for destination/system, but these are minor enhancements over the schema descriptions. Since the schema already documents each parameter thoroughly, the baseline of 3 applies; the description does not add significant semantic value beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a clear verb+resource: 'Executes an OData query (V2 or V4) against an entity set and returns the rows as JSON.' It also specifies three targeting modes (destination, system, URL) and explicitly distinguishes itself from the sibling 'query_cap_data' as its remote counterpart, making the purpose unambiguous and well-differentiated.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides concrete guidance on when to use each targeting mode (BTP destination, configured SAP system, or full serviceUrl) and references sibling tools like list_sap_systems and list_btp_destinations. It also explains the odataVersion fallback behavior. It does not explicitly list when not to use this tool versus query_cap_data, but the 'remote counterpart' phrasing implies a clear context. Minor gap: no explicit exclusions or alternatives besides this reference, so not a perfect 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.