Skip to content
Ruby toolkit for working with the viagogo API
Ruby Shell
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.


Type Name Latest commit message Commit time
Failed to load latest commit information.

The GogoKit Ruby Gem

Gem Version Downloads Build Status Dependency Status Code Climate Coverage Status

Ruby toolkit for working with the viagogo API. Our developer site documents all of the viagogo APIs.


Install via Ruby gems

gem install gogokit

... or add to your Gemfile

gem 'gogokit'


See our developer site and samples for more examples.

require 'gogokit'

# All methods require OAuth2 authentication. To get OAuth2 credentials for your
# application, see
client = do |config|
  config.client_id = YOUR_CLIENT_ID
  config.client_secret = YOUR_CLIENT_SECRET

# Get an access token. See
token = client.get_client_access_token
client.access_token = token.access_token

# Get a list of events, categories, venues and metro areas that match the given
# search query
search_results = 'FC Barcelona tickets'

# Get the different event genres (see
genres = client.get_genres

Request Headers, Query Parameters and Body

The last parameter of all GogoKit::Client methods is an options Hash that supports headers, params and body keys for specifying request headers, query parameters and body respectively.

events = client.get_events_by_category(CATEGORY_ID,
                                       headers: {'Accept-Language' => 'JA'},
                                       params: {'sort' => 'name'})

Configuration and defaults

GogoKit::Client accepts a range of options when creating a new client instance.

Configuring client instances

Every writeable attribute in {GogoKit::Configuration} can be set one at a time

client =
client.client_id = YOUR_CLIENT_ID
client.api_root_endpoint = ''

or in a block:

client = do |config|
  config.client_id = YOUR_CLIENT_ID
  config.api_root_endpoint = ''

Using ENV variables

Default configuration values are specified in {GogoKit::Default}. Many attributes will look for a default value from the ENV before returning GogoKit's default.

# ""
client =

# => "abcd1234"
# => ""

Sandbox Environment

# You can use the GogoKitConfiguration to switch between the sandbox and
# production environments. See
client =
client.api_environment = :sandbox

How to contribute

All submissions are welcome. Fork the repository, read the rest of this README file and make some changes. Once you're done with your changes send a pull request. Thanks!

Need Help? Found a bug?

Just submit a issue if you need any help. And, of course, feel free to submit pull requests with bug fixes or changes.

Supported Ruby Versions

This library aims to support and is tested against the following Ruby implementations:

  • Ruby 1.9.3
  • Ruby 2.0.0
  • Ruby 2.1.0
  • Ruby 2.2.0

If something doesn't work on one of these Ruby versions, it's a bug.

This library may inadvertently work (or seem to work) on other Ruby implementations, but support will only be provided for the versions listed above.

If you would like this library to support another Ruby version, you may volunteer to be a maintainer. Being a maintainer entails making sure all tests run and pass on that implementation. When something breaks on your implementation, you will be responsible for providing patches in a timely fashion. If critical issues for a particular implementation exist at the time of a major release, support for that Ruby version may be dropped.

Troubleshooting on Windows

GogoKit uses SSL for all HTTP requests. On Windows you will need to configure where your certificates live since OpenSSL cannot find one to validate the authenticity. This post describes how you can get this working on windows.


This library aims to adhere to Semantic Versioning 2.0.0. Violations of this scheme should be reported as bugs. Specifically, if a minor or patch version is released that breaks backward compatibility, that version should be immediately yanked and/or a new version should be immediately released that restores compatibility. Breaking changes to the public API will only be introduced with new major versions. As a result of this policy, you can (and should) specify a dependency on this gem using the Pessimistic Version Constraint with two digits of precision. For example:

spec.add_dependency 'gogokit', '~> 0.4'
You can’t perform that action at this time.