A leaked key is the most common way an API bill runs away. BroadNet Inference gives you two controls: an IP allow-list and fast revocation.
Two kinds of credential
| Credential | Use it for | Treat it as |
|---|---|---|
| Inference key | Model requests to /v1/* |
A secret for one app or agent |
| Portal credential | Account automation: keys, allowed IPs, purchases | Full account authority |
Both are shown once. The portal keeps only a SHA-256 hash, so it cannot show the key again. A pay-as-you-go inference key lasts one year from creation, and an account can hold up to ten live keys.
Set an allow-list
On the account page, add one IPv4 or IPv6 address or CIDR range per line, up to 32 entries. An empty list means no IP restriction. New keys inherit this account list. The edge checks the client IP that Cloudflare reports on every API request.
To manage the account list from a script, PUT /portal/allowed_ips replaces it in one call (portal credential required).
Give one key its own list when you create it with a portal credential:
curl -X POST https://inference.broadnet.ai/portal/keys \
-H "Authorization: Bearer $BROADNET_PORTAL_CREDENTIAL" \
-H "Content-Type: application/json" \
-d '{"label":"worker-1","allowed_ips":["203.0.113.7","198.51.100.0/24"]}'
A per-key allowed_ips replaces the inherited account list for that key. The response contains the raw key once; store it straight away.
Revoke a leaked key fast
DELETE /portal/keys/{alias} revokes a pay-as-you-go key, and DELETE /portal/keys/hourly/{alias} revokes an hourly key (the original purchase charge stays). After a revocation or allow-list change, new requests stop within five seconds.
curl -X DELETE https://inference.broadnet.ai/portal/keys/$KEY_ALIAS \
-H "Authorization: Bearer $BROADNET_PORTAL_CREDENTIAL"
Set KEY_ALIAS to the alias shown for the key on the account page or in GET /portal/keys. The alias is not the secret key. If a portal credential leaks, revoke it with DELETE /portal/credentials/{id}: it can do everything your account can.
Troubleshooting
- 403 from a server you listed. The edge sees your public egress address, not the server’s private IP. Servers behind a NAT gateway, proxy or load balancer leave through that device’s address. A server with IPv6 may leave over IPv6 even if you listed only its IPv4 address. List the address the request actually leaves from, or a CIDR range that covers it.
- A new key ignores the account list. A per-key
allowed_ipsarray replaces the inherited account list for that key. Check what you passed at creation. - 409
key_limit_reached. The account already has ten live keys. Revoke one you no longer use. - Requests still succeed a few seconds after revoking. Expected for up to five seconds while the cache catches up.
A request from an address that isn’t on the list gets a 403. See all BroadNet error codes and when to retry. To make your first request with a new key, follow the OpenAI Python SDK guide. The IP allow-list glossary entry explains the idea in general terms.

