»» Tools » API
CIDR API
The CIDR calculator available over HTTP, with an API key and rate limits — free, for your scripts and internal tools.
»» Request
GET /api/v1/cidr — parameters address and prefix, authentication via the Authorization: Bearer <key> header.
curl -H "Authorization: Bearer nak_votre_cle" \ "https://www.netarchitect.fr/api/v1/cidr?address=192.168.1.0&prefix=24"
»» Response (200)
{
"ok": true,
"result": {
"version": 4,
"prefix": 24,
"network": "192.168.1.0",
"broadcast": "192.168.1.255",
"netmask": "255.255.255.0",
"wildcardMask": "0.0.0.255",
"firstHost": "192.168.1.1",
"lastHost": "192.168.1.254",
"usableHostCount": "254",
"totalAddresses": "256"
}
}»» Errors
| Code | Cause |
|---|---|
| 400 | Missing or invalid parameters (address, prefix) |
| 401 | Missing or invalid API key |
| 429 | Rate limit exceeded (burst or daily quota) |
| 503 | Service temporarily unavailable |
{
"error": "Invalid API key."
}
»» Limits
20 / 1 m
Burst per key
500 / 1 d
Daily quota per key
3 / 1 d
Keys per IP (signup)
Exceeding the daily quota returns the X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset headers.
»» Get a key
Free, no credit card required. The key is shown only once — save it.
