Skip to content
Fourohtwo

api.lookproof.dev/v1/ip/contains

Check one IPv4 or IPv6 address against up to 100 CIDR blocks and get, for each, whether it contains the address, plus the blocks that do; blocks of the other IP version never match. Offline. Use when an agent must tell whether an address is in an allow list, a provider's ranges or an SPF ip4/ip6 term. Input: {"ip": "192.0.2.10", "cidrs": ["192.0.2.0/24"]}.

BaseAnswering
POSThttps://api.lookproof.dev/v1/ip/contains

Uptime100% of 5 checks in 30 days

30 days agoToday

Try it

Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.

The response shows up here.

Call it from an agent

// npm install fourohtwo
import { createPayer } from "fourohtwo";

// One agent key pays USDC on Base or USDG on Robinhood Chain, inside your spending rules.
const pay = createPayer({ privateKey: process.env.AGENT_KEY, maxPerCallUsd: "0.05" });
const res = await pay("https://api.lookproof.dev/v1/ip/contains", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"cidrs":["192.0.2.0/24","198.51.100.0/24","2001:db8::/32"],"ip":"192.0.2.10"}),
});
console.log(await res.json());

Example input

{
  "cidrs": [
    "192.0.2.0/24",
    "198.51.100.0/24",
    "2001:db8::/32"
  ],
  "ip": "192.0.2.10"
}

More from LookproofProvider status

api.lookproof.dev/v1/ip/contains by Lookproof · x402 API | Fourohtwo