Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Import an avatar image from the Gravatar service
ResourceFunction["ImportGravatarImage"][email] imports an avatar image associated with the email address email from the Gravatar service. |
ImageSize | 80 | size of returned avatar |
"DefaultImage" | "" | URL or ID of default image |
"ForceDefault" | False | always return "DefaultImage" |
"Rating" | "G" | return avatars suitable to rating |
"mp" | a generic "missing person" avatar | |
"identicon" | a generated colorful geometric pattern | |
"monsterid" | a generated "monster" avatar | |
"wavatar" | a generated "cartoon" avatar | |
"retro" | a generated "8-bit face" avatar | |
"robohash" | a generated "robot" avatar | |
"404" | returns HTTP 404 instead of a default image | |
"blank" | a transparent PNG image |
"G" | suitable for display on all websites with any audience type |
"PG" | may contain rude gestures, provocatively dressed individuals, lesser swear words or mild violence |
"R" | may contain such things as harsh profanity, intense violence, nudity or hard drug use |
"X" | may contain hardcore sexual imagery or extremely disturbing violence |
Import an avatar from an email address:
In[1]:= |
Out[1]= |
Specify a nondefault image size:
In[2]:= |
Out[2]= |
Specify a fallback avatar:
In[3]:= |
Out[3]= |
Always show the fallback avatar:
In[4]:= |
Out[4]= |
If you set "DefaultImage" to one of the generators and set "ForceDefault" to True, this turns the Gravatar service into an avatar generator:
In[5]:= |
Out[5]= |
By default, the Gravatar service will only allow avatars that have a "G" rating. You can allow "PG"-, "R"- or "X"-rated avatars if you wish:
In[6]:= |
Out[6]= |
This work is licensed under a Creative Commons Attribution 4.0 International License