Skip to content

Commit 280f78e

Browse files
committed
feat: add graphql mutations, queries and types
0 parents  commit 280f78e

File tree

3 files changed

+25
-0
lines changed

3 files changed

+25
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
type Mutation {
2+
userSignup(username: String!, email: String!, password: String!): User!
3+
createTodo(title: String!, description: String!): Todo!
4+
deleteTodo(id: ID!): String!
5+
updateTodo(title: String!, description: String!, status: Boolean!): Todo!
6+
completeTodo: Todo!
7+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
type Query {
2+
getTodos(userid: ID!): [Todo!]
3+
userLogin(email: String!, password: String!): User!
4+
}
+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
type Todo {
2+
id: ID!
3+
title: String!
4+
description: String!
5+
status: Boolean!
6+
userid: ID!
7+
}
8+
9+
type User {
10+
id: ID!
11+
username: String!
12+
email: String!
13+
password: String!
14+
}

0 commit comments

Comments
 (0)