fetch to call the REST API directly, without the SDK. You can make the same requests from other languages.
The examples run on your server. apiKey is your organization API key, loaded from secure configuration.
List available labs
Request your organization’s lab catalog:id. Your application uses that ID to request a deployment.
Launch a lab
Your application supplies the selectedlabId and the current learner’s learnerId. Membership comes from your application’s access policy.
deploymentId with the learner’s session. Your application uses it to check status and end this deployment.
The response means that Cybr accepted the launch request. The lab environment takes time to become ready.
Check when the lab is ready
Request the deployment status about every five seconds while it isloading:
complete status means that the environment is ready. It does not mean that the learner completed the exercise.
Your application controls the polling schedule and timeout. A page refresh can resume status checks with the saved deployment ID.
Connection details can contain credentials. Your server must check that the current learner owns the deployment before it returns those details.
