K
Docs
API ReferencePiecesFormat Text
✒️

Format Text

base.formatBase SetUtility

Constructs a piece of text by filling in a template with live values. Combine static text with Sparks to build dynamic messages, labels, or anything that needs to be assembled from parts.

When to use this
  • Drop any ✨ Spark into the template using {{sparkName}}
  • Great for building complex strings before passing them to a Reply or Send Embed

On the canvas

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

✒️
Format Text
base.format
Utility
templaterequired
🏅 {{user.name}} has {{result.0.coins}} coins! Nice!
asrequired
formatted (becomes a Spark!)

Config fields

FieldTypeReqWhat it does
template
🏅 {{user.name}} has {{result.0.coins}} coins! Nice!
textareayesThe template 📝
as
formatted (becomes a Spark!)
textyesName the result ✨

Sparks this piece adds

After this piece runs, these values are available as sparks in every node downstream.

{{formatted}}stringFormatted text

Output ports

outputMoves on with the formatted text available as a Spark
📐

In TypeScript, this would be…

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

TypeScript
const line = `#1. ${player.name} — ${player.coins} coins`;
// Template: "#{{rank}}. {{player.name}} — {{player.coins}} coins"