Update Basic Xray Settings

Xray REST APIs

Products
JFrog Xray
Content Type
REST API
ft:sourceType
Paligo

Description: Enables administrators to configure a set of basic Xray settings.

Note

Some of these settings can also be configured individually using specific APIs, as described below.

Since: 7.37

Security: Requires an admin user

Usage: POST /artifactory/api/xrayRepo/updateXrayBasicSettings

Sample Request:

{
    "xrayEnabled": true,
    "xrayAllowBlocked": false,
    "xrayAllowWhenUnavailable": false,
    "blockUnscannedTimeoutSeconds": 60,
    "blockUnfinishedScansTimeoutSeconds": 1800
}

The request includes the following information:

Property

Type

Description

xrayEnabled

boolean

Determines whether Xray is currently enabled.

Default value: true

xrayAllowBlocked

boolean

Determines whether to block artifacts from being downloaded. This setting cannot override the blocking of unscanned artifacts.

Default value: false

xrayAllowWhenUnavailable

boolean

Determines whether to block certain operations (for example, downloading artifacts) when the connected Xray instance is unavailable.

Default value: false

blockUnscannedTimeoutSeconds

integer

Defines the amount of time to wait for Xray to start scanning an artifact before blocking operations on that artifact automatically if the scan has still not started.

Default value: 60 seconds (1 minute)

blockUnfinishedScansTimeoutSeconds

integer

Defines the amount of time to wait for Xray to finish scanning an artifact before blocking operations on that artifact automatically if the scan is still unfinished.

Default value: 1800 seconds (30 minutes)

Sample Response: same as request