Skip to main content
Glama
akhelij
by akhelij

apidog_upsert_endpoint

Creates or updates an API endpoint in Apidog, preserving the existing spec format and verifying the update.

Instructions

Create or update a single API endpoint. This is the primary write tool.

WORKFLOW (validated in POC):

  1. Exports current spec to preserve existing format

  2. Finds the target endpoint — reports if it exists (UPDATE) or not (CREATE)

  3. Computes a diff showing exactly what changed

  4. Merges the endpoint into the full spec

  5. Imports back to Apidog with OVERWRITE_EXISTING

  6. Verifies the update landed correctly

IMPORTANT: The operation object must match the Apidog OpenAPI format including x-apidog-* extensions. Always call apidog_get_endpoint first on a similar endpoint to learn the exact format used in this project.

The operation must include x-apidog-orders and x-apidog-ignore-properties arrays in schema objects to match the existing format. See existing endpoints for reference.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesEndpoint path
methodYes
operationYesFull OpenAPI operation object. Must include: summary, description, tags, parameters, requestBody (if applicable), responses, security, x-apidog-folder, x-apidog-status. Match the exact format of existing endpoints.
Behavior5/5

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

With no annotations, the description carries the full behavioral burden and does so thoroughly. It discloses a 6-step workflow, the overwrite/import behavior (OVERWRITE_EXISTING), diff computation, and post-write verification, so the agent can anticipate side effects and confirmation.

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

Conciseness5/5

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

The description is front-loaded with the primary purpose, then organized into a concise numbered workflow and an explicit IMPORTANT note. Despite being longer than a one-liner, every part earns its place given the complexity of the operation object format.

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?

The description covers the complete invocation workflow, prerequisites, and format requirements, which is more than sufficient for selecting and calling the tool. It does not describe the return value shape, but with no output schema this is a minor gap and the 'verifies' step hints at post-condition.

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?

The description enriches the operation parameter with important format constraints (x-apidog-* extensions, x-apidog-orders, x-apidog-ignore-properties) that the schema only partially covers. Path and method are self-explanatory, and the description does not need to restate them; it also instructs using get_endpoint as a format template.

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 opening sentence uses a specific verb+resource: 'Create or update a single API endpoint', and 'single' clearly distinguishes it from the sibling apidog_upsert_endpoints (bulk). The workflow reinforces that this is a targeted write operation, making the tool's scope unambiguous.

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?

It provides a clear prerequisite: always call apidog_get_endpoint first on a similar endpoint to learn the project's exact format. It does not explicitly contrast with apidog_upsert_endpoints or state when not to use it, but the 'single endpoint' framing supplies enough situational context for an agent to select it.

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/akhelij/apidog-sync-mcp-server'

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