Create sandbox

createSandbox(input: CreateSandboxInput!): Sandbox!

Requires project.sandboxes.manage.

Arguments

ArgumentTypeRequired
inputCreateSandboxInput!Yes

Input fields

input

CreateSandboxInput

FieldTypeRequiredDescription
projectReferenceStringNoProject UUID or slug to bill; when set, the project owner is billed.
environmentIdIDNoEnvironment whose variables are copied once into the sandbox; it also identifies the billing project.
accessScopeSandboxAccessScope!Yes
ttlModeSandboxLifetimeModeNo
ttlHoursIntNo

Response

Returns Sandbox!. Open the type for its fields and nested types.

FieldType
idID!
accessScopeSandboxAccessScope!
workspaceStorageSandboxWorkspaceStorage!
shortIdString!
endpointString!
statusSandboxStatus!
ttlModeSandboxLifetimeMode!
ttlHoursInt

All fields of Sandbox.

Types marked with ! cannot be null. Lists use [Type] notation. The type index lists all published input and response types.

Example

graphql
mutation CreateSandbox($input: CreateSandboxInput!) {
  createSandbox(input: $input) {
    id
    projectId
    runId
    status
    createdAt
  }
}
json
{
  "input": {
    "projectReference": "00000000-0000-4000-8000-000000000001",
    "accessScope": "project"
  }
}