@wix/pricing-plans 1.0.72 → 1.0.73

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/pricing-plans",
3
- "version": "1.0.72",
3
+ "version": "1.0.73",
4
4
  "publishConfig": {
5
5
  "registry": "https://registry.npmjs.org/",
6
6
  "access": "public"
@@ -44,5 +44,5 @@
44
44
  "fqdn": ""
45
45
  }
46
46
  },
47
- "falconPackageHash": "666c52dae550fe0ceb9d3e3c094f94f0beaffbd81fc498e795f66846"
47
+ "falconPackageHash": "11e683b92efa7de5a684135926a7ba88550e7f0dac03fcc506464c13"
48
48
  }
@@ -1382,42 +1382,42 @@ interface ManagementListOrdersOptions {
1382
1382
  fieldSet?: Set;
1383
1383
  }
1384
1384
 
1385
- type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
1386
- interface HttpClient {
1387
- request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
1385
+ type RESTFunctionDescriptor$1<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$1) => T;
1386
+ interface HttpClient$1 {
1387
+ request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
1388
1388
  }
1389
- type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
1390
- type HttpResponse<T = any> = {
1389
+ type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
1390
+ type HttpResponse$1<T = any> = {
1391
1391
  data: T;
1392
1392
  status: number;
1393
1393
  statusText: string;
1394
1394
  headers: any;
1395
1395
  request?: any;
1396
1396
  };
1397
- type RequestOptions<_TResponse = any, Data = any> = {
1397
+ type RequestOptions$1<_TResponse = any, Data = any> = {
1398
1398
  method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
1399
1399
  url: string;
1400
1400
  data?: Data;
1401
1401
  params?: URLSearchParams;
1402
- } & APIMetadata;
1403
- type APIMetadata = {
1402
+ } & APIMetadata$1;
1403
+ type APIMetadata$1 = {
1404
1404
  methodFqn?: string;
1405
1405
  entityFqdn?: string;
1406
1406
  packageName?: string;
1407
1407
  };
1408
- type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
1409
- type EventDefinition<Payload = unknown, Type extends string = string> = {
1408
+ type BuildRESTFunction$1<T extends RESTFunctionDescriptor$1> = T extends RESTFunctionDescriptor$1<infer U> ? U : never;
1409
+ type EventDefinition$1<Payload = unknown, Type extends string = string> = {
1410
1410
  __type: 'event-definition';
1411
1411
  type: Type;
1412
1412
  isDomainEvent?: boolean;
1413
1413
  transformations?: unknown;
1414
1414
  __payload: Payload;
1415
1415
  };
1416
- declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
1417
- type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
1418
- type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
1416
+ declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
1417
+ type EventHandler$1<T extends EventDefinition$1> = (payload: T['__payload']) => void | Promise<void>;
1418
+ type BuildEventDefinition$1<T extends EventDefinition$1<any, string>> = (handler: EventHandler$1<T>) => void;
1419
1419
 
1420
- declare function memberGetOrder$1(httpClient: HttpClient): (_id: string, options?: MemberGetOrderOptions) => Promise<Order & {
1420
+ declare function memberGetOrder$1(httpClient: HttpClient$1): (_id: string, options?: MemberGetOrderOptions) => Promise<Order & {
1421
1421
  _id: string;
1422
1422
  planId: string;
1423
1423
  subscriptionId: string;
@@ -1501,58 +1501,58 @@ declare function memberGetOrder$1(httpClient: HttpClient): (_id: string, options
1501
1501
  planDescription: string;
1502
1502
  planPrice: string;
1503
1503
  }>;
1504
- declare function memberListOrders$1(httpClient: HttpClient): (options?: MemberListOrdersOptions) => Promise<MemberListOrdersResponse & MemberListOrdersResponseNonNullableFields>;
1505
- declare function requestCancellation$1(httpClient: HttpClient): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
1506
- declare function createOfflineOrder$1(httpClient: HttpClient): (planId: string, memberId: string, options?: CreateOfflineOrderOptions) => Promise<CreateOfflineOrderResponse & CreateOfflineOrderResponseNonNullableFields>;
1507
- declare function getOfflineOrderPreview$1(httpClient: HttpClient): (planId: string, memberId: string, options?: GetOfflineOrderPreviewOptions) => Promise<GetOfflineOrderPreviewResponse & GetOfflineOrderPreviewResponseNonNullableFields>;
1508
- declare function getPricePreview$1(httpClient: HttpClient): (planId: string, options?: GetPricePreviewOptions) => Promise<GetPricePreviewResponse & GetPricePreviewResponseNonNullableFields>;
1509
- declare function managementGetOrder$1(httpClient: HttpClient): (_id: string, options?: ManagementGetOrderOptions) => Promise<GetOrderResponse & GetOrderResponseNonNullableFields>;
1510
- declare function managementListOrders$1(httpClient: HttpClient): (options?: ManagementListOrdersOptions) => Promise<ListOrdersResponse & ListOrdersResponseNonNullableFields>;
1511
- declare function postponeEndDate$1(httpClient: HttpClient): (_id: string, endDate: Date) => Promise<void>;
1512
- declare function cancelOrder$1(httpClient: HttpClient): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
1513
- declare function markAsPaid$1(httpClient: HttpClient): (_id: string) => Promise<void>;
1514
- declare function pauseOrder$1(httpClient: HttpClient): (_id: string) => Promise<void>;
1515
- declare function resumeOrder$1(httpClient: HttpClient): (_id: string) => Promise<void>;
1516
- declare const onOrderCanceled$1: EventDefinition<OrderCanceledEnvelope, "wix.pricing_plans.v2.order_canceled">;
1517
- declare const onOrderCreated$1: EventDefinition<OrderCreatedEnvelope, "wix.pricing_plans.v2.order_created">;
1518
- declare const onOrderUpdated$1: EventDefinition<OrderUpdatedEnvelope, "wix.pricing_plans.v2.order_updated">;
1519
- declare const onOrderStartDateChanged$1: EventDefinition<OrderStartDateChangedEnvelope, "wix.pricing_plans.v2.order_start_date_changed">;
1520
- declare const onOrderPurchased$1: EventDefinition<OrderPurchasedEnvelope, "wix.pricing_plans.v2.order_purchased">;
1521
- declare const onOrderStarted$1: EventDefinition<OrderStartedEnvelope, "wix.pricing_plans.v2.order_started">;
1522
- declare const onOrderCycleStarted$1: EventDefinition<OrderCycleStartedEnvelope, "wix.pricing_plans.v2.order_cycle_started">;
1523
- declare const onOrderAutoRenewCanceled$1: EventDefinition<OrderAutoRenewCanceledEnvelope, "wix.pricing_plans.v2.order_auto_renew_canceled">;
1524
- declare const onOrderEnded$1: EventDefinition<OrderEndedEnvelope, "wix.pricing_plans.v2.order_ended">;
1525
- declare const onOrderEndDatePostponed$1: EventDefinition<OrderEndDatePostponedEnvelope, "wix.pricing_plans.v2.order_end_date_postponed">;
1526
- declare const onOrderMarkedAsPaid$1: EventDefinition<OrderMarkedAsPaidEnvelope, "wix.pricing_plans.v2.order_marked_as_paid">;
1527
- declare const onOrderPaused$1: EventDefinition<OrderPausedEnvelope, "wix.pricing_plans.v2.order_paused">;
1528
- declare const onOrderResumed$1: EventDefinition<OrderResumedEnvelope, "wix.pricing_plans.v2.order_resumed">;
1504
+ declare function memberListOrders$1(httpClient: HttpClient$1): (options?: MemberListOrdersOptions) => Promise<MemberListOrdersResponse & MemberListOrdersResponseNonNullableFields>;
1505
+ declare function requestCancellation$1(httpClient: HttpClient$1): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
1506
+ declare function createOfflineOrder$1(httpClient: HttpClient$1): (planId: string, memberId: string, options?: CreateOfflineOrderOptions) => Promise<CreateOfflineOrderResponse & CreateOfflineOrderResponseNonNullableFields>;
1507
+ declare function getOfflineOrderPreview$1(httpClient: HttpClient$1): (planId: string, memberId: string, options?: GetOfflineOrderPreviewOptions) => Promise<GetOfflineOrderPreviewResponse & GetOfflineOrderPreviewResponseNonNullableFields>;
1508
+ declare function getPricePreview$1(httpClient: HttpClient$1): (planId: string, options?: GetPricePreviewOptions) => Promise<GetPricePreviewResponse & GetPricePreviewResponseNonNullableFields>;
1509
+ declare function managementGetOrder$1(httpClient: HttpClient$1): (_id: string, options?: ManagementGetOrderOptions) => Promise<GetOrderResponse & GetOrderResponseNonNullableFields>;
1510
+ declare function managementListOrders$1(httpClient: HttpClient$1): (options?: ManagementListOrdersOptions) => Promise<ListOrdersResponse & ListOrdersResponseNonNullableFields>;
1511
+ declare function postponeEndDate$1(httpClient: HttpClient$1): (_id: string, endDate: Date) => Promise<void>;
1512
+ declare function cancelOrder$1(httpClient: HttpClient$1): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
1513
+ declare function markAsPaid$1(httpClient: HttpClient$1): (_id: string) => Promise<void>;
1514
+ declare function pauseOrder$1(httpClient: HttpClient$1): (_id: string) => Promise<void>;
1515
+ declare function resumeOrder$1(httpClient: HttpClient$1): (_id: string) => Promise<void>;
1516
+ declare const onOrderCanceled$1: EventDefinition$1<OrderCanceledEnvelope, "wix.pricing_plans.v2.order_canceled">;
1517
+ declare const onOrderCreated$1: EventDefinition$1<OrderCreatedEnvelope, "wix.pricing_plans.v2.order_created">;
1518
+ declare const onOrderUpdated$1: EventDefinition$1<OrderUpdatedEnvelope, "wix.pricing_plans.v2.order_updated">;
1519
+ declare const onOrderStartDateChanged$1: EventDefinition$1<OrderStartDateChangedEnvelope, "wix.pricing_plans.v2.order_start_date_changed">;
1520
+ declare const onOrderPurchased$1: EventDefinition$1<OrderPurchasedEnvelope, "wix.pricing_plans.v2.order_purchased">;
1521
+ declare const onOrderStarted$1: EventDefinition$1<OrderStartedEnvelope, "wix.pricing_plans.v2.order_started">;
1522
+ declare const onOrderCycleStarted$1: EventDefinition$1<OrderCycleStartedEnvelope, "wix.pricing_plans.v2.order_cycle_started">;
1523
+ declare const onOrderAutoRenewCanceled$1: EventDefinition$1<OrderAutoRenewCanceledEnvelope, "wix.pricing_plans.v2.order_auto_renew_canceled">;
1524
+ declare const onOrderEnded$1: EventDefinition$1<OrderEndedEnvelope, "wix.pricing_plans.v2.order_ended">;
1525
+ declare const onOrderEndDatePostponed$1: EventDefinition$1<OrderEndDatePostponedEnvelope, "wix.pricing_plans.v2.order_end_date_postponed">;
1526
+ declare const onOrderMarkedAsPaid$1: EventDefinition$1<OrderMarkedAsPaidEnvelope, "wix.pricing_plans.v2.order_marked_as_paid">;
1527
+ declare const onOrderPaused$1: EventDefinition$1<OrderPausedEnvelope, "wix.pricing_plans.v2.order_paused">;
1528
+ declare const onOrderResumed$1: EventDefinition$1<OrderResumedEnvelope, "wix.pricing_plans.v2.order_resumed">;
1529
1529
 
1530
- declare const memberGetOrder: BuildRESTFunction<typeof memberGetOrder$1>;
1531
- declare const memberListOrders: BuildRESTFunction<typeof memberListOrders$1>;
1532
- declare const requestCancellation: BuildRESTFunction<typeof requestCancellation$1>;
1533
- declare const createOfflineOrder: BuildRESTFunction<typeof createOfflineOrder$1>;
1534
- declare const getOfflineOrderPreview: BuildRESTFunction<typeof getOfflineOrderPreview$1>;
1535
- declare const getPricePreview: BuildRESTFunction<typeof getPricePreview$1>;
1536
- declare const managementGetOrder: BuildRESTFunction<typeof managementGetOrder$1>;
1537
- declare const managementListOrders: BuildRESTFunction<typeof managementListOrders$1>;
1538
- declare const postponeEndDate: BuildRESTFunction<typeof postponeEndDate$1>;
1539
- declare const cancelOrder: BuildRESTFunction<typeof cancelOrder$1>;
1540
- declare const markAsPaid: BuildRESTFunction<typeof markAsPaid$1>;
1541
- declare const pauseOrder: BuildRESTFunction<typeof pauseOrder$1>;
1542
- declare const resumeOrder: BuildRESTFunction<typeof resumeOrder$1>;
1543
- declare const onOrderCanceled: BuildEventDefinition<typeof onOrderCanceled$1>;
1544
- declare const onOrderCreated: BuildEventDefinition<typeof onOrderCreated$1>;
1545
- declare const onOrderUpdated: BuildEventDefinition<typeof onOrderUpdated$1>;
1546
- declare const onOrderStartDateChanged: BuildEventDefinition<typeof onOrderStartDateChanged$1>;
1547
- declare const onOrderPurchased: BuildEventDefinition<typeof onOrderPurchased$1>;
1548
- declare const onOrderStarted: BuildEventDefinition<typeof onOrderStarted$1>;
1549
- declare const onOrderCycleStarted: BuildEventDefinition<typeof onOrderCycleStarted$1>;
1550
- declare const onOrderAutoRenewCanceled: BuildEventDefinition<typeof onOrderAutoRenewCanceled$1>;
1551
- declare const onOrderEnded: BuildEventDefinition<typeof onOrderEnded$1>;
1552
- declare const onOrderEndDatePostponed: BuildEventDefinition<typeof onOrderEndDatePostponed$1>;
1553
- declare const onOrderMarkedAsPaid: BuildEventDefinition<typeof onOrderMarkedAsPaid$1>;
1554
- declare const onOrderPaused: BuildEventDefinition<typeof onOrderPaused$1>;
1555
- declare const onOrderResumed: BuildEventDefinition<typeof onOrderResumed$1>;
1530
+ declare const memberGetOrder: BuildRESTFunction$1<typeof memberGetOrder$1>;
1531
+ declare const memberListOrders: BuildRESTFunction$1<typeof memberListOrders$1>;
1532
+ declare const requestCancellation: BuildRESTFunction$1<typeof requestCancellation$1>;
1533
+ declare const createOfflineOrder: BuildRESTFunction$1<typeof createOfflineOrder$1>;
1534
+ declare const getOfflineOrderPreview: BuildRESTFunction$1<typeof getOfflineOrderPreview$1>;
1535
+ declare const getPricePreview: BuildRESTFunction$1<typeof getPricePreview$1>;
1536
+ declare const managementGetOrder: BuildRESTFunction$1<typeof managementGetOrder$1>;
1537
+ declare const managementListOrders: BuildRESTFunction$1<typeof managementListOrders$1>;
1538
+ declare const postponeEndDate: BuildRESTFunction$1<typeof postponeEndDate$1>;
1539
+ declare const cancelOrder: BuildRESTFunction$1<typeof cancelOrder$1>;
1540
+ declare const markAsPaid: BuildRESTFunction$1<typeof markAsPaid$1>;
1541
+ declare const pauseOrder: BuildRESTFunction$1<typeof pauseOrder$1>;
1542
+ declare const resumeOrder: BuildRESTFunction$1<typeof resumeOrder$1>;
1543
+ declare const onOrderCanceled: BuildEventDefinition$1<typeof onOrderCanceled$1>;
1544
+ declare const onOrderCreated: BuildEventDefinition$1<typeof onOrderCreated$1>;
1545
+ declare const onOrderUpdated: BuildEventDefinition$1<typeof onOrderUpdated$1>;
1546
+ declare const onOrderStartDateChanged: BuildEventDefinition$1<typeof onOrderStartDateChanged$1>;
1547
+ declare const onOrderPurchased: BuildEventDefinition$1<typeof onOrderPurchased$1>;
1548
+ declare const onOrderStarted: BuildEventDefinition$1<typeof onOrderStarted$1>;
1549
+ declare const onOrderCycleStarted: BuildEventDefinition$1<typeof onOrderCycleStarted$1>;
1550
+ declare const onOrderAutoRenewCanceled: BuildEventDefinition$1<typeof onOrderAutoRenewCanceled$1>;
1551
+ declare const onOrderEnded: BuildEventDefinition$1<typeof onOrderEnded$1>;
1552
+ declare const onOrderEndDatePostponed: BuildEventDefinition$1<typeof onOrderEndDatePostponed$1>;
1553
+ declare const onOrderMarkedAsPaid: BuildEventDefinition$1<typeof onOrderMarkedAsPaid$1>;
1554
+ declare const onOrderPaused: BuildEventDefinition$1<typeof onOrderPaused$1>;
1555
+ declare const onOrderResumed: BuildEventDefinition$1<typeof onOrderResumed$1>;
1556
1556
 
1557
1557
  declare const context$1_cancelOrder: typeof cancelOrder;
1558
1558
  declare const context$1_createOfflineOrder: typeof createOfflineOrder;
@@ -2227,6 +2227,41 @@ interface UpdatePlan {
2227
2227
  formId?: string | null;
2228
2228
  }
2229
2229
 
2230
+ type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
2231
+ interface HttpClient {
2232
+ request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
2233
+ }
2234
+ type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
2235
+ type HttpResponse<T = any> = {
2236
+ data: T;
2237
+ status: number;
2238
+ statusText: string;
2239
+ headers: any;
2240
+ request?: any;
2241
+ };
2242
+ type RequestOptions<_TResponse = any, Data = any> = {
2243
+ method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
2244
+ url: string;
2245
+ data?: Data;
2246
+ params?: URLSearchParams;
2247
+ } & APIMetadata;
2248
+ type APIMetadata = {
2249
+ methodFqn?: string;
2250
+ entityFqdn?: string;
2251
+ packageName?: string;
2252
+ };
2253
+ type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
2254
+ type EventDefinition<Payload = unknown, Type extends string = string> = {
2255
+ __type: 'event-definition';
2256
+ type: Type;
2257
+ isDomainEvent?: boolean;
2258
+ transformations?: unknown;
2259
+ __payload: Payload;
2260
+ };
2261
+ declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
2262
+ type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
2263
+ type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
2264
+
2230
2265
  declare function listPublicPlans$1(httpClient: HttpClient): (options?: ListPublicPlansOptions) => Promise<ListPublicPlansResponse & ListPublicPlansResponseNonNullableFields>;
2231
2266
  declare function queryPublicPlans$1(httpClient: HttpClient): () => PlansQueryBuilder;
2232
2267
  declare function getPlan$1(httpClient: HttpClient): (_id: string) => Promise<Plan & {
@@ -2043,41 +2043,41 @@ interface ManagementListOrdersOptions {
2043
2043
  fieldSet?: Set;
2044
2044
  }
2045
2045
 
2046
- interface HttpClient {
2047
- request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
2046
+ interface HttpClient$1 {
2047
+ request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
2048
2048
  }
2049
- type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
2050
- type HttpResponse<T = any> = {
2049
+ type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
2050
+ type HttpResponse$1<T = any> = {
2051
2051
  data: T;
2052
2052
  status: number;
2053
2053
  statusText: string;
2054
2054
  headers: any;
2055
2055
  request?: any;
2056
2056
  };
2057
- type RequestOptions<_TResponse = any, Data = any> = {
2057
+ type RequestOptions$1<_TResponse = any, Data = any> = {
2058
2058
  method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
2059
2059
  url: string;
2060
2060
  data?: Data;
2061
2061
  params?: URLSearchParams;
2062
- } & APIMetadata;
2063
- type APIMetadata = {
2062
+ } & APIMetadata$1;
2063
+ type APIMetadata$1 = {
2064
2064
  methodFqn?: string;
2065
2065
  entityFqdn?: string;
2066
2066
  packageName?: string;
2067
2067
  };
2068
- type EventDefinition<Payload = unknown, Type extends string = string> = {
2068
+ type EventDefinition$1<Payload = unknown, Type extends string = string> = {
2069
2069
  __type: 'event-definition';
2070
2070
  type: Type;
2071
2071
  isDomainEvent?: boolean;
2072
2072
  transformations?: unknown;
2073
2073
  __payload: Payload;
2074
2074
  };
2075
- declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
2075
+ declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
2076
2076
 
2077
2077
  declare const __metadata$1: {
2078
2078
  PACKAGE_NAME: string;
2079
2079
  };
2080
- declare function memberGetOrder(httpClient: HttpClient): (_id: string, options?: MemberGetOrderOptions) => Promise<Order & {
2080
+ declare function memberGetOrder(httpClient: HttpClient$1): (_id: string, options?: MemberGetOrderOptions) => Promise<Order & {
2081
2081
  _id: string;
2082
2082
  planId: string;
2083
2083
  subscriptionId: string;
@@ -2161,31 +2161,31 @@ declare function memberGetOrder(httpClient: HttpClient): (_id: string, options?:
2161
2161
  planDescription: string;
2162
2162
  planPrice: string;
2163
2163
  }>;
2164
- declare function memberListOrders(httpClient: HttpClient): (options?: MemberListOrdersOptions) => Promise<MemberListOrdersResponse & MemberListOrdersResponseNonNullableFields>;
2165
- declare function requestCancellation(httpClient: HttpClient): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
2166
- declare function createOfflineOrder(httpClient: HttpClient): (planId: string, memberId: string, options?: CreateOfflineOrderOptions) => Promise<CreateOfflineOrderResponse & CreateOfflineOrderResponseNonNullableFields>;
2167
- declare function getOfflineOrderPreview(httpClient: HttpClient): (planId: string, memberId: string, options?: GetOfflineOrderPreviewOptions) => Promise<GetOfflineOrderPreviewResponse & GetOfflineOrderPreviewResponseNonNullableFields>;
2168
- declare function getPricePreview(httpClient: HttpClient): (planId: string, options?: GetPricePreviewOptions) => Promise<GetPricePreviewResponse & GetPricePreviewResponseNonNullableFields>;
2169
- declare function managementGetOrder(httpClient: HttpClient): (_id: string, options?: ManagementGetOrderOptions) => Promise<GetOrderResponse & GetOrderResponseNonNullableFields>;
2170
- declare function managementListOrders(httpClient: HttpClient): (options?: ManagementListOrdersOptions) => Promise<ListOrdersResponse & ListOrdersResponseNonNullableFields>;
2171
- declare function postponeEndDate(httpClient: HttpClient): (_id: string, endDate: Date) => Promise<void>;
2172
- declare function cancelOrder(httpClient: HttpClient): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
2173
- declare function markAsPaid(httpClient: HttpClient): (_id: string) => Promise<void>;
2174
- declare function pauseOrder(httpClient: HttpClient): (_id: string) => Promise<void>;
2175
- declare function resumeOrder(httpClient: HttpClient): (_id: string) => Promise<void>;
2176
- declare const onOrderCanceled: EventDefinition<OrderCanceledEnvelope, "wix.pricing_plans.v2.order_canceled">;
2177
- declare const onOrderCreated: EventDefinition<OrderCreatedEnvelope, "wix.pricing_plans.v2.order_created">;
2178
- declare const onOrderUpdated: EventDefinition<OrderUpdatedEnvelope, "wix.pricing_plans.v2.order_updated">;
2179
- declare const onOrderStartDateChanged: EventDefinition<OrderStartDateChangedEnvelope, "wix.pricing_plans.v2.order_start_date_changed">;
2180
- declare const onOrderPurchased: EventDefinition<OrderPurchasedEnvelope, "wix.pricing_plans.v2.order_purchased">;
2181
- declare const onOrderStarted: EventDefinition<OrderStartedEnvelope, "wix.pricing_plans.v2.order_started">;
2182
- declare const onOrderCycleStarted: EventDefinition<OrderCycleStartedEnvelope, "wix.pricing_plans.v2.order_cycle_started">;
2183
- declare const onOrderAutoRenewCanceled: EventDefinition<OrderAutoRenewCanceledEnvelope, "wix.pricing_plans.v2.order_auto_renew_canceled">;
2184
- declare const onOrderEnded: EventDefinition<OrderEndedEnvelope, "wix.pricing_plans.v2.order_ended">;
2185
- declare const onOrderEndDatePostponed: EventDefinition<OrderEndDatePostponedEnvelope, "wix.pricing_plans.v2.order_end_date_postponed">;
2186
- declare const onOrderMarkedAsPaid: EventDefinition<OrderMarkedAsPaidEnvelope, "wix.pricing_plans.v2.order_marked_as_paid">;
2187
- declare const onOrderPaused: EventDefinition<OrderPausedEnvelope, "wix.pricing_plans.v2.order_paused">;
2188
- declare const onOrderResumed: EventDefinition<OrderResumedEnvelope, "wix.pricing_plans.v2.order_resumed">;
2164
+ declare function memberListOrders(httpClient: HttpClient$1): (options?: MemberListOrdersOptions) => Promise<MemberListOrdersResponse & MemberListOrdersResponseNonNullableFields>;
2165
+ declare function requestCancellation(httpClient: HttpClient$1): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
2166
+ declare function createOfflineOrder(httpClient: HttpClient$1): (planId: string, memberId: string, options?: CreateOfflineOrderOptions) => Promise<CreateOfflineOrderResponse & CreateOfflineOrderResponseNonNullableFields>;
2167
+ declare function getOfflineOrderPreview(httpClient: HttpClient$1): (planId: string, memberId: string, options?: GetOfflineOrderPreviewOptions) => Promise<GetOfflineOrderPreviewResponse & GetOfflineOrderPreviewResponseNonNullableFields>;
2168
+ declare function getPricePreview(httpClient: HttpClient$1): (planId: string, options?: GetPricePreviewOptions) => Promise<GetPricePreviewResponse & GetPricePreviewResponseNonNullableFields>;
2169
+ declare function managementGetOrder(httpClient: HttpClient$1): (_id: string, options?: ManagementGetOrderOptions) => Promise<GetOrderResponse & GetOrderResponseNonNullableFields>;
2170
+ declare function managementListOrders(httpClient: HttpClient$1): (options?: ManagementListOrdersOptions) => Promise<ListOrdersResponse & ListOrdersResponseNonNullableFields>;
2171
+ declare function postponeEndDate(httpClient: HttpClient$1): (_id: string, endDate: Date) => Promise<void>;
2172
+ declare function cancelOrder(httpClient: HttpClient$1): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
2173
+ declare function markAsPaid(httpClient: HttpClient$1): (_id: string) => Promise<void>;
2174
+ declare function pauseOrder(httpClient: HttpClient$1): (_id: string) => Promise<void>;
2175
+ declare function resumeOrder(httpClient: HttpClient$1): (_id: string) => Promise<void>;
2176
+ declare const onOrderCanceled: EventDefinition$1<OrderCanceledEnvelope, "wix.pricing_plans.v2.order_canceled">;
2177
+ declare const onOrderCreated: EventDefinition$1<OrderCreatedEnvelope, "wix.pricing_plans.v2.order_created">;
2178
+ declare const onOrderUpdated: EventDefinition$1<OrderUpdatedEnvelope, "wix.pricing_plans.v2.order_updated">;
2179
+ declare const onOrderStartDateChanged: EventDefinition$1<OrderStartDateChangedEnvelope, "wix.pricing_plans.v2.order_start_date_changed">;
2180
+ declare const onOrderPurchased: EventDefinition$1<OrderPurchasedEnvelope, "wix.pricing_plans.v2.order_purchased">;
2181
+ declare const onOrderStarted: EventDefinition$1<OrderStartedEnvelope, "wix.pricing_plans.v2.order_started">;
2182
+ declare const onOrderCycleStarted: EventDefinition$1<OrderCycleStartedEnvelope, "wix.pricing_plans.v2.order_cycle_started">;
2183
+ declare const onOrderAutoRenewCanceled: EventDefinition$1<OrderAutoRenewCanceledEnvelope, "wix.pricing_plans.v2.order_auto_renew_canceled">;
2184
+ declare const onOrderEnded: EventDefinition$1<OrderEndedEnvelope, "wix.pricing_plans.v2.order_ended">;
2185
+ declare const onOrderEndDatePostponed: EventDefinition$1<OrderEndDatePostponedEnvelope, "wix.pricing_plans.v2.order_end_date_postponed">;
2186
+ declare const onOrderMarkedAsPaid: EventDefinition$1<OrderMarkedAsPaidEnvelope, "wix.pricing_plans.v2.order_marked_as_paid">;
2187
+ declare const onOrderPaused: EventDefinition$1<OrderPausedEnvelope, "wix.pricing_plans.v2.order_paused">;
2188
+ declare const onOrderResumed: EventDefinition$1<OrderResumedEnvelope, "wix.pricing_plans.v2.order_resumed">;
2189
2189
 
2190
2190
  type index_d$1_ApplyCouponRequest = ApplyCouponRequest;
2191
2191
  type index_d$1_ApplyCouponResponse = ApplyCouponResponse;
@@ -3352,6 +3352,37 @@ interface UpdatePlan {
3352
3352
  formId?: string | null;
3353
3353
  }
3354
3354
 
3355
+ interface HttpClient {
3356
+ request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
3357
+ }
3358
+ type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
3359
+ type HttpResponse<T = any> = {
3360
+ data: T;
3361
+ status: number;
3362
+ statusText: string;
3363
+ headers: any;
3364
+ request?: any;
3365
+ };
3366
+ type RequestOptions<_TResponse = any, Data = any> = {
3367
+ method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
3368
+ url: string;
3369
+ data?: Data;
3370
+ params?: URLSearchParams;
3371
+ } & APIMetadata;
3372
+ type APIMetadata = {
3373
+ methodFqn?: string;
3374
+ entityFqdn?: string;
3375
+ packageName?: string;
3376
+ };
3377
+ type EventDefinition<Payload = unknown, Type extends string = string> = {
3378
+ __type: 'event-definition';
3379
+ type: Type;
3380
+ isDomainEvent?: boolean;
3381
+ transformations?: unknown;
3382
+ __payload: Payload;
3383
+ };
3384
+ declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
3385
+
3355
3386
  declare const __metadata: {
3356
3387
  PACKAGE_NAME: string;
3357
3388
  };