Skip to content

Commit

Permalink
update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
thanhhaudev committed Nov 7, 2024
1 parent 6adaac9 commit 7e289f1
Showing 1 changed file with 55 additions and 0 deletions.
55 changes: 55 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,61 @@ The system's database schema is as follows:
## Usage Examples

### GraphQL Queries and Mutations
- **Get all Books**:
```graphql
query {
books {
id
title
authors {
id
name
}
}
}
```

- **Get a Book by ID**:
```graphql
query {
book(id: 1) {
id
title
authors {
id
name
}
}
}
```

- **Get all Authors**:
```graphql
query {
authors {
id
name
books {
id
title
}
}
}
```

- **Get all Borrowers**:
```graphql
query {
borrowers {
id
name
books {
id
title
}
}
}
```

- **Create a Book**:
```graphql
Expand Down

0 comments on commit 7e289f1

Please sign in to comment.