A quick script in response to Donald’s query on my TextExpander Experiments post. He wanted to know if I could make the bit.ly script which expands to a bit.ly-shortened version of a url in the clipboard work with an authenticated account, presumably for click tracking. Well, sure! Just adjust the script below to contain your bit.ly username and your API key (in lines 6 & 7), and replace the existing script in the TextExpander experiments bundle with this one (or create a new snippet with the script).
The API can output JSON and XML, which would be more appropriate on most occasions, but the “txt” format (which only includes the shortened link) is perfect for this situation. Enjoy!