Skip to main content
Glama

set_field_value_cf

Apply conditional formatting by using a measure's returned color to set column background, font, or icon directly.

Instructions

FORMAT BY FIELD VALUE conditional formatting on a table/matrix column: a measure that returns a hex/CSS colour drives the column's background, font or icon colour DIRECTLY (not a rule/gradient - the measure's returned colour IS the colour). target=background|font|icon. colorMeasure = "Table[Measure]" (or pass colorMeasureTable). column = the column's queryRef e.g. 'Dim_Product.Brand'.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageYespage name or displayName
columnYesthe column's queryRef, e.g. Dim_Product.Brand
targetYesbackground | font | icon
visualYestable/matrix visual name
colorMeasureYescolour measure, e.g. Fact[Colour] or just the measure name with colorMeasureTable
reportSessionIdYes
colorMeasureTableNotable that owns the colour measure (if not in colorMeasure)
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden. It discloses the direct color application behavior and parameter roles, which is helpful. But it does not mention whether existing conditional formatting is overwritten, what happens if the measure returns an invalid color, or any prerequisites such as the visual needing to be a table/matrix. More behavioral detail would improve transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but efficient, with three sentences covering purpose, mechanism, and parameter formats. The first sentence front-loads the core purpose and key distinction. It is not as tight as a two-sentence example, but every sentence earns its place with useful information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema and no annotations, the description provides substantial context: the tool's purpose, how it works, and parameter formats. It covers the essential behavior and the main parameters (target, colorMeasure, column). It could add preconditions or failure behavior, but for a formatting tool with this complexity, it is reasonably complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 86%, so the baseline is 3. The description adds meaningful parameter semantics beyond the schema: it explains that colorMeasure takes 'Table[Measure]' or can use colorMeasureTable, and it gives a concrete example for the column queryRef. It also clarifies the meaning of the target parameter (background|font|icon) in context. This goes beyond the schema descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool sets conditional formatting on a table/matrix column based on a measure's returned color. It explicitly distinguishes from rule/gradient formatting by emphasizing the measure's returned color IS the color. This differentiates it from sibling tools like set_gradient_color or set_color_scale.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context: use when you want a measure to directly drive the column's background, font, or icon color. It explicitly contrasts with rule/gradient approaches, giving an implicit when-not-to-use. However, it does not name specific alternative tools, so it stops short of full guidance with explicit alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cyphonica/powerbi-pbix-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server