Node-gravatar is a project mainly written in JavaScript, it's free.
Create gravatar URLs and use their API in node.js
A library to assemble gravatar URLs for image and profile requests, as well as the JSON API.
gravatar.createHash(email)
Creates and returns a hash of the email address according to the gravatar implementation guide.
gravatar.imageUrlFor(hash[, options])
Assembles the image URL for the hash. options is a object with the following supported keys:
gravatar.profileUrlFor(hash[, format, callback])
Assembles the profile URL for the hash. If format and callback are omitted the human-usable profile URL is generated. If format is set to 'json', the JavaScript API URL is generated. The callback parameter can be used to enclose the JSON data in a callback for client-side use.
gravatar.getProfileFor(hash, callback)
Retrieves the JSON profile data object via HTTP. callback
is a function with two parameters: function(err, data)
The data parameter will be set to the decoded JSON object retrieved from the API service.