2017 © Pedro Peláez
 

library google-short-url

image

numenklatur/google-short-url

  • Wednesday, April 29, 2015
  • by arthurnumen
  • Repository
  • 0 Watchers
  • 1 Stars
  • 6,433 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

googleShortUrl

Provides a Laravel package to communicate with Google Short Url API., (*1)

Instalation

Add googleShorUrl to your composer.json file., (*2)

require : {
    "numenklatur/google-short-url": "1.0"
}

Or with composer command:, (*3)

composer require "numenklatur/google-short-url": "1.0"

Add provider to your app/config/app.php providers, (*4)

'NumenKlatur\GoogleShortUrl\GoogleShortUrlServiceProvider',

Publish config, (*5)

For Laravel 4 use:, (*6)

php artisan config:publish numenklatur/google-short-url

Add alias to app/config/app.php aliases, (*7)

'ShortUrl' => 'NumenKlatur\GoogleShortUrl\Facades\GoogleShortUrlApi',

Usage

Shorten links, (*8)

ShortUrl::shorten('http://numenklatur.me/');

Response format: JSON

{
  "kind": "urlshortener#url",
  "id": "http://goo.gl/xa55D2",
  "longUrl": "http://numenklatur.me/"
}

Expand links, (*9)

ShortUrl::expand('http://bit.ly/ze6poY');

Response format: JSON

{
  "kind": "urlshortener#url",
  "id": "http://goo.gl/xa55D2",
  "longUrl": "http://numenklatur.me/",
  "status": "OK"
}

The Versions

29/04 2015

dev-master

9999999-dev

  Sources   Download

The Requires

 

by Arthur Numen

29/04 2015

1.0

1.0.0.0

  Sources   Download

The Requires

 

by Arthur Numen