Skip to content

Jleagle/bitly-api-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 

Repository files navigation

bitly-api-client

To use the class, you need to use one of three static methods.

If you have a bitly account username and password:

$bitly = Bitly::usernamePassword($username, $password);

If you have an access token (you can get one from https://bitly.com/a/oauth_apps):

$bitly = Bitly::accessToken($accessToken);

If you want to log the user in using OAuth:

$bitly = Bitly::authorize($clientId, $clientSecret, $projectUrl, $state);

From there you have access to each endpoint:

Return the click rate for content containing 'obama':

$realtimeClickrates = $bitly->shorten('https://github.com/Jleagle/bitly-api-client');

About

A small library to read and write to the Bitly API

Resources

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published

Languages