@munchi_oy/core 2.15.1 → 2.16.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/dist/generated/api.d.ts +719 -38
- package/dist/generated/api.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/src/version.d.ts +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/generated/api.ts +933 -40
- package/package.json +15 -13
- package/src/version.ts +1 -1
package/generated/api.ts
CHANGED
|
@@ -5454,6 +5454,12 @@ export interface CreateVenueGiftCardDto {
|
|
|
5454
5454
|
* @memberof CreateVenueGiftCardDto
|
|
5455
5455
|
*/
|
|
5456
5456
|
'expiresAt'?: string | null;
|
|
5457
|
+
/**
|
|
5458
|
+
* When the card\'s email goes, ISO 8601 date-time, ahead and at most a year from now; it needs buyerEmail and sendEmail not false. Without expiresAt, the validity counts from this moment. Absent: at once.
|
|
5459
|
+
* @type {string}
|
|
5460
|
+
* @memberof CreateVenueGiftCardDto
|
|
5461
|
+
*/
|
|
5462
|
+
'sendAt'?: string;
|
|
5457
5463
|
}
|
|
5458
5464
|
|
|
5459
5465
|
|
|
@@ -9070,7 +9076,8 @@ export const GiftCardEmailKind = {
|
|
|
9070
9076
|
Card: 'CARD',
|
|
9071
9077
|
CardAgain: 'CARD_AGAIN',
|
|
9072
9078
|
Expiry30: 'EXPIRY_30',
|
|
9073
|
-
Expiry7: 'EXPIRY_7'
|
|
9079
|
+
Expiry7: 'EXPIRY_7',
|
|
9080
|
+
BuyerReceipt: 'BUYER_RECEIPT'
|
|
9074
9081
|
} as const;
|
|
9075
9082
|
|
|
9076
9083
|
export type GiftCardEmailKind = typeof GiftCardEmailKind[keyof typeof GiftCardEmailKind];
|
|
@@ -9188,6 +9195,12 @@ export interface GiftCardHistoryEventDto {
|
|
|
9188
9195
|
* @memberof GiftCardHistoryEventDto
|
|
9189
9196
|
*/
|
|
9190
9197
|
'emailKind': GiftCardEmailKind | null;
|
|
9198
|
+
/**
|
|
9199
|
+
* When the card\'s email is set to go, ISO 8601, on a SCHEDULED line (\"Scheduled for …\"); null for the others
|
|
9200
|
+
* @type {string}
|
|
9201
|
+
* @memberof GiftCardHistoryEventDto
|
|
9202
|
+
*/
|
|
9203
|
+
'scheduledFor': string | null;
|
|
9191
9204
|
/**
|
|
9192
9205
|
* When it happened, ISO 8601
|
|
9193
9206
|
* @type {string}
|
|
@@ -9214,7 +9227,9 @@ export const GiftCardHistoryKind = {
|
|
|
9214
9227
|
SwitchedOn: 'SWITCHED_ON',
|
|
9215
9228
|
Emailed: 'EMAILED',
|
|
9216
9229
|
EmailFailed: 'EMAIL_FAILED',
|
|
9217
|
-
EmailChanged: 'EMAIL_CHANGED'
|
|
9230
|
+
EmailChanged: 'EMAIL_CHANGED',
|
|
9231
|
+
Refunded: 'REFUNDED',
|
|
9232
|
+
Scheduled: 'SCHEDULED'
|
|
9218
9233
|
} as const;
|
|
9219
9234
|
|
|
9220
9235
|
export type GiftCardHistoryKind = typeof GiftCardHistoryKind[keyof typeof GiftCardHistoryKind];
|
|
@@ -9488,6 +9503,108 @@ export interface GiftCardMovementsDto {
|
|
|
9488
9503
|
*/
|
|
9489
9504
|
'nextCursor': string | null;
|
|
9490
9505
|
}
|
|
9506
|
+
/**
|
|
9507
|
+
*
|
|
9508
|
+
* @export
|
|
9509
|
+
* @interface GiftCardOfferDto
|
|
9510
|
+
*/
|
|
9511
|
+
export interface GiftCardOfferDto {
|
|
9512
|
+
/**
|
|
9513
|
+
* Whether the store sells gift cards online now: its selling switch is on (the default) and a buyer has an amount to choose. Its online store (food ordering) may be off. Card payments online are checked by Vendure, not here.
|
|
9514
|
+
* @type {boolean}
|
|
9515
|
+
* @memberof GiftCardOfferDto
|
|
9516
|
+
*/
|
|
9517
|
+
'sells': boolean;
|
|
9518
|
+
/**
|
|
9519
|
+
* The amounts offered, in cents, ascending: at most 3, the smallest ones when a store saved more before; with anyAmount, buyers also see Other
|
|
9520
|
+
* @type {Array<number>}
|
|
9521
|
+
* @memberof GiftCardOfferDto
|
|
9522
|
+
*/
|
|
9523
|
+
'amounts': Array<number>;
|
|
9524
|
+
/**
|
|
9525
|
+
* Whether a buyer may choose any amount
|
|
9526
|
+
* @type {boolean}
|
|
9527
|
+
* @memberof GiftCardOfferDto
|
|
9528
|
+
*/
|
|
9529
|
+
'anyAmount': boolean;
|
|
9530
|
+
/**
|
|
9531
|
+
* The smallest amount a buyer may choose, in cents
|
|
9532
|
+
* @type {number}
|
|
9533
|
+
* @memberof GiftCardOfferDto
|
|
9534
|
+
*/
|
|
9535
|
+
'minAmount': number;
|
|
9536
|
+
/**
|
|
9537
|
+
* The largest amount a buyer may choose, in cents
|
|
9538
|
+
* @type {number}
|
|
9539
|
+
* @memberof GiftCardOfferDto
|
|
9540
|
+
*/
|
|
9541
|
+
'maxAmount': number;
|
|
9542
|
+
/**
|
|
9543
|
+
*
|
|
9544
|
+
* @type {CurrencyCode}
|
|
9545
|
+
* @memberof GiftCardOfferDto
|
|
9546
|
+
*/
|
|
9547
|
+
'currency': CurrencyCode;
|
|
9548
|
+
/**
|
|
9549
|
+
* The text printed on the card; null when none
|
|
9550
|
+
* @type {string}
|
|
9551
|
+
* @memberof GiftCardOfferDto
|
|
9552
|
+
*/
|
|
9553
|
+
'cardText': string | null;
|
|
9554
|
+
/**
|
|
9555
|
+
* The card\'s picture, an https URL; null when none
|
|
9556
|
+
* @type {string}
|
|
9557
|
+
* @memberof GiftCardOfferDto
|
|
9558
|
+
*/
|
|
9559
|
+
'imageUrl': string | null;
|
|
9560
|
+
/**
|
|
9561
|
+
* The store\'s name
|
|
9562
|
+
* @type {string}
|
|
9563
|
+
* @memberof GiftCardOfferDto
|
|
9564
|
+
*/
|
|
9565
|
+
'storeName': string;
|
|
9566
|
+
/**
|
|
9567
|
+
* How many months a card stays valid from the day its email goes; null when cards never expire
|
|
9568
|
+
* @type {number}
|
|
9569
|
+
* @memberof GiftCardOfferDto
|
|
9570
|
+
*/
|
|
9571
|
+
'validityMonths': number | null;
|
|
9572
|
+
}
|
|
9573
|
+
|
|
9574
|
+
|
|
9575
|
+
/**
|
|
9576
|
+
*
|
|
9577
|
+
* @export
|
|
9578
|
+
* @interface GiftCardPaymentsOnlineDto
|
|
9579
|
+
*/
|
|
9580
|
+
export interface GiftCardPaymentsOnlineDto {
|
|
9581
|
+
/**
|
|
9582
|
+
*
|
|
9583
|
+
* @type {StripeConnectionState}
|
|
9584
|
+
* @memberof GiftCardPaymentsOnlineDto
|
|
9585
|
+
*/
|
|
9586
|
+
'stripe': StripeConnectionState;
|
|
9587
|
+
/**
|
|
9588
|
+
*
|
|
9589
|
+
* @type {VivaOnlineState}
|
|
9590
|
+
* @memberof GiftCardPaymentsOnlineDto
|
|
9591
|
+
*/
|
|
9592
|
+
'vivaOnline': VivaOnlineState;
|
|
9593
|
+
/**
|
|
9594
|
+
* Whether the store takes Viva card payments at its POS (an active Viva config on MunchiPos)
|
|
9595
|
+
* @type {boolean}
|
|
9596
|
+
* @memberof GiftCardPaymentsOnlineDto
|
|
9597
|
+
*/
|
|
9598
|
+
'vivaOnPos': boolean;
|
|
9599
|
+
/**
|
|
9600
|
+
* Whether that POS Viva config names a merchant id: POS Viva payments go through our Viva partner (ISV) account, so its merchant is under it and \"Use my Viva\" can set up online Viva from it
|
|
9601
|
+
* @type {boolean}
|
|
9602
|
+
* @memberof GiftCardPaymentsOnlineDto
|
|
9603
|
+
*/
|
|
9604
|
+
'vivaIsv': boolean;
|
|
9605
|
+
}
|
|
9606
|
+
|
|
9607
|
+
|
|
9491
9608
|
/**
|
|
9492
9609
|
*
|
|
9493
9610
|
* @export
|
|
@@ -9570,6 +9687,25 @@ export interface GiftCardPeriodTotalsDtoSpent {
|
|
|
9570
9687
|
*/
|
|
9571
9688
|
'orderCount': number;
|
|
9572
9689
|
}
|
|
9690
|
+
/**
|
|
9691
|
+
*
|
|
9692
|
+
* @export
|
|
9693
|
+
* @interface GiftCardPersonDto
|
|
9694
|
+
*/
|
|
9695
|
+
export interface GiftCardPersonDto {
|
|
9696
|
+
/**
|
|
9697
|
+
* The person\'s name, 1 to 120 characters once the spaces around it are dropped. Absent or only spaces: none; the emails then greet nobody by name.
|
|
9698
|
+
* @type {string}
|
|
9699
|
+
* @memberof GiftCardPersonDto
|
|
9700
|
+
*/
|
|
9701
|
+
'name'?: string;
|
|
9702
|
+
/**
|
|
9703
|
+
* The person\'s email, at most 254 characters once the spaces around it are dropped.
|
|
9704
|
+
* @type {string}
|
|
9705
|
+
* @memberof GiftCardPersonDto
|
|
9706
|
+
*/
|
|
9707
|
+
'email': string;
|
|
9708
|
+
}
|
|
9573
9709
|
/**
|
|
9574
9710
|
*
|
|
9575
9711
|
* @export
|
|
@@ -9771,12 +9907,76 @@ export interface GiftCardReportDtoSpent {
|
|
|
9771
9907
|
*/
|
|
9772
9908
|
'orderCount': number;
|
|
9773
9909
|
}
|
|
9910
|
+
/**
|
|
9911
|
+
*
|
|
9912
|
+
* @export
|
|
9913
|
+
* @interface GiftCardSellingDto
|
|
9914
|
+
*/
|
|
9915
|
+
export interface GiftCardSellingDto {
|
|
9916
|
+
/**
|
|
9917
|
+
*
|
|
9918
|
+
* @type {GiftCardSellingDtoCardPayments}
|
|
9919
|
+
* @memberof GiftCardSellingDto
|
|
9920
|
+
*/
|
|
9921
|
+
'cardPayments': GiftCardSellingDtoCardPayments;
|
|
9922
|
+
/**
|
|
9923
|
+
* Whether a buyer has an amount to choose: at least one amount, or any amount
|
|
9924
|
+
* @type {boolean}
|
|
9925
|
+
* @memberof GiftCardSellingDto
|
|
9926
|
+
*/
|
|
9927
|
+
'amountsSet': boolean;
|
|
9928
|
+
/**
|
|
9929
|
+
* Whether every step is done, so selling online may be turned on: card payments online (Stripe active, or Viva online), and amounts. The online store (food ordering) need not be on.
|
|
9930
|
+
* @type {boolean}
|
|
9931
|
+
* @memberof GiftCardSellingDto
|
|
9932
|
+
*/
|
|
9933
|
+
'ready': boolean;
|
|
9934
|
+
}
|
|
9935
|
+
/**
|
|
9936
|
+
* What the store can take card payments online with
|
|
9937
|
+
* @export
|
|
9938
|
+
* @interface GiftCardSellingDtoCardPayments
|
|
9939
|
+
*/
|
|
9940
|
+
export interface GiftCardSellingDtoCardPayments {
|
|
9941
|
+
/**
|
|
9942
|
+
*
|
|
9943
|
+
* @type {StripeConnectionState}
|
|
9944
|
+
* @memberof GiftCardSellingDtoCardPayments
|
|
9945
|
+
*/
|
|
9946
|
+
'stripe': StripeConnectionState;
|
|
9947
|
+
/**
|
|
9948
|
+
*
|
|
9949
|
+
* @type {VivaOnlineState}
|
|
9950
|
+
* @memberof GiftCardSellingDtoCardPayments
|
|
9951
|
+
*/
|
|
9952
|
+
'vivaOnline': VivaOnlineState;
|
|
9953
|
+
/**
|
|
9954
|
+
* Whether the store takes Viva card payments at its POS (an active Viva config on MunchiPos)
|
|
9955
|
+
* @type {boolean}
|
|
9956
|
+
* @memberof GiftCardSellingDtoCardPayments
|
|
9957
|
+
*/
|
|
9958
|
+
'vivaOnPos': boolean;
|
|
9959
|
+
/**
|
|
9960
|
+
* Whether that POS Viva config names a merchant id: POS Viva payments go through our Viva partner (ISV) account, so its merchant is under it and \"Use my Viva\" can set up online Viva from it
|
|
9961
|
+
* @type {boolean}
|
|
9962
|
+
* @memberof GiftCardSellingDtoCardPayments
|
|
9963
|
+
*/
|
|
9964
|
+
'vivaIsv': boolean;
|
|
9965
|
+
}
|
|
9966
|
+
|
|
9967
|
+
|
|
9774
9968
|
/**
|
|
9775
9969
|
*
|
|
9776
9970
|
* @export
|
|
9777
9971
|
* @interface GiftCardSettingsDto
|
|
9778
9972
|
*/
|
|
9779
9973
|
export interface GiftCardSettingsDto {
|
|
9974
|
+
/**
|
|
9975
|
+
* Whether the store has saved its gift card settings: false while the answer is the defaults of a store that never saved them (the dashboard shows its setup then); true after any save
|
|
9976
|
+
* @type {boolean}
|
|
9977
|
+
* @memberof GiftCardSettingsDto
|
|
9978
|
+
*/
|
|
9979
|
+
'saved': boolean;
|
|
9780
9980
|
/**
|
|
9781
9981
|
*
|
|
9782
9982
|
* @type {GiftCardSettingsDtoChannels}
|
|
@@ -9790,7 +9990,7 @@ export interface GiftCardSettingsDto {
|
|
|
9790
9990
|
*/
|
|
9791
9991
|
'availableChannels': Array<GiftCardChannel>;
|
|
9792
9992
|
/**
|
|
9793
|
-
* The amounts offered, in cents, ascending
|
|
9993
|
+
* The amounts offered, in cents, ascending: at most 3, though a store saved with more before keeps them until its next change of amounts
|
|
9794
9994
|
* @type {Array<number>}
|
|
9795
9995
|
* @memberof GiftCardSettingsDto
|
|
9796
9996
|
*/
|
|
@@ -9849,6 +10049,12 @@ export interface GiftCardSettingsDto {
|
|
|
9849
10049
|
* @memberof GiftCardSettingsDto
|
|
9850
10050
|
*/
|
|
9851
10051
|
'emailLanguage': GiftCardLanguage | null;
|
|
10052
|
+
/**
|
|
10053
|
+
* Whether the store\'s switch for selling gift cards online is on; on by default, true for a store that never saved its settings. The store really sells only while GET gift-card-selling also answers ready; turning it back on after it was off is refused until then.
|
|
10054
|
+
* @type {boolean}
|
|
10055
|
+
* @memberof GiftCardSettingsDto
|
|
10056
|
+
*/
|
|
10057
|
+
'sellOnline': boolean;
|
|
9852
10058
|
}
|
|
9853
10059
|
|
|
9854
10060
|
|
|
@@ -15919,6 +16125,44 @@ export interface OnboardingStoresDto {
|
|
|
15919
16125
|
*/
|
|
15920
16126
|
'stores': Array<OnboardingStoreDto>;
|
|
15921
16127
|
}
|
|
16128
|
+
/**
|
|
16129
|
+
*
|
|
16130
|
+
* @export
|
|
16131
|
+
* @interface OnlineGiftCardRefundDto
|
|
16132
|
+
*/
|
|
16133
|
+
export interface OnlineGiftCardRefundDto {
|
|
16134
|
+
/**
|
|
16135
|
+
* The card\'s id
|
|
16136
|
+
* @type {string}
|
|
16137
|
+
* @memberof OnlineGiftCardRefundDto
|
|
16138
|
+
*/
|
|
16139
|
+
'cardId': string;
|
|
16140
|
+
/**
|
|
16141
|
+
* When the card was blocked for the refund, ISO 8601: the first refund\'s moment on a repeat.
|
|
16142
|
+
* @type {string}
|
|
16143
|
+
* @memberof OnlineGiftCardRefundDto
|
|
16144
|
+
*/
|
|
16145
|
+
'refundedAt': string;
|
|
16146
|
+
}
|
|
16147
|
+
/**
|
|
16148
|
+
*
|
|
16149
|
+
* @export
|
|
16150
|
+
* @interface OnlineGiftCardSaleDto
|
|
16151
|
+
*/
|
|
16152
|
+
export interface OnlineGiftCardSaleDto {
|
|
16153
|
+
/**
|
|
16154
|
+
* The card\'s id
|
|
16155
|
+
* @type {string}
|
|
16156
|
+
* @memberof OnlineGiftCardSaleDto
|
|
16157
|
+
*/
|
|
16158
|
+
'cardId': string;
|
|
16159
|
+
/**
|
|
16160
|
+
* The card\'s 6-digit code. Never shown to the buyer of a gift: only the person it is for gets it, by email.
|
|
16161
|
+
* @type {string}
|
|
16162
|
+
* @memberof OnlineGiftCardSaleDto
|
|
16163
|
+
*/
|
|
16164
|
+
'code': string;
|
|
16165
|
+
}
|
|
15922
16166
|
/**
|
|
15923
16167
|
*
|
|
15924
16168
|
* @export
|
|
@@ -23685,6 +23929,19 @@ export interface PosUpdateOrderDto {
|
|
|
23685
23929
|
}
|
|
23686
23930
|
|
|
23687
23931
|
|
|
23932
|
+
/**
|
|
23933
|
+
*
|
|
23934
|
+
* @export
|
|
23935
|
+
* @interface PosVivaMerchantDto
|
|
23936
|
+
*/
|
|
23937
|
+
export interface PosVivaMerchantDto {
|
|
23938
|
+
/**
|
|
23939
|
+
* The Viva merchant id of the store\'s active POS Viva config; null when its POS takes no Viva payments or the config names no merchant. Never a key.
|
|
23940
|
+
* @type {string}
|
|
23941
|
+
* @memberof PosVivaMerchantDto
|
|
23942
|
+
*/
|
|
23943
|
+
'merchantId': string | null;
|
|
23944
|
+
}
|
|
23688
23945
|
/**
|
|
23689
23946
|
*
|
|
23690
23947
|
* @export
|
|
@@ -27255,6 +27512,25 @@ export const RefundMode = {
|
|
|
27255
27512
|
export type RefundMode = typeof RefundMode[keyof typeof RefundMode];
|
|
27256
27513
|
|
|
27257
27514
|
|
|
27515
|
+
/**
|
|
27516
|
+
*
|
|
27517
|
+
* @export
|
|
27518
|
+
* @interface RefundOnlineGiftCardSaleDto
|
|
27519
|
+
*/
|
|
27520
|
+
export interface RefundOnlineGiftCardSaleDto {
|
|
27521
|
+
/**
|
|
27522
|
+
* The Vendure order\'s code, 1 to 64 characters: with orderLineId, it names the sale.
|
|
27523
|
+
* @type {string}
|
|
27524
|
+
* @memberof RefundOnlineGiftCardSaleDto
|
|
27525
|
+
*/
|
|
27526
|
+
'orderCode': string;
|
|
27527
|
+
/**
|
|
27528
|
+
* The id of the Vendure order line that holds the gift card, 1 to 64 characters.
|
|
27529
|
+
* @type {string}
|
|
27530
|
+
* @memberof RefundOnlineGiftCardSaleDto
|
|
27531
|
+
*/
|
|
27532
|
+
'orderLineId': string;
|
|
27533
|
+
}
|
|
27258
27534
|
/**
|
|
27259
27535
|
*
|
|
27260
27536
|
* @export
|
|
@@ -31758,6 +32034,113 @@ export interface SearchUserInfoResponseDtoLinksValue {
|
|
|
31758
32034
|
*/
|
|
31759
32035
|
'method'?: string;
|
|
31760
32036
|
}
|
|
32037
|
+
/**
|
|
32038
|
+
*
|
|
32039
|
+
* @export
|
|
32040
|
+
* @interface SellGiftCardOnlineDto
|
|
32041
|
+
*/
|
|
32042
|
+
export interface SellGiftCardOnlineDto {
|
|
32043
|
+
/**
|
|
32044
|
+
* The Vendure order\'s code, 1 to 64 characters: with orderLineId, it names the sale.
|
|
32045
|
+
* @type {string}
|
|
32046
|
+
* @memberof SellGiftCardOnlineDto
|
|
32047
|
+
*/
|
|
32048
|
+
'orderCode': string;
|
|
32049
|
+
/**
|
|
32050
|
+
* The id of the Vendure order line that holds the gift card, 1 to 64 characters.
|
|
32051
|
+
* @type {string}
|
|
32052
|
+
* @memberof SellGiftCardOnlineDto
|
|
32053
|
+
*/
|
|
32054
|
+
'orderLineId': string;
|
|
32055
|
+
/**
|
|
32056
|
+
* The store that sold it: its orderingBusinessId, the Vendure seller of the storefront channel the order was placed on.
|
|
32057
|
+
* @type {number}
|
|
32058
|
+
* @memberof SellGiftCardOnlineDto
|
|
32059
|
+
*/
|
|
32060
|
+
'orderingBusinessId': number;
|
|
32061
|
+
/**
|
|
32062
|
+
* The card\'s balance, in cents, 100 to 100000: what the line was paid. It must be one of the store\'s amounts, or within its smallest and largest when it takes any amount.
|
|
32063
|
+
* @type {number}
|
|
32064
|
+
* @memberof SellGiftCardOnlineDto
|
|
32065
|
+
*/
|
|
32066
|
+
'amount': number;
|
|
32067
|
+
/**
|
|
32068
|
+
*
|
|
32069
|
+
* @type {CurrencyCode}
|
|
32070
|
+
* @memberof SellGiftCardOnlineDto
|
|
32071
|
+
*/
|
|
32072
|
+
'currency': CurrencyCode;
|
|
32073
|
+
/**
|
|
32074
|
+
*
|
|
32075
|
+
* @type {SellGiftCardOnlineDtoBuyer}
|
|
32076
|
+
* @memberof SellGiftCardOnlineDto
|
|
32077
|
+
*/
|
|
32078
|
+
'buyer': SellGiftCardOnlineDtoBuyer;
|
|
32079
|
+
/**
|
|
32080
|
+
*
|
|
32081
|
+
* @type {SellGiftCardOnlineDtoRecipient}
|
|
32082
|
+
* @memberof SellGiftCardOnlineDto
|
|
32083
|
+
*/
|
|
32084
|
+
'recipient'?: SellGiftCardOnlineDtoRecipient;
|
|
32085
|
+
/**
|
|
32086
|
+
* The buyer\'s message, shown in the card\'s email, 1 to 300 characters. Absent: none.
|
|
32087
|
+
* @type {string}
|
|
32088
|
+
* @memberof SellGiftCardOnlineDto
|
|
32089
|
+
*/
|
|
32090
|
+
'message'?: string;
|
|
32091
|
+
/**
|
|
32092
|
+
*
|
|
32093
|
+
* @type {GiftCardLanguage}
|
|
32094
|
+
* @memberof SellGiftCardOnlineDto
|
|
32095
|
+
*/
|
|
32096
|
+
'language'?: GiftCardLanguage;
|
|
32097
|
+
/**
|
|
32098
|
+
* When the card\'s email goes to the person it is for, ISO 8601 date-time, at most a year from now. Absent, or already past when the payment settles: at once. The card\'s validity counts from this moment.
|
|
32099
|
+
* @type {string}
|
|
32100
|
+
* @memberof SellGiftCardOnlineDto
|
|
32101
|
+
*/
|
|
32102
|
+
'sendAt'?: string;
|
|
32103
|
+
}
|
|
32104
|
+
|
|
32105
|
+
|
|
32106
|
+
/**
|
|
32107
|
+
* Who bought the card: its receipt goes to this email, and the card too when it is for them.
|
|
32108
|
+
* @export
|
|
32109
|
+
* @interface SellGiftCardOnlineDtoBuyer
|
|
32110
|
+
*/
|
|
32111
|
+
export interface SellGiftCardOnlineDtoBuyer {
|
|
32112
|
+
/**
|
|
32113
|
+
* The person\'s name, 1 to 120 characters once the spaces around it are dropped. Absent or only spaces: none; the emails then greet nobody by name.
|
|
32114
|
+
* @type {string}
|
|
32115
|
+
* @memberof SellGiftCardOnlineDtoBuyer
|
|
32116
|
+
*/
|
|
32117
|
+
'name'?: string;
|
|
32118
|
+
/**
|
|
32119
|
+
* The person\'s email, at most 254 characters once the spaces around it are dropped.
|
|
32120
|
+
* @type {string}
|
|
32121
|
+
* @memberof SellGiftCardOnlineDtoBuyer
|
|
32122
|
+
*/
|
|
32123
|
+
'email': string;
|
|
32124
|
+
}
|
|
32125
|
+
/**
|
|
32126
|
+
* Whom the card is for, when it is a gift: the card\'s email and its reminders go to this email, and the buyer gets a receipt without the code. Absent, or the buyer\'s own email: the card is the buyer\'s, and only the card\'s email goes, to the buyer.
|
|
32127
|
+
* @export
|
|
32128
|
+
* @interface SellGiftCardOnlineDtoRecipient
|
|
32129
|
+
*/
|
|
32130
|
+
export interface SellGiftCardOnlineDtoRecipient {
|
|
32131
|
+
/**
|
|
32132
|
+
* The person\'s name, 1 to 120 characters once the spaces around it are dropped. Absent or only spaces: none; the emails then greet nobody by name.
|
|
32133
|
+
* @type {string}
|
|
32134
|
+
* @memberof SellGiftCardOnlineDtoRecipient
|
|
32135
|
+
*/
|
|
32136
|
+
'name'?: string;
|
|
32137
|
+
/**
|
|
32138
|
+
* The person\'s email, at most 254 characters once the spaces around it are dropped.
|
|
32139
|
+
* @type {string}
|
|
32140
|
+
* @memberof SellGiftCardOnlineDtoRecipient
|
|
32141
|
+
*/
|
|
32142
|
+
'email': string;
|
|
32143
|
+
}
|
|
31761
32144
|
/**
|
|
31762
32145
|
*
|
|
31763
32146
|
* @export
|
|
@@ -32876,6 +33259,21 @@ export interface StripeConfigResponseDto {
|
|
|
32876
33259
|
*/
|
|
32877
33260
|
'locationId': string | null;
|
|
32878
33261
|
}
|
|
33262
|
+
/**
|
|
33263
|
+
*
|
|
33264
|
+
* @export
|
|
33265
|
+
* @enum {string}
|
|
33266
|
+
*/
|
|
33267
|
+
|
|
33268
|
+
export const StripeConnectionState = {
|
|
33269
|
+
Active: 'active',
|
|
33270
|
+
Pending: 'pending',
|
|
33271
|
+
None: 'none'
|
|
33272
|
+
} as const;
|
|
33273
|
+
|
|
33274
|
+
export type StripeConnectionState = typeof StripeConnectionState[keyof typeof StripeConnectionState];
|
|
33275
|
+
|
|
33276
|
+
|
|
32879
33277
|
/**
|
|
32880
33278
|
*
|
|
32881
33279
|
* @export
|
|
@@ -37104,7 +37502,7 @@ export interface UpdateGiftCardSettingsDto {
|
|
|
37104
37502
|
*/
|
|
37105
37503
|
'channels'?: UpdateGiftCardSettingsDtoChannels;
|
|
37106
37504
|
/**
|
|
37107
|
-
* The amounts offered, in cents: 1 to
|
|
37505
|
+
* The amounts offered, in cents: 1 to 3 different amounts, each 100 to 100000 (with anyAmount, buyers also see Other). Stored ascending. Absent: unchanged.
|
|
37108
37506
|
* @type {Array<number>}
|
|
37109
37507
|
* @memberof UpdateGiftCardSettingsDto
|
|
37110
37508
|
*/
|
|
@@ -37163,6 +37561,12 @@ export interface UpdateGiftCardSettingsDto {
|
|
|
37163
37561
|
* @memberof UpdateGiftCardSettingsDto
|
|
37164
37562
|
*/
|
|
37165
37563
|
'emailLanguage'?: GiftCardLanguage | null;
|
|
37564
|
+
/**
|
|
37565
|
+
* Whether the store\'s switch for selling gift cards online is on. Turning it from false to true is refused 400 while GET gift-card-selling does not answer ready (card payments online, amounts; the online store need not be on); true while it is already on, and false, are always taken. Absent: unchanged.
|
|
37566
|
+
* @type {boolean}
|
|
37567
|
+
* @memberof UpdateGiftCardSettingsDto
|
|
37568
|
+
*/
|
|
37569
|
+
'sellOnline'?: boolean;
|
|
37166
37570
|
}
|
|
37167
37571
|
|
|
37168
37572
|
|
|
@@ -37672,7 +38076,7 @@ export interface UpdateTableStatusDto {
|
|
|
37672
38076
|
*/
|
|
37673
38077
|
export interface UpdateVenueGiftCardDto {
|
|
37674
38078
|
/**
|
|
37675
|
-
* The card\'s email address, at most 254 characters once the spaces around it are dropped, or null to remove it. Nothing is sent.
|
|
38079
|
+
* The card\'s email address, at most 254 characters once the spaces around it are dropped, or null to remove it. On an online gift it is the buyer\'s, where only the receipt went: the gift\'s own address is recipientEmail. Nothing is sent. Absent: unchanged.
|
|
37676
38080
|
* @type {string}
|
|
37677
38081
|
* @memberof UpdateVenueGiftCardDto
|
|
37678
38082
|
*/
|
|
@@ -37683,6 +38087,24 @@ export interface UpdateVenueGiftCardDto {
|
|
|
37683
38087
|
* @memberof UpdateVenueGiftCardDto
|
|
37684
38088
|
*/
|
|
37685
38089
|
'language'?: GiftCardLanguage | null;
|
|
38090
|
+
/**
|
|
38091
|
+
* When the card\'s email goes, ISO 8601 date-time, ahead and at most a year from now, or null to send it now; only while the card\'s email waits for its first try. Absent: unchanged.
|
|
38092
|
+
* @type {string}
|
|
38093
|
+
* @memberof UpdateVenueGiftCardDto
|
|
38094
|
+
*/
|
|
38095
|
+
'sendAt'?: string | null;
|
|
38096
|
+
/**
|
|
38097
|
+
* Corrects where an online gift\'s card email and reminders go, at most 254 characters once the spaces around it are dropped; recorded as EMAIL_CHANGED, and Send again uses it. Only on an online gift (a card answered with a recipientEmail): any other card is refused 400. Nothing is sent. Absent: unchanged.
|
|
38098
|
+
* @type {string}
|
|
38099
|
+
* @memberof UpdateVenueGiftCardDto
|
|
38100
|
+
*/
|
|
38101
|
+
'recipientEmail'?: string;
|
|
38102
|
+
/**
|
|
38103
|
+
* Corrects the name an online gift greets, 1 to 120 characters once the spaces around it are dropped. Only on an online gift: any other card is refused 400. Absent: unchanged.
|
|
38104
|
+
* @type {string}
|
|
38105
|
+
* @memberof UpdateVenueGiftCardDto
|
|
38106
|
+
*/
|
|
38107
|
+
'recipientName'?: string;
|
|
37686
38108
|
}
|
|
37687
38109
|
|
|
37688
38110
|
|
|
@@ -38950,6 +39372,24 @@ export interface VenueGiftCardDetailDto {
|
|
|
38950
39372
|
* @memberof VenueGiftCardDetailDto
|
|
38951
39373
|
*/
|
|
38952
39374
|
'language': GiftCardLanguage | null;
|
|
39375
|
+
/**
|
|
39376
|
+
* When the card\'s email is set to go, ISO 8601: a day the dashboard or the online buyer chose; null for at once
|
|
39377
|
+
* @type {string}
|
|
39378
|
+
* @memberof VenueGiftCardDetailDto
|
|
39379
|
+
*/
|
|
39380
|
+
'sendAt': string | null;
|
|
39381
|
+
/**
|
|
39382
|
+
* Whom an online gift is for: its card email and reminders go to recipientEmail, while buyerEmail is the buyer\'s, who got the receipt; null for every other card
|
|
39383
|
+
* @type {string}
|
|
39384
|
+
* @memberof VenueGiftCardDetailDto
|
|
39385
|
+
*/
|
|
39386
|
+
'recipientName': string | null;
|
|
39387
|
+
/**
|
|
39388
|
+
* Where an online gift\'s card email and reminders go; null for every other card, whose emails go to buyerEmail
|
|
39389
|
+
* @type {string}
|
|
39390
|
+
* @memberof VenueGiftCardDetailDto
|
|
39391
|
+
*/
|
|
39392
|
+
'recipientEmail': string | null;
|
|
38953
39393
|
/**
|
|
38954
39394
|
*
|
|
38955
39395
|
* @type {VenueGiftCardDetailDtoLastEmail}
|
|
@@ -40393,6 +40833,20 @@ export const VivaEventId = {
|
|
|
40393
40833
|
export type VivaEventId = typeof VivaEventId[keyof typeof VivaEventId];
|
|
40394
40834
|
|
|
40395
40835
|
|
|
40836
|
+
/**
|
|
40837
|
+
*
|
|
40838
|
+
* @export
|
|
40839
|
+
* @enum {string}
|
|
40840
|
+
*/
|
|
40841
|
+
|
|
40842
|
+
export const VivaOnlineState = {
|
|
40843
|
+
Active: 'active',
|
|
40844
|
+
None: 'none'
|
|
40845
|
+
} as const;
|
|
40846
|
+
|
|
40847
|
+
export type VivaOnlineState = typeof VivaOnlineState[keyof typeof VivaOnlineState];
|
|
40848
|
+
|
|
40849
|
+
|
|
40396
40850
|
/**
|
|
40397
40851
|
*
|
|
40398
40852
|
* @export
|
|
@@ -51440,11 +51894,11 @@ export const GiftCardsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
51440
51894
|
};
|
|
51441
51895
|
},
|
|
51442
51896
|
/**
|
|
51443
|
-
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now, or never. The till channel does not need to be on. Who made it is stored.
|
|
51897
|
+
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now (from sendAt when one is sent), or never. With sendAt its email is queued for that moment instead of now. The till channel does not need to be on. Who made it is stored.
|
|
51444
51898
|
* @summary Make a gift card by hand, given for free
|
|
51445
51899
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
51446
51900
|
* @param {CreateVenueGiftCardDto} createVenueGiftCardDto
|
|
51447
|
-
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
51901
|
+
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, sendAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
51448
51902
|
* @param {*} [options] Override http request option.
|
|
51449
51903
|
* @throws {RequiredError}
|
|
51450
51904
|
*/
|
|
@@ -51620,6 +52074,44 @@ export const GiftCardsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
51620
52074
|
|
|
51621
52075
|
|
|
51622
52076
|
|
|
52077
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
52078
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
52079
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
52080
|
+
|
|
52081
|
+
return {
|
|
52082
|
+
url: toPathString(localVarUrlObj),
|
|
52083
|
+
options: localVarRequestOptions,
|
|
52084
|
+
};
|
|
52085
|
+
},
|
|
52086
|
+
/**
|
|
52087
|
+
* Each step before the store may sell gift cards online, its online store (food ordering) on or off: card payments online (its Stripe connection and Viva in its online store, read from Vendure; Viva at its POS from its POS config) and amounts to choose; ready when every step is done. Two statements and two reads of Vendure at once; nothing is written.
|
|
52088
|
+
* @summary Read a store\'s checklist for selling gift cards online
|
|
52089
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
52090
|
+
* @param {*} [options] Override http request option.
|
|
52091
|
+
* @throws {RequiredError}
|
|
52092
|
+
*/
|
|
52093
|
+
getVenueGiftCardSelling: async (businessId: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
52094
|
+
// verify required parameter 'businessId' is not null or undefined
|
|
52095
|
+
assertParamExists('getVenueGiftCardSelling', 'businessId', businessId)
|
|
52096
|
+
const localVarPath = `/api/v2/venues/{businessId}/gift-card-selling`
|
|
52097
|
+
.replace(`{${"businessId"}}`, encodeURIComponent(String(businessId)));
|
|
52098
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
52099
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
52100
|
+
let baseOptions;
|
|
52101
|
+
if (configuration) {
|
|
52102
|
+
baseOptions = configuration.baseOptions;
|
|
52103
|
+
}
|
|
52104
|
+
|
|
52105
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
52106
|
+
const localVarHeaderParameter = {} as any;
|
|
52107
|
+
const localVarQueryParameter = {} as any;
|
|
52108
|
+
|
|
52109
|
+
// authentication JWT-auth required
|
|
52110
|
+
// http bearer authentication required
|
|
52111
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
52112
|
+
|
|
52113
|
+
|
|
52114
|
+
|
|
51623
52115
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
51624
52116
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
51625
52117
|
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
@@ -51748,7 +52240,7 @@ export const GiftCardsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
51748
52240
|
* The cards of the store\'s owner, newest first (createdAt, then id). search finds a code that starts with it, or a buyer\'s name or email that contains it; state keeps the cards in that state now. Send nextCursor as cursor for the next page. Three statements; nothing is written.
|
|
51749
52241
|
* @summary List a store\'s gift cards, newest first, a page at a time
|
|
51750
52242
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
51751
|
-
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive. Absent: every card.
|
|
52243
|
+
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive; or, when the search is a phone number (only digits, spaces, +, -, ( ) and dots, at least 6 digits), a buyer\'s phone number whose digits contain it. The search drops its spaces and dashes, a leading 00, and a leading 0; the stored number is read by its digits without a leading 0, however it was typed. A search with +358 or 00358 finds the Finnish number, and one with another country code finds a number stored with that code. \"040 123 4567\", \"+358401234567\" and \"401234567\" all find +358 / 40 123 4567. Absent: every card.
|
|
51752
52244
|
* @param {GiftCardState} [state] Only the cards in this state now. Absent: every state.
|
|
51753
52245
|
* @param {string} [cursor] The nextCursor of the page before: a card\'s id. Absent for the first page.
|
|
51754
52246
|
* @param {number} [limit] How many cards a page holds, 1 to 100. Absent: 50.
|
|
@@ -51808,7 +52300,7 @@ export const GiftCardsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
51808
52300
|
};
|
|
51809
52301
|
},
|
|
51810
52302
|
/**
|
|
51811
|
-
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is.
|
|
52303
|
+
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is; a card blocked because its online order was refunded stays blocked.
|
|
51812
52304
|
* @summary Unblock a gift card
|
|
51813
52305
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
51814
52306
|
* @param {string} cardId The card\'s id
|
|
@@ -51850,8 +52342,8 @@ export const GiftCardsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
51850
52342
|
};
|
|
51851
52343
|
},
|
|
51852
52344
|
/**
|
|
51853
|
-
*
|
|
51854
|
-
* @summary Correct a gift card\'s email address
|
|
52345
|
+
* Changes the fields sent and keeps the others. buyerEmail saves the address, or removes it with null; who did it and when show in the card\'s history as EMAIL_CHANGED, and nothing is sent: send the card again to email the new address. sendAt moves the card\'s email while it waits for its first try: to that moment, or now with null; the card\'s sendAt and its history\'s SCHEDULED line follow.
|
|
52346
|
+
* @summary Correct a gift card\'s email address, its emails\' language, or when its email goes
|
|
51855
52347
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
51856
52348
|
* @param {string} cardId The card\'s id
|
|
51857
52349
|
* @param {UpdateVenueGiftCardDto} updateVenueGiftCardDto
|
|
@@ -51898,7 +52390,7 @@ export const GiftCardsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
51898
52390
|
};
|
|
51899
52391
|
},
|
|
51900
52392
|
/**
|
|
51901
|
-
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). Of two changes at once the last to commit wins whole.
|
|
52393
|
+
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). The selling switch is on by default. Turning it from false to true is taken only while GET gift-card-selling answers ready, read again here; the amounts may always be cleared, and the offer then does not sell. The online store (food ordering) is never read. A change of other fields is never refused for the switch. Of two changes at once the last to commit wins whole.
|
|
51902
52394
|
* @summary Change a store\'s gift card settings
|
|
51903
52395
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
51904
52396
|
* @param {UpdateGiftCardSettingsDto} updateGiftCardSettingsDto
|
|
@@ -51977,11 +52469,11 @@ export const GiftCardsApiFp = function(configuration?: Configuration) {
|
|
|
51977
52469
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
51978
52470
|
},
|
|
51979
52471
|
/**
|
|
51980
|
-
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now, or never. The till channel does not need to be on. Who made it is stored.
|
|
52472
|
+
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now (from sendAt when one is sent), or never. With sendAt its email is queued for that moment instead of now. The till channel does not need to be on. Who made it is stored.
|
|
51981
52473
|
* @summary Make a gift card by hand, given for free
|
|
51982
52474
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
51983
52475
|
* @param {CreateVenueGiftCardDto} createVenueGiftCardDto
|
|
51984
|
-
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52476
|
+
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, sendAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
51985
52477
|
* @param {*} [options] Override http request option.
|
|
51986
52478
|
* @throws {RequiredError}
|
|
51987
52479
|
*/
|
|
@@ -52027,6 +52519,17 @@ export const GiftCardsApiFp = function(configuration?: Configuration) {
|
|
|
52027
52519
|
const localVarAxiosArgs = await localVarAxiosParamCreator.getVenueGiftCardReport(businessId, from, to, options);
|
|
52028
52520
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
52029
52521
|
},
|
|
52522
|
+
/**
|
|
52523
|
+
* Each step before the store may sell gift cards online, its online store (food ordering) on or off: card payments online (its Stripe connection and Viva in its online store, read from Vendure; Viva at its POS from its POS config) and amounts to choose; ready when every step is done. Two statements and two reads of Vendure at once; nothing is written.
|
|
52524
|
+
* @summary Read a store\'s checklist for selling gift cards online
|
|
52525
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
52526
|
+
* @param {*} [options] Override http request option.
|
|
52527
|
+
* @throws {RequiredError}
|
|
52528
|
+
*/
|
|
52529
|
+
async getVenueGiftCardSelling(businessId: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GiftCardSellingDto>> {
|
|
52530
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getVenueGiftCardSelling(businessId, options);
|
|
52531
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
52532
|
+
},
|
|
52030
52533
|
/**
|
|
52031
52534
|
* Where its cards can be spent, the amounts offered, how long a card stays valid, and its look; the defaults when the store never saved them (till on, online store off). availableChannels lists the store\'s own channels that are on and can take cards. Two statements; nothing is written.
|
|
52032
52535
|
* @summary Read a store\'s gift card settings
|
|
@@ -52060,7 +52563,7 @@ export const GiftCardsApiFp = function(configuration?: Configuration) {
|
|
|
52060
52563
|
* The cards of the store\'s owner, newest first (createdAt, then id). search finds a code that starts with it, or a buyer\'s name or email that contains it; state keeps the cards in that state now. Send nextCursor as cursor for the next page. Three statements; nothing is written.
|
|
52061
52564
|
* @summary List a store\'s gift cards, newest first, a page at a time
|
|
52062
52565
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52063
|
-
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive. Absent: every card.
|
|
52566
|
+
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive; or, when the search is a phone number (only digits, spaces, +, -, ( ) and dots, at least 6 digits), a buyer\'s phone number whose digits contain it. The search drops its spaces and dashes, a leading 00, and a leading 0; the stored number is read by its digits without a leading 0, however it was typed. A search with +358 or 00358 finds the Finnish number, and one with another country code finds a number stored with that code. \"040 123 4567\", \"+358401234567\" and \"401234567\" all find +358 / 40 123 4567. Absent: every card.
|
|
52064
52567
|
* @param {GiftCardState} [state] Only the cards in this state now. Absent: every state.
|
|
52065
52568
|
* @param {string} [cursor] The nextCursor of the page before: a card\'s id. Absent for the first page.
|
|
52066
52569
|
* @param {number} [limit] How many cards a page holds, 1 to 100. Absent: 50.
|
|
@@ -52073,7 +52576,7 @@ export const GiftCardsApiFp = function(configuration?: Configuration) {
|
|
|
52073
52576
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
52074
52577
|
},
|
|
52075
52578
|
/**
|
|
52076
|
-
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is.
|
|
52579
|
+
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is; a card blocked because its online order was refunded stays blocked.
|
|
52077
52580
|
* @summary Unblock a gift card
|
|
52078
52581
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52079
52582
|
* @param {string} cardId The card\'s id
|
|
@@ -52085,8 +52588,8 @@ export const GiftCardsApiFp = function(configuration?: Configuration) {
|
|
|
52085
52588
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
52086
52589
|
},
|
|
52087
52590
|
/**
|
|
52088
|
-
*
|
|
52089
|
-
* @summary Correct a gift card\'s email address
|
|
52591
|
+
* Changes the fields sent and keeps the others. buyerEmail saves the address, or removes it with null; who did it and when show in the card\'s history as EMAIL_CHANGED, and nothing is sent: send the card again to email the new address. sendAt moves the card\'s email while it waits for its first try: to that moment, or now with null; the card\'s sendAt and its history\'s SCHEDULED line follow.
|
|
52592
|
+
* @summary Correct a gift card\'s email address, its emails\' language, or when its email goes
|
|
52090
52593
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52091
52594
|
* @param {string} cardId The card\'s id
|
|
52092
52595
|
* @param {UpdateVenueGiftCardDto} updateVenueGiftCardDto
|
|
@@ -52098,7 +52601,7 @@ export const GiftCardsApiFp = function(configuration?: Configuration) {
|
|
|
52098
52601
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
52099
52602
|
},
|
|
52100
52603
|
/**
|
|
52101
|
-
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). Of two changes at once the last to commit wins whole.
|
|
52604
|
+
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). The selling switch is on by default. Turning it from false to true is taken only while GET gift-card-selling answers ready, read again here; the amounts may always be cleared, and the offer then does not sell. The online store (food ordering) is never read. A change of other fields is never refused for the switch. Of two changes at once the last to commit wins whole.
|
|
52102
52605
|
* @summary Change a store\'s gift card settings
|
|
52103
52606
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52104
52607
|
* @param {UpdateGiftCardSettingsDto} updateGiftCardSettingsDto
|
|
@@ -52143,11 +52646,11 @@ export const GiftCardsApiFactory = function (configuration?: Configuration, base
|
|
|
52143
52646
|
return localVarFp.blockVenueGiftCard(businessId, cardId, blockVenueGiftCardDto, options).then((request) => request(axios, basePath));
|
|
52144
52647
|
},
|
|
52145
52648
|
/**
|
|
52146
|
-
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now, or never. The till channel does not need to be on. Who made it is stored.
|
|
52649
|
+
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now (from sendAt when one is sent), or never. With sendAt its email is queued for that moment instead of now. The till channel does not need to be on. Who made it is stored.
|
|
52147
52650
|
* @summary Make a gift card by hand, given for free
|
|
52148
52651
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52149
52652
|
* @param {CreateVenueGiftCardDto} createVenueGiftCardDto
|
|
52150
|
-
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52653
|
+
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, sendAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52151
52654
|
* @param {*} [options] Override http request option.
|
|
52152
52655
|
* @throws {RequiredError}
|
|
52153
52656
|
*/
|
|
@@ -52189,6 +52692,16 @@ export const GiftCardsApiFactory = function (configuration?: Configuration, base
|
|
|
52189
52692
|
getVenueGiftCardReport(businessId: number, from: string, to: string, options?: any): AxiosPromise<GiftCardReportDto> {
|
|
52190
52693
|
return localVarFp.getVenueGiftCardReport(businessId, from, to, options).then((request) => request(axios, basePath));
|
|
52191
52694
|
},
|
|
52695
|
+
/**
|
|
52696
|
+
* Each step before the store may sell gift cards online, its online store (food ordering) on or off: card payments online (its Stripe connection and Viva in its online store, read from Vendure; Viva at its POS from its POS config) and amounts to choose; ready when every step is done. Two statements and two reads of Vendure at once; nothing is written.
|
|
52697
|
+
* @summary Read a store\'s checklist for selling gift cards online
|
|
52698
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
52699
|
+
* @param {*} [options] Override http request option.
|
|
52700
|
+
* @throws {RequiredError}
|
|
52701
|
+
*/
|
|
52702
|
+
getVenueGiftCardSelling(businessId: number, options?: any): AxiosPromise<GiftCardSellingDto> {
|
|
52703
|
+
return localVarFp.getVenueGiftCardSelling(businessId, options).then((request) => request(axios, basePath));
|
|
52704
|
+
},
|
|
52192
52705
|
/**
|
|
52193
52706
|
* Where its cards can be spent, the amounts offered, how long a card stays valid, and its look; the defaults when the store never saved them (till on, online store off). availableChannels lists the store\'s own channels that are on and can take cards. Two statements; nothing is written.
|
|
52194
52707
|
* @summary Read a store\'s gift card settings
|
|
@@ -52220,7 +52733,7 @@ export const GiftCardsApiFactory = function (configuration?: Configuration, base
|
|
|
52220
52733
|
* The cards of the store\'s owner, newest first (createdAt, then id). search finds a code that starts with it, or a buyer\'s name or email that contains it; state keeps the cards in that state now. Send nextCursor as cursor for the next page. Three statements; nothing is written.
|
|
52221
52734
|
* @summary List a store\'s gift cards, newest first, a page at a time
|
|
52222
52735
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52223
|
-
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive. Absent: every card.
|
|
52736
|
+
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive; or, when the search is a phone number (only digits, spaces, +, -, ( ) and dots, at least 6 digits), a buyer\'s phone number whose digits contain it. The search drops its spaces and dashes, a leading 00, and a leading 0; the stored number is read by its digits without a leading 0, however it was typed. A search with +358 or 00358 finds the Finnish number, and one with another country code finds a number stored with that code. \"040 123 4567\", \"+358401234567\" and \"401234567\" all find +358 / 40 123 4567. Absent: every card.
|
|
52224
52737
|
* @param {GiftCardState} [state] Only the cards in this state now. Absent: every state.
|
|
52225
52738
|
* @param {string} [cursor] The nextCursor of the page before: a card\'s id. Absent for the first page.
|
|
52226
52739
|
* @param {number} [limit] How many cards a page holds, 1 to 100. Absent: 50.
|
|
@@ -52232,7 +52745,7 @@ export const GiftCardsApiFactory = function (configuration?: Configuration, base
|
|
|
52232
52745
|
return localVarFp.listVenueGiftCards(businessId, search, state, cursor, limit, expiresBefore, options).then((request) => request(axios, basePath));
|
|
52233
52746
|
},
|
|
52234
52747
|
/**
|
|
52235
|
-
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is.
|
|
52748
|
+
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is; a card blocked because its online order was refunded stays blocked.
|
|
52236
52749
|
* @summary Unblock a gift card
|
|
52237
52750
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52238
52751
|
* @param {string} cardId The card\'s id
|
|
@@ -52243,8 +52756,8 @@ export const GiftCardsApiFactory = function (configuration?: Configuration, base
|
|
|
52243
52756
|
return localVarFp.unblockVenueGiftCard(businessId, cardId, options).then((request) => request(axios, basePath));
|
|
52244
52757
|
},
|
|
52245
52758
|
/**
|
|
52246
|
-
*
|
|
52247
|
-
* @summary Correct a gift card\'s email address
|
|
52759
|
+
* Changes the fields sent and keeps the others. buyerEmail saves the address, or removes it with null; who did it and when show in the card\'s history as EMAIL_CHANGED, and nothing is sent: send the card again to email the new address. sendAt moves the card\'s email while it waits for its first try: to that moment, or now with null; the card\'s sendAt and its history\'s SCHEDULED line follow.
|
|
52760
|
+
* @summary Correct a gift card\'s email address, its emails\' language, or when its email goes
|
|
52248
52761
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52249
52762
|
* @param {string} cardId The card\'s id
|
|
52250
52763
|
* @param {UpdateVenueGiftCardDto} updateVenueGiftCardDto
|
|
@@ -52255,7 +52768,7 @@ export const GiftCardsApiFactory = function (configuration?: Configuration, base
|
|
|
52255
52768
|
return localVarFp.updateVenueGiftCard(businessId, cardId, updateVenueGiftCardDto, options).then((request) => request(axios, basePath));
|
|
52256
52769
|
},
|
|
52257
52770
|
/**
|
|
52258
|
-
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). Of two changes at once the last to commit wins whole.
|
|
52771
|
+
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). The selling switch is on by default. Turning it from false to true is taken only while GET gift-card-selling answers ready, read again here; the amounts may always be cleared, and the offer then does not sell. The online store (food ordering) is never read. A change of other fields is never refused for the switch. Of two changes at once the last to commit wins whole.
|
|
52259
52772
|
* @summary Change a store\'s gift card settings
|
|
52260
52773
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52261
52774
|
* @param {UpdateGiftCardSettingsDto} updateGiftCardSettingsDto
|
|
@@ -52298,11 +52811,11 @@ export interface GiftCardsApiInterface {
|
|
|
52298
52811
|
blockVenueGiftCard(businessId: number, cardId: string, blockVenueGiftCardDto: BlockVenueGiftCardDto, options?: AxiosRequestConfig): AxiosPromise<VenueGiftCardDetailDto>;
|
|
52299
52812
|
|
|
52300
52813
|
/**
|
|
52301
|
-
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now, or never. The till channel does not need to be on. Who made it is stored.
|
|
52814
|
+
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now (from sendAt when one is sent), or never. With sendAt its email is queued for that moment instead of now. The till channel does not need to be on. Who made it is stored.
|
|
52302
52815
|
* @summary Make a gift card by hand, given for free
|
|
52303
52816
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52304
52817
|
* @param {CreateVenueGiftCardDto} createVenueGiftCardDto
|
|
52305
|
-
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52818
|
+
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, sendAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52306
52819
|
* @param {*} [options] Override http request option.
|
|
52307
52820
|
* @throws {RequiredError}
|
|
52308
52821
|
* @memberof GiftCardsApiInterface
|
|
@@ -52344,6 +52857,16 @@ export interface GiftCardsApiInterface {
|
|
|
52344
52857
|
*/
|
|
52345
52858
|
getVenueGiftCardReport(businessId: number, from: string, to: string, options?: AxiosRequestConfig): AxiosPromise<GiftCardReportDto>;
|
|
52346
52859
|
|
|
52860
|
+
/**
|
|
52861
|
+
* Each step before the store may sell gift cards online, its online store (food ordering) on or off: card payments online (its Stripe connection and Viva in its online store, read from Vendure; Viva at its POS from its POS config) and amounts to choose; ready when every step is done. Two statements and two reads of Vendure at once; nothing is written.
|
|
52862
|
+
* @summary Read a store\'s checklist for selling gift cards online
|
|
52863
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
52864
|
+
* @param {*} [options] Override http request option.
|
|
52865
|
+
* @throws {RequiredError}
|
|
52866
|
+
* @memberof GiftCardsApiInterface
|
|
52867
|
+
*/
|
|
52868
|
+
getVenueGiftCardSelling(businessId: number, options?: AxiosRequestConfig): AxiosPromise<GiftCardSellingDto>;
|
|
52869
|
+
|
|
52347
52870
|
/**
|
|
52348
52871
|
* Where its cards can be spent, the amounts offered, how long a card stays valid, and its look; the defaults when the store never saved them (till on, online store off). availableChannels lists the store\'s own channels that are on and can take cards. Two statements; nothing is written.
|
|
52349
52872
|
* @summary Read a store\'s gift card settings
|
|
@@ -52375,7 +52898,7 @@ export interface GiftCardsApiInterface {
|
|
|
52375
52898
|
* The cards of the store\'s owner, newest first (createdAt, then id). search finds a code that starts with it, or a buyer\'s name or email that contains it; state keeps the cards in that state now. Send nextCursor as cursor for the next page. Three statements; nothing is written.
|
|
52376
52899
|
* @summary List a store\'s gift cards, newest first, a page at a time
|
|
52377
52900
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52378
|
-
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive. Absent: every card.
|
|
52901
|
+
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive; or, when the search is a phone number (only digits, spaces, +, -, ( ) and dots, at least 6 digits), a buyer\'s phone number whose digits contain it. The search drops its spaces and dashes, a leading 00, and a leading 0; the stored number is read by its digits without a leading 0, however it was typed. A search with +358 or 00358 finds the Finnish number, and one with another country code finds a number stored with that code. \"040 123 4567\", \"+358401234567\" and \"401234567\" all find +358 / 40 123 4567. Absent: every card.
|
|
52379
52902
|
* @param {GiftCardState} [state] Only the cards in this state now. Absent: every state.
|
|
52380
52903
|
* @param {string} [cursor] The nextCursor of the page before: a card\'s id. Absent for the first page.
|
|
52381
52904
|
* @param {number} [limit] How many cards a page holds, 1 to 100. Absent: 50.
|
|
@@ -52387,7 +52910,7 @@ export interface GiftCardsApiInterface {
|
|
|
52387
52910
|
listVenueGiftCards(businessId: number, search?: string, state?: GiftCardState, cursor?: string, limit?: number, expiresBefore?: string, options?: AxiosRequestConfig): AxiosPromise<VenueGiftCardsDto>;
|
|
52388
52911
|
|
|
52389
52912
|
/**
|
|
52390
|
-
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is.
|
|
52913
|
+
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is; a card blocked because its online order was refunded stays blocked.
|
|
52391
52914
|
* @summary Unblock a gift card
|
|
52392
52915
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52393
52916
|
* @param {string} cardId The card\'s id
|
|
@@ -52398,8 +52921,8 @@ export interface GiftCardsApiInterface {
|
|
|
52398
52921
|
unblockVenueGiftCard(businessId: number, cardId: string, options?: AxiosRequestConfig): AxiosPromise<VenueGiftCardDetailDto>;
|
|
52399
52922
|
|
|
52400
52923
|
/**
|
|
52401
|
-
*
|
|
52402
|
-
* @summary Correct a gift card\'s email address
|
|
52924
|
+
* Changes the fields sent and keeps the others. buyerEmail saves the address, or removes it with null; who did it and when show in the card\'s history as EMAIL_CHANGED, and nothing is sent: send the card again to email the new address. sendAt moves the card\'s email while it waits for its first try: to that moment, or now with null; the card\'s sendAt and its history\'s SCHEDULED line follow.
|
|
52925
|
+
* @summary Correct a gift card\'s email address, its emails\' language, or when its email goes
|
|
52403
52926
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52404
52927
|
* @param {string} cardId The card\'s id
|
|
52405
52928
|
* @param {UpdateVenueGiftCardDto} updateVenueGiftCardDto
|
|
@@ -52410,7 +52933,7 @@ export interface GiftCardsApiInterface {
|
|
|
52410
52933
|
updateVenueGiftCard(businessId: number, cardId: string, updateVenueGiftCardDto: UpdateVenueGiftCardDto, options?: AxiosRequestConfig): AxiosPromise<VenueGiftCardDetailDto>;
|
|
52411
52934
|
|
|
52412
52935
|
/**
|
|
52413
|
-
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). Of two changes at once the last to commit wins whole.
|
|
52936
|
+
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). The selling switch is on by default. Turning it from false to true is taken only while GET gift-card-selling answers ready, read again here; the amounts may always be cleared, and the offer then does not sell. The online store (food ordering) is never read. A change of other fields is never refused for the switch. Of two changes at once the last to commit wins whole.
|
|
52414
52937
|
* @summary Change a store\'s gift card settings
|
|
52415
52938
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52416
52939
|
* @param {UpdateGiftCardSettingsDto} updateGiftCardSettingsDto
|
|
@@ -52457,11 +52980,11 @@ export class GiftCardsApi extends BaseAPI implements GiftCardsApiInterface {
|
|
|
52457
52980
|
}
|
|
52458
52981
|
|
|
52459
52982
|
/**
|
|
52460
|
-
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now, or never. The till channel does not need to be on. Who made it is stored.
|
|
52983
|
+
* A card of the amount, ACTIVE at once, made BY_HAND at this store and owned like a till sale (by the store\'s merchant when it has one), in the store\'s currency. Without expiresAt it expires the settings\' validityMonths from now (from sendAt when one is sent), or never. With sendAt its email is queued for that moment instead of now. The till channel does not need to be on. Who made it is stored.
|
|
52461
52984
|
* @summary Make a gift card by hand, given for free
|
|
52462
52985
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52463
52986
|
* @param {CreateVenueGiftCardDto} createVenueGiftCardDto
|
|
52464
|
-
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52987
|
+
* @param {string} [xIdempotencyKey] Client-generated UUID, one per card made; 8 to 100 letters, digits, \'-\' or \'_\'. A repeat with the same key answers 201 with the card it made and makes no other, also when two arrive at once, when it matches that card: the same store\'s owner, amount, recipientName and note, and expiresAt, sendAt, buyerEmail, phoneCountryCode and phoneNumber when it sends them (one left out is not compared, since it was worked out from the first request\'s time). Any other repeat, or a key a till\'s sale used, is refused 400. Without the header every request makes a card.
|
|
52465
52988
|
* @param {*} [options] Override http request option.
|
|
52466
52989
|
* @throws {RequiredError}
|
|
52467
52990
|
* @memberof GiftCardsApi
|
|
@@ -52511,6 +53034,18 @@ export class GiftCardsApi extends BaseAPI implements GiftCardsApiInterface {
|
|
|
52511
53034
|
return GiftCardsApiFp(this.configuration).getVenueGiftCardReport(businessId, from, to, options).then((request) => request(this.axios, this.basePath));
|
|
52512
53035
|
}
|
|
52513
53036
|
|
|
53037
|
+
/**
|
|
53038
|
+
* Each step before the store may sell gift cards online, its online store (food ordering) on or off: card payments online (its Stripe connection and Viva in its online store, read from Vendure; Viva at its POS from its POS config) and amounts to choose; ready when every step is done. Two statements and two reads of Vendure at once; nothing is written.
|
|
53039
|
+
* @summary Read a store\'s checklist for selling gift cards online
|
|
53040
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
53041
|
+
* @param {*} [options] Override http request option.
|
|
53042
|
+
* @throws {RequiredError}
|
|
53043
|
+
* @memberof GiftCardsApi
|
|
53044
|
+
*/
|
|
53045
|
+
public getVenueGiftCardSelling(businessId: number, options?: AxiosRequestConfig) {
|
|
53046
|
+
return GiftCardsApiFp(this.configuration).getVenueGiftCardSelling(businessId, options).then((request) => request(this.axios, this.basePath));
|
|
53047
|
+
}
|
|
53048
|
+
|
|
52514
53049
|
/**
|
|
52515
53050
|
* Where its cards can be spent, the amounts offered, how long a card stays valid, and its look; the defaults when the store never saved them (till on, online store off). availableChannels lists the store\'s own channels that are on and can take cards. Two statements; nothing is written.
|
|
52516
53051
|
* @summary Read a store\'s gift card settings
|
|
@@ -52546,7 +53081,7 @@ export class GiftCardsApi extends BaseAPI implements GiftCardsApiInterface {
|
|
|
52546
53081
|
* The cards of the store\'s owner, newest first (createdAt, then id). search finds a code that starts with it, or a buyer\'s name or email that contains it; state keeps the cards in that state now. Send nextCursor as cursor for the next page. Three statements; nothing is written.
|
|
52547
53082
|
* @summary List a store\'s gift cards, newest first, a page at a time
|
|
52548
53083
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52549
|
-
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive. Absent: every card.
|
|
53084
|
+
* @param {string} [search] A code that starts with this, or a buyer\'s name or email that contains it, case-insensitive; or, when the search is a phone number (only digits, spaces, +, -, ( ) and dots, at least 6 digits), a buyer\'s phone number whose digits contain it. The search drops its spaces and dashes, a leading 00, and a leading 0; the stored number is read by its digits without a leading 0, however it was typed. A search with +358 or 00358 finds the Finnish number, and one with another country code finds a number stored with that code. \"040 123 4567\", \"+358401234567\" and \"401234567\" all find +358 / 40 123 4567. Absent: every card.
|
|
52550
53085
|
* @param {GiftCardState} [state] Only the cards in this state now. Absent: every state.
|
|
52551
53086
|
* @param {string} [cursor] The nextCursor of the page before: a card\'s id. Absent for the first page.
|
|
52552
53087
|
* @param {number} [limit] How many cards a page holds, 1 to 100. Absent: 50.
|
|
@@ -52560,7 +53095,7 @@ export class GiftCardsApi extends BaseAPI implements GiftCardsApiInterface {
|
|
|
52560
53095
|
}
|
|
52561
53096
|
|
|
52562
53097
|
/**
|
|
52563
|
-
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is.
|
|
53098
|
+
* The card works again as its state says. The block stays in its history, followed by the unblock and who made it. A card not blocked is answered as it is; a card blocked because its online order was refunded stays blocked.
|
|
52564
53099
|
* @summary Unblock a gift card
|
|
52565
53100
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52566
53101
|
* @param {string} cardId The card\'s id
|
|
@@ -52573,8 +53108,8 @@ export class GiftCardsApi extends BaseAPI implements GiftCardsApiInterface {
|
|
|
52573
53108
|
}
|
|
52574
53109
|
|
|
52575
53110
|
/**
|
|
52576
|
-
*
|
|
52577
|
-
* @summary Correct a gift card\'s email address
|
|
53111
|
+
* Changes the fields sent and keeps the others. buyerEmail saves the address, or removes it with null; who did it and when show in the card\'s history as EMAIL_CHANGED, and nothing is sent: send the card again to email the new address. sendAt moves the card\'s email while it waits for its first try: to that moment, or now with null; the card\'s sendAt and its history\'s SCHEDULED line follow.
|
|
53112
|
+
* @summary Correct a gift card\'s email address, its emails\' language, or when its email goes
|
|
52578
53113
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52579
53114
|
* @param {string} cardId The card\'s id
|
|
52580
53115
|
* @param {UpdateVenueGiftCardDto} updateVenueGiftCardDto
|
|
@@ -52587,7 +53122,7 @@ export class GiftCardsApi extends BaseAPI implements GiftCardsApiInterface {
|
|
|
52587
53122
|
}
|
|
52588
53123
|
|
|
52589
53124
|
/**
|
|
52590
|
-
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). Of two changes at once the last to commit wins whole.
|
|
53125
|
+
* Changes the fields sent and keeps the others; null clears validityMonths (cards never expire), cardText or imageUrl. With the Till channel off, the store\'s till refuses to sell, validate or redeem a card (1012). The selling switch is on by default. Turning it from false to true is taken only while GET gift-card-selling answers ready, read again here; the amounts may always be cleared, and the offer then does not sell. The online store (food ordering) is never read. A change of other fields is never refused for the switch. Of two changes at once the last to commit wins whole.
|
|
52591
53126
|
* @summary Change a store\'s gift card settings
|
|
52592
53127
|
* @param {number} businessId The store\'s orderingBusinessId
|
|
52593
53128
|
* @param {UpdateGiftCardSettingsDto} updateGiftCardSettingsDto
|
|
@@ -53911,6 +54446,364 @@ export class HistoryV6Api extends BaseAPI implements HistoryV6ApiInterface {
|
|
|
53911
54446
|
}
|
|
53912
54447
|
|
|
53913
54448
|
|
|
54449
|
+
/**
|
|
54450
|
+
* InternalGiftCardsApi - axios parameter creator
|
|
54451
|
+
* @export
|
|
54452
|
+
*/
|
|
54453
|
+
export const InternalGiftCardsApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
54454
|
+
return {
|
|
54455
|
+
/**
|
|
54456
|
+
* Vendure reads it to show the online store\'s gift card page and to check an order before it is placed: whether the store sells gift cards online now (its switch, on by default, and an amount to choose; its online store may be off), its amounts, look, currency, name and validity. Card payments online are Vendure\'s own check, not read here. One statement; nothing is written; no secret.
|
|
54457
|
+
* @summary Read what a store\'s online store offers of its gift cards
|
|
54458
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54459
|
+
* @param {*} [options] Override http request option.
|
|
54460
|
+
* @throws {RequiredError}
|
|
54461
|
+
*/
|
|
54462
|
+
getVenueGiftCardOffer: async (businessId: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
54463
|
+
// verify required parameter 'businessId' is not null or undefined
|
|
54464
|
+
assertParamExists('getVenueGiftCardOffer', 'businessId', businessId)
|
|
54465
|
+
const localVarPath = `/api/v2/internal/gift-cards/offers/{businessId}`
|
|
54466
|
+
.replace(`{${"businessId"}}`, encodeURIComponent(String(businessId)));
|
|
54467
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
54468
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
54469
|
+
let baseOptions;
|
|
54470
|
+
if (configuration) {
|
|
54471
|
+
baseOptions = configuration.baseOptions;
|
|
54472
|
+
}
|
|
54473
|
+
|
|
54474
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
54475
|
+
const localVarHeaderParameter = {} as any;
|
|
54476
|
+
const localVarQueryParameter = {} as any;
|
|
54477
|
+
|
|
54478
|
+
|
|
54479
|
+
|
|
54480
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
54481
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
54482
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
54483
|
+
|
|
54484
|
+
return {
|
|
54485
|
+
url: toPathString(localVarUrlObj),
|
|
54486
|
+
options: localVarRequestOptions,
|
|
54487
|
+
};
|
|
54488
|
+
},
|
|
54489
|
+
/**
|
|
54490
|
+
* Vendure reads it for \"Use my Viva\", to set up the online store\'s Viva from the merchant the store already has: the merchant id of the store\'s active POS Viva config, null when there is none. Only the merchant id, never a key. One statement; nothing is written.
|
|
54491
|
+
* @summary Read the Viva merchant a store\'s POS takes card payments with
|
|
54492
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54493
|
+
* @param {*} [options] Override http request option.
|
|
54494
|
+
* @throws {RequiredError}
|
|
54495
|
+
*/
|
|
54496
|
+
getVenuePosVivaMerchant: async (businessId: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
54497
|
+
// verify required parameter 'businessId' is not null or undefined
|
|
54498
|
+
assertParamExists('getVenuePosVivaMerchant', 'businessId', businessId)
|
|
54499
|
+
const localVarPath = `/api/v2/internal/gift-cards/pos-viva/{businessId}`
|
|
54500
|
+
.replace(`{${"businessId"}}`, encodeURIComponent(String(businessId)));
|
|
54501
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
54502
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
54503
|
+
let baseOptions;
|
|
54504
|
+
if (configuration) {
|
|
54505
|
+
baseOptions = configuration.baseOptions;
|
|
54506
|
+
}
|
|
54507
|
+
|
|
54508
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
54509
|
+
const localVarHeaderParameter = {} as any;
|
|
54510
|
+
const localVarQueryParameter = {} as any;
|
|
54511
|
+
|
|
54512
|
+
|
|
54513
|
+
|
|
54514
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
54515
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
54516
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
54517
|
+
|
|
54518
|
+
return {
|
|
54519
|
+
url: toPathString(localVarUrlObj),
|
|
54520
|
+
options: localVarRequestOptions,
|
|
54521
|
+
};
|
|
54522
|
+
},
|
|
54523
|
+
/**
|
|
54524
|
+
* Vendure calls it before it refunds a gift card order. The order line\'s card is blocked as refunded (its history shows REFUNDED, its block reason Refunded) only while nothing was spent of it, so it can no longer pay or be unblocked and none of its emails go any more. A repeat answers the first refund. A card of which anything was spent is refused 409: the card stays valid and the order must not be refunded.
|
|
54525
|
+
* @summary Block the gift card of an online order line before its order is refunded
|
|
54526
|
+
* @param {RefundOnlineGiftCardSaleDto} refundOnlineGiftCardSaleDto
|
|
54527
|
+
* @param {*} [options] Override http request option.
|
|
54528
|
+
* @throws {RequiredError}
|
|
54529
|
+
*/
|
|
54530
|
+
refundOnlineGiftCardSale: async (refundOnlineGiftCardSaleDto: RefundOnlineGiftCardSaleDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
54531
|
+
// verify required parameter 'refundOnlineGiftCardSaleDto' is not null or undefined
|
|
54532
|
+
assertParamExists('refundOnlineGiftCardSale', 'refundOnlineGiftCardSaleDto', refundOnlineGiftCardSaleDto)
|
|
54533
|
+
const localVarPath = `/api/v2/internal/gift-cards/online-sale/refund`;
|
|
54534
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
54535
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
54536
|
+
let baseOptions;
|
|
54537
|
+
if (configuration) {
|
|
54538
|
+
baseOptions = configuration.baseOptions;
|
|
54539
|
+
}
|
|
54540
|
+
|
|
54541
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
54542
|
+
const localVarHeaderParameter = {} as any;
|
|
54543
|
+
const localVarQueryParameter = {} as any;
|
|
54544
|
+
|
|
54545
|
+
|
|
54546
|
+
|
|
54547
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
54548
|
+
|
|
54549
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
54550
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
54551
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
54552
|
+
localVarRequestOptions.data = serializeDataIfNeeded(refundOnlineGiftCardSaleDto, localVarRequestOptions, configuration)
|
|
54553
|
+
|
|
54554
|
+
return {
|
|
54555
|
+
url: toPathString(localVarUrlObj),
|
|
54556
|
+
options: localVarRequestOptions,
|
|
54557
|
+
};
|
|
54558
|
+
},
|
|
54559
|
+
/**
|
|
54560
|
+
* Vendure calls it once the payment of a gift card order settles. The card is ACTIVE at once, sold online at orderingBusinessId and owned by its merchant when it has one, else by it; it expires the settings\' validityMonths after its email goes. Its email goes to recipient.email at sendAt (or at once); for a gift, the buyer gets a receipt without the code at once. Idempotent per orderCode and orderLineId: a repeat, also two at once, answers the card the line made, whatever the settings are now. Retry on no answer or 5xx; a 4xx is final: refund the order, after online-sale/refund when the 409 says a card exists.
|
|
54561
|
+
* @summary Make the gift card an online order line paid for
|
|
54562
|
+
* @param {SellGiftCardOnlineDto} sellGiftCardOnlineDto
|
|
54563
|
+
* @param {*} [options] Override http request option.
|
|
54564
|
+
* @throws {RequiredError}
|
|
54565
|
+
*/
|
|
54566
|
+
sellGiftCardOnline: async (sellGiftCardOnlineDto: SellGiftCardOnlineDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
54567
|
+
// verify required parameter 'sellGiftCardOnlineDto' is not null or undefined
|
|
54568
|
+
assertParamExists('sellGiftCardOnline', 'sellGiftCardOnlineDto', sellGiftCardOnlineDto)
|
|
54569
|
+
const localVarPath = `/api/v2/internal/gift-cards/online-sale`;
|
|
54570
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
54571
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
54572
|
+
let baseOptions;
|
|
54573
|
+
if (configuration) {
|
|
54574
|
+
baseOptions = configuration.baseOptions;
|
|
54575
|
+
}
|
|
54576
|
+
|
|
54577
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
54578
|
+
const localVarHeaderParameter = {} as any;
|
|
54579
|
+
const localVarQueryParameter = {} as any;
|
|
54580
|
+
|
|
54581
|
+
|
|
54582
|
+
|
|
54583
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
54584
|
+
|
|
54585
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
54586
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
54587
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
54588
|
+
localVarRequestOptions.data = serializeDataIfNeeded(sellGiftCardOnlineDto, localVarRequestOptions, configuration)
|
|
54589
|
+
|
|
54590
|
+
return {
|
|
54591
|
+
url: toPathString(localVarUrlObj),
|
|
54592
|
+
options: localVarRequestOptions,
|
|
54593
|
+
};
|
|
54594
|
+
},
|
|
54595
|
+
}
|
|
54596
|
+
};
|
|
54597
|
+
|
|
54598
|
+
/**
|
|
54599
|
+
* InternalGiftCardsApi - functional programming interface
|
|
54600
|
+
* @export
|
|
54601
|
+
*/
|
|
54602
|
+
export const InternalGiftCardsApiFp = function(configuration?: Configuration) {
|
|
54603
|
+
const localVarAxiosParamCreator = InternalGiftCardsApiAxiosParamCreator(configuration)
|
|
54604
|
+
return {
|
|
54605
|
+
/**
|
|
54606
|
+
* Vendure reads it to show the online store\'s gift card page and to check an order before it is placed: whether the store sells gift cards online now (its switch, on by default, and an amount to choose; its online store may be off), its amounts, look, currency, name and validity. Card payments online are Vendure\'s own check, not read here. One statement; nothing is written; no secret.
|
|
54607
|
+
* @summary Read what a store\'s online store offers of its gift cards
|
|
54608
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54609
|
+
* @param {*} [options] Override http request option.
|
|
54610
|
+
* @throws {RequiredError}
|
|
54611
|
+
*/
|
|
54612
|
+
async getVenueGiftCardOffer(businessId: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GiftCardOfferDto>> {
|
|
54613
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getVenueGiftCardOffer(businessId, options);
|
|
54614
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
54615
|
+
},
|
|
54616
|
+
/**
|
|
54617
|
+
* Vendure reads it for \"Use my Viva\", to set up the online store\'s Viva from the merchant the store already has: the merchant id of the store\'s active POS Viva config, null when there is none. Only the merchant id, never a key. One statement; nothing is written.
|
|
54618
|
+
* @summary Read the Viva merchant a store\'s POS takes card payments with
|
|
54619
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54620
|
+
* @param {*} [options] Override http request option.
|
|
54621
|
+
* @throws {RequiredError}
|
|
54622
|
+
*/
|
|
54623
|
+
async getVenuePosVivaMerchant(businessId: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PosVivaMerchantDto>> {
|
|
54624
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getVenuePosVivaMerchant(businessId, options);
|
|
54625
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
54626
|
+
},
|
|
54627
|
+
/**
|
|
54628
|
+
* Vendure calls it before it refunds a gift card order. The order line\'s card is blocked as refunded (its history shows REFUNDED, its block reason Refunded) only while nothing was spent of it, so it can no longer pay or be unblocked and none of its emails go any more. A repeat answers the first refund. A card of which anything was spent is refused 409: the card stays valid and the order must not be refunded.
|
|
54629
|
+
* @summary Block the gift card of an online order line before its order is refunded
|
|
54630
|
+
* @param {RefundOnlineGiftCardSaleDto} refundOnlineGiftCardSaleDto
|
|
54631
|
+
* @param {*} [options] Override http request option.
|
|
54632
|
+
* @throws {RequiredError}
|
|
54633
|
+
*/
|
|
54634
|
+
async refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto: RefundOnlineGiftCardSaleDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OnlineGiftCardRefundDto>> {
|
|
54635
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto, options);
|
|
54636
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
54637
|
+
},
|
|
54638
|
+
/**
|
|
54639
|
+
* Vendure calls it once the payment of a gift card order settles. The card is ACTIVE at once, sold online at orderingBusinessId and owned by its merchant when it has one, else by it; it expires the settings\' validityMonths after its email goes. Its email goes to recipient.email at sendAt (or at once); for a gift, the buyer gets a receipt without the code at once. Idempotent per orderCode and orderLineId: a repeat, also two at once, answers the card the line made, whatever the settings are now. Retry on no answer or 5xx; a 4xx is final: refund the order, after online-sale/refund when the 409 says a card exists.
|
|
54640
|
+
* @summary Make the gift card an online order line paid for
|
|
54641
|
+
* @param {SellGiftCardOnlineDto} sellGiftCardOnlineDto
|
|
54642
|
+
* @param {*} [options] Override http request option.
|
|
54643
|
+
* @throws {RequiredError}
|
|
54644
|
+
*/
|
|
54645
|
+
async sellGiftCardOnline(sellGiftCardOnlineDto: SellGiftCardOnlineDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OnlineGiftCardSaleDto>> {
|
|
54646
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.sellGiftCardOnline(sellGiftCardOnlineDto, options);
|
|
54647
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
54648
|
+
},
|
|
54649
|
+
}
|
|
54650
|
+
};
|
|
54651
|
+
|
|
54652
|
+
/**
|
|
54653
|
+
* InternalGiftCardsApi - factory interface
|
|
54654
|
+
* @export
|
|
54655
|
+
*/
|
|
54656
|
+
export const InternalGiftCardsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
54657
|
+
const localVarFp = InternalGiftCardsApiFp(configuration)
|
|
54658
|
+
return {
|
|
54659
|
+
/**
|
|
54660
|
+
* Vendure reads it to show the online store\'s gift card page and to check an order before it is placed: whether the store sells gift cards online now (its switch, on by default, and an amount to choose; its online store may be off), its amounts, look, currency, name and validity. Card payments online are Vendure\'s own check, not read here. One statement; nothing is written; no secret.
|
|
54661
|
+
* @summary Read what a store\'s online store offers of its gift cards
|
|
54662
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54663
|
+
* @param {*} [options] Override http request option.
|
|
54664
|
+
* @throws {RequiredError}
|
|
54665
|
+
*/
|
|
54666
|
+
getVenueGiftCardOffer(businessId: number, options?: any): AxiosPromise<GiftCardOfferDto> {
|
|
54667
|
+
return localVarFp.getVenueGiftCardOffer(businessId, options).then((request) => request(axios, basePath));
|
|
54668
|
+
},
|
|
54669
|
+
/**
|
|
54670
|
+
* Vendure reads it for \"Use my Viva\", to set up the online store\'s Viva from the merchant the store already has: the merchant id of the store\'s active POS Viva config, null when there is none. Only the merchant id, never a key. One statement; nothing is written.
|
|
54671
|
+
* @summary Read the Viva merchant a store\'s POS takes card payments with
|
|
54672
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54673
|
+
* @param {*} [options] Override http request option.
|
|
54674
|
+
* @throws {RequiredError}
|
|
54675
|
+
*/
|
|
54676
|
+
getVenuePosVivaMerchant(businessId: number, options?: any): AxiosPromise<PosVivaMerchantDto> {
|
|
54677
|
+
return localVarFp.getVenuePosVivaMerchant(businessId, options).then((request) => request(axios, basePath));
|
|
54678
|
+
},
|
|
54679
|
+
/**
|
|
54680
|
+
* Vendure calls it before it refunds a gift card order. The order line\'s card is blocked as refunded (its history shows REFUNDED, its block reason Refunded) only while nothing was spent of it, so it can no longer pay or be unblocked and none of its emails go any more. A repeat answers the first refund. A card of which anything was spent is refused 409: the card stays valid and the order must not be refunded.
|
|
54681
|
+
* @summary Block the gift card of an online order line before its order is refunded
|
|
54682
|
+
* @param {RefundOnlineGiftCardSaleDto} refundOnlineGiftCardSaleDto
|
|
54683
|
+
* @param {*} [options] Override http request option.
|
|
54684
|
+
* @throws {RequiredError}
|
|
54685
|
+
*/
|
|
54686
|
+
refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto: RefundOnlineGiftCardSaleDto, options?: any): AxiosPromise<OnlineGiftCardRefundDto> {
|
|
54687
|
+
return localVarFp.refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto, options).then((request) => request(axios, basePath));
|
|
54688
|
+
},
|
|
54689
|
+
/**
|
|
54690
|
+
* Vendure calls it once the payment of a gift card order settles. The card is ACTIVE at once, sold online at orderingBusinessId and owned by its merchant when it has one, else by it; it expires the settings\' validityMonths after its email goes. Its email goes to recipient.email at sendAt (or at once); for a gift, the buyer gets a receipt without the code at once. Idempotent per orderCode and orderLineId: a repeat, also two at once, answers the card the line made, whatever the settings are now. Retry on no answer or 5xx; a 4xx is final: refund the order, after online-sale/refund when the 409 says a card exists.
|
|
54691
|
+
* @summary Make the gift card an online order line paid for
|
|
54692
|
+
* @param {SellGiftCardOnlineDto} sellGiftCardOnlineDto
|
|
54693
|
+
* @param {*} [options] Override http request option.
|
|
54694
|
+
* @throws {RequiredError}
|
|
54695
|
+
*/
|
|
54696
|
+
sellGiftCardOnline(sellGiftCardOnlineDto: SellGiftCardOnlineDto, options?: any): AxiosPromise<OnlineGiftCardSaleDto> {
|
|
54697
|
+
return localVarFp.sellGiftCardOnline(sellGiftCardOnlineDto, options).then((request) => request(axios, basePath));
|
|
54698
|
+
},
|
|
54699
|
+
};
|
|
54700
|
+
};
|
|
54701
|
+
|
|
54702
|
+
/**
|
|
54703
|
+
* InternalGiftCardsApi - interface
|
|
54704
|
+
* @export
|
|
54705
|
+
* @interface InternalGiftCardsApi
|
|
54706
|
+
*/
|
|
54707
|
+
export interface InternalGiftCardsApiInterface {
|
|
54708
|
+
/**
|
|
54709
|
+
* Vendure reads it to show the online store\'s gift card page and to check an order before it is placed: whether the store sells gift cards online now (its switch, on by default, and an amount to choose; its online store may be off), its amounts, look, currency, name and validity. Card payments online are Vendure\'s own check, not read here. One statement; nothing is written; no secret.
|
|
54710
|
+
* @summary Read what a store\'s online store offers of its gift cards
|
|
54711
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54712
|
+
* @param {*} [options] Override http request option.
|
|
54713
|
+
* @throws {RequiredError}
|
|
54714
|
+
* @memberof InternalGiftCardsApiInterface
|
|
54715
|
+
*/
|
|
54716
|
+
getVenueGiftCardOffer(businessId: number, options?: AxiosRequestConfig): AxiosPromise<GiftCardOfferDto>;
|
|
54717
|
+
|
|
54718
|
+
/**
|
|
54719
|
+
* Vendure reads it for \"Use my Viva\", to set up the online store\'s Viva from the merchant the store already has: the merchant id of the store\'s active POS Viva config, null when there is none. Only the merchant id, never a key. One statement; nothing is written.
|
|
54720
|
+
* @summary Read the Viva merchant a store\'s POS takes card payments with
|
|
54721
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54722
|
+
* @param {*} [options] Override http request option.
|
|
54723
|
+
* @throws {RequiredError}
|
|
54724
|
+
* @memberof InternalGiftCardsApiInterface
|
|
54725
|
+
*/
|
|
54726
|
+
getVenuePosVivaMerchant(businessId: number, options?: AxiosRequestConfig): AxiosPromise<PosVivaMerchantDto>;
|
|
54727
|
+
|
|
54728
|
+
/**
|
|
54729
|
+
* Vendure calls it before it refunds a gift card order. The order line\'s card is blocked as refunded (its history shows REFUNDED, its block reason Refunded) only while nothing was spent of it, so it can no longer pay or be unblocked and none of its emails go any more. A repeat answers the first refund. A card of which anything was spent is refused 409: the card stays valid and the order must not be refunded.
|
|
54730
|
+
* @summary Block the gift card of an online order line before its order is refunded
|
|
54731
|
+
* @param {RefundOnlineGiftCardSaleDto} refundOnlineGiftCardSaleDto
|
|
54732
|
+
* @param {*} [options] Override http request option.
|
|
54733
|
+
* @throws {RequiredError}
|
|
54734
|
+
* @memberof InternalGiftCardsApiInterface
|
|
54735
|
+
*/
|
|
54736
|
+
refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto: RefundOnlineGiftCardSaleDto, options?: AxiosRequestConfig): AxiosPromise<OnlineGiftCardRefundDto>;
|
|
54737
|
+
|
|
54738
|
+
/**
|
|
54739
|
+
* Vendure calls it once the payment of a gift card order settles. The card is ACTIVE at once, sold online at orderingBusinessId and owned by its merchant when it has one, else by it; it expires the settings\' validityMonths after its email goes. Its email goes to recipient.email at sendAt (or at once); for a gift, the buyer gets a receipt without the code at once. Idempotent per orderCode and orderLineId: a repeat, also two at once, answers the card the line made, whatever the settings are now. Retry on no answer or 5xx; a 4xx is final: refund the order, after online-sale/refund when the 409 says a card exists.
|
|
54740
|
+
* @summary Make the gift card an online order line paid for
|
|
54741
|
+
* @param {SellGiftCardOnlineDto} sellGiftCardOnlineDto
|
|
54742
|
+
* @param {*} [options] Override http request option.
|
|
54743
|
+
* @throws {RequiredError}
|
|
54744
|
+
* @memberof InternalGiftCardsApiInterface
|
|
54745
|
+
*/
|
|
54746
|
+
sellGiftCardOnline(sellGiftCardOnlineDto: SellGiftCardOnlineDto, options?: AxiosRequestConfig): AxiosPromise<OnlineGiftCardSaleDto>;
|
|
54747
|
+
|
|
54748
|
+
}
|
|
54749
|
+
|
|
54750
|
+
/**
|
|
54751
|
+
* InternalGiftCardsApi - object-oriented interface
|
|
54752
|
+
* @export
|
|
54753
|
+
* @class InternalGiftCardsApi
|
|
54754
|
+
* @extends {BaseAPI}
|
|
54755
|
+
*/
|
|
54756
|
+
export class InternalGiftCardsApi extends BaseAPI implements InternalGiftCardsApiInterface {
|
|
54757
|
+
/**
|
|
54758
|
+
* Vendure reads it to show the online store\'s gift card page and to check an order before it is placed: whether the store sells gift cards online now (its switch, on by default, and an amount to choose; its online store may be off), its amounts, look, currency, name and validity. Card payments online are Vendure\'s own check, not read here. One statement; nothing is written; no secret.
|
|
54759
|
+
* @summary Read what a store\'s online store offers of its gift cards
|
|
54760
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54761
|
+
* @param {*} [options] Override http request option.
|
|
54762
|
+
* @throws {RequiredError}
|
|
54763
|
+
* @memberof InternalGiftCardsApi
|
|
54764
|
+
*/
|
|
54765
|
+
public getVenueGiftCardOffer(businessId: number, options?: AxiosRequestConfig) {
|
|
54766
|
+
return InternalGiftCardsApiFp(this.configuration).getVenueGiftCardOffer(businessId, options).then((request) => request(this.axios, this.basePath));
|
|
54767
|
+
}
|
|
54768
|
+
|
|
54769
|
+
/**
|
|
54770
|
+
* Vendure reads it for \"Use my Viva\", to set up the online store\'s Viva from the merchant the store already has: the merchant id of the store\'s active POS Viva config, null when there is none. Only the merchant id, never a key. One statement; nothing is written.
|
|
54771
|
+
* @summary Read the Viva merchant a store\'s POS takes card payments with
|
|
54772
|
+
* @param {number} businessId The store\'s orderingBusinessId
|
|
54773
|
+
* @param {*} [options] Override http request option.
|
|
54774
|
+
* @throws {RequiredError}
|
|
54775
|
+
* @memberof InternalGiftCardsApi
|
|
54776
|
+
*/
|
|
54777
|
+
public getVenuePosVivaMerchant(businessId: number, options?: AxiosRequestConfig) {
|
|
54778
|
+
return InternalGiftCardsApiFp(this.configuration).getVenuePosVivaMerchant(businessId, options).then((request) => request(this.axios, this.basePath));
|
|
54779
|
+
}
|
|
54780
|
+
|
|
54781
|
+
/**
|
|
54782
|
+
* Vendure calls it before it refunds a gift card order. The order line\'s card is blocked as refunded (its history shows REFUNDED, its block reason Refunded) only while nothing was spent of it, so it can no longer pay or be unblocked and none of its emails go any more. A repeat answers the first refund. A card of which anything was spent is refused 409: the card stays valid and the order must not be refunded.
|
|
54783
|
+
* @summary Block the gift card of an online order line before its order is refunded
|
|
54784
|
+
* @param {RefundOnlineGiftCardSaleDto} refundOnlineGiftCardSaleDto
|
|
54785
|
+
* @param {*} [options] Override http request option.
|
|
54786
|
+
* @throws {RequiredError}
|
|
54787
|
+
* @memberof InternalGiftCardsApi
|
|
54788
|
+
*/
|
|
54789
|
+
public refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto: RefundOnlineGiftCardSaleDto, options?: AxiosRequestConfig) {
|
|
54790
|
+
return InternalGiftCardsApiFp(this.configuration).refundOnlineGiftCardSale(refundOnlineGiftCardSaleDto, options).then((request) => request(this.axios, this.basePath));
|
|
54791
|
+
}
|
|
54792
|
+
|
|
54793
|
+
/**
|
|
54794
|
+
* Vendure calls it once the payment of a gift card order settles. The card is ACTIVE at once, sold online at orderingBusinessId and owned by its merchant when it has one, else by it; it expires the settings\' validityMonths after its email goes. Its email goes to recipient.email at sendAt (or at once); for a gift, the buyer gets a receipt without the code at once. Idempotent per orderCode and orderLineId: a repeat, also two at once, answers the card the line made, whatever the settings are now. Retry on no answer or 5xx; a 4xx is final: refund the order, after online-sale/refund when the 409 says a card exists.
|
|
54795
|
+
* @summary Make the gift card an online order line paid for
|
|
54796
|
+
* @param {SellGiftCardOnlineDto} sellGiftCardOnlineDto
|
|
54797
|
+
* @param {*} [options] Override http request option.
|
|
54798
|
+
* @throws {RequiredError}
|
|
54799
|
+
* @memberof InternalGiftCardsApi
|
|
54800
|
+
*/
|
|
54801
|
+
public sellGiftCardOnline(sellGiftCardOnlineDto: SellGiftCardOnlineDto, options?: AxiosRequestConfig) {
|
|
54802
|
+
return InternalGiftCardsApiFp(this.configuration).sellGiftCardOnline(sellGiftCardOnlineDto, options).then((request) => request(this.axios, this.basePath));
|
|
54803
|
+
}
|
|
54804
|
+
}
|
|
54805
|
+
|
|
54806
|
+
|
|
53914
54807
|
/**
|
|
53915
54808
|
* InvoiceCompaniesApi - axios parameter creator
|
|
53916
54809
|
* @export
|