@crmcom/self-service-sdk 3.0.0-build.31 → 3.0.0-build.33
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/index.d.ts +1 -1
- package/package.json +1 -1
- package/subscriptions.js +9 -24
package/index.d.ts
CHANGED
|
@@ -369,7 +369,7 @@ export declare const subscriptions: {
|
|
|
369
369
|
updateSubscription(params?: { action?: string; payment_method_id?: string; billing_day?: number; funding_source?: string }, id?: string): Promise<SDKResult>;
|
|
370
370
|
getServiceRescommendation(params: Record<string, any>): Promise<SDKResult>;
|
|
371
371
|
getSubscriptionAction(params: { action_id: string }): Promise<SDKResult>;
|
|
372
|
-
listSubscriptionActions(params?: PaginationParams & {
|
|
372
|
+
listSubscriptionActions(params?: PaginationParams & { contact_id?: string; is_scheduled?: boolean; service_id?: string; subscription_id?: string; behaviour_code?: string; business_classification_code?: string }): Promise<SDKResult>;
|
|
373
373
|
};
|
|
374
374
|
|
|
375
375
|
// ============================================================================
|
package/package.json
CHANGED
package/subscriptions.js
CHANGED
|
@@ -436,23 +436,16 @@ async function listSubscriptionActions({
|
|
|
436
436
|
include_total,
|
|
437
437
|
behaviour_code,
|
|
438
438
|
business_classification_code,
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
cancelled_on_lte,
|
|
444
|
-
scheduled_on,
|
|
445
|
-
scheduled_on_gt,
|
|
446
|
-
scheduled_on_gte,
|
|
447
|
-
scheduled_on_lt,
|
|
448
|
-
scheduled_on_lte,
|
|
449
|
-
state,
|
|
439
|
+
contact_id,
|
|
440
|
+
is_scheduled,
|
|
441
|
+
service_id,
|
|
442
|
+
subscription_id,
|
|
450
443
|
subscription_id,
|
|
451
444
|
} = {}) {
|
|
452
445
|
try {
|
|
453
|
-
|
|
446
|
+
if (!contact_id) contact_id = await httpUtil.getSession().sub;
|
|
454
447
|
let response = await httpUtil.get({
|
|
455
|
-
resourcePath: "/v2/
|
|
448
|
+
resourcePath: "/v2/subscriptions/actions",
|
|
456
449
|
queryParams: {
|
|
457
450
|
sort,
|
|
458
451
|
order,
|
|
@@ -460,17 +453,9 @@ async function listSubscriptionActions({
|
|
|
460
453
|
size,
|
|
461
454
|
behaviour_code,
|
|
462
455
|
business_classification_code,
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
"cancelled_on[lt]":cancelled_on_lt,
|
|
467
|
-
"cancelled_on[lte]":cancelled_on_lte,
|
|
468
|
-
scheduled_on,
|
|
469
|
-
"scheduled_on[gt]":scheduled_on_gt,
|
|
470
|
-
"scheduled_on[gte]":scheduled_on_gte,
|
|
471
|
-
"scheduled_on[lt]":scheduled_on_lt,
|
|
472
|
-
"scheduled_on[lte]":scheduled_on_lte,
|
|
473
|
-
state,
|
|
456
|
+
contact_id,
|
|
457
|
+
is_scheduled,
|
|
458
|
+
service_id,
|
|
474
459
|
subscription_id,
|
|
475
460
|
include_total,
|
|
476
461
|
},
|