@accounter/server
Version:
Accounter GraphQL server
23 lines (22 loc) • 907 B
TypeScript
import { DBProvider } from '../../app-providers/db.provider.js';
export type PendingInvitation = {
id: string;
businessId: string;
businessName: string | null;
roleId: string;
expiresAt: Date;
};
/**
* Lists the invitations waiting for a caller who has no membership yet.
*
* Deliberately uses the raw pool rather than `TenantAwareDBClient`: the callers
* this exists for have no tenant at all, so the tenant-scoped client would throw
* UNAUTHENTICATED. That makes this a privileged read, and the only thing keeping
* it safe is the email filter — so every entry point must pass an address the
* identity provider has verified, never one supplied by the client.
*/
export declare class PendingInvitationsProvider {
private dbProvider;
constructor(dbProvider: DBProvider);
getPendingInvitationsByVerifiedEmail(verifiedEmail: string): Promise<PendingInvitation[]>;
}