LCORE-1356: Updated OpenAPI specification#1239
Conversation
WalkthroughUpdates to OpenAPI specification documents to reflect changes in A2A endpoint operation identifiers, adds header propagation support to MCP server schemas, implements validation patterns for system info fields, and documents a new streaming query interrupt endpoint with associated request and response models. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~15 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
docs/openapi.json (1)
4450-4468:⚠️ Potential issue | 🟠 MajorFix duplicate
operationIdfor GET and POST/a2aendpoints.Both GET and POST operations on the
/a2apath use the sameoperationId:handle_a2a_jsonrpc_a2a_post. This violates OpenAPI specifications and will break client code generation. The GET operation must use a unique operationId.Proposed fix
"get": { "tags": [ "a2a" ], "summary": "Handle A2A Jsonrpc", "description": "Handle A2A JSON-RPC requests following the A2A protocol specification.\n\nThis endpoint uses the DefaultRequestHandler from the A2A SDK to handle\nall JSON-RPC requests including message/send, message/stream, etc.\n\nThe A2A SDK application is created per-request to include authentication\ncontext while still leveraging FastAPI's authorization middleware.\n\nAutomatically detects streaming requests (message/stream JSON-RPC method)\nand returns a StreamingResponse to enable real-time chunk delivery.\n\nArgs:\n request: FastAPI request object\n auth: Authentication tuple\n mcp_headers: MCP headers for context propagation\n\nReturns:\n JSON-RPC response or streaming response", - "operationId": "handle_a2a_jsonrpc_a2a_post", + "operationId": "handle_a2a_jsonrpc_a2a_get",🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/openapi.json` around lines 4450 - 4468, The GET and POST operations for the /a2a path both use the identical operationId "handle_a2a_jsonrpc_a2a_post", which violates OpenAPI rules; change the GET operationId to a unique name (e.g., "handle_a2a_jsonrpc_a2a_get") wherever the GET operation definition appears and update any tooling/client references that expect the old GET id so they point to the new id (search for "handle_a2a_jsonrpc_a2a_post" in the GET block and replace it with the new GET-specific operationId).
🧹 Nitpick comments (1)
docs/openapi.md (1)
5535-5547: Consider adding an example for consistency.The
StreamingInterruptRequestmodel is well-documented, but it would be more consistent with the relatedStreamingInterruptResponsemodel (which includes an example) to add a usage example here as well.📝 Suggested addition for consistency
## StreamingInterruptRequest Model representing a request to interrupt an active streaming query. Attributes: request_id: Unique ID of the active streaming request to interrupt. + +Example: + ```python + request = StreamingInterruptRequest( + request_id="123e4567-e89b-12d3-a456-426614174000" + ) + ``` | Field | Type | Description |🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/openapi.md` around lines 5535 - 5547, Add a usage example for the StreamingInterruptRequest model to match StreamingInterruptResponse; update the documentation block for StreamingInterruptRequest by inserting a short example showing instantiation of StreamingInterruptRequest with a sample UUID for request_id (e.g., "123e4567-e89b-12d3-a456-426614174000") immediately after the descriptive paragraph and before the Field table so readers see concrete usage; ensure the example follows the same formatting style as the StreamingInterruptResponse example.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In `@docs/openapi.json`:
- Around line 4450-4468: The GET and POST operations for the /a2a path both use
the identical operationId "handle_a2a_jsonrpc_a2a_post", which violates OpenAPI
rules; change the GET operationId to a unique name (e.g.,
"handle_a2a_jsonrpc_a2a_get") wherever the GET operation definition appears and
update any tooling/client references that expect the old GET id so they point to
the new id (search for "handle_a2a_jsonrpc_a2a_post" in the GET block and
replace it with the new GET-specific operationId).
---
Nitpick comments:
In `@docs/openapi.md`:
- Around line 5535-5547: Add a usage example for the StreamingInterruptRequest
model to match StreamingInterruptResponse; update the documentation block for
StreamingInterruptRequest by inserting a short example showing instantiation of
StreamingInterruptRequest with a sample UUID for request_id (e.g.,
"123e4567-e89b-12d3-a456-426614174000") immediately after the descriptive
paragraph and before the Field table so readers see concrete usage; ensure the
example follows the same formatting style as the StreamingInterruptResponse
example.
Description
LCORE-1356: Updated OpenAPI specification
Type of change
Tools used to create PR
Related Tickets & Documents
Summary by CodeRabbit
Release Notes
New Features
Documentation