Skip to content
Console

SDK overview

S4 is compatible with the S3 protocol. To use any S3 SDK or tool, you only need to change the four settings below:

SettingValue
Endpointhttps://s3.bitiful.net
Regioncn-east-1
Access Key IDSub-user AccessKey
Secret Access KeySub-user SecretKey

Create keys in the console under Object Storage (对象存储) › Sub-users & Keys (子账户&Key). See Sub-users and AccessKeys.

A new sub-user has no permissions. Grant access to a bucket or directory first, or every request returns 403 AccessDenied.

Server-side SDKs

Each page covers uploads, multipart uploads, downloads, listing, copy and move, deletion, presigned URLs, S4 extension parameters, and error handling.

Clients

Never embed an AccessKey in a web page, app, or mini program, and never deliver one through an API. Have your server issue presigned URLs so clients upload and download directly. For how this works, see Upload files securely from clients.

Command-line tools

General notes

ItemNotes
Addressing styleBoth virtual-hosted style (bucket-name.s3.bitiful.net) and path style are supported; use the SDK default
Signature versionUse Signature V4. STS temporary credentials are not supported
ChecksumsThe default upload checksums of recent SDKs work as is; you do not need to disable Payload Signing
ListingEach page returns 100 entries by default; use a paginator and do not assume everything is returned at once
Large filesUse multipart upload above 100 MB; each part is 5 MiB to 20 GiB, with up to 10000 parts
Conditional writesIf-None-Match and If-Match are supported. See Conditional requests
MoveNative move is supported. See Move and rename objects
RetriesThe SDK retries 5xx responses automatically; rate limiting returns 429, which some SDKs do not retry automatically, so handle it yourself
Client reuseClients in every language can be used concurrently; create one per process

For the support status of each operation, see S3 API compatibility.

Why we recommend the S3 protocol

S3 is the de facto standard for object storage, supported by Alibaba Cloud OSS, Tencent Cloud COS, Qiniu Kodo, AWS S3, Cloudflare R2, and others.

Standardizing your team on the S3 protocol avoids lock-in to a single vendor: switching storage only requires changing the endpoint and keys.