Port Check

Check whether TCP ports are open on a host. Scans up to 20 ports with a set timeout and returns each port's status and latency.

Pay by wallet (x402) port-check

Example

Input
{
  "host": "google.com",
  "ports": 443
}
Answer
{
  "host": "google.com",
  "open_count": 1,
  "open_ports": [
    {
      "open": true,
      "port": 443,
      "service": "HTTPS",
      "latency_ms": 1
    }
  ],
  "closed_count": 0,
  "closed_ports": [],
  "ports_scanned": 1,
  "scan_timeout_ms": 3000
}

Inputs

FieldTypeRequiredWhat it is
hoststringYes—
portsanyNoArray of port numbers or comma-separated string
timeout_msintegerNo—

Output fields

How reliably each field appears in a successful answer.

FieldTypeAppears
hoststringAlways (present in every successful answer)
open_countintegerAlways (present in every successful answer)
open_portsarrayAlways (present in every successful answer)
closed_countintegerAlways (present in every successful answer)
closed_portsarrayAlways (present in every successful answer)

How to call it

The same tool through each route. MCP clients reach it through Strale’s server at https://api.strale.io/mcp; the call below is what the agent sends.

# Needs an API key. max_price_cents caps what this call may cost.
curl -X POST https://api.strale.io/v1/do \
  -H "Authorization: Bearer $STRALE_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
    "capability_slug": "port-check",
    "inputs": {
      "host": "google.com",
      "ports": 443
    },
    "max_price_cents": 5
  }'

Limitations

  • Firewalls can block probes despite a reachable service

    TCP connection test only — firewalls may block probes from Strale's IP range while allowing traffic from other sources

    What to do instead: If a port shows as closed, verify from your own network before concluding the service is down