Rules

Preview a forward rule-configuration rollback

Preview a change that restores the rule configuration of an earlier revision.

post/v1/programs/{program_id}/rule-configuration/revisions/{version}/rollback/preview

Request

  • Base URL: https://api.scrip.dev
  • URL: https://api.scrip.dev/v1/programs/{program_id}/rule-configuration/revisions/{version}/rollback/preview
  • Auth: HTTP bearer

Path parameters

program_idstring uuid required

The program's id.

versioninteger required

The earlier version to restore

Request body

expected_rule_configuration_versioninteger required

Current rule_configuration_version. A stale value rejects the request.

Example request

{
  "expected_rule_configuration_version": 8,
  "source": {
    "reference": "rules-editor-save",
    "type": "DASHBOARD"
  }
}

Response

The planned changes, and the token and hash to apply them

base_rule_configuration_versioninteger

Configuration version the preview was planned from.

change_idstring uuid

The id of this change. The apply response and the revision history carry the same id.

expires_atstring date-time

When preview_token stops working.

local_referencesobject

Mapping from each client_ref to its preview-allocated stable UUID.

preview_tokenstring

The token to send to apply. Nobody else can use it, and it stops working at expires_at.

request_hashstring

The hash to send to apply with preview_token.

Changes

No recorded changes to this operation across all 1 revision of this API.