{"uid":"cap_bPqRnJfOgMUt8rkQcWThc","slug":"site-withzero-ai-update-hosted-site-content-by-slug-d4cbd0c7","name":"Update Hosted Site Content by Slug","description":"Replace the content of an existing slug. Owner-only. Re-runs the markdown → HTML / template-wrapping pipeline. Updates the visit counter's expiration. Title and format may be optionally updated; omitted fields preserve the existing value.","url":"https://site.withzero.ai/sites/:slug?utm_source=zero.xyz","method":"PUT","headers":{},"bodySchema":{"type":"object","required":["content"],"properties":{"css":{"type":"string","maxLength":50000},"title":{"type":"string","maxLength":200,"minLength":1},"format":{"enum":["html","markdown"],"type":"string"},"content":{"type":"string","maxLength":1048576,"minLength":1},"wrapInTemplate":{"type":"boolean"}},"additionalProperties":false},"responseSchema":{"type":"object"},"example":null,"exampleRequest":null,"tags":[],"displayCostAmount":"0","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"proven_free","priceSource":"registry","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"metered","summary":"metered — billed by usage","primary":{"kind":"metered","protocol":"mpp","network":"tempo","amountUsd":null,"per":"call","confidence":"unknown"},"accepted":[{"kind":"metered","protocol":"mpp","network":"tempo","amountUsd":null,"per":"call","confidence":"unknown"}]},"paymentMethods":[{"uid":"pm_qU-04Fo1xQeWecpjHBa4D","protocol":"mpp","methodType":"crypto","chain":"tempo","mode":"charge","costAmount":"0","costPer":"request","priority":0,"asset":"0x20C000000000000000000000b9537d11c60E8b50","unit":"request","depositMicros":null,"planRef":"make-website-put-sites-slug:1"}],"brandName":"site.withzero.ai","brandSlug":"site-withzero-ai-mpp","brandBaseUrl":"https://site.withzero.ai","brandDocsUrl":null,"whatItDoes":"Replaces the HTML or Markdown content of an existing hosted site slug, re-running the rendering pipeline and optionally updating the title, format, or CSS.","exampleAgentPrompt":"Update my hosted site at slug 'my-portfolio-2024' with this new markdown content: '# Updated Portfolio\\nHere are my latest projects...' and change the title to 'My Portfolio 2024 — Updated'.","exampleUseCases":[{"title":"Revise a live landing page","prompt":"Update my published site at slug 'product-launch' with this new HTML: '<h1>We just launched!</h1><p>Sign up now for early access.</p>' — keep the title the same but make sure it's wrapped in the site template."},{"title":"Push edited blog post content","prompt":"I've revised my blog post — please replace the content at slug 'weekly-update-june' with this new markdown: '# June Update\\nThis week we shipped three new features...' and update the title to 'June Weekly Update — Revised'."},{"title":"Apply new CSS styles to existing site","prompt":"Keep the content of my site at slug 'portfolio-v2' the same but update the CSS to: 'body { font-family: sans-serif; background: #f9f9f9; }' and re-render it."}],"resultDescription":"Returns an object confirming the update was applied to the slug, including the refreshed site metadata. The Markdown-to-HTML pipeline is re-run, the template wrapper is re-applied if applicable, and the visit counter expiration is reset.","failureModes":["Slug not found — returns 404 if the specified slug does not exist","Unauthorized — returns 403 if the caller is not the owner of the slug","Content too large — returns 400 if content exceeds 1MB limit","Invalid format value — returns 400 if format is not 'html' or 'markdown'","CSS too large — returns 400 if CSS exceeds 50,000 character limit","Missing required content field — returns 400 if content is omitted"],"whenToPreferThis":"Use this endpoint when you need to update the content of an already-published site without changing its URL slug. Prefer this over deleting and recreating a site when you want to preserve the existing slug, URL, visit counter history, or custom domain mappings. Ideal for iterative content updates, editorial revisions, or programmatic content refreshes on a live page.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-01T21:36:58.009Z","isFirstParty":true,"canonicalSlug":"site-withzero-ai-update-hosted-site-content-by-slug-d4cbd0c7"}