import { CreationOptional, DataTypes, InferAttributes, InferCreationAttributes } from 'sequelize'; import type { LiteralUnion } from 'type-fest'; import { TenantModel } from '../tenant-model'; import type { AfterPayment, CustomField, DonationSettings, LineItem, NftMintSettings, PaymentIntentData, SubscriptionData } from './types'; export declare const nextPaymentLinkId: (size?: number) => string; export declare class PaymentLink extends TenantModel, InferCreationAttributes> { id: CreationOptional; active: boolean; livemode: boolean; instance_did?: string; name: string; line_items: LineItem[]; currency_id: string; after_completion?: AfterPayment; allow_promotion_codes: boolean; consent_collection?: { promotions?: LiteralUnion<'auto' | 'none', string>; terms_of_service?: LiteralUnion<'required' | 'none', string>; }; custom_fields: CustomField[]; custom_text?: { shipping_address?: string; submit?: string; }; customer_creation: LiteralUnion<'if_required' | 'always', string>; invoice_creation?: { enabled: boolean; invoice_data?: any; }; payment_method_types?: string[]; phone_number_collection?: { enabled: boolean; }; billing_address_collection?: LiteralUnion<'auto' | 'required', string>; submit_type: LiteralUnion<'auto' | 'book' | 'donate' | 'pay', string>; subscription_data?: SubscriptionData; nft_mint_settings?: NftMintSettings; cross_sell_behavior?: LiteralUnion<'auto' | 'required', string>; donation_settings?: DonationSettings; metadata?: Record; payment_intent_data?: PaymentIntentData; enable_subscription_grouping?: boolean; lookup_key: string | null; created_at: CreationOptional; created_via: LiteralUnion<'api' | 'dashboard' | 'portal', string>; updated_at: CreationOptional; static readonly GENESIS_ATTRIBUTES: { id: { type: DataTypes.StringDataType; primaryKey: boolean; allowNull: boolean; defaultValue: (size?: number) => string; }; active: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; livemode: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; line_items: { type: DataTypes.AbstractDataTypeConstructor; defaultValue: never[]; }; name: { type: DataTypes.StringDataType; allowNull: boolean; }; currency_id: { type: DataTypes.StringDataType; allowNull: boolean; }; after_completion: { type: DataTypes.AbstractDataTypeConstructor; defaultValue: { type: string; }; }; allow_promotion_codes: { type: DataTypes.AbstractDataTypeConstructor; defaultValue: boolean; }; consent_collection: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; custom_fields: { type: DataTypes.AbstractDataTypeConstructor; defaultValue: never[]; }; custom_text: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; customer_creation: { type: DataTypes.EnumDataType<"if_required" | "always">; allowNull: boolean; }; invoice_creation: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; payment_method_types: { type: DataTypes.AbstractDataTypeConstructor; defaultValue: never[]; }; phone_number_collection: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; billing_address_collection: { type: DataTypes.EnumDataType<"auto" | "required">; defaultValue: string; allowNull: boolean; }; submit_type: { type: DataTypes.EnumDataType<"auto" | "book" | "donate" | "pay">; allowNull: boolean; }; subscription_data: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; metadata: { type: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; created_at: { type: DataTypes.DateDataTypeConstructor; defaultValue: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; created_via: { type: DataTypes.EnumDataType<"api" | "dashboard" | "portal">; }; updated_at: { type: DataTypes.DateDataTypeConstructor; defaultValue: DataTypes.AbstractDataTypeConstructor; allowNull: boolean; }; }; static initialize(sequelize: any): void; static associate(models: any): void; static insert(paymentLink: InferCreationAttributes): Promise; static findByPkOrLookupKey(id: string, options?: any): Promise; } export type TPaymentLink = InferAttributes;