https://github.com/twurple/twurple
Interact with Twitch's API, chat and subscribe to events via PubSub and EventSub.
https://github.com/twurple/twurple
api api-client chat-bot chatbot eventsub extension pubsub tmi twitch twitch-api twitch-chat twitch-extension webhooks
Last synced: 27 days ago
JSON representation
Interact with Twitch's API, chat and subscribe to events via PubSub and EventSub.
- Host: GitHub
- URL: https://github.com/twurple/twurple
- Owner: twurple
- License: mit
- Created: 2017-07-02T09:02:38.000Z (over 8 years ago)
- Default Branch: main
- Last Pushed: 2026-01-13T02:02:08.000Z (3 months ago)
- Last Synced: 2026-01-13T04:14:40.173Z (3 months ago)
- Topics: api, api-client, chat-bot, chatbot, eventsub, extension, pubsub, tmi, twitch, twitch-api, twitch-chat, twitch-extension, webhooks
- Language: TypeScript
- Homepage:
- Size: 8.73 MB
- Stars: 722
- Watchers: 9
- Forks: 110
- Open Issues: 14
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
- awesome-twitch-dev - twurple/twurple - Interact with Twitch's API, chat, PubSub and subscribe to WebHooks. (Libraries / JavaScript (Node.js))
README
# Twurple
[](https://github.com/twurple/twurple/blob/main/LICENSE)
[](https://www.npmjs.com/package/@twurple/auth)

A set of libraries that aims to cover all existing Twitch APIs.
- Query the Helix API
- Build a chat bot
- React to custom redemptions, subscriptions, follows and much more using PubSub and EventSub
- Do all this without caring about the expiry of your access tokens - **we can refresh them automatically**
## Installation
To add Twurple to your project, just execute:
npm i @twurple/auth
# or
yarn add @twurple/auth
# or
pnpm install @twurple/auth
## Documentation
A good place to start with this library is the [documentation](https://twurple.js.org)
which also includes a complete reference of all classes and interfaces, as well as changes and deprecations between major versions.
## Additional packages
The mentioned `@twurple/auth` package only provides authentication functionality. All the other things are located in separate packages:
- [@twurple/api](https://npmjs.com/package/@twurple/api) - make calls to the Helix API
- [@twurple/chat](https://npmjs.com/package/@twurple/chat) - connect to and interact with Twitch Chat
- [@twurple/eventsub-http](https://npmjs.com/package/@twurple/eventsub-http) - listen to events using EventSub over HTTP/WebHooks
- [@twurple/eventsub-ws](https://npmjs.com/package/@twurple/eventsub-ws) - listen to events using EventSub over WebSockets
## If you're getting stuck...
You can join the [Twitch API Libraries Discord Server](https://discord.gg/b9ZqMfz) and ask in `#twurple` for support.
## Special thanks
- [discord.js](https://discord.js.org) for major inspiration on the structure of the libraries (or, as it was back then, *the library*)
- [All the people who contributed to Twurple](https://github.com/twurple/twurple/graphs/contributors)
- My [sponsors](https://github.com/sponsors/d-fischer) (maybe you want to become one too?)