Skip to main content
Glama

Check a product operation

get_product_operation
Idempotent

Read per-frame product operation status and refresh private result URLs. Also advances the next unstarted step of an approved series once. Keep polling until terminal; never change request_id to retry unknown outcomes. Requires the same OAuth connection.

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": {
      "request_id": "<request_id>"
    },
    "name": "get_product_operation"
  }
}

Input Schema

NameRequiredDescriptionDefault
request_idYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "analysis": {
      -        "anyOf": [
      -          {
      -            "type": "null"
      -          },
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "analysis": {
      -                "additionalProperties": false,
      -                "properties": {
      -                  "attributes": {
      -                    "items": {
      -                      "additionalProperties": false,
      -                      "properties": {
      -                        "label": {
      -                          "maxLength": 36,
      -                          "type": "string"
      -                        },
      -                        "value": {
      -                          "maxLength": 100,
      -                          "type": "string"
      -                        }
      -                      },
      -                      "required": [
      -                        "label",
      -                        "value"
      -                      ],
      -                      "type": "object"
      -                    },
      -                    "maxItems": 6,
      -                    "type": "array"
      -                  },
      -                  "category": {
      -                    "enum": [
      -                      "fashion",
      -                      "home",
      -                      "beauty",
      -                      "kids",
      -                      "electronics",
      -                      "sport",
      -                      "pets",
      -                      "hobby",
      -                      "food",
      -                      "auto",
      -                      "garden",
      -                      "construction",
      -                      "stationery",
      -                      "other"
      -                    ]
      -                  },
      -                  "product_name": {
      -                    "maxLength": 80,
      -                    "type": "string"
      -                  },
      -                  "product_type": {
      -                    "maxLength": 80,
      -                    "type": "string"
      -                  },
      -                  "suggested_card_styles": {
      -                    "items": {
      -                      "type": "string"
      -                    },
      -                    "maxItems": 4,
      -                    "type": "array"
      -                  },
      -                  "suggested_photoshoot_styles": {
      -                    "items": {
      -                      "type": "string"
      -                    },
      -                    "maxItems": 4,
      -                    "type": "array"
      -                  }
      -                },
      -                "required": [
      -                  "category",
      -                  "product_name",
      -                  "product_type",
      -                  "attributes",
      -                  "suggested_card_styles",
      -                  "suggested_photoshoot_styles"
      -                ],
      -                "type": "object"
      -              },
      -              "error": {
      -                "type": "string"
      -              },
      -              "status": {
      -                "enum": [
      -                  "pending",
      -                  "running",
      -                  "complete",
      -                  "failed",
      -                  "unknown",
      -                  "skipped"
      -                ]
      -              },
      -              "step_id": {
      -                "format": "uuid",
      -                "type": "string"
      -              }
      -            },
      -            "required": [
      -              "step_id",
      -              "status"
      -            ],
      -            "type": "object"
      -          }
      -        ]
      -      },
      -      "approval_url": {
      -        "type": "string"
      -      },
      -      "confirmation_reason": {
      -        "type": "string"
      -      },
      -      "credits_charged": {
      -        "minimum": 0,
      -        "type": "integer"
      -      },
      -      "description": {
      -        "anyOf": [
      -          {
      -            "type": "null"
      -          },
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "description": {
      -                "additionalProperties": false,
      -                "properties": {
      -                  "bullets": {
      -                    "items": {
      -                      "maxLength": 220,
      -                      "type": "string"
      -                    },
      -                    "maxItems": 8,
      -                    "type": "array"
      -                  },
      -                  "summary": {
      -                    "maxLength": 4008,
      -                    "type": "string"
      -                  },
      -                  "title": {
      -                    "maxLength": 140,
      -                    "type": "string"
      -                  }
      -                },
      -                "required": [
      -                  "title",
      -                  "summary",
      -                  "bullets"
      -                ],
      -                "type": "object"
      -              },
      -              "error": {
      -                "type": "string"
      -              },
      -              "status": {
      -                "enum": [
      -                  "pending",
      -                  "running",
      -                  "complete",
      -                  "failed",
      -                  "unknown",
      -                  "skipped"
      -                ]
      -              },
      -              "step_id": {
      -                "format": "uuid",
      -                "type": "string"
      -              }
      -            },
      -            "required": [
      -              "step_id",
      -              "status"
      -            ],
      -            "type": "object"
      -          }
      -        ]
      -      },
      -      "frames": {
      -        "items": {
      -          "additionalProperties": false,
      -          "properties": {
      -            "credits_charged": {
      -              "minimum": 0,
      -              "type": "integer"
      -            },
      -            "credits_refunded": {
      -              "minimum": 0,
      -              "type": "integer"
      -            },
      -            "error": {
      -              "type": "string"
      -            },
      -            "id": {
      -              "format": "uuid",
      -              "type": "string"
      -            },
      -            "image": {
      -              "type": "string"
      -            },
      -            "mime_type": {
      -              "enum": [
      -                "image/png",
      -                "image/jpeg",
      -                "image/webp"
      -              ]
      -            },
      -            "scene": {
      -              "enum": [
      -                "hero",
      -                "benefits",
      -                "lifestyle",
      -                "detail"
      -              ]
      -            },
      -            "status": {
      -              "enum": [
      -                "pending",
      -                "running",
      -                "complete",
      -                "failed",
      -                "unknown",
      -                "skipped"
      -              ]
      -            },
      -            "step_id": {
      -              "format": "uuid",
      -              "type": "string"
      -            },
      -            "url_expires_in_seconds": {
      -              "const": 3600
      -            }
      -          },
      -          "required": [
      -            "step_id",
      -            "status",
      -            "scene",
      -            "credits_charged",
      -            "credits_refunded"
      -          ],
      -          "type": "object"
      -        },
      -        "maxItems": 4,
      -        "type": "array"
      -      },
      -      "message": {
      -        "type": "string"
      -      },
      -      "next": {
      -        "const": "get_product_operation"
      -      },
      -      "poll_after_seconds": {
      -        "const": 5
      -      },
      -      "progress": {
      -        "additionalProperties": false,
      -        "properties": {
      -          "completed_frames": {
      -            "minimum": 0,
      -            "type": "integer"
      -          },
      -          "finished_steps": {
      -            "minimum": 0,
      -            "type": "integer"
      -          },
      -          "total_frames": {
      -            "minimum": 0,
      -            "type": "integer"
      -          },
      -          "total_steps": {
      -            "minimum": 0,
      -            "type": "integer"
      -          }
      -        },
      -        "required": [
      -          "completed_frames",
      -          "total_frames",
      -          "finished_steps",
      -          "total_steps"
      -        ],
      -        "type": "object"
      -      },
      -      "quote": {
      -        "anyOf": [
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "analysis_credits": {
      -                "const": 0
      -              },
      -              "aspect_ratio": {
      -                "enum": [
      -                  "1:1",
      -                  "16:9",
      -                  "9:16",
      -                  "4:3",
      -                  "3:4"
      -                ]
      -              },
      -              "count": {
      -                "enum": [
      -                  1,
      -                  4
      -                ]
      -              },
      -              "currency": {
      -                "const": "ai_credits"
      -              },
      -              "description_credits": {
      -                "enum": [
      -                  0,
      -                  1
      -                ]
      -              },
      -              "free_photo_used": {
      -                "const": false
      -              },
      -              "maximum": {
      -                "minimum": 0,
      -                "type": "integer"
      -              },
      -              "model": {
      -                "enum": [
      -                  "nano",
      -                  "nano2",
      -                  "nano-pro",
      -                  "gemini",
      -                  "seedream"
      -                ]
      -              },
      -              "per_image": {
      -                "minimum": 0,
      -                "type": "integer"
      -              },
      -              "quality": {
      -                "enum": [
      -                  "standard",
      -                  "high"
      -                ]
      -              }
      -            },
      -            "required": [
      -              "currency",
      -              "per_image",
      -              "maximum",
      -              "count",
      -              "model",
      -              "quality",
      -              "aspect_ratio",
      -              "description_credits",
      -              "analysis_credits",
      -              "free_photo_used"
      -            ],
      -            "type": "object"
      -          },
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "analysis_credits": {
      -                "const": 0
      -              },
      -              "currency": {
      -                "const": "ai_credits"
      -              },
      -              "description_credits": {
      -                "const": 1
      -              },
      -              "kind": {
      -                "const": "description"
      -              },
      -              "maximum": {
      -                "const": 1
      -              }
      -            },
      -            "required": [
      -              "kind",
      -              "currency",
      -              "maximum",
      -              "description_credits",
      -              "analysis_credits"
      -            ],
      -            "type": "object"
      -          }
      -        ]
      -      },
      -      "request_id": {
      -        "format": "uuid",
      -        "type": "string"
      -      },
      -      "status": {
      -        "enum": [
      -          "awaiting_confirmation",
      -          "approved",
      -          "denied",
      -          "running",
      -          "complete",
      -          "partial",
      -          "failed",
      -          "unknown"
      -        ]
      -      }
      -    },
      -    "required": [
      -      "request_id",
      -      "status",
      -      "progress",
      -      "frames",
      -      "description",
      -      "analysis",
      -      "credits_charged",
      -      "next",
      -      "poll_after_seconds"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "error": {
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "error"
      -    ],
      -    "type": "object"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "analysis": {
      +        "anyOf": [
      +          {
      +            "type": "null"
      +          },
      +          {
      +            "additionalProperties": false,
      +            "properties": {
      +              "analysis": {
      +                "additionalProperties": false,
      +                "properties": {
      +                  "attributes": {
      +                    "items": {
      +                      "additionalProperties": false,
      +                      "properties": {
      +                        "label": {
      +                          "maxLength": 36,
      +                          "type": "string"
      +                        },
      +                        "value": {
      +                          "maxLength": 100,
      +                          "type": "string"
      +                        }
      +                      },
      +                      "required": [
      +                        "label",
      +                        "value"
      +                      ],
      +                      "type": "object"
      +                    },
      +                    "maxItems": 6,
      +                    "type": "array"
      +                  },
      +                  "category": {
      +                    "enum": [
      +                      "fashion",
      +                      "home",
      +                      "beauty",
      +                      "kids",
      +                      "electronics",
      +                      "sport",
      +                      "pets",
      +                      "hobby",
      +                      "food",
      +                      "auto",
      +                      "garden",
      +                      "construction",
      +                      "stationery",
      +                      "other"
      +                    ]
      +                  },
      +                  "product_name": {
      +                    "maxLength": 80,
      +                    "type": "string"
      +                  },
      +                  "product_type": {
      +                    "maxLength": 80,
      +                    "type": "string"
      +                  },
      +                  "suggested_card_styles": {
      +                    "items": {
      +                      "type": "string"
      +                    },
      +                    "maxItems": 4,
      +                    "type": "array"
      +                  },
      +                  "suggested_photoshoot_styles": {
      +                    "items": {
      +                      "type": "string"
      +                    },
      +                    "maxItems": 4,
      +                    "type": "array"
      +                  }
      +                },
      +                "required": [
      +                  "category",
      +                  "product_name",
      +                  "product_type",
      +                  "attributes",
      +                  "suggested_card_styles",
      +                  "suggested_photoshoot_styles"
      +                ],
      +                "type": "object"
      +              },
      +              "error": {
      +                "type": "string"
      +              },
      +              "status": {
      +                "enum": [
      +                  "pending",
      +                  "running",
      +                  "complete",
      +                  "failed",
      +                  "unknown",
      +                  "skipped"
      +                ]
      +              },
      +              "step_id": {
      +                "format": "uuid",
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "step_id",
      +              "status"
      +            ],
      +            "type": "object"
      +          }
      +        ]
      +      },
      +      "approval_url": {
      +        "type": "string"
      +      },
      +      "confirmation_reason": {
      +        "type": "string"
      +      },
      +      "credits_charged": {
      +        "minimum": 0,
      +        "type": "integer"
      +      },
      +      "description": {
      +        "anyOf": [
      +          {
      +            "type": "null"
      +          },
      +          {
      +            "additionalProperties": false,
      +            "properties": {
      +              "description": {
      +                "additionalProperties": false,
      +                "properties": {
      +                  "bullets": {
      +                    "items": {
      +                      "maxLength": 220,
      +                      "type": "string"
      +                    },
      +                    "maxItems": 8,
      +                    "type": "array"
      +                  },
      +                  "summary": {
      +                    "maxLength": 4008,
      +                    "type": "string"
      +                  },
      +                  "title": {
      +                    "maxLength": 140,
      +                    "type": "string"
      +                  }
      +                },
      +                "required": [
      +                  "title",
      +                  "summary",
      +                  "bullets"
      +                ],
      +                "type": "object"
      +              },
      +              "error": {
      +                "type": "string"
      +              },
      +              "status": {
      +                "enum": [
      +                  "pending",
      +                  "running",
      +                  "complete",
      +                  "failed",
      +                  "unknown",
      +                  "skipped"
      +                ]
      +              },
      +              "step_id": {
      +                "format": "uuid",
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "step_id",
      +              "status"
      +            ],
      +            "type": "object"
      +          }
      +        ]
      +      },
      +      "frames": {
      +        "items": {
      +          "additionalProperties": false,
      +          "properties": {
      +            "credits_charged": {
      +              "minimum": 0,
      +              "type": "integer"
      +            },
      +            "credits_refunded": {
      +              "minimum": 0,
      +              "type": "integer"
      +            },
      +            "error": {
      +              "type": "string"
      +            },
      +            "id": {
      +              "format": "uuid",
      +              "type": "string"
      +            },
      +            "image": {
      +              "type": "string"
      +            },
      +            "mime_type": {
      +              "enum": [
      +                "image/png",
      +                "image/jpeg",
      +                "image/webp"
      +              ]
      +            },
      +            "scene": {
      +              "enum": [
      +                "hero",
      +                "benefits",
      +                "lifestyle",
      +                "detail"
      +              ]
      +            },
      +            "status": {
      +              "enum": [
      +                "pending",
      +                "running",
      +                "complete",
      +                "failed",
      +                "unknown",
      +                "skipped"
      +              ]
      +            },
      +            "step_id": {
      +              "format": "uuid",
      +              "type": "string"
      +            },
      +            "url_expires_in_seconds": {
      +              "const": 3600
      +            }
      +          },
      +          "required": [
      +            "step_id",
      +            "status",
      +            "scene",
      +            "credits_charged",
      +            "credits_refunded"
      +          ],
      +          "type": "object"
      +        },
      +        "maxItems": 4,
      +        "type": "array"
      +      },
      +      "message": {
      +        "type": "string"
      +      },
      +      "next": {
      +        "const": "get_product_operation"
      +      },
      +      "poll_after_seconds": {
      +        "const": 5
      +      },
      +      "progress": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "completed_frames": {
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          "finished_steps": {
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          "total_frames": {
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          "total_steps": {
      +            "minimum": 0,
      +            "type": "integer"
      +          }
      +        },
      +        "required": [
      +          "completed_frames",
      +          "total_frames",
      +          "finished_steps",
      +          "total_steps"
      +        ],
      +        "type": "object"
      +      },
      +      "quote": {
      +        "anyOf": [
      +          {
      +            "additionalProperties": false,
      +            "properties": {
      +              "analysis_credits": {
      +                "const": 0
      +              },
      +              "aspect_ratio": {
      +                "enum": [
      +                  "1:1",
      +                  "16:9",
      +                  "9:16",
      +                  "4:3",
      +                  "3:4"
      +                ]
      +              },
      +              "count": {
      +                "enum": [
      +                  1,
      +                  4
      +                ]
      +              },
      +              "currency": {
      +                "const": "ai_credits"
      +              },
      +              "description_credits": {
      +                "enum": [
      +                  0,
      +                  1
      +                ]
      +              },
      +              "free_photo_used": {
      +                "const": false
      +              },
      +              "maximum": {
      +                "minimum": 0,
      +                "type": "integer"
      +              },
      +              "model": {
      +                "enum": [
      +                  "nano",
      +                  "nano2",
      +                  "nano-pro",
      +                  "gemini",
      +                  "seedream",
      +                  "lite"
      +                ]
      +              },
      +              "per_image": {
      +                "minimum": 0,
      +                "type": "integer"
      +              },
      +              "quality": {
      +                "enum": [
      +                  "standard",
      +                  "high"
      +                ]
      +              }
      +            },
      +            "required": [
      +              "currency",
      +              "per_image",
      +              "maximum",
      +              "count",
      +              "model",
      +              "quality",
      +              "aspect_ratio",
      +              "description_credits",
      +              "analysis_credits",
      +              "free_photo_used"
      +            ],
      +            "type": "object"
      +          },
      +          {
      +            "additionalProperties": false,
      +            "properties": {
      +              "analysis_credits": {
      +                "const": 0
      +              },
      +              "currency": {
      +                "const": "ai_credits"
      +              },
      +              "description_credits": {
      +                "const": 1
      +              },
      +              "kind": {
      +                "const": "description"
      +              },
      +              "maximum": {
      +                "const": 1
      +              }
      +            },
      +            "required": [
      +              "kind",
      +              "currency",
      +              "maximum",
      +              "description_credits",
      +              "analysis_credits"
      +            ],
      +            "type": "object"
      +          }
      +        ]
      +      },
      +      "request_id": {
      +        "format": "uuid",
      +        "type": "string"
      +      },
      +      "status": {
      +        "enum": [
      +          "awaiting_confirmation",
      +          "approved",
      +          "denied",
      +          "running",
      +          "complete",
      +          "partial",
      +          "failed",
      +          "unknown"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "request_id",
      +      "status",
      +      "progress",
      +      "frames",
      +      "description",
      +      "analysis",
      +      "credits_charged",
      +      "next",
      +      "poll_after_seconds"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "error": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "error"
      +    ],
      +    "type": "object"
      +  }
      +]
  2. First observed

TDQS

A3.6/5.0
Behavior3/5

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

The description earns real credit by disclosing a side effect the annotations only imply: it 'advances the next unstarted step of an approved series once,' which explains why readOnlyHint is false. It also documents the auth requirement and the stable-request_id retry contract. It adds no return-shape or terminal-status detail, and the annotations cover most remaining 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?

Three compact sentences with the primary function front-loaded and constraints following. Dense and telegraphic in places, but no sentence is filler.

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?

Given an output schema exists, the description is not obligated to explain return values, and it covers polling, side effects, and auth. Only the request_id origin and the product-vs-generic distinction are left implicit.

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 coverage is 0% for the one parameter, so the description must carry the burden. It does add the key semantic that request_id must stay fixed across retries, but says nothing about where to obtain it or how it relates to the product resource. That is partial compensation, not full.

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 names a specific resource and scope: per-frame product operation status, private result URL refresh, and a one-step advance of an approved series. That is far more specific than the name alone. It does not, however, distinguish this from the sibling get_operation, so an agent must infer the product-vs-generic split from the name.

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?

Strong operational guidance: keep polling until terminal, never change request_id to retry unknown outcomes, and requires the same OAuth connection. That covers when and how to call. It never names an alternative tool or states when not to use this one, which keeps it below a 5.

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.