https://github.com/japiirainen/go-oluet-api
Graphql API for querying all kinds of beer and other drinks!
https://github.com/japiirainen/go-oluet-api
api beer go golang graphql oluet-api
Last synced: 3 months ago
JSON representation
Graphql API for querying all kinds of beer and other drinks!
- Host: GitHub
- URL: https://github.com/japiirainen/go-oluet-api
- Owner: japiirainen
- License: mit
- Created: 2020-12-27T12:35:26.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2021-01-23T12:39:59.000Z (over 4 years ago)
- Last Synced: 2024-04-24T08:15:43.476Z (over 1 year ago)
- Topics: api, beer, go, golang, graphql, oluet-api
- Language: Go
- Homepage: https://oluet-api.xyz
- Size: 7.74 MB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Oluet-api
API for finding information about you favorive alcoholic beverages!😎
(not only beer!)
## This is a rewrite of my oluet-api in go!
- The poject was originally written in nodejs, but I decided to start learning glo and thought this was a good place to start exploring!
## Links
- [Homepage](https://oluet-api.xyz)
- [Graphql playground](https://oluet-api.xyz/graphql)
- [API](https://oluet-api.xyz/query)If you don't know graphql playground is a great place to try out some queries straight from you favorite browser. Give it a shot!
## API documentation v1
### Graphql endpoint
This endpoint is used by all of the queries. You should read the
official graphql documentation on more information about the
technology if it's new for you!
[Graphal docs](https://graphql.org)
```
https://oluet-api.xyz/query
```### Graphql playground endpoint
If you are not yet familiar with graphql you are going to love the
playground! There is no need to use tools like Postman with graphql
since you can test your queries straight from the playground! You
should also see the docs for playground to utilize it's full
potential!
[Graphal playground docs](https://github.com/graphql/graphql-playground)
```
https://oluet-api.xyz/graphql
```### Sample queries
You can experiment with these at the playground!
### List all drinks
```
query {
drinks {
nimi
date
productID
hinta
tyyppi
}
}
```### List all beers
```
query {
beers {
nimi
date
olutTyyppi
hinta
tyyppi
}
}
```### Search for all "karhu" beers
```
query {
beersearch(term: "karhu") {
nimi
date
valmistaja
huomautus
olutTyyppi
hinta
tyyppi
}
}
```### Search for all "karhu" beers
```
query {
pricehistory(productID:"792176") {
hinta
date
}
}
```## TODO
1. maybe make a separate type for olut