A Python app to serve Conveyor room requests and run approvals through Slack

Overview

CONVEYOR FOR SLACK

This is a friendly little Python app that will allow you to integrate your instance of Conveyor with your Slack workspace.

In order to make use of this, you will need an account with both Conveyor and Slack. Conveyor does not have a dev portal, but for Slack you will need to use their developer portal/API interface.

I built this using Bolt for Python, so most of the Slack interactions are handled by built in shortcuts. I used Flask as my server to handle the requests, as Bolt's built in server is really just meant for local testing and basic http. Other than that, the libraries involved are fairly simple and straightforward--requests, json, logging, etc. You can load those into your virtualenv from the requirements.txt in this repo.

This can do some basic but enjoyable things for you--

The main purpose of this tool is simply to push new room access requests into Slack, and allow people who are authorized Conveyor users to approve or reject those requests. This includes sourcing any special optional permissions group that you have, so different customers can be granted different permissions.

POV, u r using conveyor-for-slack and it is rad: image This is an example of what a room requests looks like when shared to Slack. It includes the email address of the person requesting, the timestamp, and whatever message they included with their request. The text at the top is a link to that specific request in Conveyor. Below, the privileges are pulled directly from the Conveyor API so that as our privileges change, so does the menu.

If you choose to accept the request, it is logged and the request goes through to the Conveyor API to be processed and the customer is granted access.

image If you choose to hit reject, a modal will pop up requesting a note about why. We chose to implement this so that anyone can answer questions about why a request was rejected without having to track down the original responder. This is not optional and must be filled out for the response to go through. This can easily be removed by pulling out the modal step in the @app.action("reject") section.

image Once the request has been processed and a 200 has been received from Conveyor, the original message in Slack is updated to reflect that the request was either approved or rejected, who did it, and when. Where applicable, the note is included. This is intended for transparency and self-service so that sales reps can search the Conveyor request channel and see whether or not their customer has had their request taken care of and what the response was.

To get this up and running,

you will need to:

  • get your Conveyor API key from your integrations menu
  • create a Slack app to install this to on your workspace in your Slack API apge
  • get your Slack signing secret and bot token from the API page
  • get your channel ID for where you want your app to post
  • set up a server either locally or in your infra
  • assign that URL to your Slack app in the interactions page
  • update the .env file with your assorted secrets

From there, you can pretty much start the up and be good to go. For my deployment at my company, mine is in a Docker container on Nomad, with Consul and some other fun frippery providing commuication with the outside world. So everything is orchestrated and all needed aspects are launched in the Dockerfile.

If you're running a local server, such as nginx, you'll need to start your nginx server on the correct port that you gave your Bolt/Flask app, and then run python3 app.py to launch the app.

I recommend going through and looking at some of the error messages. I had them custom tailored to me and my team, so when I changed them for mass consumption, they got a little sterile. Also, see if you want nearly as verbose of logging as I like to have.

Please fork the hell out of this, but...

Also please be aware that I will probably not ever look at any submitted PRs to this repo. I wrote this for my company to make my colleagues' lives easier, and also because I thought it was fun. I'll be maintaining it, and likely adding more features, within my professional GitHub organization, but updates will be ported over here only infrequently. This isn't to be an ass, just honesty. I'm not gonna think about it, and I don't want to leave you hanging. However, the great folks at Conveyor didn't have an API when I first wanted to do this, and they were amazing about being willing to spin something up to see what could happen. I would really love to see more companies and devs using their API. Their team was so great to work with, and I hope you will enjoy working with this too!

Owner
Vivienne
Security, Python, Node, all things back end. Hackbright Academy part-time SWE student, vulnerability management engineer full-time.
Vivienne
A python notification tool used for sending you text messages when certain conditions are met in the game, Neptune's Pride.

A python notification tool used for sending you text messages when certain conditions are met in the game, Neptune's Pride.

Paul Clarke 1 Jan 16, 2022
Telegram bot for Whisper Message.

Whisper Bot @WhisperStarkBot A star ⭐ from you means a lot to us! Telegram bot for Whisper Message. Usage Deploy to Heroku Tap on above button and fil

Stark Bots 33 Nov 24, 2022
Bot para automatizacao de registros no Vacivida para o COVID19

VACIBOT v.06 - Bot para automatizacao de registros no Vacivida para o COVID19 by Victor Fragoso - Prefeitura Municipal de Santo André Email:

Prefeitura de Santo André 22 Sep 19, 2022
Python client for Invidious' JSON API

Python project template A template for new Python projects. Features Automatically builds PDoc documentation & uploads package to PyPI on new GitHub r

Kevo 2 Jun 05, 2022
A minimal caching proxy to GitHub's REST & GraphQL APIs

github-proxy A caching forward proxy to GitHub's REST and GraphQL APIs. GitHub-Proxy is a thin, highly extensible, highly configurable python framewor

Babylon Health 26 Oct 05, 2022
A telegram bot that messages you available vaccine appointments in the Veneto region

Serenissimo, domande frequenti Chi sei? Sono Alberto Granzotto, libero professionista a Berlino. Mi occupo di servizi software, privacy, decentralizza

vrde 31 Sep 30, 2022
Telegram bot to download tiktok video/audio

TikTokDL (Bot) Telegram RoBot to Download Tiktok video/audio. Features: 👉 Download TikTok Video without Watermark 👉 Download TikTok Video with Water

X-Noid 23 Nov 21, 2022
Cleaning Tiktok Hacks With Python

Cleaning Tiktok Hacks With Python

13 Jan 06, 2023
Interact and easily use Google Chat room webhooks.

Chat Webhooks Easily interact and send messages with Google Chat's webhooks feature. This API is small, but should be a nice framework for working wit

BD103 2 Dec 13, 2021
A self-hosted Discord music bot.

Cassette A self-hosted Discord music bot. Requirements py-cord pynacl pytube Setup Intended to be hosted on Heroku. Fork or clone this repo. Create a

Lohan 8 Apr 28, 2022
Basic Discord python bot

#How to Create a Discord Bot Account In order to work with the Python library and the Discord API, we must first create a Discord Bot account. Here ar

Tustus 1 Oct 13, 2021
Automatically download any NFT collection from OpenSea.

OpenSea NFT Stealer The sole purpose of this script is to download any NFT collection from OpenSea. How does it work? Basically, the OpenSea website a

Dan 111 Dec 29, 2022
A self-bot for discord, written in Python, which will send you notifications to your desktop if it detects an intruder on your discord server

A self-bot for discord, written in Python, which will send you notifications to your desktop if it detects an intruder on your discord server

LevPrav 1 Jan 11, 2022
Code for "Multimodal Trajectory Prediction Conditioned on Lane-Graph Traversals," CoRL 2021.

Multimodal Trajectory Prediction Conditioned on Lane-Graph Traversals This repository contains code for "Multimodal trajectory prediction conditioned

Nachiket Deo 113 Dec 28, 2022
A bot that can play songs in Telegram group voice chats like AK 47

🎧 47Music Player 🎧 A bot that can play songs in Telegram group voice chats like AK 47 ✨ Easy To Deploy Pyrogram Session Config Vars API_ID : Assista

Janindu Malshan 23 Dec 07, 2022
Want to get your driver's license? Can't get a appointment because of COVID? Well I got a solution for you.

NJDMV-appoitment-alert Want to get your driver's license? Can't get a appointment because of COVID? Well I got a solution for you. We'll get you one i

Harris Spahic 3 Feb 04, 2022
Discord Rpc With Python And 2 Buttons

Discord-RPC-With-Python- Discord Rpc With Python And 2 Buttons Packages pypresence time Required Programs Python Latest Version Random IDE Discord :P

Kaz 4 Dec 12, 2021
Coinbase Listing Sniper

Coinbase Listing Sniper Script that listens to the @CoinbaseAssets twitter to find information about new Coinbase listings, and automatically buys 100

4 Oct 26, 2022
Properly-formatted dynamic timestamps for Discord messages

discord-timestamps discord-timestamps generates properly-formatted dynamic timestamps for Discord messages, with support for Arrow objects. format

Ben Soyka 2 Mar 10, 2022
This tool adds votes to strawpoll.me polls.

Strawpoll-Botter This tool adds votes to strawpoll.me polls. Usage Basic usage: py main.py -r amount of votes to put poll id option # Usage: py

MonkeySkid 2 Feb 28, 2022