client.apps
Apps API resource. CRUD / deploy / domain / version-file ops are generated; only the preview-session lifecycle stays hand-written.
Accessed via client.apps.
Methods
create
Create a new app.
create(params: CreateAppParams): Promise<App>Types: CreateAppParams · App
createVersionFile
Create a file in a specific app version.
createVersionFile(params: CreateAppVersionFileParams): Promise<SuccessResponse>Types: CreateAppVersionFileParams · SuccessResponse
delete
Soft-delete an app.
delete(params: DeleteAppParams): Promise<SuccessResponse>Types: DeleteAppParams · SuccessResponse
deleteVersionFile
Delete a file from a specific app version.
deleteVersionFile(params: DeleteAppVersionFileParams): Promise<SuccessResponse>Types: DeleteAppVersionFileParams · SuccessResponse
deploy
Deploy the app's default version (legacy shortcut).
deploy(params: DeployAppParams): Promise<Deploy>Types: DeployAppParams · Deploy
getDomain
Get the custom domain attached to an app, or null.
getDomain(params: GetAppDomainParams): Promise<AppDomain | null>Types: GetAppDomainParams · AppDomain
getPreview
Get the current state of a preview session.
getPreview(params: { sessionId: string }): Promise<unknown>keepalivePreview
Heartbeat a preview session. Call every ~30s while the preview is visible.
keepalivePreview(params: { sessionId: string; }): Promise<{ id: string; status: string }>list
List apps with pagination and optional filtering.
list(params?: Omit<ListAppsParams, "filter" | "orderBy"> & { filter?: AppFilter; orderBy?: AppOrderBy[]; } & AppShorthands): Promise<Page<App>>Types: ListAppsParams · AppFilter · AppOrderBy · AppShorthands · Page · App
listVersionFiles
List files in a specific app version.
listVersionFiles(params: ListAppVersionFilesParams): Promise<AppFileListResponse>Types: ListAppVersionFilesParams · AppFileListResponse
purge
Permanently delete a soft-deleted app.
purge(params: PurgeAppParams): Promise<SuccessResponse>Types: PurgeAppParams · SuccessResponse
readVersionFile
Read a file's content from a specific app version.
readVersionFile(params: ReadAppVersionFileParams): Promise<AppFileContentResponse>Types: ReadAppVersionFileParams · AppFileContentResponse
removeDomain
Detach the app's custom domain.
removeDomain(params: RemoveAppDomainParams): Promise<SuccessResponse>Types: RemoveAppDomainParams · SuccessResponse
restore
Restore a soft-deleted app.
restore(params: RestoreAppParams): Promise<App>Types: RestoreAppParams · App
retrieve
Get a single app by ID.
retrieve(params: RetrieveAppParams): Promise<App>Types: RetrieveAppParams · App
setDomain
Attach (or replace) the app's custom domain.
setDomain(params: SetAppDomainParams): Promise<AppDomain>Types: SetAppDomainParams · AppDomain
startPreview
Start (or wake) a live preview session for the given version.
Idempotent — returns the existing session if one is active.
POST /api/app-preview-sessions
startPreview(params: { appVersionId: string }): Promise<unknown>stopPreview
Stop a preview session and tear down the sandbox.
stopPreview(params: { sessionId: string }): Promise<SuccessResponse>Types: SuccessResponse
update
Update an app (name, description, handle, publicAccess, defaultVersionId, config).
update(params: UpdateAppParams): Promise<App>Types: UpdateAppParams · App
updateVersionFile
Update a file in a specific app version.
updateVersionFile(params: UpdateAppVersionFileParams): Promise<SuccessResponse>