# FastX402 IP CIDR Membership Check

> FastX402 IP CIDR Membership Check is a paid API for AI agents from fastx402.tools, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-29).

Checks whether a given IP address (IPv4 or IPv6) falls within a specified CIDR network range

## Facts

- Endpoint: GET https://fastx402.tools/ip-cidr-membership?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-29
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/fastx402-ip-cidr-membership-check-db51a250
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_QfoMlOkx09lLiDQ_q3QuC

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability fastx402-ip-cidr-membership-check-db51a250
```

Example prompt: Check if the IP address 192.168.1.50 falls within the CIDR range 192.168.1.0/24.

## When to prefer this

Use this endpoint when you need a fast, lightweight, no-account-required check for IP-to-CIDR membership — especially useful in agent workflows that need to validate whether a request IP is within an allowed or blocked range, perform geofencing logic, or enforce network access control policies. Prefer this over writing custom subnet math when you need a reliable, API-based single check at minimal cost ($0.001 USDC per call).

## Known failure modes

- Invalid IP address format returns an error response
- Malformed CIDR notation (e.g. missing prefix length) returns an error
- IPv4 address checked against IPv6 CIDR or vice versa may return match: false or error
- Missing required query parameters (ip or cidr) results in a bad request error
- Payment failure via x402 protocol prevents the call from completing

## How this service works

200 pay-per-call tools for AI agents, from $0.001 per request in USDC on Base or Solana with x402. No account, no API key.

## Output

Returns a JSON object with the queried IP address, the CIDR range, and a boolean 'match' field indicating whether the IP falls within the specified CIDR block (e.g. {"ip": "192.168.1.50", "cidr": "192.168.1.0/24", "match": true}).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "ip",
      "cidr"
     ],
     "properties": {
      "ip": {
       "type": "string",
       "description": "IPv4 or IPv6 address to check"
      },
      "cidr": {
       "type": "string",
       "description": "CIDR range (e.g. 192.168.0.0/16 or 2001:db8::/32)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "ip": {
       "type": "string"
      },
      "cidr": {
       "type": "string"
      },
      "match": {
       "type": "boolean"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ip": "192.168.1.50",
  "cidr": "192.168.1.0/24",
  "match": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/fastx402-ip-cidr-membership-check-db51a250/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from fastx402.tools](https://www.zero.xyz/host/fastx402.tools/llms.txt)
