skillbox/server/api/schema_public.py

25 lines
575 B
Python

import graphene
from django.conf import settings
from graphene import relay
from graphene_django.debug import DjangoDebug
from users.schema_public import UsersQuery
from users.mutations_public import UserMutations
class Query(UsersQuery, graphene.ObjectType):
node = relay.Node.Field()
if settings.DEBUG:
debug = graphene.Field(DjangoDebug, name='__debug')
class Mutation(UserMutations, graphene.ObjectType):
if settings.DEBUG:
debug = graphene.Field(DjangoDebug, name='__debug')
schema = graphene.Schema(query=Query, mutation=Mutation)