Giter Club home page Giter Club logo

node-twitch-webhook's People

Contributors

bethaneeks avatar daniilshev avatar nic11 avatar robintail avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

node-twitch-webhook's Issues

http.createServer(function (req, res) {Issue closed as no further information was provided

Issue is TypeError: http.createServer is not a function

_Originally posted by @nic11 in #14 (comment)
_const fs = require("fs");
const http =("http");
const server = http.createServer();
server.on('request', (req, res) => {
const rstream = fs.creatReadStream("input.txt");
rstream.on("data", (chunkdata) => {
res.write(chunkdata);
});
rstream.on("end", () =>{
});
rstream.on('error', (err) => {
console.log(err);
res.end("file is not found");
});
});
server.listen(8000,"127.0.0.1");

Access to unknown URL/method

stops working after 1h - 1h 30m
/ twitch-webhooks WARNING Access to unknown URL/method attempted: GET /
After receiving this message in the console, listening no longer works.
This only happens on the remote server, with local tests everything is fine. Remote Ubuntu Server 20.04 64bit if it matters.
I suspect this is due to ngrok, but not sure about it. What can I do to find out the real reason for this?

node: 14.16.1
npm: 7.11.2

Stream event doesn't work

Why

It happens because Twitch replaced JSON property "topic" with HTTP header "Link" in some events and will do it with all the others. Also it's a W3C standard

How to fix

Implement routing for events, for example
api.your-website.com/twitch-webhooks/follows
api.your-website.com/twitch-webhooks/streams

Cannot find module 'twitch-webhook'

According to runnit and from using in my app, there's no index.js file, thus can't be required just by using;

require('twitch-webhook')

We need to use;

require('twitch-webhook/src/index.js')

Node Version: 8.9.3 and 9.3.0
NPM Version: 5.6.0

What is an example of what callback should be?

Is it suppose to point to the listen config?

listen: {
          port: 5000,           // default: 8443
          host: '127.0.0.1',    // default: 0.0.0.0
          autoStart: true       // default: true
      }

or should i be adding a route that points to a function?

or should it point to the callback for the auth? http://localhost:5000/auth/twitch/callback?

Help subscribing to stream change.

I'm trying to figure out how to properly subscribe to stream changes. The examples show user/follow, but the streams topic requires a user id.

I assume it would be like this:

twitchWebhook.subscribe('streams', {
  user_id: 12826 // ID of Twitch Channel 
}).then(res => res);

When I do this, I receive a GET request with a challenge. Does this library handle the verification, or that something I still have to do myself?

Missing OAuth token

{"error":"Unauthorized","status":401,"message":"OAuth token is missing"}

What’s changing?
Starting on May 1, 2020, Helix will require the following:

Use of OAuth across all endpoints, either via an app access token or user access token.
The client ID provided in the corresponding header must match the client ID used to generate the OAuth token.

Link here

Will this library be handling this?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.