@pwngh/economy-lab
    Preparing search index...

    Interface Processor

    External payment provider: all money leaving the platform goes through this.

    Processor for the seam, the Tilia adapter, and dispute webhooks.

    interface Processor {
        payoutStatus?(
            input: { providerRef: string },
            options?: CallOptions,
        ): Promise<PayoutProviderStatus>;
        submitPayout(
            input: { amount: Amount; key: string; userId: string },
            options?: CallOptions,
        ): Promise<{ providerRef: string }>;
    }
    Index
    • Optional evidence probe the sweep consults before force-failing a silent payout: FAILED or RETURNED releases the reserve early, SETTLED blocks the force-fail (a lost webhook can't double-pay), PENDING defers the timeout; absent, webhook plus timeout are the whole protocol.

      Parameters

      • input: { providerRef: string }
      • Optionaloptions: CallOptions

      Returns Promise<PayoutProviderStatus>

    • Submits a USD transfer to the provider. amount is in real USD; key makes the request safe to retry without paying twice. The returned providerRef is the provider's own id for the transfer — webhooks and the payoutStatus probe join back to the saga through it.

      Parameters

      Returns Promise<{ providerRef: string }>