@compassdigital/sdk.typescript 4.794.0 → 4.796.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 +12 -33
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +13 -40
- package/lib/index.js.map +1 -1
- package/lib/interface/centricos.d.ts +6 -80
- package/lib/interface/centricos.d.ts.map +1 -1
- package/lib/interface/user.d.ts +7 -0
- package/lib/interface/user.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/index.ts +29 -94
- package/src/interface/centricos.ts +9 -145
- package/src/interface/user.ts +12 -0
|
@@ -774,7 +774,7 @@ export interface CentricDiscountSchedule {
|
|
|
774
774
|
endTime: string;
|
|
775
775
|
}
|
|
776
776
|
|
|
777
|
-
export interface
|
|
777
|
+
export interface PutDiscountVoucherifyRequestDiscount {
|
|
778
778
|
// name of the discount
|
|
779
779
|
name: string;
|
|
780
780
|
// Discount method configuration
|
|
@@ -784,7 +784,7 @@ export interface PutCentricDiscountRequestDiscount {
|
|
|
784
784
|
// item level config of the discount
|
|
785
785
|
itemLevelConfig?: CentricDiscountItemLevelConfig;
|
|
786
786
|
is?: CentricDiscountIs;
|
|
787
|
-
//
|
|
787
|
+
// Voucherify metadata
|
|
788
788
|
meta?: CentricVoucherifyMetaDataDiscount;
|
|
789
789
|
// discount schedule
|
|
790
790
|
schedule?: CentricDiscountSchedule;
|
|
@@ -845,9 +845,9 @@ export interface DiscountBrand {
|
|
|
845
845
|
meta: DiscountBrandMeta;
|
|
846
846
|
}
|
|
847
847
|
|
|
848
|
-
export interface
|
|
848
|
+
export interface PutDiscountVoucherifyRequestDTO {
|
|
849
849
|
// Discount to update
|
|
850
|
-
discount:
|
|
850
|
+
discount: PutDiscountVoucherifyRequestDiscount;
|
|
851
851
|
// List of sites with metadata
|
|
852
852
|
sites?: DiscountSite[];
|
|
853
853
|
// List of brands with metadata
|
|
@@ -882,7 +882,7 @@ export interface DiscountResponseDTO {
|
|
|
882
882
|
type: 'Total Order' | 'Single Items' | 'Bundle';
|
|
883
883
|
// item level config of the discount
|
|
884
884
|
itemLevelConfig?: CentricDiscountItemLevelConfig;
|
|
885
|
-
//
|
|
885
|
+
// Voucherify metadata
|
|
886
886
|
meta?: CentricVoucherifyMetaDataDiscount;
|
|
887
887
|
id: string;
|
|
888
888
|
createdAt: string;
|
|
@@ -891,7 +891,7 @@ export interface DiscountResponseDTO {
|
|
|
891
891
|
schedule?: Record<string, any>;
|
|
892
892
|
}
|
|
893
893
|
|
|
894
|
-
export interface
|
|
894
|
+
export interface PutDiscountVoucherifyResponseDTO {
|
|
895
895
|
// Discount details
|
|
896
896
|
discount: DiscountResponseDTO;
|
|
897
897
|
// List of sites with metadata
|
|
@@ -915,73 +915,6 @@ export interface CentricDiscountMeta {
|
|
|
915
915
|
provider: CentricMetaProvider;
|
|
916
916
|
}
|
|
917
917
|
|
|
918
|
-
export interface PutCentricDiscountPublishResponseDTO {
|
|
919
|
-
// user is of discount creator
|
|
920
|
-
createdBy: string;
|
|
921
|
-
// last user who updated the discount
|
|
922
|
-
updatedBy: string;
|
|
923
|
-
// name of the discount
|
|
924
|
-
name: string;
|
|
925
|
-
// status of the discount
|
|
926
|
-
status: CentricDiscountStatus;
|
|
927
|
-
// Discount method configuration
|
|
928
|
-
method: CentricDiscountMethod;
|
|
929
|
-
// channel config of the discount
|
|
930
|
-
channelConfig: CentricDiscountChannelConfig;
|
|
931
|
-
// type of the discount
|
|
932
|
-
type: 'Total Order' | 'Single Items' | 'Bundle';
|
|
933
|
-
// item level config of the discount
|
|
934
|
-
itemLevelConfig?: CentricDiscountItemLevelConfig;
|
|
935
|
-
// discount metadata
|
|
936
|
-
meta?: CentricDiscountMeta;
|
|
937
|
-
// List of sites where discount is published
|
|
938
|
-
sites?: CentricDiscountEntityBase[];
|
|
939
|
-
id: string;
|
|
940
|
-
createdAt: string;
|
|
941
|
-
updatedAt: string;
|
|
942
|
-
is?: CentricDiscountIs;
|
|
943
|
-
schedule?: Record<string, any>;
|
|
944
|
-
}
|
|
945
|
-
|
|
946
|
-
export interface PutDiscountVoucherifyRequestDiscount {
|
|
947
|
-
// name of the discount
|
|
948
|
-
name: string;
|
|
949
|
-
// Discount method configuration
|
|
950
|
-
method: CentricDiscountMethod;
|
|
951
|
-
// channel config of the discount
|
|
952
|
-
channelConfig: CentricDiscountChannelConfig;
|
|
953
|
-
// item level config of the discount
|
|
954
|
-
itemLevelConfig?: CentricDiscountItemLevelConfig;
|
|
955
|
-
is?: CentricDiscountIs;
|
|
956
|
-
// discount metadata
|
|
957
|
-
meta?: CentricVoucherifyMetaDataDiscount;
|
|
958
|
-
// discount schedule
|
|
959
|
-
schedule?: CentricDiscountSchedule;
|
|
960
|
-
id?: string;
|
|
961
|
-
// discount active status flag
|
|
962
|
-
active?: boolean;
|
|
963
|
-
// type of the discount
|
|
964
|
-
type?: 'Total Order' | 'Single Items' | 'Bundle';
|
|
965
|
-
}
|
|
966
|
-
|
|
967
|
-
export interface PutDiscountVoucherifyRequestDTO {
|
|
968
|
-
// Discount to update
|
|
969
|
-
discount: PutDiscountVoucherifyRequestDiscount;
|
|
970
|
-
// List of sites with metadata
|
|
971
|
-
sites?: DiscountSite[];
|
|
972
|
-
// List of brands with metadata
|
|
973
|
-
brands?: DiscountBrand[];
|
|
974
|
-
}
|
|
975
|
-
|
|
976
|
-
export interface PutDiscountVoucherifyResponseDTO {
|
|
977
|
-
// Discount details
|
|
978
|
-
discount: DiscountResponseDTO;
|
|
979
|
-
// List of sites with metadata
|
|
980
|
-
sites: DiscountSite[];
|
|
981
|
-
// List of brands with metadata
|
|
982
|
-
brands: DiscountBrand[];
|
|
983
|
-
}
|
|
984
|
-
|
|
985
918
|
export interface PutDiscountVoucherifyPublishResponseDTO {
|
|
986
919
|
// user is of discount creator
|
|
987
920
|
createdBy: string;
|
|
@@ -1010,10 +943,6 @@ export interface PutDiscountVoucherifyPublishResponseDTO {
|
|
|
1010
943
|
schedule?: Record<string, any>;
|
|
1011
944
|
}
|
|
1012
945
|
|
|
1013
|
-
export interface DeleteCentricDiscountResponseDTO {
|
|
1014
|
-
success: boolean;
|
|
1015
|
-
}
|
|
1016
|
-
|
|
1017
946
|
export interface DeleteDiscountsVoucherifyResponseDTO {
|
|
1018
947
|
success: boolean;
|
|
1019
948
|
}
|
|
@@ -1213,36 +1142,6 @@ export interface DeleteBusinessUnitResponse {
|
|
|
1213
1142
|
success: boolean;
|
|
1214
1143
|
}
|
|
1215
1144
|
|
|
1216
|
-
export interface BusinessUnitCustomTimeslotDto {
|
|
1217
|
-
// Window start, HH:mm on a 24 hour clock
|
|
1218
|
-
start_time: string;
|
|
1219
|
-
// Window end, HH:mm on a 24 hour clock
|
|
1220
|
-
end_time: string;
|
|
1221
|
-
// Delivery destination names served during this window
|
|
1222
|
-
destinations: string[];
|
|
1223
|
-
}
|
|
1224
|
-
|
|
1225
|
-
export interface PutBusinessUnitDropOffRequest {
|
|
1226
|
-
// How drop-off timeslots are generated for the business unit
|
|
1227
|
-
mode?: 'automatic' | 'custom';
|
|
1228
|
-
// Delivery destination names served all day. Replaces the stored list.
|
|
1229
|
-
destinations?: string[];
|
|
1230
|
-
// Caller-defined delivery windows. Replaces the stored list.
|
|
1231
|
-
custom_timeslots?: BusinessUnitCustomTimeslotDto[];
|
|
1232
|
-
// Whether guests see a single timeslot instead of a list
|
|
1233
|
-
show_single_timeslot?: boolean;
|
|
1234
|
-
// Whether guests can leave drop-off instructions
|
|
1235
|
-
show_instructions?: boolean;
|
|
1236
|
-
// Whether the runner app is enabled for the business unit
|
|
1237
|
-
runner_app_enabled?: boolean;
|
|
1238
|
-
// Delivery fee in dollars. Send null to remove it; omit to leave it as is.
|
|
1239
|
-
fee?: number | null;
|
|
1240
|
-
}
|
|
1241
|
-
|
|
1242
|
-
export interface PutBusinessUnitDropOffResponse {
|
|
1243
|
-
success: boolean;
|
|
1244
|
-
}
|
|
1245
|
-
|
|
1246
1145
|
export interface GlobalMenuGroupPublishedBrand {
|
|
1247
1146
|
id: string;
|
|
1248
1147
|
name: string;
|
|
@@ -1805,21 +1704,6 @@ export interface DeleteCentricosStationIntegrationPath {
|
|
|
1805
1704
|
|
|
1806
1705
|
export type DeleteCentricosStationIntegrationResponse = DeleteStationIntegrationResponse;
|
|
1807
1706
|
|
|
1808
|
-
// PUT /centricos/discount - Add or Update a discount and assign it to multiple sites
|
|
1809
|
-
|
|
1810
|
-
export type PutCentricosDiscountBody = PutCentricDiscountRequestDTO;
|
|
1811
|
-
|
|
1812
|
-
export type PutCentricosDiscountResponse = PutCentricDiscountResponseDTO;
|
|
1813
|
-
|
|
1814
|
-
// PUT /centricos/discount/{id}/publish - Update and publish a discount and assign it to multiple sites
|
|
1815
|
-
|
|
1816
|
-
export interface PutCentricosDiscountPublishPath {
|
|
1817
|
-
// Discount ID
|
|
1818
|
-
id: string;
|
|
1819
|
-
}
|
|
1820
|
-
|
|
1821
|
-
export type PutCentricosDiscountPublishResponse = PutCentricDiscountPublishResponseDTO;
|
|
1822
|
-
|
|
1823
1707
|
// PUT /centricos/discount/voucherify - Add or Update a voucherify discount and assign it to multiple sites
|
|
1824
1708
|
|
|
1825
1709
|
export type PutCentricosDiscountVoucherifyBody = PutDiscountVoucherifyRequestDTO;
|
|
@@ -1835,14 +1719,14 @@ export interface PutCentricosDiscountVoucherifyPublishPath {
|
|
|
1835
1719
|
|
|
1836
1720
|
export type PutCentricosDiscountVoucherifyPublishResponse = PutDiscountVoucherifyPublishResponseDTO;
|
|
1837
1721
|
|
|
1838
|
-
// DELETE /centricos/discount/{id} - Delete a discount and all of its entity associations
|
|
1722
|
+
// DELETE /centricos/discount/{id}/voucherify - Delete a discount from voucherify and all of its entity associations
|
|
1839
1723
|
|
|
1840
|
-
export interface
|
|
1724
|
+
export interface DeleteCentricosDiscountsVoucherifyPath {
|
|
1841
1725
|
// Discount ID
|
|
1842
1726
|
id: string;
|
|
1843
1727
|
}
|
|
1844
1728
|
|
|
1845
|
-
export type
|
|
1729
|
+
export type DeleteCentricosDiscountsVoucherifyResponse = DeleteDiscountsVoucherifyResponseDTO;
|
|
1846
1730
|
|
|
1847
1731
|
// GET /centricos/discount/{id} - Get discount information by ID
|
|
1848
1732
|
|
|
@@ -1853,15 +1737,6 @@ export interface GetCentricosDiscountPath {
|
|
|
1853
1737
|
|
|
1854
1738
|
export type GetCentricosDiscountResponse = GetDiscountResponseDTO;
|
|
1855
1739
|
|
|
1856
|
-
// DELETE /centricos/discount/{id}/voucherify - Delete a discount from voucherify and all of its entity associations
|
|
1857
|
-
|
|
1858
|
-
export interface DeleteCentricosDiscountsVoucherifyPath {
|
|
1859
|
-
// Discount ID
|
|
1860
|
-
id: string;
|
|
1861
|
-
}
|
|
1862
|
-
|
|
1863
|
-
export type DeleteCentricosDiscountsVoucherifyResponse = DeleteDiscountsVoucherifyResponseDTO;
|
|
1864
|
-
|
|
1865
1740
|
// GET /centricos/discounts - Get discounts with pagination and filtering
|
|
1866
1741
|
|
|
1867
1742
|
export interface GetCentricosDiscountsQuery {
|
|
@@ -1967,17 +1842,6 @@ export interface DeleteCentricosBusinessUnitPath {
|
|
|
1967
1842
|
|
|
1968
1843
|
export type DeleteCentricosBusinessUnitResponse = DeleteBusinessUnitResponse;
|
|
1969
1844
|
|
|
1970
|
-
// PUT /centricos/business-unit/{bu_id}/drop-off - Update shared drop-off settings for a business unit
|
|
1971
|
-
|
|
1972
|
-
export interface PutCentricosBusinessUnitDropOffPath {
|
|
1973
|
-
// TODO: cannot use CompassLongID as path parameter
|
|
1974
|
-
bu_id: string;
|
|
1975
|
-
}
|
|
1976
|
-
|
|
1977
|
-
export type PutCentricosBusinessUnitDropOffBody = PutBusinessUnitDropOffRequest;
|
|
1978
|
-
|
|
1979
|
-
export type PutCentricosBusinessUnitDropOffResponse = PutBusinessUnitDropOffResponse;
|
|
1980
|
-
|
|
1981
1845
|
// GET /centricos/menu/global-menu-groups - Get a paginated list of global menu groups with filtering, sorting, and relationships
|
|
1982
1846
|
|
|
1983
1847
|
export interface GetCentricosMenuGlobalMenuGroupsQuery {
|
package/src/interface/user.ts
CHANGED
|
@@ -636,6 +636,18 @@ export interface GetUserSecretRequest
|
|
|
636
636
|
RequestQuery<GetUserSecretQuery>,
|
|
637
637
|
GetUserSecretPath {}
|
|
638
638
|
|
|
639
|
+
// DELETE /user/{id}/secret/{key} - Delete a secret key
|
|
640
|
+
|
|
641
|
+
export interface DeleteUserSecretPath {
|
|
642
|
+
// User ID
|
|
643
|
+
id: string;
|
|
644
|
+
key: string;
|
|
645
|
+
}
|
|
646
|
+
|
|
647
|
+
export type DeleteUserSecretResponse = success;
|
|
648
|
+
|
|
649
|
+
export interface DeleteUserSecretRequest extends BaseRequest, DeleteUserSecretPath {}
|
|
650
|
+
|
|
639
651
|
// POST /user/forgotpassword - Reset the users password
|
|
640
652
|
|
|
641
653
|
export interface PostUserResetPasswordQuery {
|