services

package
v0.0.1-alpha-albatross... Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 4, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ImportStatement

func ImportStatement(filename string, statement string, accountID uint) (result *models.ImportSubmission, err error)

Types

type AccountNameAndID

type AccountNameAndID struct {
	AccountName string
	AccountID   uint
}

func GetAccountNamesAndIDs

func GetAccountNamesAndIDs() (result []AccountNameAndID, err error)

type AccountNotFoundError

type AccountNotFoundError struct {
	AccountID uint
}

func (*AccountNotFoundError) Error

func (a *AccountNotFoundError) Error() string

type BankOfAmericaCreditCardCSVParser

type BankOfAmericaCreditCardCSVParser struct{}

func (BankOfAmericaCreditCardCSVParser) Parse

func (BankOfAmericaCreditCardCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 0th column, description in 2nd column, and amount in 4th column

type CapitalOneCredictCardCSVParser

type CapitalOneCredictCardCSVParser struct{}

func (CapitalOneCredictCardCSVParser) Parse

func (s CapitalOneCredictCardCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 0th column, description in 3rd column, category in 4th column, debits (purchases) in 5th column, credit (payments/refunds) amount in 6th column

type CapitalOneSavingsCSVParser

type CapitalOneSavingsCSVParser struct{}

func (CapitalOneSavingsCSVParser) Parse

func (s CapitalOneSavingsCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, description in 1st column, date in 2nd column, transaction type (credit vs debit) in 3rd column, amount in 4th column, and balance in 5th column. Transactions are sorted by newest transaction first, so the balance is the first row after the header

type ChaseCheckingCSVParser

type ChaseCheckingCSVParser struct{}

func (ChaseCheckingCSVParser) Parse

func (ChaseCheckingCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 1st column, description in 2nd column, and amount in 3rd column

type ChaseCreditCardCSVParser

type ChaseCreditCardCSVParser struct{}

func (ChaseCreditCardCSVParser) Parse

func (s ChaseCreditCardCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 0th column, description in 2nd column, and amount in 4th column

type FidelityBrokerageCSVParser

type FidelityBrokerageCSVParser struct{}

func (FidelityBrokerageCSVParser) Parse

func (FidelityBrokerageCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 2nd row, date in 0th column, description in 1st column, amount in 10th column, and balance in 11th column Transactions are sorted by newest transaction first, so the balance is the first row after the header

type FidelityCreditCardCSVParser

type FidelityCreditCardCSVParser struct{}

func (FidelityCreditCardCSVParser) Parse

func (FidelityCreditCardCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 0th column, description in 2nd column, and amount in 4th column

type GeneralCSVParser

type GeneralCSVParser struct{}

func (GeneralCSVParser) Parse

func (g GeneralCSVParser) Parse(statement string, dateCol int, descCol int, amountCol int, skipHeader bool, skipRecordLengthValidation bool) (transactions []models.Transaction, balances []models.Balance, err error)

type NoParserError

type NoParserError struct{}

func (*NoParserError) Error

func (*NoParserError) Error() string

type Parser

type Parser interface {
	Parse(string) ([]models.Transaction, []models.Balance, error)
}

type SchwabBrokerageCSVParser

type SchwabBrokerageCSVParser struct{}

func (SchwabBrokerageCSVParser) Parse

func (s SchwabBrokerageCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 0th column, action in 1st column, symbol in 2nd column, description in 3rd column, amount in 7th column,

type SchwabCheckingCSVParser

type SchwabCheckingCSVParser struct{}

func (SchwabCheckingCSVParser) Parse

func (s SchwabCheckingCSVParser) Parse(statement string) (transactions []models.Transaction, balances []models.Balance, err error)

Parses CSVs with the header as the 1st row, date in 0th column, description in 4th column, withdrawal amount in 5th column, deposit Amount in 6th column, and running balance in 7th column

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL