Skip to main content
Glama

SMS over IMS

sms_over_ims
Read-onlyIdempotent

Extract SMS over IMS from packet captures: parse SIP MESSAGE RP-DATA/RP-SMMA, pair RP-ACK/RP-ERROR, and filter by subscriber, number, or time.

Instructions

SMS over IMS (TS 24.341): SIP MESSAGE carrying application/vnd.3gpp.sms, one row per RP-DATA or RP-SMMA. Each row gives direction (MO: RP-DATA from the UE with an SMS-SUBMIT; MT: RP-DATA to the UE with an SMS-DELIVER or SMS-STATUS-REPORT), the RP message reference, the SMSC address (smsc_digits), the TPDU (type, TP-MR, TP-OA/TP-DA, status report requested, concatenation part, TP-Status of a status report; never the text), the SIP response to the MESSAGE with its frame and delay, and ack: the RP-ACK or RP-ERROR that answers it (paired by RP-MR and the UE's identity, including the identities its REGISTER associated), with RP cause named, the TPDU it carries and the SIP response to the MESSAGE that carried it. An MO submit that asked for a status report gets status_report. ue_registration is the UE's IMS registration from this capture and whether its Contact had +g.3gpp.smsip. number keeps rows naming those digits, imsi rows whose identities contain it; filter is ANDed with the MESSAGE filter. More detail: resource schema://tools/sms_over_ims.

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": {
      "path": "<path>"
    },
    "name": "sms_over_ims"
  }
}

Input Schema

NameRequiredDescriptionDefault
endNoSame forms as start
imsiNoIMSI, 6 to 15 digits
pathYesCapture file (absolute, in an allowed dir) or open_capture handle
limitNoMost rows per page
startNoISO 8601, epoch s, +Ns from start, -Ns from end
filterNoExtra display filter, ANDed
numberNoPhone number digits found in From, To, Request-URI or P-Asserted-Identity
offsetNoRows to skip (next_offset)
outputNosummary: all but rows, plus 3 rows (<8 KB)rows
redactNoReplace subscriber identifiers in this result with tokens; ids+ips hides every IP toooff
columnsNoRow keys to keep (frame keys stay)
esp_nullNoRead SIP in NULL-encrypted ESP
max_output_kbNoLower output cap, KB

Output Schema

NameRequiredDescriptionDefault
countNo
errorNo
ipsecNokeys: esp_packets, spis, decoded_null, unreadable, esp_null, hint
offsetNo
windowNo
droppedNo
summaryNo
has_moreNo
messagesNorows with keys: time, frame, direction, rp_message, rp_mr, call_id, request_uri, smsc_digits, tpdu, status_report_of_frame, sip_response, sip_response_frame, sip_response_ms, other_leg_statuses, legs, retransmissions, copies, ack, status_report, ue_registration, verdict, reasons
returnedNo
capture_endNo
next_offsetNo
total_foundNo
total_matchedNo
packets_matchedNo
packets_scannedNo
total_is_lower_boundNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior4/5

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

Annotations already establish readOnly, idempotent, non-destructive, closed-world semantics, so the bar is lower, and the description still adds real behavioral context: message text is never exposed ('never the text'), acks are paired by RP-MR plus the UE's identity including REGISTER-associated identities, and rows carry the SIP response with frame and delay. It does not say what happens on captures with no IMS traffic, nor how large result sets are paged beyond the limit/offset schema fields.

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

Conciseness3/5

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

It is front-loaded with the protocol and row unit, which is good, but the core is one very long run-on sentence of nested parentheses enumerating every TPDU and ack field — much of which restates what the existing output schema already returns. Dense and information-rich, yet heavier than needed and hard to scan for an agent deciding whether to call it.

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

Completeness4/5

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

For a complex 13-parameter capture-analysis tool it covers the domain model thoroughly: MO/MT direction semantics, RP-ACK/RP-ERROR pairing, status-report handling, ue_registration derived from the capture, and how filters compose, plus a pointer to a deeper resource. With an output schema present the detailed return-value prose is redundant rather than missing, and the only substantive gap is selection guidance relative to sibling tools.

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 coverage is 100%, so the schema already documents all 13 parameters and the baseline is 3. The description adds a little beyond it — 'number keeps rows naming those digits', 'imsi rows whose identities contain it', and that filter is ANDed with the MESSAGE filter — but leaves start/end, output, redact, columns, esp_null and max_output_kb to the schema, so the added meaning is modest rather than substantial.

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

Purpose4/5

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

The description names the specific protocol artifact (SIP MESSAGE with application/vnd.3gpp.sms, per TS 24.341) and the unit of output — one row per RP-DATA or RP-SMMA — and then enumerates the row contents, so the agent knows exactly what it gets. It never states the action verb (extract/list from a capture) nor differentiates itself from siblings such as ims_registration or sip_call_detail, which keeps it below a 5.

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

Usage Guidelines2/5

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

There is no when-to-use, when-not-to-use, or alternative-tool guidance anywhere in the description; it goes straight into row anatomy. The only routing cue is the bare pointer 'More detail: resource schema://tools/sms_over_ims', which pushes usage discovery out of the definition entirely.

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