@cfxlabsinc/b2b-services
    Preparing search index...

    Manage the per-customer origin allowlist and reconcile the aggregate allowlist onto the entity-document S3 buckets' CORS configuration.

    Hierarchy (View Summary)

    Index
    db: B2bDatabase
    instance: (...args: []) => CustomerOriginService = ...

    The process default: built from each dependency's own instance().

    • Push the aggregate origin allowlist (all customers' origins merged with the base origins) onto both entity-document buckets' CORS configuration.

      Standalone repair entrypoint: opens its own transaction, acquires the advisory lock, and reconciles. create/update/delete do NOT call this — they run the reconcile INLINE within their own mutation tx (via reconcileWithin) so the row write and the CORS write are atomic.

      Returns Promise<{ ok: true; value: { origins: string[] } }>

    • Parameters

      • __namedParameters: { customerId: string; origin?: string; page?: number; pageSize?: number }
        • customerId: string
        • Optionalorigin?: string

          Exact-match filter on the canonical origin

        • Optionalpage?: number

          Defaults to 1

        • OptionalpageSize?: number

          Defaults to 50

      Returns Promise<
          {
              ok: true;
              value: { hasNext: boolean; items: CustomerOrigin[]; total: number };
          },
      >

      The customer's allowlisted origins, ordered by origin, paginated.