Skip to content

Commit 925fcde

Browse files
committed
adding queries to readme
1 parent 7a38028 commit 925fcde

File tree

2 files changed

+57
-5
lines changed

2 files changed

+57
-5
lines changed

README.md

Lines changed: 57 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -114,13 +114,65 @@ mutation {
114114
```
115115

116116
#### UPDATE A BOOK
117-
TODO
117+
```
118+
mutation {
119+
updateBook(bookId: 8, author:"Unknown Author"){
120+
book{
121+
id
122+
author
123+
description
124+
}
125+
}
126+
}
127+
```
118128

119129
#### DELETE A BOOK
120-
TODO
130+
```
131+
mutation {
132+
deleteBook(bookId: 8){
133+
bookId
134+
}
135+
}
136+
```
137+
121138
#### LIKE A BOOK
122-
TODO
139+
```
140+
mutation {
141+
createLike(bookId: 8) {
142+
user {
143+
id
144+
username
145+
}
146+
}
147+
}
148+
```
149+
123150
#### CHECK HOW MANY LIKES ARE ON BOOKS
124-
TODO
151+
```
152+
query {
153+
books {
154+
id
155+
title
156+
description
157+
likes {
158+
id
159+
user {
160+
id
161+
username
162+
}
163+
}
164+
}
165+
}
166+
```
167+
125168
#### SEARCH A BOOK
126-
TODO
169+
```
170+
query{
171+
books(search: "python") {
172+
id
173+
title
174+
author
175+
description
176+
}
177+
}
178+
```

app/db.sqlite3

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)