@munchi_oy/core 1.9.97 → 1.9.98

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.
@@ -6813,6 +6813,12 @@ export interface InitiateVivaA2aSessionDto {
6813
6813
  * @memberof InitiateVivaA2aSessionDto
6814
6814
  */
6815
6815
  'splitContext'?: CreateManualSessionDtoSplitContext;
6816
+ /**
6817
+ * Pay-terminal chargeId (from the pay-terminal-protocol relay) for this attempt. Stamped onto the session\'s metadata so the charge-status fallback can address this exact attempt directly, even when other charges are concurrently in flight on the same order (e.g. a split payment dispatched to a different paired terminal).
6818
+ * @type {string}
6819
+ * @memberof InitiateVivaA2aSessionDto
6820
+ */
6821
+ 'chargeId'?: string;
6816
6822
  }
6817
6823
  /**
6818
6824
  *
@@ -19296,31 +19302,6 @@ export interface RefundedItemDto {
19296
19302
  */
19297
19303
  'amount': number;
19298
19304
  }
19299
- /**
19300
- *
19301
- * @export
19302
- * @interface RegisterChargeMappingDto
19303
- */
19304
- export interface RegisterChargeMappingDto {
19305
- /**
19306
- * POS-generated id for this charge attempt (from the pay-terminal Ably relay).
19307
- * @type {string}
19308
- * @memberof RegisterChargeMappingDto
19309
- */
19310
- 'chargeId': string;
19311
- /**
19312
- * The order this charge belongs to (matches the Viva session\'s referenceId).
19313
- * @type {string}
19314
- * @memberof RegisterChargeMappingDto
19315
- */
19316
- 'orderId': string;
19317
- /**
19318
- * The business the order belongs to.
19319
- * @type {number}
19320
- * @memberof RegisterChargeMappingDto
19321
- */
19322
- 'businessId': number;
19323
- }
19324
19305
  /**
19325
19306
  *
19326
19307
  * @export
@@ -35467,21 +35448,13 @@ export declare const PaymentSessionApiAxiosParamCreator: (configuration?: Config
35467
35448
  */
35468
35449
  initiateWorldlineSession: (initiateWorldlineSessionDto: InitiateWorldlineSessionDto, xIdempotencyKey?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
35469
35450
  /**
35470
- * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity.
35451
+ * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity. chargeId is stamped onto the session\'s own metadata at /viva/a2a initiate time, so this addresses one specific charge attempt even when other charges are concurrently in flight on the same order (e.g. a split payment across multiple paired terminals).
35471
35452
  * @summary Poll a charge\'s outcome by chargeId.
35472
35453
  * @param {string} chargeId
35473
35454
  * @param {*} [options] Override http request option.
35474
35455
  * @throws {RequiredError}
35475
35456
  */
35476
35457
  paymentSessionGetChargeStatus: (chargeId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
35477
- /**
35478
- * Called by the paying device (e.g. a paired Munchi Pay terminal) right as it starts a charge relayed from the POS over Ably, so the POS can fall back to polling if the Ably charge_result message never arrives.
35479
- * @summary Register a POS-generated chargeId against an order so its outcome can be polled.
35480
- * @param {RegisterChargeMappingDto} registerChargeMappingDto
35481
- * @param {*} [options] Override http request option.
35482
- * @throws {RequiredError}
35483
- */
35484
- paymentSessionRegisterChargeMapping: (registerChargeMappingDto: RegisterChargeMappingDto, options?: AxiosRequestConfig) => Promise<RequestArgs>;
35485
35458
  /**
35486
35459
  * Called by a Cloud Task (not the client). Holds the request open and long-polls Viva by sessionId for up to ~45s. As soon as the transaction is terminal it updates the session status and, on success, triggers order reconciliation — guarded by a CAS claim (tryClose) so a late webhook never double-writes the paymentEvent — so the order closes even if the webhook never arrives.
35487
35460
  * @summary Internal: long-poll Viva for a stuck payment session (Cloud Task callback)
@@ -35630,21 +35603,13 @@ export declare const PaymentSessionApiFp: (configuration?: Configuration) => {
35630
35603
  */
35631
35604
  initiateWorldlineSession(initiateWorldlineSessionDto: InitiateWorldlineSessionDto, xIdempotencyKey?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InitiateWorldlineSessionResponseDto>>;
35632
35605
  /**
35633
- * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity.
35606
+ * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity. chargeId is stamped onto the session\'s own metadata at /viva/a2a initiate time, so this addresses one specific charge attempt even when other charges are concurrently in flight on the same order (e.g. a split payment across multiple paired terminals).
35634
35607
  * @summary Poll a charge\'s outcome by chargeId.
35635
35608
  * @param {string} chargeId
35636
35609
  * @param {*} [options] Override http request option.
35637
35610
  * @throws {RequiredError}
35638
35611
  */
35639
35612
  paymentSessionGetChargeStatus(chargeId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChargeStatusResponseDto>>;
35640
- /**
35641
- * Called by the paying device (e.g. a paired Munchi Pay terminal) right as it starts a charge relayed from the POS over Ably, so the POS can fall back to polling if the Ably charge_result message never arrives.
35642
- * @summary Register a POS-generated chargeId against an order so its outcome can be polled.
35643
- * @param {RegisterChargeMappingDto} registerChargeMappingDto
35644
- * @param {*} [options] Override http request option.
35645
- * @throws {RequiredError}
35646
- */
35647
- paymentSessionRegisterChargeMapping(registerChargeMappingDto: RegisterChargeMappingDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
35648
35613
  /**
35649
35614
  * Called by a Cloud Task (not the client). Holds the request open and long-polls Viva by sessionId for up to ~45s. As soon as the transaction is terminal it updates the session status and, on success, triggers order reconciliation — guarded by a CAS claim (tryClose) so a late webhook never double-writes the paymentEvent — so the order closes even if the webhook never arrives.
35650
35615
  * @summary Internal: long-poll Viva for a stuck payment session (Cloud Task callback)
@@ -35793,21 +35758,13 @@ export declare const PaymentSessionApiFactory: (configuration?: Configuration, b
35793
35758
  */
35794
35759
  initiateWorldlineSession(initiateWorldlineSessionDto: InitiateWorldlineSessionDto, xIdempotencyKey?: string, options?: any): AxiosPromise<InitiateWorldlineSessionResponseDto>;
35795
35760
  /**
35796
- * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity.
35761
+ * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity. chargeId is stamped onto the session\'s own metadata at /viva/a2a initiate time, so this addresses one specific charge attempt even when other charges are concurrently in flight on the same order (e.g. a split payment across multiple paired terminals).
35797
35762
  * @summary Poll a charge\'s outcome by chargeId.
35798
35763
  * @param {string} chargeId
35799
35764
  * @param {*} [options] Override http request option.
35800
35765
  * @throws {RequiredError}
35801
35766
  */
35802
35767
  paymentSessionGetChargeStatus(chargeId: string, options?: any): AxiosPromise<ChargeStatusResponseDto>;
35803
- /**
35804
- * Called by the paying device (e.g. a paired Munchi Pay terminal) right as it starts a charge relayed from the POS over Ably, so the POS can fall back to polling if the Ably charge_result message never arrives.
35805
- * @summary Register a POS-generated chargeId against an order so its outcome can be polled.
35806
- * @param {RegisterChargeMappingDto} registerChargeMappingDto
35807
- * @param {*} [options] Override http request option.
35808
- * @throws {RequiredError}
35809
- */
35810
- paymentSessionRegisterChargeMapping(registerChargeMappingDto: RegisterChargeMappingDto, options?: any): AxiosPromise<void>;
35811
35768
  /**
35812
35769
  * Called by a Cloud Task (not the client). Holds the request open and long-polls Viva by sessionId for up to ~45s. As soon as the transaction is terminal it updates the session status and, on success, triggers order reconciliation — guarded by a CAS claim (tryClose) so a late webhook never double-writes the paymentEvent — so the order closes even if the webhook never arrives.
35813
35770
  * @summary Internal: long-poll Viva for a stuck payment session (Cloud Task callback)
@@ -35964,7 +35921,7 @@ export interface PaymentSessionApiInterface {
35964
35921
  */
35965
35922
  initiateWorldlineSession(initiateWorldlineSessionDto: InitiateWorldlineSessionDto, xIdempotencyKey?: string, options?: AxiosRequestConfig): AxiosPromise<InitiateWorldlineSessionResponseDto>;
35966
35923
  /**
35967
- * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity.
35924
+ * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity. chargeId is stamped onto the session\'s own metadata at /viva/a2a initiate time, so this addresses one specific charge attempt even when other charges are concurrently in flight on the same order (e.g. a split payment across multiple paired terminals).
35968
35925
  * @summary Poll a charge\'s outcome by chargeId.
35969
35926
  * @param {string} chargeId
35970
35927
  * @param {*} [options] Override http request option.
@@ -35972,15 +35929,6 @@ export interface PaymentSessionApiInterface {
35972
35929
  * @memberof PaymentSessionApiInterface
35973
35930
  */
35974
35931
  paymentSessionGetChargeStatus(chargeId: string, options?: AxiosRequestConfig): AxiosPromise<ChargeStatusResponseDto>;
35975
- /**
35976
- * Called by the paying device (e.g. a paired Munchi Pay terminal) right as it starts a charge relayed from the POS over Ably, so the POS can fall back to polling if the Ably charge_result message never arrives.
35977
- * @summary Register a POS-generated chargeId against an order so its outcome can be polled.
35978
- * @param {RegisterChargeMappingDto} registerChargeMappingDto
35979
- * @param {*} [options] Override http request option.
35980
- * @throws {RequiredError}
35981
- * @memberof PaymentSessionApiInterface
35982
- */
35983
- paymentSessionRegisterChargeMapping(registerChargeMappingDto: RegisterChargeMappingDto, options?: AxiosRequestConfig): AxiosPromise<void>;
35984
35932
  /**
35985
35933
  * Called by a Cloud Task (not the client). Holds the request open and long-polls Viva by sessionId for up to ~45s. As soon as the transaction is terminal it updates the session status and, on success, triggers order reconciliation — guarded by a CAS claim (tryClose) so a late webhook never double-writes the paymentEvent — so the order closes even if the webhook never arrives.
35986
35934
  * @summary Internal: long-poll Viva for a stuck payment session (Cloud Task callback)
@@ -36148,7 +36096,7 @@ export declare class PaymentSessionApi extends BaseAPI implements PaymentSession
36148
36096
  */
36149
36097
  initiateWorldlineSession(initiateWorldlineSessionDto: InitiateWorldlineSessionDto, xIdempotencyKey?: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<InitiateWorldlineSessionResponseDto, any, {}>>;
36150
36098
  /**
36151
- * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity.
36099
+ * Fallback for when the pay-terminal Ably charge_result message is lost to a flaky connection. Returns \'pending\' until the backend observes the underlying PaymentSession reach a terminal state, regardless of either device\'s connectivity. chargeId is stamped onto the session\'s own metadata at /viva/a2a initiate time, so this addresses one specific charge attempt even when other charges are concurrently in flight on the same order (e.g. a split payment across multiple paired terminals).
36152
36100
  * @summary Poll a charge\'s outcome by chargeId.
36153
36101
  * @param {string} chargeId
36154
36102
  * @param {*} [options] Override http request option.
@@ -36156,15 +36104,6 @@ export declare class PaymentSessionApi extends BaseAPI implements PaymentSession
36156
36104
  * @memberof PaymentSessionApi
36157
36105
  */
36158
36106
  paymentSessionGetChargeStatus(chargeId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ChargeStatusResponseDto, any, {}>>;
36159
- /**
36160
- * Called by the paying device (e.g. a paired Munchi Pay terminal) right as it starts a charge relayed from the POS over Ably, so the POS can fall back to polling if the Ably charge_result message never arrives.
36161
- * @summary Register a POS-generated chargeId against an order so its outcome can be polled.
36162
- * @param {RegisterChargeMappingDto} registerChargeMappingDto
36163
- * @param {*} [options] Override http request option.
36164
- * @throws {RequiredError}
36165
- * @memberof PaymentSessionApi
36166
- */
36167
- paymentSessionRegisterChargeMapping(registerChargeMappingDto: RegisterChargeMappingDto, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
36168
36107
  /**
36169
36108
  * Called by a Cloud Task (not the client). Holds the request open and long-polls Viva by sessionId for up to ~45s. As soon as the transaction is terminal it updates the session status and, on success, triggers order reconciliation — guarded by a CAS claim (tryClose) so a late webhook never double-writes the paymentEvent — so the order closes even if the webhook never arrives.
36170
36109
  * @summary Internal: long-poll Viva for a stuck payment session (Cloud Task callback)