export interface AppPlans { /** App ID, as defined in the [app dashboard](https://dev.wix.com/apps/my-apps?viewId=active-apps-view). */ _id?: string; /** * List of the app's pricing plans. * * Min: `0` plans * Max: `50` plans */ plans?: Plan[]; } export declare enum SaleType { /** Default value, can be used when no specific sale is associated. */ SALE_TYPE_UNSPECIFIED = "SALE_TYPE_UNSPECIFIED", CYBER_MONDAY = "CYBER_MONDAY", NOVEMBER_SALE = "NOVEMBER_SALE", BLACK_FRIDAY = "BLACK_FRIDAY", DEVELOPER_SALE = "DEVELOPER_SALE" } export declare enum DiscountType { DISCOUNT_TYPE_UNSPECIFIED = "DISCOUNT_TYPE_UNSPECIFIED", /** Discount is a fixed amount in USD. */ FIXED_AMOUNT = "FIXED_AMOUNT", /** Discount is a percentage of the total price. */ PERCENTAGE = "PERCENTAGE" } export declare enum SourceType { /** Default value, can be used when no specific source is associated. */ SOURCE_TYPE_UNSPECIFIED = "SOURCE_TYPE_UNSPECIFIED", /** Discount is due to Wix/Developer Sale */ SALE = "SALE", /** Discount is due to App Benefit */ APP_BENEFIT = "APP_BENEFIT" } export interface SaleSource { saleId?: string | null; saleType?: SaleType; startDate?: Date | null; endDate?: Date | null; } export interface Cycle { /** * Type of the billing cycle. * * + `"UNKNOWN_UNIT"`: There is no information about the billing cycle. * + `"ONE_TIME"`: The customer pays for unlimited usage of the app with a single payment. * + `"RECURRING"`: The customer pays for a subscription to the app on a recurring schedule. */ cycleType?: CycleType; /** Duration of the billing cycle. Available only for `{"cycleType": "RECURRING"}`. */ cycleDuration?: Duration; } export declare enum DurationUnit { /** unknown interval unit */ UNKNOWN_UNIT = "UNKNOWN_UNIT", /** month */ MONTH = "MONTH", /** year */ YEAR = "YEAR" } export declare enum CycleType { UNKNOWN_TYPE = "UNKNOWN_TYPE", ONE_TIME = "ONE_TIME", RECURRING = "RECURRING" } export interface Duration { /** Unit of the billing cycle. */ unit?: DurationUnit; /** Count of units that make up the billing cycle. */ count?: number; } export interface UsageBasedDetails { /** * Smallest possible amount that your app charges customers in usage-based * pricing. For example, the price of a single SMS message if your * app charges customers for sending text messages. Always in * [USD](https://en.wikipedia.org/wiki/United_States_dollar). * * Min: `0.00` * Max: 1024 characters */ minimumChargeIncrement?: string | null; /** * Recurring, monthly base fee in usage-based pricing that your app * charges customers regardless of how much they use your app. * * Min: `0.00` * Max: 1024 characters */ monthlyBaseFee?: string | null; /** * Description of the usage-based pricing plan, as defined in the [app dashboard](https://dev.wix.com/apps/my-apps?viewId=active-apps-view). * * Max: 1024 characters */ customChargeDescription?: string | null; } export interface Discount extends DiscountSourceDataOneOf { type?: DiscountType; /** Discount amount */ amount?: string; /** * Price without taxes. For yearly plans, Wix calculates and returns the * average price per month. You can get the full price by multiplying the * returned price with 12. * Min: `0.00` * Max: 1024 characters */ priceBeforeTax?: string; /** * Total price including taxes. * Min: `0.00` * Max: 1024 characters */ totalPrice?: string; } /** @oneof */ export interface DiscountSourceDataOneOf { } export declare enum BillingSource { UNKNOWN = "UNKNOWN", /** plan billing and charges is managed by Wix */ WIX = "WIX", /** plan billing and charges is managed by the app */ EXTERNAL = "EXTERNAL" } export interface Price { /** * Price without taxes. For yearly plans, Wix calculates and returns the * average price per month. You can get the full price by multiplying the * returned price by 12. * * Min: `0.00` * Max: 1024 characters */ priceBeforeTax?: string; /** * Total price including taxes. * * Min: `0.00` * Max: 1024 characters */ totalPrice?: string; /** Information about the plan's recurring billing cycle or single payment. */ billingCycle?: Cycle; /** * Details about the plan's usage-based pricing. * Available only for plans with * [usage-based pricing](https://dev.wix.com/docs/build-apps/build-your-app/pricing-plans/usage-based-pricing). */ usageBaseOptions?: UsageBasedDetails; discount?: Discount; billingSource?: BillingSource; /** Can be shown instead of plan price - used for dynamic plans */ customPaymentTitle?: string | null; } export interface Plan { /** * ID of the app plan. * @readonly */ _id?: string; /** * ID of your app's pricing plan, as displayed in the [app dashboard](https://dev.wix.com/apps/my-apps?viewId=active-apps-view). * Identical to `vendorProductId` in the * [Paid Plan Purchased webhook](https://dev.wix.com/docs/rest/api-reference/app-management/apps/app-instance/paid-plan-purchased). */ vendorId?: string; /** Name of your app's pricing plan, as defined by you in the [app dashboard](https://dev.wix.com/apps/my-apps?viewId=active-apps-view). */ name?: string; /** * List of your plan's benefits, as defined by you in the [app dashboard](https://dev.wix.com/apps/my-apps?viewId=active-apps-view). * Currently, the benefits are available only in English. * * Min: `0` benefits * Max: `4` benefits * Max per benefit: 1024 characters */ benefits?: string[]; /** * List of the plan's prices. Available only when the plan's prices are managed * by Wix and not externally. * * Min: `0` prices * Max: `10` prices */ prices?: Price[]; } export interface ListAppPlansByAppIdRequest { /** * List of app IDs to retrieve plans for. * * Min: 1 app ID * Max: 100 app IDs */ appIds: string[]; } export interface ListAppPlansByAppIdResponse { /** * Tax settings. Wix calculates the tax settings based on the country code that * you pass in the call's header. If you don't pass a country code in the header, * Wix calculates the tax settings based on the caller's IP address. Note that the * tax settings may not resolve properly if you call through a VPN. */ taxSettings?: TaxSettings; /** * 3-letter currency code in [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) * format. Wix calculates the currency based on the country code that * you pass in the call's header. If you don't pass a country code in the header, * Wix calculates the currency based on the caller's IP address. Note that the * currency may not resolve properly if you call through a VPN. */ currency?: string; /** * Currency symbol in decimal HTML entity format. For example, `$` for $ * (United States Dollar). Wix calculates the currency symbol based on the * country code that you pass in the call's header. If you don't pass a country * code in the header, Wix calculates the tax settings based on the caller's IP * address. Note that the currency symbol may not resolve properly if you call * through a VPN. */ currencySymbol?: string; /** * Retrieved app plans. * * Min: 0 plans * Max: 50 plans * * If any plans aren't returned, it's likely because they haven't been activated yet. */ appPlans?: AppPlans[]; } export interface TaxSettings { /** * Whether you must display the total price including taxes in the given * country. */ showPriceWithTax?: boolean; /** * Tax rate for the given country as percentage. Returned as `0` when * `{"showPriceWithTax": false}`. */ percentage?: string | null; /** * Type of tax required in the given country. * * + `"NOT_APPLICABLE"`: The country doesn't require that you display the total price including taxes, or Wix failed to calculate the country based on the call's IP address. * + `"VAT"`: The given country requires that you display the total price including [value-added tax (VAT)](https://en.wikipedia.org/wiki/Value-added_tax). * + `"GST"`: The given country requires that you display the total price including [generation-skipping transfer tax (GST)](https://en.wikipedia.org/wiki/Generation-skipping_transfer_tax). */ taxType?: TaxType; } export declare enum TaxType { NOT_APPLICABLE = "NOT_APPLICABLE", VAT = "VAT", GST = "GST" } export interface GetAvailableAppPlansRequest { /** AppId to get the available app plans for. */ appId?: string; /** The specific app plan info to retrieve the available app plans for. */ appPlanInfo?: AppPlanInfo; } /** * An `AppPlanInfo` object describes which app plan you want to retrieve data for. * Every plan in an app is identified by a unique combination of `productId` and `billingCycle`. */ export interface AppPlanInfo { /** * The app plan's vendorId to retrieve the response for. * * Max: 100 characters */ vendorId?: string; /** The app plan cycle to retrieve the response for. */ billingCycle?: Cycle; } export interface GetAvailableAppPlansResponse { /** The available upgrades for the given app plan. */ availableUpgrades?: AppPlans; /** The available downgrades for the given app plan. */ availableDowngrades?: AppPlans; /** The current app plan. */ currentPlan?: Plan; } export interface GetPricingPageUrlRequest { /** AppId to get the pricing page url for. */ appId?: string; /** The specific app plan to retrieve the pricing page url for. */ appPlanInfo?: AppPlanInfo; } export interface GetPricingPageUrlResponse { /** the pricing page url, if there is a app plan that is upgradable. */ packagePickerUrl?: string | null; } interface TaxSettingsNonNullableFields { showPriceWithTax: boolean; taxType: TaxType; } interface DurationNonNullableFields { unit: DurationUnit; count: number; } interface CycleNonNullableFields { cycleType: CycleType; cycleDuration?: DurationNonNullableFields; } interface SaleSourceNonNullableFields { saleType: SaleType; } interface DiscountNonNullableFields { saleOptions?: SaleSourceNonNullableFields; type: DiscountType; amount: string; priceBeforeTax: string; totalPrice: string; sourceType: SourceType; } interface PriceNonNullableFields { priceBeforeTax: string; totalPrice: string; billingCycle?: CycleNonNullableFields; discount?: DiscountNonNullableFields; billingSource: BillingSource; } interface PlanNonNullableFields { _id: string; vendorId: string; name: string; benefits: string[]; prices: PriceNonNullableFields[]; } interface AppPlansNonNullableFields { _id: string; plans: PlanNonNullableFields[]; } export interface ListAppPlansByAppIdResponseNonNullableFields { taxSettings?: TaxSettingsNonNullableFields; currency: string; currencySymbol: string; appPlans: AppPlansNonNullableFields[]; } /** * Retrieves plans for the given apps. * * * Also returns tax settings and currency details. Wix calculates this information * based on the 2-letter country code in [ISO-3166 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements) * format that you pass in the call's header. If you don't pass a country code in * the header, Wix calculates the tax settings and currency details based on the * call's IP address. Note that the tax settings and currency details may not resolve * properly if you call through a VPN. * * Prices for plans that are managed outside of Wix aren't returned. * * Consumers must pay for yearly and multi-yearly plans of your app every month. * For these plans this endpoint returns the price that the consumer must pay every * month and not the total price for the entire year. * * > **Notes:** * > - The App Plans API doesn't follow any tenancy model. You don't need any permissions to call `List App Plans by App ID`. * > - This endpoint only returns app plans that have been activated. ([REST](https://dev.wix.com/docs/rest/app-management/app-billing/app-plans/introduction#before-you-begin)|[SDK](https://dev.wix.com/docs/sdk/backend-modules/app-management/app-plans/introduction)). * @param appIds - List of app IDs to retrieve plans for. * * Min: 1 app ID * Max: 100 app IDs * @public * @documentationMaturity preview * @requiredField appIds * @fqn wix.appmarket.app_plans.v1.AppsPlans.ListAppPlansByAppId */ export declare function listAppPlansByAppId(appIds: string[]): Promise; export {};