Snapshots
A snapshot is a point in time representation of any configuration resource in PingOne. A snapshot is triggered when the request POST {{apiPath}}/v1/environments/{{envID}}/snapshots is called. The configuration resource, and all of its dependencies, are then stored by the Snapshot service.
The snapshots are stored and indexed using the original identifier (ID) of the configuration resource. For example, an applications snapshot will be stored using the ID of the application.
Subsequent calls to the request POST {{apiPath}}/v1/environments/{{envID}}/snapshots for the same configuration resource generates a new version of the configuration resource each time the request is called. You can retrieve the version history of any configuration resource using the original identifier of the resource. The snapshot created for a configuration resource is used to promote (apply) the configuration resource from the source environment to another environment.
When you create a new promotion, the snapshot contains source and target environments with all their dependencies, all resources for each environment. To get the snapshot with all dependencies for the environment, you need to read the snapshot embedded in the promotion. For this, you’ll use GET {{apiPath}}/v1/environments/{{envID}}/snapshots/{{configResourceID}}/embeddedSnapshots or GET {{apiPath}}/v1/environments/{{envID}}/snapshots/{{configResourceID}}/versions/{{snapshotID}}/embeddedSnapshots.
However, when you read a snapshot without using embeddedSnapshots, you’ll get a snapshot of the environments without all of the dependencies. For example, using GET {{apiPath}}/v1/environments/{{envID}}/snapshots/{{configResourceID}} doesn’t include all of the source and target environment dependencies.
|
You need to create a snapshot if you want to assign promotion variables. |
Snapshots data model
| Property | Type | Required | Mutable | Description |
|---|---|---|---|---|
|
String |
Required |
Mutable |
The URL of the resource to use. The form is: "https://api.pingone.com/v1/environments/{{envId}}/{{resourceName}}/{{resourceId}}", where "resourceName" is the name of the configuration resource to snapshot. |
|
Date |
N/A |
Read-only |
The date and time at which the resource was created (ISO 8601 format). |
|
Date |
N/A |
Read-only |
The date and time at which the snapshot creation was completed (ISO 8601 format). |
|
Object |
N/A |
Read-only |
The JSON representation of the configuration resource. Any attributes containing sensitive information in plain text (such as, display names, client secrets, passwords) are masked in the responses, and aren’t available to any caller, even administrators. If the configuration resource has been deleted, this will be empty (null). |
|
String |
N/A |
Read-only |
If an error occurs while creating the snapshot, it’s returned here. |
|
String |
N/A |
Read-only |
The identifier of the configuration. |
|
String |
Optional |
Mutable |
The identifier of the configuration resource used for the snapshot. |
|
String |
Optional |
Mutable |
The URL of the configuration resource. |
|
String[] |
Optional |
Mutable |
The list of identifiers for any dependent or referenced configuration resources. The dependent or referenced resources can be only one level down in the possible tree of such resources. |
|
String |
N/A |
Read-only |
The identifier of the snapshot. |
|
Date |
N/A |
Read-only |
The date and time at which the snapshot creation was started (ISO 8601 format). |
|
String |
N/A |
Read-only |
The status of the snapshot creation process. This can be any one of: COMPLETE, WAITING, IN_PROGRESS, ERROR. |
|
Date |
N/A |
Read-only |
The date and time at which the resource was last updated (ISO 8601 format). |
|
Date |
N/A |
Read-only |
The date and time of the |
Snapshots errors
In addition to the general error codes, snapshot operations can return the following errors:
| HTTP status | Top‑level code | Detail code | When it happens and what the response contains |
|---|---|---|---|
400 |
|
|
Message: When and detailsWhen: A snapshot request references an environment, resource, or snapshot ID that cannot be parsed as a UUID Details: |
400 |
|
|
Message: When and detailsWhen: A Details: |
400 |
|
|
Message: When and detailsWhen: A Details: Describes the failing parameter with target |
400 |
|
|
Message: When and detailsWhen: The service could not read or write the promotion variable definition in its datastore Details: Describes the datastore failure with target |
400 |
|
|
Message: When and detailsWhen: A Details: |
400 |
|
None |
Message: When and detailsWhen: A Details: |
401 |
|
None |
Message: When and detailsWhen: The access token is missing, invalid, or expired Details: None. |
403 |
|
|
Message: When and detailsWhen: The actor lacks the Details: |
403 |
|
|
Message: When and detailsWhen: The environment referenced by the request is disabled, or the Configuration Management capability is not enabled for the environment Details: |
404 |
|
None |
Message: When and detailsWhen: The snapshot or dependent snapshot referenced by the request does not exist, or a Read All Versions request finds no snapshots for the resource Details: |