{ signal } for cancellation.
Labs
submitFlag() and submitGuideAnswer() return { correct, verdict }. The REST responses carry the verdict in message.
Guides: completion, lab content, discussions.
Lab types
Lab
Use
difficulty to show or filter labs. Map the values to your own wording if you like, such as “Easy” for beginner. Lab authors set it in the dashboard lab editor or the customer MCP, not through the API or SDK.
LabDetails
labs.get() returns the Lab fields except the has* indicators, plus:
The package exports
LabGuide, GuideTask, GuideQuestion, GuideCompletion, LabResourceLink, LabDiagram, LabVideo, and LabWriteup. The lab content guide explains them.
Deployments
membership defaults to free. sourceIp applies only to labs that use it.
Deployment handle
launch() and get() return a Deployment with id and these methods:
waitUntilReady(options?)
Resolves with
{ status: 'complete', outputs }. Throws deployment_failed when the deployment fails or ends, timeout at the deadline, and aborted when the signal fires.
Network errors, timeouts, server errors, and rate limits do not stop the wait. Definite errors, such as not_found or invalid_key, stop it at once. Stopping the wait does not end the deployment.
Status and run types
complete status with no recorded outputs returns an empty outputs object. Use normalizeOutputs to read it.
DeploymentRun has id, deploymentId, action, status, exitCode, outputs, error, and timestamps. action names the operation, such as building or tearing down the lab environment. States are queued, running, completed, or errored.