@paystack/checkout-js 1.25.0 → 1.26.0-dev.10

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/es/checkout.js CHANGED
@@ -11568,6 +11568,38 @@ var PayWithTransferAPI = {
11568
11568
  }).then(function (response) {
11569
11569
  return ChargeResponses.parse(response.data);
11570
11570
  });
11571
+ },
11572
+ incorrectAmountDecision: function incorrectAmountDecision(params, publicKey) {
11573
+ var language = getLanguage();
11574
+
11575
+ var headers = _objectSpread2({
11576
+ Authorization: "Bearer ".concat(publicKey)
11577
+ }, language && {
11578
+ 'Accept-Language': language
11579
+ });
11580
+
11581
+ var url = new URL('pay-with-transfer/incorrect-amount/decision', configToUse.paystackApiUrl).toString();
11582
+ return axiosInstance.post(url, params, {
11583
+ headers: headers
11584
+ }).then(function (response) {
11585
+ return ChargeResponses.parse(response.data);
11586
+ });
11587
+ },
11588
+ authenticatePayer: function authenticatePayer(params, publicKey) {
11589
+ var language = getLanguage();
11590
+
11591
+ var headers = _objectSpread2({
11592
+ Authorization: "Bearer ".concat(publicKey)
11593
+ }, language && {
11594
+ 'Accept-Language': language
11595
+ });
11596
+
11597
+ var url = new URL('pay-with-transfer/authenticate-payer', configToUse.paystackApiUrl).toString();
11598
+ return axiosInstance.post(url, params, {
11599
+ headers: headers
11600
+ }).then(function (response) {
11601
+ return ChargeResponses.parse(response.data);
11602
+ });
11571
11603
  }
11572
11604
  };
11573
11605
 
@@ -11598,6 +11630,25 @@ var PayWithTransferCharge = {
11598
11630
  paymentMethod: 'bank_transfer'
11599
11631
  };
11600
11632
  return this.listenForCharge(listenerOptions, callback);
11633
+ },
11634
+ sendIncorrectAmountDecision: function sendIncorrectAmountDecision(decisionMade) {
11635
+ var params = {
11636
+ transaction_id: this.id,
11637
+ decision: decisionMade
11638
+ };
11639
+ return PayWithTransferAPI.incorrectAmountDecision(params, this.merchant.key);
11640
+ },
11641
+ sendAuthenticatePayer: function sendAuthenticatePayer(_ref2) {
11642
+ var amountPaid = _ref2.amountPaid,
11643
+ payerAccountNumber = _ref2.payerAccountNumber,
11644
+ payerBankSlug = _ref2.payerBankSlug;
11645
+ var params = {
11646
+ transaction_id: this.id,
11647
+ amount: amountPaid,
11648
+ payer_account_number: payerAccountNumber,
11649
+ payer_bank_slug: payerBankSlug
11650
+ };
11651
+ return PayWithTransferAPI.authenticatePayer(params, this.merchant.key);
11601
11652
  }
11602
11653
  };
11603
11654
 
@@ -19148,14 +19199,16 @@ var CardCharge = {
19148
19199
  });
19149
19200
  },
19150
19201
  chargeSavedCard: function chargeSavedCard(_ref5) {
19151
- var cardCode = _ref5.cardCode;
19202
+ var cardCode = _ref5.cardCode,
19203
+ _ref5$selectedCurrenc = _ref5.selectedCurrency,
19204
+ selectedCurrency = _ref5$selectedCurrenc === void 0 ? this.currency : _ref5$selectedCurrenc;
19152
19205
  this.logAttempt(savedCardMethods.payment);
19153
19206
  return CardAPI$1.chargeSavedCard({
19154
19207
  cardCode: cardCode,
19155
19208
  transaction: this.id,
19156
19209
  token: this.savedCardsToken,
19157
19210
  device: this.deviceFingerprint,
19158
- selectedCurrency: this.currency
19211
+ selectedCurrency: selectedCurrency
19159
19212
  });
19160
19213
  }
19161
19214
  };
@@ -19418,7 +19471,8 @@ var DigitalBankMandateAPI = {
19418
19471
  var bankId = _ref.bankId,
19419
19472
  transactionId = _ref.transactionId,
19420
19473
  phoneNumber = _ref.phoneNumber,
19421
- payId = _ref.payId;
19474
+ payId = _ref.payId,
19475
+ walletId = _ref.walletId;
19422
19476
  var url = "".concat(configToUse.paymentBaseUrl, "bank/digitalbankmandate/").concat(bankId, "/").concat(transactionId);
19423
19477
  var language = getLanguage();
19424
19478
 
@@ -19428,10 +19482,13 @@ var DigitalBankMandateAPI = {
19428
19482
  'Accept-Language': language
19429
19483
  });
19430
19484
 
19431
- var params = {
19485
+ var params = _objectSpread2({}, walletId ? {
19486
+ wallet_id: walletId
19487
+ } : {
19432
19488
  phone_number: phoneNumber,
19433
19489
  token: payId
19434
- };
19490
+ });
19491
+
19435
19492
  var urlEncodedParams = formUrlencoded(params);
19436
19493
  return axiosInstance.post(url, urlEncodedParams, {
19437
19494
  headers: headers
@@ -19448,12 +19505,14 @@ var DigitalBankMandate = {
19448
19505
 
19449
19506
  var phoneNumber = _ref.phoneNumber,
19450
19507
  payId = _ref.payId,
19451
- bankId = _ref.bankId;
19508
+ bankId = _ref.bankId,
19509
+ walletId = _ref.walletId;
19452
19510
  var params = {
19453
19511
  transactionId: this.id,
19454
19512
  phoneNumber: phoneNumber,
19455
19513
  payId: payId,
19456
- bankId: bankId
19514
+ bankId: bankId,
19515
+ walletId: walletId
19457
19516
  };
19458
19517
  return DigitalBankMandateAPI.charge(params).then(function (response) {
19459
19518
  _this.logAPIResponse(response, paymentMethod$2);
@@ -19771,67 +19830,90 @@ function validate$1(phoneNumber) {
19771
19830
  });
19772
19831
  }
19773
19832
 
19833
+ var mobileMoney = {};
19834
+
19835
+ function mobileMoneyChargeAPI(params) {
19836
+ var _this = this;
19837
+
19838
+ return MobileMoneyAPI.charge(params).then(function (response) {
19839
+ if (response.status === 'success') {
19840
+ mobileMoney = response;
19841
+
19842
+ if (response.data && response.data.display && response.data.display.otpSentCount === 1) {
19843
+ _this.logTokenRequest('mobile money');
19844
+ }
19845
+ }
19846
+
19847
+ return response;
19848
+ });
19849
+ }
19850
+
19774
19851
  var MobileMoneyCharge = {
19775
19852
  chargeMobileMoney: function chargeMobileMoney(_ref) {
19776
- var _this = this;
19853
+ var _this2 = this;
19777
19854
 
19778
19855
  var phoneNumber = _ref.phoneNumber,
19779
19856
  provider = _ref.provider,
19780
19857
  voucher = _ref.voucher,
19781
19858
  registrationToken = _ref.registrationToken;
19782
19859
  return validate$1(phoneNumber).then(function () {
19783
- _this.logAttempt('mobile money');
19860
+ _this2.logAttempt('mobile money');
19784
19861
 
19785
19862
  var params = {
19786
19863
  provider: provider,
19787
19864
  voucher: voucher,
19788
19865
  registrationToken: registrationToken,
19789
- transaction: _this.id,
19866
+ transaction: _this2.id,
19790
19867
  phone: phoneNumber,
19791
- device: _this.deviceFingerprint,
19792
- channel_name: "MOBILE_MONEY_".concat(_this.id)
19868
+ device: _this2.deviceFingerprint,
19869
+ channel_name: "MOBILE_MONEY_".concat(_this2.id)
19793
19870
  };
19794
- return MobileMoneyAPI.charge(params).then(function (response) {
19795
- if (response.status === 'success') {
19796
- _this.mobileMoney = response;
19797
-
19798
- if (response.data && response.data.display && response.data.display.otpSentCount === 1) {
19799
- _this.logTokenRequest('mobile money');
19800
- }
19801
- }
19802
-
19803
- return response;
19804
- });
19871
+ return mobileMoneyChargeAPI(params);
19805
19872
  });
19806
19873
  },
19874
+ chargeMpesaOffline: function chargeMpesaOffline(_ref2) {
19875
+ var provider = _ref2.provider,
19876
+ voucher = _ref2.voucher,
19877
+ registrationToken = _ref2.registrationToken;
19878
+ this.logAttempt('mobile money');
19879
+ var params = {
19880
+ provider: provider,
19881
+ voucher: voucher,
19882
+ registrationToken: registrationToken,
19883
+ transaction: this.id,
19884
+ device: this.deviceFingerprint,
19885
+ channel_name: "MOBILE_MONEY_".concat(this.id)
19886
+ };
19887
+ return mobileMoneyChargeAPI(params);
19888
+ },
19807
19889
  authenticateMobileMoney: function authenticateMobileMoney(payload) {
19808
- var _this2 = this;
19890
+ var _this3 = this;
19809
19891
 
19810
19892
  var phoneNumber = payload.phoneNumber,
19811
19893
  provider = payload.provider,
19812
19894
  registrationToken = payload.registrationToken;
19813
19895
  return validate$1(phoneNumber).then(function () {
19814
- _this2.logMobileMoneyActions(payload);
19896
+ _this3.logMobileMoneyActions(payload);
19815
19897
 
19816
19898
  var params = {
19817
19899
  provider: provider,
19818
19900
  registrationToken: registrationToken,
19819
- transaction: _this2.id,
19901
+ transaction: _this3.id,
19820
19902
  phone: phoneNumber,
19821
- device: _this2.deviceFingerprint,
19822
- channel_name: "MOBILE_MONEY_".concat(_this2.id)
19903
+ device: _this3.deviceFingerprint,
19904
+ channel_name: "MOBILE_MONEY_".concat(_this3.id)
19823
19905
  };
19824
19906
  return MobileMoneyAPI.charge(params).then(function (response) {
19825
19907
  if (response.status === 'success') {
19826
- _this2.mobileMoney = response;
19908
+ mobileMoney = response;
19827
19909
 
19828
19910
  if (response.data && response.data.display && response.data.display.otpSentCount === 1) {
19829
- _this2.logTokenRequest('mobile money');
19911
+ _this3.logTokenRequest('mobile money');
19830
19912
  }
19831
19913
  } else if (response.errors && response.errors.data && response.errors.data.status === 'awaiting_registration_token') {
19832
- _this2.logTokenAuthenticationFailure(response.message);
19914
+ _this3.logTokenAuthenticationFailure(response.message);
19833
19915
  } else {
19834
- _this2.logError(response.message);
19916
+ _this3.logError(response.message);
19835
19917
  }
19836
19918
 
19837
19919
  return response;
@@ -19839,19 +19921,19 @@ var MobileMoneyCharge = {
19839
19921
  });
19840
19922
  },
19841
19923
  submitMobileMoneyCode: function submitMobileMoneyCode(payload) {
19842
- var _this3 = this;
19924
+ var _this4 = this;
19843
19925
 
19844
19926
  return MobileMoneyAPI.submitCode({
19845
19927
  code: payload.code,
19846
19928
  transaction: this.id
19847
19929
  }).then(function (response) {
19848
- _this3.logAPIResponse(response, 'mobile_money');
19930
+ _this4.logAPIResponse(response, 'mobile_money');
19849
19931
 
19850
19932
  return response;
19851
19933
  });
19852
19934
  },
19853
19935
  listenForMobileMoneyCharge: function listenForMobileMoneyCharge(callback) {
19854
- if (this.mobileMoney.status !== 'success') {
19936
+ if (mobileMoney.status !== 'success') {
19855
19937
  return Promise.reject(Error('Please start a mobile money charge with Transaction.chargeMobileMoney()'));
19856
19938
  }
19857
19939
 
@@ -20831,6 +20913,21 @@ var ToolkitAPI = {
20831
20913
  resolvedCardBins[bin] = data;
20832
20914
  return data;
20833
20915
  });
20916
+ },
20917
+ resolveIPAddress: function resolveIPAddress(ipAddress) {
20918
+ var url = new URL("decision/resolve_ip/".concat(ipAddress), configToUse.paystackApiUrl).toString();
20919
+ var language = getLanguage();
20920
+
20921
+ var headers = _objectSpread2({}, language && {
20922
+ 'Accept-Language': language
20923
+ });
20924
+
20925
+ return axiosInstance.get(url, {
20926
+ headers: headers
20927
+ }).then(function (_ref2) {
20928
+ var data = _ref2.data;
20929
+ return data;
20930
+ });
20834
20931
  }
20835
20932
  };
20836
20933
 
@@ -20896,6 +20993,11 @@ var Toolkit = /*#__PURE__*/function () {
20896
20993
  value: function resolveCardBin(bin) {
20897
20994
  return ToolkitAPI.resolveCardBin(bin);
20898
20995
  }
20996
+ }, {
20997
+ key: "resolveIPAddress",
20998
+ value: function resolveIPAddress(ipAddress) {
20999
+ return ToolkitAPI.resolveIPAddress(ipAddress);
21000
+ }
20899
21001
  }]);
20900
21002
 
20901
21003
  return Toolkit;
package/lib/checkout.js CHANGED
@@ -11572,6 +11572,38 @@ var PayWithTransferAPI = {
11572
11572
  }).then(function (response) {
11573
11573
  return ChargeResponses.parse(response.data);
11574
11574
  });
11575
+ },
11576
+ incorrectAmountDecision: function incorrectAmountDecision(params, publicKey) {
11577
+ var language = getLanguage();
11578
+
11579
+ var headers = _objectSpread2({
11580
+ Authorization: "Bearer ".concat(publicKey)
11581
+ }, language && {
11582
+ 'Accept-Language': language
11583
+ });
11584
+
11585
+ var url = new URL('pay-with-transfer/incorrect-amount/decision', configToUse.paystackApiUrl).toString();
11586
+ return axiosInstance.post(url, params, {
11587
+ headers: headers
11588
+ }).then(function (response) {
11589
+ return ChargeResponses.parse(response.data);
11590
+ });
11591
+ },
11592
+ authenticatePayer: function authenticatePayer(params, publicKey) {
11593
+ var language = getLanguage();
11594
+
11595
+ var headers = _objectSpread2({
11596
+ Authorization: "Bearer ".concat(publicKey)
11597
+ }, language && {
11598
+ 'Accept-Language': language
11599
+ });
11600
+
11601
+ var url = new URL('pay-with-transfer/authenticate-payer', configToUse.paystackApiUrl).toString();
11602
+ return axiosInstance.post(url, params, {
11603
+ headers: headers
11604
+ }).then(function (response) {
11605
+ return ChargeResponses.parse(response.data);
11606
+ });
11575
11607
  }
11576
11608
  };
11577
11609
 
@@ -11602,6 +11634,25 @@ var PayWithTransferCharge = {
11602
11634
  paymentMethod: 'bank_transfer'
11603
11635
  };
11604
11636
  return this.listenForCharge(listenerOptions, callback);
11637
+ },
11638
+ sendIncorrectAmountDecision: function sendIncorrectAmountDecision(decisionMade) {
11639
+ var params = {
11640
+ transaction_id: this.id,
11641
+ decision: decisionMade
11642
+ };
11643
+ return PayWithTransferAPI.incorrectAmountDecision(params, this.merchant.key);
11644
+ },
11645
+ sendAuthenticatePayer: function sendAuthenticatePayer(_ref2) {
11646
+ var amountPaid = _ref2.amountPaid,
11647
+ payerAccountNumber = _ref2.payerAccountNumber,
11648
+ payerBankSlug = _ref2.payerBankSlug;
11649
+ var params = {
11650
+ transaction_id: this.id,
11651
+ amount: amountPaid,
11652
+ payer_account_number: payerAccountNumber,
11653
+ payer_bank_slug: payerBankSlug
11654
+ };
11655
+ return PayWithTransferAPI.authenticatePayer(params, this.merchant.key);
11605
11656
  }
11606
11657
  };
11607
11658
 
@@ -19152,14 +19203,16 @@ var CardCharge = {
19152
19203
  });
19153
19204
  },
19154
19205
  chargeSavedCard: function chargeSavedCard(_ref5) {
19155
- var cardCode = _ref5.cardCode;
19206
+ var cardCode = _ref5.cardCode,
19207
+ _ref5$selectedCurrenc = _ref5.selectedCurrency,
19208
+ selectedCurrency = _ref5$selectedCurrenc === void 0 ? this.currency : _ref5$selectedCurrenc;
19156
19209
  this.logAttempt(savedCardMethods.payment);
19157
19210
  return CardAPI$1.chargeSavedCard({
19158
19211
  cardCode: cardCode,
19159
19212
  transaction: this.id,
19160
19213
  token: this.savedCardsToken,
19161
19214
  device: this.deviceFingerprint,
19162
- selectedCurrency: this.currency
19215
+ selectedCurrency: selectedCurrency
19163
19216
  });
19164
19217
  }
19165
19218
  };
@@ -19422,7 +19475,8 @@ var DigitalBankMandateAPI = {
19422
19475
  var bankId = _ref.bankId,
19423
19476
  transactionId = _ref.transactionId,
19424
19477
  phoneNumber = _ref.phoneNumber,
19425
- payId = _ref.payId;
19478
+ payId = _ref.payId,
19479
+ walletId = _ref.walletId;
19426
19480
  var url = "".concat(configToUse.paymentBaseUrl, "bank/digitalbankmandate/").concat(bankId, "/").concat(transactionId);
19427
19481
  var language = getLanguage();
19428
19482
 
@@ -19432,10 +19486,13 @@ var DigitalBankMandateAPI = {
19432
19486
  'Accept-Language': language
19433
19487
  });
19434
19488
 
19435
- var params = {
19489
+ var params = _objectSpread2({}, walletId ? {
19490
+ wallet_id: walletId
19491
+ } : {
19436
19492
  phone_number: phoneNumber,
19437
19493
  token: payId
19438
- };
19494
+ });
19495
+
19439
19496
  var urlEncodedParams = formUrlencoded(params);
19440
19497
  return axiosInstance.post(url, urlEncodedParams, {
19441
19498
  headers: headers
@@ -19452,12 +19509,14 @@ var DigitalBankMandate = {
19452
19509
 
19453
19510
  var phoneNumber = _ref.phoneNumber,
19454
19511
  payId = _ref.payId,
19455
- bankId = _ref.bankId;
19512
+ bankId = _ref.bankId,
19513
+ walletId = _ref.walletId;
19456
19514
  var params = {
19457
19515
  transactionId: this.id,
19458
19516
  phoneNumber: phoneNumber,
19459
19517
  payId: payId,
19460
- bankId: bankId
19518
+ bankId: bankId,
19519
+ walletId: walletId
19461
19520
  };
19462
19521
  return DigitalBankMandateAPI.charge(params).then(function (response) {
19463
19522
  _this.logAPIResponse(response, paymentMethod$2);
@@ -19775,67 +19834,90 @@ function validate$1(phoneNumber) {
19775
19834
  });
19776
19835
  }
19777
19836
 
19837
+ var mobileMoney = {};
19838
+
19839
+ function mobileMoneyChargeAPI(params) {
19840
+ var _this = this;
19841
+
19842
+ return MobileMoneyAPI.charge(params).then(function (response) {
19843
+ if (response.status === 'success') {
19844
+ mobileMoney = response;
19845
+
19846
+ if (response.data && response.data.display && response.data.display.otpSentCount === 1) {
19847
+ _this.logTokenRequest('mobile money');
19848
+ }
19849
+ }
19850
+
19851
+ return response;
19852
+ });
19853
+ }
19854
+
19778
19855
  var MobileMoneyCharge = {
19779
19856
  chargeMobileMoney: function chargeMobileMoney(_ref) {
19780
- var _this = this;
19857
+ var _this2 = this;
19781
19858
 
19782
19859
  var phoneNumber = _ref.phoneNumber,
19783
19860
  provider = _ref.provider,
19784
19861
  voucher = _ref.voucher,
19785
19862
  registrationToken = _ref.registrationToken;
19786
19863
  return validate$1(phoneNumber).then(function () {
19787
- _this.logAttempt('mobile money');
19864
+ _this2.logAttempt('mobile money');
19788
19865
 
19789
19866
  var params = {
19790
19867
  provider: provider,
19791
19868
  voucher: voucher,
19792
19869
  registrationToken: registrationToken,
19793
- transaction: _this.id,
19870
+ transaction: _this2.id,
19794
19871
  phone: phoneNumber,
19795
- device: _this.deviceFingerprint,
19796
- channel_name: "MOBILE_MONEY_".concat(_this.id)
19872
+ device: _this2.deviceFingerprint,
19873
+ channel_name: "MOBILE_MONEY_".concat(_this2.id)
19797
19874
  };
19798
- return MobileMoneyAPI.charge(params).then(function (response) {
19799
- if (response.status === 'success') {
19800
- _this.mobileMoney = response;
19801
-
19802
- if (response.data && response.data.display && response.data.display.otpSentCount === 1) {
19803
- _this.logTokenRequest('mobile money');
19804
- }
19805
- }
19806
-
19807
- return response;
19808
- });
19875
+ return mobileMoneyChargeAPI(params);
19809
19876
  });
19810
19877
  },
19878
+ chargeMpesaOffline: function chargeMpesaOffline(_ref2) {
19879
+ var provider = _ref2.provider,
19880
+ voucher = _ref2.voucher,
19881
+ registrationToken = _ref2.registrationToken;
19882
+ this.logAttempt('mobile money');
19883
+ var params = {
19884
+ provider: provider,
19885
+ voucher: voucher,
19886
+ registrationToken: registrationToken,
19887
+ transaction: this.id,
19888
+ device: this.deviceFingerprint,
19889
+ channel_name: "MOBILE_MONEY_".concat(this.id)
19890
+ };
19891
+ return mobileMoneyChargeAPI(params);
19892
+ },
19811
19893
  authenticateMobileMoney: function authenticateMobileMoney(payload) {
19812
- var _this2 = this;
19894
+ var _this3 = this;
19813
19895
 
19814
19896
  var phoneNumber = payload.phoneNumber,
19815
19897
  provider = payload.provider,
19816
19898
  registrationToken = payload.registrationToken;
19817
19899
  return validate$1(phoneNumber).then(function () {
19818
- _this2.logMobileMoneyActions(payload);
19900
+ _this3.logMobileMoneyActions(payload);
19819
19901
 
19820
19902
  var params = {
19821
19903
  provider: provider,
19822
19904
  registrationToken: registrationToken,
19823
- transaction: _this2.id,
19905
+ transaction: _this3.id,
19824
19906
  phone: phoneNumber,
19825
- device: _this2.deviceFingerprint,
19826
- channel_name: "MOBILE_MONEY_".concat(_this2.id)
19907
+ device: _this3.deviceFingerprint,
19908
+ channel_name: "MOBILE_MONEY_".concat(_this3.id)
19827
19909
  };
19828
19910
  return MobileMoneyAPI.charge(params).then(function (response) {
19829
19911
  if (response.status === 'success') {
19830
- _this2.mobileMoney = response;
19912
+ mobileMoney = response;
19831
19913
 
19832
19914
  if (response.data && response.data.display && response.data.display.otpSentCount === 1) {
19833
- _this2.logTokenRequest('mobile money');
19915
+ _this3.logTokenRequest('mobile money');
19834
19916
  }
19835
19917
  } else if (response.errors && response.errors.data && response.errors.data.status === 'awaiting_registration_token') {
19836
- _this2.logTokenAuthenticationFailure(response.message);
19918
+ _this3.logTokenAuthenticationFailure(response.message);
19837
19919
  } else {
19838
- _this2.logError(response.message);
19920
+ _this3.logError(response.message);
19839
19921
  }
19840
19922
 
19841
19923
  return response;
@@ -19843,19 +19925,19 @@ var MobileMoneyCharge = {
19843
19925
  });
19844
19926
  },
19845
19927
  submitMobileMoneyCode: function submitMobileMoneyCode(payload) {
19846
- var _this3 = this;
19928
+ var _this4 = this;
19847
19929
 
19848
19930
  return MobileMoneyAPI.submitCode({
19849
19931
  code: payload.code,
19850
19932
  transaction: this.id
19851
19933
  }).then(function (response) {
19852
- _this3.logAPIResponse(response, 'mobile_money');
19934
+ _this4.logAPIResponse(response, 'mobile_money');
19853
19935
 
19854
19936
  return response;
19855
19937
  });
19856
19938
  },
19857
19939
  listenForMobileMoneyCharge: function listenForMobileMoneyCharge(callback) {
19858
- if (this.mobileMoney.status !== 'success') {
19940
+ if (mobileMoney.status !== 'success') {
19859
19941
  return Promise.reject(Error('Please start a mobile money charge with Transaction.chargeMobileMoney()'));
19860
19942
  }
19861
19943
 
@@ -20835,6 +20917,21 @@ var ToolkitAPI = {
20835
20917
  resolvedCardBins[bin] = data;
20836
20918
  return data;
20837
20919
  });
20920
+ },
20921
+ resolveIPAddress: function resolveIPAddress(ipAddress) {
20922
+ var url = new URL("decision/resolve_ip/".concat(ipAddress), configToUse.paystackApiUrl).toString();
20923
+ var language = getLanguage();
20924
+
20925
+ var headers = _objectSpread2({}, language && {
20926
+ 'Accept-Language': language
20927
+ });
20928
+
20929
+ return axiosInstance.get(url, {
20930
+ headers: headers
20931
+ }).then(function (_ref2) {
20932
+ var data = _ref2.data;
20933
+ return data;
20934
+ });
20838
20935
  }
20839
20936
  };
20840
20937
 
@@ -20900,6 +20997,11 @@ var Toolkit = /*#__PURE__*/function () {
20900
20997
  value: function resolveCardBin(bin) {
20901
20998
  return ToolkitAPI.resolveCardBin(bin);
20902
20999
  }
21000
+ }, {
21001
+ key: "resolveIPAddress",
21002
+ value: function resolveIPAddress(ipAddress) {
21003
+ return ToolkitAPI.resolveIPAddress(ipAddress);
21004
+ }
20903
21005
  }]);
20904
21006
 
20905
21007
  return Toolkit;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@paystack/checkout-js",
3
- "version": "1.25.0",
3
+ "version": "1.26.0-dev.10",
4
4
  "description": "Client-side JS library for billing on Paystack",
5
5
  "main": "lib/checkout.js",
6
6
  "module": "es/checkout.js",