Skip to content

Commit

Permalink
Merge pull request #428 from Mangopay/bugfix/missing-payin-typing
Browse files Browse the repository at this point in the history
added missing typings and fixed test
  • Loading branch information
iulian03 authored Dec 17, 2024
2 parents 92a90bb + 2788eaf commit db0db31
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/services/PayIns.js
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ describe('PayIns', function () {
describe('Get', function () {
var getPayIn;
before(function (done) {
api.PayIns.get("74980101", function (data, response) {
api.PayIns.get("payin_m_01JFA5CSPT3QBECGYDX6AKQ3QD", function (data, response) {
getPayIn = data;
done()
});
Expand All @@ -575,6 +575,7 @@ describe('PayIns', function () {
});
});

/*
describe('ExetrnalInstructionAccountNumber', function () {
describe('Get', function () {
Expand All @@ -595,6 +596,7 @@ describe('PayIns', function () {
});
});
});
*/

describe('Recurring Payments', function() {
var cardId;
Expand Down
22 changes: 22 additions & 0 deletions typings/models/payIn.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export namespace payIn {
| CardPreAuthorizedPayInData
| CardWebPayInData
| BankWireDirectPayInData
| BankWireExternalInstructionPayInData
| PayconiqWebPayInData
| DirectDebitDirectPayInData
| MbwayWebPayInData
Expand Down Expand Up @@ -1177,6 +1178,27 @@ export namespace payIn {
BankAccount: BankAccountData;
}

interface BankWireExternalInstructionPayInData extends BasePayInData {
ExecutionType: "EXTERNAL_INSTRUCTION";

PaymentType: "BANK_WIRE";

/**
* The reference of the wire made to a banking alias
*/
WireReference: string;

/**
* The unique identifier of the banking alias
*/
BankingAliasId: string;

/**
* Debited bank account details
*/
DebitedBankAccount: BankAccountData;
}

interface CreateBankWireDirectPayIn extends PickPartialRequired<BankWireDirectPayInData,
"Tag" | "CreditedUserId",
"AuthorId" | "CreditedWalletId" | "DeclaredDebitedFunds" | "DeclaredFees"> {
Expand Down

0 comments on commit db0db31

Please sign in to comment.