One preview with the log of its latest build
Generated from the OpenAPI contract. Sessions send the CSRF header on writes; API keys use a Bearer token. Authentication
GET
/api/v1/tenants/{tid}/sites/{id}/previews/{pid}One preview with the log of its latest build
Authentication: session cookie __Host-panel_session (contract default; see Authentication).
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
tid | path | string | required | |
id | path | string | required | |
pid | path | string | required |
Responses
200 Preview
Content type: application/json
idstring requiredsite_idstring requiredThe preview's own site
kindstring requiredAllowed values:"branch""pull_request"refstring requirednumberinteger requiredtitlestring requiredhostnamestring requiredurlstring requiredcommitstring requiredstatestring requiredAllowed values:"creating""deploying""ready""failed""deleting"error_codestring requireddatabase_idstring requiredcreated_atstring (date-time) requiredupdated_atstring (date-time) requiredactive_atstring (date-time) requireddeployed_atstring (date-time) | null requiredexpires_atstring (date-time) requireddisk_bytesinteger (int64) required-1 until measured
logarray<object> requiredatstring (date-time) requiredstepstring requiredstatestring requireddetailstring optional
Example
{
"id": "string",
"site_id": "string",
"kind": "branch",
"ref": "string",
"number": 0,
"title": "string",
"hostname": "string",
"url": "string",
"commit": "string",
"state": "creating",
"error_code": "string",
"database_id": "string",
"created_at": "2026-01-01T00:00:00Z",
"updated_at": "2026-01-01T00:00:00Z",
"active_at": "2026-01-01T00:00:00Z",
"deployed_at": "2026-01-01T00:00:00Z",
"expires_at": "2026-01-01T00:00:00Z",
"disk_bytes": 0,
"log": [
{
"at": "2026-01-01T00:00:00Z",
"step": "string",
"state": "string",
"detail": "string"
}
]
}default Error
Content type: application/json
codestring requiredmessagestring requireddetails_redactedboolean requiredcorrelation_idstring requiredretryableboolean required