import type { FeedbackSubject, FeedbackOutcome, PortreeveOptions, ReviewResolvedEvent, VerdictOptions, VerdictRequest, VerdictResult } from "./types.js"; export declare class Portreeve { #private; constructor(secretKey: string, options?: PortreeveOptions); verdict(event: VerdictRequest, options?: VerdictOptions): Promise; /** * Report an outcome. The subject is what the report is ABOUT: pass an event * id string (shorthand for `{ kind: "event_id", value }`), or a * `{ kind, value }` subject — `external_user_id` for "this account charged * back" (the natural shape from a payment-provider dispute webhook), or * `email`. Back-office path — unlike verdict(), every failure throws * (silently losing abuse feedback would be worse than an exception here). */ feedback(subject: string | FeedbackSubject, outcome: FeedbackOutcome, note?: string): Promise; /** * Attach your account id to a past event — the late-binding path for stacks * whose auth provider mints the user id (Supabase, Auth0, Clerk, Firebase): * screen first, create the user, then attach the id the provider returned. * Write-once on the server: replaying the same value succeeds idempotently; * a different value throws with status 409. Like feedback(), every failure * throws — an unbound account would make a later denial unenforceable. */ attachUser(eventId: string, externalUserId: string): Promise; /** Verify and parse a `review.resolved` webhook. See webhook.ts for the scheme. */ static verifyWebhook(rawBody: string, signatureHeader: string, secret: string): ReviewResolvedEvent; /** Instance convenience — identical to the static method. */ verifyWebhook(rawBody: string, signatureHeader: string, secret: string): ReviewResolvedEvent; }