# Cloudflare AI Gateway API

**Canonical:** https://apis.io/apis/cloudflare/cloudflare-ai-gateway-api/  
**Provider:** Cloudflare — https://apis.io/providers/cloudflare/  
**Base URL:** https://api.cloudflare.com  
**Documentation:** https://developers.cloudflare.com/load-balancing/

Cloudflare AI Gateway API is one of 651 APIs that [Cloudflare](https://apis.io/providers/cloudflare/) publishes on the [APIs.io](https://apis.io/) network, described by a machine-readable OpenAPI specification. Tagged areas include AI Gateway. The published artifact set on APIs.io includes an OpenAPI specification.

The AI Gateway API from Cloudflare — 11 operation(s) for ai gateway.

## Operations (15)

| Method | Path | Summary |
|---|---|---|
| GET | `/accounts/{account_id}/ai-gateway/billing/credit-balance` | Get credit balance |
| GET | `/accounts/{account_id}/ai-gateway/billing/invoice-history` | Get invoice history |
| GET | `/accounts/{account_id}/ai-gateway/billing/invoice-preview` | Get invoice preview |
| DELETE | `/accounts/{account_id}/ai-gateway/billing/spending-limit` | Delete spending limit (deprecated) |
| GET | `/accounts/{account_id}/ai-gateway/billing/spending-limit` | Get spending limit (deprecated) |
| POST | `/accounts/{account_id}/ai-gateway/billing/spending-limit` | Set spending limit (deprecated) |
| POST | `/accounts/{account_id}/ai-gateway/billing/topup` | Create a top-up |
| DELETE | `/accounts/{account_id}/ai-gateway/billing/topup/config` | Delete auto top-up configuration |
| GET | `/accounts/{account_id}/ai-gateway/billing/topup/config` | Get auto top-up configuration |
| POST | `/accounts/{account_id}/ai-gateway/billing/topup/config` | Set auto top-up configuration |
| POST | `/accounts/{account_id}/ai-gateway/billing/topup/eligibility` | Get top-up eligibility |
| GET | `/accounts/{account_id}/ai-gateway/billing/topup/limits` | Get account top-up limits |
| POST | `/accounts/{account_id}/ai-gateway/billing/topup/status` | Check top-up status |
| GET | `/accounts/{account_id}/ai-gateway/billing/usage-history` | Get usage history |
| POST | `/accounts/{account_id}/ai/websearch` | Search the web through AI Gateway |

## Machine-readable artifacts (1)

- **OpenAPI** — https://raw.githubusercontent.com/api-evangelist/cloudflare/refs/heads/main/openapi/cloudflare-ai-gateway-api-openapi.yml

## Other Cloudflare APIs (12)

- [Cloudflare Workers AI Clef Decision Models API](https://apis.io/apis/cloudflare/cloudflare-workers-ai-clef-decision-api/)
- [Cloudflare Load Balancing API](https://apis.io/apis/cloudflare/cloudflare-load-balancing-api/)
- [Cloudflare WAF API](https://apis.io/apis/cloudflare/cloudflare-waf-api/)
- [Cloudflare GraphQL Analytics API](https://apis.io/apis/cloudflare/cloudflare-graphql-analytics-api/)
- [Cloudflare Magic Transit API](https://apis.io/apis/cloudflare/cloudflare-magic-transit-api/)
- [Cloudflare Email Routing API](https://apis.io/apis/cloudflare/cloudflare-email-routing-api/)
- [Cloudflare Waiting Room API](https://apis.io/apis/cloudflare/cloudflare-waiting-room-api/)
- [Cloudflare Spectrum API](https://apis.io/apis/cloudflare/cloudflare-spectrum-api/)
- [Cloudflare API Shield API](https://apis.io/apis/cloudflare/cloudflare-api-shield-api/)
- [Cloudflare Zero Trust API](https://apis.io/apis/cloudflare/cloudflare-zero-trust-api/)
- [Cloudflare Registrar API](https://apis.io/apis/cloudflare/cloudflare-registrar-api/)
- [Cloudflare Workflows API](https://apis.io/apis/cloudflare/cloudflare-workflows-api/)

## Tags

AI Gateway

---

Profiled by [API Evangelist](https://apievangelist.com) and published on [APIs.io](https://apis.io/apis/cloudflare/cloudflare-ai-gateway-api/). The API's provider profile, Kin Score and agent-readiness rating are at https://apis.io/providers/cloudflare/.
