← ClaudeAtlas

docs-translate-webhooklisted

Bypass Docsbook's built-in AI translator and delegate translation work to a custom external service over webhooks. Switches the workspace to external translation mode, registers a translation.requested webhook, and scaffolds a handler function the user deploys with their own translation logic. Requires PRO+ plan.
Docsbook-io/docs-skills · ★ 0 · AI & Automation · score 75
Install: claude install-skill Docsbook-io/docs-skills
# docs-translate-webhook — Wire an external translation pipeline via webhook ## Workflow 1. **Verify MCP transport** — call `list_workspaces` as a connectivity probe. If it fails, print the MCP connection command and exit gracefully. 2. **Validate plan and inputs** — read the workspace plan via `get_workspace`. If the plan is below PRO+, stop and print an upgrade prompt. Validate that the webhook URL is `https://` (reject `http://` and non-URLs). Confirm the runtime flavor (`vercel` or `express`; default `vercel`). 3. **Switch translation mode** — call `set_translation_mode` with `mode: external`. This stops Docsbook's built-in translator and causes it to emit `translation.requested` events instead. 4. **Register the webhook** — generate a fresh HMAC secret and call `register_webhook_translation_requested` with the provided URL. Capture the `callback_url` from the response for use in the handler. Surface the HMAC secret to the user once. 5. **Scaffold the handler** — produce a handler file for the selected runtime that verifies the HMAC signature, invokes the user's translation logic (as a TODO placeholder), and POSTs results back to the callback URL. 6. **Write the handler file** — place it at the configured output path (default `api/docsbook-translate.ts` for Vercel, `src/routes/docsbook-translate.ts` for Express). Create parent directories if needed. Overwrite if the file already exists. 7. **Report** — print the webhook URL, HMAC secret, handler path, and the next steps