Skip to content
Merged
Show file tree
Hide file tree
Changes from 20 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ slug: 1.1.1.1/encryption/dns-over-https/make-api-requests/dns-wireformat

Cloudflare respects DNS wireformat as defined in [RFC 1035](https://www.rfc-editor.org/rfc/rfc1035.html).

To send queries using DNS wireformat, set the header `accept: application/dns-message`, or `content-type: application/dns-message` if using `POST` to signalize the media type of the query.
To send queries using DNS wireformat, set the header `accept: application/dns-message`, or `content-type: application/dns-message` if using `POST` to indicate the media type of the query.

Queries using DNS wireformat can be sent using `POST` or `GET`.

Expand Down
2 changes: 1 addition & 1 deletion src/content/docs/1.1.1.1/setup/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ You can also set up [1.1.1.1 for Families](#1111-for-families) for an added laye
1.1.1.1 for Families has two default options:


<Details header="Block malware">
<Details header='Block malware'>

Use the following DNS resolvers to block malicious content:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ export class MyAgent extends Agent<Env> {

</TypeScriptExample>

You can also supply a [TypeScript type argument](https://www.typescriptlang.org/docs/handbook/2/generics.html#using-type-parameters-in-generic-constraints) the query, which will be used to infer the type of the result:
You can also supply a [TypeScript type argument](https://www.typescriptlang.org/docs/handbook/2/generics.html#using-type-parameters-in-generic-constraints) to the query, which will be used to infer the type of the result:

```ts
type User = {
Expand All @@ -209,7 +209,7 @@ type User = {
export class MyAgent extends Agent<Env> {
async onRequest(request: Request) {
let userId = new URL(request.url).searchParams.get('userId');
// Supply the type paramter to the query when calling this.sql
// Supply the type parameter to the query when calling this.sql
// This assumes the results returns one or more User rows with "id", "name", and "email" columns
const user = await this.sql<User>`SELECT * FROM users WHERE id = ${userId}`;
return Response.json(user)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { Render } from "~/components"

Cloudflare runs a catalog of managed remote MCP Servers which you can connect to using OAuth on clients like [Claude](https://modelcontextprotocol.io/quickstart/user), [Windsurf](https://docs.windsurf.com/windsurf/cascade/mcp), our own [AI Playground](https://playground.ai.cloudflare.com/) or any [SDK that supports MCP](https://github.com/cloudflare/agents/tree/main/packages/agents/src/mcp).

These MCP servers allow your MCP Client to read configurations from your account, process information, make suggestions based on data, and even make those suggested changes for you. All of these actions can happen across cloudflare's many services including application development, security and performance.
All of these actions can happen across Cloudflare's many services including application development, security and performance.

| Server Name | Description | Server URL |
| -------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ---------------------------------------------- |
Expand All @@ -30,4 +30,5 @@ These MCP servers allow your MCP Client to read configurations from your account
| [Cloudflare One CASB server](https://github.com/cloudflare/mcp-server-cloudflare/tree/main/apps/cloudflare-one-casb) | Quickly identify any security misconfigurations for SaaS applications to safeguard users & data | `https://casb.mcp.cloudflare.com/sse` |
| [GraphQL server](https://github.com/cloudflare/mcp-server-cloudflare/tree/main/apps/graphql/) | Get analytics data using Cloudflare’s GraphQL API | `https://graphql.mcp.cloudflare.com/sse` |

Check our [GitHub page](https://github.com/cloudflare/mcp-server-cloudflare) to know how to use Cloudflare's remote MCP servers with different MCP clients.
Check our [GitHub page](https://github.com/cloudflare/mcp-server-cloudflare) to know how to use Cloudflare's remote MCP servers with different MCP clients.

4 changes: 2 additions & 2 deletions src/content/docs/ai-gateway/chat-completion.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ curl -X POST https://gateway.ai.cloudflare.com/v1/{account_id}/{gateway_id}/comp

### Universal provider

You can also use this pattern with the [Universal Endpoint](/ai-gateway/universal/) to add [fallbacks](/ai-gateway/configuration/fallbacks/) across multiple providers. When used in combination, every request will return the same standardized format, whether from the primary or fallback model. This behavior means that you do not have to add extra parsing logic to your app.
You can also use this pattern with the [Universal Endpoint](/ai-gateway/universal/) to add [fallbacks](/ai-gateway/configuration/fallbacks/) across multiple providers. When used in combination, every request will return the same standardized format, whether from the primary or fallback model. This behavior means that you do not have to add extra parsing logic to your app.

```ts title="index.ts"
export interface Env {
Expand All @@ -77,7 +77,7 @@ export default {
provider: "compat",
endpoint: "chat/completions",
headers: {
authorization: "Bearer ",
authorization: "Bearer",
},
query: {
model: "google-ai-studio/gemini-2.0-flash",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ To illustrate this, let us say you had a limit of ten requests per ten minutes,

## Handling rate limits

When your requests exceed the allowed rate, you'll encounter rate limiting. This means the server will respond with a `429 Too Many Requests` status code and your request won't be processed.
When your requests exceed the allowed rate, you will encounter rate limiting. This means the server will respond with a `429 Too Many Requests` status code and your request will not be processed.

## Default configuration

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ In the example below, the `cf-aig-log-id` is `01JADMCQQQBWH3NXZ5GCRN98DP`.

### Method 2: Retrieve the `cf-aig-log-id` via API (GET request)

If you don't have the `cf-aig-log-id` in the response body or you need to access it after the fact, you can retrieve it by querying the logs using the [Cloudflare API](/api/resources/ai_gateway/subresources/logs/methods/list/).
If you do not have the `cf-aig-log-id` in the response body or you need to access it after the fact, you are able to retrieve it by querying the logs using the [Cloudflare API](/api/resources/ai_gateway/subresources/logs/methods/list/).

The steps below outline how to do this.

Expand Down
2 changes: 1 addition & 1 deletion src/content/docs/ai-gateway/providers/grok.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ pcx_content_type: get-started

import { Render } from "~/components";

[Grok](https://docs.x.ai/docs#getting-started) is s a general purpose model that can be used for a variety of tasks, including generating and understanding text, code, and function calling.
[Grok](https://docs.x.ai/docs#getting-started) is a general purpose model that can be used for a variety of tasks, including generating and understanding text, code, and function calling.

## Endpoint

Expand Down
Loading