Git Product home page Git Product logo

managed-bots's Introduction

Keybase Managed Bots

Travis CI

Home of bots managed by Keybase. All of the managed bots within this repo can be run independently, each directory contains a readme to get started with self-hosting. For more information about bots on Keybase you can checkout the blog or technical documentation.

If you're interested in developing a bot on keybase, canarybot is a good starting place as a simple example. You can also checkout the various API libaries in Golang, Javascript and Python.

managed-bots's People

Contributors

adamjspooner avatar cori-hudson avatar daniel-wang avatar dependabot[bot] avatar josephgregg avatar joshblum avatar knorrium avatar marceloneil avatar mmaxim avatar pantani avatar songgao avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

managed-bots's Issues

githubbot: Closing of issue is attributed to the wrong person

I pushed this commit which closed this issue but the bot announced the following:

awolven closed issue #15 on common-lispers.hexstreamsoft.com.
https://github.com/Hexstream/common-lispers.hexstreamsoft.com/issues/15

awolven (the issue creator) did not close the issue, I did.

I'm not sure if this bug only occurs when closing via commit or always.

GitLab bot - no notifications

I used !gitlabbot feedback to report an issue about not getting any notifications and got some basic troubleshooting tips from @Daniel-Wang but that didn't solve the issue, so I'll submit this as an issue here instead.

Copy/paste of my initial feedback but formatted for easier reading:

I'm not getting any notifications.

  • Does it matter if the project is private or public?
  • Does it matter if the owner/username contains capital letters?
    • My username begins with a capital letter and the URL in the browser reflects that, but in Keybase the URL is shown in all lower case. Clicking the link in Keybase that leads to the webhook settings in GitLab sends me to the correct site, but I can see the URL change in the browser from lower to uppercase for my username.

I've made sure that the webhook url is correct, and I've ticked all the types of events.

When saving the webhook configuration in GitLab there was a "success" message and using the test funtion gave no errors, and running a real push and pipeline job all seems to run just fine, I just don't get any notifications in keybase.

Below is a screenshot of the log in in "Recent Deliveries" for the webhook in GitLab.
bild

"Something went wrong!" when trying to subscribe or unsubscribe to repo events

After setting up the Keybase integration on a repository, I can't subscribe or unsubscribe to any event types. githubbot always responds with Something went wrong!.

I couldn't setup my own instance to debug further, but it seems to be thrown by line 219 here

func (d *DB) SetFeatures(convID chat1.ConvIDStr, repo string, features *Features) error {
return d.RunTxn(func(tx *sql.Tx) error {
_, err := tx.Exec(`
INSERT INTO features
(conv_id, repo, issues, pull_requests, commits, statuses, releases)
VALUES
(?, ?, ?, ?, ?, ?)
ON DUPLICATE KEY UPDATE
issues=VALUES(issues),
pull_requests=VALUES(pull_requests),
commits=VALUES(commits),
statuses=VALUES(statuses)
releases=VALUES(releases)
`, convID, repo, features.Issues, features.PullRequests, features.Commits, features.Statuses, features.Releases)
return err
})
}

pollbot: green circles not displaying

The green circle emojis used by pollbot to display the results of the poll are not displayed properly on Android devices. According to Emojipedia it was added in 2019 and should be supported on all updated systems. However this emoji doesn't display on my phone and is substituted with a crossed rectangle:
green circle
Keybase prevents from taking screenshots, so it's complicated to provide proof, but believe me - it doesn't show up in Keybase either.
My phone is OnePlus 5 OxygenOS 9.0.11 (compilation A5000_23_200224) last updated in February 2020. There are no new updates. I've asked my friends and all having Android devices experienced the same issue. However, the green circles are displayed properly on iOS and Windows 10.
Please keep in mind that many older Android devices that are still working won't receive system updates, so it won't start working on them ever.
Maybe it would be better to change used sign to:

or maybe use a different approach...

TriviaBot Does not work

I've added triviabot to multiple teams and typing !trivia begin doesn't do anything at all

githubbot: ability to subscribe to only failure statuses

I'd like to get notifications in Keybase when our continuous integration fails, but it would be a lot of noise to have every success posted. We could have a separate channel for these notifications and filter to successes, but it would be more convenient if we could just subscribe to failures.

Bonus points for being able to also subscribe to newly-passing successes, but this is less important.

webhookbot - message format

Is it possible to add a feature to beautify the json code when we have the content-type header for JSON.

Because it's very hard to read in the keybase channel otherwise.

This tool is really great !

webhookbot - image urls don't preview

I have webhookbot installed in a chat channel and posting links to images, but they don't show a preview in my MacOS desktop client. If I copy the link and paste it as a message from me, it does. Is this a missing feature of the bot, or a limitation based on it's access?

githubbot/gitlabbot: list

Not sure whether this is really needed, maybe in the interest of housekeeping: After subscribing numerous repos, I'm certain not to remember which ones in a few weeks time. How about adding

!github list
!gitlab list

to get a list of all subscriptions and therefore the ability to unsubscribe from no longer needed or incorrect subscriptions (typos etc)?

Keybase webhookbot not responding

Webhookbot on keybase is not responding to commands & attempts to POST to existing URLs are receiving 504 Gateway Timeout errors.

Issue with webhookbot and Radarr

The webhookbot doesn't seem fully compatible with Radarr or I'm doing something wrong.

I added the webhook to Radarr as in the screenshot below. But the only thing that gets posted in the Keybase chat is [hook: radarr] (radarr is the name of the webhook) no matter if I just click the Test button in Radarr or if it's a real grab/download message. It doesn't matter weather I choose POST or PUT as method.

More info about webhooks in Radarr can be found here

bild

"Something went wrong!" is a poor error message

When something goes wrong, githubbot sends the message "Something went wrong!"

image

This message gives no clues about how to solve the problem. It does not say any of these:

  • what to do about it
  • who to talk to
  • where to look for more information
  • what went wrong

An error message should give at least one clue.

In particular, subscribers to githubbot are probably devs, or have devs nearby, and could cope with a backtrace.

Thanks!

webhookbot: Support JSON request body data for message placeholders

The webhookbot comes in very handy when bridging on-premises services to Keybase! However, it's missing a bit of adaptability to support certain services such as most notably GitLab on-premises aka GitLab on your own server and domain such as my gitlab.bitcetera.com instance.

(The gitlabbot won't do the trick neither as it only works for repos on gitlab.com only.)

GitLab (like other services) is able to fire a plethora of webhooks to freely definable URLs. for instance for pipeline events. The JSON request body contains lots of details on the event:

{
   "object_kind": "pipeline",
   "object_attributes":{
      "id": 31,
      "ref": "master",
      "tag": false,
      "sha": "bcbb5ec396a2c0f828686f14fac9b80b780504f2",
      "before_sha": "bcbb5ec396a2c0f828686f14fac9b80b780504f2",
      "source": "merge_request_event",
      "status": "success",
      "stages":[
         "build",
         "test",
         "deploy"
      ],
      "created_at": "2016-08-12 15:23:28 UTC",
      "finished_at": "2016-08-12 15:26:29 UTC",
      "duration": 63,
      "variables": [
        {
          "key": "NESTOR_PROD_ENVIRONMENT",
          "value": "us-west-1"
        }
      ]
   },
    "merge_request": {
      "id": 1,
      "iid": 1,
      "title": "Test",
      "source_branch": "test",
      "source_project_id": 1,
      "target_branch": "master",
      "target_project_id": 1,
      "state": "opened",
      "merge_status": "can_be_merged",
      "url": "http://192.168.64.1:3005/gitlab-org/gitlab-test/merge_requests/1"
   },
   "user":{
      "name": "Administrator",
      "username": "root",
      "avatar_url": "http://www.gravatar.com/avatar/e32bd13e2add097461cb96824b7a829c?s=80\u0026d=identicon"
   },
   "project":{
      "id": 1,
      "name": "Gitlab Test",
      "description": "Atque in sunt eos similique dolores voluptatem.",
      "web_url": "http://192.168.64.1:3005/gitlab-org/gitlab-test",
      "avatar_url": null,
      "git_ssh_url": "[email protected]:gitlab-org/gitlab-test.git",
      "git_http_url": "http://192.168.64.1:3005/gitlab-org/gitlab-test.git",
      "namespace": "Gitlab Org",
      "visibility_level": 20,
      "path_with_namespace": "gitlab-org/gitlab-test",
      "default_branch": "master"
   },
   "commit":{
      "id": "bcbb5ec396a2c0f828686f14fac9b80b780504f2",
      "message": "test\n",
      "timestamp": "2016-08-12T17:23:21+02:00",
      "url": "http://example.com/gitlab-org/gitlab-test/commit/bcbb5ec396a2c0f828686f14fac9b80b780504f2",
      "author":{
         "name": "User",
         "email": "[email protected]"
      }
   },
   "builds":[
      {
         "id": 380,
         "stage": "deploy",
         "name": "production",
         "status": "skipped",
         "created_at": "2016-08-12 15:23:28 UTC",
         "started_at": null,
         "finished_at": null,
         "when": "manual",
         "manual": true,
         "allow_failure": false,
         "user":{
            "name": "Administrator",
            "username": "root",
            "avatar_url": "http://www.gravatar.com/avatar/e32bd13e2add097461cb96824b7a829c?s=80\u0026d=identicon"
         },
         "runner": null,
         "artifacts_file":{
            "filename": null,
            "size": null
         }
      },
      {
         "id": 377,
         "stage": "test",
         "name": "test-image",
         "status": "success",
         "created_at": "2016-08-12 15:23:28 UTC",
         "started_at": "2016-08-12 15:26:12 UTC",
         "finished_at": null,
         "when": "on_success",
         "manual": false,
         "allow_failure": false,
         "user":{
            "name": "Administrator",
            "username": "root",
            "avatar_url": "http://www.gravatar.com/avatar/e32bd13e2add097461cb96824b7a829c?s=80\u0026d=identicon"
         },
         "runner": {
            "id":380987,
            "description":"shared-runners-manager-6.gitlab.com",
            "active":true,
            "is_shared":true
         },
         "artifacts_file":{
            "filename": null,
            "size": null
         }
      },
      {
         "id": 378,
         "stage": "test",
         "name": "test-build",
         "status": "success",
         "created_at": "2016-08-12 15:23:28 UTC",
         "started_at": "2016-08-12 15:26:12 UTC",
         "finished_at": "2016-08-12 15:26:29 UTC",
         "when": "on_success",
         "manual": false,
         "allow_failure": false,
         "user":{
            "name": "Administrator",
            "username": "root",
            "avatar_url": "http://www.gravatar.com/avatar/e32bd13e2add097461cb96824b7a829c?s=80\u0026d=identicon"
         },
         "runner": {
            "id":380987,
            "description":"shared-runners-manager-6.gitlab.com",
            "active":true,
            "is_shared":true
         },
         "artifacts_file":{
            "filename": null,
            "size": null
         }
      },
      {
         "id": 376,
         "stage": "build",
         "name": "build-image",
         "status": "success",
         "created_at": "2016-08-12 15:23:28 UTC",
         "started_at": "2016-08-12 15:24:56 UTC",
         "finished_at": "2016-08-12 15:25:26 UTC",
         "when": "on_success",
         "manual": false,
         "allow_failure": false,
         "user":{
            "name": "Administrator",
            "username": "root",
            "avatar_url": "http://www.gravatar.com/avatar/e32bd13e2add097461cb96824b7a829c?s=80\u0026d=identicon"
         },
         "runner": {
            "id":380987,
            "description":"shared-runners-manager-6.gitlab.com",
            "active":true,
            "is_shared":true
         },
         "artifacts_file":{
            "filename": null,
            "size": null
         }
      },
      {
         "id": 379,
         "stage": "deploy",
         "name": "staging",
         "status": "created",
         "created_at": "2016-08-12 15:23:28 UTC",
         "started_at": null,
         "finished_at": null,
         "when": "on_success",
         "manual": false,
         "allow_failure": false,
         "user":{
            "name": "Administrator",
            "username": "root",
            "avatar_url": "http://www.gravatar.com/avatar/e32bd13e2add097461cb96824b7a829c?s=80\u0026d=identicon"
         },
         "runner": null,
         "artifacts_file":{
            "filename": null,
            "size": null
         }
      }
   ]
}

Job events

Triggered on status change of a job.

Request Header:

X-Gitlab-Event: Job Hook

Request Body:

{
  "object_kind": "build",
  "ref": "gitlab-script-trigger",
  "tag": false,
  "before_sha": "2293ada6b400935a1378653304eaf6221e0fdb8f",
  "sha": "2293ada6b400935a1378653304eaf6221e0fdb8f",
  "build_id": 1977,
  "build_name": "test",
  "build_stage": "test",
  "build_status": "created",
  "build_started_at": null,
  "build_finished_at": null,
  "build_duration": null,
  "build_allow_failure": false,
  "build_failure_reason": "script_failure",
  "pipeline_id": 2366,
  "project_id": 380,
  "project_name": "gitlab-org/gitlab-test",
  "user": {
    "id": 3,
    "name": "User",
    "email": "[email protected]"
  },
  "commit": {
    "id": 2366,
    "sha": "2293ada6b400935a1378653304eaf6221e0fdb8f",
    "message": "test\n",
    "author_name": "User",
    "author_email": "[email protected]",
    "status": "created",
    "duration": null,
    "started_at": null,
    "finished_at": null
  },
  "repository": {
    "name": "gitlab_test",
    "description": "Atque in sunt eos similique dolores voluptatem.",
    "homepage": "http://192.168.64.1:3005/gitlab-org/gitlab-test",
    "git_ssh_url": "[email protected]:gitlab-org/gitlab-test.git",
    "git_http_url": "http://192.168.64.1:3005/gitlab-org/gitlab-test.git",
    "visibility_level": 20
  },
  "runner": {
    "active": true,
    "is_shared": false,
    "id": 380987,
    "description": "shared-runners-manager-6.gitlab.com"
  }
}

It would be great if parts from this JSON payload could be inserted in the webhookbot message by use of placeholders wrapped in double underscores, something along the line of:

https://bots.keybase.io/webhookbot/xxxxxxxxxx?msg=project+__project.name__+with+status+__object_attributes.status__

What do you think about this idea?

(Right now I'm running a simple Sinatra bridge which takes the webhook from GitLab and translates it for the Keybase webhookbot โ€“ an unnecessary possible point of failure. Unfortunately, my Go skills are not good enough (yet) to do a PR on this repo.)

Google Meet Bot compatability with hangouts video invite links

Would it be possible to allow the Google Meet bot, to also generate links to Google hangouts video chat? I think it may use a lot of the same google services? Also since Google meet is restricted to Gsuite users (a paid service), so it limits the use. My knowledge of this is limited at best, it just a suggestion.

gcalbot: better interface for multiple calendar subscriptions

I see that you can connect multiple Google calendar accounts, but as far as I can tell it is only possible to subscribe to a single calendar per account. Please correct me if I'm just missing how to do this.

I'd like to have the ability to subscribe to multiple calendars (in a single channel.)

Slack bot

I understand that this would probably be a heavy lift; however, the primary reason that keybase only sees a few hours of my time each day rather than eight or more is that slack is too dang sticky in work environments. I would greatly value a slackbot that I can use to mirror posts to a subgroup so that each slack channel that I select can be mapped a sub-sub group (or something along those lines to map channels into keybase). Using more than one chat system is such a major overhead - having everything in Keybase with bose secure and external non-secure chats being visibly labeled would be optimal.

Jira bot work for anyone?

I cannot get this bot to respond to commands across channels or in messages. Does it work for anyone?

Split each bot into its own repo?

I'm very interested in githubbot, but not really interested in the other bots. Right now, if I subscribed to the repo, I would get tons of notifications I really don't care about, whereas if githubbot had its own repo, I could just subscribe to that. This repo could still be retained for issues common to all bots (or a new one could be created for this).

The new bot repos could be either part of the keybase org or a new keybase-bots org or similar.

I realize this might be deemed administratively inconvenient...

"Something went wrong!" when trying to subscribe to repo

I saw you already had a similar issue opened earlier which you closed, but I'm still getting this same issue.

It's just keybase hosted githubbot that i'm using, and unsure what to do.
Please let me know what you need to resolve this issue

Keybase Login "Server Rejected Session"

I cant access my keybase account. I keep getting an error message saying session rejected, is my device revoked. I have tried other devices same thing. The weird part is i get a sign in notification mail anytime i use my paper keys.

webhookbot: support for images

I wonder whether it is possible to send out not only text, but images via the webhookbot? That would be a super cool feature. We would like to be able to send some images (charts) via webhookbot.

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.