Vidstream API
This project includes:
- A scraper for the website "vidstream.to"
- A parser for the stream provider "rabbitstream.net"
[!IMPORTANT]
- This API is just an unofficial api for vidstream.to and is in no other way officially related to the same.
- The content that this api provides is not mine, nor is it hosted by me. These belong to their respective owners. This api just demonstrates how to build an api that scrapes websites and uses their content.
Contents
API Documentation
### `GET` Home Page
```
/home
```
```javascript
{
spotlight: [
{
id: string,
title: string,
banner: string,
poster: string,
rating: string,
year: string,
},
{ ... }
],
trending: {
movies: [
{
id: string,
title: string,
poster: string,
stats: {
duration: string,
rating: string,
year: string,
}
},
{ ... }
],
tvSeries: [
{
id: string,
title: string,
poster: string,
stats: {
seasons: string,
rating: string,
}
},
{ ... }
]
},
latestMovies: [
{
id: string,
title: string,
poster: string,
stats: {
duration: string,
rating: string,
year: string,
}
},
{ ... }
],
latestTvSeries: [
{
id: string,
title: string,
poster: string,
stats: {
seasons: string,
rating: string,
}
},
{ ... }
]
}
```
### `GET` Search
```
/search?q={searchQuery}&page={pageIndex}
```
| Parameter | Type | Description | Required? | Default |
| :------------------: | :----: | :-----------------------------------: | :-------: | :-----: |
| `searchQuery` | string | The search string. E.g. "family guy". | Yes | -- |
| `pageIndex` | number | The index of the page. | No | 1 |
```javascript
{
items: [
{
id: string,
title: string,
poster: string,
stats: {
duration: string,
rating: string,
year: string,
}
},
{
id: string,
title: string,
poster: string,
stats: {
seasons: string,
rating: string,
}
},
{ ... }
],
pagination: {
current: number,
total: number,
}
}
```
### `GET` Movie Details
```
/movie/{movieId}
```
| Parameter | Type | Description | Required? | Default |
| :----------------: | :----: | :---------------------------------: | :-------: | :-----: |
| `movieId` | string | The movie id given in e.g. `/home`. | Yes | -- |
episodeId is only available when type is equal to movie and only has one episode.
```javascript
{
title: string,
description: string,
type: "movie" | "tvSeries",
stats: { name: string, value: string | string[] }[],
episodeId?: string,
related: [
{
id: string,
title: string,
poster: string,
stats: {
seasons: string,
rating: string,
}
},
{
id: string,
title: string,
poster: string,
stats: {
year: string,
duration: string,
rating: string,
}
},
{ ... }
]
}
```
### `GET` Movie Seasons
```
/movie/{movieId}/seasons
```
| Parameter | Type | Description | Required? | Default |
| :----------------: | :----: | :---------------------------------: | :-------: | :-----: |
| `movieId` | string | The movie id given in e.g. `/home`. | Yes | -- |
```javascript
[
{
id: string,
number: number,
},
{ ... }
]
```
### `GET` Movie Episodes
```
/movie/{movieId}/episodes?seasonId={seasonId}
```
| Parameter | Type | Description | Required? | Default |
| :-----------------: | :----: | :------------------------------------------------: | :-------: | :-----: |
| `movieId` | string | The movie id given in e.g. `/home`. | Yes | -- |
| `seasonId` | string | The season id given in `/movie/{movieId}/seasons`. | Yes | -- |
```javascript
[
{
id: string,
number: number,
title: string,
},
{ ... }
]
```
### `GET` Movie Episode Servers
```
/movie/{movieId}/servers?episodeId={episodeId}
```
| Parameter | Type | Description | Required? | Default |
| :------------------: | :----: | :-------------------------------------------------------: | :-------: | :-----: |
| `movieId` | string | The movie id given in e.g. `/home`. | Yes | -- |
| `episodeId` | string | The episode id given in e.g. `/movie/{movieId}/episodes`. | Yes | -- |
```javascript
[
{
id: string,
name: string,
},
{ ... }
]
```
### `GET` Movie Episode Sources
```
/movie/{movieId}/sources?serverId={serverId}
```
| Parameter | Type | Description | Required? | Default |
| :-----------------: | :----: | :------------------------------------------------: | :-------: | :-----: |
| `movieId` | string | The movie id given in e.g. `/home`. | Yes | -- |
| `serverId` | string | The server id given in `/movie/{movieId}/servers`. | Yes | -- |
```javascript
{
sources: [
{
src: string,
type: string,
},
{ ... }
],
tracks: [
{
file: string,
label: string,
kind: string,
default?: string,
},
{ ... }
]
}
```
Contributors
None
Thanks to ...