Add support for batched GraphQL responses
This commit is contained in:
parent
70e2f4cebd
commit
1c13e25b17
2 changed files with 27 additions and 0 deletions
|
|
@ -449,3 +449,20 @@ class GraphQLResponse(BaseModel):
|
|||
"strict": True,
|
||||
"populate_by_name": True,
|
||||
}
|
||||
|
||||
|
||||
class BatchedGraphQLResponse(BaseModel):
|
||||
"""Schema for batched GraphQL responses wrapped in a 'responses' array.
|
||||
|
||||
Handles cases where multiple GraphQL responses are collected and wrapped
|
||||
in an outer object with a 'responses' field.
|
||||
"""
|
||||
|
||||
responses: list[GraphQLResponse]
|
||||
|
||||
model_config = {
|
||||
"extra": "forbid",
|
||||
"validate_assignment": True,
|
||||
"strict": True,
|
||||
"populate_by_name": True,
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue