POST /accounts/{account_id}/ai-search/instances/{id}/search
SearchServers
- https://api.cloudflare.com/client/v4
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id |
String | Yes |
Use your AI Search ID. |
account_id |
String | Yes |
Request headers
| Name | Type | Required | Description |
|---|---|---|---|
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/json" |
Request body fields
| Name | Type | Required | Description |
|---|---|---|---|
ai_search_options |
Object | No | |
ai_search_options.reranking |
Object | No | |
ai_search_options.reranking.match_threshold |
Number | No |
Default value: 0.4 |
ai_search_options.reranking.enabled |
Boolean | No | |
ai_search_options.reranking.model |
No | ||
ai_search_options.query_rewrite |
Object | No | |
ai_search_options.query_rewrite.enabled |
Boolean | No | |
ai_search_options.query_rewrite.model |
No | ||
ai_search_options.query_rewrite.rewrite_prompt |
String | No | |
ai_search_options.retrieval |
Object | No | |
ai_search_options.retrieval.filters |
Object | No | |
ai_search_options.retrieval.context_expansion |
Integer | No |
Default value: 0 |
ai_search_options.retrieval.retrieval_type |
String | No |
Valid values:
|
ai_search_options.retrieval.fusion_method |
String | No |
Valid values:
|
ai_search_options.retrieval.match_threshold |
Number | No |
Default value: 0.4 |
ai_search_options.retrieval.keyword_match_mode |
String | No |
Controls how keyword search terms are matched. exact_match requires all terms to appear (AND); fuzzy_match returns results containing any term (OR). Defaults to exact_match. Valid values:
Default value: "exact_match" |
ai_search_options.retrieval.max_num_results |
Integer | No |
Default value: 10 |
ai_search_options.retrieval.return_on_failure |
Boolean | No |
Default value: true |
messages[] |
Array | Yes | |
messages[].content |
String | Yes | |
messages[].role |
String | Yes |
Valid values:
|
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.