@appsaloon/ponto
v2.0.1
Published
Unofficial Ponto API Nodejs client
Maintainers
Readme
ponto-nodejs
Ponto API Nodejs client
Based on their REST API
Features
- Authentication and accessToken management
- Accounts
- Synchronisation of account details
Install
npm install pontoUsage
Initialize
const Ponto = require('ponto')
const sandboxMode = true
const ponto = new Ponto()('<ponto_client_id>', '<ponto_client_secret>', sandboxMode)Notes:
- Ponto can be initialised in sandbox mode for testing purpose.
ponto.listFinancialInstitutions (production & sandbox)
const pagingParameters = {
limit: 2, // Defaults :100
before: '<financialInstitutionId>', // cursor for pagination
after: '<financialInstitutionId>', // cursor for pagination
}
const response = await ponto.listFinancialInstitutions(pagingParameters)
const { meta, data, links, next, previous } = response
if (response.next) {
const nextPageResponse = await response.next()
}Notes :
pagingParameters.before&pagingParameters.aftercannot be used together- All list functions return a paging result. If they have a next or previous page a next or previous async function will be present.
more info
ponto.getFinancialInstitution (production & sandbox)
const response = await ponto.getFinancialInstitution('<financialInstitutionId>')
const { data } = responsemore info
ponto.listFinancialInstitutionAccounts (sandbox only)
const pagingParameters = {
limit: 2, // Defaults :100
before: '<financialInstitutionId>', // cursor for pagination
after: '<financialInstitutionId>', // cursor for pagination
}
const response = await ponto.listFinancialInstitutionAccounts('<financialInstitutionId>', pagingParameters)
const { meta, data, links, next, previous } = response
if (response.next) {
const nextPageResponse = await response.next()
}Notes :
pagingParameters.before&pagingParameters.aftercannot be used together- All list functions return a paging result. If they have a next or previous page a next or previous async function will be present.
more info
ponto.getFinancialInstitutionAccount (sandbox only)
const response = await ponto.getFinancialInstitutionAccount('<financialInstitutionId>', '<financialInstitutionAccountId>')
const { data } = responsemore info
ponto.listFinancialInstitutionTransactions (sandbox only)
const pagingParameters = {
limit: 2, // Defaults :100
before: '<financialInstitutionId>', // cursor for pagination
after: '<financialInstitutionId>', // cursor for pagination
}
const response = await ponto.listFinancialInstitutionTransactions('<financialInstitutionId>', '<financialInstitutionAccountId>', pagingParameters)
const { meta, data, links, next, previous } = response
if (response.next) {
const nextPageResponse = await response.next()
}Notes :
pagingParameters.before&pagingParameters.aftercannot be used together- All list functions return a paging result. If they have a next or previous page a next or previous async function will be present.
more info
ponto.getFinancialInstitutionTransaction (sandbox only)
const response = await ponto.getFinancialInstitutionTransaction('<financialInstitutionId>', '<financialInstitutionAccountId>', '<financialInstitutionTransactionId>')
const { data } = responsemore info
ponto.listAccounts (production only)
const pagingParameters = {
limit: 2, // Defaults :100
before: '<accountId>', // cursor for pagination
after: '<accountId>', // cursor for pagination
}
const response = await ponto.listAccounts(pagingParameters)
const { meta, data, links, next, previous } = response
if (response.next) {
const nextPageResponse = await response.next()
}Notes :
pagingParameters.before&pagingParameters.aftercannot be used together- All list functions return a paging result. If they have a next or previous page a next or previous async function will be present.
more info
ponto.getAccount (production only)
const response = await ponto.getAccount('<accountId>')
const { data } = responsemore info
ponto.syncAccount (production only)
const response = await ponto.syncAccount('<accountId>')
const { data } = responsemore info
ponto.getSynchronization (production only)
const response = await ponto.getSynchronization('<synchronizationId>')
const { data } = responsemore info
ponto.listTransactions (production only)
const pagingParameters = {
limit: 2, // Defaults :100
before: '<accountId>', // cursor for pagination
after: '<accountId>', // cursor for pagination
}
const response = await ponto.listAccounts('<accountId>', pagingParameters)
const { meta, data, links, next, previous } = response
if (response.next) {
const nextPageResponse = await response.next()
}Notes :
pagingParameters.before&pagingParameters.aftercannot be used together- All list functions return a paging result. If they have a next or previous page a next or previous async function will be present.
more info
ponto.getTransaction (production only)
const response = await ponto.getTransaction('<accountId>', t'<ransactionId>')
const { data } = responsemore info
