GithubHelp home page GithubHelp logo

kairstenfay / slack-wayback Goto Github PK

View Code? Open in Web Editor NEW
4.0 1.0 0.0 188 KB

A Slack bot that fetches the most current archived versions of URLs (as available) and posts them in response to mentions. Uses the Wayback Machine API for creating URLs.

Home Page: http://web.archive.org

License: MIT License

Python 100.00%
wayback-machine internet-archive slack slack-bot slack-bots

slack-wayback's Introduction

Slack Wayback bot

Example of Slack bot interaction

This code is for deploying a Slack bot that responds to app mentions with the latest web.archive.org archived copy of any links in the user's message. The code is written to run on AWS Lambda.

Requirements

To deploy this bot, you'll need access to a Slack space where you have permissions to install new apps, and you'll also need an AWS account.

Slack configuration

The Slack app has the following features and functionality:

  • Event Subscriptions (registered using the provided AWS Lambda URL endpoint)
  • Bots
  • Permissions (This is where you'll find your bot token which you'll want to configure as an environment variable named SLACK_BOT_TOKEN. This is the token that starts with xoxb-*.)

Currently, the configured Slack Bot Token Scopes are:

  • app_mentions:read
  • channels:join
  • chat:write
  • chat:write.public
  • links:read

The bot is also subscribed to the app_mention Event Name. It is not subscribed to any events on behalf of users.

Example Display Information

App name Short description
Wayback Machine If you @ me, I'll post the most recent archived copies of the links in your message. Use me to get around news paywalls!

Related tutorials

If you're interested in setting up a similar Slack bot, I recommend starting with the Slack API Bot tutorial.

Once you're ready to deploy, I recommend this Medium post for configuring Slack bots on AWS Lambda.

slack-wayback's People

Contributors

kairstenfay avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

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.