-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathapi.ts
11691 lines (10984 loc) · 567 KB
/
api.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/* tslint:disable */
/* eslint-disable */
/**
* API Endpoints
* Deliver monetary rewards and incentives to employees, customers, survey participants, and more through the Tremendous API. For organizational tasks, like managing your organization and its members within Tremendous, please see the Tremendous Organizational API.
*
* The version of the OpenAPI document: 2
* Contact: [email protected]
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import type { Configuration } from './configuration';
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
import globalAxios from 'axios';
// Some imports not used depending on template conditions
// @ts-ignore
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
import type { RequestArgs } from './base';
// @ts-ignore
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError, operationServerMap } from './base';
/**
* Ignore flagging rules for rewards redeemed by an email or domain matching this list.
* @export
* @interface AllowEmail
*/
export interface AllowEmail {
/**
* The list of emails.
* @type {Array<string>}
* @memberof AllowEmail
*/
'emails': Array<string>;
}
/**
* The list of emails and domains where a matching redemption will ignore other flagging rules and automatically go through.
* @export
* @interface AllowEmail1
*/
export interface AllowEmail1 {
/**
* The list of emails.
* @type {Array<string>}
* @memberof AllowEmail1
*/
'emails': Array<string>;
}
/**
* Ignore flagging rules for rewards redeemed by an IP matching this list.
* @export
* @interface AllowIp
*/
export interface AllowIp {
/**
* The list of IP addresses to flag or allow. Accepts both IPv4 and IPv6 addresses using CIDR notation.
* @type {Array<string>}
* @memberof AllowIp
*/
'ips': Array<string>;
}
/**
* The list of IP addresses and/or IP ranges where a matching redemption will ignore other flagging rules and automatically go through.
* @export
* @interface AllowIp1
*/
export interface AllowIp1 {
/**
* The list of IP addresses to flag or allow. Accepts both IPv4 and IPv6 addresses using CIDR notation.
* @type {Array<string>}
* @memberof AllowIp1
*/
'ips': Array<string>;
}
/**
* A balance transaction represents a specific movement or change in an account\'s balance.
* @export
* @interface BalanceTransaction
*/
export interface BalanceTransaction {
/**
* Date that the transaction was created
* @type {string}
* @memberof BalanceTransaction
*/
'created_at': string;
/**
* Amount of the transaction in USD
* @type {number}
* @memberof BalanceTransaction
*/
'amount': number;
/**
* The updated total after the transaction. Note that this running balance may be delayed and contain `null`.
* @type {number}
* @memberof BalanceTransaction
*/
'balance': number;
/**
* The action that was performed
* @type {string}
* @memberof BalanceTransaction
*/
'action': string;
/**
* A brief description of the transaction
* @type {string}
* @memberof BalanceTransaction
*/
'description': string;
/**
*
* @type {BalanceTransactionOrder}
* @memberof BalanceTransaction
*/
'order'?: BalanceTransactionOrder;
}
/**
* Order details
* @export
* @interface BalanceTransactionOrder
*/
export interface BalanceTransactionOrder {
/**
*
* @type {string}
* @memberof BalanceTransactionOrder
*/
'id'?: string;
/**
* Reference for this order, supplied by the customer. When set, `external_id` makes order idempotent. All requests that use the same `external_id` after the initial order creation, will result in a response that returns the data of the initially created order. The response will have a `201` response code. These responses **fail** to create any further orders. It also allows for retrieving by `external_id` instead of `id` only.
* @type {string}
* @memberof BalanceTransactionOrder
*/
'external_id'?: string | null;
/**
*
* @type {BalanceTransactionOrderPayment}
* @memberof BalanceTransactionOrder
*/
'payment'?: BalanceTransactionOrderPayment;
}
/**
*
* @export
* @interface BalanceTransactionOrderPayment
*/
export interface BalanceTransactionOrderPayment {
/**
* Total price of the order before fees (in USD)
* @type {number}
* @memberof BalanceTransactionOrderPayment
*/
'subtotal': number;
/**
* Total price of the order including fees (in USD)
* @type {number}
* @memberof BalanceTransactionOrderPayment
*/
'total': number;
/**
* Fees for the order (in USD)
* @type {number}
* @memberof BalanceTransactionOrderPayment
*/
'fees': number;
/**
* Discount for the order (in USD)
* @type {number}
* @memberof BalanceTransactionOrderPayment
*/
'discount': number;
/**
*
* @type {PaymentDetailsRefund}
* @memberof BalanceTransactionOrderPayment
*/
'refund'?: PaymentDetailsRefund;
}
/**
*
* @export
* @interface BaseOrderForCreate
*/
export interface BaseOrderForCreate {
/**
* Reference for this order, supplied by the customer. When set, `external_id` makes order idempotent. All requests that use the same `external_id` after the initial order creation, will result in a response that returns the data of the initially created order. The response will have a `201` response code. These responses **fail** to create any further orders. It also allows for retrieving by `external_id` instead of `id` only.
* @type {string}
* @memberof BaseOrderForCreate
*/
'external_id'?: string | null;
/**
*
* @type {SingleRewardOrderPayment}
* @memberof BaseOrderForCreate
*/
'payment': SingleRewardOrderPayment;
}
/**
* With a campaign you can define the look & feel of how rewards are sent out. It also lets you set the available products (different gift cards, charity, etc.) recipients can choose from.
* @export
* @interface Campaign
*/
export interface Campaign {
/**
*
* @type {string}
* @memberof Campaign
*/
'id'?: string;
/**
* Name of the campaign
* @type {string}
* @memberof Campaign
*/
'name': string;
/**
* Description of the campaign
* @type {string}
* @memberof Campaign
*/
'description': string | null;
/**
* List of IDs of products (different gift cards, charity, etc.) that are available in this campaign.
* @type {Array<string>}
* @memberof Campaign
*/
'products': Array<string>;
/**
*
* @type {ListCampaigns200ResponseCampaignsInnerWebpageStyle}
* @memberof Campaign
*/
'webpage_style'?: ListCampaigns200ResponseCampaignsInnerWebpageStyle;
/**
*
* @type {ListCampaigns200ResponseCampaignsInnerEmailStyle}
* @memberof Campaign
*/
'email_style'?: ListCampaigns200ResponseCampaignsInnerEmailStyle;
}
/**
* With a campaign you can define the look & feel of how rewards are sent out. It also lets you set the available products (different gift cards, charity, etc.) recipients can choose from.
* @export
* @interface CampaignBase
*/
export interface CampaignBase {
/**
*
* @type {string}
* @memberof CampaignBase
*/
'id'?: string;
/**
* Name of the campaign
* @type {string}
* @memberof CampaignBase
*/
'name'?: string;
/**
* Description of the campaign
* @type {string}
* @memberof CampaignBase
*/
'description'?: string | null;
/**
* List of IDs of products (different gift cards, charity, etc.) that are available in this campaign.
* @type {Array<string>}
* @memberof CampaignBase
*/
'products'?: Array<string>;
/**
*
* @type {ListCampaigns200ResponseCampaignsInnerWebpageStyle}
* @memberof CampaignBase
*/
'webpage_style'?: ListCampaigns200ResponseCampaignsInnerWebpageStyle;
/**
*
* @type {ListCampaigns200ResponseCampaignsInnerEmailStyle}
* @memberof CampaignBase
*/
'email_style'?: ListCampaigns200ResponseCampaignsInnerEmailStyle;
}
/**
* Name of the channel in which the order was created
* @export
* @enum {string}
*/
export const Channel = {
Ui: 'UI',
Api: 'API',
Embed: 'EMBED',
Decipher: 'DECIPHER',
Qualtrics: 'QUALTRICS',
Typeform: 'TYPEFORM',
SurveyMonkey: 'SURVEY MONKEY'
} as const;
export type Channel = typeof Channel[keyof typeof Channel];
/**
*
* @export
* @interface CreateApiKey200Response
*/
export interface CreateApiKey200Response {
/**
* The new API key
* @type {string}
* @memberof CreateApiKey200Response
*/
'api_key'?: string;
}
/**
*
* @export
* @interface CreateCampaign201Response
*/
export interface CreateCampaign201Response {
/**
*
* @type {ListCampaigns200ResponseCampaignsInner}
* @memberof CreateCampaign201Response
*/
'campaign': ListCampaigns200ResponseCampaignsInner;
}
/**
* With a campaign you can define the look & feel of how rewards are sent out. It also lets you set the available products (different gift cards, charity, etc.) recipients can choose from.
* @export
* @interface CreateCampaignRequest
*/
export interface CreateCampaignRequest {
/**
* Name of the campaign
* @type {string}
* @memberof CreateCampaignRequest
*/
'name': string;
/**
* Description of the campaign
* @type {string}
* @memberof CreateCampaignRequest
*/
'description': string | null;
/**
* List of IDs of products (different gift cards, charity, etc.) that are available in this campaign.
* @type {Array<string>}
* @memberof CreateCampaignRequest
*/
'products': Array<string>;
/**
*
* @type {ListCampaigns200ResponseCampaignsInnerWebpageStyle}
* @memberof CreateCampaignRequest
*/
'webpage_style'?: ListCampaigns200ResponseCampaignsInnerWebpageStyle;
/**
*
* @type {ListCampaigns200ResponseCampaignsInnerEmailStyle}
* @memberof CreateCampaignRequest
*/
'email_style'?: ListCampaigns200ResponseCampaignsInnerEmailStyle;
}
/**
*
* @export
* @interface CreateInvoice200Response
*/
export interface CreateInvoice200Response {
/**
*
* @type {ListInvoices200ResponseInvoicesInner}
* @memberof CreateInvoice200Response
*/
'invoice': ListInvoices200ResponseInvoicesInner;
}
/**
*
* @export
* @interface CreateInvoiceRequest
*/
export interface CreateInvoiceRequest {
/**
* Reference to the purchase order number within your organization
* @type {string}
* @memberof CreateInvoiceRequest
*/
'po_number'?: string | null;
/**
* Amount of the invoice in USD
* @type {number}
* @memberof CreateInvoiceRequest
*/
'amount': number;
/**
* A note to be included in the invoice. This is for your internal use and will not be visible to the recipient.
* @type {string}
* @memberof CreateInvoiceRequest
*/
'memo'?: string | null;
}
/**
*
* @export
* @interface CreateMember
*/
export interface CreateMember {
/**
* Email address of the member
* @type {string}
* @memberof CreateMember
*/
'email': string;
/**
* The role ID of the member within the organization.
* @type {string}
* @memberof CreateMember
*/
'role': string;
}
/**
*
* @export
* @interface CreateMember200Response
*/
export interface CreateMember200Response {
/**
*
* @type {ListMembers200ResponseMembersInner}
* @memberof CreateMember200Response
*/
'member': ListMembers200ResponseMembersInner;
}
/**
*
* @export
* @interface CreateMemberRequest
*/
export interface CreateMemberRequest {
/**
* Email address of the member
* @type {string}
* @memberof CreateMemberRequest
*/
'email': string;
/**
* The role ID of the member within the organization.
* @type {string}
* @memberof CreateMemberRequest
*/
'role': string;
}
/**
*
* @export
* @interface CreateOrder200Response
*/
export interface CreateOrder200Response {
/**
*
* @type {CreateOrder200ResponseOrder}
* @memberof CreateOrder200Response
*/
'order': CreateOrder200ResponseOrder;
}
/**
* An order wraps around the fulfilment of one or more rewards.
* @export
* @interface CreateOrder200ResponseOrder
*/
export interface CreateOrder200ResponseOrder {
/**
* Tremendous ID of the order
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'id': string;
/**
* Reference for this order, supplied by the customer. When set, `external_id` makes order idempotent. All requests that use the same `external_id` after the initial order creation, will result in a response that returns the data of the initially created order. The response will have a `201` response code. These responses **fail** to create any further orders. It also allows for retrieving by `external_id` instead of `id` only.
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'external_id'?: string | null;
/**
* ID of the campaign in your account, that defines the available products (different gift cards, charity, etc.) that the recipient can choose from.
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'campaign_id'?: string | null;
/**
* Date the order has been created
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'created_at': string;
/**
* Execution status of a given order <table> <thead> <tr> <th> Status </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <code> CANCELED </code> </td> <td> The order and all of its rewards were canceled. </td> </tr> <tr> <td> <code> CART </code> </td> <td> The order has been created, but hasn\'t yet been processed. </td> </tr> <tr> <td> <code> EXECUTED </code> </td> <td> The order has been executed. Payment has been handled and rewards are being delivered (if applicable). </td> </tr> <tr> <td> <code> FAILED </code> </td> <td> The order could not be processed due to an error. E.g. due to insufficient funds in the account. </td> </tr> <tr> <td> <code> PENDING APPROVAL </code> </td> <td> The order has been created but needs approval to be executed. </td> </tr> <tr> <td> <code> PENDING INTERNAL PAYMENT APPROVAL </code> </td> <td> The order has been created but it is under review and requires approval from our team. </td> </tr> </tbody> </table>
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'status': CreateOrder200ResponseOrderStatusEnum;
/**
* Name of the channel in which the order was created
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'channel'?: CreateOrder200ResponseOrderChannelEnum;
/**
*
* @type {ListOrders200ResponseOrdersInnerPayment}
* @memberof CreateOrder200ResponseOrder
*/
'payment'?: ListOrders200ResponseOrdersInnerPayment;
/**
* The ID for the invoice associated with this order
* @type {string}
* @memberof CreateOrder200ResponseOrder
*/
'invoice_id'?: string;
/**
*
* @type {Array<CreateOrder200ResponseOrderRewardsInner>}
* @memberof CreateOrder200ResponseOrder
*/
'rewards'?: Array<CreateOrder200ResponseOrderRewardsInner>;
}
export const CreateOrder200ResponseOrderStatusEnum = {
Canceled: 'CANCELED',
Cart: 'CART',
Executed: 'EXECUTED',
Failed: 'FAILED',
PendingApproval: 'PENDING APPROVAL',
PendingInternalPaymentApproval: 'PENDING INTERNAL PAYMENT APPROVAL'
} as const;
export type CreateOrder200ResponseOrderStatusEnum = typeof CreateOrder200ResponseOrderStatusEnum[keyof typeof CreateOrder200ResponseOrderStatusEnum];
export const CreateOrder200ResponseOrderChannelEnum = {
Ui: 'UI',
Api: 'API',
Embed: 'EMBED',
Decipher: 'DECIPHER',
Qualtrics: 'QUALTRICS',
Typeform: 'TYPEFORM',
SurveyMonkey: 'SURVEY MONKEY'
} as const;
export type CreateOrder200ResponseOrderChannelEnum = typeof CreateOrder200ResponseOrderChannelEnum[keyof typeof CreateOrder200ResponseOrderChannelEnum];
/**
* A single reward, sent to a recipient. A reward is always part of an order. Either `products` or `campaign_id` must be specified.
* @export
* @interface CreateOrder200ResponseOrderRewardsInner
*/
export interface CreateOrder200ResponseOrderRewardsInner {
/**
* Tremendous ID of the reward
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'id'?: string;
/**
* Tremendous ID of the order this reward is part of.
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'order_id'?: string;
/**
* Date the reward was created
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'created_at'?: string;
/**
*
* @type {ListRewards200ResponseRewardsInnerValue}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'value'?: ListRewards200ResponseRewardsInnerValue;
/**
*
* @type {ListRewards200ResponseRewardsInnerRecipient}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'recipient'?: ListRewards200ResponseRewardsInnerRecipient;
/**
* Timestamp of reward delivery within the next year. Note that if date-time is provided, the time values will be ignored.
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'deliver_at'?: string;
/**
*
* @type {Array<ListRewards200ResponseRewardsInnerCustomFieldsInner>}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'custom_fields'?: Array<ListRewards200ResponseRewardsInnerCustomFieldsInner>;
/**
*
* @type {CreateOrder200ResponseOrderRewardsInnerDelivery}
* @memberof CreateOrder200ResponseOrderRewardsInner
*/
'delivery'?: CreateOrder200ResponseOrderRewardsInnerDelivery;
}
/**
* Details on how the reward is delivered to the recipient.
* @export
* @interface CreateOrder200ResponseOrderRewardsInnerDelivery
*/
export interface CreateOrder200ResponseOrderRewardsInnerDelivery {
/**
* How to deliver the reward to the recipient. <table> <thead> <tr> <th>Delivery Method</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code>EMAIL</code></td> <td>Deliver the reward to the recipient by email</td> </tr> <tr> <td><code>LINK</code></td> <td> <p>Deliver the reward to the recipient via a link.</p> <p>The link can be retrieved on a successfully ordered reward via the <code>/rewards</code> or <code>/rewards/{id}</code> endpoint. That link must then be delivered to the recipient out-of-band.</p> </td> </tr> <tr> <td><code>PHONE</code></td> <td>Deliver the reward to the recipient by SMS</td> </tr> </tbody> </table>
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInnerDelivery
*/
'method': CreateOrder200ResponseOrderRewardsInnerDeliveryMethodEnum;
/**
* Current status of the delivery of the reward: * `SCHEDULED` - Reward is scheduled for delivery and will be delivered soon. * `FAILED` - Delivery of reward failed (e.g. email bounced). * `SUCCEEDED` - Reward was successfully delivered (email or text message delivered or reward link active). * `PENDING` - Delivery is pending but not yet scheduled.
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInnerDelivery
*/
'status': CreateOrder200ResponseOrderRewardsInnerDeliveryStatusEnum;
/**
* Link to redeem the reward at. You need to deliver this link to the recipient.
* @type {string}
* @memberof CreateOrder200ResponseOrderRewardsInnerDelivery
*/
'link'?: string;
}
export const CreateOrder200ResponseOrderRewardsInnerDeliveryMethodEnum = {
Email: 'EMAIL',
Link: 'LINK',
Phone: 'PHONE'
} as const;
export type CreateOrder200ResponseOrderRewardsInnerDeliveryMethodEnum = typeof CreateOrder200ResponseOrderRewardsInnerDeliveryMethodEnum[keyof typeof CreateOrder200ResponseOrderRewardsInnerDeliveryMethodEnum];
export const CreateOrder200ResponseOrderRewardsInnerDeliveryStatusEnum = {
Scheduled: 'SCHEDULED',
Failed: 'FAILED',
Succeeded: 'SUCCEEDED',
Pending: 'PENDING'
} as const;
export type CreateOrder200ResponseOrderRewardsInnerDeliveryStatusEnum = typeof CreateOrder200ResponseOrderRewardsInnerDeliveryStatusEnum[keyof typeof CreateOrder200ResponseOrderRewardsInnerDeliveryStatusEnum];
/**
* @type CreateOrderRequest
* @export
*/
export type CreateOrderRequest = SingleRewardOrder;
/**
*
* @export
* @interface CreateOrganization
*/
export interface CreateOrganization {
/**
*
* @type {string}
* @memberof CreateOrganization
*/
'id'?: string;
/**
* Name of the organization
* @type {string}
* @memberof CreateOrganization
*/
'name': string;
/**
* URL of the website of that organization
* @type {string}
* @memberof CreateOrganization
*/
'website': string;
/**
* Default value is `false`. Set to true to also generate an API key associated to the new organization.
* @type {boolean}
* @memberof CreateOrganization
*/
'with_api_key': boolean;
/**
*
* @type {CreateOrganizationRequestCopySettings}
* @memberof CreateOrganization
*/
'copy_settings'?: CreateOrganizationRequestCopySettings;
/**
* Phone number of the organization. For non-US phone numbers, specify the country code (prefixed with +).
* @type {string}
* @memberof CreateOrganization
*/
'phone'?: string;
/**
* Timestamp of when the organization has been created.
* @type {string}
* @memberof CreateOrganization
*/
'created_at'?: string;
}
/**
*
* @export
* @interface CreateOrganization200Response
*/
export interface CreateOrganization200Response {
/**
*
* @type {CreateOrganization200ResponseOrganization}
* @memberof CreateOrganization200Response
*/
'organization'?: CreateOrganization200ResponseOrganization;
}
/**
*
* @export
* @interface CreateOrganization200ResponseOrganization
*/
export interface CreateOrganization200ResponseOrganization {
/**
*
* @type {string}
* @memberof CreateOrganization200ResponseOrganization
*/
'id'?: string;
/**
* Name of the organization
* @type {string}
* @memberof CreateOrganization200ResponseOrganization
*/
'name': string;
/**
* URL of the website of that organization
* @type {string}
* @memberof CreateOrganization200ResponseOrganization
*/
'website': string;
/**
*
* @type {CreateOrganizationRequestCopySettings}
* @memberof CreateOrganization200ResponseOrganization
*/
'copy_settings'?: CreateOrganizationRequestCopySettings;
/**
* Phone number of the organization. For non-US phone numbers, specify the country code (prefixed with +).
* @type {string}
* @memberof CreateOrganization200ResponseOrganization
*/
'phone'?: string | null;
/**
* Timestamp of when the organization has been created.
* @type {string}
* @memberof CreateOrganization200ResponseOrganization
*/
'created_at'?: string;
/**
* The API key for the created organization. This property is only returned when `api_key` is set to `true`.
* @type {string}
* @memberof CreateOrganization200ResponseOrganization
*/
'api_key'?: string;
}
/**
*
* @export
* @interface CreateOrganizationForResponse
*/
export interface CreateOrganizationForResponse {
/**
*
* @type {string}
* @memberof CreateOrganizationForResponse
*/
'id'?: string;
/**
* Name of the organization
* @type {string}
* @memberof CreateOrganizationForResponse
*/
'name': string;
/**
* URL of the website of that organization
* @type {string}
* @memberof CreateOrganizationForResponse
*/
'website': string;
/**
* Default value is `false`. Set to true to also generate an API key associated to the new organization.
* @type {boolean}
* @memberof CreateOrganizationForResponse
*/
'with_api_key'?: boolean;
/**
*
* @type {CreateOrganizationRequestCopySettings}
* @memberof CreateOrganizationForResponse
*/
'copy_settings'?: CreateOrganizationRequestCopySettings;
/**
* Phone number of the organization. For non-US phone numbers, specify the country code (prefixed with +).
* @type {string}
* @memberof CreateOrganizationForResponse
*/
'phone'?: string | null;
/**
* Timestamp of when the organization has been created.
* @type {string}
* @memberof CreateOrganizationForResponse
*/
'created_at'?: string;
}
/**
*
* @export
* @interface CreateOrganizationProperties
*/
export interface CreateOrganizationProperties {
/**
*
* @type {string}
* @memberof CreateOrganizationProperties
*/
'id'?: string;
/**
* Name of the organization
* @type {string}
* @memberof CreateOrganizationProperties
*/
'name'?: string;
/**
* URL of the website of that organization
* @type {string}
* @memberof CreateOrganizationProperties
*/
'website'?: string;
/**
* Default value is `false`. Set to true to also generate an API key associated to the new organization.
* @type {boolean}
* @memberof CreateOrganizationProperties
*/
'with_api_key'?: boolean;
/**
*
* @type {CreateOrganizationRequestCopySettings}
* @memberof CreateOrganizationProperties
*/
'copy_settings'?: CreateOrganizationRequestCopySettings;
/**
* Phone number of the organization. For non-US phone numbers, specify the country code (prefixed with +).
* @type {string}
* @memberof CreateOrganizationProperties
*/
'phone'?: string;
/**
* Timestamp of when the organization has been created.
* @type {string}
* @memberof CreateOrganizationProperties
*/
'created_at'?: string;
}
/**
*
* @export
* @interface CreateOrganizationRequest
*/
export interface CreateOrganizationRequest {
/**
* Name of the organization
* @type {string}
* @memberof CreateOrganizationRequest
*/
'name': string;
/**
* URL of the website of that organization
* @type {string}
* @memberof CreateOrganizationRequest
*/
'website': string;
/**
* Default value is `false`. Set to true to also generate an API key associated to the new organization.
* @type {boolean}
* @memberof CreateOrganizationRequest
*/
'with_api_key': boolean;
/**
*
* @type {CreateOrganizationRequestCopySettings}
* @memberof CreateOrganizationRequest
*/
'copy_settings'?: CreateOrganizationRequestCopySettings;
/**
* Phone number of the organization. For non-US phone numbers, specify the country code (prefixed with +).
* @type {string}
* @memberof CreateOrganizationRequest
*/
'phone'?: string;
}
/**
* A list of the settings that you wish to copy over to the new organization.
* @export
* @interface CreateOrganizationRequestCopySettings
*/
export interface CreateOrganizationRequestCopySettings {
/**
* Copy over the campaigns from the current organization to the new organization. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'campaigns'?: boolean;
/**
* Copy over the custom fields from the current organization to the new organization. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'custom_fields'?: boolean;
/**
* Copy over the order approvals settings from the current organization to the new organization. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'order_approvals'?: boolean;
/**
* Copy over the payment methods from the current organization to the new organization. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'payment_methods'?: boolean;
/**
* Copy over the security settings from the current organization to the new organization. Defaults to `true`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'security_settings'?: boolean;
/**
* Copy over the users and custom roles from the current organization to the new organization. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'users'?: boolean;
/**
* Copy over the custom roles from the current organization to the new organization. Custom roles are always copied if `users` is `true`. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'custom_roles'?: boolean;
/**
* Copy over the fraud prevention settings and rules from the current organization to the new organization. Defaults to `false`.
* @type {boolean}
* @memberof CreateOrganizationRequestCopySettings
*/
'fraud_prevention'?: boolean;
}
/**
*
* @export
* @interface CreateReport201Response
*/
export interface CreateReport201Response {
/**
*
* @type {CreateReport201ResponseReport}
* @memberof CreateReport201Response
*/
'report': CreateReport201ResponseReport;
/**
* Report status message
* @type {string}
* @memberof CreateReport201Response
*/
'message'?: string;
}
/**
* Reports represent a collection of your Tremendous data that can be filtered and downloaded. The report object that is returned has a unique ID, a status, and an predicted time of report generation completion. When the report generation is complete, it will also contain an expiring url where you can retrieve your report.
* @export
* @interface CreateReport201ResponseReport
*/
export interface CreateReport201ResponseReport {
/**
* Tremendous ID of the report, used to retrieve your report
* @type {string}
* @memberof CreateReport201ResponseReport
*/
'id'?: string;
/**
* Status of this report <table> <thead> <tr> <th>Status</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code>CREATED</code></td> <td>Report has been created</td> </tr> <tr> <td><code>PROCESSING</code></td> <td>Report is currently being generated</td> </tr> <tr> <td><code>READY_FOR_DOWNLOAD</code></td> <td>Report generation is complete and ready for download</td> </tr> <tr> <td><code>FAILED</code></td> <td>Report failed to generate</td> </tr> </tbody> </table>
* @type {string}
* @memberof CreateReport201ResponseReport
*/
'status'?: CreateReport201ResponseReportStatusEnum;
/**
* Timestamp of when the report was created
* @type {string}
* @memberof CreateReport201ResponseReport