Twitch icon

Twitch

Interact with Twitch

Overview

This node interacts with the Twitch API to retrieve information about Twitch streams, games, and channels. Specifically, for the "Get Channel Streams" operation, it fetches live stream data for a specified Twitch channel by its name. This is useful for workflows that need to monitor or analyze live streaming activity on Twitch channels, such as tracking when a streamer goes live, aggregating stream metadata, or integrating Twitch stream info into other applications.

Practical examples include:

  • Automatically notifying a community when a specific Twitch channel starts streaming.
  • Collecting live stream details for analytics dashboards.
  • Integrating Twitch stream data into social media posts or marketing automation.

Properties

Name Meaning
Channel Name Name of the Twitch channel whose live streams you want to retrieve. This is a required string input.

Output

The node outputs an array of JSON objects representing the live streams of the specified Twitch channel. Each object corresponds to a stream and contains detailed information as returned by the Twitch API's /streams endpoint, such as stream ID, user ID, game being played, viewer count, stream title, start time, and more.

If the channel is not currently live or no streams are found, the output array will be empty.

The node does not output binary data.

Dependencies

  • Requires an active Twitch API credential configured in n8n to authenticate requests.
  • Uses the Twitch API endpoints, specifically /streams for this operation.
  • The node depends on a helper function (twitchApiRequest) to make authenticated HTTP requests to Twitch.

Troubleshooting

  • Common issues:

    • Invalid or missing Twitch API credentials will cause authentication errors.
    • Providing a non-existent or misspelled channel name will result in an empty output (no streams found).
    • Rate limiting by Twitch API if too many requests are made in a short period.
  • Error messages:

    • Authentication errors typically indicate invalid or expired API tokens; reconfigure the Twitch API credential.
    • Network or API errors may occur if Twitch services are down or unreachable; retry later.
    • If the output is unexpectedly empty, verify the channel name is correct and that the channel is currently live streaming.

Links and References

Discussion