Edit history

Support dynamic placeholders in custom badge descriptions has not been edited, so there are no earlier versions.

Current version | Original by penguin
Show

Support dynamic placeholders in custom badge descriptions

Current problem

Custom user and guild badges currently only support static descriptions. Every recipient of the same badge sees identical tooltip text, even when relevant information is already available in Fluxer. For example, administrators cannot dynamically include a user's account creation date, a community's creation date, or other available information in a badge description. Fluxer already uses dynamic information for certain built-in badges, such as displaying when a user started their Plutonium subscription. Having similar functionality for custom badges would allow administrators to create more informative and personalized descriptions without manually maintaining or updating their content.

Proposed change

Allow instance administrators to use dynamic placeholders in custom user and guild badge descriptions. These placeholders would automatically resolve to the corresponding information for the user or community displaying the badge. A small initial implementation could already provide significant value by supporting a few commonly available properties, for example: User properties:
  • {user.display_name} – User's display name
  • {user.created_at} – Account creation date on the instance
Guild properties:
  • {guild.name} – Community name
  • {guild.created_at} – Community creation date
Instance-wide properties:
  • {instance.name} – Public instance name
  • {instance.domain} – Public instance domain
Ideally, placeholders would not be strictly limited to the badge's own category. For example, both user and guild badges could use instance-wide information where applicable. The system could initially support only a small selection of existing data, while being designed to accommodate additional placeholders over time. Potential future additions could include: Badge properties:
  • {badge.awarded_at} – Date the badge was awarded
  • {badge.recipient_count} – Number of recipients
Additional user properties:
  • {user.guild_count} – Number of communities joined
  • {user.application_count} – Number of applications created
Additional guild properties:
  • {guild.member_count} – Current member count
  • {guild.age} – Time since the community was created
Descriptions containing values that change over time could automatically display updated information without requiring manual changes. This request is about dynamically resolving badge descriptions, not automatic badge assignment or an achievement system. Only information suitable for public display should be available through placeholders. Sensitive or private account information must remain inaccessible.

Platform

Web, API, Self-hosting

Additional information

Example 1 – User badge with account information Configured description: Member since {user.created_at}. Displayed tooltip: Member since June 12, 2024. Each recipient would see their own account creation date, regardless of which communities they belong to. Example 2 – Guild badge Configured description: Community established on {guild.created_at}. Displayed tooltip: Community established on March 15, 2023. The same badge could be assigned to multiple communities while displaying their respective creation dates. Example 3 – Instance-wide information Configured description: Member of {instance.name} since {user.created_at}. Displayed tooltip: Member of My Fluxer Instance since June 12, 2024. This would allow user badges to reference the overall instance rather than a specific community. It would also work for users who do not belong to any communities and primarily use Fluxer for direct messaging. Example 4 – Dynamic community statistics (future extension) Configured description: Currently home to {guild.member_count} members. Displayed tooltip: Currently home to 248 members. The number would automatically reflect the latest available member count without manual updates. Example 5 – Badge award date (future extension) Configured description: Awarded on {badge.awarded_at}. Displayed tooltip: Awarded on October 20, 2026. This could be useful for recognition badges, competitions, anniversaries, partnerships, and other achievements. Additional considerations:
  • Support multiple placeholders within a single description.
  • Allow placeholders to be freely combined with ordinary text.
  • Format dates according to the viewer's locale.
  • Provide a list of available placeholders in the badge editor.
  • Optionally provide a preview of the resolved description.
  • Handle missing or unavailable values gracefully.
  • Keep existing static badge descriptions fully compatible.
  • Restrict placeholders to information appropriate for public display.
  • Allow additional placeholders to be introduced over time without redesigning the system.
Some properties, such as the date a badge was awarded, may require additional data to be stored if they are not already available. The initial implementation does not need to include every suggested variable. A small, extensible foundation would already be a valuable improvement.