Secret Santa Bot
Number of APIs: 7
This collection helps initiate a Secret Santa gift exchange through a specified slack channel for a particular budget. It also gives gift recommendations based on the interest of the person you were assigned.
Setup
To run this collection locally, you will need an environment with the following variables:
budget
: denotes the spending cap for all participants in the gift exchange in numberschannel
: denotes the Slack channel name whose members will be participating in Secret SantaamazonUrl
: denotes the Amazon base url for your regionbotToken
: denotes the token of the bot user created in SlackgoogleClientId
,googleClientSecret
: specifies your Google API Oauth Client credentials that need to be generated
-
Create Google calendar invite POST https://www.googleapis.com/calendar/v3/calendars/primary/events
-
Get channel Id from slack channel GET https://slack.com/api/channels.list
-
Get user Ids from Slack channel GET https://slack.com/api/channels.info?channel={{channelId}}
-
Get user email from slack GET https://slack.com/api/users.info?user={{userId}}
-
Get all user interests from app GET https://secretsantatest.herokuapp.com/slack
-
Get Amazon product links for a user GET {{amazonUrl}}/s?k={{category}}+under+{{budget}}&ref=nb_sb_noss_1
-
Post recomendations to slack POST https://slack.com/api/chat.postMessage