小编Mau*_*ini的帖子

用于用户活动的 Node + Github webhook

我会很容易地解释我的问题:

我想与 github webhooks 交互以在我的用户(或登录用户)单击 repo 上的 star(应该是这个钩子事件)时获取。

我有一个带有 node + express 的简单服务器,但我真的不明白如何执行它。有人可以帮助我吗?

const chalk = require('chalk');
const express = require('express');
const serverConfig = require('./config/server.config');

const app = express();

const port = process.env.PORT || serverConfig.port;

console.log(chalk.bgGreen(chalk.black('###   Starting server...   ###'))); // eslint-disable-line

app.listen(port, () => {
  const uri = `http://localhost:${port}`;
  console.log(chalk.red(`> Listening ${chalk.white(serverConfig.env)} server at: ${chalk.bgRed(chalk.white(uri))}`)); // eslint-disable-line
});
Run Code Online (Sandbox Code Playgroud)

javascript github node.js github-api

3
推荐指数
1
解决办法
165
查看次数

标签 统计

github ×1

github-api ×1

javascript ×1

node.js ×1