Google recently introduced an API to use their URL shortening service. Today I’m going to quickly demo how you can use cURL with PHP to call the API. If you read over the getting started document you will see you can create a project in which you can call this API much more frequently using an API key generated for you so Google knows whom is calling their service, etc. (you should do this in a production environment obviously). To keep it simple I’ll leave out the API key and simply make a quick cURL call to the API to demo how to use this very simple service.