HTML body

Read an HTML surface body

Returns the resolved html surface's body (html, css, js). Empty fields when the surface exists but no body has been written yet. 404 when ?surface_slug= doesn't match a live html surface.

get/api/workspaces/{slug}/html

Request

  • Base URL
    https://trydock.ai
  • Auth
    HTTP bearer

Path parameters

slugstring required

Query parameters

surface_slugstring

Surface slug for multi-html workspaces. Omit for the primary html surface (lowest position).

surfacestring

Legacy alias for surface_slug. Same semantics. Prefer surface_slug in new code.

Response

Resolved html body.

htmlstring required

Sanitized HTML body. Empty string when the surface exists but no body has been written yet.

cssstring required

CSS source. Applied inside the sandboxed iframe.

jsstring required

JS source. Stored but NOT executed at v1 — the sandbox iframe is scripts-off. Interactive mode lands in a later PR.

updatedAtstring date-time nullable required
updatedBystring nullable required
updatedByPrincipalTypestring nullable required
surfaceSlugstring nullable required

Slug of the resolved html surface. Null when the workspace has no html surface yet.

Changes

No recorded changes to this operation across all 2 revisions of this API.