cancel
Cancel a pending Chrome Web Store submission to stop an item currently under review from being published.
Instructions
Cancel a pending submission on Chrome Web Store. Can be used to cancel an item currently in review.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| itemId | No | Extension item ID (defaults to CWS_ITEM_ID env var) | |
| publisherId | No | Publisher ID (defaults to CWS_PUBLISHER_ID env var or 'me') |
Implementation Reference
- src/index.ts:375-404 (handler)The 'cancel' tool implementation handles the API call to cancel a pending submission for a Chrome Web Store extension. It uses 'resolveItemId' and 'resolvePublisherId' to get parameters, calls the ':cancelSubmission' endpoint via 'apiCall', and formats the response.
server.tool( "cancel", "Cancel a pending submission on Chrome Web Store. Can be used to cancel an item currently in review.", { itemId: z .string() .optional() .describe("Extension item ID (defaults to CWS_ITEM_ID env var)"), publisherId: z .string() .optional() .describe("Publisher ID (defaults to CWS_PUBLISHER_ID env var or 'me')"), }, async ({ itemId, publisherId }) => { try { const id = resolveItemId(itemId); const pub = resolvePublisherId(publisherId); const url = `${API_BASE}/v2/publishers/${pub}/items/${id}:cancelSubmission`; const result = await apiCall(url, { method: "POST" }); return formatResponse(result); } catch (e: any) { return { content: [{ type: "text" as const, text: `Error: ${e.message}` }], isError: true, }; } }, );