Help Center/ Object Storage Service/ SDK Reference/ Node.js/ Bucket APIs (SDK for Node.js)/ Direct Reading (SDK for Node.js)/ Obtaining the Direct Reading Configuration of a Bucket (SDK for Node.js)
Updated on 2026-07-22 GMT+08:00

Obtaining the Direct Reading Configuration of a Bucket (SDK for Node.js)

Function

This API is used to obtain the direct reading configuration of a bucket.

If you have any questions during development, post them on the Issues page of GitHub.

Restrictions

Method

ObsClient.getBucketDirectColdAccess(params)

Request Parameters

Table 1 List of request parameters

Parameter

Type

Mandatory (Yes/No)

Description

Bucket

String

Yes

Explanation:

Bucket name

Restrictions:

  • A bucket name must be unique across all accounts and regions.
  • A bucket name:
    • Must be 3 to 63 characters long and start with a digit or letter. Lowercase letters, digits, hyphens (-), and periods (.) are allowed.
    • Cannot be formatted as an IP address.
    • Cannot start or end with a hyphen (-) or period (.).
    • Cannot contain two consecutive periods (..), for example, my..bucket.
    • Cannot contain a period (.) and a hyphen (-) adjacent to each other, for example, my-.bucket or my.-bucket.
  • If you repeatedly create buckets with the same name in the same region, no error will be reported and the bucket properties comply with those set in the first creation request.

Default value:

None

Responses

Table 2 Responses

Type

Description

Table 3

NOTE:

This API returns a Promise response, which requires the Promise or async/await syntax.

Explanation:

Returned results. For details, see Table 3.

Table 3 Response

Parameter

Type

Description

CommonMsg

ICommonMsg

Explanation:

Common information generated after an API call is complete, including the HTTP status code and error code. For details, see Table 4.

InterfaceResult

Table 5

Explanation:

Results returned for a successful call. For details, see Table 5.

Restrictions:

This parameter is left blank if the value of Status is greater than 300.

Table 4 ICommonMsg

Parameter

Type

Description

Status

number

Explanation:

HTTP status code returned by the OBS server.

Value range:

A status code is a group of digits indicating the status of a response. It ranges from 2xx (indicating successes) to 4xx or 5xx (indicating errors). For details, see Status Codes.

Code

string

Explanation:

Error code returned by the OBS server.

Message

string

Explanation:

Error description returned by the OBS server.

HostId

string

Explanation:

Request server ID returned by the OBS server.

RequestId

string

Explanation:

Request ID returned by the OBS server.

Id2

string

Explanation:

Request ID2 returned by the OBS server.

Indicator

string

Explanation:

Error code details returned by the OBS server.

Table 5 InterfaceResult

Parameter

Type

Description

Status

string

Explanation:

Direct reading status of a bucket. If direct reading has never been configured for a bucket or the direct reading configuration has been deleted, no direct reading status will be returned.

Value range:

  • Enabled: Direct reading is enabled for a bucket.
  • Disabled: Direct reading is disabled for a bucket.
  • If the Status parameter does not exist, direct reading is disabled for a bucket.