18 lines
422 B
Python
18 lines
422 B
Python
from ariadne import ObjectType
|
|
|
|
query = ObjectType("Query")
|
|
|
|
# Define resolver function for _service field
|
|
@query.field("_service")
|
|
def resolve_service(*_):
|
|
print("Inside the _service resolver")
|
|
# For now, return a placeholder SDL.
|
|
sdl = "type Query { _service: _Service } type _Service { sdl: String }"
|
|
return {"sdl": sdl}
|
|
|
|
service_resolvers = {
|
|
"Query": {
|
|
"_service": resolve_service
|
|
}
|
|
}
|