SandboxInfo
SandboxInfo enqueues a sandbox for creation or refresh. A create operation on SandboxInfo represents creation of a new sandbox, and an update represents refresh of an existing sandbox. For every creation or update, a SandboxProcess is automatically created and is used for monitoring the sandbox copy process.
This object is available in API version 35.0 and later.
Supported SOAP Calls
create(), delete(), query(), retrieve(), update()
Supported REST HTTP Methods
GET, PATCH, POST, DELETE
Fields
Field | Details |
---|---|
ActivationUserGroupId |
|
ApexClassId |
|
AutoActivate |
|
CopyArchivedActivities |
|
CopyChatter |
|
Description |
|
Features |
|
HistoryDays |
|
LicenseType |
|
SandboxName |
|
SourceId |
|
TemplateId |
|
Usage
Creating a Sandbox
To enqueue a new sandbox:
- Create a SandboxInfo record.
- To find the status of a sandbox after it is enqueued, query SandboxProcess for a given SandboxInfoId field to find the latest SandboxProcess record. The value of Completed in Status indicates that the creation process is finished.
Refreshing a Sandbox
To refresh a sandbox:
- To start a sandbox refresh, edit the SandboxInfo record.
- To find the status of a sandbox after it is enqueued, find the latest SandboxProcess record by querying SandboxProcess for a given SandboxInfoId value. The value of Status indicates the current state of the process.
- When the Status field value is Pending Activation, change the value of the RefreshAction field to either ACTIVATE or DISCARD.
Deleting a Sandbox
To delete a sandbox, delete the SandboxInfo record that represents the sandbox. Deleting the SandboxInfo record deletes the sandbox and frees up a license.