[Skip to main content](/content/docs/sdks/tigris/api/#__docusaurus_skipToContent_fallback/index.html)

On this page

API reference for
[`@tigrisdata/storage`](https://www.npmjs.com/package/@tigrisdata/storage)
v3.16.0.

For usage examples and guides, see [Using the SDK](/content/docs/sdks/tigris/using-sdk/index.html).

## Contents [​](/content/docs/sdks/tigris/api/\#contents "Direct link to Contents"/index.html)

- [Client API](/content/docs/sdks/tigris/api/#client-api/index.html)
- [Object Operations](/content/docs/sdks/tigris/api/#object-operations/index.html)
- [Presigned URLs](/content/docs/sdks/tigris/api/#presigned-urls/index.html)
- [Bucket Management](/content/docs/sdks/tigris/api/#bucket-management/index.html)
- [Bucket Configuration](/content/docs/sdks/tigris/api/#bucket-configuration/index.html)
- [Snapshots](/content/docs/sdks/tigris/api/#snapshots/index.html)
- [Multipart Upload](/content/docs/sdks/tigris/api/#multipart-upload/index.html)
- [Client Upload Handling](/content/docs/sdks/tigris/api/#client-upload-handling/index.html)
- [Statistics](/content/docs/sdks/tigris/api/#statistics/index.html)
- [Common Types](/content/docs/sdks/tigris/api/#common-types/index.html)

## Client API [​](/content/docs/sdks/tigris/api/\#client-api "Direct link to Client API"/index.html)

Functions and types exported from `@tigrisdata/storage/client` for browser-side
uploads.

### `upload` [​](/content/docs/sdks/tigris/api/\#upload "Direct link to upload"/index.html)

```ts
function upload(

name: string,

data: File | Blob,

options?: UploadOptions,

): Promise<TigrisStorageResponse<UploadResponse, Error>>;
```

### `executeWithConcurrency` [​](/content/docs/sdks/tigris/api/\#executewithconcurrency "Direct link to executewithconcurrency"/index.html)

Executes an array of task functions with a concurrency limit. Each task is a
function that returns a Promise.

```ts
function executeWithConcurrency<T>(

tasks: (() => Promise<T>)[],

concurrency: number,

): Promise<T[]>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types "Direct link to Types"/index.html)

### `UploadOptions` [​](/content/docs/sdks/tigris/api/\#uploadoptions "Direct link to uploadoptions"/index.html)

```ts
type UploadOptions = {

access?: "public" | "private";

addRandomSuffix?: boolean;

allowOverwrite?: boolean;

contentType?: string;

contentDisposition?: "attachment" | "inline";

url?: string;

multipart?: boolean;

partSize?: number;

/**

* Maximum number of concurrent part uploads for multipart uploads

* @default 4

*/

concurrency?: number;

onUploadProgress?: (progress: UploadProgress) => void;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `access` | `'public' | 'private'` | No |  |
| `addRandomSuffix` | `boolean` | No |  |
| `allowOverwrite` | `boolean` | No |  |
| `contentType` | `string` | No |  |
| `contentDisposition` | `'attachment' | 'inline'` | No |  |
| `url` | `string` | No |  |
| `multipart` | `boolean` | No |  |
| `partSize` | `number` | No |  |
| `concurrency` | `number` | No | Maximum number of concurrent part uploads for multipart uploads |
| `onUploadProgress` | `(progress: UploadProgress) =&gt; void` | No |  |

### `UploadProgress` [​](/content/docs/sdks/tigris/api/\#uploadprogress "Direct link to uploadprogress"/index.html)

```ts
type UploadProgress = {

loaded: number;

total: number;

percentage: number;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `loaded` | `number` | Yes |  |
| `total` | `number` | Yes |  |
| `percentage` | `number` | Yes |  |

### `UploadResponse` [​](/content/docs/sdks/tigris/api/\#uploadresponse "Direct link to uploadresponse"/index.html)

```ts
type UploadResponse = {

contentDisposition?: string;

contentType?: string;

modified: Date;

name: string;

size: number;

url: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `contentDisposition` | `string` | No |  |
| `contentType` | `string` | No |  |
| `modified` | `Date` | Yes |  |
| `name` | `string` | Yes |  |
| `size` | `number` | Yes |  |
| `url` | `string` | Yes |  |

## Object Operations [​](/content/docs/sdks/tigris/api/\#object-operations "Direct link to Object Operations"/index.html)

Create, read, update, and delete objects in a bucket.

### `put` [​](/content/docs/sdks/tigris/api/\#put "Direct link to put"/index.html)

```ts
function put(

path: string,

body: string | ReadableStream | Blob | Buffer,

options?: PutOptions,

): Promise<TigrisStorageResponse<PutResponse, Error>>;
```

### `get` [​](/content/docs/sdks/tigris/api/\#get "Direct link to get"/index.html)

**Overloads:**

```ts
function get(

path: string,

format: "string",

options: GetOptions & {

includeMetadata: true;

},

): Promise<TigrisStorageResponse<GetResponseWithMetadata<string>, Error>>;
```

```ts
function get(

path: string,

format: "file",

options: GetOptions & {

includeMetadata: true;

},

): Promise<TigrisStorageResponse<GetResponseWithMetadata<File>, Error>>;
```

```ts
function get(

path: string,

format: "stream",

options: GetOptions & {

includeMetadata: true;

},

): Promise<

TigrisStorageResponse<GetResponseWithMetadata<ReadableStream>, Error>

>;
```

```ts
function get(

path: string,

format: "string",

options?: GetOptions,

): Promise<TigrisStorageResponse<string, Error>>;
```

```ts
function get(

path: string,

format: "file",

options?: GetOptions,

): Promise<TigrisStorageResponse<File, Error>>;
```

```ts
function get(

path: string,

format: "stream",

options?: GetOptions,

): Promise<TigrisStorageResponse<ReadableStream, Error>>;
```

### `head` [​](/content/docs/sdks/tigris/api/\#head "Direct link to head"/index.html)

```ts
function head(

path: string,

options?: HeadOptions,

): Promise<TigrisStorageResponse<HeadResponse | undefined, Error>>;
```

### `list` [​](/content/docs/sdks/tigris/api/\#list "Direct link to list"/index.html)

```ts
function list(

options?: ListOptions,

): Promise<TigrisStorageResponse<ListResponse, Error>>;
```

### `remove` [​](/content/docs/sdks/tigris/api/\#remove "Direct link to remove"/index.html)

```ts
function remove(

path: string,

options?: RemoveOptions,

): Promise<TigrisStorageResponse<void, Error>>;
```

### `updateObject` [​](/content/docs/sdks/tigris/api/\#updateobject "Direct link to updateobject"/index.html)

> **Deprecated** Use `setObjectAccess` to change object ACLs, or the dedicated
> rename helper to change an object's key. `updateObject` will be removed in a
> future major version.

```ts
function updateObject(

path: string,

options?: UpdateObjectOptions,

): Promise<TigrisStorageResponse<UpdateObjectResponse, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-1 "Direct link to Types"/index.html)

### `PutOptions` [​](/content/docs/sdks/tigris/api/\#putoptions "Direct link to putoptions"/index.html)

```ts
type PutOptions = {

access?: "public" | "private";

addRandomSuffix?: boolean;

allowOverwrite?: boolean;

contentType?: string;

contentDisposition?: "attachment" | "inline";

metadata?: Record<string, string>;

multipart?: boolean;

partSize?: number;

queueSize?: number;

abortController?: AbortController;

onUploadProgress?: PutOnUploadProgress;

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `access` | `'public' | 'private'` | No |  |
| `addRandomSuffix` | `boolean` | No |  |
| `allowOverwrite` | `boolean` | No |  |
| `contentType` | `string` | No |  |
| `contentDisposition` | `'attachment' | 'inline'` | No |  |
| `metadata` | `Record&lt;string, string&gt;` | No |  |
| `multipart` | `boolean` | No |  |
| `partSize` | `number` | No |  |
| `queueSize` | `number` | No |  |
| `abortController` | `AbortController` | No |  |
| `onUploadProgress` | `PutOnUploadProgress` | No |  |
| `config` | `TigrisStorageConfig` | No |  |

### `PutResponse` [​](/content/docs/sdks/tigris/api/\#putresponse "Direct link to putresponse"/index.html)

```ts
type PutResponse = {

contentDisposition: string | undefined;

contentType: string | undefined;

etag: string;

metadata: Record<string, string> | undefined;

modified: Date;

path: string;

size: number;

url: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `contentDisposition` | `string | undefined` | Yes |  |
| `contentType` | `string | undefined` | Yes |  |
| `etag` | `string` | Yes |  |
| `metadata` | `Record&lt;string, string&gt; | undefined` | Yes |  |
| `modified` | `Date` | Yes |  |
| `path` | `string` | Yes |  |
| `size` | `number` | Yes |  |
| `url` | `string` | Yes |  |

### `PutOnUploadProgress` [​](/content/docs/sdks/tigris/api/\#putonuploadprogress "Direct link to putonuploadprogress"/index.html)

```ts
type PutOnUploadProgress = ({

loaded,

total,

percentage,

}: {

loaded: number;

total: number;

percentage: number;

}) => void;
```

### `GetOptions` [​](/content/docs/sdks/tigris/api/\#getoptions "Direct link to getoptions"/index.html)

```ts
type GetOptions = {

config?: TigrisStorageConfig;

contentDisposition?: "attachment" | "inline";

contentType?: string;

encoding?: string;

/**

* When true, `get` returns `{ body, metadata }` instead of the bare

* body, surfacing the object's etag, content metadata, user metadata,

* and (when `range` is used) `Content-Range` — all read from the same

* S3 response, no extra round-trip.

*/

includeMetadata?: boolean;

/**

* Byte range to read. Both bounds are inclusive and 0-based, matching

* the HTTP `Range: bytes=…` semantics. Omit `end` to read from `start`

* to the end of the object. A range that falls entirely outside the

* object returns an error (HTTP 416). The returned body is the partial

* content only.

*/

range?: {

start: number;

end?: number;

};

snapshotVersion?: string;

versionId?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |
| `contentDisposition` | `'attachment' | 'inline'` | No |  |
| `contentType` | `string` | No |  |
| `encoding` | `string` | No |  |
| `includeMetadata` | `boolean` | No | When true, `get` returns `{ body, metadata }` instead of the bare |

body, surfacing the object's etag, content metadata, user metadata, and (when
`range` is used) `Content-Range` — all read from the same S3 response, no extra
round-trip. \| \| `range` \| `\{ start: number; end?: number; \}` \| No \| Byte range
to read. Both bounds are inclusive and 0-based, matching the HTTP
`Range: bytes=…` semantics. Omit `end` to read from `start` to the end of the
object. A range that falls entirely outside the object returns an error (HTTP
416). The returned body is the partial content only. \| \| `snapshotVersion` \|
`string` \| No \| \| \| `versionId` \| `string` \| No \| \|

### `GetResponse` [​](/content/docs/sdks/tigris/api/\#getresponse "Direct link to getresponse"/index.html)

```ts
type GetResponse = string | File | ReadableStream;
```

### `HeadOptions` [​](/content/docs/sdks/tigris/api/\#headoptions "Direct link to headoptions"/index.html)

```ts
type HeadOptions = {

snapshotVersion?: string;

versionId?: string;

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `snapshotVersion` | `string` | No |  |
| `versionId` | `string` | No |  |
| `config` | `TigrisStorageConfig` | No |  |

### `HeadResponse` [​](/content/docs/sdks/tigris/api/\#headresponse "Direct link to headresponse"/index.html)

```ts
type HeadResponse = {

contentDisposition: string;

contentType: string;

etag: string;

metadata: Record<string, string>;

modified: Date;

path: string;

size: number;

url: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `contentDisposition` | `string` | Yes |  |
| `contentType` | `string` | Yes |  |
| `etag` | `string` | Yes |  |
| `metadata` | `Record&lt;string, string&gt;` | Yes |  |
| `modified` | `Date` | Yes |  |
| `path` | `string` | Yes |  |
| `size` | `number` | Yes |  |
| `url` | `string` | Yes |  |

### `ListOptions` [​](/content/docs/sdks/tigris/api/\#listoptions "Direct link to listoptions"/index.html)

```ts
type ListOptions = {

delimiter?: string;

prefix?: string;

limit?: number;

paginationToken?: string;

snapshotVersion?: string;

source?: "tigris" | "shadow";

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `delimiter` | `string` | No |  |
| `prefix` | `string` | No |  |
| `limit` | `number` | No |  |
| `paginationToken` | `string` | No |  |
| `snapshotVersion` | `string` | No |  |
| `source` | `'tigris' | 'shadow'` | No |  |
| `config` | `TigrisStorageConfig` | No |  |

### `ListItem` [​](/content/docs/sdks/tigris/api/\#listitem "Direct link to listitem"/index.html)

```ts
type ListItem = {

id: string;

name: string;

size: number;

lastModified: Date;

etag: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | Yes |  |
| `name` | `string` | Yes |  |
| `size` | `number` | Yes |  |
| `lastModified` | `Date` | Yes |  |
| `etag` | `string` | Yes |  |

### `ListResponse` [​](/content/docs/sdks/tigris/api/\#listresponse "Direct link to listresponse"/index.html)

```ts
type ListResponse = {

items: ListItem[];

commonPrefixes: string[];

paginationToken: string | undefined;

hasMore: boolean;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `items` | `ListItem[]` | Yes |  |
| `commonPrefixes` | `string[]` | Yes |  |
| `paginationToken` | `string | undefined` | Yes |  |
| `hasMore` | `boolean` | Yes |  |

### `RemoveOptions` [​](/content/docs/sdks/tigris/api/\#removeoptions "Direct link to removeoptions"/index.html)

```ts
type RemoveOptions = {

config?: TigrisStorageConfig;

versionId?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |
| `versionId` | `string` | No |  |

### `UpdateObjectOptions` [​](/content/docs/sdks/tigris/api/\#updateobjectoptions "Direct link to updateobjectoptions"/index.html)

```ts
type UpdateObjectOptions = {

config?: TigrisStorageConfig;

key?: string;

access?: "public" | "private";

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |
| `key` | `string` | No |  |
| `access` | `'public' | 'private'` | No |  |

### `UpdateObjectResponse` [​](/content/docs/sdks/tigris/api/\#updateobjectresponse "Direct link to updateobjectresponse"/index.html)

```ts
type UpdateObjectResponse = {

path: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `path` | `string` | Yes |  |

## Presigned URLs [​](/content/docs/sdks/tigris/api/\#presigned-urls "Direct link to Presigned URLs"/index.html)

Generate presigned URLs for time-limited access to objects.

### `getPresignedUrl` [​](/content/docs/sdks/tigris/api/\#getpresignedurl "Direct link to getpresignedurl"/index.html)

```ts
function getPresignedUrl(

path: string,

options: GetPresignedUrlOptions,

): Promise<TigrisStorageResponse<GetPresignedUrlResponse, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-2 "Direct link to Types"/index.html)

### `GetPresignedUrlOptions` [​](/content/docs/sdks/tigris/api/\#getpresignedurloptions "Direct link to getpresignedurloptions"/index.html)

```ts
type GetPresignedUrlOptions = {

/**

* The access key ID to use for the presigned URL.

* If not provided, the access key ID from the config will be used.

*/

accessKeyId?: string;

/**

* The expiration time of the presigned URL in seconds.

* Default is 3600 seconds (1 hour).

*/

expiresIn?: number;

/**

* Snapshot version to read from. When set, the presigned URL is

* pinned to the object version that was current at the time of the

* snapshot.

*

* The gateway's presign endpoint accepts a literal object versionId

* (not a snapshot version), so this function resolves the snapshot

* to the correct versionId client-side: lists the key's versions

* (and delete markers) and selects the newest entry with

* `versionId <= snapshotVersion`.

*

* Only valid with `operation: 'get'`. Returns an error if the object

* did not exist at the snapshot time (either never written, or

* deleted before the snapshot).

*/

snapshotVersion?: string;

config?: TigrisStorageConfig;

} & MethodOrOperation;
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `accessKeyId` | `string` | No | The access key ID to use for the presigned URL. |
| If not provided, the access key ID from the config will be used. |  |  |  |
| `expiresIn` | `number` | No | The expiration time of the presigned URL in seconds. |
| Default is 3600 seconds (1 hour). |  |  |  |
| `snapshotVersion` | `string` | No | Snapshot version to read from. When set, the presigned URL is |

pinned to the object version that was current at the time of the snapshot.

The gateway's presign endpoint accepts a literal object versionId (not a
snapshot version), so this function resolves the snapshot to the correct
versionId client-side: lists the key's versions (and delete markers) and selects
the newest entry with `versionId <= snapshotVersion`.

Only valid with `operation: 'get'`. Returns an error if the object did not exist
at the snapshot time (either never written, or deleted before the snapshot). \| \|
`config` \| `TigrisStorageConfig` \| No \| \|

### `GetPresignedUrlResponse` [​](/content/docs/sdks/tigris/api/\#getpresignedurlresponse "Direct link to getpresignedurlresponse"/index.html)

```ts
type GetPresignedUrlResponse = {

url: string;

expiresIn: number;

} & MethodOrOperation;
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `url` | `string` | Yes |  |
| `expiresIn` | `number` | Yes |  |

### `GetPresignedUrlOperation` [​](/content/docs/sdks/tigris/api/\#getpresignedurloperation "Direct link to getpresignedurloperation"/index.html)

```ts
type GetPresignedUrlOperation = "get" | "put";
```

### `MethodOrOperation` [​](/content/docs/sdks/tigris/api/\#methodoroperation "Direct link to methodoroperation"/index.html)

```ts
type MethodOrOperation =

| {

method: GetPresignedUrlOperation;

operation?: never;

}

| {

operation: GetPresignedUrlOperation;

method?: never;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `method` | `GetPresignedUrlOperation` | Yes |  |
| `operation` | `never` | No |  |
| `operation` | `GetPresignedUrlOperation` | Yes |  |
| `method` | `never` | No |  |

## Bucket Management [​](/content/docs/sdks/tigris/api/\#bucket-management "Direct link to Bucket Management"/index.html)

Create, list, update, and delete buckets.

### `createBucket` [​](/content/docs/sdks/tigris/api/\#createbucket "Direct link to createbucket"/index.html)

```ts
function createBucket(

bucketName: string,

options?: CreateBucketOptions,

): Promise<TigrisStorageResponse<CreateBucketResponse, Error>>;
```

### `getBucketInfo` [​](/content/docs/sdks/tigris/api/\#getbucketinfo "Direct link to getbucketinfo"/index.html)

```ts
function getBucketInfo(

bucketName: string,

options?: GetBucketInfoOptions,

): Promise<TigrisStorageResponse<BucketInfoResponse, Error>>;
```

### `listBuckets` [​](/content/docs/sdks/tigris/api/\#listbuckets "Direct link to listbuckets"/index.html)

```ts
function listBuckets(

options?: ListBucketsOptions,

): Promise<TigrisStorageResponse<ListBucketsResponse, Error>>;
```

### `updateBucket` [​](/content/docs/sdks/tigris/api/\#updatebucket "Direct link to updatebucket"/index.html)

```ts
function updateBucket(

bucketName: string,

options?: UpdateBucketOptions,

): Promise<TigrisStorageResponse<UpdateBucketResponse, Error>>;
```

### `removeBucket` [​](/content/docs/sdks/tigris/api/\#removebucket "Direct link to removebucket"/index.html)

```ts
function removeBucket(

bucketName: string,

options?: RemoveBucketOptions,

): Promise<TigrisStorageResponse<void, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-3 "Direct link to Types"/index.html)

### `CreateBucketOptions` [​](/content/docs/sdks/tigris/api/\#createbucketoptions "Direct link to createbucketoptions"/index.html)

```ts
type CreateBucketOptions = {

enableSnapshot?: boolean;

sourceBucketName?: string;

sourceBucketSnapshot?: string;

access?: "public" | "private";

defaultTier?: StorageClass;

locations?: BucketLocations;

enableDirectoryListing?: boolean;

allowObjectAcl?: boolean;

config?: Omit<TigrisStorageConfig, "bucket">;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `enableSnapshot` | `boolean` | No |  |
| `sourceBucketName` | `string` | No |  |
| `sourceBucketSnapshot` | `string` | No |  |
| `access` | `'public' | 'private'` | No |  |
| `defaultTier` | `StorageClass` | No |  |
| `locations` | `BucketLocations` | No |  |
| `enableDirectoryListing` | `boolean` | No |  |
| `allowObjectAcl` | `boolean` | No |  |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |

### `CreateBucketResponse` [​](/content/docs/sdks/tigris/api/\#createbucketresponse "Direct link to createbucketresponse"/index.html)

```ts
type CreateBucketResponse = {

isSnapshotEnabled: boolean;

hasForks: boolean;

sourceBucketName?: string;

sourceBucketSnapshot?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `isSnapshotEnabled` | `boolean` | Yes |  |
| `hasForks` | `boolean` | Yes |  |
| `sourceBucketName` | `string` | No |  |
| `sourceBucketSnapshot` | `string` | No |  |

### `GetBucketInfoOptions` [​](/content/docs/sdks/tigris/api/\#getbucketinfooptions "Direct link to getbucketinfooptions"/index.html)

```ts
type GetBucketInfoOptions = {

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |

### `BucketInfoResponse` [​](/content/docs/sdks/tigris/api/\#bucketinforesponse "Direct link to bucketinforesponse"/index.html)

```ts
type BucketInfoResponse = {

/**

* @deprecated Use `locations` instead — it carries the same data with

* a structured `BucketLocations` shape that distinguishes `global` /

* `multi` / `single` / `dual`. `regions` will be removed in the next

* major version.

*

* Note: for region codes the SDK does not recognize, `regions` passes

* the raw value through (e.g. `['mars']`) while `locations` falls back

* defensively to `{ type: 'global' }`. The two fields can therefore

* disagree when the gateway returns a region code newer than the SDK.

*/

regions: string[];

locations: BucketLocations;

isSnapshotEnabled: boolean;

forkInfo:

| {

hasChildren: boolean;

parents: Array<{

bucketName: string;

forkCreatedAt: Date;

snapshot: string;

snapshotCreatedAt: Date;

}>;

}

| undefined;

settings: {

allowObjectAcl: boolean;

defaultTier: StorageClass;

lifecycleRules?: BucketLifecycleRule[];

dataMigration?: Omit<BucketMigration, "enabled">;

/**

* @deprecated Use `lifecycleRules` instead. This field is no longer

* populated — read the rule with only `expiration` (no transition,

* no filter) from `lifecycleRules` if you need the bucket-wide TTL.

*/

ttlConfig?: BucketTtl;

customDomain?: string;

softDelete:

| {

enabled: true;

retentionDays: number;

}

| {

enabled: false;

};

/**

* @deprecated Use `softDelete` instead.

*/

deleteProtection: boolean;

corsRules: BucketCorsRule[];

additionalHeaders?: GetBucketInfoApiResponseBody["additional_http_headers"];

notifications?: BucketNotification;

};

sizeInfo: {

numberOfObjects: number | undefined;

size: number | undefined;

numberOfObjectsAllVersions: number | undefined;

};

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `regions` | `string[]` | Yes | **Deprecated.** Use `locations` instead — it carries the same data with |

a structured `BucketLocations` shape that distinguishes `global` / `multi` /
`single` / `dual`. `regions` will be removed in the next major version.

Note: for region codes the SDK does not recognize, `regions` passes the raw
value through (e.g. `['mars']`) while `locations` falls back defensively to
`{ type: 'global' }`. The two fields can therefore disagree when the gateway
returns a region code newer than the SDK. \| \| `locations` \| `BucketLocations` \|
Yes \| \| \| `isSnapshotEnabled` \| `boolean` \| Yes \| \| \| `forkInfo` \|
`\{ hasChildren: boolean; parents: Array&lt;\{ bucketName: string; forkCreatedAt: Date; snapshot: string; snapshotCreatedAt: Date; \}&gt;; \} \| undefined`
\| Yes \| \| \| `settings` \|
`\{ allowObjectAcl: boolean; defaultTier: StorageClass; lifecycleRules?: BucketLifecycleRule[]; dataMigration?: Omit&lt;BucketMigration, 'enabled'&gt;; /** * @deprecated Use`lifecycleRules`instead. This field is no longer * populated — read the rule with only`expiration`(no transition, * no filter) from`lifecycleRules`if you need the bucket-wide TTL. */ ttlConfig?: BucketTtl; customDomain?: string; softDelete: \{ enabled: true; retentionDays: number; \} \| \{ enabled: false; \}; /** * @deprecated Use`softDelete` instead. */ deleteProtection: boolean; corsRules: BucketCorsRule[]; additionalHeaders?: GetBucketInfoApiResponseBody['additional_http_headers']; notifications?: BucketNotification; \}`
\| Yes \| \| \| `sizeInfo` \|
`\{ numberOfObjects: number \| undefined; size: number \| undefined; numberOfObjectsAllVersions: number \| undefined; \}`
\| Yes \| \|

### `ListBucketsOptions` [​](/content/docs/sdks/tigris/api/\#listbucketsoptions "Direct link to listbucketsoptions"/index.html)

```ts
type ListBucketsOptions = {

config?: TigrisStorageConfig;

paginationToken?: string;

limit?: number;

deleted?: boolean;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |
| `paginationToken` | `string` | No |  |
| `limit` | `number` | No |  |
| `deleted` | `boolean` | No |  |

### `ListBucketsResponse` [​](/content/docs/sdks/tigris/api/\#listbucketsresponse "Direct link to listbucketsresponse"/index.html)

```ts
type ListBucketsResponse = {

buckets: Bucket[];

owner?: BucketOwner;

paginationToken?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `buckets` | `Bucket[]` | Yes |  |
| `owner` | `BucketOwner` | No |  |
| `paginationToken` | `string` | No |  |

### `Bucket` [​](/content/docs/sdks/tigris/api/\#bucket "Direct link to bucket"/index.html)

```ts
type Bucket = {

name: string;

creationDate: Date;

regions?: string[];

type?: BucketType;

visibility?: BucketVisibility;

softDeleteInfo?: {

enabled: boolean;

retentionDays: number;

};

forkInfo?: {

hasChildren: boolean;

parents: Array<{

bucketName: string;

forkCreatedAt: Date;

snapshot: string;

snapshotCreatedAt: Date;

}>;

};

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `name` | `string` | Yes |  |
| `creationDate` | `Date` | Yes |  |
| `regions` | `string[]` | No |  |
| `type` | `BucketType` | No |  |
| `visibility` | `BucketVisibility` | No |  |
| `softDeleteInfo` | `\{ enabled: boolean; retentionDays: number; \}` | No |  |
| `forkInfo` | `\{ hasChildren: boolean; parents: Array&lt;\{ bucketName: string; forkCreatedAt: Date; snapshot: string; snapshotCreatedAt: Date; \}&gt;; \}` | No |  |

### `BucketOwner` [​](/content/docs/sdks/tigris/api/\#bucketowner "Direct link to bucketowner"/index.html)

```ts
type BucketOwner = {

name: string;

id: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `name` | `string` | Yes |  |
| `id` | `string` | Yes |  |

### `UpdateBucketOptions` [​](/content/docs/sdks/tigris/api/\#updatebucketoptions "Direct link to updatebucketoptions"/index.html)

```ts
type UpdateBucketOptions = {

access?: "public" | "private";

allowObjectAcl?: boolean;

disableDirectoryListing?: boolean;

locations?: BucketLocations;

cacheControl?: string;

customDomain?: string;

enableAdditionalHeaders?: boolean;

softDelete?:

| {

enabled: true;

retentionDays: number;

}

| {

enabled: false;

};

/**

* @deprecated Use `softDelete` instead.

*/

enableDeleteProtection?: boolean;

config?: Omit<TigrisStorageConfig, "bucket">;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `access` | `'public' | 'private'` | No |  |
| `allowObjectAcl` | `boolean` | No |  |
| `disableDirectoryListing` | `boolean` | No |  |
| `locations` | `BucketLocations` | No |  |
| `cacheControl` | `string` | No |  |
| `customDomain` | `string` | No |  |
| `enableAdditionalHeaders` | `boolean` | No |  |
| `softDelete` | `\{ enabled: true; retentionDays: number; \} | \{ enabled: false; \}` | No |  |
| `enableDeleteProtection` | `boolean` | No | **Deprecated.** Use `softDelete` instead. |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |

### `UpdateBucketResponse` [​](/content/docs/sdks/tigris/api/\#updatebucketresponse "Direct link to updatebucketresponse"/index.html)

```ts
type UpdateBucketResponse = {

bucket: string;

updated: boolean;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `bucket` | `string` | Yes |  |
| `updated` | `boolean` | Yes |  |

### `RemoveBucketOptions` [​](/content/docs/sdks/tigris/api/\#removebucketoptions "Direct link to removebucketoptions"/index.html)

```ts
type RemoveBucketOptions = {

force?: boolean;

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `force` | `boolean` | No |  |
| `config` | `TigrisStorageConfig` | No |  |

## Bucket Configuration [​](/content/docs/sdks/tigris/api/\#bucket-configuration "Direct link to Bucket Configuration"/index.html)

Configure CORS, lifecycle rules, TTL, migration, and notifications for a bucket.

### `setBucketCors` [​](/content/docs/sdks/tigris/api/\#setbucketcors "Direct link to setbucketcors"/index.html)

```ts
function setBucketCors(

bucketName: string,

options?: SetBucketCorsOptions,

): Promise<TigrisStorageResponse<UpdateBucketResponse, Error>>;
```

### `setBucketLifecycle` [​](/content/docs/sdks/tigris/api/\#setbucketlifecycle "Direct link to setbucketlifecycle"/index.html)

```ts
function setBucketLifecycle(

bucketName: string,

options?: SetBucketLifecycleOptions,

): Promise<TigrisStorageResponse<UpdateBucketResponse, Error>>;
```

### `setBucketTtl` [​](/content/docs/sdks/tigris/api/\#setbucketttl "Direct link to setbucketttl"/index.html)

```ts
function setBucketTtl(

bucketName: string,

options?: SetBucketTtlOptions,

): Promise<TigrisStorageResponse<UpdateBucketResponse, Error>>;
```

### `setBucketMigration` [​](/content/docs/sdks/tigris/api/\#setbucketmigration "Direct link to setbucketmigration"/index.html)

```ts
function setBucketMigration(

bucketName: string,

options?: SetBucketMigrationOptions,

): Promise<TigrisStorageResponse<UpdateBucketResponse, Error>>;
```

### `setBucketNotifications` [​](/content/docs/sdks/tigris/api/\#setbucketnotifications "Direct link to setbucketnotifications"/index.html)

Configure webhook notifications for object events on a bucket.

**Scenarios:**

1. If `notificationConfig` is empty (`{}`), sends it as-is to clear
notifications.

2. If only `enabled` is provided, fetches the existing config and merges with
the new `enabled` value. Errors if no existing config is found.

3. If config is provided without `enabled`, fetches existing config and merges,
retaining the existing `enabled` value.

4. `url` is validated when provided (must be a valid http/https URL).

5. `auth.username` and `auth.password` are validated when provided.

6. `auth.token` is validated when provided.

7. `auth.token` and `auth.username`/`auth.password` cannot be provided together.

8. `override` replaces the existing config when `true`. When `false` (default),
merges with the existing config.

```ts
function setBucketNotifications(

bucketName: string,

options: SetBucketNotificationsOptions,

): Promise<TigrisStorageResponse<UpdateBucketResponse, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-4 "Direct link to Types"/index.html)

### `SetBucketCorsOptions` [​](/content/docs/sdks/tigris/api/\#setbucketcorsoptions "Direct link to setbucketcorsoptions"/index.html)

```ts
type SetBucketCorsOptions = {

config?: Omit<TigrisStorageConfig, "bucket">;

override?: boolean;

rules: BucketCorsRule[];

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |
| `override` | `boolean` | No |  |
| `rules` | `BucketCorsRule[]` | Yes |  |

### `SetBucketLifecycleOptions` [​](/content/docs/sdks/tigris/api/\#setbucketlifecycleoptions "Direct link to setbucketlifecycleoptions"/index.html)

```ts
type SetBucketLifecycleOptions = {

lifecycleRules: BucketLifecycleRule[];

config?: Omit<TigrisStorageConfig, "bucket">;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `lifecycleRules` | `BucketLifecycleRule[]` | Yes |  |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |

### `SetBucketTtlOptions` [​](/content/docs/sdks/tigris/api/\#setbucketttloptions "Direct link to setbucketttloptions"/index.html)

```ts
type SetBucketTtlOptions = {

ttlConfig?: BucketTtl;

config?: Omit<TigrisStorageConfig, "bucket">;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `ttlConfig` | `BucketTtl` | No |  |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |

### `SetBucketMigrationOptions` [​](/content/docs/sdks/tigris/api/\#setbucketmigrationoptions "Direct link to setbucketmigrationoptions"/index.html)

```ts
type SetBucketMigrationOptions = {

dataMigration?: BucketMigration;

config?: Omit<TigrisStorageConfig, "bucket">;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `dataMigration` | `BucketMigration` | No |  |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |

### `SetBucketNotificationsOptions` [​](/content/docs/sdks/tigris/api/\#setbucketnotificationsoptions "Direct link to setbucketnotificationsoptions"/index.html)

```ts
type SetBucketNotificationsOptions = {

config?: Omit<TigrisStorageConfig, "bucket">;

notificationConfig: BucketNotification;

override?: boolean;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |
| `notificationConfig` | `BucketNotification` | Yes |  |
| `override` | `boolean` | No |  |

### `BucketCorsRule` [​](/content/docs/sdks/tigris/api/\#bucketcorsrule "Direct link to bucketcorsrule"/index.html)

```ts
type BucketCorsRule = {

allowedOrigins: string | string[];

allowedMethods?: string | string[];

allowedHeaders?: string | string[];

exposeHeaders?: string | string[];

maxAge?: number;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `allowedOrigins` | `string | string[]` | Yes |  |
| `allowedMethods` | `string | string[]` | No |  |
| `allowedHeaders` | `string | string[]` | No |  |
| `exposeHeaders` | `string | string[]` | No |  |
| `maxAge` | `number` | No |  |

### `BucketLifecycleRule` [​](/content/docs/sdks/tigris/api/\#bucketlifecyclerule "Direct link to bucketlifecyclerule"/index.html)

A bucket lifecycle rule. A rule can have at most one transition (top-level
`storageClass` \+ `days`/`date`) and/or one `expiration`, optionally scoped to a
key prefix via `filter.prefix`. At least one of transition or expiration must be
present.

```ts
/**

* A bucket lifecycle rule. A rule can have at most one transition

* (top-level `storageClass` + `days`/`date`) and/or one `expiration`,

* optionally scoped to a key prefix via `filter.prefix`. At least one

* of transition or expiration must be present.

*/

type BucketLifecycleRule = {

id?: string;

enabled?: boolean;

storageClass?: Exclude<StorageClass, "STANDARD">;

days?: number;

date?: string;

expiration?: BucketLifecycleExpiration;

filter?: BucketLifecycleFilter;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | No |  |
| `enabled` | `boolean` | No |  |
| `storageClass` | `Exclude&lt;StorageClass, 'STANDARD'&gt;` | No |  |
| `days` | `number` | No |  |
| `date` | `string` | No |  |
| `expiration` | `BucketLifecycleExpiration` | No |  |
| `filter` | `BucketLifecycleFilter` | No |  |

### `BucketTtl` [​](/content/docs/sdks/tigris/api/\#bucketttl "Direct link to bucketttl"/index.html)

Bucket-wide TTL configuration. Kept for back-compat with `setBucketTtl`, which
manages a lifecycle rule with only `expiration` (no transition, no filter). New
code should configure expirations via `BucketLifecycleRule.expiration` on
`setBucketLifecycle` instead. This shape is expected to be removed in the next
major version.

```ts
/**

* Bucket-wide TTL configuration. Kept for back-compat with `setBucketTtl`,

* which manages a lifecycle rule with only `expiration` (no transition,

* no filter). New code should configure expirations via

* `BucketLifecycleRule.expiration` on `setBucketLifecycle` instead. This

* shape is expected to be removed in the next major version.

*/

type BucketTtl = {

id?: string;

enabled?: boolean;

days?: number;

date?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | No |  |
| `enabled` | `boolean` | No |  |
| `days` | `number` | No |  |
| `date` | `string` | No |  |

### `BucketMigration` [​](/content/docs/sdks/tigris/api/\#bucketmigration "Direct link to bucketmigration"/index.html)

```ts
type BucketMigration = {

enabled: boolean;

accessKey?: string;

secretKey?: string;

region?: string;

name?: string;

endpoint?: string;

writeThrough?: boolean;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `enabled` | `boolean` | Yes |  |
| `accessKey` | `string` | No |  |
| `secretKey` | `string` | No |  |
| `region` | `string` | No |  |
| `name` | `string` | No |  |
| `endpoint` | `string` | No |  |
| `writeThrough` | `boolean` | No |  |

### `BucketNotification` [​](/content/docs/sdks/tigris/api/\#bucketnotification "Direct link to bucketnotification"/index.html)

```ts
type BucketNotification =

| BucketNotificationBase

| BucketNotificationBasicAuth

| BucketNotificationTokenAuth;
```

### `BucketNotificationBase` [​](/content/docs/sdks/tigris/api/\#bucketnotificationbase "Direct link to bucketnotificationbase"/index.html)

```ts
type BucketNotificationBase = {

enabled?: boolean;

url?: string;

filter?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `enabled` | `boolean` | No |  |
| `url` | `string` | No |  |
| `filter` | `string` | No |  |

### `BucketNotificationBasicAuth` [​](/content/docs/sdks/tigris/api/\#bucketnotificationbasicauth "Direct link to bucketnotificationbasicauth"/index.html)

```ts
type BucketNotificationBasicAuth = BucketNotificationBase & {

auth: {

username: string;

password: string;

token?: never;

};

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `auth` | `\{ username: string; password: string; token?: never; \}` | Yes |  |

### `BucketNotificationTokenAuth` [​](/content/docs/sdks/tigris/api/\#bucketnotificationtokenauth "Direct link to bucketnotificationtokenauth"/index.html)

```ts
type BucketNotificationTokenAuth = BucketNotificationBase & {

auth: {

token: string;

username?: never;

password?: never;

};

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `auth` | `\{ token: string; username?: never; password?: never; \}` | Yes |  |

## Snapshots [​](/content/docs/sdks/tigris/api/\#snapshots "Direct link to Snapshots"/index.html)

Create and list bucket snapshots.

### `createBucketSnapshot` [​](/content/docs/sdks/tigris/api/\#createbucketsnapshot "Direct link to createbucketsnapshot"/index.html)

**Overloads:**

```ts
function createBucketSnapshot(

options?: CreateBucketSnapshotOptions,

): Promise<TigrisStorageResponse<CreateBucketSnapshotResponse, Error>>;
```

```ts
function createBucketSnapshot(

sourceBucketName?: string,

options?: CreateBucketSnapshotOptions,

): Promise<TigrisStorageResponse<CreateBucketSnapshotResponse, Error>>;
```

### `listBucketSnapshots` [​](/content/docs/sdks/tigris/api/\#listbucketsnapshots "Direct link to listbucketsnapshots"/index.html)

**Overloads:**

```ts
function listBucketSnapshots(

options?: ListBucketSnapshotsOptions,

): Promise<TigrisStorageResponse<ListBucketSnapshotsResponse, Error>>;
```

```ts
function listBucketSnapshots(

sourceBucketName?: string,

options?: ListBucketSnapshotsOptions,

): Promise<TigrisStorageResponse<ListBucketSnapshotsResponse, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-5 "Direct link to Types"/index.html)

### `CreateBucketSnapshotOptions` [​](/content/docs/sdks/tigris/api/\#createbucketsnapshotoptions "Direct link to createbucketsnapshotoptions"/index.html)

```ts
type CreateBucketSnapshotOptions = {

name?: string;

config?: Omit<TigrisStorageConfig, "bucket">;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `name` | `string` | No |  |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |

### `CreateBucketSnapshotResponse` [​](/content/docs/sdks/tigris/api/\#createbucketsnapshotresponse "Direct link to createbucketsnapshotresponse"/index.html)

```ts
type CreateBucketSnapshotResponse = {

snapshotVersion: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `snapshotVersion` | `string` | Yes |  |

### `ListBucketSnapshotsOptions` [​](/content/docs/sdks/tigris/api/\#listbucketsnapshotsoptions "Direct link to listbucketsnapshotsoptions"/index.html)

```ts
type ListBucketSnapshotsOptions = {

config?: Omit<TigrisStorageConfig, "bucket">;

paginationToken?: string;

limit?: number;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `Omit&lt;TigrisStorageConfig, 'bucket'&gt;` | No |  |
| `paginationToken` | `string` | No |  |
| `limit` | `number` | No |  |

### `ListBucketSnapshotsResponse` [​](/content/docs/sdks/tigris/api/\#listbucketsnapshotsresponse "Direct link to listbucketsnapshotsresponse"/index.html)

```ts
type ListBucketSnapshotsResponse = {

snapshots: BucketSnapshot[];

paginationToken?: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `snapshots` | `BucketSnapshot[]` | Yes |  |
| `paginationToken` | `string` | No |  |

## Multipart Upload [​](/content/docs/sdks/tigris/api/\#multipart-upload "Direct link to Multipart Upload"/index.html)

Low-level multipart upload operations for advanced use cases.

### `initMultipartUpload` [​](/content/docs/sdks/tigris/api/\#initmultipartupload "Direct link to initmultipartupload"/index.html)

```ts
function initMultipartUpload(

path: string,

options?: InitMultipartUploadOptions,

): Promise<TigrisStorageResponse<InitMultipartUploadResponse, Error>>;
```

### `getPartsPresignedUrls` [​](/content/docs/sdks/tigris/api/\#getpartspresignedurls "Direct link to getpartspresignedurls"/index.html)

```ts
function getPartsPresignedUrls(

path: string,

parts: number[],

uploadId: string,

options?: GetPartsPresignedUrlsOptions,

): Promise<TigrisStorageResponse<GetPartsPresignedUrlsResponse, Error>>;
```

### `completeMultipartUpload` [​](/content/docs/sdks/tigris/api/\#completemultipartupload "Direct link to completemultipartupload"/index.html)

```ts
function completeMultipartUpload(

path: string,

uploadId: string,

partIds: Array<{

[key: number]: string;

}>,

options?: CompleteMultipartUploadOptions,

): Promise<TigrisStorageResponse<CompleteMultipartUploadResponse, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-6 "Direct link to Types"/index.html)

### `InitMultipartUploadOptions` [​](/content/docs/sdks/tigris/api/\#initmultipartuploadoptions "Direct link to initmultipartuploadoptions"/index.html)

```ts
type InitMultipartUploadOptions = {

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |

### `InitMultipartUploadResponse` [​](/content/docs/sdks/tigris/api/\#initmultipartuploadresponse "Direct link to initmultipartuploadresponse"/index.html)

```ts
type InitMultipartUploadResponse = {

uploadId: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `uploadId` | `string` | Yes |  |

### `GetPartsPresignedUrlsOptions` [​](/content/docs/sdks/tigris/api/\#getpartspresignedurlsoptions "Direct link to getpartspresignedurlsoptions"/index.html)

```ts
type GetPartsPresignedUrlsOptions = {

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |

### `GetPartsPresignedUrlsResponse` [​](/content/docs/sdks/tigris/api/\#getpartspresignedurlsresponse "Direct link to getpartspresignedurlsresponse"/index.html)

```ts
type GetPartsPresignedUrlsResponse = Array<{

part: number;

url: string;

}>;
```

### `CompleteMultipartUploadOptions` [​](/content/docs/sdks/tigris/api/\#completemultipartuploadoptions "Direct link to completemultipartuploadoptions"/index.html)

```ts
type CompleteMultipartUploadOptions = {

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `config` | `TigrisStorageConfig` | No |  |

### `CompleteMultipartUploadResponse` [​](/content/docs/sdks/tigris/api/\#completemultipartuploadresponse "Direct link to completemultipartuploadresponse"/index.html)

```ts
type CompleteMultipartUploadResponse = {

path: string;

url: string;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `path` | `string` | Yes |  |
| `url` | `string` | Yes |  |

## Client Upload Handling [​](/content/docs/sdks/tigris/api/\#client-upload-handling "Direct link to Client Upload Handling"/index.html)

Server-side handler for processing client upload requests (pairs with the Client
API `upload` function).

### `handleClientUpload` [​](/content/docs/sdks/tigris/api/\#handleclientupload "Direct link to handleclientupload"/index.html)

```ts
function handleClientUpload(

request: ClientUploadRequest,

config?: TigrisStorageConfig,

): Promise<TigrisStorageResponse<unknown, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-7 "Direct link to Types"/index.html)

### `ClientUploadRequest` [​](/content/docs/sdks/tigris/api/\#clientuploadrequest "Direct link to clientuploadrequest"/index.html)

```ts
interface ClientUploadRequest {

action: UploadAction;

name: string;

/** @deprecated This property is no longer used by the server handler. Will be removed in the next major version. */

contentType?: string;

uploadId?: string;

parts?: number[];

partIds?: Array<{

[key: number]: string;

}>;

}
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `action` | `UploadAction` | Yes |  |
| `name` | `string` | Yes |  |
| `contentType` | `string` | No | **Deprecated.** This property is no longer used by the server handler. Will be removed in the next major version. |
| `uploadId` | `string` | No |  |
| `parts` | `number[]` | No |  |
| `partIds` | `Array&lt;\{ [key: number]: string; \}&gt;` | No |  |

### `UploadAction` [​](/content/docs/sdks/tigris/api/\#uploadaction "Direct link to uploadaction"/index.html)

```ts
enum UploadAction {

SinglepartInit = "singlepart-init",

MultipartInit = "multipart-init",

MultipartGetParts = "multipart-get-parts",

MultipartComplete = "multipart-complete",

}
```

## Statistics [​](/content/docs/sdks/tigris/api/\#statistics "Direct link to Statistics"/index.html)

Retrieve account and bucket-level storage statistics.

### `getStats` [​](/content/docs/sdks/tigris/api/\#getstats "Direct link to getstats"/index.html)

```ts
function getStats(

options?: GetStatsOptions,

): Promise<TigrisStorageResponse<StatsResponse, Error>>;
```

#### Types [​](/content/docs/sdks/tigris/api/\#types-8 "Direct link to Types"/index.html)

### `GetStatsOptions` [​](/content/docs/sdks/tigris/api/\#getstatsoptions "Direct link to getstatsoptions"/index.html)

```ts
type GetStatsOptions = {

paginationToken?: string;

config?: TigrisStorageConfig;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `paginationToken` | `string` | No |  |
| `config` | `TigrisStorageConfig` | No |  |

### `StatsResponse` [​](/content/docs/sdks/tigris/api/\#statsresponse "Direct link to statsresponse"/index.html)

```ts
type StatsResponse = {

paginationToken?: string;

stats: BucketsStats;

buckets: Bucket[];

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `paginationToken` | `string` | No |  |
| `stats` | `BucketsStats` | Yes |  |
| `buckets` | `Bucket[]` | Yes |  |

### `BucketType` [​](/content/docs/sdks/tigris/api/\#buckettype "Direct link to buckettype"/index.html)

```ts
type BucketType = "Regular" | "Snapshot";
```

### `BucketVisibility` [​](/content/docs/sdks/tigris/api/\#bucketvisibility "Direct link to bucketvisibility"/index.html)

```ts
type BucketVisibility = "public" | "private";
```

## Common Types [​](/content/docs/sdks/tigris/api/\#common-types "Direct link to Common Types"/index.html)

Shared configuration and response types used across all API methods.

#### Types [​](/content/docs/sdks/tigris/api/\#types-9 "Direct link to Types"/index.html)

### `TigrisStorageConfig` [​](/content/docs/sdks/tigris/api/\#tigrisstorageconfig "Direct link to tigrisstorageconfig"/index.html)

```ts
type TigrisStorageConfig = {

bucket?: string;

forcePathStyle?: boolean;

} & TigrisConfig;
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `bucket` | `string` | No |  |
| `forcePathStyle` | `boolean` | No |  |

### `TigrisStorageResponse` [​](/content/docs/sdks/tigris/api/\#tigrisstorageresponse "Direct link to tigrisstorageresponse"/index.html)

```ts
type TigrisStorageResponse<T, E = Error> = TigrisResponse<T, E>;
```

### `TigrisResponse` [​](/content/docs/sdks/tigris/api/\#tigrisresponse "Direct link to tigrisresponse"/index.html)

```ts
type TigrisResponse<T, E = Error> =

| {

data: T;

error?: never;

}

| {

error: E;

data?: never;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `data` | `T` | Yes |  |
| `error` | `never` | No |  |
| `error` | `E` | Yes |  |
| `data` | `never` | No |  |

### `StorageClass` [​](/content/docs/sdks/tigris/api/\#storageclass "Direct link to storageclass"/index.html)

```ts
type StorageClass = "STANDARD" | "STANDARD_IA" | "GLACIER" | "GLACIER_IR";
```

### `BucketLocations` [​](/content/docs/sdks/tigris/api/\#bucketlocations "Direct link to bucketlocations"/index.html)

```ts
type BucketLocations =

| {

type: "multi";

values: BucketLocationMulti;

}

| {

type: "dual";

values: BucketLocationDualOrSingle | BucketLocationDualOrSingle[];

}

| {

type: "single";

values: BucketLocationDualOrSingle;

}

| {

type: "global";

values?: never;

};
```

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `type` | `'multi'` | Yes |  |
| `values` | `BucketLocationMulti` | Yes |  |
| `type` | `'dual'` | Yes |  |
| `values` | `BucketLocationDualOrSingle | BucketLocationDualOrSingle[]` | Yes |  |
| `type` | `'single'` | Yes |  |
| `values` | `BucketLocationDualOrSingle` | Yes |  |
| `type` | `'global'` | Yes |  |
| `values` | `never` | No |  |

### `BucketLocationMulti` [​](/content/docs/sdks/tigris/api/\#bucketlocationmulti "Direct link to bucketlocationmulti"/index.html)

```ts
type BucketLocationMulti = (typeof multiRegions)[number];
```

### `BucketLocationDualOrSingle` [​](/content/docs/sdks/tigris/api/\#bucketlocationdualorsingle "Direct link to bucketlocationdualorsingle"/index.html)

```ts
type BucketLocationDualOrSingle = (typeof singleOrDualRegions)[number];
```

### `multiRegions` [​](/content/docs/sdks/tigris/api/\#multiregions "Direct link to multiregions"/index.html)

```ts
const multiRegions: readonly ["usa", "eur"];
```

### `singleOrDualRegions` [​](/content/docs/sdks/tigris/api/\#singleordualregions "Direct link to singleordualregions"/index.html)

```ts
const singleOrDualRegions: readonly [\
\
  "ams",\
\
  "fra",\
\
  "gru",\
\
  "iad",\
\
  "jnb",\
\
  "lhr",\
\
  "nrt",\
\
  "ord",\
\
  "sin",\
\
  "sjc",\
\
  "syd",\
\
];
```

- [Contents](/content/docs/sdks/tigris/api/#contents/index.html)
- [Client API](/content/docs/sdks/tigris/api/#client-api/index.html)
  - [`upload`](/content/docs/sdks/tigris/api/#upload/index.html)
  - [`executeWithConcurrency`](/content/docs/sdks/tigris/api/#executewithconcurrency/index.html)
  - [`UploadOptions`](/content/docs/sdks/tigris/api/#uploadoptions/index.html)
  - [`UploadProgress`](/content/docs/sdks/tigris/api/#uploadprogress/index.html)
  - [`UploadResponse`](/content/docs/sdks/tigris/api/#uploadresponse/index.html)
- [Object Operations](/content/docs/sdks/tigris/api/#object-operations/index.html)
  - [`put`](/content/docs/sdks/tigris/api/#put/index.html)
  - [`get`](/content/docs/sdks/tigris/api/#get/index.html)
  - [`head`](/content/docs/sdks/tigris/api/#head/index.html)
  - [`list`](/content/docs/sdks/tigris/api/#list/index.html)
  - [`remove`](/content/docs/sdks/tigris/api/#remove/index.html)
  - [`updateObject`](/content/docs/sdks/tigris/api/#updateobject/index.html)
  - [`PutOptions`](/content/docs/sdks/tigris/api/#putoptions/index.html)
  - [`PutResponse`](/content/docs/sdks/tigris/api/#putresponse/index.html)
  - [`PutOnUploadProgress`](/content/docs/sdks/tigris/api/#putonuploadprogress/index.html)
  - [`GetOptions`](/content/docs/sdks/tigris/api/#getoptions/index.html)
  - [`GetResponse`](/content/docs/sdks/tigris/api/#getresponse/index.html)
  - [`HeadOptions`](/content/docs/sdks/tigris/api/#headoptions/index.html)
  - [`HeadResponse`](/content/docs/sdks/tigris/api/#headresponse/index.html)
  - [`ListOptions`](/content/docs/sdks/tigris/api/#listoptions/index.html)
  - [`ListItem`](/content/docs/sdks/tigris/api/#listitem/index.html)
  - [`ListResponse`](/content/docs/sdks/tigris/api/#listresponse/index.html)
  - [`RemoveOptions`](/content/docs/sdks/tigris/api/#removeoptions/index.html)
  - [`UpdateObjectOptions`](/content/docs/sdks/tigris/api/#updateobjectoptions/index.html)
  - [`UpdateObjectResponse`](/content/docs/sdks/tigris/api/#updateobjectresponse/index.html)
- [Presigned URLs](/content/docs/sdks/tigris/api/#presigned-urls/index.html)
  - [`getPresignedUrl`](/content/docs/sdks/tigris/api/#getpresignedurl/index.html)
  - [`GetPresignedUrlOptions`](/content/docs/sdks/tigris/api/#getpresignedurloptions/index.html)
  - [`GetPresignedUrlResponse`](/content/docs/sdks/tigris/api/#getpresignedurlresponse/index.html)
  - [`GetPresignedUrlOperation`](/content/docs/sdks/tigris/api/#getpresignedurloperation/index.html)
  - [`MethodOrOperation`](/content/docs/sdks/tigris/api/#methodoroperation/index.html)
- [Bucket Management](/content/docs/sdks/tigris/api/#bucket-management/index.html)
  - [`createBucket`](/content/docs/sdks/tigris/api/#createbucket/index.html)
  - [`getBucketInfo`](/content/docs/sdks/tigris/api/#getbucketinfo/index.html)
  - [`listBuckets`](/content/docs/sdks/tigris/api/#listbuckets/index.html)
  - [`updateBucket`](/content/docs/sdks/tigris/api/#updatebucket/index.html)
  - [`removeBucket`](/content/docs/sdks/tigris/api/#removebucket/index.html)
  - [`CreateBucketOptions`](/content/docs/sdks/tigris/api/#createbucketoptions/index.html)
  - [`CreateBucketResponse`](/content/docs/sdks/tigris/api/#createbucketresponse/index.html)
  - [`GetBucketInfoOptions`](/content/docs/sdks/tigris/api/#getbucketinfooptions/index.html)
  - [`BucketInfoResponse`](/content/docs/sdks/tigris/api/#bucketinforesponse/index.html)
  - [`ListBucketsOptions`](/content/docs/sdks/tigris/api/#listbucketsoptions/index.html)
  - [`ListBucketsResponse`](/content/docs/sdks/tigris/api/#listbucketsresponse/index.html)
  - [`Bucket`](/content/docs/sdks/tigris/api/#bucket/index.html)
  - [`BucketOwner`](/content/docs/sdks/tigris/api/#bucketowner/index.html)
  - [`UpdateBucketOptions`](/content/docs/sdks/tigris/api/#updatebucketoptions/index.html)
  - [`UpdateBucketResponse`](/content/docs/sdks/tigris/api/#updatebucketresponse/index.html)
  - [`RemoveBucketOptions`](/content/docs/sdks/tigris/api/#removebucketoptions/index.html)
- [Bucket Configuration](/content/docs/sdks/tigris/api/#bucket-configuration/index.html)
  - [`setBucketCors`](/content/docs/sdks/tigris/api/#setbucketcors/index.html)
  - [`setBucketLifecycle`](/content/docs/sdks/tigris/api/#setbucketlifecycle/index.html)
  - [`setBucketTtl`](/content/docs/sdks/tigris/api/#setbucketttl/index.html)
  - [`setBucketMigration`](/content/docs/sdks/tigris/api/#setbucketmigration/index.html)
  - [`setBucketNotifications`](/content/docs/sdks/tigris/api/#setbucketnotifications/index.html)
  - [`SetBucketCorsOptions`](/content/docs/sdks/tigris/api/#setbucketcorsoptions/index.html)
  - [`SetBucketLifecycleOptions`](/content/docs/sdks/tigris/api/#setbucketlifecycleoptions/index.html)
  - [`SetBucketTtlOptions`](/content/docs/sdks/tigris/api/#setbucketttloptions/index.html)
  - [`SetBucketMigrationOptions`](/content/docs/sdks/tigris/api/#setbucketmigrationoptions/index.html)
  - [`SetBucketNotificationsOptions`](/content/docs/sdks/tigris/api/#setbucketnotificationsoptions/index.html)
  - [`BucketCorsRule`](/content/docs/sdks/tigris/api/#bucketcorsrule/index.html)
  - [`BucketLifecycleRule`](/content/docs/sdks/tigris/api/#bucketlifecyclerule/index.html)
  - [`BucketTtl`](/content/docs/sdks/tigris/api/#bucketttl/index.html)
  - [`BucketMigration`](/content/docs/sdks/tigris/api/#bucketmigration/index.html)
  - [`BucketNotification`](/content/docs/sdks/tigris/api/#bucketnotification/index.html)
  - [`BucketNotificationBase`](/content/docs/sdks/tigris/api/#bucketnotificationbase/index.html)
  - [`BucketNotificationBasicAuth`](/content/docs/sdks/tigris/api/#bucketnotificationbasicauth/index.html)
  - [`BucketNotificationTokenAuth`](/content/docs/sdks/tigris/api/#bucketnotificationtokenauth/index.html)
- [Snapshots](/content/docs/sdks/tigris/api/#snapshots/index.html)
  - [`createBucketSnapshot`](/content/docs/sdks/tigris/api/#createbucketsnapshot/index.html)
  - [`listBucketSnapshots`](/content/docs/sdks/tigris/api/#listbucketsnapshots/index.html)
  - [`CreateBucketSnapshotOptions`](/content/docs/sdks/tigris/api/#createbucketsnapshotoptions/index.html)
  - [`CreateBucketSnapshotResponse`](/content/docs/sdks/tigris/api/#createbucketsnapshotresponse/index.html)
  - [`ListBucketSnapshotsOptions`](/content/docs/sdks/tigris/api/#listbucketsnapshotsoptions/index.html)
  - [`ListBucketSnapshotsResponse`](/content/docs/sdks/tigris/api/#listbucketsnapshotsresponse/index.html)
- [Multipart Upload](/content/docs/sdks/tigris/api/#multipart-upload/index.html)
  - [`initMultipartUpload`](/content/docs/sdks/tigris/api/#initmultipartupload/index.html)
  - [`getPartsPresignedUrls`](/content/docs/sdks/tigris/api/#getpartspresignedurls/index.html)
  - [`completeMultipartUpload`](/content/docs/sdks/tigris/api/#completemultipartupload/index.html)
  - [`InitMultipartUploadOptions`](/content/docs/sdks/tigris/api/#initmultipartuploadoptions/index.html)
  - [`InitMultipartUploadResponse`](/content/docs/sdks/tigris/api/#initmultipartuploadresponse/index.html)
  - [`GetPartsPresignedUrlsOptions`](/content/docs/sdks/tigris/api/#getpartspresignedurlsoptions/index.html)
  - [`GetPartsPresignedUrlsResponse`](/content/docs/sdks/tigris/api/#getpartspresignedurlsresponse/index.html)
  - [`CompleteMultipartUploadOptions`](/content/docs/sdks/tigris/api/#completemultipartuploadoptions/index.html)
  - [`CompleteMultipartUploadResponse`](/content/docs/sdks/tigris/api/#completemultipartuploadresponse/index.html)
- [Client Upload Handling](/content/docs/sdks/tigris/api/#client-upload-handling/index.html)
  - [`handleClientUpload`](/content/docs/sdks/tigris/api/#handleclientupload/index.html)
  - [`ClientUploadRequest`](/content/docs/sdks/tigris/api/#clientuploadrequest/index.html)
  - [`UploadAction`](/content/docs/sdks/tigris/api/#uploadaction/index.html)
- [Statistics](/content/docs/sdks/tigris/api/#statistics/index.html)
  - [`getStats`](/content/docs/sdks/tigris/api/#getstats/index.html)
  - [`GetStatsOptions`](/content/docs/sdks/tigris/api/#getstatsoptions/index.html)
  - [`StatsResponse`](/content/docs/sdks/tigris/api/#statsresponse/index.html)
  - [`BucketType`](/content/docs/sdks/tigris/api/#buckettype/index.html)
  - [`BucketVisibility`](/content/docs/sdks/tigris/api/#bucketvisibility/index.html)
- [Common Types](/content/docs/sdks/tigris/api/#common-types/index.html)
  - [`TigrisStorageConfig`](/content/docs/sdks/tigris/api/#tigrisstorageconfig/index.html)
  - [`TigrisStorageResponse`](/content/docs/sdks/tigris/api/#tigrisstorageresponse/index.html)
  - [`TigrisResponse`](/content/docs/sdks/tigris/api/#tigrisresponse/index.html)
  - [`StorageClass`](/content/docs/sdks/tigris/api/#storageclass/index.html)
  - [`BucketLocations`](/content/docs/sdks/tigris/api/#bucketlocations/index.html)
  - [`BucketLocationMulti`](/content/docs/sdks/tigris/api/#bucketlocationmulti/index.html)
  - [`BucketLocationDualOrSingle`](/content/docs/sdks/tigris/api/#bucketlocationdualorsingle/index.html)
  - [`multiRegions`](/content/docs/sdks/tigris/api/#multiregions/index.html)
  - [`singleOrDualRegions`](/content/docs/sdks/tigris/api/#singleordualregions/index.html)
