increase 0.2.0 → 0.4.0
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/.prettierignore +1 -0
- package/.release-please-manifest.json +3 -0
- package/.stats.yml +1 -1
- package/CHANGELOG.md +130 -0
- package/README.md +19 -5
- package/api.md +99 -0
- package/bin/check-release-environment +25 -0
- package/bin/publish-npm +6 -0
- package/check-version.ts +4 -1
- package/core.ts +32 -126
- package/dist/cjs/check-version.d.ts +1 -0
- package/dist/cjs/check-version.d.ts.map +1 -0
- package/dist/cjs/check-version.js +3 -1
- package/dist/cjs/check-version.js.map +1 -1
- package/dist/cjs/core.d.ts +25 -55
- package/dist/cjs/core.d.ts.map +1 -0
- package/dist/cjs/core.js +43 -168
- package/dist/cjs/core.js.map +1 -1
- package/dist/cjs/error.d.ts +208 -0
- package/dist/cjs/error.d.ts.map +1 -0
- package/dist/cjs/error.js +326 -0
- package/dist/cjs/error.js.map +1 -0
- package/dist/cjs/examples/api-error.d.ts +3 -0
- package/dist/cjs/examples/api-error.d.ts.map +1 -0
- package/dist/cjs/examples/api-error.js +92 -0
- package/dist/cjs/examples/api-error.js.map +1 -0
- package/dist/cjs/fetch-polyfill.d.ts +1 -0
- package/dist/cjs/fetch-polyfill.d.ts.map +1 -0
- package/dist/cjs/fetch-polyfill.js +2 -2
- package/dist/cjs/fetch-polyfill.js.map +1 -1
- package/dist/cjs/index.d.ts +81 -22
- package/dist/cjs/index.d.ts.map +1 -0
- package/dist/cjs/index.js +80 -26
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/pagination.d.ts +4 -0
- package/dist/cjs/pagination.d.ts.map +1 -0
- package/dist/cjs/pagination.js.map +1 -1
- package/dist/cjs/resource.d.ts +1 -0
- package/dist/cjs/resource.d.ts.map +1 -0
- package/dist/cjs/resources/account-numbers.d.ts +26 -0
- package/dist/cjs/resources/account-numbers.d.ts.map +1 -0
- package/dist/cjs/resources/account-numbers.js.map +1 -1
- package/dist/cjs/resources/account-statements.d.ts +1 -0
- package/dist/cjs/resources/account-statements.d.ts.map +1 -0
- package/dist/cjs/resources/account-statements.js.map +1 -1
- package/dist/cjs/resources/account-transfers.d.ts +20 -11
- package/dist/cjs/resources/account-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/account-transfers.js.map +1 -1
- package/dist/cjs/resources/accounts.d.ts +41 -19
- package/dist/cjs/resources/accounts.d.ts.map +1 -0
- package/dist/cjs/resources/accounts.js.map +1 -1
- package/dist/cjs/resources/ach-prenotifications.d.ts +4 -0
- package/dist/cjs/resources/ach-prenotifications.d.ts.map +1 -0
- package/dist/cjs/resources/ach-prenotifications.js.map +1 -1
- package/dist/cjs/resources/ach-transfers.d.ts +89 -9
- package/dist/cjs/resources/ach-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/ach-transfers.js.map +1 -1
- package/dist/cjs/resources/balance-lookups.d.ts +47 -0
- package/dist/cjs/resources/balance-lookups.d.ts.map +1 -0
- package/dist/cjs/resources/balance-lookups.js +15 -0
- package/dist/cjs/resources/balance-lookups.js.map +1 -0
- package/dist/cjs/resources/bookkeeping-accounts.d.ts +71 -0
- package/dist/cjs/resources/bookkeeping-accounts.d.ts.map +1 -0
- package/dist/cjs/resources/bookkeeping-accounts.js +29 -0
- package/dist/cjs/resources/bookkeeping-accounts.js.map +1 -0
- package/dist/cjs/resources/bookkeeping-entries.d.ts +43 -0
- package/dist/cjs/resources/bookkeeping-entries.d.ts.map +1 -0
- package/dist/cjs/resources/bookkeeping-entries.js +19 -0
- package/dist/cjs/resources/bookkeeping-entries.js.map +1 -0
- package/dist/cjs/resources/bookkeeping-entry-sets.d.ts +83 -0
- package/dist/cjs/resources/bookkeeping-entry-sets.d.ts.map +1 -0
- package/dist/cjs/resources/bookkeeping-entry-sets.js +15 -0
- package/dist/cjs/resources/bookkeeping-entry-sets.js.map +1 -0
- package/dist/cjs/resources/card-disputes.d.ts +13 -3
- package/dist/cjs/resources/card-disputes.d.ts.map +1 -0
- package/dist/cjs/resources/card-disputes.js.map +1 -1
- package/dist/cjs/resources/card-profiles.d.ts +18 -2
- package/dist/cjs/resources/card-profiles.d.ts.map +1 -0
- package/dist/cjs/resources/card-profiles.js.map +1 -1
- package/dist/cjs/resources/cards.d.ts +31 -2
- package/dist/cjs/resources/cards.d.ts.map +1 -0
- package/dist/cjs/resources/cards.js.map +1 -1
- package/dist/cjs/resources/check-deposits.d.ts +16 -1
- package/dist/cjs/resources/check-deposits.d.ts.map +1 -0
- package/dist/cjs/resources/check-deposits.js.map +1 -1
- package/dist/cjs/resources/check-transfers.d.ts +104 -5
- package/dist/cjs/resources/check-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/check-transfers.js.map +1 -1
- package/dist/cjs/resources/declined-transactions.d.ts +85 -23
- package/dist/cjs/resources/declined-transactions.d.ts.map +1 -0
- package/dist/cjs/resources/declined-transactions.js.map +1 -1
- package/dist/cjs/resources/digital-wallet-tokens.d.ts +1 -0
- package/dist/cjs/resources/digital-wallet-tokens.d.ts.map +1 -0
- package/dist/cjs/resources/digital-wallet-tokens.js.map +1 -1
- package/dist/cjs/resources/documents.d.ts +105 -4
- package/dist/cjs/resources/documents.d.ts.map +1 -0
- package/dist/cjs/resources/documents.js.map +1 -1
- package/dist/cjs/resources/entities/entities.d.ts +363 -136
- package/dist/cjs/resources/entities/entities.d.ts.map +1 -0
- package/dist/cjs/resources/entities/entities.js +1 -1
- package/dist/cjs/resources/entities/entities.js.map +1 -1
- package/dist/cjs/resources/entities/index.d.ts +7 -1
- package/dist/cjs/resources/entities/index.d.ts.map +1 -0
- package/dist/cjs/resources/entities/index.js +8 -1
- package/dist/cjs/resources/entities/index.js.map +1 -1
- package/dist/cjs/resources/entities/supplemental-documents.d.ts +36 -0
- package/dist/cjs/resources/entities/supplemental-documents.d.ts.map +1 -0
- package/dist/cjs/resources/entities/supplemental-documents.js +14 -1
- package/dist/cjs/resources/entities/supplemental-documents.js.map +1 -1
- package/dist/cjs/resources/event-subscriptions.d.ts +5 -0
- package/dist/cjs/resources/event-subscriptions.d.ts.map +1 -0
- package/dist/cjs/resources/event-subscriptions.js.map +1 -1
- package/dist/cjs/resources/events.d.ts +30 -24
- package/dist/cjs/resources/events.d.ts.map +1 -0
- package/dist/cjs/resources/events.js.map +1 -1
- package/dist/cjs/resources/exports.d.ts +162 -0
- package/dist/cjs/resources/exports.d.ts.map +1 -0
- package/dist/cjs/resources/exports.js +31 -0
- package/dist/cjs/resources/exports.js.map +1 -0
- package/dist/cjs/resources/external-accounts.d.ts +4 -2
- package/dist/cjs/resources/external-accounts.d.ts.map +1 -0
- package/dist/cjs/resources/external-accounts.js.map +1 -1
- package/dist/cjs/resources/files.d.ts +10 -4
- package/dist/cjs/resources/files.d.ts.map +1 -0
- package/dist/cjs/resources/files.js.map +1 -1
- package/dist/cjs/resources/groups.d.ts +1 -0
- package/dist/cjs/resources/groups.d.ts.map +1 -0
- package/dist/cjs/resources/inbound-ach-transfer-returns.d.ts +4 -0
- package/dist/cjs/resources/inbound-ach-transfer-returns.d.ts.map +1 -0
- package/dist/cjs/resources/inbound-ach-transfer-returns.js.map +1 -1
- package/dist/cjs/resources/inbound-wire-drawdown-requests.d.ts +1 -0
- package/dist/cjs/resources/inbound-wire-drawdown-requests.d.ts.map +1 -0
- package/dist/cjs/resources/inbound-wire-drawdown-requests.js.map +1 -1
- package/dist/cjs/resources/index.d.ts +29 -0
- package/dist/cjs/resources/index.d.ts.map +1 -0
- package/dist/cjs/resources/index.js +100 -9
- package/dist/cjs/resources/index.js.map +1 -1
- package/dist/cjs/resources/limits.d.ts +1 -0
- package/dist/cjs/resources/limits.d.ts.map +1 -0
- package/dist/cjs/resources/limits.js.map +1 -1
- package/dist/cjs/resources/oauth-connections.d.ts +1 -0
- package/dist/cjs/resources/oauth-connections.d.ts.map +1 -0
- package/dist/cjs/resources/oauth-connections.js.map +1 -1
- package/dist/cjs/resources/pending-transactions.d.ts +115 -36
- package/dist/cjs/resources/pending-transactions.d.ts.map +1 -0
- package/dist/cjs/resources/pending-transactions.js.map +1 -1
- package/dist/cjs/resources/programs.d.ts +48 -0
- package/dist/cjs/resources/programs.d.ts.map +1 -0
- package/dist/cjs/resources/programs.js +25 -0
- package/dist/cjs/resources/programs.js.map +1 -0
- package/dist/cjs/resources/real-time-decisions.d.ts +43 -7
- package/dist/cjs/resources/real-time-decisions.d.ts.map +1 -0
- package/dist/cjs/resources/real-time-payments-transfers.d.ts +287 -0
- package/dist/cjs/resources/real-time-payments-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/real-time-payments-transfers.js +35 -0
- package/dist/cjs/resources/real-time-payments-transfers.js.map +1 -0
- package/dist/cjs/resources/routing-numbers.d.ts +1 -0
- package/dist/cjs/resources/routing-numbers.d.ts.map +1 -0
- package/dist/cjs/resources/shared.d.ts +1 -0
- package/dist/cjs/resources/shared.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/account-statements.d.ts +1 -0
- package/dist/cjs/resources/simulations/account-statements.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/account-transfers.d.ts +1 -0
- package/dist/cjs/resources/simulations/account-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/ach-transfers.d.ts +470 -157
- package/dist/cjs/resources/simulations/ach-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/card-disputes.d.ts +1 -0
- package/dist/cjs/resources/simulations/card-disputes.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/card-refunds.d.ts +1 -0
- package/dist/cjs/resources/simulations/card-refunds.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/cards.d.ts +188 -56
- package/dist/cjs/resources/simulations/cards.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/check-deposits.d.ts +1 -0
- package/dist/cjs/resources/simulations/check-deposits.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/check-transfers.d.ts +16 -0
- package/dist/cjs/resources/simulations/check-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/check-transfers.js +10 -0
- package/dist/cjs/resources/simulations/check-transfers.js.map +1 -1
- package/dist/cjs/resources/simulations/digital-wallet-token-requests.d.ts +1 -0
- package/dist/cjs/resources/simulations/digital-wallet-token-requests.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/documents.d.ts +1 -0
- package/dist/cjs/resources/simulations/documents.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/inbound-wire-drawdown-requests.d.ts +1 -0
- package/dist/cjs/resources/simulations/inbound-wire-drawdown-requests.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/index.d.ts +5 -0
- package/dist/cjs/resources/simulations/index.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/interest-payments.d.ts +1237 -0
- package/dist/cjs/resources/simulations/interest-payments.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/interest-payments.js +16 -0
- package/dist/cjs/resources/simulations/interest-payments.js.map +1 -0
- package/dist/cjs/resources/simulations/programs.d.ts +21 -0
- package/dist/cjs/resources/simulations/programs.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/programs.js +17 -0
- package/dist/cjs/resources/simulations/programs.js.map +1 -0
- package/dist/cjs/resources/simulations/real-time-payments-transfers.d.ts +470 -155
- package/dist/cjs/resources/simulations/real-time-payments-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/real-time-payments-transfers.js +11 -0
- package/dist/cjs/resources/simulations/real-time-payments-transfers.js.map +1 -1
- package/dist/cjs/resources/simulations/simulations.d.ts +5 -0
- package/dist/cjs/resources/simulations/simulations.d.ts.map +1 -0
- package/dist/cjs/resources/simulations/simulations.js +4 -0
- package/dist/cjs/resources/simulations/simulations.js.map +1 -1
- package/dist/cjs/resources/simulations/wire-transfers.d.ts +332 -133
- package/dist/cjs/resources/simulations/wire-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/transactions.d.ts +353 -165
- package/dist/cjs/resources/transactions.d.ts.map +1 -0
- package/dist/cjs/resources/transactions.js.map +1 -1
- package/dist/cjs/resources/wire-drawdown-requests.d.ts +5 -0
- package/dist/cjs/resources/wire-drawdown-requests.d.ts.map +1 -0
- package/dist/cjs/resources/wire-drawdown-requests.js.map +1 -1
- package/dist/cjs/resources/wire-transfers.d.ts +39 -4
- package/dist/cjs/resources/wire-transfers.d.ts.map +1 -0
- package/dist/cjs/resources/wire-transfers.js.map +1 -1
- package/dist/cjs/streaming.d.ts +13 -0
- package/dist/cjs/streaming.d.ts.map +1 -0
- package/dist/cjs/streaming.js +282 -0
- package/dist/cjs/streaming.js.map +1 -0
- package/dist/cjs/tests/api-resources/account-numbers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/account-numbers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/account-numbers.test.js +25 -28
- package/dist/cjs/tests/api-resources/account-numbers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/account-statements.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/account-statements.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/account-statements.test.js +7 -20
- package/dist/cjs/tests/api-resources/account-statements.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/account-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/account-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/account-transfers.test.js +16 -29
- package/dist/cjs/tests/api-resources/account-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/accounts.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/accounts.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/accounts.test.js +22 -23
- package/dist/cjs/tests/api-resources/accounts.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/ach-prenotifications.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/ach-prenotifications.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/ach-prenotifications.test.js +12 -24
- package/dist/cjs/tests/api-resources/ach-prenotifications.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/ach-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/ach-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/ach-transfers.test.js +17 -31
- package/dist/cjs/tests/api-resources/ach-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/balance-lookups.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/balance-lookups.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/balance-lookups.test.js +55 -0
- package/dist/cjs/tests/api-resources/balance-lookups.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/bookkeeping-accounts.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/bookkeeping-accounts.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/bookkeeping-accounts.test.js +78 -0
- package/dist/cjs/tests/api-resources/bookkeeping-accounts.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entries.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entries.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entries.test.js +65 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entries.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entry-sets.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entry-sets.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entry-sets.test.js +66 -0
- package/dist/cjs/tests/api-resources/bookkeeping-entry-sets.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/card-disputes.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/card-disputes.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/card-disputes.test.js +18 -24
- package/dist/cjs/tests/api-resources/card-disputes.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/card-profiles.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/card-profiles.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/card-profiles.test.js +28 -19
- package/dist/cjs/tests/api-resources/card-profiles.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/cards.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/cards.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/cards.test.js +13 -35
- package/dist/cjs/tests/api-resources/cards.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/check-deposits.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/check-deposits.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/check-deposits.test.js +24 -27
- package/dist/cjs/tests/api-resources/check-deposits.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/check-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/check-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/check-transfers.test.js +27 -40
- package/dist/cjs/tests/api-resources/check-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/declined-transactions.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/declined-transactions.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/declined-transactions.test.js +9 -23
- package/dist/cjs/tests/api-resources/declined-transactions.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/digital-wallet-tokens.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/digital-wallet-tokens.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/digital-wallet-tokens.test.js +8 -21
- package/dist/cjs/tests/api-resources/digital-wallet-tokens.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/documents.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/documents.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/documents.test.js +15 -23
- package/dist/cjs/tests/api-resources/documents.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/entities/entities.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/entities/entities.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/entities/entities.test.js +40 -31
- package/dist/cjs/tests/api-resources/entities/entities.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/entities/supplemental-documents.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/entities/supplemental-documents.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/entities/supplemental-documents.test.js +25 -6
- package/dist/cjs/tests/api-resources/entities/supplemental-documents.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/event-subscriptions.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/event-subscriptions.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/event-subscriptions.test.js +10 -20
- package/dist/cjs/tests/api-resources/event-subscriptions.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/events.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/events.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/events.test.js +8 -22
- package/dist/cjs/tests/api-resources/events.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/exports.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/exports.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/exports.test.js +101 -0
- package/dist/cjs/tests/api-resources/exports.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/external-accounts.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/external-accounts.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/external-accounts.test.js +13 -27
- package/dist/cjs/tests/api-resources/external-accounts.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/files.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/files.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/files.test.js +8 -21
- package/dist/cjs/tests/api-resources/files.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/groups.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/groups.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/groups.test.js +6 -5
- package/dist/cjs/tests/api-resources/groups.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/inbound-ach-transfer-returns.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/inbound-ach-transfer-returns.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/inbound-ach-transfer-returns.test.js +16 -12
- package/dist/cjs/tests/api-resources/inbound-ach-transfer-returns.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/inbound-wire-drawdown-requests.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/inbound-wire-drawdown-requests.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/inbound-wire-drawdown-requests.test.js +6 -9
- package/dist/cjs/tests/api-resources/inbound-wire-drawdown-requests.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/limits.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/limits.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/limits.test.js +14 -17
- package/dist/cjs/tests/api-resources/limits.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/oauth-connections.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/oauth-connections.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/oauth-connections.test.js +6 -9
- package/dist/cjs/tests/api-resources/oauth-connections.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/pending-transactions.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/pending-transactions.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/pending-transactions.test.js +13 -17
- package/dist/cjs/tests/api-resources/pending-transactions.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/programs.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/programs.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/programs.test.js +73 -0
- package/dist/cjs/tests/api-resources/programs.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/real-time-decisions.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/real-time-decisions.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/real-time-decisions.test.js +6 -16
- package/dist/cjs/tests/api-resources/real-time-decisions.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/real-time-payments-transfers.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/real-time-payments-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/real-time-payments-transfers.test.js +113 -0
- package/dist/cjs/tests/api-resources/real-time-payments-transfers.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/routing-numbers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/routing-numbers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/routing-numbers.test.js +6 -5
- package/dist/cjs/tests/api-resources/routing-numbers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/account-statements.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/account-statements.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/account-statements.test.js +11 -8
- package/dist/cjs/tests/api-resources/simulations/account-statements.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/account-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/account-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/account-transfers.test.js +5 -4
- package/dist/cjs/tests/api-resources/simulations/account-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/ach-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/ach-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/ach-transfers.test.js +13 -19
- package/dist/cjs/tests/api-resources/simulations/ach-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/card-disputes.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/card-disputes.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/card-disputes.test.js +8 -7
- package/dist/cjs/tests/api-resources/simulations/card-disputes.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/card-refunds.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/card-refunds.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/card-refunds.test.js +11 -8
- package/dist/cjs/tests/api-resources/simulations/card-refunds.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/cards.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/cards.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/cards.test.js +12 -10
- package/dist/cjs/tests/api-resources/simulations/cards.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/check-deposits.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/check-deposits.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/check-deposits.test.js +5 -4
- package/dist/cjs/tests/api-resources/simulations/check-deposits.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/check-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/check-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/check-transfers.test.js +23 -4
- package/dist/cjs/tests/api-resources/simulations/check-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/digital-wallet-token-requests.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/digital-wallet-token-requests.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/digital-wallet-token-requests.test.js +11 -8
- package/dist/cjs/tests/api-resources/simulations/digital-wallet-token-requests.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/documents.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/documents.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/documents.test.js +10 -7
- package/dist/cjs/tests/api-resources/simulations/documents.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/inbound-wire-drawdown-requests.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/inbound-wire-drawdown-requests.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/inbound-wire-drawdown-requests.test.js +29 -28
- package/dist/cjs/tests/api-resources/simulations/inbound-wire-drawdown-requests.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/interest-payments.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/simulations/interest-payments.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/interest-payments.test.js +58 -0
- package/dist/cjs/tests/api-resources/simulations/interest-payments.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/programs.test.d.ts +2 -0
- package/dist/cjs/tests/api-resources/simulations/programs.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/programs.test.js +52 -0
- package/dist/cjs/tests/api-resources/simulations/programs.test.js.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/real-time-payments-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/real-time-payments-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/real-time-payments-transfers.test.js +20 -12
- package/dist/cjs/tests/api-resources/simulations/real-time-payments-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/simulations/wire-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/simulations/wire-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/simulations/wire-transfers.test.js +11 -10
- package/dist/cjs/tests/api-resources/simulations/wire-transfers.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/transactions.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/transactions.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/transactions.test.js +11 -28
- package/dist/cjs/tests/api-resources/transactions.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/wire-drawdown-requests.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/wire-drawdown-requests.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/wire-drawdown-requests.test.js +20 -23
- package/dist/cjs/tests/api-resources/wire-drawdown-requests.test.js.map +1 -1
- package/dist/cjs/tests/api-resources/wire-transfers.test.d.ts +1 -0
- package/dist/cjs/tests/api-resources/wire-transfers.test.d.ts.map +1 -0
- package/dist/cjs/tests/api-resources/wire-transfers.test.js +22 -36
- package/dist/cjs/tests/api-resources/wire-transfers.test.js.map +1 -1
- package/dist/cjs/tests/form.test.d.ts +1 -0
- package/dist/cjs/tests/form.test.d.ts.map +1 -0
- package/dist/cjs/tests/form.test.js +4 -3
- package/dist/cjs/tests/index.test.d.ts +1 -0
- package/dist/cjs/tests/index.test.d.ts.map +1 -0
- package/dist/cjs/tests/index.test.js +36 -4
- package/dist/cjs/tests/index.test.js.map +1 -1
- package/dist/cjs/tests/responses.test.d.ts +1 -0
- package/dist/cjs/tests/responses.test.d.ts.map +1 -0
- package/dist/cjs/tests/responses.test.js +4 -3
- package/dist/cjs/version.d.ts +2 -1
- package/dist/cjs/version.d.ts.map +1 -0
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/version.js.map +1 -1
- package/error.ts +505 -0
- package/examples/api-error.ts +21 -0
- package/fetch-polyfill.ts +2 -2
- package/index.ts +90 -20
- package/package.json +2 -2
- package/pagination.ts +3 -0
- package/release-please-config.json +61 -0
- package/resources/account-numbers.ts +30 -1
- package/resources/account-statements.ts +0 -1
- package/resources/account-transfers.ts +21 -13
- package/resources/accounts.ts +48 -23
- package/resources/ach-prenotifications.ts +3 -1
- package/resources/ach-transfers.ts +92 -11
- package/resources/balance-lookups.ts +57 -0
- package/resources/bookkeeping-accounts.ts +98 -0
- package/resources/bookkeeping-entries.ts +62 -0
- package/resources/bookkeeping-entry-sets.ts +100 -0
- package/resources/card-disputes.ts +12 -4
- package/resources/card-profiles.ts +17 -3
- package/resources/cards.ts +30 -3
- package/resources/check-deposits.ts +15 -2
- package/resources/check-transfers.ts +117 -7
- package/resources/declined-transactions.ts +96 -27
- package/resources/digital-wallet-tokens.ts +0 -1
- package/resources/documents.ts +104 -5
- package/resources/entities/entities.ts +443 -212
- package/resources/entities/index.ts +6 -1
- package/resources/entities/supplemental-documents.ts +46 -0
- package/resources/event-subscriptions.ts +4 -1
- package/resources/events.ts +33 -29
- package/resources/exports.ts +204 -0
- package/resources/external-accounts.ts +3 -3
- package/resources/files.ts +9 -5
- package/resources/inbound-ach-transfer-returns.ts +3 -1
- package/resources/inbound-wire-drawdown-requests.ts +0 -1
- package/resources/index.ts +28 -0
- package/resources/limits.ts +0 -1
- package/resources/oauth-connections.ts +0 -1
- package/resources/pending-transactions.ts +126 -48
- package/resources/programs.ts +70 -0
- package/resources/real-time-decisions.ts +43 -8
- package/resources/real-time-payments-transfers.ts +351 -0
- package/resources/simulations/ach-transfers.ts +504 -192
- package/resources/simulations/cards.ts +206 -69
- package/resources/simulations/check-transfers.ts +19 -0
- package/resources/simulations/index.ts +4 -0
- package/resources/simulations/interest-payments.ts +1501 -0
- package/resources/simulations/programs.ts +26 -0
- package/resources/simulations/real-time-payments-transfers.ts +512 -190
- package/resources/simulations/simulations.ts +4 -0
- package/resources/simulations/wire-transfers.ts +354 -165
- package/resources/transactions.ts +379 -202
- package/resources/wire-drawdown-requests.ts +4 -1
- package/resources/wire-transfers.ts +43 -6
- package/streaming.ts +199 -0
- package/tests/api-resources/account-numbers.test.ts +22 -25
- package/tests/api-resources/account-statements.test.ts +4 -17
- package/tests/api-resources/account-transfers.test.ts +13 -26
- package/tests/api-resources/accounts.test.ts +19 -20
- package/tests/api-resources/ach-prenotifications.test.ts +9 -21
- package/tests/api-resources/ach-transfers.test.ts +14 -28
- package/tests/api-resources/balance-lookups.test.ts +18 -0
- package/tests/api-resources/bookkeeping-accounts.test.ts +38 -0
- package/tests/api-resources/bookkeeping-entries.test.ts +25 -0
- package/tests/api-resources/bookkeeping-entry-sets.test.ts +29 -0
- package/tests/api-resources/card-disputes.test.ts +15 -21
- package/tests/api-resources/card-profiles.test.ts +25 -16
- package/tests/api-resources/cards.test.ts +10 -32
- package/tests/api-resources/check-deposits.test.ts +21 -24
- package/tests/api-resources/check-transfers.test.ts +24 -37
- package/tests/api-resources/declined-transactions.test.ts +6 -20
- package/tests/api-resources/digital-wallet-tokens.test.ts +5 -18
- package/tests/api-resources/documents.test.ts +8 -20
- package/tests/api-resources/entities/entities.test.ts +37 -31
- package/tests/api-resources/entities/supplemental-documents.test.ts +22 -3
- package/tests/api-resources/event-subscriptions.test.ts +7 -17
- package/tests/api-resources/events.test.ts +5 -19
- package/tests/api-resources/exports.test.ts +64 -0
- package/tests/api-resources/external-accounts.test.ts +10 -24
- package/tests/api-resources/files.test.ts +5 -19
- package/tests/api-resources/groups.test.ts +3 -2
- package/tests/api-resources/inbound-ach-transfer-returns.test.ts +13 -9
- package/tests/api-resources/inbound-wire-drawdown-requests.test.ts +3 -6
- package/tests/api-resources/limits.test.ts +11 -14
- package/tests/api-resources/oauth-connections.test.ts +3 -6
- package/tests/api-resources/pending-transactions.test.ts +10 -14
- package/tests/api-resources/programs.test.ts +36 -0
- package/tests/api-resources/real-time-decisions.test.ts +3 -13
- package/tests/api-resources/real-time-payments-transfers.test.ts +76 -0
- package/tests/api-resources/routing-numbers.test.ts +3 -2
- package/tests/api-resources/simulations/account-statements.test.ts +8 -5
- package/tests/api-resources/simulations/account-transfers.test.ts +2 -1
- package/tests/api-resources/simulations/ach-transfers.test.ts +10 -16
- package/tests/api-resources/simulations/card-disputes.test.ts +5 -4
- package/tests/api-resources/simulations/card-refunds.test.ts +8 -5
- package/tests/api-resources/simulations/cards.test.ts +9 -7
- package/tests/api-resources/simulations/check-deposits.test.ts +2 -1
- package/tests/api-resources/simulations/check-transfers.test.ts +14 -1
- package/tests/api-resources/simulations/digital-wallet-token-requests.test.ts +8 -5
- package/tests/api-resources/simulations/documents.test.ts +7 -4
- package/tests/api-resources/simulations/inbound-wire-drawdown-requests.test.ts +26 -25
- package/tests/api-resources/simulations/interest-payments.test.ts +15 -0
- package/tests/api-resources/simulations/programs.test.ts +15 -0
- package/tests/api-resources/simulations/real-time-payments-transfers.test.ts +17 -9
- package/tests/api-resources/simulations/wire-transfers.test.ts +8 -7
- package/tests/api-resources/transactions.test.ts +8 -25
- package/tests/api-resources/wire-drawdown-requests.test.ts +17 -20
- package/tests/api-resources/wire-transfers.test.ts +19 -33
- package/tests/index.test.ts +30 -1
- package/tsconfig.json +2 -0
- package/version.ts +1 -1
package/index.ts
CHANGED
|
@@ -4,6 +4,7 @@ import qs from 'qs';
|
|
|
4
4
|
import * as Core from './core';
|
|
5
5
|
import * as Pagination from './pagination';
|
|
6
6
|
import * as API from './resources';
|
|
7
|
+
import * as Errors from '~/error';
|
|
7
8
|
import type { Agent } from 'http';
|
|
8
9
|
import * as FileFromPath from 'formdata-node/file-from-path';
|
|
9
10
|
|
|
@@ -21,12 +22,16 @@ type Config = {
|
|
|
21
22
|
baseURL?: string;
|
|
22
23
|
timeout?: number;
|
|
23
24
|
httpAgent?: Agent;
|
|
25
|
+
maxRetries?: number;
|
|
26
|
+
defaultHeaders?: Core.Headers;
|
|
24
27
|
};
|
|
25
28
|
|
|
26
29
|
/** Instantiate the API Client. */
|
|
27
30
|
export class Increase extends Core.APIClient {
|
|
28
31
|
apiKey: string;
|
|
29
32
|
|
|
33
|
+
private _options: Config;
|
|
34
|
+
|
|
30
35
|
constructor(config?: Config) {
|
|
31
36
|
const options: Config = {
|
|
32
37
|
apiKey: process.env['INCREASE_API_KEY'] || '',
|
|
@@ -44,21 +49,30 @@ export class Increase extends Core.APIClient {
|
|
|
44
49
|
baseURL: options.baseURL || environments[options.environment || 'production'],
|
|
45
50
|
timeout: options.timeout,
|
|
46
51
|
httpAgent: options.httpAgent,
|
|
52
|
+
maxRetries: options.maxRetries,
|
|
47
53
|
});
|
|
48
54
|
this.apiKey = options.apiKey;
|
|
55
|
+
this._options = options;
|
|
49
56
|
this.idempotencyHeader = 'Idempotency-Key';
|
|
50
57
|
}
|
|
51
58
|
|
|
52
59
|
accounts: API.Accounts = new API.Accounts(this);
|
|
53
60
|
accountNumbers: API.AccountNumbers = new API.AccountNumbers(this);
|
|
61
|
+
bookkeepingAccounts: API.BookkeepingAccounts = new API.BookkeepingAccounts(this);
|
|
62
|
+
bookkeepingEntrySets: API.BookkeepingEntrySets = new API.BookkeepingEntrySets(this);
|
|
63
|
+
bookkeepingEntries: API.BookkeepingEntries = new API.BookkeepingEntries(this);
|
|
54
64
|
realTimeDecisions: API.RealTimeDecisions = new API.RealTimeDecisions(this);
|
|
65
|
+
realTimePaymentsTransfers: API.RealTimePaymentsTransfers = new API.RealTimePaymentsTransfers(this);
|
|
66
|
+
balanceLookups: API.BalanceLookups = new API.BalanceLookups(this);
|
|
55
67
|
cards: API.Cards = new API.Cards(this);
|
|
56
68
|
cardDisputes: API.CardDisputes = new API.CardDisputes(this);
|
|
57
69
|
cardProfiles: API.CardProfiles = new API.CardProfiles(this);
|
|
58
70
|
externalAccounts: API.ExternalAccounts = new API.ExternalAccounts(this);
|
|
71
|
+
exports: API.Exports = new API.Exports(this);
|
|
59
72
|
digitalWalletTokens: API.DigitalWalletTokens = new API.DigitalWalletTokens(this);
|
|
60
73
|
transactions: API.Transactions = new API.Transactions(this);
|
|
61
74
|
pendingTransactions: API.PendingTransactions = new API.PendingTransactions(this);
|
|
75
|
+
programs: API.Programs = new API.Programs(this);
|
|
62
76
|
declinedTransactions: API.DeclinedTransactions = new API.DeclinedTransactions(this);
|
|
63
77
|
limits: API.Limits = new API.Limits(this);
|
|
64
78
|
accountTransfers: API.AccountTransfers = new API.AccountTransfers(this);
|
|
@@ -81,6 +95,13 @@ export class Increase extends Core.APIClient {
|
|
|
81
95
|
accountStatements: API.AccountStatements = new API.AccountStatements(this);
|
|
82
96
|
simulations: API.Simulations = new API.Simulations(this);
|
|
83
97
|
|
|
98
|
+
protected override defaultHeaders(): Core.Headers {
|
|
99
|
+
return {
|
|
100
|
+
...super.defaultHeaders(),
|
|
101
|
+
...this._options.defaultHeaders,
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
|
|
84
105
|
protected override authHeaders(): Core.Headers {
|
|
85
106
|
return { Authorization: `Bearer ${this.apiKey}` };
|
|
86
107
|
}
|
|
@@ -89,36 +110,56 @@ export class Increase extends Core.APIClient {
|
|
|
89
110
|
return { allowDots: true, arrayFormat: 'comma' };
|
|
90
111
|
}
|
|
91
112
|
|
|
92
|
-
static APIError =
|
|
93
|
-
|
|
94
|
-
static
|
|
95
|
-
static
|
|
96
|
-
|
|
97
|
-
static
|
|
98
|
-
static
|
|
99
|
-
static
|
|
100
|
-
static
|
|
101
|
-
static
|
|
102
|
-
static
|
|
103
|
-
static
|
|
104
|
-
static
|
|
113
|
+
static APIError = Errors.APIError;
|
|
114
|
+
static APIConnectionError = Errors.APIConnectionError;
|
|
115
|
+
static APIConnectionTimeoutError = Errors.APIConnectionTimeoutError;
|
|
116
|
+
static NotFoundError = Errors.NotFoundError;
|
|
117
|
+
static ConflictError = Errors.ConflictError;
|
|
118
|
+
static RateLimitError = Errors.RateLimitError;
|
|
119
|
+
static BadRequestError = Errors.BadRequestError;
|
|
120
|
+
static RateLimitedError = Errors.RateLimitedError;
|
|
121
|
+
static InvalidAPIKeyError = Errors.InvalidAPIKeyError;
|
|
122
|
+
static AuthenticationError = Errors.AuthenticationError;
|
|
123
|
+
static InternalServerError = Errors.InternalServerError;
|
|
124
|
+
static ObjectNotFoundError = Errors.ObjectNotFoundError;
|
|
125
|
+
static PrivateFeatureError = Errors.PrivateFeatureError;
|
|
126
|
+
static PermissionDeniedError = Errors.PermissionDeniedError;
|
|
127
|
+
static InvalidOperationError = Errors.InvalidOperationError;
|
|
128
|
+
static MalformedRequestError = Errors.MalformedRequestError;
|
|
129
|
+
static APIMethodNotFoundError = Errors.APIMethodNotFoundError;
|
|
130
|
+
static InvalidParametersError = Errors.InvalidParametersError;
|
|
131
|
+
static UnprocessableEntityError = Errors.UnprocessableEntityError;
|
|
132
|
+
static EnvironmentMismatchError = Errors.EnvironmentMismatchError;
|
|
133
|
+
static IdempotencyConflictError = Errors.IdempotencyConflictError;
|
|
134
|
+
static InsufficientPermissionsError = Errors.InsufficientPermissionsError;
|
|
135
|
+
static IdempotencyUnprocessableError = Errors.IdempotencyUnprocessableError;
|
|
105
136
|
}
|
|
106
137
|
|
|
107
138
|
export const {
|
|
108
139
|
APIError,
|
|
109
|
-
|
|
110
140
|
APIConnectionError,
|
|
111
141
|
APIConnectionTimeoutError,
|
|
112
|
-
|
|
113
|
-
BadRequestError,
|
|
114
|
-
AuthenticationError,
|
|
115
|
-
PermissionDeniedError,
|
|
116
142
|
NotFoundError,
|
|
117
143
|
ConflictError,
|
|
118
|
-
UnprocessableEntityError,
|
|
119
144
|
RateLimitError,
|
|
145
|
+
BadRequestError,
|
|
146
|
+
RateLimitedError,
|
|
147
|
+
InvalidAPIKeyError,
|
|
148
|
+
AuthenticationError,
|
|
120
149
|
InternalServerError,
|
|
121
|
-
|
|
150
|
+
ObjectNotFoundError,
|
|
151
|
+
PrivateFeatureError,
|
|
152
|
+
PermissionDeniedError,
|
|
153
|
+
InvalidOperationError,
|
|
154
|
+
MalformedRequestError,
|
|
155
|
+
APIMethodNotFoundError,
|
|
156
|
+
InvalidParametersError,
|
|
157
|
+
UnprocessableEntityError,
|
|
158
|
+
EnvironmentMismatchError,
|
|
159
|
+
IdempotencyConflictError,
|
|
160
|
+
InsufficientPermissionsError,
|
|
161
|
+
IdempotencyUnprocessableError,
|
|
162
|
+
} = Errors;
|
|
122
163
|
|
|
123
164
|
export import fileFromPath = FileFromPath.fileFromPath;
|
|
124
165
|
|
|
@@ -142,9 +183,29 @@ export namespace Increase {
|
|
|
142
183
|
export import AccountNumberUpdateParams = API.AccountNumberUpdateParams;
|
|
143
184
|
export import AccountNumberListParams = API.AccountNumberListParams;
|
|
144
185
|
|
|
186
|
+
export import BookkeepingAccount = API.BookkeepingAccount;
|
|
187
|
+
export import BookkeepingAccountsPage = API.BookkeepingAccountsPage;
|
|
188
|
+
export import BookkeepingAccountCreateParams = API.BookkeepingAccountCreateParams;
|
|
189
|
+
export import BookkeepingAccountListParams = API.BookkeepingAccountListParams;
|
|
190
|
+
|
|
191
|
+
export import BookkeepingEntrySet = API.BookkeepingEntrySet;
|
|
192
|
+
export import BookkeepingEntrySetCreateParams = API.BookkeepingEntrySetCreateParams;
|
|
193
|
+
|
|
194
|
+
export import BookkeepingEntry = API.BookkeepingEntry;
|
|
195
|
+
export import BookkeepingEntriesPage = API.BookkeepingEntriesPage;
|
|
196
|
+
export import BookkeepingEntryListParams = API.BookkeepingEntryListParams;
|
|
197
|
+
|
|
145
198
|
export import RealTimeDecision = API.RealTimeDecision;
|
|
146
199
|
export import RealTimeDecisionActionParams = API.RealTimeDecisionActionParams;
|
|
147
200
|
|
|
201
|
+
export import RealTimePaymentsTransfer = API.RealTimePaymentsTransfer;
|
|
202
|
+
export import RealTimePaymentsTransfersPage = API.RealTimePaymentsTransfersPage;
|
|
203
|
+
export import RealTimePaymentsTransferCreateParams = API.RealTimePaymentsTransferCreateParams;
|
|
204
|
+
export import RealTimePaymentsTransferListParams = API.RealTimePaymentsTransferListParams;
|
|
205
|
+
|
|
206
|
+
export import BalanceLookupLookupResponse = API.BalanceLookupLookupResponse;
|
|
207
|
+
export import BalanceLookupLookupParams = API.BalanceLookupLookupParams;
|
|
208
|
+
|
|
148
209
|
export import Card = API.Card;
|
|
149
210
|
export import CardDetails = API.CardDetails;
|
|
150
211
|
export import CardsPage = API.CardsPage;
|
|
@@ -168,6 +229,11 @@ export namespace Increase {
|
|
|
168
229
|
export import ExternalAccountUpdateParams = API.ExternalAccountUpdateParams;
|
|
169
230
|
export import ExternalAccountListParams = API.ExternalAccountListParams;
|
|
170
231
|
|
|
232
|
+
export import Export = API.Export;
|
|
233
|
+
export import ExportsPage = API.ExportsPage;
|
|
234
|
+
export import ExportCreateParams = API.ExportCreateParams;
|
|
235
|
+
export import ExportListParams = API.ExportListParams;
|
|
236
|
+
|
|
171
237
|
export import DigitalWalletToken = API.DigitalWalletToken;
|
|
172
238
|
export import DigitalWalletTokensPage = API.DigitalWalletTokensPage;
|
|
173
239
|
export import DigitalWalletTokenListParams = API.DigitalWalletTokenListParams;
|
|
@@ -180,6 +246,10 @@ export namespace Increase {
|
|
|
180
246
|
export import PendingTransactionsPage = API.PendingTransactionsPage;
|
|
181
247
|
export import PendingTransactionListParams = API.PendingTransactionListParams;
|
|
182
248
|
|
|
249
|
+
export import Program = API.Program;
|
|
250
|
+
export import ProgramsPage = API.ProgramsPage;
|
|
251
|
+
export import ProgramListParams = API.ProgramListParams;
|
|
252
|
+
|
|
183
253
|
export import DeclinedTransaction = API.DeclinedTransaction;
|
|
184
254
|
export import DeclinedTransactionsPage = API.DeclinedTransactionsPage;
|
|
185
255
|
export import DeclinedTransactionListParams = API.DeclinedTransactionListParams;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "increase",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "Client library for the Increase API",
|
|
5
5
|
"author": "Increase <dev-feedback@increase.com>",
|
|
6
6
|
"types": "dist/cjs/index.d.ts",
|
|
@@ -30,12 +30,12 @@
|
|
|
30
30
|
"qs": "^6.10.3"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
+
"increase": "link:.",
|
|
33
34
|
"@types/jest": "^27.5.0",
|
|
34
35
|
"@typescript-eslint/eslint-plugin": "^5.33.0",
|
|
35
36
|
"@typescript-eslint/parser": "^5.33.0",
|
|
36
37
|
"eslint": "^8.22.0",
|
|
37
38
|
"eslint-plugin-unused-imports": "^2.0.0",
|
|
38
|
-
"increase": "link:.",
|
|
39
39
|
"jest": "^28.1.0",
|
|
40
40
|
"prettier": "rattrayalex/prettier#postfix-ternaries",
|
|
41
41
|
"ts-jest": "^28.0.2",
|
package/pagination.ts
CHANGED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
{
|
|
2
|
+
"packages": {
|
|
3
|
+
".": {}
|
|
4
|
+
},
|
|
5
|
+
"$schema": "https://raw.githubusercontent.com/stainless-api/release-please/main/schemas/config.json",
|
|
6
|
+
"include-v-in-tag": true,
|
|
7
|
+
"include-component-in-tag": false,
|
|
8
|
+
"bump-minor-pre-major": true,
|
|
9
|
+
"bump-patch-for-minor-pre-major": true,
|
|
10
|
+
"pull-request-header": "Automated Release PR",
|
|
11
|
+
"changelog-sections": [
|
|
12
|
+
{
|
|
13
|
+
"type": "feat",
|
|
14
|
+
"section": "Features"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"type": "fix",
|
|
18
|
+
"section": "Bug Fixes"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"type": "perf",
|
|
22
|
+
"section": "Performance Improvements"
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"type": "revert",
|
|
26
|
+
"section": "Reverts"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"type": "chore",
|
|
30
|
+
"section": "Chores"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"type": "docs",
|
|
34
|
+
"section": "Documentation"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"type": "style",
|
|
38
|
+
"section": "Styles"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"type": "refactor",
|
|
42
|
+
"section": "Refactors"
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"type": "test",
|
|
46
|
+
"section": "Tests",
|
|
47
|
+
"hidden": true
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"type": "build",
|
|
51
|
+
"section": "Build System"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"type": "ci",
|
|
55
|
+
"section": "Continuous Integration",
|
|
56
|
+
"hidden": true
|
|
57
|
+
}
|
|
58
|
+
],
|
|
59
|
+
"release-type": "node",
|
|
60
|
+
"extra-files": ["version.ts"]
|
|
61
|
+
}
|
|
@@ -46,7 +46,6 @@ export class AccountNumbers extends APIResource {
|
|
|
46
46
|
if (isRequestOptions(query)) {
|
|
47
47
|
return this.list({}, query);
|
|
48
48
|
}
|
|
49
|
-
|
|
50
49
|
return this.getAPIList('/account_numbers', AccountNumbersPage, { query, ...options });
|
|
51
50
|
}
|
|
52
51
|
}
|
|
@@ -134,8 +133,38 @@ export interface AccountNumberListParams extends PageParams {
|
|
|
134
133
|
*/
|
|
135
134
|
account_id?: string;
|
|
136
135
|
|
|
136
|
+
created_at?: AccountNumberListParams.CreatedAt;
|
|
137
|
+
|
|
137
138
|
/**
|
|
138
139
|
* The status to retrieve Account Numbers for.
|
|
139
140
|
*/
|
|
140
141
|
status?: 'active' | 'disabled' | 'canceled';
|
|
141
142
|
}
|
|
143
|
+
|
|
144
|
+
export namespace AccountNumberListParams {
|
|
145
|
+
export interface CreatedAt {
|
|
146
|
+
/**
|
|
147
|
+
* Return results after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
|
|
148
|
+
* timestamp.
|
|
149
|
+
*/
|
|
150
|
+
after?: string;
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* Return results before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
|
|
154
|
+
* timestamp.
|
|
155
|
+
*/
|
|
156
|
+
before?: string;
|
|
157
|
+
|
|
158
|
+
/**
|
|
159
|
+
* Return results on or after this
|
|
160
|
+
* [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
|
|
161
|
+
*/
|
|
162
|
+
on_or_after?: string;
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
* Return results on or before this
|
|
166
|
+
* [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
|
|
167
|
+
*/
|
|
168
|
+
on_or_before?: string;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
@@ -41,7 +41,6 @@ export class AccountTransfers extends APIResource {
|
|
|
41
41
|
if (isRequestOptions(query)) {
|
|
42
42
|
return this.list({}, query);
|
|
43
43
|
}
|
|
44
|
-
|
|
45
44
|
return this.getAPIList('/account_transfers', AccountTransfersPage, { query, ...options });
|
|
46
45
|
}
|
|
47
46
|
|
|
@@ -135,18 +134,7 @@ export interface AccountTransfer {
|
|
|
135
134
|
/**
|
|
136
135
|
* The lifecycle status of the transfer.
|
|
137
136
|
*/
|
|
138
|
-
status:
|
|
139
|
-
| 'pending_submission'
|
|
140
|
-
| 'pending_approval'
|
|
141
|
-
| 'canceled'
|
|
142
|
-
| 'requires_attention'
|
|
143
|
-
| 'flagged_by_operator'
|
|
144
|
-
| 'complete';
|
|
145
|
-
|
|
146
|
-
/**
|
|
147
|
-
* If the transfer was created from a template, this will be the template's ID.
|
|
148
|
-
*/
|
|
149
|
-
template_id: string | null;
|
|
137
|
+
status: 'pending_approval' | 'canceled' | 'complete';
|
|
150
138
|
|
|
151
139
|
/**
|
|
152
140
|
* The ID for the transaction funding the transfer.
|
|
@@ -161,20 +149,40 @@ export interface AccountTransfer {
|
|
|
161
149
|
}
|
|
162
150
|
|
|
163
151
|
export namespace AccountTransfer {
|
|
152
|
+
/**
|
|
153
|
+
* If your account requires approvals for transfers and the transfer was approved,
|
|
154
|
+
* this will contain details of the approval.
|
|
155
|
+
*/
|
|
164
156
|
export interface Approval {
|
|
165
157
|
/**
|
|
166
158
|
* The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
|
167
159
|
* the transfer was approved.
|
|
168
160
|
*/
|
|
169
161
|
approved_at: string;
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* If the Transfer was approved by a user in the dashboard, the email address of
|
|
165
|
+
* that user.
|
|
166
|
+
*/
|
|
167
|
+
approved_by: string | null;
|
|
170
168
|
}
|
|
171
169
|
|
|
170
|
+
/**
|
|
171
|
+
* If your account requires approvals for transfers and the transfer was not
|
|
172
|
+
* approved, this will contain details of the cancellation.
|
|
173
|
+
*/
|
|
172
174
|
export interface Cancellation {
|
|
173
175
|
/**
|
|
174
176
|
* The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
|
175
177
|
* the Transfer was canceled.
|
|
176
178
|
*/
|
|
177
179
|
canceled_at: string;
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* If the Transfer was canceled by a user in the dashboard, the email address of
|
|
183
|
+
* that user.
|
|
184
|
+
*/
|
|
185
|
+
canceled_by: string | null;
|
|
178
186
|
}
|
|
179
187
|
}
|
|
180
188
|
|
package/resources/accounts.ts
CHANGED
|
@@ -43,7 +43,6 @@ export class Accounts extends APIResource {
|
|
|
43
43
|
if (isRequestOptions(query)) {
|
|
44
44
|
return this.list({}, query);
|
|
45
45
|
}
|
|
46
|
-
|
|
47
46
|
return this.getAPIList('/accounts', AccountsPage, { query, ...options });
|
|
48
47
|
}
|
|
49
48
|
|
|
@@ -62,12 +61,6 @@ export class AccountsPage extends Page<Account> {}
|
|
|
62
61
|
* transfers, and send payments. They earn interest and have depository insurance.
|
|
63
62
|
*/
|
|
64
63
|
export interface Account {
|
|
65
|
-
/**
|
|
66
|
-
* The Account's balances in the minor unit of its currency. For dollars, for
|
|
67
|
-
* example, these values will represent cents.
|
|
68
|
-
*/
|
|
69
|
-
balances: Account.Balances;
|
|
70
|
-
|
|
71
64
|
/**
|
|
72
65
|
* The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time at which the Account
|
|
73
66
|
* was created.
|
|
@@ -108,6 +101,13 @@ export interface Account {
|
|
|
108
101
|
*/
|
|
109
102
|
interest_accrued_at: string | null;
|
|
110
103
|
|
|
104
|
+
/**
|
|
105
|
+
* The Interest Rate currently being earned on the account, as a string containing
|
|
106
|
+
* a decimal number. For example, a 1% interest rate would be represented as
|
|
107
|
+
* "0.01".
|
|
108
|
+
*/
|
|
109
|
+
interest_rate: string;
|
|
110
|
+
|
|
111
111
|
/**
|
|
112
112
|
* The name you choose for the Account.
|
|
113
113
|
*/
|
|
@@ -125,22 +125,6 @@ export interface Account {
|
|
|
125
125
|
type: 'account';
|
|
126
126
|
}
|
|
127
127
|
|
|
128
|
-
export namespace Account {
|
|
129
|
-
export interface Balances {
|
|
130
|
-
/**
|
|
131
|
-
* The Account's available balance, representing the current balance less any open
|
|
132
|
-
* Pending Transactions on the Account.
|
|
133
|
-
*/
|
|
134
|
-
available_balance: number;
|
|
135
|
-
|
|
136
|
-
/**
|
|
137
|
-
* The Account's current balance, representing the sum of all posted Transactions
|
|
138
|
-
* on the Account.
|
|
139
|
-
*/
|
|
140
|
-
current_balance: number;
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
|
|
144
128
|
export interface AccountCreateParams {
|
|
145
129
|
/**
|
|
146
130
|
* The name you choose for the Account.
|
|
@@ -157,6 +141,12 @@ export interface AccountCreateParams {
|
|
|
157
141
|
* with its activity. Its relationship to your group must be `informational`.
|
|
158
142
|
*/
|
|
159
143
|
informational_entity_id?: string;
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* The identifier for the Program that this Account falls under. Required if you
|
|
147
|
+
* operate more than one Program.
|
|
148
|
+
*/
|
|
149
|
+
program_id?: string;
|
|
160
150
|
}
|
|
161
151
|
|
|
162
152
|
export interface AccountUpdateParams {
|
|
@@ -167,13 +157,48 @@ export interface AccountUpdateParams {
|
|
|
167
157
|
}
|
|
168
158
|
|
|
169
159
|
export interface AccountListParams extends PageParams {
|
|
160
|
+
created_at?: AccountListParams.CreatedAt;
|
|
161
|
+
|
|
170
162
|
/**
|
|
171
163
|
* Filter Accounts for those belonging to the specified Entity.
|
|
172
164
|
*/
|
|
173
165
|
entity_id?: string;
|
|
174
166
|
|
|
167
|
+
/**
|
|
168
|
+
* Filter Accounts for those belonging to the specified Entity as informational.
|
|
169
|
+
*/
|
|
170
|
+
informational_entity_id?: string;
|
|
171
|
+
|
|
175
172
|
/**
|
|
176
173
|
* Filter Accounts for those with the specified status.
|
|
177
174
|
*/
|
|
178
175
|
status?: 'open' | 'closed';
|
|
179
176
|
}
|
|
177
|
+
|
|
178
|
+
export namespace AccountListParams {
|
|
179
|
+
export interface CreatedAt {
|
|
180
|
+
/**
|
|
181
|
+
* Return results after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
|
|
182
|
+
* timestamp.
|
|
183
|
+
*/
|
|
184
|
+
after?: string;
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Return results before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
|
|
188
|
+
* timestamp.
|
|
189
|
+
*/
|
|
190
|
+
before?: string;
|
|
191
|
+
|
|
192
|
+
/**
|
|
193
|
+
* Return results on or after this
|
|
194
|
+
* [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
|
|
195
|
+
*/
|
|
196
|
+
on_or_after?: string;
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* Return results on or before this
|
|
200
|
+
* [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
|
|
201
|
+
*/
|
|
202
|
+
on_or_before?: string;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
@@ -41,7 +41,6 @@ export class ACHPrenotifications extends APIResource {
|
|
|
41
41
|
if (isRequestOptions(query)) {
|
|
42
42
|
return this.list({}, query);
|
|
43
43
|
}
|
|
44
|
-
|
|
45
44
|
return this.getAPIList('/ach_prenotifications', ACHPrenotificationsPage, { query, ...options });
|
|
46
45
|
}
|
|
47
46
|
}
|
|
@@ -127,6 +126,9 @@ export interface ACHPrenotification {
|
|
|
127
126
|
}
|
|
128
127
|
|
|
129
128
|
export namespace ACHPrenotification {
|
|
129
|
+
/**
|
|
130
|
+
* If your prenotification is returned, this will contain details of the return.
|
|
131
|
+
*/
|
|
130
132
|
export interface PrenotificationReturn {
|
|
131
133
|
/**
|
|
132
134
|
* The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|