All Products
Search
Document Center

Security Center:GetOssScanConfig

Last Updated:Aug 28, 2026

Retrieves the scan policy configuration.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

yundun-sas:GetOssScanConfig

get

*OssScanConfig

acs:yundun-sas:*:{#accountId}:ossscanconfig/{#ConfigId}

None None

Request parameters

Parameter

Type

Required

Description

Example

BucketName

string

No

The bucket name.

iboxpublic****

Id

string

No

The policy ID.

1

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID. It is a unique identifier generated by Alibaba Cloud for this request and can be used to troubleshoot issues.

E10BAF1C-A6C5-51E2-866C-76D5922E****

Data

object

The data details.

Enable

integer

Indicates whether the policy is enabled. Valid values:

  • 1: Enabled.

  • 0: Disabled.

1

ScanDayList

array

The scan days. The numbers represent the day of the week.

integer

The scan days. The numbers represent the day of the week.

1

BucketNameList

array

The list of bucket names.

string

The bucket name.

bcdata-oss****

KeySuffixList

array

The list of file suffixes to scan.

string

The file suffix to scan.

.asp

StartTime

string

The scan start time in the HH:mm:ss format.

00:00:00

EndTime

string

The scan end time in the HH:mm:ss format.

00:00:00

Name

string

The policy name.

testPolicy****

KeyPrefixList

array

The file prefix list.

string

The file prefix.

/root

Id

string

The policy ID.

1

BucketName

string

The bucket name.

hz-new02****

LastUpdateTime

integer

The last update timestamp.

1702025633079

BucketCount

integer

The number of buckets.

1

AllKeyPrefix

boolean

Indicates whether all prefixes are matched.

true

DecompressMaxLayer

integer

The maximum number of decompression layers when nested compressed files exist. The minimum value is 1 and the maximum value is 5. When the maximum decompression layer is exceeded, the decompression operation ends immediately. The scanning of files that have already been decompressed is not affected.

1

DecompressMaxFileCount

integer

The maximum number of files to decompress. The minimum value is 1 and the maximum value is 1000. When the maximum number of decompressed files is exceeded, the decompression operation ends immediately. The scanning of files that have already been decompressed is not affected.

100

DecryptionList

array

The list of decryption types.

string

The decryption type. Valid values:

  • OSS: OSS fully managed.

  • KMS: KMS.

KMS

LastModifiedStartTime

integer

Scans files whose last modification time is after the specified timestamp, in milliseconds.

1724301769834

RealTimeIncr

boolean

Specifies whether to enable real-time incremental scanning. When this parameter is set to true, the parameters ScanDayList, StartTime, and EndTime do not take effect.

true

Source

string

The business source. Valid values:

  • OSS: OSS

  • NAS: NAS

OSS

AutoAdd

integer

AutoAddConfigName

string

Examples

Success response

JSON format

{
  "RequestId": "E10BAF1C-A6C5-51E2-866C-76D5922E****",
  "Data": {
    "Enable": 1,
    "ScanDayList": [
      1
    ],
    "BucketNameList": [
      "bcdata-oss****"
    ],
    "KeySuffixList": [
      ".asp"
    ],
    "StartTime": "00:00:00",
    "EndTime": "00:00:00\n",
    "Name": "testPolicy****",
    "KeyPrefixList": [
      "/root"
    ],
    "Id": "1",
    "BucketName": "hz-new02****",
    "LastUpdateTime": 1702025633079,
    "BucketCount": 1,
    "AllKeyPrefix": true,
    "DecompressMaxLayer": 1,
    "DecompressMaxFileCount": 100,
    "DecryptionList": [
      "KMS"
    ],
    "LastModifiedStartTime": 1724301769834,
    "RealTimeIncr": true,
    "Source": "OSS",
    "AutoAdd": 0,
    "AutoAddConfigName": ""
  }
}

Error codes

HTTP status code

Error code

Error message

Description

500 ServerError ServerError
403 NoPermission caller has no permission You are not authorized to do this operation.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.