Googleâ€™s URL shortener externally back in September, there was no accompanying API to allow people to integrateÂ goo.gl into their applications and web pages.Google launched the goo.gl API inÂ Google Code Labs. Thedocumentation can be found on the Google Code site, with example code in theÂ Getting Started section.
With this API, developers are able to programmatically access all of the fast, sleek goo.gl goodness that we currently provide via the web interface. You can shorten and expand URLs using the API, as well as fetch your history and analytics. You could use these features for a wide variety of applications, enabling behaviors ranging from auto-shortening within Twitter or Google Buzz clients to running regular jobs that monitor your usage statistics and traffic patterns. You can check out theÂ Google APIs console to get started.