Skip to main content
Glama
amittell

firewalla-mcp-server

get_flow_data

Read-only

Query network traffic flows from Firewalla MSP, filter by region, protocol, or status, and paginate results with cursors or streaming sessions.

Instructions

Query network traffic flows from the Firewalla MSP API (GET /v2/flows). Without a ts: qualifier the API covers the last 24 hours. Returns up to limit flows and a cursor for the next page, or groups with groupBy; coverage gives the oldest and newest ts returned and why paging stopped. A limit over 50 is streamed: pass nextContinuationToken back as cursor, or sessionId as streaming_session_id. Scoped to FIREWALLA_BOX_ID when set, otherwise every box.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum results (optional, default: 200, at most 1000; read 500 per request, following the cursor)
queryNoSearch query for flows. Supports region:US for geographic filtering, protocol:tcp, status:blocked, domain:*, category:social, etc. Terms joined by spaces or AND must all match; OR works between values of one field (sent as a comma list, e.g. region:US,CN) and is refused across fields; NOT or a leading - excludes.
cursorNoPagination cursor from a previous response: pagination.cursor, or the nextContinuationToken of a streamed one. Returns the page at that cursor, not streamed.
sortByNoSort flows (default: "ts:desc")
streamNotrue streams any limit, false returns a plain page with pagination.cursor (default: a limit over 50 is streamed)
groupByNoFields to group by, comma-separated, e.g. "category", "domain", "device", "box" or "device,category". The API then returns groups instead of flows: groups of { key, count, download, upload, total }, where key holds the group fields (gid for box; for device the device with its name, but only its id for "device,category") and the rest are the group's summed connection count and bytes.
response_formatNoResponse format. 'json' (default): the compact JSON response. 'markdown': the same response as readable markdown, its fields as bullet lists and each list of records as a table of up to 8 columns and DEFAULT_PAGE_SIZE rows (default 100), ending with a line that says what the view leaves out. Omitted or null: 'json'. Errors are JSON either way.json
streaming_session_idNoThe sessionId of a streamed response: returns its next chunk, of the same size. A session expires 10 minutes after its latest chunk. Refused with stream: false; with a cursor, the cursor is read instead.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv2.0.1
    • changedInput schema / properties / cursor / description
      Previous value: -"Pagination cursor from previous response"New value: +"Pagination cursor from a previous response: pagination.cursor, or the nextContinuationToken of a streamed one. Returns the page at that cursor, not streamed."
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum results (optional, default: 200, API maximum: 500)"New value: +"Maximum results (optional, default: 200, at most 1000; read 500 per request, following the cursor)"
    • changedInput schema / properties / limit / maximum
      Previous value: -500New value: +1000
    • changedInput schema / properties / query / description
      Previous value: -"Search query for flows. Supports region:US for geographic filtering, protocol:tcp, status:blocked, domain:*, category:social, etc."New value: +"Search query for flows. Supports region:US for geographic filtering, protocol:tcp, status:blocked, domain:*, category:social, etc. Terms joined by spaces or AND must all match; OR works between values of one field (sent as a comma list, e.g. region:US,CN) and is refused across fields; NOT or a leading - excludes."
    • addedInput schema / properties / response_format
      Added value: +{
      +  "default": "json",
      +  "description": "Response format. 'json' (default): the compact JSON response. 'markdown': the same response as readable markdown, its fields as bullet lists and each list of records as a table of up to 8 columns and DEFAULT_PAGE_SIZE rows (default 100), ending with a line that says what the view leaves out. Omitted or null: 'json'. Errors are JSON either way.",
      +  "enum": [
      +    "json",
      +    "markdown",
      +    null
      +  ],
      +  "type": [
      +    "string",
      +    "null"
      +  ]
      +}
    • addedInput schema / properties / stream
      Added value: +{
      +  "description": "true streams any limit, false returns a plain page with pagination.cursor (default: a limit over 50 is streamed)",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / streaming_session_id
      Added value: +{
      +  "description": "The sessionId of a streamed response: returns its next chunk, of the same size. A session expires 10 minutes after its latest chunk. Refused with stream: false; with a cursor, the cursor is read instead.",
      +  "type": "string"
      +}
  2. Changed2 schema fields changedv1.5.0
    • changedInput schema / properties / groupBy / description
      Previous value: -"Group flows by specified values (e.g., \"domain,box\")"New value: +"Fields to group by, comma-separated, e.g. \"category\", \"domain\", \"device\", \"box\" or \"device,category\". The API then returns groups instead of flows: groups of { key, count, download, upload, total }, where key holds the group fields (gid for box; for device the device with its name, but only its id for \"device,category\") and the rest are the group's summed connection count and bytes."
    • changedInput schema / properties / query / description
      Previous value: -"Search query for flows. Supports region:US for geographic filtering, protocol:tcp, blocked:true, domain:*, category:social, etc."New value: +"Search query for flows. Supports region:US for geographic filtering, protocol:tcp, status:blocked, domain:*, category:social, etc."
  3. First observed

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already establish readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds real behavioral context beyond that: the implicit 24-hour coverage window, the automatic switch to streaming above limit 50, the cursor/session continuation contract, and the FIREWALLA_BOX_ID scoping rule that changes the result set.

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

Conciseness4/5

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

Five sentences, no filler, and the most decision-relevant facts (what it queries, default time window, streaming threshold) are front-loaded before result-shape and scoping details. Dense but readable; only slightly over-packed with paging mechanics.

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?

With no output schema, the description usefully describes the return shape itself: up to limit flows plus a cursor, groups when groupBy is set, and a coverage block reporting oldest/newest ts and why paging stopped. An agent can call it and interpret the response correctly; only sibling-level routing guidance 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%, so the baseline is 3. The description does add one genuinely external fact not in the schema — that omitting a ts: qualifier yields a 24-hour window — plus the cursor/stream interplay and box scoping, but most parameter meaning is already carried by the schema.

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?

States a specific verb and resource with the backing endpoint: 'Query network traffic flows from the Firewalla MSP API (GET /v2/flows)'. An agent immediately knows it retrieves flow records. It does not, however, distinguish itself from close siblings like search_flows or get_recent_flow_activity, so the differentiation half of the criterion is unmet.

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

Usage Guidelines3/5

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

Gives operational guidance (default 24-hour window without a ts: qualifier, stream once limit exceeds 50, pass nextContinuationToken as cursor or sessionId as streaming_session_id) but this is mechanism rather than tool selection. There is no statement of when to prefer this tool over sibling flow tools such as search_flows or get_recent_flow_activity, and no explicit when-not condition.

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