Rule Pack Api Install
Installs the stored review in one transaction after verifying the stored files again. Changes Rule rows only: no Policy is marked unpublished and nothing is published. Requires the ADMIN role.
The stored review to install: its reviewId and artifactSha256, and confirmRetirement when the install retires Rules.
Show optional properties
{
"reviewId": "string",
"artifactSha256": "string"
}
{
"reviewId": "00000000-0000-4000-8000-000000000051",
"artifactSha256": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef",
"confirmRetirement": false
}
As the review response returned it
The review response artifactSha256
Confirms a pack whose review showed retirementNeedsConfirmation; absent means false
200 OK successful response envelope. The result of the install
{
"packSequence": 2,
"packVersion": "1.1.0",
"status": "INSTALLED",
"added": 1,
"updated": 1,
"unchanged": 12,
"retired": 0
}
Sequence number of the pack, from its manifest
Version text of the pack, from its manifest
ALREADY_INSTALLED means the ledger already records this exact pack: nothing changed and every count is 0.
INSTALLED: The pack was applied by this request; the counts are this install'sALREADY_INSTALLED: The ledger already records this exact pack: nothing was written and every count is 0
Number of Built-in Rules the install added; 0 when ALREADY_INSTALLED
Number of Built-in Rules the install updated; 0 when ALREADY_INSTALLED
Number of pack entries identical to the stored rule and not written; 0 when ALREADY_INSTALLED
Number of Built-in Rules the install retired; 0 when ALREADY_INSTALLED
400 Bad Request: MALFORMED_REQUEST or VALIDATION_FAILED
{
"errorCode": "string",
"message": "string",
"path": "string",
"timestamp": "string",
"reason": "string"
}
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
401 Unauthorized: UNAUTHENTICATED when the VTP_SESSION cookie is missing, unknown, expired or revoked
{
"errorCode": "string",
"message": "string",
"path": "string",
"timestamp": "string",
"reason": "string"
}
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
403 Forbidden: FORBIDDEN or CSRF_ERROR. CSRF_ERROR when the X-XSRF-TOKEN header is missing or wrong on a POST, PUT, PATCH or DELETE (only POST /api/v1/auth/login is exempt, and a request without a valid session gets 401 UNAUTHENTICATED instead); PASSWORD_CHANGE_REQUIRED when the account must change its password first (only GET /api/v1/auth/session, POST /api/v1/auth/logout and POST /api/v1/auth/change-password are exempt); LICENSE_REQUIRED or LICENSE_EXPIRED while the license pool is restricted (no license, or expired past grace) (exempt: every route under /api/v1/auth, GET /api/v1/user/preferences, GET /api/v1/licensing/summary and POST /api/v1/licensing/licenses)
{
"errorCode": "string",
"message": "string",
"path": "string",
"timestamp": "string",
"reason": "string"
}
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
409 Conflict: REVIEW_EXPIRED (no stored review with this reviewId), REVIEW_MISMATCH or RETIREMENT_NEEDS_CONFIRMATION
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
413 Content Too Large: PACK_TOO_LARGE
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
415 Unsupported Media Type: UNSUPPORTED_MEDIA_TYPE
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
422 Unprocessable Content: the stored pack no longer verifies (a PACK_* code), or PACK_ENTRY_INVALID with the import code as reason
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
503 Service Unavailable: TRUST_PROFILE_INVALID or CONSOLE_VERSION_UNKNOWN
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"reviewId":"string","artifactSha256":"string"}' https://{api_host}/api/v1/rules/pack/install