# twitch-comment-downloader

> Fetch comments for a given twitch vod

Latest version **1.3.3** (published 2020-01-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install twitch-comment-downloader
pnpm add twitch-comment-downloader
yarn add twitch-comment-downloader
bun add twitch-comment-downloader
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.3.3 |
| Published | 2020-01-03 |
| First published | 2020-01-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 35.2 KB |
| Known vulnerabilities | 0 (+25 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Jarvis Prestidge |
| Maintainers | jarvisprestidge |
| Keywords | typescript, twitch, stream, video, vod, comment, downloader |

## Links

- npm: https://www.npmjs.com/package/twitch-comment-downloader
- Repository: https://github.com/jarvisprestidge/twitch-comment-downloader
- Homepage: https://github.com/jarvisprestidge/twitch-comment-downloader#readme
- Issues: https://github.com/jarvisprestidge/twitch-comment-downloader/issues
- npm.io page: https://npm.io/package/twitch-comment-downloader

## Dependencies (1)

- [axios](https://npm.io/package/axios.md) ^0.19.0

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 1.3.3 (latest) — 2020-01-03
- 1.3.2 — 2020-01-03
- 1.3.1 — 2020-01-03
- 1.2.4 — 2020-01-01

## README

# Twitch Comment Downloader

<p>
  <img alt="Version" src="https://img.shields.io/npm/v/twitch-comment-downloader?style=for-the-badge" />
  
  <img alt="License: MIT" src="https://img.shields.io/badge/License-MIT-yellow.svg?style=for-the-badge" />

  <img alt="Open Issues" src="https://img.shields.io/github/issues/jarvisprestidge/twitch-comment-downloader?style=for-the-badge" />
  
  <img alt="Size" src="https://img.shields.io/bundlephobia/minzip/twitch-comment-downloader?style=for-the-badge" />

</p>

Fetch comments for a given twitch vod

-   🎉 First class Typescript support
-   🚅 Faster than similar libraries
-   🌈 Returns the full unopinionated result
-   1️⃣ Single dependency
-   👌 Simple API

## Table of Contents

-   [Install](#install)
-   [Usage](#usage)
-   [Example](#example)
-   [Run Tests](#run-tests)
-   [Author](#author)
-   [Contributing](#contributing)
-   [Support](#show-your-support)

## Install

```bash
yarn add twitch-comment-downloader
```

```bash
npm install twitch-comment-downloader
```

## Usage

There are example implementations for both [javascript](./examples/javascript/index.js) and [typescript](./examples/typescript/index.ts) in the top level [examples](./examples) directory.

```typescript
import { TwitchCommentDownloader } from "../../src/index";

const vodId = "524487996";

const clientId = "kimne78kx3ncx6brgo4mv6wki5h1ko";

const main = async (): Promise<void> => {

    // Instantiate twitch comment downloader
    const twitchCommentDownloader = new TwitchCommentDownloader(clientId);
    // Get all comments for a given vod id
    const comments = await twitchCommentDownloader.getComments(vodId);

    // Do something with the results
    for (const comment of comments) {
        const timestamp = new Date(comment.created_at).toISOString();
        const commenter = comment.commenter.display_name;
        const message = comment.message.body;
        console.log(`[${timestamp}] @${commenter} - ${message}`);
    }

    console.log(`Done fetching ${comments.length} comments from vod id: ${vodId}`);
};

main().catch((err) => console.error(err));

```

## Example

More examples can be found in the [examples](./examples) directory.

```bash
➜ yarn example
$ ts-node example/index.ts

[2019-12-21T16:40:32.516Z] @cwestlove - Pog
[2019-12-21T16:41:18.824Z] @Nathz - HeyGuys
[2019-12-21T16:41:22.869Z] @RakinWar - Me
[2019-12-21T16:41:23.580Z] @huskaa - DADDY
[2019-12-21T16:41:25.185Z] @SBT_NoSKiLLZ - !sens
[2019-12-21T16:41:25.321Z] @Nightbot - 400 dpi - 0.092 X&Y // ADS: 0.50 // Scoped: 0.50
[2019-12-21T16:41:26.429Z] @caffeinne - !sens
[2019-12-21T16:41:27.063Z] @cwestlove - it was none of you
.
.
.
[2019-12-21T19:44:22.544Z] @purg3001 - hi
[2019-12-21T19:44:22.732Z] @cwestlove - <3

Done fetching 1456 comments from vod id: 524487996
```

## Run tests

```bash
yarn test
```

## Author

👤 **Jarvis Prestidge <jarvisprestidge@gmail.com>**

-   Site: https://jarvisprestidge.io
-   Twitter: [@jarvisprestidge](https://twitter.com/jarvisprestidge)
-   Github: [@jarvisprestidge](https://github.com/jarvisprestidge)
-   LinkedIn: [@jarvisprestidge](https://linkedin.com/in/jarvisprestidge)

<p>
  <a href="https://twitter.com/jarvisprestidge" target="_blank">
    <img alt="Twitter: jarvisprestidge" src="https://img.shields.io/twitter/follow/jarvisprestidge.svg?style=social" />
  </a>
</p>

## Contributing

Contributions, issues and feature requests are welcome!<br />Feel free to check [issues page](https://github.com/jarvisprestidge/twitch-comment-downloader/issues). You can also take a look at the [contributing guide](./CONTRIBUTING.md).

## Show your support

Give a ⭐️ if this project helped you!

<a href="https://www.patreon.com/jarvisprestidge">
  <img src="https://c5.patreon.com/external/logo/become_a_patron_button@2x.png" width="160">
</a>

---

_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_

---
_Source: https://npm.io/package/twitch-comment-downloader · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
