@compassdigital/sdk.typescript 3.10.0 → 3.11.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.
@@ -5,6 +5,76 @@ export interface Error {
5
5
  code?: number;
6
6
  }
7
7
 
8
+ export interface ApplicationPostBody {
9
+ name: string;
10
+ phone: string;
11
+ description?: string;
12
+ email: string;
13
+ // Property to store any additional data
14
+ meta?: {
15
+ website?: string;
16
+ // Contact info
17
+ contact?: {
18
+ first_name?: string;
19
+ last_name?: string;
20
+ phone_number?: string;
21
+ };
22
+ [index: string]: any;
23
+ };
24
+ captcha_token: string;
25
+ }
26
+
27
+ export interface ApplicationPatchBody {
28
+ // application
29
+ id?: string;
30
+ name?: string;
31
+ description?: string;
32
+ email?: string;
33
+ phone?: string;
34
+ // Property to store any additional data
35
+ meta?: {
36
+ website?: string;
37
+ // Contact info
38
+ contact?: {
39
+ first_name?: string;
40
+ last_name?: string;
41
+ phone_number?: string;
42
+ };
43
+ [index: string]: any;
44
+ };
45
+ status?: string;
46
+ }
47
+
48
+ export interface Application {
49
+ // application
50
+ id?: string;
51
+ date_created?: string;
52
+ date_modified?: string;
53
+ name?: string;
54
+ description?: string;
55
+ email?: string;
56
+ phone?: string;
57
+ // Property to store any additional data
58
+ meta?: {
59
+ website?: string;
60
+ // Contact info
61
+ contact?: {
62
+ first_name?: string;
63
+ last_name?: string;
64
+ phone_number?: string;
65
+ };
66
+ // vendor
67
+ vendor_id?: string;
68
+ [index: string]: any;
69
+ };
70
+ status?: string;
71
+ }
72
+
73
+ export interface Applications {
74
+ last_evaluated_key?: string;
75
+ applications: Application[];
76
+ }
77
+
8
78
  export interface Vendor {
9
79
  // vendor
10
80
  id?: string;
@@ -19,6 +89,14 @@ export interface Vendor {
19
89
  staging?: string;
20
90
  v1?: string;
21
91
  };
92
+ website?: string;
93
+ // Contact info
94
+ contact?: {
95
+ first_name?: string;
96
+ last_name?: string;
97
+ phone_number?: string;
98
+ };
99
+ reset_token?: string;
22
100
  [index: string]: any;
23
101
  };
24
102
  domain?: string;
@@ -30,6 +108,23 @@ export interface VendorPostBody {
30
108
  email: string;
31
109
  domain?: string;
32
110
  phone?: string;
111
+ // Property to store any additional data
112
+ meta?: {
113
+ legacy_token?: {
114
+ dev?: string;
115
+ staging?: string;
116
+ v1?: string;
117
+ };
118
+ website?: string;
119
+ reset_token?: string;
120
+ // Contact info
121
+ contact?: {
122
+ first_name?: string;
123
+ last_name?: string;
124
+ phone_number?: string;
125
+ };
126
+ [index: string]: any;
127
+ };
33
128
  }
34
129
 
35
130
  export interface Vendors {
@@ -70,6 +165,7 @@ export interface KeyPatchBody {
70
165
  }
71
166
 
72
167
  export interface Keys {
168
+ last_evaluated_key?: string;
73
169
  keys: Key[];
74
170
  }
75
171
 
@@ -93,6 +189,48 @@ export interface RefreshPayload {
93
189
  refresh_token: string;
94
190
  }
95
191
 
192
+ export interface ResetPassword {
193
+ reset_token: string;
194
+ password: string;
195
+ }
196
+
197
+ // POST /vendor/application - Create a new application for review
198
+
199
+ export type PostVendorApplicationBody = ApplicationPostBody;
200
+
201
+ export type PostVendorApplicationResponse = Application;
202
+
203
+ export interface PostVendorApplicationRequest {
204
+ body: PostVendorApplicationBody;
205
+ }
206
+
207
+ // GET /vendor/application - Get a list of all applications
208
+
209
+ export interface GetVendorApplicationQuery {
210
+ status?: string;
211
+ // Pagination token to start query from
212
+ last_evaluated_key?: string;
213
+ }
214
+
215
+ export type GetVendorApplicationResponse = Applications;
216
+
217
+ export interface GetVendorApplicationRequest extends GetVendorApplicationQuery {}
218
+
219
+ // PATCH /vendor/application/{id} - Update an application (or update status)
220
+
221
+ export interface PatchVendorApplicationPath {
222
+ // TODO: add parameter to swagger.json
223
+ id: string;
224
+ }
225
+
226
+ export type PatchVendorApplicationBody = ApplicationPatchBody;
227
+
228
+ export type PatchVendorApplicationResponse = Application;
229
+
230
+ export interface PatchVendorApplicationRequest extends PatchVendorApplicationPath {
231
+ body: PatchVendorApplicationBody;
232
+ }
233
+
96
234
  // POST /vendor - Create new vendor
97
235
 
98
236
  export type PostVendorBody = VendorPostBody;
@@ -243,3 +381,18 @@ export type PostVendorKeyRotateResponse = Success;
243
381
  export interface PostVendorKeyRotateRequest
244
382
  extends PostVendorKeyRotateQuery,
245
383
  PostVendorKeyRotatePath {}
384
+
385
+ // POST /vendor/{id}/reset/password - Reset the existing password for vendor
386
+
387
+ export interface PostVendorResetPasswordPath {
388
+ // vendor
389
+ id: string;
390
+ }
391
+
392
+ export type PostVendorResetPasswordBody = ResetPassword;
393
+
394
+ export type PostVendorResetPasswordResponse = Success;
395
+
396
+ export interface PostVendorResetPasswordRequest extends PostVendorResetPasswordPath {
397
+ body: PostVendorResetPasswordBody;
398
+ }