export interface WalletKeypair { publicKey: Uint8Array; secretKey: Uint8Array; } export interface SignupResponse { token: string; refId: string; newUser: boolean; } export interface Subscription { id: string; plan: string; billingPeriodStart: string; billingPeriodEnd: string; cryptoSub: boolean; paymentServiceProvider: string; } export interface User { id: string; name: string; email: string; role: string; } export interface DnsRecord { id: string; dns: string; network: string; usageType: string; } export interface ApiKey { keyId: string; keyName: string; walletId: string; projectId: string; usagePlan: string; createdAt: number; prepaidCredits: number; } export interface CreditsUsage { totalCreditsUsed: number; remainingCredits: number; remainingPrepaidCredits: number; prepaidCreditsUsed: number; overageCreditsUsed: number; overageCost: number; webhookUsage: number; apiUsage: number; rpcUsage: number; rpcGPAUsage: number; } export interface BillingCycle { start: string; end: string; } export interface SubscriptionPlanDetails { currentPlan: string; upcomingPlan: string; isUpgrading: boolean; } export interface ProjectListItem { id: string; name: string; createdAt: string; verifiedEmail: string | null; subscription: Subscription; users: User[]; dnsRecords: DnsRecord[]; } export interface ProjectDetails { apiKeys: ApiKey[]; creditsUsage: CreditsUsage; billingCycle: BillingCycle; subscriptionPlanDetails: SubscriptionPlanDetails; prepaidCreditsLink: string; } export interface Project extends ProjectListItem { apiKeys?: ApiKey[]; creditsUsage?: CreditsUsage; billingCycle?: BillingCycle; subscriptionPlanDetails?: SubscriptionPlanDetails; prepaidCreditsLink?: string; } export type PaymentIntentStatus = "pending" | "completed" | "expired" | "failed"; export type CheckoutPhase = "confirming" | "activating" | "complete" | "failed" | "expired"; export interface CheckoutRequest { plan: string; period: "monthly" | "yearly"; refId: string; email?: string; firstName?: string; lastName?: string; walletAddress?: string; couponCode?: string; } export interface CheckoutInitializeRequest { priceId: string; refId: string; email?: string; firstName?: string; lastName?: string; walletAddress?: string; couponCode?: string; } export interface CheckoutInitializeResponse { id: string; status: PaymentIntentStatus; amount: number; destinationWallet: string; solanaPayUrl: string; expiresAt: string; createdAt: string; priceId: string; refId: string; couponCode?: string; originalAmountCents?: number; discountAmountCents?: number; txSignature?: string; payerWallet?: string; confirmedAt?: string; failedAt?: string; failureReason?: string; } export interface CheckoutStatusResponse { status: PaymentIntentStatus; phase: CheckoutPhase; subscriptionActive: boolean; readyToRedirect: boolean; message: string; messageSecondary?: string; } export interface CheckoutPreviewCoupon { code: string; valid: boolean; percentOff?: number; amountOff?: number; description?: string; invalidReason?: string; } export interface CheckoutPreviewCustomerInfo { email: string; firstName: string; lastName: string; } export interface CheckoutPreviewResponse { planName: string; period: "monthly" | "yearly"; baseAmount: number; subtotal: number; appliedCredits: number; proratedCredits: number; discounts: number; dueToday: number; destinationWallet: string; note: string; coupon?: CheckoutPreviewCoupon | null; customerInfo?: CheckoutPreviewCustomerInfo; } export interface CheckoutResult { paymentIntentId: string; txSignature: string | null; status: "completed" | "expired" | "failed" | "timeout"; projectId?: string; apiKey?: string; error?: string; } export interface AgenticSignupOptions { secretKey: Uint8Array; userAgent?: string; plan?: string; period?: "monthly" | "yearly"; email?: string; firstName?: string; lastName?: string; couponCode?: string; } export interface AgenticSignupResult { status: "success" | "existing_project" | "upgraded"; jwt: string; walletAddress: string; projectId: string; apiKey: string | null; endpoints: { mainnet: string; devnet: string; } | null; credits: number | null; txSignature?: string; } export interface AuthClient { generateKeypair(): Promise<{ publicKey: Uint8Array; secretKey: Uint8Array; }>; loadKeypair(bytes: Uint8Array): WalletKeypair; getAddress(keypair: WalletKeypair): Promise; signAuthMessage(secretKey: Uint8Array): Promise<{ message: string; signature: string; }>; walletSignup(msg: string, sig: string, address: string): Promise; listProjects(jwt: string): Promise; createProject(jwt: string): Promise; getProject(jwt: string, id: string): Promise; createApiKey(jwt: string, projectId: string, wallet: string): Promise; checkSolBalance(address: string): Promise; checkUsdcBalance(address: string): Promise; payUSDC(secretKey: Uint8Array): Promise; initializeCheckout(jwt: string, request: CheckoutInitializeRequest): Promise; executeCheckout(secretKey: Uint8Array, jwt: string, request: CheckoutRequest): Promise; payWithMemo(secretKey: Uint8Array, treasury: string, amount: bigint, memo: string): Promise; agenticSignup(options: AgenticSignupOptions): Promise; getCheckoutPreview(jwt: string, plan: string, period: "monthly" | "yearly", refId: string, couponCode?: string): Promise; getPaymentIntent(jwt: string, paymentIntentId: string): Promise; getPaymentStatus(jwt: string, paymentIntentId: string): Promise; payPaymentIntent(secretKey: Uint8Array, intent: CheckoutInitializeResponse): Promise; executeUpgrade(secretKey: Uint8Array, jwt: string, plan: string, period: "monthly" | "yearly", projectId: string, couponCode?: string): Promise; executeRenewal(secretKey: Uint8Array, jwt: string, paymentIntentId: string): Promise; } //# sourceMappingURL=types.d.ts.map