2021-06-09 14:44:14 +02:00
|
|
|
# MovieQuoteBot API
|
|
|
|
|
|
|
|
A simple API written in Rust for MovieQuoteBot that returns JSON data via HTTP.
|
|
|
|
|
|
|
|
> This API is in an unstable state: it will surely change a lot.
|
|
|
|
|
2021-06-09 16:23:48 +02:00
|
|
|
The data Structures are like:
|
|
|
|
|
|
|
|
![this image describing the data Structures in MoviesQuoteBot's database](https://gitlab.com/lovallat/moviesquotebot/-/raw/master/DatabaseSchema.png)
|
|
|
|
|
|
|
|
Except the user ids that have been redacted and removed from the API.
|
|
|
|
|
2021-06-09 14:44:14 +02:00
|
|
|
## Endpoints
|
|
|
|
|
2021-06-09 16:23:48 +02:00
|
|
|
## Health
|
|
|
|
|
|
|
|
You can query `/health` and if `Healthy` is returned, the API is alive.
|
|
|
|
|
2021-06-09 14:44:14 +02:00
|
|
|
### V1
|
|
|
|
|
|
|
|
#### List subtitles
|
|
|
|
|
2021-06-09 16:23:48 +02:00
|
|
|
You can use `/v1/subtitles/list` to list subtitles stored in database.
|
2021-06-09 14:44:14 +02:00
|
|
|
|
|
|
|
##### Structure
|
|
|
|
|
|
|
|
- `subtitles`: all subtitles stored in database
|
|
|
|
- `films`: the films associated with these subtitles, linked by their id: `subtitles.film_id` -> `films.id`
|
|
|
|
- `languages`: the languages associated with these subtitles, linked by their id: `subtitles.language_id` -> `languages.id`
|
|
|
|
|
|
|
|
The time is represented using the UTC Timezone.
|
|
|
|
|
2021-06-09 16:23:48 +02:00
|
|
|
#### List subtitles
|
|
|
|
|
|
|
|
You can use `/v1/languages/list` to list languages stored in database.
|