@compassdigital/sdk.typescript 4.528.0 → 4.528.1-beta.0
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/lib/index.d.ts +308 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +373 -0
- package/lib/index.js.map +1 -1
- package/lib/interface/loyalty.d.ts +402 -0
- package/lib/interface/loyalty.d.ts.map +1 -0
- package/lib/interface/loyalty.js +5 -0
- package/lib/interface/loyalty.js.map +1 -0
- package/manifest.json +7 -0
- package/package.json +1 -1
- package/src/index.ts +914 -0
- package/src/interface/loyalty.ts +659 -0
package/src/index.ts
CHANGED
|
@@ -1398,6 +1398,76 @@ import {
|
|
|
1398
1398
|
PutDiscountPublishResponse,
|
|
1399
1399
|
} from './interface/discount';
|
|
1400
1400
|
|
|
1401
|
+
import {
|
|
1402
|
+
BundleControllerFindAllQuery,
|
|
1403
|
+
BundleControllerFindAllResponse,
|
|
1404
|
+
BundleControllerCreateBody,
|
|
1405
|
+
BundleControllerCreateResponse,
|
|
1406
|
+
BundleControllerFindOneResponse,
|
|
1407
|
+
BundleControllerUpdateBody,
|
|
1408
|
+
BundleControllerUpdateResponse,
|
|
1409
|
+
BundleControllerRemoveResponse,
|
|
1410
|
+
CampaignControllerListQuery,
|
|
1411
|
+
CampaignControllerListResponse,
|
|
1412
|
+
CampaignControllerCreateBody,
|
|
1413
|
+
CampaignControllerCreateResponse,
|
|
1414
|
+
CampaignControllerFindOneResponse,
|
|
1415
|
+
CampaignControllerUpdateBody,
|
|
1416
|
+
CampaignControllerUpdateResponse,
|
|
1417
|
+
CampaignControllerRemoveResponse,
|
|
1418
|
+
CampaignControllerUpdateStatusBody,
|
|
1419
|
+
CampaignControllerUpdateStatusResponse,
|
|
1420
|
+
CampaignControllerCloneResponse,
|
|
1421
|
+
VoucherControllerFindAllQuery,
|
|
1422
|
+
VoucherControllerFindAllResponse,
|
|
1423
|
+
VoucherControllerCreateBody,
|
|
1424
|
+
VoucherControllerCreateResponse,
|
|
1425
|
+
VoucherControllerFindOneResponse,
|
|
1426
|
+
VoucherControllerUpdateBody,
|
|
1427
|
+
VoucherControllerUpdateResponse,
|
|
1428
|
+
VoucherControllerRemoveResponse,
|
|
1429
|
+
VoucherControllerRevokeBody,
|
|
1430
|
+
VoucherControllerRevokeResponse,
|
|
1431
|
+
VoucherControllerBatchGenerateBody,
|
|
1432
|
+
VoucherControllerBatchGenerateResponse,
|
|
1433
|
+
VoucherControllerFindRedemptionsQuery,
|
|
1434
|
+
VoucherControllerFindRedemptionsResponse,
|
|
1435
|
+
VoucherControllerValidateResponse,
|
|
1436
|
+
VoucherControllerRedeemResponse,
|
|
1437
|
+
SegmentControllerFindAllQuery,
|
|
1438
|
+
SegmentControllerFindAllResponse,
|
|
1439
|
+
SegmentControllerCreateBody,
|
|
1440
|
+
SegmentControllerCreateResponse,
|
|
1441
|
+
SegmentControllerGetAttributesResponse,
|
|
1442
|
+
SegmentControllerPreviewRuleCountResponse,
|
|
1443
|
+
SegmentControllerFindOneResponse,
|
|
1444
|
+
SegmentControllerUpdateBody,
|
|
1445
|
+
SegmentControllerUpdateResponse,
|
|
1446
|
+
SegmentControllerRemoveResponse,
|
|
1447
|
+
SegmentControllerFindMembersQuery,
|
|
1448
|
+
SegmentControllerFindMembersResponse,
|
|
1449
|
+
SegmentControllerAddMembersBody,
|
|
1450
|
+
SegmentControllerAddMembersResponse,
|
|
1451
|
+
SegmentControllerRemoveMembersBody,
|
|
1452
|
+
SegmentControllerRemoveMembersResponse,
|
|
1453
|
+
RedemptionControllerRollbackBody,
|
|
1454
|
+
RedemptionControllerRollbackResponse,
|
|
1455
|
+
LoyaltyControllerListProgramsQuery,
|
|
1456
|
+
LoyaltyControllerListProgramsResponse,
|
|
1457
|
+
LoyaltyControllerCreateProgramBody,
|
|
1458
|
+
LoyaltyControllerCreateProgramResponse,
|
|
1459
|
+
LoyaltyControllerFindOneProgramResponse,
|
|
1460
|
+
LoyaltyControllerUpdateProgramBody,
|
|
1461
|
+
LoyaltyControllerUpdateProgramResponse,
|
|
1462
|
+
LoyaltyControllerUpdateProgramStatusBody,
|
|
1463
|
+
LoyaltyControllerUpdateProgramStatusResponse,
|
|
1464
|
+
LoyaltyControllerListCardsQuery,
|
|
1465
|
+
LoyaltyControllerListCardsResponse,
|
|
1466
|
+
LoyaltyControllerFindCardResponse,
|
|
1467
|
+
LoyaltyControllerAdjustPointsBody,
|
|
1468
|
+
LoyaltyControllerAdjustPointsResponse,
|
|
1469
|
+
} from './interface/loyalty';
|
|
1470
|
+
|
|
1401
1471
|
import {
|
|
1402
1472
|
GetTimeslotsBrandQuery,
|
|
1403
1473
|
GetTimeslotsBrandResponse,
|
|
@@ -15718,6 +15788,850 @@ export class ServiceClient extends BaseServiceClient {
|
|
|
15718
15788
|
);
|
|
15719
15789
|
}
|
|
15720
15790
|
|
|
15791
|
+
/**
|
|
15792
|
+
* GET /loyalty/bundles - List bundles with optional filters
|
|
15793
|
+
*
|
|
15794
|
+
* @param options - additional request options
|
|
15795
|
+
*/
|
|
15796
|
+
BundleController_findAll(
|
|
15797
|
+
options?: {
|
|
15798
|
+
query?: BundleControllerFindAllQuery;
|
|
15799
|
+
} & RequestOptions,
|
|
15800
|
+
): ResponsePromise<BundleControllerFindAllResponse> {
|
|
15801
|
+
return this.request(
|
|
15802
|
+
'loyalty',
|
|
15803
|
+
'/loyalty/bundles',
|
|
15804
|
+
'GET',
|
|
15805
|
+
`/loyalty/bundles`,
|
|
15806
|
+
null,
|
|
15807
|
+
options,
|
|
15808
|
+
);
|
|
15809
|
+
}
|
|
15810
|
+
|
|
15811
|
+
/**
|
|
15812
|
+
* POST /loyalty/bundles - Create a new bundle
|
|
15813
|
+
*
|
|
15814
|
+
* @param body
|
|
15815
|
+
* @param options - additional request options
|
|
15816
|
+
*/
|
|
15817
|
+
BundleController_create(
|
|
15818
|
+
body: BundleControllerCreateBody,
|
|
15819
|
+
options?: RequestOptions,
|
|
15820
|
+
): ResponsePromise<BundleControllerCreateResponse> {
|
|
15821
|
+
return this.request(
|
|
15822
|
+
'loyalty',
|
|
15823
|
+
'/loyalty/bundles',
|
|
15824
|
+
'POST',
|
|
15825
|
+
`/loyalty/bundles`,
|
|
15826
|
+
body,
|
|
15827
|
+
options,
|
|
15828
|
+
);
|
|
15829
|
+
}
|
|
15830
|
+
|
|
15831
|
+
/**
|
|
15832
|
+
* GET /loyalty/bundles/{id} - Get bundle by ID with groups
|
|
15833
|
+
*
|
|
15834
|
+
* @param id
|
|
15835
|
+
* @param options - additional request options
|
|
15836
|
+
*/
|
|
15837
|
+
BundleController_findOne(
|
|
15838
|
+
id: string,
|
|
15839
|
+
options?: RequestOptions,
|
|
15840
|
+
): ResponsePromise<BundleControllerFindOneResponse> {
|
|
15841
|
+
return this.request(
|
|
15842
|
+
'loyalty',
|
|
15843
|
+
'/loyalty/bundles/{id}',
|
|
15844
|
+
'GET',
|
|
15845
|
+
`/loyalty/bundles/${id}`,
|
|
15846
|
+
null,
|
|
15847
|
+
options,
|
|
15848
|
+
);
|
|
15849
|
+
}
|
|
15850
|
+
|
|
15851
|
+
/**
|
|
15852
|
+
* PATCH /loyalty/bundles/{id} - Update a bundle
|
|
15853
|
+
*
|
|
15854
|
+
* @param id
|
|
15855
|
+
* @param body
|
|
15856
|
+
* @param options - additional request options
|
|
15857
|
+
*/
|
|
15858
|
+
BundleController_update(
|
|
15859
|
+
id: string,
|
|
15860
|
+
body: BundleControllerUpdateBody,
|
|
15861
|
+
options?: RequestOptions,
|
|
15862
|
+
): ResponsePromise<BundleControllerUpdateResponse> {
|
|
15863
|
+
return this.request(
|
|
15864
|
+
'loyalty',
|
|
15865
|
+
'/loyalty/bundles/{id}',
|
|
15866
|
+
'PATCH',
|
|
15867
|
+
`/loyalty/bundles/${id}`,
|
|
15868
|
+
body,
|
|
15869
|
+
options,
|
|
15870
|
+
);
|
|
15871
|
+
}
|
|
15872
|
+
|
|
15873
|
+
/**
|
|
15874
|
+
* DELETE /loyalty/bundles/{id} - Soft-delete a bundle
|
|
15875
|
+
*
|
|
15876
|
+
* @param id
|
|
15877
|
+
* @param options - additional request options
|
|
15878
|
+
*/
|
|
15879
|
+
BundleController_remove(
|
|
15880
|
+
id: string,
|
|
15881
|
+
options?: RequestOptions,
|
|
15882
|
+
): ResponsePromise<BundleControllerRemoveResponse> {
|
|
15883
|
+
return this.request(
|
|
15884
|
+
'loyalty',
|
|
15885
|
+
'/loyalty/bundles/{id}',
|
|
15886
|
+
'DELETE',
|
|
15887
|
+
`/loyalty/bundles/${id}`,
|
|
15888
|
+
null,
|
|
15889
|
+
options,
|
|
15890
|
+
);
|
|
15891
|
+
}
|
|
15892
|
+
|
|
15893
|
+
/**
|
|
15894
|
+
* GET /loyalty/campaigns - List campaigns with filters and pagination
|
|
15895
|
+
*
|
|
15896
|
+
* @param options - additional request options
|
|
15897
|
+
*/
|
|
15898
|
+
CampaignController_list(
|
|
15899
|
+
options?: {
|
|
15900
|
+
query?: CampaignControllerListQuery;
|
|
15901
|
+
} & RequestOptions,
|
|
15902
|
+
): ResponsePromise<CampaignControllerListResponse> {
|
|
15903
|
+
return this.request(
|
|
15904
|
+
'loyalty',
|
|
15905
|
+
'/loyalty/campaigns',
|
|
15906
|
+
'GET',
|
|
15907
|
+
`/loyalty/campaigns`,
|
|
15908
|
+
null,
|
|
15909
|
+
options,
|
|
15910
|
+
);
|
|
15911
|
+
}
|
|
15912
|
+
|
|
15913
|
+
/**
|
|
15914
|
+
* POST /loyalty/campaigns - Create a campaign with nested child entities
|
|
15915
|
+
*
|
|
15916
|
+
* @param body
|
|
15917
|
+
* @param options - additional request options
|
|
15918
|
+
*/
|
|
15919
|
+
CampaignController_create(
|
|
15920
|
+
body: CampaignControllerCreateBody,
|
|
15921
|
+
options?: RequestOptions,
|
|
15922
|
+
): ResponsePromise<CampaignControllerCreateResponse> {
|
|
15923
|
+
return this.request(
|
|
15924
|
+
'loyalty',
|
|
15925
|
+
'/loyalty/campaigns',
|
|
15926
|
+
'POST',
|
|
15927
|
+
`/loyalty/campaigns`,
|
|
15928
|
+
body,
|
|
15929
|
+
options,
|
|
15930
|
+
);
|
|
15931
|
+
}
|
|
15932
|
+
|
|
15933
|
+
/**
|
|
15934
|
+
* GET /loyalty/campaigns/{id} - Get campaign detail with all child entities
|
|
15935
|
+
*
|
|
15936
|
+
* @param id
|
|
15937
|
+
* @param options - additional request options
|
|
15938
|
+
*/
|
|
15939
|
+
CampaignController_findOne(
|
|
15940
|
+
id: string,
|
|
15941
|
+
options?: RequestOptions,
|
|
15942
|
+
): ResponsePromise<CampaignControllerFindOneResponse> {
|
|
15943
|
+
return this.request(
|
|
15944
|
+
'loyalty',
|
|
15945
|
+
'/loyalty/campaigns/{id}',
|
|
15946
|
+
'GET',
|
|
15947
|
+
`/loyalty/campaigns/${id}`,
|
|
15948
|
+
null,
|
|
15949
|
+
options,
|
|
15950
|
+
);
|
|
15951
|
+
}
|
|
15952
|
+
|
|
15953
|
+
/**
|
|
15954
|
+
* PUT /loyalty/campaigns/{id} - Update a campaign and its child entities
|
|
15955
|
+
*
|
|
15956
|
+
* @param id
|
|
15957
|
+
* @param body
|
|
15958
|
+
* @param options - additional request options
|
|
15959
|
+
*/
|
|
15960
|
+
CampaignController_update(
|
|
15961
|
+
id: string,
|
|
15962
|
+
body: CampaignControllerUpdateBody,
|
|
15963
|
+
options?: RequestOptions,
|
|
15964
|
+
): ResponsePromise<CampaignControllerUpdateResponse> {
|
|
15965
|
+
return this.request(
|
|
15966
|
+
'loyalty',
|
|
15967
|
+
'/loyalty/campaigns/{id}',
|
|
15968
|
+
'PUT',
|
|
15969
|
+
`/loyalty/campaigns/${id}`,
|
|
15970
|
+
body,
|
|
15971
|
+
options,
|
|
15972
|
+
);
|
|
15973
|
+
}
|
|
15974
|
+
|
|
15975
|
+
/**
|
|
15976
|
+
* DELETE /loyalty/campaigns/{id} - Soft-delete a campaign
|
|
15977
|
+
*
|
|
15978
|
+
* @param id
|
|
15979
|
+
* @param options - additional request options
|
|
15980
|
+
*/
|
|
15981
|
+
CampaignController_remove(
|
|
15982
|
+
id: string,
|
|
15983
|
+
options?: RequestOptions,
|
|
15984
|
+
): ResponsePromise<CampaignControllerRemoveResponse> {
|
|
15985
|
+
return this.request(
|
|
15986
|
+
'loyalty',
|
|
15987
|
+
'/loyalty/campaigns/{id}',
|
|
15988
|
+
'DELETE',
|
|
15989
|
+
`/loyalty/campaigns/${id}`,
|
|
15990
|
+
null,
|
|
15991
|
+
options,
|
|
15992
|
+
);
|
|
15993
|
+
}
|
|
15994
|
+
|
|
15995
|
+
/**
|
|
15996
|
+
* PATCH /loyalty/campaigns/{id}/status - Transition campaign status
|
|
15997
|
+
*
|
|
15998
|
+
* @param id
|
|
15999
|
+
* @param body
|
|
16000
|
+
* @param options - additional request options
|
|
16001
|
+
*/
|
|
16002
|
+
CampaignController_updateStatus(
|
|
16003
|
+
id: string,
|
|
16004
|
+
body: CampaignControllerUpdateStatusBody,
|
|
16005
|
+
options?: RequestOptions,
|
|
16006
|
+
): ResponsePromise<CampaignControllerUpdateStatusResponse> {
|
|
16007
|
+
return this.request(
|
|
16008
|
+
'loyalty',
|
|
16009
|
+
'/loyalty/campaigns/{id}/status',
|
|
16010
|
+
'PATCH',
|
|
16011
|
+
`/loyalty/campaigns/${id}/status`,
|
|
16012
|
+
body,
|
|
16013
|
+
options,
|
|
16014
|
+
);
|
|
16015
|
+
}
|
|
16016
|
+
|
|
16017
|
+
/**
|
|
16018
|
+
* POST /loyalty/campaigns/{id}/clone - Deep clone a campaign and all child entities
|
|
16019
|
+
*
|
|
16020
|
+
* @param id
|
|
16021
|
+
* @param options - additional request options
|
|
16022
|
+
*/
|
|
16023
|
+
CampaignController_clone(
|
|
16024
|
+
id: string,
|
|
16025
|
+
options?: RequestOptions,
|
|
16026
|
+
): ResponsePromise<CampaignControllerCloneResponse> {
|
|
16027
|
+
return this.request(
|
|
16028
|
+
'loyalty',
|
|
16029
|
+
'/loyalty/campaigns/{id}/clone',
|
|
16030
|
+
'POST',
|
|
16031
|
+
`/loyalty/campaigns/${id}/clone`,
|
|
16032
|
+
null,
|
|
16033
|
+
options,
|
|
16034
|
+
);
|
|
16035
|
+
}
|
|
16036
|
+
|
|
16037
|
+
/**
|
|
16038
|
+
* GET /loyalty/vouchers - List vouchers with optional filters
|
|
16039
|
+
*
|
|
16040
|
+
* @param options - additional request options
|
|
16041
|
+
*/
|
|
16042
|
+
VoucherController_findAll(
|
|
16043
|
+
options?: {
|
|
16044
|
+
query?: VoucherControllerFindAllQuery;
|
|
16045
|
+
} & RequestOptions,
|
|
16046
|
+
): ResponsePromise<VoucherControllerFindAllResponse> {
|
|
16047
|
+
return this.request(
|
|
16048
|
+
'loyalty',
|
|
16049
|
+
'/loyalty/vouchers',
|
|
16050
|
+
'GET',
|
|
16051
|
+
`/loyalty/vouchers`,
|
|
16052
|
+
null,
|
|
16053
|
+
options,
|
|
16054
|
+
);
|
|
16055
|
+
}
|
|
16056
|
+
|
|
16057
|
+
/**
|
|
16058
|
+
* POST /loyalty/vouchers - Create a single voucher
|
|
16059
|
+
*
|
|
16060
|
+
* @param body
|
|
16061
|
+
* @param options - additional request options
|
|
16062
|
+
*/
|
|
16063
|
+
VoucherController_create(
|
|
16064
|
+
body: VoucherControllerCreateBody,
|
|
16065
|
+
options?: RequestOptions,
|
|
16066
|
+
): ResponsePromise<VoucherControllerCreateResponse> {
|
|
16067
|
+
return this.request(
|
|
16068
|
+
'loyalty',
|
|
16069
|
+
'/loyalty/vouchers',
|
|
16070
|
+
'POST',
|
|
16071
|
+
`/loyalty/vouchers`,
|
|
16072
|
+
body,
|
|
16073
|
+
options,
|
|
16074
|
+
);
|
|
16075
|
+
}
|
|
16076
|
+
|
|
16077
|
+
/**
|
|
16078
|
+
* GET /loyalty/vouchers/{id} - Get voucher by ID with campaign info and redemption count
|
|
16079
|
+
*
|
|
16080
|
+
* @param id
|
|
16081
|
+
* @param options - additional request options
|
|
16082
|
+
*/
|
|
16083
|
+
VoucherController_findOne(
|
|
16084
|
+
id: string,
|
|
16085
|
+
options?: RequestOptions,
|
|
16086
|
+
): ResponsePromise<VoucherControllerFindOneResponse> {
|
|
16087
|
+
return this.request(
|
|
16088
|
+
'loyalty',
|
|
16089
|
+
'/loyalty/vouchers/{id}',
|
|
16090
|
+
'GET',
|
|
16091
|
+
`/loyalty/vouchers/${id}`,
|
|
16092
|
+
null,
|
|
16093
|
+
options,
|
|
16094
|
+
);
|
|
16095
|
+
}
|
|
16096
|
+
|
|
16097
|
+
/**
|
|
16098
|
+
* PUT /loyalty/vouchers/{id} - Update a voucher
|
|
16099
|
+
*
|
|
16100
|
+
* @param id
|
|
16101
|
+
* @param body
|
|
16102
|
+
* @param options - additional request options
|
|
16103
|
+
*/
|
|
16104
|
+
VoucherController_update(
|
|
16105
|
+
id: string,
|
|
16106
|
+
body: VoucherControllerUpdateBody,
|
|
16107
|
+
options?: RequestOptions,
|
|
16108
|
+
): ResponsePromise<VoucherControllerUpdateResponse> {
|
|
16109
|
+
return this.request(
|
|
16110
|
+
'loyalty',
|
|
16111
|
+
'/loyalty/vouchers/{id}',
|
|
16112
|
+
'PUT',
|
|
16113
|
+
`/loyalty/vouchers/${id}`,
|
|
16114
|
+
body,
|
|
16115
|
+
options,
|
|
16116
|
+
);
|
|
16117
|
+
}
|
|
16118
|
+
|
|
16119
|
+
/**
|
|
16120
|
+
* DELETE /loyalty/vouchers/{id} - Soft-delete a voucher
|
|
16121
|
+
*
|
|
16122
|
+
* @param id
|
|
16123
|
+
* @param options - additional request options
|
|
16124
|
+
*/
|
|
16125
|
+
VoucherController_remove(
|
|
16126
|
+
id: string,
|
|
16127
|
+
options?: RequestOptions,
|
|
16128
|
+
): ResponsePromise<VoucherControllerRemoveResponse> {
|
|
16129
|
+
return this.request(
|
|
16130
|
+
'loyalty',
|
|
16131
|
+
'/loyalty/vouchers/{id}',
|
|
16132
|
+
'DELETE',
|
|
16133
|
+
`/loyalty/vouchers/${id}`,
|
|
16134
|
+
null,
|
|
16135
|
+
options,
|
|
16136
|
+
);
|
|
16137
|
+
}
|
|
16138
|
+
|
|
16139
|
+
/**
|
|
16140
|
+
* POST /loyalty/vouchers/{id}/revoke - Revoke a voucher with a required reason
|
|
16141
|
+
*
|
|
16142
|
+
* @param id
|
|
16143
|
+
* @param body
|
|
16144
|
+
* @param options - additional request options
|
|
16145
|
+
*/
|
|
16146
|
+
VoucherController_revoke(
|
|
16147
|
+
id: string,
|
|
16148
|
+
body: VoucherControllerRevokeBody,
|
|
16149
|
+
options?: RequestOptions,
|
|
16150
|
+
): ResponsePromise<VoucherControllerRevokeResponse> {
|
|
16151
|
+
return this.request(
|
|
16152
|
+
'loyalty',
|
|
16153
|
+
'/loyalty/vouchers/{id}/revoke',
|
|
16154
|
+
'POST',
|
|
16155
|
+
`/loyalty/vouchers/${id}/revoke`,
|
|
16156
|
+
body,
|
|
16157
|
+
options,
|
|
16158
|
+
);
|
|
16159
|
+
}
|
|
16160
|
+
|
|
16161
|
+
/**
|
|
16162
|
+
* POST /loyalty/vouchers/batch - Batch generate voucher codes for a campaign
|
|
16163
|
+
*
|
|
16164
|
+
* @param body
|
|
16165
|
+
* @param options - additional request options
|
|
16166
|
+
*/
|
|
16167
|
+
VoucherController_batchGenerate(
|
|
16168
|
+
body: VoucherControllerBatchGenerateBody,
|
|
16169
|
+
options?: RequestOptions,
|
|
16170
|
+
): ResponsePromise<VoucherControllerBatchGenerateResponse> {
|
|
16171
|
+
return this.request(
|
|
16172
|
+
'loyalty',
|
|
16173
|
+
'/loyalty/vouchers/batch',
|
|
16174
|
+
'POST',
|
|
16175
|
+
`/loyalty/vouchers/batch`,
|
|
16176
|
+
body,
|
|
16177
|
+
options,
|
|
16178
|
+
);
|
|
16179
|
+
}
|
|
16180
|
+
|
|
16181
|
+
/**
|
|
16182
|
+
* GET /loyalty/vouchers/{id}/redemptions - Get redemption history for a voucher
|
|
16183
|
+
*
|
|
16184
|
+
* @param id
|
|
16185
|
+
* @param options - additional request options
|
|
16186
|
+
*/
|
|
16187
|
+
VoucherController_findRedemptions(
|
|
16188
|
+
id: string,
|
|
16189
|
+
options?: {
|
|
16190
|
+
query?: VoucherControllerFindRedemptionsQuery;
|
|
16191
|
+
} & RequestOptions,
|
|
16192
|
+
): ResponsePromise<VoucherControllerFindRedemptionsResponse> {
|
|
16193
|
+
return this.request(
|
|
16194
|
+
'loyalty',
|
|
16195
|
+
'/loyalty/vouchers/{id}/redemptions',
|
|
16196
|
+
'GET',
|
|
16197
|
+
`/loyalty/vouchers/${id}/redemptions`,
|
|
16198
|
+
null,
|
|
16199
|
+
options,
|
|
16200
|
+
);
|
|
16201
|
+
}
|
|
16202
|
+
|
|
16203
|
+
/**
|
|
16204
|
+
* POST /loyalty/vouchers/validate - Validate a voucher code (stub)
|
|
16205
|
+
*
|
|
16206
|
+
* @param options - additional request options
|
|
16207
|
+
*/
|
|
16208
|
+
VoucherController_validate(
|
|
16209
|
+
options?: RequestOptions,
|
|
16210
|
+
): ResponsePromise<VoucherControllerValidateResponse> {
|
|
16211
|
+
return this.request(
|
|
16212
|
+
'loyalty',
|
|
16213
|
+
'/loyalty/vouchers/validate',
|
|
16214
|
+
'POST',
|
|
16215
|
+
`/loyalty/vouchers/validate`,
|
|
16216
|
+
null,
|
|
16217
|
+
options,
|
|
16218
|
+
);
|
|
16219
|
+
}
|
|
16220
|
+
|
|
16221
|
+
/**
|
|
16222
|
+
* POST /loyalty/vouchers/redeem - Redeem a voucher code (stub)
|
|
16223
|
+
*
|
|
16224
|
+
* @param options - additional request options
|
|
16225
|
+
*/
|
|
16226
|
+
VoucherController_redeem(
|
|
16227
|
+
options?: RequestOptions,
|
|
16228
|
+
): ResponsePromise<VoucherControllerRedeemResponse> {
|
|
16229
|
+
return this.request(
|
|
16230
|
+
'loyalty',
|
|
16231
|
+
'/loyalty/vouchers/redeem',
|
|
16232
|
+
'POST',
|
|
16233
|
+
`/loyalty/vouchers/redeem`,
|
|
16234
|
+
null,
|
|
16235
|
+
options,
|
|
16236
|
+
);
|
|
16237
|
+
}
|
|
16238
|
+
|
|
16239
|
+
/**
|
|
16240
|
+
* GET /loyalty/segments - List segments with optional filters
|
|
16241
|
+
*
|
|
16242
|
+
* @param options - additional request options
|
|
16243
|
+
*/
|
|
16244
|
+
SegmentController_findAll(
|
|
16245
|
+
options?: {
|
|
16246
|
+
query?: SegmentControllerFindAllQuery;
|
|
16247
|
+
} & RequestOptions,
|
|
16248
|
+
): ResponsePromise<SegmentControllerFindAllResponse> {
|
|
16249
|
+
return this.request(
|
|
16250
|
+
'loyalty',
|
|
16251
|
+
'/loyalty/segments',
|
|
16252
|
+
'GET',
|
|
16253
|
+
`/loyalty/segments`,
|
|
16254
|
+
null,
|
|
16255
|
+
options,
|
|
16256
|
+
);
|
|
16257
|
+
}
|
|
16258
|
+
|
|
16259
|
+
/**
|
|
16260
|
+
* POST /loyalty/segments - Create a new segment
|
|
16261
|
+
*
|
|
16262
|
+
* @param body
|
|
16263
|
+
* @param options - additional request options
|
|
16264
|
+
*/
|
|
16265
|
+
SegmentController_create(
|
|
16266
|
+
body: SegmentControllerCreateBody,
|
|
16267
|
+
options?: RequestOptions,
|
|
16268
|
+
): ResponsePromise<SegmentControllerCreateResponse> {
|
|
16269
|
+
return this.request(
|
|
16270
|
+
'loyalty',
|
|
16271
|
+
'/loyalty/segments',
|
|
16272
|
+
'POST',
|
|
16273
|
+
`/loyalty/segments`,
|
|
16274
|
+
body,
|
|
16275
|
+
options,
|
|
16276
|
+
);
|
|
16277
|
+
}
|
|
16278
|
+
|
|
16279
|
+
/**
|
|
16280
|
+
* GET /loyalty/segments/attributes - List available attributes for rule-based segments
|
|
16281
|
+
*
|
|
16282
|
+
* @param options - additional request options
|
|
16283
|
+
*/
|
|
16284
|
+
SegmentController_getAttributes(
|
|
16285
|
+
options?: RequestOptions,
|
|
16286
|
+
): ResponsePromise<SegmentControllerGetAttributesResponse> {
|
|
16287
|
+
return this.request(
|
|
16288
|
+
'loyalty',
|
|
16289
|
+
'/loyalty/segments/attributes',
|
|
16290
|
+
'GET',
|
|
16291
|
+
`/loyalty/segments/attributes`,
|
|
16292
|
+
null,
|
|
16293
|
+
options,
|
|
16294
|
+
);
|
|
16295
|
+
}
|
|
16296
|
+
|
|
16297
|
+
/**
|
|
16298
|
+
* POST /loyalty/segments/preview-count - Preview how many customers match a segment rule
|
|
16299
|
+
*
|
|
16300
|
+
* @param options - additional request options
|
|
16301
|
+
*/
|
|
16302
|
+
SegmentController_previewRuleCount(
|
|
16303
|
+
options?: RequestOptions,
|
|
16304
|
+
): ResponsePromise<SegmentControllerPreviewRuleCountResponse> {
|
|
16305
|
+
return this.request(
|
|
16306
|
+
'loyalty',
|
|
16307
|
+
'/loyalty/segments/preview-count',
|
|
16308
|
+
'POST',
|
|
16309
|
+
`/loyalty/segments/preview-count`,
|
|
16310
|
+
null,
|
|
16311
|
+
options,
|
|
16312
|
+
);
|
|
16313
|
+
}
|
|
16314
|
+
|
|
16315
|
+
/**
|
|
16316
|
+
* GET /loyalty/segments/{id} - Get segment by ID
|
|
16317
|
+
*
|
|
16318
|
+
* @param id
|
|
16319
|
+
* @param options - additional request options
|
|
16320
|
+
*/
|
|
16321
|
+
SegmentController_findOne(
|
|
16322
|
+
id: string,
|
|
16323
|
+
options?: RequestOptions,
|
|
16324
|
+
): ResponsePromise<SegmentControllerFindOneResponse> {
|
|
16325
|
+
return this.request(
|
|
16326
|
+
'loyalty',
|
|
16327
|
+
'/loyalty/segments/{id}',
|
|
16328
|
+
'GET',
|
|
16329
|
+
`/loyalty/segments/${id}`,
|
|
16330
|
+
null,
|
|
16331
|
+
options,
|
|
16332
|
+
);
|
|
16333
|
+
}
|
|
16334
|
+
|
|
16335
|
+
/**
|
|
16336
|
+
* PATCH /loyalty/segments/{id} - Update a segment
|
|
16337
|
+
*
|
|
16338
|
+
* @param id
|
|
16339
|
+
* @param body
|
|
16340
|
+
* @param options - additional request options
|
|
16341
|
+
*/
|
|
16342
|
+
SegmentController_update(
|
|
16343
|
+
id: string,
|
|
16344
|
+
body: SegmentControllerUpdateBody,
|
|
16345
|
+
options?: RequestOptions,
|
|
16346
|
+
): ResponsePromise<SegmentControllerUpdateResponse> {
|
|
16347
|
+
return this.request(
|
|
16348
|
+
'loyalty',
|
|
16349
|
+
'/loyalty/segments/{id}',
|
|
16350
|
+
'PATCH',
|
|
16351
|
+
`/loyalty/segments/${id}`,
|
|
16352
|
+
body,
|
|
16353
|
+
options,
|
|
16354
|
+
);
|
|
16355
|
+
}
|
|
16356
|
+
|
|
16357
|
+
/**
|
|
16358
|
+
* DELETE /loyalty/segments/{id} - Soft-delete a segment
|
|
16359
|
+
*
|
|
16360
|
+
* @param id
|
|
16361
|
+
* @param options - additional request options
|
|
16362
|
+
*/
|
|
16363
|
+
SegmentController_remove(
|
|
16364
|
+
id: string,
|
|
16365
|
+
options?: RequestOptions,
|
|
16366
|
+
): ResponsePromise<SegmentControllerRemoveResponse> {
|
|
16367
|
+
return this.request(
|
|
16368
|
+
'loyalty',
|
|
16369
|
+
'/loyalty/segments/{id}',
|
|
16370
|
+
'DELETE',
|
|
16371
|
+
`/loyalty/segments/${id}`,
|
|
16372
|
+
null,
|
|
16373
|
+
options,
|
|
16374
|
+
);
|
|
16375
|
+
}
|
|
16376
|
+
|
|
16377
|
+
/**
|
|
16378
|
+
* GET /loyalty/segments/{id}/members - List members of a static_list segment
|
|
16379
|
+
*
|
|
16380
|
+
* @param id
|
|
16381
|
+
* @param options - additional request options
|
|
16382
|
+
*/
|
|
16383
|
+
SegmentController_findMembers(
|
|
16384
|
+
id: string,
|
|
16385
|
+
options?: {
|
|
16386
|
+
query?: SegmentControllerFindMembersQuery;
|
|
16387
|
+
} & RequestOptions,
|
|
16388
|
+
): ResponsePromise<SegmentControllerFindMembersResponse> {
|
|
16389
|
+
return this.request(
|
|
16390
|
+
'loyalty',
|
|
16391
|
+
'/loyalty/segments/{id}/members',
|
|
16392
|
+
'GET',
|
|
16393
|
+
`/loyalty/segments/${id}/members`,
|
|
16394
|
+
null,
|
|
16395
|
+
options,
|
|
16396
|
+
);
|
|
16397
|
+
}
|
|
16398
|
+
|
|
16399
|
+
/**
|
|
16400
|
+
* POST /loyalty/segments/{id}/members - Add members to a segment
|
|
16401
|
+
*
|
|
16402
|
+
* @param id
|
|
16403
|
+
* @param body
|
|
16404
|
+
* @param options - additional request options
|
|
16405
|
+
*/
|
|
16406
|
+
SegmentController_addMembers(
|
|
16407
|
+
id: string,
|
|
16408
|
+
body: SegmentControllerAddMembersBody,
|
|
16409
|
+
options?: RequestOptions,
|
|
16410
|
+
): ResponsePromise<SegmentControllerAddMembersResponse> {
|
|
16411
|
+
return this.request(
|
|
16412
|
+
'loyalty',
|
|
16413
|
+
'/loyalty/segments/{id}/members',
|
|
16414
|
+
'POST',
|
|
16415
|
+
`/loyalty/segments/${id}/members`,
|
|
16416
|
+
body,
|
|
16417
|
+
options,
|
|
16418
|
+
);
|
|
16419
|
+
}
|
|
16420
|
+
|
|
16421
|
+
/**
|
|
16422
|
+
* DELETE /loyalty/segments/{id}/members - Remove members from a segment
|
|
16423
|
+
*
|
|
16424
|
+
* @param id
|
|
16425
|
+
* @param body
|
|
16426
|
+
* @param options - additional request options
|
|
16427
|
+
*/
|
|
16428
|
+
SegmentController_removeMembers(
|
|
16429
|
+
id: string,
|
|
16430
|
+
body: SegmentControllerRemoveMembersBody,
|
|
16431
|
+
options?: RequestOptions,
|
|
16432
|
+
): ResponsePromise<SegmentControllerRemoveMembersResponse> {
|
|
16433
|
+
return this.request(
|
|
16434
|
+
'loyalty',
|
|
16435
|
+
'/loyalty/segments/{id}/members',
|
|
16436
|
+
'DELETE',
|
|
16437
|
+
`/loyalty/segments/${id}/members`,
|
|
16438
|
+
body,
|
|
16439
|
+
options,
|
|
16440
|
+
);
|
|
16441
|
+
}
|
|
16442
|
+
|
|
16443
|
+
/**
|
|
16444
|
+
* POST /loyalty/redemptions/{id}/rollback - Roll back a redemption and restore the voucher
|
|
16445
|
+
*
|
|
16446
|
+
* @param id
|
|
16447
|
+
* @param body
|
|
16448
|
+
* @param options - additional request options
|
|
16449
|
+
*/
|
|
16450
|
+
RedemptionController_rollback(
|
|
16451
|
+
id: string,
|
|
16452
|
+
body: RedemptionControllerRollbackBody,
|
|
16453
|
+
options?: RequestOptions,
|
|
16454
|
+
): ResponsePromise<RedemptionControllerRollbackResponse> {
|
|
16455
|
+
return this.request(
|
|
16456
|
+
'loyalty',
|
|
16457
|
+
'/loyalty/redemptions/{id}/rollback',
|
|
16458
|
+
'POST',
|
|
16459
|
+
`/loyalty/redemptions/${id}/rollback`,
|
|
16460
|
+
body,
|
|
16461
|
+
options,
|
|
16462
|
+
);
|
|
16463
|
+
}
|
|
16464
|
+
|
|
16465
|
+
/**
|
|
16466
|
+
* GET /loyalty/loyalty/programs - List loyalty programs with filters and pagination
|
|
16467
|
+
*
|
|
16468
|
+
* @param options - additional request options
|
|
16469
|
+
*/
|
|
16470
|
+
LoyaltyController_listPrograms(
|
|
16471
|
+
options?: {
|
|
16472
|
+
query?: LoyaltyControllerListProgramsQuery;
|
|
16473
|
+
} & RequestOptions,
|
|
16474
|
+
): ResponsePromise<LoyaltyControllerListProgramsResponse> {
|
|
16475
|
+
return this.request(
|
|
16476
|
+
'loyalty',
|
|
16477
|
+
'/loyalty/loyalty/programs',
|
|
16478
|
+
'GET',
|
|
16479
|
+
`/loyalty/loyalty/programs`,
|
|
16480
|
+
null,
|
|
16481
|
+
options,
|
|
16482
|
+
);
|
|
16483
|
+
}
|
|
16484
|
+
|
|
16485
|
+
/**
|
|
16486
|
+
* POST /loyalty/loyalty/programs - Create a loyalty program with earning rules and milestones
|
|
16487
|
+
*
|
|
16488
|
+
* @param body
|
|
16489
|
+
* @param options - additional request options
|
|
16490
|
+
*/
|
|
16491
|
+
LoyaltyController_createProgram(
|
|
16492
|
+
body: LoyaltyControllerCreateProgramBody,
|
|
16493
|
+
options?: RequestOptions,
|
|
16494
|
+
): ResponsePromise<LoyaltyControllerCreateProgramResponse> {
|
|
16495
|
+
return this.request(
|
|
16496
|
+
'loyalty',
|
|
16497
|
+
'/loyalty/loyalty/programs',
|
|
16498
|
+
'POST',
|
|
16499
|
+
`/loyalty/loyalty/programs`,
|
|
16500
|
+
body,
|
|
16501
|
+
options,
|
|
16502
|
+
);
|
|
16503
|
+
}
|
|
16504
|
+
|
|
16505
|
+
/**
|
|
16506
|
+
* GET /loyalty/loyalty/programs/{id} - Get loyalty program detail with earning rules and milestones
|
|
16507
|
+
*
|
|
16508
|
+
* @param id
|
|
16509
|
+
* @param options - additional request options
|
|
16510
|
+
*/
|
|
16511
|
+
LoyaltyController_findOneProgram(
|
|
16512
|
+
id: string,
|
|
16513
|
+
options?: RequestOptions,
|
|
16514
|
+
): ResponsePromise<LoyaltyControllerFindOneProgramResponse> {
|
|
16515
|
+
return this.request(
|
|
16516
|
+
'loyalty',
|
|
16517
|
+
'/loyalty/loyalty/programs/{id}',
|
|
16518
|
+
'GET',
|
|
16519
|
+
`/loyalty/loyalty/programs/${id}`,
|
|
16520
|
+
null,
|
|
16521
|
+
options,
|
|
16522
|
+
);
|
|
16523
|
+
}
|
|
16524
|
+
|
|
16525
|
+
/**
|
|
16526
|
+
* PUT /loyalty/loyalty/programs/{id} - Update a loyalty program and replace its earning rules and milestones
|
|
16527
|
+
*
|
|
16528
|
+
* @param id
|
|
16529
|
+
* @param body
|
|
16530
|
+
* @param options - additional request options
|
|
16531
|
+
*/
|
|
16532
|
+
LoyaltyController_updateProgram(
|
|
16533
|
+
id: string,
|
|
16534
|
+
body: LoyaltyControllerUpdateProgramBody,
|
|
16535
|
+
options?: RequestOptions,
|
|
16536
|
+
): ResponsePromise<LoyaltyControllerUpdateProgramResponse> {
|
|
16537
|
+
return this.request(
|
|
16538
|
+
'loyalty',
|
|
16539
|
+
'/loyalty/loyalty/programs/{id}',
|
|
16540
|
+
'PUT',
|
|
16541
|
+
`/loyalty/loyalty/programs/${id}`,
|
|
16542
|
+
body,
|
|
16543
|
+
options,
|
|
16544
|
+
);
|
|
16545
|
+
}
|
|
16546
|
+
|
|
16547
|
+
/**
|
|
16548
|
+
* PATCH /loyalty/loyalty/programs/{id}/status - Transition loyalty program status
|
|
16549
|
+
*
|
|
16550
|
+
* @param id
|
|
16551
|
+
* @param body
|
|
16552
|
+
* @param options - additional request options
|
|
16553
|
+
*/
|
|
16554
|
+
LoyaltyController_updateProgramStatus(
|
|
16555
|
+
id: string,
|
|
16556
|
+
body: LoyaltyControllerUpdateProgramStatusBody,
|
|
16557
|
+
options?: RequestOptions,
|
|
16558
|
+
): ResponsePromise<LoyaltyControllerUpdateProgramStatusResponse> {
|
|
16559
|
+
return this.request(
|
|
16560
|
+
'loyalty',
|
|
16561
|
+
'/loyalty/loyalty/programs/{id}/status',
|
|
16562
|
+
'PATCH',
|
|
16563
|
+
`/loyalty/loyalty/programs/${id}/status`,
|
|
16564
|
+
body,
|
|
16565
|
+
options,
|
|
16566
|
+
);
|
|
16567
|
+
}
|
|
16568
|
+
|
|
16569
|
+
/**
|
|
16570
|
+
* GET /loyalty/loyalty/programs/{id}/cards - List enrolled customer cards for a program
|
|
16571
|
+
*
|
|
16572
|
+
* @param id
|
|
16573
|
+
* @param options - additional request options
|
|
16574
|
+
*/
|
|
16575
|
+
LoyaltyController_listCards(
|
|
16576
|
+
id: string,
|
|
16577
|
+
options?: {
|
|
16578
|
+
query?: LoyaltyControllerListCardsQuery;
|
|
16579
|
+
} & RequestOptions,
|
|
16580
|
+
): ResponsePromise<LoyaltyControllerListCardsResponse> {
|
|
16581
|
+
return this.request(
|
|
16582
|
+
'loyalty',
|
|
16583
|
+
'/loyalty/loyalty/programs/{id}/cards',
|
|
16584
|
+
'GET',
|
|
16585
|
+
`/loyalty/loyalty/programs/${id}/cards`,
|
|
16586
|
+
null,
|
|
16587
|
+
options,
|
|
16588
|
+
);
|
|
16589
|
+
}
|
|
16590
|
+
|
|
16591
|
+
/**
|
|
16592
|
+
* GET /loyalty/loyalty/programs/{id}/cards/{customerId} - Get card detail with transaction event history
|
|
16593
|
+
*
|
|
16594
|
+
* @param id
|
|
16595
|
+
* @param customerId
|
|
16596
|
+
* @param options - additional request options
|
|
16597
|
+
*/
|
|
16598
|
+
LoyaltyController_findCard(
|
|
16599
|
+
id: string,
|
|
16600
|
+
customerId: string,
|
|
16601
|
+
options?: RequestOptions,
|
|
16602
|
+
): ResponsePromise<LoyaltyControllerFindCardResponse> {
|
|
16603
|
+
return this.request(
|
|
16604
|
+
'loyalty',
|
|
16605
|
+
'/loyalty/loyalty/programs/{id}/cards/{customerId}',
|
|
16606
|
+
'GET',
|
|
16607
|
+
`/loyalty/loyalty/programs/${id}/cards/${customerId}`,
|
|
16608
|
+
null,
|
|
16609
|
+
options,
|
|
16610
|
+
);
|
|
16611
|
+
}
|
|
16612
|
+
|
|
16613
|
+
/**
|
|
16614
|
+
* POST /loyalty/loyalty/cards/{cardId}/adjust - Manual point adjustment on a loyalty card
|
|
16615
|
+
*
|
|
16616
|
+
* @param cardId
|
|
16617
|
+
* @param body
|
|
16618
|
+
* @param options - additional request options
|
|
16619
|
+
*/
|
|
16620
|
+
LoyaltyController_adjustPoints(
|
|
16621
|
+
cardId: string,
|
|
16622
|
+
body: LoyaltyControllerAdjustPointsBody,
|
|
16623
|
+
options?: RequestOptions,
|
|
16624
|
+
): ResponsePromise<LoyaltyControllerAdjustPointsResponse> {
|
|
16625
|
+
return this.request(
|
|
16626
|
+
'loyalty',
|
|
16627
|
+
'/loyalty/loyalty/cards/{cardId}/adjust',
|
|
16628
|
+
'POST',
|
|
16629
|
+
`/loyalty/loyalty/cards/${cardId}/adjust`,
|
|
16630
|
+
body,
|
|
16631
|
+
options,
|
|
16632
|
+
);
|
|
16633
|
+
}
|
|
16634
|
+
|
|
15721
16635
|
/**
|
|
15722
16636
|
* GET /timeslots/brand/{brandId} - Get timeslots for brand
|
|
15723
16637
|
*
|