Skip to main content
Glama
redesignhealth

Google Workspace MCP Server

add_conditional_formatting

Apply conditional formatting to Google Sheets cells based on numeric, text, date, or custom formula rules, including background and text colors, with support for gradient color scales.

Instructions

Adds a conditional formatting rule to a range.

Args: user_google_email (str): The user's Google email address. Required. spreadsheet_id (str): The ID of the spreadsheet. Required. range_name (str): A1-style range (optionally with sheet name). Required. condition_type (str): Sheets condition type (e.g., NUMBER_GREATER, TEXT_CONTAINS, DATE_BEFORE, CUSTOM_FORMULA). condition_values (Optional[Union[str, List[Union[str, int, float]]]]): Values for the condition; accepts a list or a JSON string representing a list. Depends on condition_type. background_color (Optional[str]): Hex background color to apply when condition matches. text_color (Optional[str]): Hex text color to apply when condition matches. rule_index (Optional[int]): Optional position to insert the rule (0-based) within the sheet's rules. gradient_points (Optional[Union[str, List[dict]]]): List (or JSON list) of gradient points for a color scale. If provided, a gradient rule is created and boolean parameters are ignored.

Returns: str: Confirmation of the added rule.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
range_nameYes
rule_indexNo
text_colorNo
condition_typeYes
spreadsheet_idYes
gradient_pointsNo
background_colorNo
condition_valuesNo
user_google_emailYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/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 effect (adds a rule), key behavioral details (e.g., gradient points create a gradient rule and ignore boolean parameters), and return type. It lacks permission or auth context, but the required user_google_email parameter hints at authentication.

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 well-structured with a concise one-sentence purpose followed by an Args section and a Returns section. It is longer due to the parameter explanations, but every sentence serves a purpose given the lack of schema descriptions.

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 the tool's complexity (9 parameters, no annotations, no schema descriptions), the description is nearly complete. It covers all parameters, behavior, and return value. It does not address error conditions or prerequisites beyond user_google_email, but this is a minor gap.

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

Parameters5/5

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

The description provides detailed explanations for all 9 parameters, including types, required status, and dependencies (e.g., 'Values for the condition... Depends on condition_type'). Since schema coverage is 0%, this fully compensates and adds significant meaning beyond the schema.

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 'Adds a conditional formatting rule to a range' with a specific verb and resource. It distinguishes from sibling tools like update_conditional_formatting and delete_conditional_formatting by focusing on the 'add' action.

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

Usage Guidelines2/5

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

No explicit guidance on when to use this tool versus alternatives. Sibling tools (update_conditional_formatting, delete_conditional_formatting) exist, but the description does not mention them or provide context on choosing this tool. Usage is only implied by the word 'Adds'.

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/redesignhealth/google-mcp-unofficial'

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