finalynx.budget.source_n26

Module Contents

Classes

SourceN26

Fetch expenses from N26

API

class finalynx.budget.source_n26.SourceN26(force_signin: bool = False, fetch_limit: int = 100, cache_validity: int = 12)[source]

Bases: finalynx.budget.source_base_expense.SourceBaseExpense

Fetch expenses from N26

Initialization

Initialize the N26 client with the credentials.

_authenticate() Optional[n26.config.Config][source]

Internal method used to signin and retrieve a session from Finary. Called by _fetch_data once, only exists for better logic separation.

Returns:

A session for fetching data if everything worked, None otherwise.

_fetch_data(tree: rich.tree.Tree) None[source]

Abstract method, must be averridden by children classes. This method retrieves the data from the source, and calls _register_fetchline to create a FetchLine instance representing each fetched investment.