K
Docs
API Reference→Pieces→Grab Avatar
👤

Grab Avatar

img.avatarThe DarkroomImages

Fetches a member's avatar as an image spark you can drop into the Studio, touch up, or attach. Leave Whose avatar empty for whoever triggered the flow — or whoever got right-clicked. Animated avatars stay animated unless you freeze them.

When to use this
  • →Point it at a member input — {{options.member}} — to grab anyone's avatar
  • →Avatar sparks already exist everywhere as {{user.avatar}}; you only need this piece to resize, freeze, or use the server avatar

On the canvas

This is what Grab Avatar looks like when you place it on your flow. Each field below is something you configure in the inspector panel.

👤
Grab Avatar
img.avatar
Images
user
Empty = whoever triggered it · or {{options.member}}
serverAvatar
boolean…
size
select…
stillOnly
boolean…
as
avatar
output
error

Config fields

FieldTypeReqWhat it does
user
Empty = whoever triggered it · or {{options.member}}
text—Whose avatar 👤
serverAvatarboolean—Use their server avatar 🏠
sizeselect—Size 📐
stillOnlyboolean—Freeze animated avatars ❄️
as
avatar
text—Save it as ✨

Output ports

outputThe avatar is in your spark
errorNo such user, or Discord didn't answer
📐

In TypeScript, this would be…

Not something you need to write — just a look at what Kitcord does for you.

TypeScript
// Animated avatars come back as .gif, everyone else as .png
const url = member.displayAvatarURL({ size: 512, extension: "png", forceStatic: false });
const avatar = await loadImage(url); // @napi-rs/canvas