Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

StorageClient

import { StorageClient } from "https://esm.sh/@supabase/storage-js@2.89.0/dist/index.d.mts";
class StorageClient extends StorageBucketApi {
constructor(
url: string,
headers?: {
[key: string]: string;
}
,
fetch?: Fetch$1,
);
get vectors(): StorageVectorsClient;
get analytics(): StorageAnalyticsClient;
 
from(id: string): StorageFileApi;
}

§Extends

§
StorageBucketApi
[src]

§Constructors

§
new StorageClient(url: string, headers?: {
[key: string]: string;
}
, fetch?: Fetch$1, opts?: StorageClientOptions)
[src]

Creates a client for Storage buckets, files, analytics, and vectors.

@example
import { StorageClient } from '@supabase/storage-js'

const storage = new StorageClient('https://xyzcompany.supabase.co/storage/v1', {
  apikey: 'public-anon-key',
})
const avatars = storage.from('avatars')

§Properties

§
vectors: StorageVectorsClient readonly
[src]
§
analytics: StorageAnalyticsClient readonly
[src]

§Methods

§
from(id: string): StorageFileApi
[src]

Perform file operation in a bucket.

@param id

The bucket id to operate on.

@example
const avatars = supabase.storage.from('avatars')