Documentation
¶
Index ¶
- type Account
- type AccountAttributes
- type Firefly
- func (f *Firefly) CreateTransactions(ctx context.Context, tx *Transaction, errorOnDuplicate bool) (*Transaction, error)
- func (f *Firefly) ListAccounts(ctx context.Context) ([]*Account, error)
- func (f *Firefly) MapTransactions(ctx context.Context, transactions []*database.Transaction) ([]*MappedTransaction, error)
- type GenericApiResponse
- type MappedTransaction
- type Transaction
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { Id string `json:"id"` Attributes AccountAttributes `json:"attributes"` }
type AccountAttributes ¶
type Firefly ¶
type Firefly struct {
// contains filtered or unexported fields
}
func NewFirefly ¶
func (*Firefly) CreateTransactions ¶
func (f *Firefly) CreateTransactions( ctx context.Context, tx *Transaction, errorOnDuplicate bool, ) (*Transaction, error)
func (*Firefly) ListAccounts ¶
func (*Firefly) MapTransactions ¶
func (f *Firefly) MapTransactions( ctx context.Context, transactions []*database.Transaction, ) ([]*MappedTransaction, error)
type GenericApiResponse ¶
type GenericApiResponse[T any] struct { Data T `json:"data"` }
type MappedTransaction ¶
type MappedTransaction struct { Original *database.Transaction Transaction *Transaction Error error IsCommitted bool }
type Transaction ¶
type Transaction struct { Type string `json:"type"` Date string `json:"date"` Amount string `json:"amount"` Description string `json:"description"` CurrencyCode string `json:"currency_code"` SourceID string `json:"source_id"` SourceName string `json:"-"` DestinationID string `json:"destination_id,omitempty"` DestinationName string `json:"-"` Notes string `json:"notes"` ForeignAmount string `json:"foreign_amount,omitempty"` ForeignCurrencyCode string `json:"foreign_currency_code,omitempty"` }
Click to show internal directories.
Click to hide internal directories.