This commit is contained in:
春河晴
2025-04-24 13:52:48 +09:00
parent f09a65e510
commit cefd8aa5b7
3 changed files with 23 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
import strawberry
from fastapi import FastAPI
from strawberry.fastapi import GraphQLRouter
from src.common.server import global_server
@strawberry.type
class Query:
@strawberry.field
def hello(self) -> str:
return "Hello World"
schema = strawberry.Schema(Query)
graphql_app = GraphQLRouter(schema)
fast_api_app: FastAPI = global_server.get_app()
fast_api_app.include_router(graphql_app, prefix="/graphql")

View File

@@ -0,0 +1 @@
pass