AI Search introduces OpenAI-compatible REST API endpoints with chat completions support
Key Points
- OpenAI-compatible REST API endpoints launched
- Multi-turn conversation context support added
- Migration from AutoRAG API recommended
Summary
Cloudflare AI Search has released new REST API endpoints that provide OpenAI-compatible formatting for search and chat completions. The new endpoints support familiar messages array structure and maintain conversational context across multiple turns.
Key Points
-
New Endpoints Available:
POST /accounts/{account_id}/ai-search/instances/{name}/chat/completionsPOST /accounts/{account_id}/ai-search/instances/{name}/search
-
OpenAI Compatibility: Uses standard
messagesarray format compatible with existing OpenAI SDKs and tools -
Context Preservation: Supports passing previous messages within sessions for multi-turn conversations
-
Migration Recommended: Users should migrate from legacy AutoRAG API endpoints (
/autorag/rags/) as new features will only be added to the new endpoints -
Deprecation Timeline: Legacy AutoRAG endpoints will continue working with at least 90 days notice before any breaking changes