Skip to main content
Glama

Get a restoration

pinin_get_restoration
Read-only

Retrieve a photo restoration by ID to check status, credits charged, failure details, file expiry, and completed image URLs or share link. Wait the returned retry_after before checking.

Instructions

Read one restoration by id: status (pending, processing, completed, failed), mode, credits charged, the failure detail when it failed, when the files expire, and signed image URLs plus a share link once it completes. Call it after pinin_restore_photo, waiting at least the retry_after seconds the response carries; to follow several jobs, sweep pinin_list_restorations with updated_since instead of polling each id. Read-only and free. An unchanged pending job may answer from its weak ETag without a body.

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": {
      "id": "<id>"
    },
    "name": "pinin_get_restoration"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesRestoration id returned by pinin_restore_photo — the `id` field of the restoration document.

Output Schema

NameRequiredDescriptionDefault
idNoRestoration id.
modeNoRestoration mode the job was queued with.
seedNoDeterministic seed in force, or null.
errorNo`{ code, message }` when the job failed, otherwise null.
imagesNo`{ original: { url, expires_in }, restored: { url, expires_in } }` once complete; null before that.
objectNoAlways `restoration`.
statusNo`pending`, `processing`, `completed` or `failed`.
creditsNoCredits charged by this job.
metadataNoMetadata supplied at creation.
share_urlNoPublic share link for the restored photo, or null.
created_atNoISO 8601 creation instant.
expires_atNoISO 8601 instant when files are deleted — download before this.
updated_atNoISO 8601 instant of the last state change.
completed_atNoISO 8601 completion instant, or null while running.
order_numberNoHuman-readable order reference.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.1

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnlyHint and destructiveHint=false, but the description adds behavior those annotations cannot express: the job is free (no credits), URLs and share link only materialize once completed, files expire, and an unchanged pending job may return from a weak ETag with no body. The ETag/conditional-request note is the kind of detail that prevents an agent from misreading an empty response as an error.

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?

Front-loaded with purpose, then sequencing, then the alternative strategy, then a caching caveat — a sensible order with no filler. The one inefficiency is the long enumeration of returned fields, which partially duplicates the existing output schema.

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 single-id read tool with full schema coverage, an output schema, and read-only annotations, the description covers everything an agent needs: prerequisite call, wait interval, alternative for bulk tracking, and response-emptiness semantics. No meaningful gap remains.

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?

One parameter at 100% schema description coverage, and the schema already explains that `id` is the field returned by pinin_restore_photo. The description's "by id" framing adds no syntax or format detail beyond that, so the schema does the heavy lifting and baseline 3 applies.

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?

Opens with a specific verb and resource ("Read one restoration by id") and immediately enumerates what the document contains: status enum, mode, credits, failure detail, expiry, signed URLs and share link. An agent can distinguish this single-job read from pinin_list_restorations without opening either schema.

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?

Explicit sequencing guidance ("Call it after pinin_restore_photo") plus a concrete wait rule tied to the `retry_after` field, and an explicit alternative with its own trigger: sweep pinin_list_restorations with `updated_since` when following several jobs instead of polling each id. Both when-to-use and when-not-to-use are stated.

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