81 lines
1.6 KiB
TypeScript
81 lines
1.6 KiB
TypeScript
export interface MerchantRegistration {
|
|
name: string;
|
|
email: string;
|
|
country: string;
|
|
companyInfo?: {
|
|
legalName?: string;
|
|
taxId?: string;
|
|
address?: string;
|
|
};
|
|
}
|
|
|
|
export interface MerchantResponse {
|
|
partnerId: string;
|
|
name: string;
|
|
email: string;
|
|
country: string;
|
|
apiKey: string;
|
|
secretKey: string;
|
|
status: 'PENDING' | 'ACTIVE' | 'SUSPENDED';
|
|
createdAt: string;
|
|
companyInfo?: {
|
|
legalName?: string;
|
|
taxId?: string;
|
|
address?: string;
|
|
};
|
|
}
|
|
|
|
export interface CallbackConfiguration {
|
|
headerEnrichment?: {
|
|
url?: string;
|
|
method?: 'GET' | 'POST';
|
|
headers?: { [key: string]: string };
|
|
};
|
|
subscription?: {
|
|
onCreate?: string;
|
|
onRenew?: string;
|
|
onCancel?: string;
|
|
onExpire?: string;
|
|
};
|
|
payment?: {
|
|
onSuccess?: string;
|
|
onFailure?: string;
|
|
onRefund?: string;
|
|
};
|
|
authentication?: {
|
|
onSuccess?: string;
|
|
onFailure?: string;
|
|
};
|
|
}
|
|
|
|
export interface MerchantStats {
|
|
totalTransactions: number;
|
|
successfulTransactions: number;
|
|
failedTransactions: number;
|
|
totalRevenue: number;
|
|
activeSubscriptions: number;
|
|
successRate: number;
|
|
monthlyGrowth: number;
|
|
}
|
|
|
|
export interface MerchantFormData {
|
|
companyInfo: {
|
|
name: string;
|
|
legalName: string;
|
|
taxId: string;
|
|
address: string;
|
|
country: string;
|
|
};
|
|
contactInfo: {
|
|
email: string;
|
|
phone: string;
|
|
firstName: string;
|
|
lastName: string;
|
|
};
|
|
paymentConfig: {
|
|
supportedOperators: string[];
|
|
defaultCurrency: string;
|
|
maxTransactionAmount: number;
|
|
};
|
|
webhookConfig: CallbackConfiguration;
|
|
} |