Exgravatar

Build Status

An Elixir module for generating Gravatar urls.

Make sure to check out the Gravatar documentation for all available options.

Usage

Exgravatar.generate "jdoe@example.com"
#=> "http://gravatar.com/avatar/694ea0904ceaf766c6738166ed89bafb"

# with size option in pixels
Exgravatar.generate("jdoe@example.com", %{s: 256})
#=> "http://gravatar.com/avatar/694ea0904ceaf766c6738166ed89bafb?s=256"

# add true after the options to get the secure https url
Exgravatar.generate("jdoe@example.com", %{}, true)
#=> "https://secure.gravatar.com/avatar/694ea0904ceaf766c6738166ed89bafb"