# @youon/videos-api-wrapper

> A js wrapper for skoiy's video api

Latest version **0.4.2** (published 2019-05-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install @youon/videos-api-wrapper
pnpm add @youon/videos-api-wrapper
yarn add @youon/videos-api-wrapper
bun add @youon/videos-api-wrapper
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.4.2 |
| Published | 2019-05-15 |
| First published | 2019-03-26 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 8.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Pedro Silva |
| Maintainers | bgomes, psilva_uon |

## Links

- npm: https://www.npmjs.com/package/@youon/videos-api-wrapper
- npm.io page: https://npm.io/package/@youon/videos-api-wrapper

## Recent versions

- 0.4.2 (latest) — 2019-05-15
- 0.4.1 — 2019-05-13
- 0.4.0 — 2019-05-06
- 0.3.0 — 2019-05-06
- 0.2.0 — 2019-04-08
- 0.1.0 — 2019-03-26

## README

#### VIDEOS API WRAPPER


```js

const { VideosApiClient } = require('@youon/videos-api-wrapper');
import { VideosApiClient } from '@youon/videos-api-wrapper';

const endpoints = new VideosApiClient("host",1,"key","token");

```
#### Initial config

these params are passed in the constructor of VideoApiClient

Param|Description|
----|----|
Host| Api Host endpoint
Version| Api Version |
apiKey | Api Key Available on Accounts APP
apiToken | Api Token Available on Accounts APP


#### Methods

```
getChannels(params = null)

getChannelsByTag(iso, tag, params = null)

getChannel(channelId, params = null)

getPlaylists(channelId, params = null)

getPlaylist(channelId, playlistId, params = null)

getPlaylistVideos(channelId, playlistId, params = null)

getPlaylistLatestVideos(channelId, playlistId, params = null)

getVideo(channelId, playlistId, videoId, params = null)

getChannelVideos(channelId, params = null)

```
#### Params

the params argument is an object that is transformed into a query

```typescript
type Params = {[key:string]:any}


{ 
    ids : 'tags,video.tags',
    iso : 'pt',
    tag: 'programa' 
}
//"ids=tags,video.tags&iso=pt&tag=programa"

```


URI  | Description | Query parameters | Notes
---- | ---- | ---- |---- 
getChannels(params = null) | Return a Channel list | ids=tags&iso=<ISO_LANGUAGE>&order_by=position&order=asc|desc
getChannelsByTag(iso, tag, params = null) | Return a Channel List by tag | iso=<ISO_LANGUAGE>&tag=<TAG_SLUG>&ids=... | 
getChannel(channelId, params = null)  | Show information about a Channel | ids=tags&iso=<ISO_LANGUAGE>
getPlaylists(channelId, params = null) | Return a Playlist list inside a Channel | iso=<ISO_LANGUAGE>&order_by=position&order=asc|desc
getChannelVideos(channelId, params = null)  | Return a Videos list inside a Channel | ids=profile.tags, playlists, profile.metadata, profile.assets, profile.albums, profile.body, video.versions, labels&order_by=position|title|duration&order=asc|desc | A order_by=title so faz sentido se se passar uma iso 
getPlaylist(channelId, playlistId, params = null)  | Show information about a Playlist inside a Channel | iso=<ISO_LANGUAGE>
getPlaylistVideos(channelId, playlistId, params = null)  | Return a Video lists inside a Playlist Channel| iso=<ISO_LANGUAGE>&ids=profile.tags, playlists, profile.metadata, profile.assets, profile.albums, profile.body, video.versions, labels&order_by=position|title|duration&order=asc|desc | A order_by=title so faz sentido se se passar uma iso
getVideo(channelId, playlistId, videoId, params = null) | Show information about a Video | iso=<ISO_LANGUAGE>&ids=profile.tags, playlists, profile.metadata, profile.assets, profile.albums, profile.body, labels
getPlaylistLatestVideos(channelId, playlistId, params = null)  | Latest videos | ids=profile.tags, playlists, profile.metadata, profile.assets, profile.albums, profile.body,  video.versions, labels&order_by=position|title|duration&order=asc|desc | A order_by=title so faz sentido se se passar uma iso

---
_Source: https://npm.io/package/@youon/videos-api-wrapper · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
