Skip to main content
Glama
thenavidm
by thenavidm

Upsert a link for a partner

upsert_partner_link
Destructive

Create or update a short link for an enrolled partner; if the URL already exists, return or update it instead of creating a duplicate.

Instructions

Upsert a link for a partner that is enrolled in your program. If a link with the same URL already exists, return it (or update it if there are any changes). Otherwise, a new link will be created.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyNoThe short link slug. If not provided, a random 7-character slug will be generated.
urlNoThe URL to upsert for.
accountNoExact configured private workspace profile label; not a tenant or provider account ID.
confirmNoMust be true for the requested mutation or exclusive private output file.
payloadNoComplete native JSON body; do not mix with body flags or payload_file. Arrays use repeated JSON object flags or a whole native array in a private file.
commentsNoThe comments for the short link.
tenantIdNoThe ID of the partner in your system. If both `partnerId` and `tenantId` are not provided, an error will be thrown.
linkPropsNoAdditional properties that you can pass to the partner's short link. Will be used to override the default link properties for this partner.
partnerIdNoThe ID of the partner to create a link for. Will take precedence over `tenantId` if provided.
payload_fileNoAbsolute regular non-symlink JSON body file, at most 1 MiB. Cannot mix with payload/body flags.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already cover the safety profile (destructive=true, openWorld=true, readOnly=false), and the description usefully adds the URL-keyed match/update semantics. It does not say what happens to existing link properties that are omitted (overwritten vs preserved), and the 'return it if unchanged' wording sits in mild tension with idempotentHint=false without resolving it.

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?

Two sentences with zero filler, front-loading the operation and then the branch behavior. Every clause carries information; nothing is restated from the title or schema.

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

Completeness3/5

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

For a 10-parameter, nested-payload mutation the description omits important framing: that partnerId or tenantId must be supplied or an error is thrown, that confirm=true is required, and that body can be passed either as flat flags or as a native payload. It is adequate but leaves the agent to discover these from the schema.

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?

Schema description coverage is 100%, so all 10 properties (key, url, account, confirm, payload, partnerId, tenantId, linkProps, etc.) are already documented in the schema. The description adds no parameter-level meaning beyond that, which is the expected baseline when the schema carries the load.

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

Purpose4/5

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

States a specific verb (upsert) and resource (a short link for a partner) plus a scoping condition (partner must be enrolled in your program). It does not, however, contrast itself with close siblings like create_partner_link or upsert_link, so the agent still has to infer the distinction.

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

Usage Guidelines3/5

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

The description explains the create-vs-update branch (existing URL is returned or updated, otherwise created), which implies when the tool is appropriate. It gives no explicit when-not guidance and never names an alternative, so routing between this and create_partner_link / upsert_link is left to inference.

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