Project

goo-gl

0.0
No commit activity in last 3 years
No release in over 3 years
A really tiny Google Shortener API gem without dependencies
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Runtime

>= 1.8
 Project Readme

#goo-gl

Really tiny Google Shortener API client in 25 lines of code. It depends on 3 libraries, which are usually included with Ruby:

  • net/http
  • openssl
  • json

##Installation

Install the gem:

gem install 'goo-gl'

Or add goo-gl to your Gemfile:

gem 'goo-gl'

That's it!

##How to use goo-gl

First get your API key here

googl = GooglApi.new('your-google-api-key')
long_url = 'http://github.com'
short_url = googl.shorten(long_url) 
# => "http://goo.gl/KkZ8"

Copyright (c) 2016 Vladislav Zaets, released under the MIT License