Skip to main content
Glama

shodan_count

Count Shodan search results to scope queries before running full searches, helping conserve API credits by previewing result volumes and distributions.

Instructions

Get the total number of results for a search query without returning the actual results. Useful for scoping searches before running full queries to avoid wasting API credits.

Best Practice: Always use count first for large ICS/SCADA queries.

Example Workflow:

  1. Count: "port:502 tag:ics" → 50,000 results

  2. Narrow: "port:502 tag:ics country:US" → 15,000 results

  3. Refine: "port:502 tag:ics country:US org:"Electric"" → 500 results

  4. Then run full search on refined query

Use with facets to see distribution without burning credits on full results.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesShodan search query. Same syntax as shodan_host_search. Examples: "port:502 tag:ics", "port:502 country:US", "tag:ics has_vuln:true"
facetsNoOptional facets for aggregated counts. Use to see distribution: "country,org,product". Shows breakdown without full results.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/GangGreenTemperTatum/shodan-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server