85 lines
1.3 KiB
GraphQL
85 lines
1.3 KiB
GraphQL
# GraphQL schema example
|
|
#
|
|
# https://gqlgen.com/getting-started/
|
|
scalar Int64
|
|
|
|
type User {
|
|
id: ID!
|
|
email: String!
|
|
SignUpMethod: String!
|
|
firstName: String
|
|
lastName: String
|
|
emailVerifiedAt: Int64
|
|
password: String
|
|
image: String
|
|
createdAt: Int64
|
|
updatedAt: Int64
|
|
}
|
|
|
|
type VerificationRequest {
|
|
id: ID!
|
|
identifier: String
|
|
token: String
|
|
email: String
|
|
expires: Int64
|
|
createdAt: Int64
|
|
updatedAt: Int64
|
|
}
|
|
|
|
type Error {
|
|
message: String!
|
|
reason: String!
|
|
}
|
|
|
|
type Response {
|
|
success: Boolean!
|
|
message: String!
|
|
errors: [Error!]
|
|
statusCode: Int!
|
|
}
|
|
|
|
type BasicAuthLoginResponse {
|
|
success: Boolean!
|
|
message: String!
|
|
errors: [Error!]
|
|
statusCode: Int!
|
|
refreshToken: String
|
|
user: User
|
|
}
|
|
|
|
type BasicAuthSignupResponse {
|
|
success: Boolean!
|
|
message: String!
|
|
errors: [Error!]
|
|
statusCode: Int!
|
|
user: User
|
|
}
|
|
|
|
type Query {
|
|
users: [User!]!
|
|
}
|
|
|
|
input BasicAuthSignupInput {
|
|
firstName: String
|
|
lastName: String
|
|
email: String!
|
|
password: String!
|
|
cofirmPassword: String!
|
|
image: String
|
|
}
|
|
|
|
input BasicAuthLoginInput {
|
|
email: String!
|
|
password: String!
|
|
}
|
|
|
|
input VerifySignupTokenInput {
|
|
token: String!
|
|
}
|
|
|
|
type Mutation {
|
|
verifySignupToken(params: VerifySignupTokenInput!): Response!
|
|
basicAuthSignUp(params: BasicAuthSignupInput!): BasicAuthSignupResponse!
|
|
basicAuthLogin(params: BasicAuthLoginInput!): BasicAuthLoginResponse!
|
|
}
|