Astlide API Reference
    Preparing search index...

    Interface ObjectStorage

    Where a template store keeps its files: keys like acme/manifest.json and acme/v2.potx. Astlide has one for a folder, S3, Google Cloud Storage and Azure Blob Storage; implement it for any other storage.

    interface ObjectStorage {
        delete(key: string): Promise<void>;
        list(prefix: string): Promise<string[]>;
        read(key: string): Promise<Uint8Array<ArrayBufferLike> | undefined>;
        write(key: string, data: Uint8Array): Promise<void>;
    }
    Index
    • The object's bytes, or undefined when there is none.

      Parameters

      • key: string

      Returns Promise<Uint8Array<ArrayBufferLike> | undefined>

    • Create or replace an object, all at once (a reader never sees half of it).

      Parameters

      • key: string
      • data: Uint8Array

      Returns Promise<void>