Skip to main content
Glama

update_terms

Modify term metadata like display text, context, references, or tags in POEditor translation projects by identifying terms with their current values.

Instructions

Update term metadata such as the display text, context, references, or tags. Identify each term by its current term/context values.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idNo
itemsYes

Implementation Reference

  • Handler function that executes the update_terms tool logic: maps input items to payload, calls POEditor 'terms/update' API via poeditor helper, and formats response.
    UpdateTermsInput.shape,
    async (args) => {
      const id = requireProjectId(args.project_id ?? null);
      const payload = args.items.map((item) => {
        const termData: Record<string, any> = {
          term: item.term,
          context: item.context ?? ""
        };
        if (item.new_term) termData.new_term = item.new_term;
        if (item.new_context) termData.new_context = item.new_context;
        if (item.reference) termData.reference = item.reference;
        if (item.comment) termData.comment = item.comment;
        if (item.tags) termData.tags = item.tags;
        if (item.untranslatable !== undefined) {
          termData.untranslatable = item.untranslatable ? 1 : 0;
        }
        return termData;
      });
      const data = JSON.stringify(payload);
      const res = await poeditor("terms/update", { id: String(id), data });
      return { content: [{ type: "text", text: JSON.stringify(res.result ?? {}, null, 2) }] };
  • Zod input schema for update_terms tool defining project_id (optional) and array of items with current term/context and optional updates.
    const UpdateTermsInput = z.object({
      project_id: z.number().int().positive().optional(),
      items: z.array(z.object({
        term: z.string().min(1),
        context: z.string().optional(),
        new_term: z.string().optional(),
        new_context: z.string().optional(),
        reference: z.string().optional(),
        comment: z.string().optional(),
        tags: z.array(z.string()).optional(),
        untranslatable: z.boolean().optional()
      })).min(1)
    });
  • src/server.ts:258-283 (registration)
    Registration of the update_terms tool via server.tool() call, specifying name, description, schema, and inline handler function.
    server.tool(
      "update_terms",
      "Update term metadata such as the display text, context, references, or tags. Identify each term by its current term/context values.",
      UpdateTermsInput.shape,
      async (args) => {
        const id = requireProjectId(args.project_id ?? null);
        const payload = args.items.map((item) => {
          const termData: Record<string, any> = {
            term: item.term,
            context: item.context ?? ""
          };
          if (item.new_term) termData.new_term = item.new_term;
          if (item.new_context) termData.new_context = item.new_context;
          if (item.reference) termData.reference = item.reference;
          if (item.comment) termData.comment = item.comment;
          if (item.tags) termData.tags = item.tags;
          if (item.untranslatable !== undefined) {
            termData.untranslatable = item.untranslatable ? 1 : 0;
          }
          return termData;
        });
        const data = JSON.stringify(payload);
        const res = await poeditor("terms/update", { id: String(id), data });
        return { content: [{ type: "text", text: JSON.stringify(res.result ?? {}, null, 2) }] };
      }
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions that the tool updates metadata, implying a mutation operation, but doesn't cover critical aspects like required permissions, whether updates are reversible, error handling for invalid inputs, or rate limits. This leaves significant gaps for an agent to understand the tool's behavior.

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 concise and front-loaded, with two sentences that directly convey the tool's purpose and a key usage note. There's no unnecessary verbosity, and each sentence adds value, though it could be slightly more structured by explicitly separating purpose from guidelines.

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

Completeness2/5

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

Given the complexity (2 parameters with nested objects, 0% schema coverage, no annotations, no output schema), the description is incomplete. It doesn't address the 'project_id' parameter, error conditions, response format, or how updates interact with existing data, making it inadequate for an agent to use the tool effectively without additional context.

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 description adds some value by explaining that terms are identified by 'current term/context values' and lists updatable fields ('display text, context, references, or tags'), which partially clarifies the 'items' parameter. However, with 0% schema description coverage and 2 parameters (including a complex nested array), it doesn't fully compensate for the lack of schema details, such as the purpose of 'project_id' or the specifics of each field in 'items'.

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?

The description clearly states the action ('Update term metadata') and specifies what can be updated ('display text, context, references, or tags'), which goes beyond just restating the name. However, it doesn't explicitly differentiate from sibling tools like 'update_translations' or 'add_terms_with_translations', which prevents a perfect score.

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?

The description provides minimal guidance by stating 'Identify each term by its current term/context values,' which hints at how to use the tool. However, it doesn't explain when to use this tool versus alternatives like 'update_translations' or 'delete_terms,' nor does it mention prerequisites such as requiring a project context or handling multiple items.

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/ryan-shaw/poeditor-mcp'

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