Reference
MCP tools, prompts and limits reference
Updated
The PcapAI MCP server offers ten tools and five prompts. This reference is generated from the server's own definitions, so the names, descriptions and parameters below are exactly what your agent receives. You rarely need to name a tool yourself; the agent picks them from your request.
New to the server? The install guide connects your agent, and the example prompts show which tools each kind of request uses.
Connection
The server is stateless: every request is a complete JSON-RPC call over HTTP POST, answered with plain JSON, without a session id or server-sent events. It authenticates every request with the bearer token before anything else, so even a discovery request without a token gets a 401.
| Endpoint | POST https://pcapai.com/mcp |
|---|---|
| Transport | Streamable HTTP, JSON answers, no session |
| Authentication | Authorization: Bearer pcapai_pat_…, a personal token from your profile |
| Protocol versions | 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28 |
| Server name | pcapai, offering tools and prompts |
| HTTP refusals | 401 without a valid token · 403 for a browser Origin or a foreign Host · 405 for anything but POST · 413 for a request body over 256 KB · 429 over 60 requests a minute |
Tools
Six tools are free, three need an unlocked analysis, and one spends money: unlock_analysis takes one report credit the first time it unlocks a capture, after you agree. A business failure comes back as a tool result with isError and a JSON body {"error": {"code", "message"}} the agent can act on; the codes are listed under error codes.
| Tool | What it does | Cost |
|---|---|---|
| get_account | Get account | Free |
| upload_capture | Upload a capture | Free |
| analyze_capture | Analyze a capture | Free |
| get_analysis | Get analysis | Free |
| list_analyses | List analyses | Free |
| unlock_analysis | Unlock an analysis | 1 report credit, once per analysis |
| get_finding | Get a finding | Needs an unlock |
| query_analysis | Query an analysis | Needs an unlock |
| create_pdf_report | Create the PDF report | Included in the unlock |
| delete_analysis | Delete an analysis | Free |
get_account · Get account
Free scope: none read-only idempotent
Usually the first call: it shows whether the connection works and what the account can do.
What the agent is told: Shows the PcapAI account this connection uses: its plan, how many report credits are left (unlocking the details of one analysis uses one), the largest capture it can upload, and what this token is allowed to do.
No parameters.
upload_capture · Upload a capture
Free scope: analyses:write
The agent measures the file, gets a signed link and a curl command, and runs the command itself. Counts toward the 20 analyses a day.
What the agent is told: Starts the analysis of a network capture (.pcap or .pcapng) the agent can read. Returns a signed HTTPS link that accepts exactly size_bytes bytes for 15 minutes, and a ready curl command; upload the file with it, then call analyze_capture. The capture is stored and analyzed on PcapAI's servers; an analysis that is not unlocked is deleted after 24 hours.
| Parameter | Type | Description |
|---|---|---|
| file_name required | string | The capture's file name, for example slow.pcap. |
| size_bytes required | integer | The file's exact size in bytes, for example from stat or wc -c. |
| mode | "troubleshooting" | "security" | "troubleshooting": why the network is slow or failing; "security": threats mapped to MITRE ATT&CK. The account's default when left out. |
analyze_capture · Analyze a capture
Free scope: analyses:write idempotent
Called after the upload. Returns the free summary, or status processing when the engine needs longer than wait_seconds.
What the agent is told: Analyzes a capture uploaded with upload_capture and returns its free summary: verdict, risk, counts and the titles of the findings. Waits up to wait_seconds; if the engine is not done by then, answers status processing, and get_analysis returns the summary later.
| Parameter | Type | Description |
|---|---|---|
| upload_id required | string | The upload_id upload_capture returned, after the file was uploaded. |
| wait_seconds | integer | How long to wait for the free summary, 0 to 25 seconds (20 when left out). |
get_analysis · Get analysis
Free scope: analyses:read read-only idempotent
The agent polls it while the engine works, and reads old summaries with it.
What the agent is told: Returns the status of an analysis and, once the engine is done, its free summary: verdict, risk, counts and the titles of the findings. For an unlocked analysis it also says that the details are available.
| Parameter | Type | Description |
|---|---|---|
| analysis_id required | string | The analysis_id that analyze_capture or list_analyses returned. |
list_analyses · List analyses
Free scope: analyses:read read-only idempotent
Finds earlier analyses, for example to compare a capture taken after a fix.
What the agent is told: Lists the analyses of this account, newest first, with their status and whether they are unlocked.
| Parameter | Type | Description |
|---|---|---|
| cursor | string | The next_cursor of the previous page. |
| limit | integer | Analyses per page, 1 to 50 (20 when left out). |
unlock_analysis · Unlock an analysis
1 report credit, once per analysis scope: credits:spend destructive: clients ask first idempotent
Without confirm it only reports the cost; the agent asks you before it confirms, unless the token unlocks without asking.
What the agent is told: Unlocks the details of one finished analysis: the evidence of every finding, the hosts, the fixes and the PDF report. The first unlock of an analysis spends one report credit from the account; calling it again never spends another. Without confirm set to true it spends nothing and only reports what it would cost and how many credits are left, so the user can decide.
| Parameter | Type | Description |
|---|---|---|
| analysis_id required | string | The analysis_id of a finished analysis. |
| confirm | boolean | True once the user agreed to spend one report credit on this analysis. |
get_finding · Get a finding
Needs an unlock scope: analyses:read read-only idempotent
One finding in full: evidence, frames, display filters, hosts in their roles, confidence, alternatives to rule out and the fix. A network problem comes with the hosts affected, the fault domain, the measurements and how to verify the fix.
What the agent is told: Returns one finding of an unlocked analysis in full: the evidence with Wireshark frame numbers and display filters, the hosts in their roles, the MITRE ATT&CK technique, the confidence and benign explanations to rule out, and the steps that fix it. A network problem (kind network_problem) comes with who is affected, where the fault lies, the measurements behind it, the steps that fix it, how to verify the fix and, where the engine has them, read-only commands that confirm it; it is measured over many packets, so it has no frame numbers. Use the finding ids of the free summary.
| Parameter | Type | Description |
|---|---|---|
| analysis_id required | string | The analysis_id of an unlocked analysis. |
| finding_id required | string | A finding id from the free summary, such as F01. |
query_analysis · Query an analysis
Needs an unlock scope: analyses:read read-only idempotent
Pages through hosts, flows, destinations, indicators, network problems, fix steps or coverage, with a text filter.
What the agent is told: Pages through one section of an unlocked analysis: hosts (addresses, MAC vendors, host names, users), flows, destinations (names, ports, countries, reputation), indicators (domains, addresses and other IOCs), network_problems (as get_finding returns them), actions (the fix steps) or coverage (what was checked, area by area). Before an unlock the free summary of get_analysis is the whole result. filter keeps the items that contain a text, such as an address.
| Parameter | Type | Description |
|---|---|---|
| analysis_id required | string | The analysis_id of an unlocked analysis. |
| section required | "hosts" | "flows" | "destinations" | "indicators" | "network_problems" | "actions" | "coverage" | The section to page through: hosts, flows, destinations, indicators, network_problems, actions or coverage. |
| cursor | string | The next_cursor of the previous page. |
| filter | string | Only items that contain this text (an address, a host name, a domain); case-insensitive. |
| limit | integer | Items per page, 1 to 50 (20 when left out). |
create_pdf_report · Create the PDF report
Included in the unlock scope: analyses:write idempotent
Renders the PDF with your report settings; call it again for a fresh 15-minute link.
What the agent is told: Creates the PDF report of an unlocked analysis, at no extra credit, and returns a download link valid for 15 minutes. The first call starts the rendering and waits up to wait_seconds; call it again to get the link once the PDF is ready. The PDF carries the account's report settings: organization, TLP label, country and sector.
| Parameter | Type | Description |
|---|---|---|
| analysis_id required | string | The analysis_id of an unlocked analysis. |
| wait_seconds | integer | How long to wait for the PDF, 0 to 25 seconds (20 when left out). |
delete_analysis · Delete an analysis
Free scope: analyses:write destructive: clients ask first idempotent
Deletes the capture and everything made from it at once. A spent credit is not given back.
What the agent is told: Deletes an analysis at once: the capture, its summary, its details and its PDF. This cannot be undone, and a credit spent on it is not given back.
| Parameter | Type | Description |
|---|---|---|
| analysis_id required | string | The analysis to delete, with its capture, summary, details and PDF. |
Prompts
Prompts are ready-made requests. Claude Code lists them in its / menu as shown; other clients show them under their own names or not at all (VS Code does not). Every prompt that can lead to an unlock tells the agent to ask you before it spends a credit.
| Prompt (Claude Code) | What it asks | Arguments |
|---|---|---|
/pcapai:triage-capture [path] |
Triage a capture. Analyze a capture and explain the free summary. |
path: The capture's path (.pcap or .pcapng).
|
/pcapai:why-is-the-network-slow [interface] [path] |
Why is the network slow?. Capture traffic during the problem, or take a capture, and find the cause. |
interface: The interface to capture on, such as eth0. path: An existing capture's path instead of a new one.
|
/pcapai:is-this-host-compromised <host> [path] |
Is this host compromised?. Check one host's traffic for signs of compromise. |
host required: The host's address or name. path: The capture's path.
|
/pcapai:client-report <analysis_id> |
Client report. Get the PDF of an unlocked analysis and a short message for the client. |
analysis_id required: The analysis to report on.
|
/pcapai:verify-a-fix <analysis_id> [path] |
Verify a fix. Capture again after a change and compare with the analysis before it. |
analysis_id required: The analysis made before the change. path: A capture taken after the change, if there is one.
|
Limits
Limits apply per account, whichever agent or token sends the requests. When one is reached, the answer says how long to wait, and agents usually wait on their own.
| Capture size | 20 MB without a plan or with credit packs, 25 MB on Starter, 50 MB on Pro, 100 MB on Advanced |
|---|---|
| Analyses | 20 started in any 24 hours (every upload_capture counts, failed and deleted ones too); 3 uploading or running at a time |
| Requests | 60 a minute, with Retry-After on the 429 |
| Upload link | 15 minutes, exactly size_bytes bytes, one PUT |
| Waiting in a call | wait_seconds 0 to 25, default 20; then status processing |
| Pages | Up to 50 items per list_analyses or query_analysis call, with a cursor for the next page |
| PDF link | 15 minutes; call create_pdf_report again for a new one |
| Retention | 24 hours after the upload unless unlocked; 30 days after the unlock (Advanced: while subscribed) |
Error codes
Every refusal carries a code and a message written for the agent, which usually knows what to do next. The messages below are the server's own, with example values where it fills in a number or an address; the troubleshooting page explains each one at more length.
| Code | Kind | Message |
|---|---|---|
| missing_token | HTTP 401 | Send a PcapAI MCP token in the Authorization header (Bearer pcapai_pat_...). Create one at https://pcapai.com/profile#mcp. |
| invalid_token | HTTP 401 | This is not a PcapAI MCP token. Create one at https://pcapai.com/profile#mcp. |
| invalid_token | HTTP 401 | The token is revoked, expired or unknown. Create a new one at https://pcapai.com/profile#mcp. |
| Origin header is not allowed | HTTP 403 | Forbidden: Origin header is not allowed |
| rate_limited | HTTP 429 | More than 60 requests in a minute. Wait 12 seconds. |
| rate_limited | tool error | This account started 20 analyses in the last 24 hours, the daily limit. |
| rate_limited | tool error | 3 analyses of this account are still uploading or running. Finish or wait for them first. |
| too_large | tool error | This capture is larger than this account's limit of 20.0 MB. Cut it down, for example with editcap or a shorter tcpdump. |
| upload_missing | tool error | The file has not reached storage yet. Run the PUT (the curl command from upload_capture), then call analyze_capture again. |
| expired | tool error | This upload expired: the link lives 15 minutes. Call upload_capture again. |
| size_mismatch | tool error | The uploaded file doesn't have the size this upload was opened for. Upload it again. |
| not_a_capture | tool error | The uploaded file is not a readable PCAP or PCAPNG capture. Upload an uncompressed .pcap or .pcapng file exported from Wireshark, tcpdump, tshark, or another packet capture tool. |
| processing | status | The engine is still working on the capture. Call get_analysis again in about 10 seconds. |
| failed | status | The analysis did not finish: the file may be damaged or not a capture the engine reads. Upload it again, or try it at https://pcapai.com/analyze-pcap. |
| expired | status | This analysis is older than its 24-hour window and was not unlocked, so its results are gone. Upload the capture again. |
| confirmation_required | status | Unlocking spends 1 of the 12 report credits left. Ask the user; if they agree, call unlock_analysis again with confirm set to true. |
| payment_required | status | The account has no report credits left. The user can buy a single report or a pack on PcapAI while signed in as [email protected], then ask again. |
| insufficient_scope | tool error | This token is not allowed to do this (credits:spend). Create a token with that permission in the PcapAI profile. |
| locked | tool error | The details of this analysis need an unlock: unlock_analysis spends one report credit, so ask the user first. The free summary stays available through get_analysis. |
| nothing_to_unlock | status | The engine found nothing to report: this summary is the whole result. |
What the answers contain
A successful tool call returns structured content and the same JSON as text, so every client can read it. Times are UTC. In the details of an unlocked analysis, long strings are cut at 600 characters and lists at 50 items, and paged sections come with a cursor. Passwords, cookies, authorization headers and other secret values found in the capture never appear in an answer, not even masked: the server drops them, and a masked value becomes [withheld]. The PDF shows them masked, like S******! (11).
Titles, host names, URLs, user agents, file names and certificate fields are copied from network traffic, which anyone on the network can write. Every answer that contains them carries a note telling the agent to treat that text as data, never as instructions. How PcapAI stores captures and tokens is on security, tokens and data handling.
Was this page helpful?
Thanks. Missing something? Tell us what.