Publish a site
publish_sitePublish a website from files or a local directory to a live URL instantly. Anonymous sites last 24 hours; claim them to keep forever for free.
Instructions
Publish a website to shiply.now and get back a live URL — in one call, no account needed to start. Pass files (inline) or a local dir. Anonymous sites go live instantly and last 24 hours; the response includes a claimUrl to keep the site forever on a free account. NEVER create a new site to update an existing one — re-publish to the SAME site by passing its claimToken (anonymous) or slug (owned, requires an API key).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| files | No | Inline files to publish. Provide this OR `dir`. | |
| dir | No | Path to a local directory to publish (read recursively). Provide this OR `files`. | |
| slug | No | Update an existing OWNED site in place (requires an API key). | |
| claimToken | No | Update an existing ANONYMOUS site in place (from a prior publish response). | |
| ttlSeconds | No | Anonymous-site lifetime in seconds (capped server-side, default 24h). | |
| spaMode | No | Serve index.html for deep links (single-page apps). | |
| apiKey | No | shiply API key (shp_…) for owned publishes. Falls back to SHIPLY_API_KEY. |