From 1bb5009d003fbe76acbc4e2366a629e67ef79750 Mon Sep 17 00:00:00 2001 From: Gabriel Pan Gantes Date: Thu, 16 Jan 2025 15:24:30 +0100 Subject: [PATCH] fix: missing types from account & transactions --- src/types/account.ts | 10 ++++++++++ src/types/transaction.ts | 19 +++++++++++++++++++ 2 files changed, 29 insertions(+) diff --git a/src/types/account.ts b/src/types/account.ts index d060c5c..c0c8776 100644 --- a/src/types/account.ts +++ b/src/types/account.ts @@ -50,6 +50,10 @@ export type BankData = { closingBalance: number | null /** Automatically invested balance */ automaticallyInvestedBalance: number | null + /** Overdraft used limit */ + overdraftUsedLimit: number | null + /** Unarranged overdraft amount */ + unarrangedOverdraftAmount: number | null } export type CreditData = { @@ -69,4 +73,10 @@ export type CreditData = { minimumPayment: number | null /** Maximum credit card limit. */ creditLimit: number | null + /** If the credit card limit is flexible. */ + isLimitFlexible: boolean | null + /** Credit card status. */ + status: 'ACTIVE' | 'BLOCKED' | 'CANCELLED' | null + /** Credit card holder type. */ + holderType: 'MAIN' | 'ADDITIONAL' | null } diff --git a/src/types/transaction.ts b/src/types/transaction.ts index 6733fd1..980736b 100644 --- a/src/types/transaction.ts +++ b/src/types/transaction.ts @@ -34,6 +34,21 @@ export type TransactionPaymentParticipant = { routingNumber?: string } +export type TransactionBoletoMetadataResponse = { + /** Digitable line of the boleto */ + digitableLine: string | null + /** Barcode of the boleto */ + barcode: string | null + /** Base amount of the boleto */ + baseAmount: number | null + /** Penalty amount of the boleto */ + penaltyAmount: number | null + /** Interest amount of the boleto */ + interestAmount: number | null + /** Discount amount of the boleto */ + discountAmount: number | null +} + export type TransactionPaymentData = { /** The identity of the sender of the transfer */ payer?: TransactionPaymentParticipant @@ -51,6 +66,8 @@ export type TransactionPaymentData = { referenceNumber?: string /** The payer description / motive of the transfer */ reason?: string + /** Additional data related to boleto transaction */ + boletoMetadata: TransactionBoletoMetadataResponse | null } export type TransactionMerchantData = { @@ -121,4 +138,6 @@ export type Transaction = { merchant?: TransactionMerchantData /** Category ID of the transaction */ categoryId: string | null + /** Operation type of the transaction */ + operationType: string | null }