# site.withzero.ai Webpage Publisher

> site.withzero.ai Webpage Publisher is a paid API for AI agents from site.withzero.ai, paid per call via MPP, $0.005/call, status healthy (last checked 2026-10-01, last successful call 2026-10-01).

Publishes HTML or Markdown content as a live, hosted webpage and returns a public URL valid for 365 days

## Facts

- Endpoint: POST https://site.withzero.ai/run?utm_source=zero.xyz
- Price: $0.005/call
- Payment: MPP
- Status: healthy
- Last checked: 2026-10-01
- Last successful call: 2026-10-01
- Success rate: 100% of calls made through Zero
- Rating: 5.0 / 5 from 2 reviews
- Activations on Zero: 25
- Provider: site.withzero.ai
- Website: https://site.withzero.ai
- Canonical page: https://www.zero.xyz/c/site-withzero-ai-webpage-publisher-5105819c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ts-wLYj_kt6E3xTW5MXt6

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability site-withzero-ai-webpage-publisher-5105819c -d '<json body>'
```

Example prompt: Can you publish this Markdown content as a live webpage with the slug 'project-recap' and the title 'Q3 Project Recap'? Here's the content: '# Q3 Project Recap\n\nThis quarter we shipped three major features...'

## When to prefer this

Choose this endpoint when you need to instantly publish HTML or Markdown as a publicly accessible webpage with a stable URL that lasts up to a year, without needing your own server or CDN. Ideal when you want to share agent-generated content, reports, or landing pages via a link. Prefer it over file storage endpoints when the output must be human-readable in a browser, and over full CMS platforms when you need a lightweight, zero-setup publish with a custom slug and optional CSS styling.

## Known failure modes

- Missing or empty content field returns a validation error
- Slug conflicts with a taken slug — the existing site is overwritten silently
- Slug pattern violation (uppercase, special characters) returns a 400 error
- Content exceeding 1MB (1,048,576 bytes) is rejected
- Invalid format enum value (not 'html' or 'markdown') returns a validation error
- Custom CSS exceeding 50,000 characters is rejected

## How this service works

Generate and host a webpage from HTML or Markdown content. Returns a live URL valid for 365 days. After publishing, the returned slug is reachable via free routes: `GET /s/:slug` (canonical render, increments visit counter), `HEAD /s/:slug` (head-only, no body), `GET /site/:slug` (legacy alias), `GET /stats/:slug` (JSON metadata + visit count).

## Output

Returns a JSON object containing the live URL where the page is accessible, the slug identifier, the page title, the content format used, creation and expiration ISO 8601 timestamps, TTL in days (always 365), content size in bytes, and an operational note describing how to refresh the page.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "content"
 ],
 "properties": {
  "css": {
   "type": "string",
   "maxLength": 50000,
   "description": "Custom CSS to inject into the page. Applied after the default styles, so you can override any default styling. Example: \"body { background: #000; color: #fff; }\""
  },
  "slug": {
   "type": "string",
   "pattern": "^[a-z0-9][a-z0-9_-]*[a-z0-9]$|^[a-z0-9]$",
   "maxLength": 64,
   "minLength": 1,
   "description": "Custom URL slug. Must be lowercase alphanumeric with hyphens/underscores. If not provided, a random 8-character slug is generated. If the slug already exists, the existing site is overwritten."
  },
  "title": {
   "type": "string",
   "maxLength": 200,
   "description": "Page title (shown in browser tab). Defaults to \"Untitled\" if not provided."
  },
  "format": {
   "enum": [
    "html",
    "markdown"
   ],
   "type": "string",
   "default": "html",
   "description": "Content format. \"html\" (default): raw HTML content. \"markdown\": Markdown text that gets converted to HTML with a clean, responsive default template."
  },
  "content": {
   "type": "string",
   "maxLength": 1048576,
   "minLength": 1,
   "description": "The website content. Either raw HTML or Markdown text. For HTML: can be a full document (with <html>) or a fragment (just the body content). For Markdown: standard Markdown syntax (headings, bold, links, code blocks, etc.)."
  },
  "wrapInTemplate": {
   "type": "boolean",
   "default": true,
   "description": "Whether to wrap the content in the default HTML template with responsive styles. Set to false if your HTML content is already a complete document. For markdown, this is always true."
  }
 },
 "additionalProperties": false
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "url",
  "slug",
  "title",
  "format",
  "createdAt",
  "expiresAt",
  "ttlDays",
  "ttl",
  "contentLength",
  "note"
 ],
 "properties": {
  "ttl": {
   "type": "string",
   "description": "Human-readable TTL summary. Always \"365 days\" for this service."
  },
  "url": {
   "type": "string",
   "description": "Live URL where the website is accessible"
  },
  "note": {
   "type": "string",
   "description": "Operational summary. Includes the TTL applied, expiration timestamp, and how to refresh."
  },
  "slug": {
   "type": "string",
   "description": "URL slug for the site"
  },
  "title": {
   "type": "string",
   "description": "Page title"
  },
  "format": {
   "enum": [
    "html",
    "markdown"
   ],
   "type": "string",
   "description": "Content format that was used"
  },
  "ttlDays": {
   "type": "number",
   "description": "TTL (days) applied to this publish. Fixed at 365 — there is no `ttlHours`/`ttlDays` input. POST /run with the same slug to re-publish and refresh the 365-day window."
  },
  "createdAt": {
   "type": "string",
   "description": "ISO 8601 creation timestamp"
  },
  "expiresAt": {
   "type": "string",
   "description": "ISO 8601 expiration timestamp (365 days from creation)"
  },
  "contentLength": {
   "type": "number",
   "description": "Size of the stored HTML in bytes"
  }
 },
 "additionalProperties": false
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/site-withzero-ai-webpage-publisher-5105819c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from site.withzero.ai](https://www.zero.xyz/host/site.withzero.ai/llms.txt)
