testing harness gets more Nexus API
This commit is contained in:
parent
cf0260fa7f
commit
98014f4b64
@ -849,6 +849,31 @@ export namespace LibeufinNexusApi {
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
export async function getPaymentInitiations(
|
||||
libeufinNexusService: LibeufinNexusService,
|
||||
accountName: string,
|
||||
username: string = "admin",
|
||||
password: string = "test",
|
||||
): Promise<void> {
|
||||
const baseUrl = libeufinNexusService.baseUrl;
|
||||
let url = new URL(
|
||||
`/bank-accounts/${accountName}/payment-initiations`,
|
||||
baseUrl,
|
||||
);
|
||||
let response = await axios.get(
|
||||
url.href,
|
||||
{
|
||||
auth: {
|
||||
username: username,
|
||||
password: password,
|
||||
},
|
||||
},
|
||||
);
|
||||
console.log(`Payment initiations of: ${accountName}`,
|
||||
JSON.stringify(response.data, null, 2));
|
||||
}
|
||||
|
||||
export async function getAccountTransactions(
|
||||
libeufinNexusService: LibeufinNexusService,
|
||||
accountName: string,
|
||||
|
Loading…
Reference in New Issue
Block a user