bitly v0.1.1 Bitly.Link

Bitly Links API

https://dev.bitly.com/links.html

Link to this section Summary

Functions

Given a bitly URL or hash (or multiple), returns the target (long) URL

This is used to return the page title for a given Bitlink

This is used to query for a Bitlink based on a long URL

Given a long URL, returns a Bitlink

Link to this section Types

Link to this type t()
t() :: %Bitly.Link{
  data: map() | list(),
  status_code: integer(),
  status_txt: String.t()
}

Link to this section Functions

Link to this function expand(short_url, opts \\ [], client \\ Client.new())
expand(String.t(), keyword(), Bitly.Client.t()) :: t() | String.t()

Given a bitly URL or hash (or multiple), returns the target (long) URL.

Example

Bitly.Client.expand("http://bit.ly/ze6poY")
Link to this function info(short_url, opts \\ [], client \\ Client.new())
info(String.t(), keyword(), Bitly.Client.t()) :: t()

This is used to return the page title for a given Bitlink.

Example

Bitly.Link.info("http://bit.ly/ze6poY")
Link to this function lookup(url, client \\ Client.new())
lookup(String.t(), Bitly.Client.t()) :: t()

This is used to query for a Bitlink based on a long URL.

Example

Bitly.Link.lookup("http://www.google.com/")
Link to this function shorten(long_url, opts \\ [], client \\ Client.new())
shorten(String.t(), keyword(), Bitly.Client.t()) :: t() | String.t()

Given a long URL, returns a Bitlink.

Example

Bitly.Link.shorten("http://google.com/")