Description
Get Short URL will check to see if the link provided has published a shortened version of the given page using an HTTP or HTML link header element. If the link provided has not published a shortened link, then the original URL will be returned.
Details
Get Short URL returns the shortest result of the following possible sources:
HTTP Headers
-
Link <...>; rel="shorturl" -
Link <...>; rel="shortlink" -
Link <...>; rel="canonical" -
Link <...>; rev="canonical"
HTML Headers
-
<link rel="shorturl" href="..."> -
<link rel="shortlink" href="..."> -
<link rel="canonical" href="..."> -
<link rev="canonical" href="...">
API
There is also an API version, which returns just the resulting URL.
Ubiquity
There is also a Ubiquity command for the api.