how to avoid multiple short URLs in urlBorg API

misc — Tags: — Panayotis @ 17:08

The urlBorg API will normally create a new short URL each time the ‘create’ method is called. There is a good reason for this, but many devlopers have been asking for a way to reuse already created short URLs.

I just added a new option that is currently only available through the API. Instead of using the ‘create’ method, you can now use the ‘create_or_reuse’ method. ‘create_or_reuse’ will check if the same combination of (api_key, long URL) has already been used and if so will return the short URL from the database instaed of creating a new one -if not, a new one will be created, as usual.

Check out the urlBorg API for details.

0 Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License.
(c) 2008 vrypan|net|log | powered by WordPress with Barecity