prorm API Reference
    Preparing search index...

    Class S3Store

    Amazon S3 store, implementing the minimal NoSqlStore marker interface. Unlike the SQL dialects, there is no query(sql) — S3's operations are object-shaped (Put/Get/Delete/List/Head/Copy) and that shape is preserved here rather than forced into a SQL string.

    Implements

    Index
    name: "s3" = 's3'

    The name of the store (e.g. 'mongodb', 'redis', 'dynamodb')

    library: "@aws-sdk/client-s3" = '@aws-sdk/client-s3'

    The client library being used

    • PutObject — store an object's body (and optional metadata) under bucket/key.

      Parameters

      • bucket: string
      • key: string
      • body: unknown
      • options: PutObjectOptions = {}

      Returns Promise<PutObjectResult>

    • GetObject — fetch an object's body and metadata.

      Parameters

      • bucket: string
      • key: string

      Returns Promise<GetObjectResult>

    • DeleteObject — remove an object. Succeeds even if the key doesn't exist.

      Parameters

      • bucket: string
      • key: string

      Returns Promise<void>

    • ListObjectsV2 — list objects in bucket, optionally restricted to those whose key starts with prefix. A single call returns at most 1000 objects; use result.nextContinuationToken (via the raw client) to page beyond that.

      Parameters

      • bucket: string
      • Optionalprefix: string

      Returns Promise<ListObjectsResult>

    • HeadObject — fetch an object's metadata without its body. Throws (NotFound) if the object doesn't exist.

      Parameters

      • bucket: string
      • key: string

      Returns Promise<HeadObjectResult>

    • Whether an object exists, implemented via HeadObject. Returns false when S3 reports the object is missing (a NotFound / 404 error) rather than throwing; any other error (e.g. access denied) is re-thrown.

      Parameters

      • bucket: string
      • key: string

      Returns Promise<boolean>

    • CopyObject — server-side copy from srcBucket/srcKey to destBucket/destKey.

      Parameters

      • srcBucket: string
      • srcKey: string
      • destBucket: string
      • destKey: string

      Returns Promise<CopyObjectResult>