import { S3Client } from '@aws-sdk/client-s3'; import { Adapter } from '../index.js'; interface AlibabaAdapterOptions { bucket: string; /** * Alibaba Cloud OSS region, e.g. `"cn-hangzhou"`, `"cn-shanghai"`, * `"cn-beijing"`, `"ap-southeast-1"` (Singapore), `"us-east-1"` (Virginia), * `"eu-central-1"` (Frankfurt). Drives the endpoint host * (`https://oss-.aliyuncs.com`); there's no env-var fallback. * Doubles as the SigV4 region (pass the bare region, not the * `oss-`-prefixed form). Buckets live in exactly one region. */ region: string; /** * Override the Alibaba OSS endpoint. When unset, defaults to * `https://oss-${region}.aliyuncs.com`. OSS routes by Host header — the * SDK prepends the bucket subdomain for virtual-hosted style. */ endpoint?: string; accessKeyId?: string; secretAccessKey?: string; /** * Use path-style addressing (`//`) rather than virtual-hosted * style. Defaults to `false` — virtual-hosted is canonical for Alibaba OSS. */ forcePathStyle?: boolean; /** * Origin used to build URLs from `url()`. When set, `url(key)` returns * `${publicBaseUrl}/${key}` and skips signing. For public buckets the * natural value is `https://${bucket}.oss-${region}.aliyuncs.com`; a * custom domain bound to the bucket also works. When unset, `url()` * falls back to a presigned GetObject (default expiry: 1 hour). */ publicBaseUrl?: string; /** * Default expiry, in seconds, for the presigned URLs returned by `url()` * when `publicBaseUrl` is not set. Defaults to 3600 (1 hour). */ defaultUrlExpiresIn?: number; } type AlibabaAdapter = Adapter; declare const alibaba: (opts: AlibabaAdapterOptions) => AlibabaAdapter; export { type AlibabaAdapter, type AlibabaAdapterOptions, alibaba };