0.0
No commit activity in last 3 years
No release in over 3 years
Gem description
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 10.0
~> 0.37.2
~> 1.24.2

Runtime

~> 4.3.0
= 0.1.49
 Project Readme

xambassador

Build Status Coverage Status

GitHub webhook written in Ruby

Usage

Xambassador is intended to be used with Sinatra.

  1. First install Xambassador with gem install xambassador

  2. Create a new Sinatra webapp and in your server.rb file add the following code:

require 'sinatra'
require 'json'

require 'xambassador/pull_request'

post '/event_handler' do
  case request.env['HTTP_X_GITHUB_EVENT']
  when 'pull_request'
    payload = JSON.parse(request.body.read)
    Xambassador::PullRequest.new(payload)
  end
end