AI Search (2)
AI SearchNamespaces
List namespaces
GET/accounts/{account_id}/ai-search/namespaces
Create a namespace
POST/accounts/{account_id}/ai-search/namespaces
Get a namespace
GET/accounts/{account_id}/ai-search/namespaces/{name}
Update a namespace
PUT/accounts/{account_id}/ai-search/namespaces/{name}
Delete a namespace
DELETE/accounts/{account_id}/ai-search/namespaces/{name}
Multi-Instance Search
POST/accounts/{account_id}/ai-search/namespaces/{name}/search
Multi-Instance Chat Completions
POST/accounts/{account_id}/ai-search/namespaces/{name}/chat/completions
ModelsExpand Collapse
<details>
<summary>
NamespaceListResponse object {created_at, name, description, 2 more }
</summary>
created_at: string
formatdate-time
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20created_at">Link to this property</a>
name: string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20name">Link to this property</a>
description: optional string
Optional description for the namespace. Max 256 characters.
maxLength256
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20description">Link to this property</a>
public_endpoint_id: optional string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_id">Link to this property</a>
<details>
<summary>
public_endpoint_params: optional object {authorized_hosts, chat_completions_endpoint, custom_domains, 6 more }
</summary>
authorized_hosts: optional array of string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20authorized_hosts">Link to this property</a>
<details>
<summary>
chat_completions_endpoint: optional object {disabled }
</summary>
disabled: optional boolean
Disable chat completions endpoint for this public endpoint.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20chat_completions_endpoint%20%3E%20(property)%20disabled">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20chat_completions_endpoint">Link to this property</a>
custom_domains: optional array of string
Custom domain hostnames that alias this public endpoint. GET and create responses return the current set; on update (PUT) this field is only echoed back when supplied in the request body, otherwise it is null (omit it to leave domains unchanged).
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20custom_domains">Link to this property</a>
default_domain_enabled: optional boolean
When false, the instance is reachable only via a registered custom domain and the default <public_endpoint_id>.search.ai.cloudflare.com host returns 404. Requires at least one custom domain. Defaults to true. public_endpoint_params is replaced wholesale on update, so resend default_domain_enabled on every update to keep the default host off — omitting it resets to true.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20default_domain_enabled">Link to this property</a>
enabled: optional boolean
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20enabled">Link to this property</a>
instances_allowed: optional array of string
Instance IDs exposed through the namespace public endpoint. Empty means nothing is searchable. Every ID must reference an existing instance in this namespace, and the list must stay within the account’s multi-instance search limit.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20instances_allowed">Link to this property</a>
<details>
<summary>
mcp: optional object {description, disabled }
</summary>
description: optional string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20mcp%20%3E%20(property)%20description">Link to this property</a>
disabled: optional boolean
Disable MCP endpoint for this public endpoint.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20mcp%20%3E%20(property)%20disabled">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20mcp">Link to this property</a>
<details>
<summary>
rate_limit: optional object {period_ms, requests, technique }
</summary>
period_ms: optional number
maximum3600000
minimum60000
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20period_ms">Link to this property</a>
requests: optional number
minimum1
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20requests">Link to this property</a>
<details>
<summary>
technique: optional "fixed"or "sliding"
</summary>
One of the following:
"fixed"
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20technique%20%3E%20(member)%200">Link to this property</a>
"sliding"
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20technique%20%3E%20(member)%201">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20technique">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit">Link to this property</a>
<details>
<summary>
search_endpoint: optional object {disabled }
</summary>
disabled: optional boolean
Disable search endpoint for this public endpoint.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20search_endpoint%20%3E%20(property)%20disabled">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20search_endpoint">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_list_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params">Link to this property</a>
</details>
<details>
<summary>
NamespaceCreateResponse object {created_at, name, description, 2 more }
</summary>
created_at: string
formatdate-time
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20created_at">Link to this property</a>
name: string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20name">Link to this property</a>
description: optional string
Optional description for the namespace. Max 256 characters.
maxLength256
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20description">Link to this property</a>
public_endpoint_id: optional string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_id">Link to this property</a>
<details>
<summary>
public_endpoint_params: optional object {authorized_hosts, chat_completions_endpoint, custom_domains, 6 more }
</summary>
authorized_hosts: optional array of string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20authorized_hosts">Link to this property</a>
<details>
<summary>
chat_completions_endpoint: optional object {disabled }
</summary>
disabled: optional boolean
Disable chat completions endpoint for this public endpoint.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20chat_completions_endpoint%20%3E%20(property)%20disabled">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20chat_completions_endpoint">Link to this property</a>
custom_domains: optional array of string
Custom domain hostnames that alias this public endpoint. GET and create responses return the current set; on update (PUT) this field is only echoed back when supplied in the request body, otherwise it is null (omit it to leave domains unchanged).
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20custom_domains">Link to this property</a>
default_domain_enabled: optional boolean
When false, the instance is reachable only via a registered custom domain and the default <public_endpoint_id>.search.ai.cloudflare.com host returns 404. Requires at least one custom domain. Defaults to true. public_endpoint_params is replaced wholesale on update, so resend default_domain_enabled on every update to keep the default host off — omitting it resets to true.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20default_domain_enabled">Link to this property</a>
enabled: optional boolean
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20enabled">Link to this property</a>
instances_allowed: optional array of string
Instance IDs exposed through the namespace public endpoint. Empty means nothing is searchable. Every ID must reference an existing instance in this namespace, and the list must stay within the account’s multi-instance search limit.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20instances_allowed">Link to this property</a>
<details>
<summary>
mcp: optional object {description, disabled }
</summary>
description: optional string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20mcp%20%3E%20(property)%20description">Link to this property</a>
disabled: optional boolean
Disable MCP endpoint for this public endpoint.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20mcp%20%3E%20(property)%20disabled">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20mcp">Link to this property</a>
<details>
<summary>
rate_limit: optional object {period_ms, requests, technique }
</summary>
period_ms: optional number
maximum3600000
minimum60000
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20period_ms">Link to this property</a>
requests: optional number
minimum1
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20requests">Link to this property</a>
<details>
<summary>
technique: optional "fixed"or "sliding"
</summary>
One of the following:
"fixed"
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20technique%20%3E%20(member)%200">Link to this property</a>
"sliding"
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20technique%20%3E%20(member)%201">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit%20%3E%20(property)%20technique">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20rate_limit">Link to this property</a>
<details>
<summary>
search_endpoint: optional object {disabled }
</summary>
disabled: optional boolean
Disable search endpoint for this public endpoint.
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20search_endpoint%20%3E%20(property)%20disabled">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20search_endpoint">Link to this property</a>
</details>
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_create_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params">Link to this property</a>
</details>
<details>
<summary>
NamespaceReadResponse object {created_at, name, description, 2 more }
</summary>
created_at: string
formatdate-time
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_read_response%20%3E%20(schema)%20%3E%20(property)%20created_at">Link to this property</a>
name: string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_read_response%20%3E%20(schema)%20%3E%20(property)%20name">Link to this property</a>
description: optional string
Optional description for the namespace. Max 256 characters.
maxLength256
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_read_response%20%3E%20(schema)%20%3E%20(property)%20description">Link to this property</a>
public_endpoint_id: optional string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_read_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_id">Link to this property</a>
<details>
<summary>
public_endpoint_params: optional object {authorized_hosts, chat_completions_endpoint, custom_domains, 6 more }
</summary>
authorized_hosts: optional array of string
<a href="#(resource)%20ai_search.namespaces%20%3E%20(model)%20namespace_read_response%20%3E%20(schema)%20%3E%20(property)%20public_endpoint_params%20%3E%20(property)%20authorized_hosts">Link to this property</a>
