Zoom integration #53
@ -1,8 +1,7 @@
|
||||
|
||||
const fetch = require('node-fetch');
|
||||
|
||||
module.exports = async function(robot, kredits) {
|
||||
const Contributor = kredits.Contributor;
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
|
||||
const Contribution = kredits.Contribution;
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
|
||||
const { Contributor, Contribution } = kredits;
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
|
||||
|
||||
const kreditsContributionAmount = 500;
|
||||
const kreditsContributionKind = 'community';
|
||||
@ -17,7 +16,7 @@ module.exports = async function(robot, kredits) {
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
|
||||
|
||||
return getContributorByZoomDisplayName(displayName)
|
||||
.then(contributor => {
|
||||
let contribution = {
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
|
||||
const contribution = {
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
![]() I think we should not do this. It will be a normal thing in a public call that not everyone is a contributor with a profile. I think we should not do this. It will be a normal thing in a public call that not everyone is a contributor with a profile.
|
||||
contributorId: contributor.id,
|
||||
contributorIpfsHash: contributor.ipfsHash,
|
||||
amount: kreditsContributionAmount,
|
||||
|
||||
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const { Contributor, Contribution } = kredits;
```
![]()
```suggestion
const contribution = {
```
![]()
```suggestion
const contribution = {
```
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]() This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call". This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Ignoring zoom call ${data.uuid} (duration: ${meetingDetails.duration}, participants_count: ${meetingDetails.participants_count})`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.logger.info(`[hubot-kredits] Contribution created: ${tx.hash}`);
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
![]()
```suggestion
robot.router.post('/incoming/kredits/zoom/'+process.env.KREDITS_WEBHOOK_TOKEN, (req, res) => {
```
|
This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".
This is a bit of an issue, because we sometimes use the Weekly Call room for other meetings. Not sure what the best solution is. Maybe just something generic like "Team/Community Call".