A Simple, Gravatar-compatible API server.
Note
This project was made without proper planning or anything, so expect it to be bad.
The only endpoint is /avatar
Create a POST request to the endpoint with multipart/form-data body containing:
| Field | Content |
|---|---|
| User's email | |
| avatar | The avatar image file |
Note
Only image/png, image/jpeg, and image/webp (if compiled with -tags vips) are supported.
And with Authorization: <secret> header. Secret is the AWATA_SECRET environment.
Create a GET request to the endpoint with /avatar/<hash, sha256 or md5>
| Key | |
|---|---|
d, default |
Default response when avatar is not found. |
s, size |
Size of the image, mix 1, and max 2048. |
f, force |
Force the use of default, regardless if avatar exist or not. |
Note
Only 404, mp/mm, and identicon are supported defaults.