Beignet API reference
    Preparing search index...

    Interface CreateUploadRouterOptions<Ctx>

    Options for createUploadRouter(...).

    interface CreateUploadRouterOptions<Ctx> {
        ctx: Ctx | (() => MaybePromise<Ctx>);
        id?: () => string;
        instrumentation?: ProviderInstrumentationTarget;
        signer?: UploadSignerPort;
        storage: StoragePort;
        uploads: readonly UploadDef<string, StandardSchema, Ctx, unknown>[];
    }

    Type Parameters

    • Ctx
    Index

    Properties

    ctx: Ctx | (() => MaybePromise<Ctx>)

    Request context value or lazy context factory.

    id?: () => string

    Optional upload id generator for tests or custom id policies.

    Optional instrumentation target used by devtools/provider watchers.

    Optional signer used to prepare direct upload instructions.

    storage: StoragePort

    Storage port used for server uploads and direct upload completion checks.

    uploads: readonly UploadDef<string, StandardSchema, Ctx, unknown>[]

    Upload definitions registered with this router.