Logic Blocks, Glyphs and agents belong to your organization and run for every tenant. Each run receives the organization's flags already worked out for the person and tenant it is running for, in the same way it receives tenant settings. There is nothing to call and nothing to configure.
| Where | Write | Missing flag |
|---|---|---|
| Logic Block step or condition | {{params.flags.new-checkout}} | empty |
| Agent instructions | {{params.flags.new-checkout}} — filled in when the agent runs | empty |
| JavaScript Glyph | ctx.params.flags['new-checkout'] | undefined |
| Python Glyph | ctx.params.flags.get('new-checkout', False) | your default |
A Logic Block
Use the value in any step field, or branch on it with a condition step:
{
"id": "pricing",
"type": "condition",
"config": { "field": "{{params.flags.new-pricing}}", "operator": "==", "value": "true" },
"then": ["use_new_price"],
"else": ["use_old_price"]
} Because the block is the same for every tenant, two tenants running it get different results only because their flags differ — exactly what you want.
A Glyph
// JavaScript
module.exports.handler = async (request, ctx) => {
const useNew = ctx.params.flags['new-pricing'] ?? false;
return { price: useNew ? newPrice(request) : oldPrice(request) };
}; # Python
def handler(request, ctx):
use_new = ctx.params.flags.get('new-pricing', False)
return {'price': new_price(request) if use_new else old_price(request)} An agent
Put the token in the agent's instructions and the value is filled in for the run, so you can change how an agent behaves per tenant or per rollout without editing it:
You are the support assistant.
Beta features enabled for this customer: {{params.flags.beta-features}} The value goes to the model
What you write in instructions reaches the AI provider. Flags are plain values and never secrets; keep anything sensitive in Secrets, not in a flag.
Who the run is evaluated as
| The run is… | Evaluated as |
|---|---|
| Started by a signed-in user (HTTP, WebSocket, console test) | That user — so a percentage rollout is stable per person. |
| A schedule | The user the schedule runs as. |
| An event or background run with nobody behind it | The tenant itself — so a percentage rollout gives the same answer for every such run of that tenant. |
Good to know
- Flags are read when the run starts; a run that is already going is not changed halfway.
- A scheduled change is in effect for any run that starts after it.
- If flags cannot be read, the run still works — they are just missing. Give your asset its own default.
- What the asset does with a value is up to you; flags only hand it over.
- Settings and secrets work exactly as before.