Appwrite icon

Appwrite

Interact with Appwrite API

Actions181

Avatars → Get Initials Avatar

AI-generated

Overview

This node interacts with the Appwrite API to generate an initials avatar image based on a provided full name. It is useful for creating personalized avatar images when user profile pictures are not available, such as in user management systems, chat applications, or any platform requiring user identification visuals. The node allows customization of the avatar's dimensions and background color.

Use Case Examples

  1. Generating an avatar image with initials from a user's full name for display in a user profile.
  2. Creating default avatars for users who have not uploaded a profile picture, using their initials and a random or specified background color.

Properties

Name Meaning
Name Full name used to generate initials for the avatar. If left empty, the current user's name or email is used. Maximum length is 128 characters.
Width Width of the generated avatar image in pixels. Accepts values from 0 to 2000, where 0 means the original width is used.
Height Height of the generated avatar image in pixels. Accepts values from 0 to 2000, where 0 means the original height is used.
Background Color Background color of the avatar image in hexadecimal format (without the #). If left empty, a random color is used.

Output

JSON

  • url - URL of the generated initials avatar image.

Dependencies

  • Requires an Appwrite API key credential with access to the Avatars service.

Troubleshooting

  • Ensure the Appwrite API credentials (endpoint, project ID, API key) are correctly configured to avoid authentication errors.
  • Verify that the 'Name' property does not exceed 128 characters to prevent input validation errors.
  • If the avatar image does not generate, check that the width and height values are within the allowed range (0-2000).
  • Background color must be a valid hex string without the '#' prefix; otherwise, the node may default to a random color or fail.

Links

Discussion