type RegisterResponse { accessToken: String! refreshToken: String! } enum WorkerKind { COMPLETION CHAT } type Mutation { resetRegistrationToken: String! register(email: String!, password1: String!, password2: String!, invitationCode: String): RegisterResponse! tokenAuth(email: String!, password: String!): TokenAuthResponse! verifyToken(token: String!): VerifyTokenResponse! refreshToken(refreshToken: String!): RefreshTokenResponse! createInvitation(email: String!): Int! deleteInvitation(id: Int!): Int! } type VerifyTokenResponse { claims: Claims! } type UserInfo { email: String! isAdmin: Boolean! } type Claims { exp: Float! iat: Float! user: UserInfo! } type Query { workers: [Worker!]! registrationToken: String! isAdminInitialized: Boolean! invitations: [Invitation!]! me: UserInfo! } type Invitation { id: Int! email: String! code: String! createdAt: String! } type Worker { kind: WorkerKind! name: String! addr: String! device: String! arch: String! cpuInfo: String! cpuCount: Int! cudaDevices: [String!]! } type TokenAuthResponse { accessToken: String! refreshToken: String! } type RefreshTokenResponse { accessToken: String! refreshToken: String! refreshExpiresAt: Float! } schema { query: Query mutation: Mutation }