Overview
A Resource is a reusable value you define once and use throughout your Dynamic Component. Resources, power filters, formulas, interactions, conditional visibility, and the values that flow between your component, Flows, and Agentforce.
This page helps you pick the right type and explains how Resources relate to Data Sources.
Resource vs. Data Source
Avonni has two different concepts that both deal with data. They answer different questions.
Resource
What values should my filters, formulas, or interactions use?
A Variable holding the current user's region
Data Source
What records should this component display?
A Data Table showing open Opportunities
Resources feed logic. Data Sources feed components.
Rule of thumb
If you're building a filter, a formula, an interaction, or a visibility condition, you want a Resource. If you're feeding records into a data-aware component, you want a Data Source
The Three Resource Types
A single fixed value
No — set once, never changes
Default country codes, max record limits, status codes, record type IDs
A computed value derived from other Resources and fields
Recomputed automatically when its inputs change
Full name from first + last, totals, conditional labels, formatted strings
Any value — text, number, boolean, date, record, or JSON
Yes — read and written during the component's lifecycle
Filters, toggles, form state, records, Flow outputs, Agentforce responses, JSON collections
Choosing the Right Resource
Walk through these questions in order:
Does the value never change, ever? → use Constant.
Is the value computed from other values or Salesforce fields? → use Formula.
Does the value need to be read, updated, or written to during the component's lifecycle? → use Variable.
Do you need to store structured data, a collection, or a Flow output? → use a Variable with the JSON data type.
Variables are the most flexible Resource type
With the JSON data type, a Variable can hold an entire record, a collection of records, or any nested structure — making it the bridge between Flows, Agentforce, Assignment Interactions, and your components
A Note on Query and Nested Queries
You may notice that Query and Nested Queries are not listed in this Resources panel. That's deliberate.
In the Avonni app, Queries and Nested Queries are configured as Data Sources — directly on data-aware components — because that's where they're most useful. Under the hood they work like Resources, but exposing them in the component's Data Source section keeps the configuration close to the thing that displays the records.
Fetch records to feed a Data Table, List, Kanban, Map, etc.
Data Sources
Pull parent-child or multi-object records in one structure
Data Sources
See the Data Sources Overview for the full picture.
Where to Create a Resource
All Resources are managed in the Resources panel inside the Component Builder.
Open the Component Builder for your Dynamic Component.
Click the Resources button to open the Resources panel.
Click New Resource (usually a + icon).
Choose the type: Constant, Formula, or Variable.
Configure the resource — API name, data type, default value, and any type-specific settings.
Click Save.
Referencing a Resource
Once a Resource exists, you can use it anywhere a dynamic value is accepted — filter values, component defaults, formula expressions, interaction inputs, visibility conditions, and more.
Open the property where you want the value.
Click the resource selection icon next to the field.
Pick the Resource from the list.
The reference is inserted automatically, wrapped in curly braces:
{!DEFAULT_COUNTRY_CODE}— reference a Constant{!currentUserRegion}— reference a Variable{!selectedRecord.Account.Name}— drill into a JSON Variable's nested path{{Record.email}}— reference a Variable inside a loop (for example, a Repeater bound to a JSON Collection)
Last updated
Was this helpful?
