import type { BillingInterval, BillingPlanId, PlanEntitlements } from '../plans/types';
import type { SubscriptionRepository, SubscriptionRecord } from '../subscriptions/store';
export interface MembershipState {
    userId: string;
    planId: BillingPlanId;
    interval: BillingInterval;
    status: SubscriptionRecord['status'];
    currentPeriodEnd: string;
    cancelAtPeriodEnd: boolean;
    trialEndsAt?: string | null;
    isPaid: boolean;
    active: boolean;
    entitlements: PlanEntitlements;
}
export interface MembershipSummary {
    userId: string;
    planId: BillingPlanId;
    interval: BillingInterval;
    status: SubscriptionRecord['status'];
    currentPeriodEnd: string;
    cancelAtPeriodEnd: boolean;
    trialEndsAt?: string | null;
    isPaid: boolean;
    active: boolean;
}
export interface MembershipContext {
    subscriptions: SubscriptionRepository;
}
export declare function toMembershipSummary(state: MembershipState): MembershipSummary;
export declare function getMembershipState(userId: string, context: MembershipContext): Promise<MembershipState | null>;
export declare function getMembershipSummary(userId: string, context: MembershipContext): Promise<MembershipSummary | null>;
