mirror of
https://codeberg.org/SafeTwitch/safetwitch-backend.git
synced 2024-12-22 05:02:58 -05:00
Update readme
This commit is contained in:
parent
12116d7c9b
commit
45f77b7a3b
1 changed files with 8 additions and 25 deletions
33
README.md
33
README.md
|
@ -12,7 +12,7 @@ Every endpoint can return a 500 status code, and it follows this schema:
|
|||
```json
|
||||
{
|
||||
status: "error",
|
||||
message: "Error message..."
|
||||
data: "Error message..."
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -25,7 +25,7 @@ Gets a specific twitch streamer
|
|||
|
||||
###### 200
|
||||
|
||||
The request was successful, returns data of type [StreamerData](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/types/scraping/Streamer.ts)
|
||||
The request was successful, returns data of type [Streamer](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/extractor/structs/parsed.go)
|
||||
*Example:*
|
||||
|
||||
```json
|
||||
|
@ -35,6 +35,7 @@ The request was successful, returns data of type [StreamerData](https://codeberg
|
|||
"username": "filian",
|
||||
"about": "Welcome to my Vtuber alpha! 3D streaming and variety games! Join the discord! n_n",
|
||||
"pfp": "https://safetwitch.dragongoose.us/proxy/img/aHR0cHM6Ly9zdGF0aWMtY2RuLmp0dm53Lm5ldC9qdHZfdXNlcl9waWN0dXJlcy9mNzVkNDEwMy1hMjY1LTRlMjEtODhiNS00NDc0NWZjMWJmNDQtcHJvZmlsZV9pbWFnZS0zMDB4MzAwLnBuZw",
|
||||
"banner": "https://safetwitch.dragongoose.us/proxy/img/aHR0cHM6Ly9zdGF0aWMtY2RuLmp0dm53Lm5ldC9qdHZfdXNlcl9waWN0dXJlcy9kMjY2OTZlMC1hYjJhLTRlZjEtYTI3Ni0wZmZjZWM5NmM3NzYtcHJvZmlsZV9iYW5uZXItNDgwLnBuZw==",
|
||||
"followers": 579463,
|
||||
"socials": [
|
||||
{
|
||||
|
@ -70,7 +71,7 @@ Gets the discover page of twitch, a list of categories
|
|||
|
||||
##### 200
|
||||
|
||||
The request was successful, returns a [Category[]](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/types/scraping/Category.ts)
|
||||
The request was successful, returns a [CategoryData[]](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/extractor/structs/parsed.go)
|
||||
*Example:*
|
||||
|
||||
```json
|
||||
|
@ -101,7 +102,7 @@ Gets a specific twitch category
|
|||
|
||||
##### 200
|
||||
|
||||
The server found the category, returns data of type [CategoryData[]](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/types/scraping/CategoryData.ts)
|
||||
The server found the category, returns data of type [CategoryPreview[]](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/extractor/structs/parsed.go)
|
||||
*Example:*
|
||||
|
||||
```json
|
||||
|
@ -154,7 +155,7 @@ streamerName query is optional, if given it will only provide the badges for tha
|
|||
|
||||
##### 200
|
||||
|
||||
Server retrieved the badges, returns type [Badge[]](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/types/scraping/Streamer.ts)
|
||||
Server retrieved the badges, returns type [Badge[]](hhttps://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/extractor/structs/parsed.go)
|
||||
*Example:*
|
||||
|
||||
```json
|
||||
|
@ -180,7 +181,7 @@ Server retrieved the badges, returns type [Badge[]](https://codeberg.org/dragong
|
|||
### /api/search?query=SEARCHQUERY
|
||||
|
||||
**GET** - SEARCHQUERY is any string
|
||||
Searches for categories, streamers, tags, and live streamers. Returns data of type [SearchResult]()
|
||||
Searches for categories, streamers, tags, and live streamers. Returns data of type [SearchResult](https://codeberg.org/dragongoose/safetwitch-backend/src/branch/master/extractor/structs/parsed.go)
|
||||
|
||||
|
||||
|
||||
|
@ -268,24 +269,6 @@ The server found the search data, returns:
|
|||
}
|
||||
```
|
||||
|
||||
### /api/emotes/:streamerName
|
||||
**GET**
|
||||
Gets all of the emotes for a streamer
|
||||
|
||||
#### Resposnes
|
||||
##### 200
|
||||
Returns the found Emotes
|
||||
*Example:*
|
||||
```json
|
||||
{
|
||||
"name": "fillyTailChase",
|
||||
"urls": {
|
||||
"1": "..."
|
||||
}
|
||||
},
|
||||
...
|
||||
```
|
||||
|
||||
## Proxying Endpoints
|
||||
|
||||
### /proxy/img/:base64Url
|
||||
|
@ -323,7 +306,7 @@ The streamer is not live
|
|||
```json
|
||||
{
|
||||
"status": "error",
|
||||
"message": "Streamer is not live"
|
||||
"data": "Streamer is not live"
|
||||
}
|
||||
```
|
||||
|
||||
|
|
Loading…
Reference in a new issue