UNPKG

@apihawk/billia-sdk

Version:

The ApiHawk Billia SDK

109 lines 3.13 kB
import { ICatalogOption, ICatalogProduct } from './billia-sdk.types'; import { IDiscountProductEntity, IDiscountPromocodeEntity } from './billia-sdk-affiliate.types'; export declare type ICustomerProductStatus = 'inactive' | 'active' | 'pending' | 'expired' | 'suspended' | 'terminated' | 'redemption' | 'pending.error' | 'configure'; export interface ICustomerProductBase { customer_product_id: number; trash: number; descriptor: string; status: ICustomerProductStatus; billing_type: string; product_id: number; module: string; product_type: string; parent_product_id: number | string; user_id: number; customer_profile_id: number; quantity: number; create_date: string; activate_date: string; next_due_date: string; expire_date: string; suspend_date: string; redemption_date: string; terminate_date: string; auto_renew: string; } export interface ICustomerProduct extends ICustomerProductBase { price: { unit_price: number; install_price: number; redemption_price: number; amount: number; quantity: number; quantity_type: number; tax: { amount_without_tax: number; amount: number; country_code: string; percent: number; tax_included: boolean; }; display: { amount: number; unit_price: number; }; _currency: { currency: string; convertedFrom: string; rate: number; }; total?: { amount: number; [key: string]: any; }; }; _links: any; _language: { translations: any; }; options?: ICustomerProductOption[]; discounts?: IDiscountProductEntity[]; product?: ICatalogProduct; _populated?: boolean; _settings?: any; hashedOptions?: any; } export interface ICustomerProductOption { customer_product_option_id: number; trash: number; customer_product_id: number; catalog_option_id: number; catalog_choice_id: number | string; value: string; user_id: number; option?: ICatalogOption; choice?: any; state: string; previous: string; } export interface ICustomerProductDiscount { discount: string; hook: string; id: string; item_type: string; min_quantity: string; max_quantity: string; product_id: string; type: string; trash?: number | string; code_details?: IDiscountPromocodeEntity[]; } export interface ICustomerProductNote { note_id: number | string; route: string; identifier: number | string; create_date: string; update_date: string; note: string; visible_for_resource_owner: number; history_note_id: number | string; user_id: number | string; reseller: string; trash?: number | string; _language?: { translations: any; }; history?: ICustomerProductNote[]; } export declare type IExpiringProductsPeriod = 'week' | 'month' | 'quarter'; //# sourceMappingURL=billia-sdk-customer-product.types.d.ts.map