import type { S3Client } from "@aws-sdk/client-s3"; import type { Adapter } from "../index.js"; export interface DigitalOceanSpacesAdapterOptions { /** Spaces name. The adapter scopes all operations to it. */ bucket: string; /** * Spaces datacenter region, e.g. `"nyc3"`, `"sfo3"`, `"ams3"`, `"fra1"`, * `"sgp1"`, `"syd1"`, `"blr1"`, `"tor1"`, `"lon1"`. Drives the endpoint * host; there's no env-var fallback (no `DO_REGION` convention). */ region: string; /** * Override the Spaces endpoint. When unset, defaults to * `https://${region}.digitaloceanspaces.com`. Spaces routes by Host header * — the SDK prepends the bucket subdomain for virtual-hosted style. */ endpoint?: string; /** * Static credentials. Falls back to `DO_SPACES_KEY`; required if that env * var isn't set. */ accessKeyId?: string; /** * Static credentials. Falls back to `DO_SPACES_SECRET`; required if that * env var isn't set. */ secretAccessKey?: string; /** * Use path-style addressing (`//`) rather than virtual-hosted * style. Defaults to `false` — virtual-hosted is canonical for Spaces. */ forcePathStyle?: boolean; /** * Origin used to build URLs from `url()`. When set, `url(key)` returns * `${publicBaseUrl}/${key}` and skips signing — typical values are the * Spaces CDN host (`https://${bucket}.${region}.cdn.digitaloceanspaces.com`) * or a custom CNAME. 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; } export type DigitalOceanSpacesAdapter = Adapter; export declare const digitaloceanSpaces: (opts: DigitalOceanSpacesAdapterOptions) => DigitalOceanSpacesAdapter; //# sourceMappingURL=index.d.ts.map