Publish Studio Preview
POST
/v1/admin/studio/runs/{run_id}/preview
const url = 'https://example.com/v1/admin/studio/runs/example/preview?tenant_id=';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"project_slug":"","url":"","domain_url":"","port":0,"sandbox_id":"","signed":false,"status":"live","published_by_agent":"","note":""}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url 'https://example.com/v1/admin/studio/runs/example/preview?tenant_id=' \ --header 'Content-Type: application/json' \ --data '{ "project_slug": "", "url": "", "domain_url": "", "port": 0, "sandbox_id": "", "signed": false, "status": "live", "published_by_agent": "", "note": "" }'Publish (upsert) the run’s shared LIVE preview so every agent reads the same URL.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”run_id
required
Run Id
string
Query Parameters
Section titled “Query Parameters”tenant_id
Tenant Id
string
Header Parameters
Section titled “Header Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
StudioPreviewShareIn
object
project_slug
Project Slug
string
url
Url
string
domain_url
Domain Url
string
port
Port
integer
sandbox_id
Sandbox Id
string
signed
Signed
boolean
status
Status
string
published_by_agent
Published By Agent
string
note
Note
string
Responses
Section titled “Responses”Successful Response
Media typeapplication/json
StudioPreviewShareOut
object
run_id
required
Run Id
string
project_slug
Project Slug
string
url
Url
string
domain_url
Domain Url
string
port
Port
integer
sandbox_id
Sandbox Id
string
signed
Signed
boolean
status
Status
string
published_by_agent
Published By Agent
string
note
Note
string
updated_at
Updated At
string
Example
{ "project_slug": "", "url": "", "domain_url": "", "port": 0, "sandbox_id": "", "signed": false, "status": "live", "published_by_agent": "", "note": "", "updated_at": ""}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}