Skip to main content
Glama

Update API Test

update_api_test
DestructiveIdempotent

Replace the entire configuration of an existing API test (identified by apiTestId) with the supplied values — a full overwrite, not a partial patch, so pass every field you want to keep. Same parameters and request variables as create_api_test. Does not touch notification destinations; change those with set_api_test_destinations. If the change affects how the probe behaves (target, credential, assertions or timeout), the updated test is run once before it is saved, the same way create_api_test does; a failing trial run leaves the existing test unchanged and returns an error that says what failed. Changing only the name, interval, retries, failure threshold or enabled flag saves without a trial run. Returns the updated API test and its state. The target URL must be reachable from the public internet; private, loopback and cloud-internal addresses are refused.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "apiTestId": "<apiTestId>",
      "name": "<name>",
      "type": "<type>",
      "intervalSeconds": "<intervalSeconds>",
      "timeoutSeconds": "<timeoutSeconds>",
      "retries": "<retries>",
      "failureThreshold": "<failureThreshold>",
      "enabled": "<enabled>"
    },
    "name": "update_api_test"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesHuman-readable name for the API test
typeYesAPI test type: 'HTTP' or 'MCP'
mcpUrlNoMCP only: the MCP server URL to probe
enabledYesWhether the API test is enabled (scheduled) or paused
httpUrlNoHTTP only: the http(s) URL to probe. Supports {{uuid}}, {{now}}, {{date}}, {{timestamp}}, {{timestampMs}}, {{timestampNs}}, {{randomInt}} and {{traceId}} variables, resolved once per run; write \{{ for a literal {{.
mcpTierNoMCP only: assertion tier — UPTIME, HANDSHAKE, TOOLS_LIST or TOOL_CALL
retriesYesRetries per run before recording a failure (0-5)
httpBodyNoHTTP only: request body
toolNameNoMCP TOOL_CALL tier: name of the tool to invoke
apiTestIdYesId of the API test to update (from list_api_tests or get_api_test)
httpMethodNoHTTP only: request method — GET, POST, PUT, PATCH, DELETE or HEAD
httpHeadersNoHTTP only: request headers, as a name->value map
expectedToolsNoMCP TOOLS_LIST tier: tool names the server must advertise
statusPatternNoHTTP only: status matcher — '200', '2xx' or '20x'
headerMatchersNoHTTP only: response headers that must match, as a name->value map
timeoutSecondsYesPer-run timeout in seconds, 1-30
intervalSecondsYesHow often to run the API test, in seconds (minimum 30)
mcpCredentialIdNoMCP only: id of a stored credential
failureThresholdYesConsecutive failing runs before the API test flips to DOWN (1-10)
httpCredentialIdNoHTTP only: id of a stored credential; omit for unauthenticated
maxLatencyMillisNoHTTP only: fail if slower than this many milliseconds
toolArgumentsJsonNoMCP TOOL_CALL tier: JSON object of tool arguments; omit it for a tool that takes none. Supports {{uuid}}, {{now}}, {{date}}, {{timestamp}}, {{timestampMs}}, {{timestampNs}}, {{randomInt}} and {{traceId}} variables, resolved once per run; write \{{ for a literal {{.
bodyValidationTierNoHTTP only: body validation tier — NONE, VALID_JSON, JSON_CONTAINS (sample fields must be present with the same types, extra fields allowed), JSON_SHAPE (exact field set) or EXACT_MATCH
mcpMaxLatencyMillisNoMCP only: fail if slower than this many milliseconds
mcpProtocolRevisionNoMCP only: protocol revision policy — ANY (the default when omitted), NEWEST_SUPPORTED, or a dated revision: 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28. ANY checks that the endpoint answers as an MCP server and records whatever revision it speaks, without asserting it. NEWEST_SUPPORTED runs against the newest protocol revision the server speaks and moves with it when the server changes. A dated revision pins the test to it and the test fails if the server stops accepting it. Get the server's revisions from detect_mcp_protocol.
bodyValidationSampleNoHTTP only: sample body for JSON_CONTAINS/JSON_SHAPE/EXACT_MATCH tiers
mcpResultValidationTierNoMCP TOOL_CALL tier: result validation tier — NONE, VALID_JSON, JSON_CONTAINS, JSON_SHAPE or EXACT_MATCH
mcpResultValidationSampleNoMCP TOOL_CALL tier: sample result for JSON_CONTAINS/JSON_SHAPE/EXACT_MATCH

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / toolArgumentsJson / description
      Previous value: -"MCP TOOL_CALL tier: JSON object of tool arguments. Supports {{uuid}}, {{now}}, {{date}}, {{timestamp}}, {{timestampMs}}, {{timestampNs}}, {{randomInt}} and {{traceId}} variables, resolved once per run; write \\{{ for a literal {{."New value: +"MCP TOOL_CALL tier: JSON object of tool arguments; omit it for a tool that takes none. Supports {{uuid}}, {{now}}, {{date}}, {{timestamp}}, {{timestampMs}}, {{timestampNs}}, {{randomInt}} and {{traceId}} variables, resolved once per run; write \\{{ for a literal {{."
  2. Changed2 schema fields changed
    • changedInput schema / properties / mcpProtocolRevision / description
      Previous value: -"MCP only: protocol revision policy — ANY (the default when omitted), NEWEST_SUPPORTED, or a dated revision: 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28. ANY checks that the endpoint answers as an MCP server and records whatever revision it speaks, without asserting it; at the HANDSHAKE tier, a server that answers 401 or 403 when the test has no credential counts as up. NEWEST_SUPPORTED runs against the newest protocol revision the server speaks and moves with it when the server changes. A dated revision pins the test to it and the test fails if the server stops accepting it. Get the server's revisions from detect_mcp_protocol."New value: +"MCP only: protocol revision policy — ANY (the default when omitted), NEWEST_SUPPORTED, or a dated revision: 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28. ANY checks that the endpoint answers as an MCP server and records whatever revision it speaks, without asserting it. NEWEST_SUPPORTED runs against the newest protocol revision the server speaks and moves with it when the server changes. A dated revision pins the test to it and the test fails if the server stops accepting it. Get the server's revisions from detect_mcp_protocol."
    • changedInput schema / properties / mcpTier / description
      Previous value: -"MCP only: assertion tier — HANDSHAKE, TOOLS_LIST or TOOL_CALL"New value: +"MCP only: assertion tier — UPTIME, HANDSHAKE, TOOLS_LIST or TOOL_CALL"
  3. Changed1 schema field changed
    • changedInput schema / properties / mcpProtocolRevision / description
      Previous value: -"MCP only: protocol revision the test speaks — 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28 or NEWEST_SUPPORTED (the default when omitted). NEWEST_SUPPORTED runs against the newest protocol revision the server speaks and moves with it when the server changes; a dated revision pins the test to it and the test fails if the server stops accepting it. Get the server's revisions from detect_mcp_protocol."New value: +"MCP only: protocol revision policy — ANY (the default when omitted), NEWEST_SUPPORTED, or a dated revision: 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28. ANY checks that the endpoint answers as an MCP server and records whatever revision it speaks, without asserting it; at the HANDSHAKE tier, a server that answers 401 or 403 when the test has no credential counts as up. NEWEST_SUPPORTED runs against the newest protocol revision the server speaks and moves with it when the server changes. A dated revision pins the test to it and the test fails if the server stops accepting it. Get the server's revisions from detect_mcp_protocol."
  4. Changed2 schema fields changed
    • addedInput schema / properties / mcpProtocolRevision
      Added value: +{
      +  "description": "MCP only: protocol revision the test speaks — 2024-11-05, 2025-03-26, 2025-06-18, 2025-11-25, 2026-07-28 or NEWEST_SUPPORTED (the default when omitted). NEWEST_SUPPORTED runs against the newest protocol revision the server speaks and moves with it when the server changes; a dated revision pins the test to it and the test fails if the server stops accepting it. Get the server's revisions from detect_mcp_protocol.",
      +  "type": "string"
      +}
    • changedInput schema / properties / timeoutSeconds / description
      Previous value: -"Per-run timeout in seconds; positive and not exceeding intervalSeconds"New value: +"Per-run timeout in seconds, 1-30"
  5. Changed4 schema fields changed
    • changedInput schema / properties / bodyValidationSample / description
      Previous value: -"HTTP only: sample body for JSON_SHAPE/EXACT_MATCH tiers"New value: +"HTTP only: sample body for JSON_CONTAINS/JSON_SHAPE/EXACT_MATCH tiers"
    • changedInput schema / properties / bodyValidationTier / description
      Previous value: -"HTTP only: body validation tier — NONE, VALID_JSON, JSON_SHAPE or EXACT_MATCH"New value: +"HTTP only: body validation tier — NONE, VALID_JSON, JSON_CONTAINS (sample fields must be present with the same types, extra fields allowed), JSON_SHAPE (exact field set) or EXACT_MATCH"
    • changedInput schema / properties / mcpResultValidationSample / description
      Previous value: -"MCP TOOL_CALL tier: sample result for JSON_SHAPE/EXACT_MATCH"New value: +"MCP TOOL_CALL tier: sample result for JSON_CONTAINS/JSON_SHAPE/EXACT_MATCH"
    • changedInput schema / properties / mcpResultValidationTier / description
      Previous value: -"MCP TOOL_CALL tier: result validation tier"New value: +"MCP TOOL_CALL tier: result validation tier — NONE, VALID_JSON, JSON_CONTAINS, JSON_SHAPE or EXACT_MATCH"
  6. Changed8 schema fields changed
    • addedInput schema / $schema
      Added value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / failureThreshold / format
      Added value: +"int32"
    • addedInput schema / properties / intervalSeconds / format
      Added value: +"int32"
    • addedInput schema / properties / maxLatencyMillis / format
      Added value: +"int64"
    • addedInput schema / properties / mcpMaxLatencyMillis / format
      Added value: +"int64"
    • addedInput schema / properties / retries / format
      Added value: +"int32"
    • addedInput schema / properties / timeoutSeconds / format
      Added value: +"int32"
  7. Added
  8. Removed
  9. Changed2 schema fields changed
    • changedInput schema / properties / httpUrl / description
      Previous value: -"HTTP only: the http(s) URL to probe"New value: +"HTTP only: the http(s) URL to probe. Supports {{uuid}}, {{now}}, {{date}}, {{timestamp}}, {{timestampMs}}, {{timestampNs}}, {{randomInt}} and {{traceId}} variables, resolved once per run; write \\{{ for a literal {{."
    • changedInput schema / properties / toolArgumentsJson / description
      Previous value: -"MCP TOOL_CALL tier: JSON object of tool arguments"New value: +"MCP TOOL_CALL tier: JSON object of tool arguments. Supports {{uuid}}, {{now}}, {{date}}, {{timestamp}}, {{timestampMs}}, {{timestampNs}}, {{randomInt}} and {{traceId}} variables, resolved once per run; write \\{{ for a literal {{."
  10. Added

TDQS

A4.8/5.0
Behavior5/5

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

Goes well beyond the annotations (destructive/idempotent/openWorld) by disclosing the overwrite semantics, the conditional trial-run behavior (runs once before saving when target/credential/assertions/timeout change), the exact failure mode (existing test left unchanged, error returned describing the failure), which changes skip the trial run, and the public-internet address restriction.

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 most consequential constraint (full overwrite, pass every field) is front-loaded in the first sentence. Subsequent sentences each carry distinct operational information, though the trial-run explanation is dense and could be tightened.

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?

For a 28-parameter destructive mutation with no output schema, the description covers invocation semantics, destructive risk, conditional side effects, error behavior, and the return value ('the updated API test and its state'). Nothing an agent needs to call it safely is missing.

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 100%, so the baseline is 3; the description adds real semantic value by grouping fields into behavior classes — which fields trigger a trial run versus which save instantly — information the schema does not encode. It does not, however, add format or enum guidance for individual optional fields (e.g. MCP tier selection).

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?

States a specific verb+resource ('Replace the entire configuration of an existing API test') and immediately clarifies scope: full overwrite, not a partial patch. It also distinguishes itself from two siblings by name (create_api_test for shared shape, set_api_test_destinations for notification changes).

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?

Explicitly tells the agent to pass every field it wants to keep, routes notification-destination changes to set_api_test_destinations, and points at create_api_test for the shared parameter set. The alternative and the exclusion are named rather than inferred.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources