Skip to main content
Glama
SmartBear

SmartBear MCP server

Official
by SmartBear

QMetry: Fetch Test Run UDF Metadata

qmetry_fetch_test_run_udf_metadata
Read-onlyIdempotent

Retrieves field definitions and IDs for all Test Run UDF fields in a QMetry project, enabling accurate bulk updates.

Instructions

Fetch the metadata (field definitions) for all Test Run UDF (User Defined Fields) configured in this QMetry project. Returns each field's name, display label, type, and numeric fieldID (projectUserFieldID) required for bulk updates.

Toolset: UDF

Parameters:

  • projectKey (string): Project key - unique identifier for the project (default: "default")

Output Description: JSON object with 'fields' array (each item has fieldID, name, label, fieldType, allowBlank, and optional listName/listMasterID) and 'lookupOptions' map for list-based fields. If lookupOptions is empty for a list field, options could not be fetched automatically.

Use Cases: 1. Get the fieldID for 'planned_execution_date' before bulk updating it 2. List all available Test Run UDF fields and their types in the project 3. Find the lookup list item IDs for a LOOKUPLIST or MULTILOOKUPLIST Test Run UDF 4. Discover UDF field names and IDs when user says 'what Test Run UDF fields are available'

Examples:

  1. List all Test Run UDF fields in the project

{}

Expected Output: Array of fields with fieldID, name, label, fieldType, and lookupOptions for list-based fields.

Hints: 1. ALWAYS call this tool before 'Bulk Update Test Run UDFs' when the user has not explicitly provided a numeric fieldID. The 'fieldID' in the bulk update corresponds to 'projectUserFieldID' in this response. 2. This tool is the authoritative source of fieldIDs for all Test Run UDF fields — do NOT guess or hard-code fieldIDs. 3. For LOOKUPLIST and MULTILOOKUPLIST fields, the response 'lookupOptions' contains items with 'id', 'name' (display label), and 'uniqueLabel' (internal key stored in executions). When execution UDF values are returned by Fetch Issue Executions or Fetch Test Run UDF Values, LOOKUPLIST/MULTILOOKUPLIST values are already resolved from uniqueLabel → name. For bulk updates, use the item 'id' as the value. 4. DATE fields use MM-DD-YYYY format (e.g. '06-23-2026') when setting values via Bulk Update Test Run UDFs. 5. EMPTY lookupOptions: If 'lookupOptions' is empty or missing a list key for a LOOKUPLIST/MULTILOOKUPLIST field, the API did not return options for that field. In this case the user must provide the option name manually or check the QMetry UI for available option IDs. Do NOT proceed with a guess — ask the user for the option ID or name.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectKeyNoProject key - unique identifier for the projectdefault
Install Server

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so no contradiction exists. The description adds substantial behavioral context beyond that: the exact response shape (fields array + lookupOptions map), the empty-lookupOptions failure mode and required user action, the mapping between fieldID and projectUserFieldID, and the resolved-value behavior for LOOKUPLIST/MULTILOOKUPLIST fields. It transparently discloses a known API limitation and instructs the agent not to guess.

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 clear Markdown sections (Toolset, Parameters, Output Description, Use Cases, Examples, Hints) and is front-loaded with the core purpose. It is on the verbose side — the Examples section largely repeats the Output Description, and Hints #3 and #5 are dense — but every major section earns its place given the complexity of UDF metadata and its downstream use in bulk updates.

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

Completeness5/5

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

Despite having no output schema, the description fully specifies the output structure, enumerates use cases, gives an invocation example, and documents edge cases (empty lookupOptions, DATE format, lookup item id semantics). It even coordinates with sibling tools like Bulk Update Test Run UDFs and Fetch Test Run UDF Values. For a single-parameter read-only tool, nothing an agent needs to call it correctly is missing.

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

Parameters3/5

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

The schema coverage is 100%, so the schema already documents projectKey with type, default, and description. The description's Parameters section largely repeats the schema, adding no new semantic detail beyond the context that fields are 'configured in this QMetry project.' Per the baseline rule for high schema coverage, a 3 is appropriate.

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 opens with a specific verb and resource: 'Fetch the metadata (field definitions) for all Test Run UDF ... configured in this QMetry project.' It clearly distinguishes itself from the sibling qmetry_fetch_test_run_udf_values (fetches values, not metadata) and qmetry_bulk_update_test_run_udfs (writes, not fetches). The intended output — field names, labels, types, and fieldID — is explicit.

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

Usage Guidelines5/5

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

The Hints section explicitly says 'ALWAYS call this tool before Bulk Update Test Run UDFs' and states it is the authoritative source of fieldIDs, with explicit 'do NOT guess or hard-code' guidance. It also provides concrete use cases, including when a user just asks what Test Run UDF fields are available, and explains how LOOKUPLIST/MULTILOOKUPLIST values are resolved by sibling value-fetching tools. This is explicit when-to-use and when-not-to-guess guidance, naming the relevant alternative.

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

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/SmartBear/smartbear-mcp'

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