diff --git a/.github/workflows/publish-pypi.yml b/.github/workflows/publish-pypi.yml index 06782645..48070222 100644 --- a/.github/workflows/publish-pypi.yml +++ b/.github/workflows/publish-pypi.yml @@ -31,13 +31,13 @@ jobs: - name: Pytest run: uv run pytest - name: Ruff check - run: uv run ruff check + run: uvx ruff@0.9.6 check - name: Ruff format - run: uv run ruff format --check --diff + run: uvx ruff@0.9.6 format --check --diff - name: Mypy type check run: uv run mypy . - name: Check if README.md automatically generated content is up to date - run: diff -u <(cat README.md | sed -z '$s/\n*$//') <(uvx mksync@0.1.5 README.md | sed -z '$s/\n*$//') + run: diff -u <(printf '%s\n' "$(cat README.md)") <(printf '%s\n' "$(uvx mksync@0.1.5 README.md)") build-n-publish: name: Build and publish Python distributions to PyPI diff --git a/README.md b/README.md index 8cf44c84..05ab5e0a 100644 --- a/README.md +++ b/README.md @@ -12,9 +12,11 @@ __Table of Contents__ * [Quickstart](#quickstart) * [Usage](#usage) +* [GUI (Windows)](#gui-windows) * [Authentication](#authentication) - * [Web login (default)](#web-login-default) - * [App login](#app-login) + * [Web login](#web-login) + * [If web login suddenly stops working](#if-web-login-suddenly-stops-working) + * [Other accounts of your login](#other-accounts-of-your-login) * [Development](#development) * [Setting Up a Development Environment](#setting-up-a-development-environment) * [Linting and Code Formatting](#linting-and-code-formatting) @@ -62,17 +64,20 @@ If you want to use the cutting-edge version, use this command instead: ```console usage: pytr [-h] [-V] [-v {warning,info,debug}] [--debug-logfile DEBUG_LOGFILE] [--debug-log-filter DEBUG_LOG_FILTER] - {help,login,portfolio,details,dl_docs,export_transactions,get_price_alarms,set_price_alarms,get_savings_plans,completion} ... + {help,login,accounts,portfolio,rates,details,dl_docs,export_transactions,get_price_alarms,set_price_alarms,get_savings_plans,completion} ... Use "pytr command_name --help" to get detailed help to a specific command Commands: - {help,login,portfolio,details,dl_docs,export_transactions,get_price_alarms,set_price_alarms,get_savings_plans,completion} + {help,login,accounts,portfolio,rates,details,dl_docs,export_transactions,get_price_alarms,set_price_alarms,get_savings_plans,completion} Desired action to perform help Print this help message login Check if credentials file exists. If not create it and ask for input. Try to login. Ask for device reset if needed + accounts List accounts of this login, e.g. a company accounts or child accounts. Use them + with --account portfolio Show current portfolio + rates Fetch current prices for a list of ISINs given as direct list or CSV input details Get details for an ISIN dl_docs Download all pdf documents from the timeline and sort them into folders. Also export account transactions (account_transactions.csv) and JSON files with all @@ -93,30 +98,78 @@ Options: ``` +## GUI (Windows) + +A Windows desktop interface that exposes all pytr functionality without the command line. +It requires the same Python installation and dependencies as the CLI. + +After installing (see [Quickstart](#quickstart)), run: + +```sh +pytr-gui +``` + ## Authentication -There are two authentication methods: +### Web login + +Web login uses the public web-login endpoints at `api.traderepublic.com`. Two variants are available: + +- **v1 (default)**: `pytr login`. You receive a four-digit code in the TradeRepublic app (or via SMS as a + fallback) and enter it in the terminal. This is the original behavior; nothing changes for existing users. + v1 requires passing an AWS WAF token with the login request; by default pytr fetches one automatically + via Playwright (requires the optional `playwright` extra: `pip install 'pytr[playwright]' && playwright install chromium`). + The pure-Python alternative `--waf-token awswaf` exists but has been reported to no longer work reliably. +- **v2 (opt-in)**: `pytr login --v2`. Mirrors what + [app.traderepublic.com](https://app.traderepublic.com/) currently does. Instead of typing a four-digit code, you + confirm the login from a push notification in the Trade Republic mobile app. Accounts secured with an authenticator + app are asked for a code from that app instead. Useful if your account no longer issues a code via the app or SMS. + v2 does not require a WAF token; pytr skips it automatically when `--v2` is used. + Note that Trade Republic removed the SMS resend endpoint along with the v1 web login, so there is no SMS fallback + under `--v2`. The flag is available on every subcommand that performs a login, e.g. `pytr portfolio --v2`, + `pytr dl_docs --v2`. -### Web login (default) +Both variants keep you logged in on your primary device, but you may need to re-authenticate every so often when +running `pytr`. -Web login is the newer method that uses the same login method as [app.traderepublic.com](https://app.traderepublic.com/), -meaning you receive a four-digit code in the TradeRepublic app or via SMS. This will keep you logged in your primary -device, but means that you may need to repeat entering a new four-digit code ever so often when runnnig `pytr`. +### If web login suddenly stops working -### App login +The web login identifies itself to Trade Republic as their own web frontend, using a build version, a platform name +and a browser `User-Agent` that are pinned in `pytr`. Trade Republic can invalidate any of them at any time, and when +they do, login fails for everyone until a new release goes out. Three environment variables let you fix it yourself +in the meantime: -App login is the older method that uses the same login method as the TradeRepublic app. First you need to perform a -device reset - a private key will be generated that pins your "device". The private key is saved to your keyfile. This -procedure will log you out from your mobile device. +| Variable | Overrides | Use it when | +|---|---|---| +| `PYTR_TR_APP_VERSION` | The frontend build version sent as `X-TR-App-Version` | Login fails with `426 CLIENT_VERSION_OUTDATED` | +| `PYTR_TR_USER_AGENT` | The `User-Agent` sent on every request | Login is rejected or challenged in a way that looks like bot filtering | +| `PYTR_TR_PLATFORM` | The platform name sent as `X-Tr-Platform` | Login fails with a missing or invalid header error naming the platform | ```sh - pytr login - # or - pytr login --phone_no +49123456789 --pin 1234 + PYTR_TR_APP_VERSION=2.2700.4 pytr login --v2 + PYTR_TR_USER_AGENT='Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/149.0.0.0 Safari/537.36' pytr login + PYTR_TR_PLATFORM=web pytr login --v2 ``` -If no arguments are supplied pytr will look for them in the file `~/.pytr/credentials` (the first line must contain -the phone number, the second line the pin). If the file doesn't exist pytr will ask for for the phone number and pin. +Read the current values off [app.traderepublic.com](https://app.traderepublic.com/) in your browser's dev tools, on the +network request to `/api/v2/auth/web/login`. Leaving a variable unset, or setting it to an empty string, keeps the +built-in default. If you need one of these, please also open an issue so the default can be updated for everyone. + +### Other accounts of your login + +A Trade Republic login can hold more than its own account, e.g. company accounts or child accounts. Trade Republic +treats each of them as a customer of its own, and the web app switches between them after the login. Pass `--account` +to do the same, on any subcommand that performs a login: + +```sh +pytr portfolio --account LEGAL_ENTITY +pytr dl_docs --account "Mustermann Holding GmbH" ./docs +``` + +The value is the account's type, its name or its customer id, as listed by `pytr accounts`. Without `--account`, +pytr uses your own account. The choice is not remembered between runs. + +Unfortunately, it seems that this only works with company accounts, not with child accounts at the moment. ## Development diff --git a/conftest.py b/conftest.py new file mode 100644 index 00000000..ccdb6324 --- /dev/null +++ b/conftest.py @@ -0,0 +1,19 @@ +import pytest + +import pytr.utils as pytr_utils + + +@pytest.fixture(autouse=True) +def suppress_info_logs(monkeypatch): + # pytr loggers call coloredlogs.install(level=log_level, ...) with propagate=False, + # bypassing pytest's capture. Setting log_level to "warning" before tests run + # makes all subsequently created loggers install at WARNING level. + monkeypatch.setattr(pytr_utils, "log_level", "warning") + # Also raise the level on handlers already installed on existing loggers. + import logging + + for lg in logging.root.manager.loggerDict.values(): + if isinstance(lg, logging.Logger): + for handler in lg.handlers: + handler.setLevel(logging.WARNING) + yield diff --git a/pyproject.toml b/pyproject.toml index a50b9b1c..2b1ffb67 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "pytr" -version = "0.4.10" +version = "0.4.11" description = "Use TradeRepublic in terminal" readme = "README.md" requires-python = ">=3.10" @@ -29,27 +29,39 @@ dependencies = [ "curl_cffi", "packaging", "pathvalidate", - "playwright", "pygments", + "reportlab", "requests_futures", "shtab", "websockets>=14", ] +[project.optional-dependencies] +# Only `--waf-token playwright` (the CLI default) needs this, and it drags in a +# ~130 MB package plus a ~630 MB Chromium download that `playwright install` +# fetches separately. The pure-Python `--waf-token awswaf` path solves the same +# challenge without either, so deployments that use it — or that find their IP +# is not challenged at all — should not have to carry the browser. +playwright = [ + "playwright>=1.62.0", +] + [project.scripts] pytr = "pytr.main:main" +pytr-gui = "pytr.gui:main" [tool.hatch.build.hooks.babel] locale_dir = "pytr/locale" [dependency-groups] dev = [ - "ruff>=0.9.4", + "ruff==0.9.6", "pytest>=8.3.4", "mypy>=1.15.0", "types-babel>=2.11.0.15", - "types-requests>=2.32.0.20241016", "types-pygments>=2.19.0.20250107", + "types-reportlab", + "types-requests>=2.32.0.20241016", ] [tool.ruff] diff --git a/pytr/account.py b/pytr/account.py index 5f688547..b5203fe4 100644 --- a/pytr/account.py +++ b/pytr/account.py @@ -1,11 +1,13 @@ import json +import os import sys import time from getpass import getpass +import requests from pygments import formatters, highlight, lexers -from .api import BASE_DIR, CREDENTIALS_FILE, TradeRepublicApi +from .api import BASE_DIR, CREDENTIALS_FILE, TradeRepublicApi, account_kind, account_name from .utils import get_logger @@ -18,10 +20,34 @@ def get_settings(tr): return formatted_json -def login(phone_no=None, pin=None, store_credentials=False, waf_token="playwright"): +def print_accounts(tr): + """List the accounts of this login, one per line: type, name, customer id and state. + + `--account` takes the type, the name or, where those are not unique, the customer id. + """ + rows = [ + ( + account_kind(r), + account_name(r), + str(r.get("customerId") or ""), + "your own account" if r.get("relationshipType") == "SELF" else str(r.get("accountState") or ""), + ) + for r in tr.relationships() + ] + if not rows: + return "" + heading = ("TYPE", "NAME", "CUSTOMER ID", "STATE") + widths = [max(len(heading[i]), max(len(row[i]) for row in rows)) for i in range(4)] + all_rows = [heading] + rows + return "\n".join(" ".join(f"{cell:<{width}}" for cell, width in zip(row, widths)).rstrip() for row in all_rows) + + +def login(phone_no=None, pin=None, store_credentials=False, waf_token="playwright", v2=False, account=None): """ Handle credentials parameters and store to credentials file if requested. If no parameters are set but are needed then ask for input + + `account` selects another account of this login, e.g. a company account. """ log = get_logger(__name__) save_cookies = True @@ -47,12 +73,13 @@ def login(phone_no=None, pin=None, store_credentials=False, waf_token="playwrigh if store_credentials: with open(CREDENTIALS_FILE, "w") as f: f.writelines([phone_no + "\n", pin + "\n"]) + os.chmod(CREDENTIALS_FILE, 0o600) log.info(f"Storing credentials/cookies in {BASE_DIR}") else: save_cookies = False - tr = TradeRepublicApi(phone_no=phone_no, pin=pin, save_cookies=save_cookies, waf_token=waf_token) + tr = TradeRepublicApi(phone_no=phone_no, pin=pin, save_cookies=save_cookies, waf_token=waf_token, use_v2_login=v2) # Use same login as app.traderepublic.com if not tr.resume_websession(): @@ -62,22 +89,40 @@ def login(phone_no=None, pin=None, store_credentials=False, waf_token="playwrigh log.fatal(str(e)) sys.exit(1) request_time = time.time() - print("Enter the code you received to your mobile app as a notification.") - print(f"Enter nothing if you want to receive the (same) code as SMS. (Countdown: {countdown})") - code = input("Code: ") - if code == "": - countdown = countdown - (time.time() - request_time) - for remaining in range(int(countdown)): - print( - f"Need to wait {int(countdown - remaining)} seconds before requesting SMS...", - end="\r", - ) - time.sleep(1) - print() - tr.resend_weblogin() - code = input("SMS requested. Enter the confirmation code:") + if v2: + if tr.weblogin_needs_authenticator: + code = input("Enter the code from your authenticator app: ") + else: + print(f"Confirm the login in your Trade Republic app. (Countdown: {countdown})") + code = None + else: + print("Enter the code you received to your mobile app as a notification.") + print(f"Enter nothing if you want to receive the (same) code as SMS. (Countdown: {countdown})") + code = input("Code: ") + if code == "": + countdown = countdown - (time.time() - request_time) + for remaining in range(int(countdown)): + print( + f"Need to wait {int(countdown - remaining)} seconds before requesting SMS...", + end="\r", + ) + time.sleep(1) + print() + tr.resend_weblogin() + code = input("SMS requested. Enter the confirmation code:") tr.complete_weblogin(code) log.info("Logged in.") log.debug(get_settings(tr)) + + if account is not None: + try: + tr.switch_account(account) + except ValueError as e: + log.fatal(str(e)) + sys.exit(1) + except requests.exceptions.HTTPError as e: + status = e.response.status_code if e.response is not None else "unknown" + log.fatal(f"Trade Republic refused to switch to account {account!r} (status {status}).") + sys.exit(1) return tr diff --git a/pytr/api.py b/pytr/api.py index 82af5013..d1ad49b3 100644 --- a/pytr/api.py +++ b/pytr/api.py @@ -21,14 +21,19 @@ # SOFTWARE. import asyncio +import base64 +import hashlib import json +import os import pathlib +import platform import re import ssl -import subprocess import time import urllib.parse import uuid +from collections import deque +from datetime import datetime from http.cookiejar import Cookie, MozillaCookieJar from typing import Any, Dict @@ -36,25 +41,105 @@ import requests import websockets from curl_cffi import requests as cffi_requests -from playwright.sync_api import sync_playwright -from pytr.awswaf.aws import AwsWaf from pytr.utils import get_logger +# `playwright` and `pytr.awswaf` are imported lazily inside the two +# `_fetch_waf_token_*` methods, not here. Both are only reachable when the +# caller asks for that specific WAF strategy, and importing them at module +# level made every consumer pay for them unconditionally: +# - `playwright` is an optional extra (see pyproject). A module-level import +# makes `import pytr.api` fail outright when it is not installed, which +# would defeat the point of making it optional. +# - `pytr.awswaf` reaches the network and reads `webgl.json` from disk at +# import time (`awswaf/fingerprint.py`). Deferring the import means a +# deployment that never selects `waf_token="awswaf"` neither performs that +# file IO nor carries the code in a hot import path. + home = pathlib.Path.home() BASE_DIR = home / ".pytr" CREDENTIALS_FILE = BASE_DIR / "credentials" COOKIES_FILE = BASE_DIR / "cookies.txt" +# Hosts that `_fetch_waf_token_awswaf` is allowed to talk to. The challenge +# endpoint is scraped out of the login page with a regular expression, so +# whatever `app.traderepublic.com` serves decides where the follow-up requests +# for `/inputs` and `/verify` go — that is a server-side request forgery +# primitive if left unchecked. AWS serves WAF challenge tokens exclusively from +# `*.token.awswaf.com`, so pinning the suffix costs nothing and removes the +# primitive. Comparison is on the parsed host, never on the raw URL string. +_AWSWAF_ALLOWED_HOST_SUFFIX = ".token.awswaf.com" + +# errorCodes the v2 login process can answer with, mapped to readable messages. +LOGIN_ERRORS = { + "PROCESS_GONE": "The login request expired. Please start again.", + "ALREADY_PROCESSED": "The login request was rejected or has already been used.", + "NOT_FOUND": "Trade Republic does not know this login request.", + "TOO_MANY_REQUESTS": "Too many attempts. Please wait before trying again.", + "VALIDATION_CODE_INVALID": "That authenticator code is not correct.", + "VALIDATION_CODE_ALREADY_USED": "That authenticator code was already used.", +} + +# Build version of the web frontend. Sent on every api/v2 login call. +# Moves with each frontend deployment; bump when TR starts rejecting stale versions. +APP_VERSION = "2.2631.13" + +# The web frontend's API client identifies itself with this platform on all v2 login calls. +WEB_PLATFORM = "web-pro" + +# Sent on every request. Trade Republic can start rejecting a stale one as bot traffic. +USER_AGENT = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36" + +# Trade Republic can invalidate any of the three values above at any time, and none of +# those failures needs a code change to fix, only a different string. Overriding them +# from the environment turns "wait for a pytr release" into "export a variable" for a +# user who is locked out today. See the README for when to reach for which. An unset or +# empty variable keeps the built-in default, so an empty assignment sends no empty header. +ENV_APP_VERSION = "PYTR_TR_APP_VERSION" +ENV_PLATFORM = "PYTR_TR_PLATFORM" +ENV_USER_AGENT = "PYTR_TR_USER_AGENT" + + +# Seconds after which the web session is refreshed. +SESSION_REFRESH_INTERVAL = 290 + + +def account_kind(relationship): + """The kind of account behind an entry of `relationships()`, e.g. `ADULT` or `LEGAL_ENTITY`.""" + return str(relationship.get("accountType") or relationship.get("relationshipType") or "UNKNOWN") + + +def account_name(relationship): + """The name of the account behind an entry of `relationships()`: the account's, else the person's.""" + person = [str(part) for part in (relationship.get("firstName"), relationship.get("lastName")) if part] + return str(relationship.get("accountName") or " ".join(person)) + + +def _account_selectors(relationship): + """Everything an entry of `relationships()` can be selected by, lower-cased.""" + selectors = [ + relationship.get("customerId"), + relationship.get("relationshipType"), + relationship.get("accountType"), + relationship.get("firstName"), + account_name(relationship), + ] + return {str(selector).strip().casefold() for selector in selectors if selector and str(selector).strip()} + + +def _describe_account(relationship): + name = account_name(relationship) + return f"{account_kind(relationship)} ({name})" if name else account_kind(relationship) + class TradeRepublicApi: - _default_headers = { - "User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36" - } + _default_headers = {"User-Agent": os.environ.get(ENV_USER_AGENT) or USER_AGENT} _host = "https://api.traderepublic.com" _waf_login_url = "https://app.traderepublic.com/login" _process_id = None + _required_action = None + _device_info = None _session_expires_at = 0 _ws = None @@ -74,12 +159,16 @@ def __init__( save_cookies=False, credentials_file=None, cookies_file=None, - waf_token="playwright", + use_v2_login=False, + waf_token="default", ): self.log = get_logger(__name__) self._locale = locale self._save_cookies = save_cookies + self._use_v2_login = use_v2_login self._waf_token = waf_token + if self._waf_token == "default": + self._waf_token = None if self._use_v2_login else "playwright" self._credentials_file = pathlib.Path(credentials_file) if credentials_file else CREDENTIALS_FILE @@ -102,12 +191,18 @@ def __init__( if self._save_cookies: self._websession.cookies = MozillaCookieJar(self._cookies_file) self._sec_acc_no: str | None = None + # Customer id of the account the session acts for, once it is not the login's own. + self._subject_id: str | None = None + # Messages read off the websocket on behalf of a caller that has not asked for them yet. + self._held_back: deque = deque() def _fetch_waf_token_awswaf(self): """ Get the AWS WAF token, using the awswaf library. """ + from pytr.awswaf.aws import AwsWaf + self.log.info("Retrieving AWS WAF token using awswaf...") try: session = cffi_requests.Session(impersonate="chrome") @@ -117,6 +212,16 @@ def _fetch_waf_token_awswaf(self): self.log.warning("AWS WAF token not acquired. challenge.js URL not found in login page.") return None challenge_js_url = m.group(1) + # The URL above came out of a regular expression over whatever the + # login page returned, and everything below turns it into outbound + # requests. Check the host before the first of them, not after. + host = urllib.parse.urlparse(challenge_js_url).hostname or "" + if not host.lower().endswith(_AWSWAF_ALLOWED_HOST_SUFFIX): + self.log.warning( + "AWS WAF token not acquired. challenge.js host is not an AWS WAF endpoint (expected *%s).", + _AWSWAF_ALLOWED_HOST_SUFFIX, + ) + return None waf_endpoint = challenge_js_url.split("https://", 1)[1].rsplit("/challenge.js", 1)[0] challenge_js = session.get(challenge_js_url).text token = AwsWaf(waf_endpoint, "app.traderepublic.com", challenge_js)() @@ -132,52 +237,64 @@ def _fetch_waf_token_playwright(self, timeout_ms: int = 30000): """ Get the AWS WAF token, using a Playwright browser session. - One-time setup needed: - playwright install chromium + Requires the optional `playwright` extra plus its browser binary: + pip install 'pytr[playwright]' && playwright install chromium + + Neither is installed automatically. An earlier version of this method + caught *every* exception — a network blip, a WAF change, a timeout — + and answered it by shelling out to `playwright install chromium`, i.e. + by downloading and executing a browser at runtime, in the process that + is holding the user's PIN and Trade Republic cookies. That download + bypasses whatever pinning the installing environment applied to its + dependencies, and it only ever helped for one of the many failures it + was triggered by. A missing browser is now reported like any other + failure and left to the operator to fix deliberately. """ + try: + from playwright.sync_api import sync_playwright # type: ignore[import-not-found] + except ImportError: + raise ValueError( + "playwright is not installed. " + "Install the optional extra with `pip install 'pytr[playwright]'` " + "and then run `playwright install chromium`. " + "Alternatively, use --v2 which does not require a WAF token." + ) from None self.log.info("Retrieving AWS WAF token using Playwright...") - called_playwright_install = False - while True: - try: - with sync_playwright() as p: - browser = p.chromium.launch( - headless=True, - args=["--no-sandbox", "--disable-setuid-sandbox"], - ) - context = browser.new_context() - page = context.new_page() - page.goto( - "https://app.traderepublic.com/login", - wait_until="domcontentloaded", - timeout=timeout_ms, - ) - deadline = time.time() + timeout_ms / 1000 - token = None - while time.time() < deadline: - for c in context.cookies(): - if c["name"] == "aws-waf-token": - token = c["value"] - break - if token: + try: + with sync_playwright() as p: + browser = p.chromium.launch( + headless=True, + args=["--no-sandbox", "--disable-setuid-sandbox"], + ) + context = browser.new_context() + page = context.new_page() + page.goto( + "https://app.traderepublic.com/login", + wait_until="domcontentloaded", + timeout=timeout_ms, + ) + deadline = time.time() + timeout_ms / 1000 + token = None + while time.time() < deadline: + for c in context.cookies(): + if c["name"] == "aws-waf-token": + token = c["value"] break - time.sleep(0.5) - browser.close() - done = True - except Exception as e: - if called_playwright_install: - self.log.error("Failed to get AWS WAF token.") - raise - else: - self.log.warning("%s", e) - self.log.info('Running "playwright install chromium"...') - called_playwright_install = True - done = False - subprocess.run(["playwright", "install", "chromium"], check=True) - self.log.info("Calling Playwright once more...") - if done: - break + if token: + break + time.sleep(0.5) + browser.close() + except Exception as e: + if "Executable doesn't exist" in str(e): + raise ValueError( + "Chromium is not installed. " + "Run `playwright install chromium` to download it. " + "Alternatively, use --v2 which does not require a WAF token." + ) from None + self.log.error("Failed to get AWS WAF token.") + raise if not token: self.log.warning("AWS WAF token not acquired. Value is None.") @@ -205,27 +322,95 @@ def _set_waf_cookie(self, token: str): ) self._websession.cookies.set_cookie(cookie) + def _stable_device_id(self): + """An id that stays the same for this installation. + + The web frontend derives it from a canvas fingerprint hashed with SHA-512. + There is no canvas here, so the hash covers what identifies this machine + instead. Same length, same alphabet, no state on disk and no request to anyone. + """ + seed = "|".join([str(uuid.getnode()), platform.node(), platform.machine(), platform.system()]) + return hashlib.sha512(seed.encode()).hexdigest() + + def _timezone_name(self): + """The IANA name of the local timezone, with the frontend's own fallback.""" + try: + return str(pathlib.Path("/etc/localtime").resolve()).split("zoneinfo/")[1] + except (OSError, IndexError): + return "Etc/UTC" + + def _login_headers(self): + """The headers Trade Republic requires on the web login calls. + + Without them the endpoints answer 400 MISSING_REQUIRED_HEADER. The web + frontend sends the same set on all three of them: a base64-encoded JSON + description of the device, its build version, the platform its API client is + configured with, and the language it wants to be answered in. + + Fields the frontend can only fill from a browser are left out rather than + invented. It omits them itself when the browser doesn't provide them + (`model` on desktop, `deviceMemory` outside Chromium), so their absence + is accepted by the server. `screen` is the one value with no counterpart here. + """ + if self._device_info is None: + chrome = re.search(r"Chrome/([\d.]+)", self._websession.headers.get("User-Agent", "")) + offset = datetime.now().astimezone().utcoffset() + device = { + "stableDeviceId": self._stable_device_id(), + "browser": "Chrome", + "browserVersion": chrome.group(1) if chrome else "", + "os": platform.system(), + "osVersion": platform.release(), + "timezone": self._timezone_name(), + # JavaScript counts the offset the other way round than Python does. + "timezoneOffset": -int(offset.total_seconds() // 60) if offset else 0, + "screen": "1920x1080x24", + "preferredLanguages": [self._locale], + "numberOfCores": os.cpu_count() or 1, + } + self._device_info = base64.b64encode(json.dumps(device).encode()).decode() + return { + "X-TR-Device-Info": self._device_info, + "X-TR-App-Version": os.environ.get(ENV_APP_VERSION) or APP_VERSION, + "X-Tr-Platform": os.environ.get(ENV_PLATFORM) or WEB_PLATFORM, + "Accept-Language": self._locale, + } + def initiate_weblogin(self): self.log.info("Initiating web login...") if self._waf_token == "awswaf": self._waf_token = self._fetch_waf_token_awswaf() + if not self._waf_token: + self.log.warning("No WAF token available.") elif self._waf_token == "playwright": self._waf_token = self._fetch_waf_token_playwright() + if not self._waf_token: + self.log.warning("No WAF token available.") elif self._waf_token: self.log.info("Using WAF token from arguments.") + else: + self.log.info("WAF token skipped.") if self._waf_token: self.log.debug(f"WAF Token: {self._waf_token}") self._set_waf_cookie(self._waf_token) - else: - self.log.warning("No WAF token available.") + login_path = "/api/v2/auth/web/login" if self._use_v2_login else "/api/v1/auth/web/login" r = self._websession.post( - f"{self._host}/api/v1/auth/web/login", + f"{self._host}{login_path}", json={"phoneNumber": self.phone_no, "pin": self.pin}, + headers=self._login_headers(), ) self.log.debug(f"Web login returned: {r.status_code}") + if r.status_code == 405 and "awselb" in r.headers.get("server", "").lower(): + hint = ( + f"The request was blocked by the AWS load balancer before reaching Trade Republic " + f"(server: {r.headers.get('server')}, empty body). " + "This means the AWS WAF token is missing or was rejected. " + "Try using --waf-token playwright to obtain a valid token, or switch to --v2 which does not require a WAF token." + ) + raise ValueError(hint) r.raise_for_status() j = r.json() self.log.debug(f"Web login data: {json.dumps(j, indent=4)}") @@ -237,23 +422,113 @@ def initiate_weblogin(self): raise ValueError(str(err)) else: raise ValueError("processId not in reponse") - return int(j["countdownInSeconds"]) + 1 + if not self._use_v2_login: + return int(j["countdownInSeconds"]) + 1 + if self._process_id is None: + raise ValueError("Trade Republic completed the login without a confirmation step.") + # The second factor is on the login process, not in the login response. + self._required_action = self._get_weblogin_process(quiet=True).get("requiredAction") + # v2 does not always send countdownInSeconds; the web frontend falls back to 120s. + return int(j.get("countdownInSeconds", 120)) + 1 + + @property + def weblogin_needs_authenticator(self): + """Whether complete_weblogin() needs a code from the user's authenticator app.""" + return self._required_action == "AUTHENTICATOR_VERIFICATION" def resend_weblogin(self): + if self._use_v2_login: + self.log.warning( + "Trade Republic removed the SMS resend endpoint along with the v1 web login. " + "Confirm the login in the Trade Republic mobile app instead." + ) + return r = self._websession.post( f"{self._host}/api/v1/auth/web/login/{self._process_id}/resend", - headers=self._default_headers, + headers=self._login_headers(), ) r.raise_for_status() - def complete_weblogin(self, verify_code): + def complete_weblogin(self, verify_code=None): if not self._process_id and not self._websession: raise ValueError("Initiate web login first.") - r = self._websession.post(f"{self._host}/api/v1/auth/web/login/{self._process_id}/{verify_code}") - r.raise_for_status() + if not self._use_v2_login: + r = self._websession.post( + f"{self._host}/api/v1/auth/web/login/{self._process_id}/{verify_code}", + headers=self._login_headers(), + ) + r.raise_for_status() + self.save_websession() + return + + if self.weblogin_needs_authenticator: + if not verify_code: + raise ValueError("This account needs a code from your authenticator app.") + r = self._websession.post( + f"{self._host}/api/v2/auth/web/login/processes/{self._process_id}/authenticator-verification", + json={"code": verify_code}, + headers=self._login_headers(), + ) + self._raise_for_login_error(r) + + self._await_weblogin_confirmation() self.save_websession() + def _raise_for_login_error(self, r): + """Raise a readable error, keeping the process id out of the message.""" + if r.status_code < 400: + return + try: + code = r.json()["errors"][0]["errorCode"] + except (ValueError, KeyError, IndexError, TypeError): + raise ValueError(f"Login failed with status {r.status_code}.") from None + raise ValueError(LOGIN_ERRORS.get(code, f"Login failed: {code}.")) + + def _get_weblogin_process(self, quiet=False): + """Read the state of the current login process.""" + r = self._websession.get( + f"{self._host}/api/v2/auth/web/login/processes/{self._process_id}", + headers=self._login_headers(), + ) + if quiet and r.status_code >= 400: + return {} + self._raise_for_login_error(r) + return r.json() + + def _weblogin_deadline(self, process, fallback=120): + """Return deadline as a Unix timestamp; fall back to a fixed window.""" + expires_at = process.get("expiresAt") + try: + if isinstance(expires_at, (int, float)): + return expires_at / 1000 if expires_at > 1e11 else float(expires_at) + return datetime.fromisoformat(str(expires_at).replace("Z", "+00:00")).timestamp() + except (TypeError, ValueError): + return time.time() + fallback + + def _await_weblogin_confirmation(self, interval=2): + """Poll the login process until confirmed in the Trade Republic mobile app.""" + process = self._get_weblogin_process() + deadline = self._weblogin_deadline(process) + self.log.info("Waiting for you to confirm the login in the Trade Republic app...") + announced = 0.0 + while True: + status = process.get("status") + self.log.debug(f"Login process status: {status}") + if status in ("CONFIRMED", "COMPLETED"): + self.log.info("Login confirmed.") + return + if status != "PENDING": + raise ValueError(f"Unexpected login process status: {status!r}") + remaining = deadline - time.time() + if remaining <= 0: + raise TimeoutError("The login was not confirmed in time.") + if time.time() - announced >= 10: + self.log.info(f"Still waiting, {int(remaining)}s left...") + announced = time.time() + time.sleep(interval) + process = self._get_weblogin_process() + def save_websession(self): if self._save_cookies: # Saves session cookies too (expirydate=0). @@ -290,11 +565,81 @@ def resume_websession(self): def _web_request(self, url_path, payload=None, method="GET"): if self._session_expires_at < time.time(): - r = self._websession.get(f"{self._host}/api/v1/auth/web/session") + if self._subject_id is None: + # Refreshing without a subject returns the session to the login's own account. + # A new process starts here, so it never inherits the account an earlier run chose. + r = self._websession.get(f"{self._host}/api/v1/auth/web/session") + else: + r = self._post_session(self._subject_id) r.raise_for_status() - self._session_expires_at = time.time() + 290 + self._session_expires_at = time.time() + SESSION_REFRESH_INTERVAL return self._websession.request(method=method, url=f"{self._host}{url_path}", data=payload) + def _post_session(self, subject_id): + """Ask for session cookies that act for `subject_id`, the way the web frontend does. + + The frontend uses this call both to switch the account and to refresh the session. + """ + return self._websession.post( + f"{self._host}/api/v2/auth/web/session", + json={"subjectId": subject_id}, + headers=self._login_headers(), + ) + + def relationships(self): + """List the accounts this login can act for. + + Besides the login's own account (`relationshipType` `SELF`) this is e.g. a + company account (`LEGAL_ENTITY_ACTOR`). + """ + r = self._web_request("/api/v1/customer/relationships/detailed") + r.raise_for_status() + return r.json().get("relationships") or [] + + def _find_relationship(self, account): + """Pick one relationship by customer id, type or name. `None` picks the login's own account.""" + relationships = self.relationships() + if account is None: + matches = [r for r in relationships if r.get("relationshipType") == "SELF"] + wanted = "Your own account" + else: + matches = [r for r in relationships if account.strip().casefold() in _account_selectors(r)] + wanted = repr(account) + if len(matches) == 1 and matches[0].get("customerId"): + return matches[0] + known = ", ".join(_describe_account(r) for r in relationships) or "none" + if len(matches) > 1: + raise ValueError(f"{wanted} matches more than one account, use its customer id. Accounts: {known}.") + raise ValueError(f"{wanted} was not found among the accounts of this login. Accounts: {known}.") + + def switch_account(self, account=None): + """Let the session act for another account of this login, e.g. a company account. + + `account` is the account's type (`LEGAL_ENTITY`), its name or its customer id, as listed + by `relationships()`. `None` switches back to the login's own account. Returns the chosen + relationship. + + Trade Republic does not address these accounts by a second account number. It hands + out new session cookies that act for the other customer, so every call made afterwards, + the websocket included, sees that account only. + """ + if self._ws is not None and self._ws.close_code is None: + raise ValueError("Close the websocket connection before switching the account.") + + relationship = self._find_relationship(account) + r = self._post_session(relationship["customerId"]) + r.raise_for_status() + + is_self = relationship.get("relationshipType") == "SELF" + self._subject_id = None if is_self else relationship["customerId"] + self._session_expires_at = time.time() + SESSION_REFRESH_INTERVAL + # The securities account belongs to the previous account. + self._sec_acc_no = None + # The switch replaced the session cookies; keep the saved ones usable for the next run. + self.save_websession() + self.log.info(f"Using account: {_describe_account(relationship)}") + return relationship + async def _get_ws(self): if self._ws and self._ws.close_code is None: return self._ws @@ -365,6 +710,11 @@ async def unsubscribe(self, subscription_id): self._previous_responses.pop(subscription_id, None) async def recv(self): + if self._held_back: + return self._held_back.popleft() + return await self._recv_ws() + + async def _recv_ws(self): ws = await self._get_ws() while True: response = await ws.recv() @@ -443,10 +793,41 @@ async def portfolio_status(self): async def compact_portfolio(self): if self._sec_acc_no is None: - self.settings() + if self._subject_id is None: + self.settings() + else: + # /api/v2/auth/account answers 400 INVALID_AUTH_ACCOUNT_STATE for any account but + # the login's own, so the number has to come from the websocket instead. + self._sec_acc_no = await self._sec_acc_no_from_account_pairs() if self._sec_acc_no is None: - raise ValueError("Could not retrieve securities account number from account settings.") - return await self.subscribe({"type": "compactPortfolio", "secAccNo": self._sec_acc_no}) + source = "account settings" if self._subject_id is None else "account pairs" + raise ValueError(f"Could not retrieve securities account number from {source}.") + return await self.subscribe({"type": "compactPortfolioByType", "secAccNo": self._sec_acc_no}) + + async def account_pairs(self): + return await self.subscribe({"type": "accountPairs"}) + + async def _sec_acc_no_from_account_pairs(self, timeout=5.0): + """Read the securities account number of the account the session acts for.""" + subscription_id = await self.account_pairs() + try: + response = await asyncio.wait_for(self._recv_holding_back_others(subscription_id), timeout) + except asyncio.TimeoutError: + return None + finally: + await self.unsubscribe(subscription_id) + accounts = [a for a in response.get("accounts") or [] if a.get("securitiesAccountNumber")] + # Prefer the pair of the default product if the account has more than one. + accounts.sort(key=lambda a: a.get("productType") != "DEFAULT") + return accounts[0]["securitiesAccountNumber"] if accounts else None + + async def _recv_holding_back_others(self, subscription_id): + """Wait for one subscription's answer; keep the answers to others for the next `recv()`.""" + while True: + message = await self._recv_ws() + if message[0] == subscription_id: + return message[2] + self._held_back.append(message) async def watchlist(self): return await self.subscribe({"type": "watchlist"}) diff --git a/pytr/awswaf/aws.py b/pytr/awswaf/aws.py index 115a7fdf..e42d918b 100644 --- a/pytr/awswaf/aws.py +++ b/pytr/awswaf/aws.py @@ -147,6 +147,12 @@ def build_payload(self, inputs: dict): checksum, fp = get_fp(self.user_agent) bandwidth_sizes = self._js_config.get("bandwidth_sizes", {}) solution = solver(inputs["challenge"]["input"], checksum, inputs["difficulty"], bandwidth_sizes=bandwidth_sizes) + if solution is None: + # The proof-of-work solvers give up instead of spinning forever on a + # difficulty the server picked (see verify.py). Stop here rather than + # posting a null solution to /verify, where the failure would surface + # as a KeyError on the response instead of as what it is. + raise ValueError(f"Could not solve WAF challenge of type {challenge_type} within the allotted budget") return { "challenge": inputs["challenge"], "checksum": checksum, diff --git a/pytr/awswaf/verify.py b/pytr/awswaf/verify.py index 11d0ee48..477e9f5a 100644 --- a/pytr/awswaf/verify.py +++ b/pytr/awswaf/verify.py @@ -28,8 +28,30 @@ import binascii import hashlib import itertools +import time from typing import Any, Callable, Optional +# Bounds for the two proof-of-work solvers below. +# +# Both used to loop over `itertools.count()` with no exit other than success, +# while `difficulty` arrives from the WAF's own `/inputs` response — so the +# server on the other end decided how long this process would spin. Two ways +# that ends badly: a difficulty above 256 can never be satisfied at all +# (`_check` compares a 32-byte digest against a longer all-zero prefix, which +# is false for every possible digest), and values below that are already +# computationally out of reach while still looking like a legitimate +# challenge. Either way a login someone is waiting on hangs forever. +# +# Giving up returns `None`, which `build_payload` turns into a clean error. +# A WAF token that takes longer than the deadline is worthless anyway: the +# caller is a synchronous login request. +_MAX_SOLVABLE_DIFFICULTY = 256 +_POW_DEADLINE_SECONDS = 30.0 +# The deadline is only consulted every N nonces — a `time.monotonic()` call per +# sha256 would cost more than the hash it is guarding. scrypt is expensive +# enough per iteration to check every time. +_POW_TIME_CHECK_INTERVAL = 4096 + def _check(digest: bytes, difficulty: int) -> bool: full, rem = divmod(difficulty, 8) @@ -41,11 +63,16 @@ def _check(digest: bytes, difficulty: int) -> bool: def hash_pow(challenge: str, salt: str, difficulty: int, **kwargs) -> Optional[str]: + if difficulty > _MAX_SOLVABLE_DIFFICULTY: + return None prefix = (challenge + salt).encode() + deadline = time.monotonic() + _POW_DEADLINE_SECONDS for nonce in itertools.count(): digest = hashlib.sha256(prefix + str(nonce).encode()).digest() if _check(digest, difficulty): return str(nonce) + if nonce % _POW_TIME_CHECK_INTERVAL == 0 and time.monotonic() > deadline: + return None return None @@ -64,7 +91,10 @@ def compute_scrypt_nonce( dklen: int = 16, **kwargs, ) -> Optional[str]: + if difficulty > _MAX_SOLVABLE_DIFFICULTY: + return None prefix = challenge + salt + deadline = time.monotonic() + _POW_DEADLINE_SECONDS for nonce in itertools.count(): digest = hashlib.scrypt( password=f"{prefix}{nonce}".encode(), @@ -76,11 +106,20 @@ def compute_scrypt_nonce( ) if _check(digest, difficulty): return str(nonce) + if time.monotonic() > deadline: + return None return None _DEFAULT_BANDWIDTH_SIZES = {1: 0x400, 2: 0xA * 0x400, 3: 0x64 * 0x400, 4: 0x100000, 5: 0xA * 0x100000} +# The largest entry in the table above. `bandwidth_sizes` can also arrive from +# `parse_challenge_js`, i.e. from numbers scraped out of a page with a regular +# expression, and the buffer is allocated in one go. Without a ceiling a single +# rewritten constant turns into an out-of-memory kill of the whole process — +# which, in this application, is the process holding the user's session. +_MAX_BANDWIDTH_BYTES = 0xA * 0x100000 + def network_bandwidth(challenge: str, salt: str, difficulty: int, **kwargs) -> str: """NetworkBandwidth challenge — returns base64-encoded zero buffer sized by difficulty.""" @@ -88,6 +127,11 @@ def network_bandwidth(challenge: str, salt: str, difficulty: int, **kwargs) -> s sizes = kwargs.get("bandwidth_sizes") or _DEFAULT_BANDWIDTH_SIZES size = sizes.get(difficulty, 0x400) + try: + size = int(size) + except (TypeError, ValueError): + size = 0x400 + size = min(max(size, 0), _MAX_BANDWIDTH_BYTES) return base64.b64encode(b"\x00" * size).decode() diff --git a/pytr/details.py b/pytr/details.py index e556bd70..58c1c016 100644 --- a/pytr/details.py +++ b/pytr/details.py @@ -17,7 +17,6 @@ async def details_loop(self): await self.tr.ticker(self.isin, exchange="LSX") await self.tr.performance(self.isin, exchange="LSX") await self.tr.instrument_details(self.isin) - await self.tr.instrument_suitability(self.isin) # await self.tr.add_watchlist(self.isin) # await self.tr.remove_watchlist(self.isin) @@ -42,14 +41,10 @@ async def details_loop(self): elif subscription["type"] == "instrument": recv += 1 self.instrument = response - elif subscription["type"] == "instrumentSuitability": - recv += 1 - self.instrumentSuitability = response - print("instrumentSuitability:", response) else: print(f"unmatched subscription of type '{subscription['type']}':\n{preview(response, num_lines=30)}") - if recv == 6: + if recv == 5: await self.tr.close() return diff --git a/pytr/dl.py b/pytr/dl.py index 10a759e9..fd41868a 100644 --- a/pytr/dl.py +++ b/pytr/dl.py @@ -17,19 +17,33 @@ event_subfolder_mapping = { "OUTGOING_TRANSFER_DELEGATION": "Auszahlungen", "OUTGOING_TRANSFER": "Auszahlungen", + "BANK_TRANSACTION_OUTGOING": "Auszahlungen", "CREDIT": "Dividende", - "ssp_corporate_action_invoice_cash": "Dividende", + "SSP_CORPORATE_ACTION_INVOICE_CASH": "Dividende", + "SSP_CORPORATE_ACTION_CASH": "Dividende", + "SSP_CORPORATE_ACTION_CASH_AND_STOCK": "Dividende", "ACCOUNT_TRANSFER_INCOMING": "Einzahlungen", "INCOMING_TRANSFER_DELEGATION": "Einzahlungen", "INCOMING_TRANSFER": "Einzahlungen", "PAYMENT_INBOUND_GOOGLE_PAY": "Einzahlungen", "PAYMENT_INBOUND_SEPA_DIRECT_DEBIT": "Einzahlungen", + "BANK_TRANSACTION_INCOMING": "Einzahlungen", + "PAYMENT_INBOUND": "Einzahlungen", + "JUNIOR_P2P_TRANSFER": "Einzahlungen", + "CARD_TRANSACTION": "Karte", + "CARD_REFUND": "Karte", + "CARD_VERIFICATION": "Karte", "CREDIT_CANCELED": "Misc", "CRYPTO_ANNUAL_STATEMENT": "Misc", + "CRYPTO_TNC_UPDATE_2025": "Misc", + "CSX_CHAT_ACTIVITY": "Misc", "CUSTOMER_CREATED": "Misc", + "DEVICE_RESET": "Misc", "DOCUMENTS_ACCEPTED": "Misc", "DOCUMENTS_CHANGED": "Misc", "DOCUMENTS_CREATED": "Misc", + "EMAIL_VALIDATED": "Misc", + "EXEMPTION_ORDER_CHANGED": "Misc", "EX_POST_COST_REPORT": "Misc", "EX_POST_COST_REPORT_CREATED": "Misc", "GENERAL_MEETING": "Misc", @@ -38,45 +52,59 @@ "INSTRUCTION_CORPORATE_ACTION": "Misc", "JUNIOR_ONBOARDING_GUARDIAN_B_CONSENT": "Misc", "PRE_DETERMINED_TAX_BASE_EARNING": "Misc", + "PRIVATE_MARKETS_SUITABILITY_QUIZ_COMPLETED": "Misc", + "PUK_CREATED": "Misc", + "QUARTERLY_NET_WORTH_STATEMENT_CREATED": "Misc", "QUARTERLY_REPORT": "Misc", + "REFERENCE_ACCOUNT_CHANGED": "Misc", + "SECURITIES_ACCOUNT_CREATED": "Misc", "SHAREBOOKING": "Misc", "SHAREBOOKING_TRANSACTIONAL": "Misc", + "SPARE_CHANGE_AGGREGATE": "RoundUp", + "SSP_CAPITAL_INCREASE_CUSTOMER_INSTRUCTION": "Misc", + "SSP_CORPORATE_ACTION_ACTIVITY": "Misc", + "SSP_CORPORATE_ACTION_CASH_NON_DIVIDEND": "Misc", + "SSP_CORPORATE_ACTION_INFORMATIVE": "Misc", + "SSP_CORPORATE_ACTION_INFORMATIVE_NOTIFICATION": "Misc", + "SSP_CORPORATE_ACTION_INSTRUCTION": "Misc", + "SSP_CORPORATE_ACTION_INVOICE_SHARES": "Misc", + "SSP_CORPORATE_ACTION_NO_CASH": "Misc", + "SSP_CORPORATE_ACTION_UPCOMING": "Misc", + "SSP_DIVIDEND_OPTION_CUSTOMER_INSTRUCTION": "Misc", + "SSP_GENERAL_MEETING_CUSTOMER_INSTRUCTION": "Misc", + "SSP_TENDER_OFFER_CUSTOMER_INSTRUCTION": "Misc", "STOCK_PERK_REFUNDED": "Misc", "TAX_YEAR_END_REPORT": "Misc", "TAX_YEAR_END_REPORT_CREATED": "Misc", + "VERIFICATION_TRANSFER_ACCEPTED": "Misc", "YEAR_END_TAX_REPORT": "Misc", - "crypto_annual_statement": "Misc", - "private_markets_suitability_quiz_completed": "Misc", - "ssp_capital_increase_customer_instruction": "Misc", - "ssp_corporate_action_informative_notification": "Misc", - "ssp_corporate_action_invoice_shares": "Misc", - "ssp_dividend_option_customer_instruction": "Misc", - "ssp_general_meeting_customer_instruction": "Misc", - "ssp_tender_offer_customer_instruction": "Misc", - "benefits_spare_change_execution": "RoundUp", - "benefits_saveback_execution": "Saveback", + "BENEFITS_SPARE_CHANGE_EXECUTION": "RoundUp", + "BENEFITS_SAVEBACK_EXECUTION": "Saveback", + "SAVEBACK_AGGREGATE": "Saveback", "SAVINGS_PLAN_EXECUTED": "Sparplan", "SAVINGS_PLAN_INVOICE_CREATED": "Sparplan", - "trading_savingsplan_executed": "Sparplan", - "trading_savingsplan_execution_failed": "Sparplan", + "TRADING_SAVINGSPLAN_EXECUTED": "Sparplan", + "TRADING_SAVINGSPLAN_EXECUTION_FAILED": "Sparplan", + "SSP_TAX_CORRECTION": "Steuerkorrekturen", + "SSP_TAX_CORRECTION_INVOICE": "Steuerkorrekturen", "TAX_CORRECTION": "Steuerkorrekturen", "TAX_REFUND": "Steuerkorrekturen", - "ssp_tax_correction_invoice": "Steuerkorrekturen", + "IPO_TRADE_EXECUTED": "Trades", "ORDER_CANCELED": "Trades", "ORDER_EXECUTED": "Trades", "ORDER_EXPIRED": "Trades", "ORDER_REJECTED": "Trades", + "PRIVATE_MARKET_FUND_TRADE_EXECUTED": "Trades", + "PRIVATE_MARKETS_TRADE_EXECUTED": "Trades", + "PRIVATE_MARKETS_ORDER_CREATED": "Trades", "TRADE_CORRECTED": "Trades", "TRADE_INVOICE": "Trades", "TRADING_ORDER_CANCELLED": "Trades", "TRADING_ORDER_CREATED": "Trades", - "private_markets_order_created": "Trades", - "trading_order_cancelled": "Trades", - "trading_order_created": "Trades", - "trading_order_rejected": "Trades", - "trading_trade_executed": "Trades", - "trading_order_expired": "Trades", - "ACQUISITION_TRADE_PERK": "Vorteil", + "TRADING_ORDER_EXPIRED": "Trades", + "TRADING_ORDER_REJECTED": "Trades", + "TRADING_TRADE_EXECUTED": "Trades", + "ACQUISITION_TRADE_PERK": "Misc", "INTEREST_PAYOUT": "Zinsen", "INTEREST_PAYOUT_CREATED": "Zinsen", } @@ -99,7 +127,8 @@ "Bardividende": "Dividende", "Cash oder Aktie": "Dividende", "Dividende Wahlweise": "Dividende", - "Aktienprämiendividende": "Misc", + "Dividende. Cash oder Stockdividende?": "Dividende", + "Aktienprämiendividende": "Dividende", "Aktiensplit": "Misc", "Aufruf von Zwischenpapieren": "Misc", "Bardividende korrigiert": "Misc", @@ -145,7 +174,6 @@ def __init__( scan_for_duplicates=False, dump_raw_data=False, export_transactions=True, - history_file="pytr_history", max_workers=8, universal_filepath=False, lang="en", @@ -154,6 +182,8 @@ def __init__( sort_export=False, format_export: Literal["json", "csv"] = "csv", flat=False, + load_event_database=None, + dry_run=False, ): """ tr: api object @@ -165,7 +195,6 @@ def __init__( self.filename_fmt = filename_fmt self.dump_raw_data = dump_raw_data self.export_transactions = export_transactions - self.history_file = self.output_path / history_file self.universal_filepath = universal_filepath self.lang = lang self.date_with_time = date_with_time @@ -173,6 +202,7 @@ def __init__( self.sort_export = sort_export self.format_export: Literal["json", "csv"] = format_export self.flat = flat + self.dry_run = dry_run self.tl = Timeline( self.tr, @@ -183,9 +213,12 @@ def __init__( scan_for_duplicates, dump_raw_data, self.dl_callback, + load_event_database=load_event_database, ) - self.session = FuturesSession(max_workers=max_workers, session=self.tr._websession) + self.session = ( + FuturesSession(max_workers=max_workers, session=self.tr._websession) if self.tr is not None else None + ) self.futures: list[Future[Response]] = [] self.events_without_docs: List[Dict[str, Any]] = [] @@ -195,23 +228,11 @@ def __init__( self.done = 0 self.filepaths: List[str] = [] self.doc_urls: List[str] = [] - self.doc_urls_history: List[str] = [] + self.events_processed = 0 self.log = get_logger(__name__) - self.load_history() - - def load_history(self): - """ - Read history file with URLs if it exists, otherwise create empty file - """ - if self.history_file.exists(): - with self.history_file.open() as f: - self.doc_urls_history = f.read().splitlines() - self.log.info(f"Found {len(self.doc_urls_history)} lines in history file") - else: - self.history_file.parent.mkdir(exist_ok=True, parents=True) - self.history_file.touch() - self.log.info("Created history file") + if load_event_database is not None: + self.dry_run = True def do_dl(self): asyncio.run(self.tl.tl_loop()) @@ -239,24 +260,32 @@ def do_dl(self): self.work_responses() def dl_callback(self, event): + if hasattr(self, "tl") and not self.tl.fetch_from_tr: + self.events_processed += 1 + if self.events_processed % 1000 == 0: + self.log.info(f"Processing events: {self.events_processed}/{self.tl.all_detail}") has_docs = False for section in event["details"]["sections"]: if section["type"] != "documents": continue subfolder = None - eventType = event.get("eventType", None) + eventType = (event.get("eventType") or "").upper() or None title = event.get("title", "") subtitle = event.get("subtitle", "") eventdesc = f"{title} {subtitle} ({event['id']})" sections = event.get("details", {}).get("sections", [{}]) uebersicht_dict = next(filter(lambda x: x.get("title") in ["Übersicht"], sections), None) - if eventType in ["timeline_legacy_migrated_events", None]: + if eventType in ["TIMELINE_LEGACY_MIGRATED_EVENTS", None]: subfolder = title_subfolder_mapping.get(title) if subfolder is None: subfolder = subtitle_subfolder_mapping.get(subtitle) else: subfolder = event_subfolder_mapping.get(eventType) + if subfolder == "Misc": + subtitle_override = subtitle_subfolder_mapping.get(subtitle) + if subtitle_override is not None: + subfolder = subtitle_override if subfolder is None and uebersicht_dict: for item in uebersicht_dict.get("data", []): @@ -283,11 +312,19 @@ def dl_callback(self, event): if subfolder is None: self.log.warning(f"no subfolder mapping for {eventdesc}") + doc_type_counts = {} + for doc in section["data"]: + if not isinstance(doc["action"]["payload"], dict): + t = doc["title"].rsplit(" ") + t = " ".join(t[:-1] if t[-1].isnumeric() else t) + doc_type_counts[t] = doc_type_counts.get(t, 0) + 1 + doc_type_seen = {} + for idx, doc in enumerate(section["data"]): if isinstance(doc["action"]["payload"], dict): - self.log.warning( - f'Download of document with new API-Path URL "{doc["action"]["payload"]["path"]}" is not possible. (yet?)' - ) + # self.log.warning( + # f'Download of document with new API-Path URL "{doc["action"]["payload"]["path"]}" is not possible. (yet?)' + # ) continue has_docs = True timestamp_str = event["timestamp"] @@ -299,17 +336,31 @@ def dl_callback(self, event): self.log.warning(f"no timestamp parseable from {timestamp_str}") docdate = datetime.now() - suffix = f" - {idx}" if idx > 0 else "" + t = doc["title"].rsplit(" ") + has_num = t[-1].isnumeric() + t = " ".join(t[:-1] if has_num else t) + doc_type_seen[t] = doc_type_seen.get(t, 0) + 1 + if not has_num and doc_type_counts[t] > 1 and doc_type_seen[t] > 1: + suffix = f" {doc_type_seen[t]}" if t == "Dokumente" else f" - {doc_type_seen[t] - 1}" + else: + suffix = "" title = f"{doc['title']} - {event['title']} - {event['subtitle']}{suffix}" - self.dl_doc(doc, title, subfolder, docdate) + self.dl_doc( + doc, + title, + subfolder, + docdate, + event.get("subtitle") or "", + subdir_override=event["title"] if eventType == "ACQUISITION_TRADE_PERK" else None, + ) if has_docs: self.events_with_docs.append(event) else: self.events_without_docs.append(event) - def dl_doc(self, doc, titleText, subfolder, doc_date): + def dl_doc(self, doc, titleText, subfolder, doc_date, subtitle="", subdir_override=None): """ send asynchronous request, append future with filepath to self.futures """ @@ -345,7 +396,21 @@ def dl_doc(self, doc, titleText, subfolder, doc_date): doc_type = " ".join(doc_type) if doc_type == "Abrechnung Ausführung" or doc_type == "Abrechnungsausführung": doc_type = "Abrechnung" + if doc_type == "Bestätigung eines Ausführungsfehlers": + doc_type = "Ausführungsfehler" titleText = titleText.replace("\n", "").replace("/", "-") + if doc_type == "Dokumente" or doc_type == "Steuerabrechnung": + titleText = titleText.removeprefix("Dokumente - ").removeprefix("Steuerabrechnung - ") + if subtitle and subfolder == "Misc": + titleText = titleText.removesuffix(f" - {subtitle}") + else: + titleText = ( + titleText.replace("Abrechnung Ausführung - ", "Abrechnung - ") + .replace("Abrechnungsausführung - ", "Abrechnung - ") + .replace("Bestätigung eines Ausführungsfehlers - ", "Ausführungsfehler - ") + .replace(" - Teilnehmen?", "") + ) + titleText = titleText.removesuffix(" - None") subtitleText = subtitleText.replace("\n", "").replace("/", "-") filename = self.filename_fmt.format( @@ -356,16 +421,29 @@ def dl_doc(self, doc, titleText, subfolder, doc_date): doc_num=doc_type_num, id=doc_id, ) - + filename = filename.rstrip("?") # In case, the filename already ends with the doc id, we remove it to avoid a duplicate id in the name filename_with_doc_id = filename.removesuffix(doc_id).rstrip() + f" ({doc_id})" if doc_type in ["Kontoauszug", "Depotauszug"]: filepath = directory / "Abschlüsse" / f"{filename}" / f"{doc_type}.pdf" filepath_with_doc_id = directory / "Abschlüsse" / f"{filename_with_doc_id}" / f"{doc_type}.pdf" + elif ( + doc_type in ["Dokumente", "Steuerabrechnung", "Dividende Wahlweise", "Dividendenbeleg"] + or (doc_type == "Transaktionsbestätigung" and subfolder in ["Einzahlungen", "Auszahlungen"]) + or (subfolder == "Zinsen") + or (doc_type == "Abrechnung" and subfolder in ["RoundUp", "Saveback", "Sparplan", "Trades"]) + ): + if subtitle and subfolder == "Misc": + filepath = directory / subtitle / f"{filename}.pdf" + filepath_with_doc_id = directory / subtitle / f"{filename_with_doc_id}.pdf" + else: + filepath = directory / f"{filename}.pdf" + filepath_with_doc_id = directory / f"{filename_with_doc_id}.pdf" else: - filepath = directory / doc_type / f"{filename}.pdf" - filepath_with_doc_id = directory / doc_type / f"{filename_with_doc_id}.pdf" + subdir = subdir_override if subdir_override is not None else doc_type + filepath = directory / subdir / f"{filename}.pdf" + filepath_with_doc_id = directory / subdir / f"{filename_with_doc_id}.pdf" if self.universal_filepath: filepath = sanitize_filepath(filepath, "_", "universal") @@ -385,18 +463,24 @@ def dl_doc(self, doc, titleText, subfolder, doc_date): doc["local_filepath"] = str(filepath) self.filepaths.append(str(filepath)) + if self.dry_run: + if not filepath.exists(): + filepath.parent.mkdir(parents=True, exist_ok=True) + filepath.touch() + self.log.debug(f"[dry-run] Created placeholder {filepath}") + else: + self.log.debug(f"[dry-run] Already exists {filepath}") + return + if filepath.is_file() is False: doc_url_base = doc_url.split("?")[0] if doc_url_base in self.doc_urls: self.log.debug(f"URL {doc_url_base} already in queue. Skipping...") return - elif doc_url_base in self.doc_urls_history: - self.log.debug(f"URL {doc_url_base} already in history. Skipping...") - return else: self.doc_urls.append(doc_url_base) - future = self.session.get(doc_url) + future = self.session.get(doc_url) # type: ignore[union-attr] future.filepath = filepath # type: ignore[attr-defined] future.doc_url_base = doc_url_base # type: ignore[attr-defined] self.futures.append(future) # type: ignore[arg-type] @@ -412,26 +496,25 @@ def work_responses(self): self.log.info("Nothing to download.") return - with self.history_file.open("a") as history_file: - self.log.info("Waiting for downloads to complete...") - for future in as_completed(self.futures): - if future.filepath.is_file() is True: # type: ignore[attr-defined] - self.log.debug(f"file {future.filepath} was already downloaded.") # type: ignore[attr-defined] + self.log.info("Waiting for downloads to complete...") + for future in as_completed(self.futures): + if future.filepath.is_file() is True: # type: ignore[attr-defined] + self.log.debug(f"file {future.filepath} was already downloaded.") # type: ignore[attr-defined] - try: - r = future.result() - except Exception as e: - self.log.fatal(str(e)) - continue - - future.filepath.parent.mkdir(parents=True, exist_ok=True) # type: ignore[attr-defined] - with open(future.filepath, "wb") as f: # type: ignore[attr-defined] - f.write(r.content) - self.done += 1 - history_file.write(f"{future.doc_url_base}\n") # type: ignore[attr-defined] + try: + r = future.result() + except Exception as e: + self.log.fatal(str(e)) + continue - self.log.debug(f"{self.done:>3}/{len(self.doc_urls)} {future.filepath.name}") # type: ignore[attr-defined] + future.filepath.parent.mkdir(parents=True, exist_ok=True) # type: ignore[attr-defined] + with open(future.filepath, "wb") as f: # type: ignore[attr-defined] + f.write(r.content) + self.done += 1 + if self.done % 500 == 0: + self.log.info(f"Downloading: {self.done}/{len(self.doc_urls)}") + self.log.debug(f"{self.done:>3}/{len(self.doc_urls)} {future.filepath.name}") # type: ignore[attr-defined] - if self.done == len(self.doc_urls): - self.log.info("Done.") - return + if self.done == len(self.doc_urls): + self.log.info("Done.") + return diff --git a/pytr/event.py b/pytr/event.py index a923403e..86d503f8 100644 --- a/pytr/event.py +++ b/pytr/event.py @@ -4,7 +4,7 @@ from datetime import datetime from decimal import ROUND_HALF_UP, Decimal from enum import Enum, auto -from typing import Any, Dict, Optional, Tuple +from typing import Any, Dict, Optional from babel.numbers import NumberFormatError, parse_decimal @@ -40,57 +40,67 @@ class PPEventType(EventType): SWAP = "SWAP" TAXES = "TAXES" TAX_REFUND = "TAX_REFUND" - TRANSFER_IN = "TRANSFER_IN" # Currently not mapped to - TRANSFER_OUT = "TRANSFER_OUT" # Currently not mapped to + TRANSFER_IN = "TRANSFER_IN" + TRANSFER_OUT = "TRANSFER_OUT" tr_event_type_mapping = { # Deposits "ACCOUNT_TRANSFER_INCOMING": PPEventType.DEPOSIT, + "BANK_TRANSACTION_INCOMING": PPEventType.DEPOSIT, + "CARD_REFUND": PPEventType.DEPOSIT, + "CARD_SUCCESSFUL_OCT": PPEventType.DEPOSIT, + "CARD_TR_REFUND": PPEventType.DEPOSIT, "INCOMING_TRANSFER": PPEventType.DEPOSIT, "INCOMING_TRANSFER_DELEGATION": PPEventType.DEPOSIT, "PAYMENT_INBOUND": PPEventType.DEPOSIT, "PAYMENT_INBOUND_APPLE_PAY": PPEventType.DEPOSIT, + "PAYMENT_INBOUND_CREDIT_CARD": PPEventType.DEPOSIT, "PAYMENT_INBOUND_GOOGLE_PAY": PPEventType.DEPOSIT, "PAYMENT_INBOUND_SEPA_DIRECT_DEBIT": PPEventType.DEPOSIT, - "PAYMENT_INBOUND_CREDIT_CARD": PPEventType.DEPOSIT, "PAYMENT-SERVICE-IN-PAYMENT-DIRECT-DEBIT": PPEventType.DEPOSIT, - "card_refund": PPEventType.DEPOSIT, - "card_successful_oct": PPEventType.DEPOSIT, - "card_tr_refund": PPEventType.DEPOSIT, # Dividends "CREDIT": PPEventType.DIVIDEND, # Interests "INTEREST_PAYOUT": PPEventType.INTEREST, "INTEREST_PAYOUT_CREATED": PPEventType.INTEREST, # Removals + "BANK_TRANSACTION_OUTGOING": PPEventType.REMOVAL, + "CARD_FAILED_TRANSACTION": PPEventType.REMOVAL, + "CARD_ORDER_BILLED": PPEventType.REMOVAL, + "CARD_SUCCESSFUL_ATM_WITHDRAWAL": PPEventType.REMOVAL, + "CARD_SUCCESSFUL_TRANSACTION": PPEventType.REMOVAL, + "CARD_TRANSACTION": PPEventType.REMOVAL, + "JUNIOR_P2P_TRANSFER": PPEventType.REMOVAL, "OUTGOING_TRANSFER": PPEventType.REMOVAL, "OUTGOING_TRANSFER_DELEGATION": PPEventType.REMOVAL, "PAYMENT_OUTBOUND": PPEventType.REMOVAL, - "card_failed_transaction": PPEventType.REMOVAL, - "card_order_billed": PPEventType.REMOVAL, - "card_successful_atm_withdrawal": PPEventType.REMOVAL, - "card_successful_transaction": PPEventType.REMOVAL, - "junior_p2p_transfer": PPEventType.REMOVAL, + # Transfers + "SSP_SECURITIES_TRANSFER_INCOMING": PPEventType.TRANSFER_IN, # Saveback "ACQUISITION_TRADE_PERK": ConditionalEventType.SAVEBACK, - "benefits_saveback_execution": ConditionalEventType.SAVEBACK, + "BENEFITS_SAVEBACK_EXECUTION": ConditionalEventType.SAVEBACK, + "SAVEBACK_AGGREGATE": ConditionalEventType.SAVEBACK, # Tax refunds + "SSP_TAX_CORRECTION": PPEventType.TAX_REFUND, + "SSP_TAX_CORRECTION_INVOICE": PPEventType.TAX_REFUND, "TAX_CORRECTION": PPEventType.TAX_REFUND, "TAX_REFUND": PPEventType.TAX_REFUND, - "ssp_tax_correction_invoice": PPEventType.TAX_REFUND, # Trade invoices + "BENEFITS_SPARE_CHANGE_EXECUTION": ConditionalEventType.TRADE_INVOICE, + "IPO_TRADE_EXECUTED": ConditionalEventType.TRADE_INVOICE, "ORDER_EXECUTED": ConditionalEventType.TRADE_INVOICE, "SAVINGS_PLAN_EXECUTED": ConditionalEventType.TRADE_INVOICE, "SAVINGS_PLAN_INVOICE_CREATED": ConditionalEventType.TRADE_INVOICE, + "SPARE_CHANGE_AGGREGATE": ConditionalEventType.TRADE_INVOICE, "TRADE_CORRECTED": ConditionalEventType.TRADE_INVOICE, "TRADE_INVOICE": ConditionalEventType.TRADE_INVOICE, - "benefits_spare_change_execution": ConditionalEventType.TRADE_INVOICE, - "trading_savingsplan_executed": ConditionalEventType.TRADE_INVOICE, - "trading_trade_executed": ConditionalEventType.TRADE_INVOICE, + "TRADING_SAVINGSPLAN_EXECUTED": ConditionalEventType.TRADE_INVOICE, + "TRADING_TRADE_EXECUTED": ConditionalEventType.TRADE_INVOICE, # Private markets order - "private_markets_order_created": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "private_markets_trade_executed": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "PRIVATE_MARKET_FUND_TRADE_EXECUTED": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "PRIVATE_MARKETS_ORDER_CREATED": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "PRIVATE_MARKETS_TRADE_EXECUTED": ConditionalEventType.PRIVATE_MARKETS_ORDER, } timeline_legacy_migrated_events_title_type_mapping = { @@ -107,6 +117,9 @@ class PPEventType(EventType): "Sparplan ausgeführt": ConditionalEventType.TRADE_INVOICE, "Stop-Sell-Order": ConditionalEventType.TRADE_INVOICE, "Verkaufsorder": ConditionalEventType.TRADE_INVOICE, + # Transfers + "Aktien erhalten": PPEventType.TRANSFER_IN, + "Aktien übertragen": PPEventType.TRANSFER_OUT, } title_event_type_mapping = { @@ -142,6 +155,7 @@ class PPEventType(EventType): # Swap "Aufruf von Zwischenpapieren": PPEventType.SWAP, "Reverse Split": PPEventType.SWAP, + "Tausch": PPEventType.SWAP, "Teilrückzahlung ohne Reduzierung des Poolfaktors": PPEventType.SWAP, "Zusammenschluss": PPEventType.SWAP, # Taxes @@ -156,36 +170,50 @@ class PPEventType(EventType): "Stop-Sell-Order": ConditionalEventType.TRADE_INVOICE, "Verkaufsorder": ConditionalEventType.TRADE_INVOICE, "Wertlos": ConditionalEventType.TRADE_INVOICE, + # Transfers + "Aktien erhalten": PPEventType.TRANSFER_IN, + "Aktien übertragen": PPEventType.TRANSFER_OUT, } events_known_ignored = [ + "ADDRESS_CHANGED", "AML_SOURCE_OF_WEALTH_RESPONSE_EXECUTED", + "CARD_FAILED_VERIFICATION", + "CARD_SUCCESSFUL_VERIFICATION", + "CARD_VERIFICATION", "CASH_ACCOUNT_CHANGED", "CREDIT_CANCELED", - "CUSTOMER_CREATED", "CRYPTO_ANNUAL_STATEMENT", + "CRYPTO_TNC_UPDATE_2025", + "CSX_CHAT_ACTIVITY", + "CURRENT_ACCOUNT_ACTIVATED", + "CUSTOMER_CREATED", "DEVICE_RESET", "DOCUMENTS_ACCEPTED", "DOCUMENTS_CHANGED", "DOCUMENTS_CREATED", "EMAIL_VALIDATED", - "EX_POST_COST_REPORT", - "EX_POST_COST_REPORT_CREATED", "EXEMPTION_ORDER_CHANGE_REQUESTED", "EXEMPTION_ORDER_CHANGE_REQUESTED_AUTOMATICALLY", "EXEMPTION_ORDER_CHANGED", + "EX_POST_COST_REPORT", + "EX_POST_COST_REPORT_CREATED", + "GENERAL_MEETING", + "GESH_CORPORATE_ACTION", "INPAYMENTS_SEPA_MANDATE_CREATED", "INSTRUCTION_CORPORATE_ACTION", "JUNIOR_ONBOARDING_GUARDIAN_B_CONSENT", - "GENERAL_MEETING", - "GESH_CORPORATE_ACTION", "MATURITY", + "NEW_TR_IBAN", "ORDER_CANCELED", "ORDER_CREATED", "ORDER_EXPIRED", "ORDER_REJECTED", "PRE_DETERMINED_TAX_BASE_EARNING", + "PRIVATE_MARKET_FUND_ORDER_RECEIVED", + "PRIVATE_MARKETS_SUITABILITY_QUIZ_COMPLETED", "PUK_CREATED", + "QUARTERLY_NET_WORTH_STATEMENT_CREATED", "QUARTERLY_REPORT", "RDD_FLOW", "REFERENCE_ACCOUNT_CHANGED", @@ -193,47 +221,54 @@ class PPEventType(EventType): "SECURITIES_ACCOUNT_CREATED", "SHAREBOOKING", "SHAREBOOKING_TRANSACTIONAL", + "SSP_CAPITAL_INCREASE_CUSTOMER_INSTRUCTION", + "SSP_CORPORATE_ACTION_INFORMATIVE", + "SSP_CORPORATE_ACTION_INFORMATIVE_NOTIFICATION", + "SSP_CORPORATE_ACTION_INSTRUCTION", + "SSP_CORPORATE_ACTION_UPCOMING", + "SSP_DIVIDEND_OPTION_CUSTOMER_INSTRUCTION", + "SSP_GENERAL_MEETING_CUSTOMER_INSTRUCTION", + "SSP_TENDER_OFFER_CUSTOMER_INSTRUCTION", "STOCK_PERK_REFUNDED", "TAX_YEAR_END_REPORT", "TAX_YEAR_END_REPORT_CREATED", + "TRADING_ORDER_CANCELLED", + "TRADING_ORDER_CREATED", + "TRADING_ORDER_EXPIRED", + "TRADING_ORDER_REJECTED", + "TRADING_SAVINGSPLAN_EXECUTION_FAILED", + "TRADING_SAVINGSPLAN_EXECUTION_PENDING", "VERIFICATION_TRANSFER_ACCEPTED", "YEAR_END_TAX_REPORT", - "card_failed_verification", - "card_successful_verification", - "crypto_annual_statement", - "current_account_activated", - "new_tr_iban", - "private_markets_suitability_quiz_completed", - "ssp_general_meeting_customer_instruction", - "ssp_tender_offer_customer_instruction", - "trading_order_cancelled", - "trading_order_created", - "trading_order_expired", - "trading_order_rejected", - "trading_savingsplan_execution_failed", - "ssp_capital_increase_customer_instruction", - "ssp_corporate_action_informative_notification", - "ssp_dividend_option_customer_instruction", ] events_known_ignored_title = [ + "Auszahlungskonto", + "Basisinformationen", "Crypto Jahresaufstellung", + "E-Mail", "Eignungsprüfung", "Ex-Post Kosteninformation", "Jährlicher Steuerreport", "Neue IBAN", + "Neues Gerät", "Persönliche Daten", "PUK versendet", "Rechtliche Dokumente", "Überprüfung der Identität", + "Wertpapierdepot", ] events_known_ignored_subtitle = [ + "Außerordentliche oder spezielle Hauptversammlung", "Cash oder Aktie", + "Dividende. Cash oder Stockdividende?", "Erteilt", + "Fall abgeschlossen", "Jährliche Hauptversammlung", "Kartenprüfung", "Kauf-Abrechnung storniert", + "Kauforder abgelehnt", "Kauforder storniert", "Limit-Buy-Order abgelaufen", "Limit-Buy-Order erstellt", @@ -251,6 +286,45 @@ class PPEventType(EventType): "Verkaufsorder abgelehnt", ] +_note_to_isin: dict[str, str] = { + "BlackRock Funding": "US09290D1019", + "BYD": "CNE100000296", + "Chipotle": "US1696561059", + "Eckert & Ziegler": "DE0005659700", + "Enovix Corp. WTS 01.10.26": "US2935941318", + "Gamestop Corp. WTS 30.10.26": "US36467W1172", + "GLOBALSTAR INC. O.N.": "US3789735079", + "Honeywell Aerospace": "US43849R1059", + "HONEYWELL AEROSPACE INC.": "US43849R1059", + "Magnum Ice Cream": "NL0015002MS2", + "Netflix": "US64110L1061", + "NVIDIA": "US67066G1040", + "OHB": "DE000A41YFG5", + "Orsted": "DK0060094928", + "ORSTED A/S -ANR-": "DK0064307839", + "ORSTED A/S EM.09/25 DK 10": "DK0064307755", + "ROCKET LAB CORP. O.N.": "US7731211089", + "tk accelis": "DE000TKCC1S8", + "TKMS": "DE000TKMS001", + "Unilever": "GB00BVZK7T90", + "VERSANT MEDIA GRP A O.N.": "US9252831030", + "Worldline": "FR0014015MS9", +} + +# Overrides for SWAP events where the target ISIN differs from the spinoff case. +_swap_note_to_isin_overrides: dict[str, str] = { + "Worldline": "FR0011981968", +} + +# Known ISIN renames/swaps: old ISIN -> new ISIN. +# Used to resolve paired TR swap events (one event per ISIN) into a single SWAP transaction. +_swap_old_to_new_isin: dict[str, str] = { + "DE0005785604": "DE000FRE5EN2", # Fresenius SE ISIN change 2026-08 + "IE000BI8OT95": "LU1781541179", # MSCI World USD (Acc) fund change + "US4385161066": "US4385162056", # Honeywell International reverse split 2026 + "US8816242098": "IL0006290147", # Teva ADR → Israeli ordinary share 2026-09 +} + logger = None @@ -285,107 +359,161 @@ def from_dict(cls, event_dict: Dict[Any, Any]): Returns: Event: Event object """ + event_type: Optional[EventType] = None ts = event_dict["timestamp"] ts = ts[:-2] + ":" + ts[-2:] date: datetime = datetime.fromisoformat(ts) title: str = event_dict["title"] - isin: Optional[str] = None + isin: Optional[str] = cls._parse_isin(event_dict) isin2: Optional[str] = None shares: Optional[float] = None shares2: Optional[float] = None - value: Optional[float] = None + value: Optional[float] = event_dict.get("amount", {}).get("value", None) fees: Optional[float] = None taxes: Optional[float] = None note: Optional[str] = None + + eventTypeStr = (event_dict.get("eventType") or "").upper() subtitle = event_dict["subtitle"] eventdesc = f"{title} {subtitle} ({event_dict['id']})" dump_dict = {"eventdesc": eventdesc, "id": event_dict["id"]} pref_locale = "de" + ignoreEvent = False + + # Get sections and some special dicts from it ( + gesamt_dict, + uebersicht_dict, + shares_dict, + shares_dict2, + wertpapier_dict, + wertpapier_dict2, + quotation_dict, fees_dict, taxes_dict, - wertpapier_dict, - ) = (None,) * 3 - + ) = (None,) * 9 sections = event_dict.get("details", {}).get("sections", [{}]) - - transaction_dict = next(filter(lambda x: x.get("title") in ["Transaktion", "Geschäft"], sections), None) + transaction_dict = next( + filter(lambda x: x.get("title") in ["Transaktion", "Geschäft", "Transaction"], sections), None + ) if transaction_dict: # old style event dump_dict["maintitle"] = transaction_dict["title"] data = transaction_dict.get("data", [{}]) - fees_dict = next(filter(lambda x: x["title"] == "Gebühr", data), None) + shares_dict = next(filter(lambda x: x["title"] in ["Aktien", "Anteile", "Shares"], data), None) + fees_dict = next(filter(lambda x: x["title"] in ["Gebühr", "Fee"], data), None) taxes_dict = next(filter(lambda x: x["title"] in ["Steuer", "Steuern"], data), None) - uebersicht_dict = next(filter(lambda x: x.get("title") in ["Übersicht", "Overview"], sections), None) + uebersicht_dict = next( + filter(lambda x: x.get("title") in ["Überblick", "Übersicht", "Overview"], sections), None + ) if uebersicht_dict: # new style event for item in uebersicht_dict.get("data", []): ititle = item.get("title") - if ititle == "Gebühr" and not fees_dict: + if ititle == "Gesamt": + gesamt_dict = item + elif ititle == "Gebühr" and not fees_dict: fees_dict = item - elif ititle == "Steuer" and not taxes_dict: + elif ititle in ["Steuer", "Steuern"] and not taxes_dict: taxes_dict = item - elif ititle in ["Wertpapier", "Asset"] and not wertpapier_dict: + elif ititle in ["Vermögenswert", "Wertpapier", "Asset"] and not wertpapier_dict: wertpapier_dict = item + elif ititle in ["Vermögenswert", "Wertpapier", "Asset"] and wertpapier_dict and not wertpapier_dict2: + wertpapier_dict2 = item + elif ititle in ["Aktien", "Aktien entfernt", "Aktien hinzugefügt", "Shares"] and not shares_dict: + shares_dict = item + elif ( + ititle in ["Aktien", "Aktien entfernt", "Aktien hinzugefügt", "Shares"] + and shares_dict + and not shares_dict2 + ): + shares_dict2 = item + elif ititle == "Transaktion" and not transaction_dict: + transaction_dict = item + sections = item.get("detail", {}).get("action", {}).get("payload", {}).get("sections", []) - event_type: Optional[EventType] = None - eventTypeStr = event_dict.get("eventType", "") - if eventTypeStr == "timeline_legacy_migrated_events": - event_type = timeline_legacy_migrated_events_title_type_mapping.get(title) - if event_type is None: - event_type = timeline_legacy_migrated_events_subtitle_type_mapping.get(subtitle) - if event_type is None: - for item in event_dict.get("details", {}).get("sections", []): - ititle = item.get("title", "") - if ititle.startswith("Du hast "): - if ititle.endswith(" erhalten"): - event_type = PPEventType.DEPOSIT - break - elif ititle.endswith(" gesendet"): - event_type = PPEventType.REMOVAL - break - if event_type is None: - print(f"unmatched timeline_legacy_migrated_events: {eventdesc}") - elif eventTypeStr == "ssp_corporate_action_invoice_shares": - if subtitle in [ - "Aktiendividende", - "Spin-off", - "Zwischenvertrieb von Wertpapieren", - ]: - event_type = PPEventType.SPINOFF - elif subtitle == "Bonusaktien": - event_type = PPEventType.SPLIT - elif subtitle in ["Reverse Split", "Teilrückzahlung ohne Reduzierung des Poolfaktors", "Zusammenschluss"]: - event_type = PPEventType.SWAP - elif subtitle == "Wertlos": - event_type = ConditionalEventType.TRADE_INVOICE - elif eventTypeStr == "ssp_corporate_action_invoice_cash": - if subtitle == "Aufruf von Zwischenpapieren": - event_type = PPEventType.SWAP - elif subtitle in [ - "Aktienprämiendividende", - "Bardividende", - "Bardividende korrigiert", - "Dividende Wahlweise", - "Tilgung", - ]: - event_type = PPEventType.DIVIDEND - else: - event_type = PPEventType.TAXES - else: - event_type = tr_event_type_mapping.get(eventTypeStr, None) + for section in sections: + if section.get("type") == "table": + for subitem in section.get("data", []): + if subitem.get("title") == "Aktien" and not shares_dict: + shares_dict = subitem + elif subitem.get("title") == "Quotation" and not quotation_dict: + quotation_dict = subitem + + # Most Trade republic events have an EventType and can be directly mapped with it. + event_type = tr_event_type_mapping.get(eventTypeStr, None) + + # We support some older eventType entries which might not exist any more in current TR data. + # We could consider removing this if block some time in the future. if event_type is None: + if eventTypeStr == "TIMELINE_LEGACY_MIGRATED_EVENTS": + event_type = timeline_legacy_migrated_events_title_type_mapping.get(title) + if event_type is None: + event_type = timeline_legacy_migrated_events_subtitle_type_mapping.get(subtitle) + if event_type is None and subtitle != "Wertpapiertransfer": + for item in event_dict.get("details", {}).get("sections", []): + ititle = item.get("title", "") + if ititle.startswith("Du hast "): + if ititle.endswith(" erhalten") and "Angebot" not in ititle: + event_type = PPEventType.DEPOSIT + break + elif ititle.endswith(" gesendet"): + event_type = PPEventType.REMOVAL + break + elif eventTypeStr == "SSP_CORPORATE_ACTION_INVOICE_SHARES": + if subtitle in [ + "Aktiendividende", + "Spin-off", + "Zwischenvertrieb von Wertpapieren", + ]: + event_type = PPEventType.SPINOFF + elif subtitle == "Bonusaktien": + event_type = PPEventType.SPLIT + elif subtitle in [ + "Reverse Split", + "Teilrückzahlung ohne Reduzierung des Poolfaktors", + "Zusammenschluss", + ]: + event_type = PPEventType.SWAP + elif subtitle == "Wertlos": + event_type = ConditionalEventType.TRADE_INVOICE + elif eventTypeStr in ["SSP_CORPORATE_ACTION_INVOICE_CASH", "SSP_CORPORATE_ACTION_CASH"]: + if subtitle == "Aufruf von Zwischenpapieren": + event_type = PPEventType.SWAP + elif value is not None and value < 0: + event_type = PPEventType.TAXES + else: + event_type = PPEventType.DIVIDEND + + # Now try to deduct the event type from the title if we still don't have one + if event_type is None and eventTypeStr not in events_known_ignored: event_type = title_event_type_mapping.get(title, None) - if event_type is None: + + # Now try to deduct the event type from the subtitle if we still don't have one + if event_type is None and eventTypeStr not in events_known_ignored: event_type = subtitle_event_type_mapping.get(subtitle, None) - if event_type == ConditionalEventType.PRIVATE_MARKETS_ORDER and subtitle == "Vorabpauschale": - event_type = PPEventType.TAXES - if event_type is None and uebersicht_dict: + + # Handle "Wertpapiertransfer" which can be either TRANSFER_IN or TRANSFER_OUT + if event_type is None and subtitle == "Wertpapiertransfer" and sections: + for item in sections: + ititle = item.get("title") + if ititle is None: + continue + if "Aktien erhalten" in ititle or "erhalten" in ititle: + event_type = PPEventType.TRANSFER_IN + break + elif "Aktien gesendet" in ititle or "gesendet" in ititle: + event_type = PPEventType.TRANSFER_OUT + break + + # If still no event type, try to deduce it from the overview section + if event_type is None and uebersicht_dict and eventTypeStr not in events_known_ignored: for item in uebersicht_dict.get("data", []): ititle = item.get("title") - if ititle == "Kartenzahlung": - event_type = PPEventType.REMOVAL + if ititle in ["Kartenzahlung", "Zahlung"]: + if event_type is None: + event_type = PPEventType.REMOVAL elif ititle in ["Überweisung", "Kartenerstattung", "Überweisen"]: if sections: for item in sections: @@ -394,22 +522,26 @@ def from_dict(cls, event_dict: Dict[Any, Any]): continue if "gesendet" in ititle: event_type = PPEventType.REMOVAL - elif "erhalten" in ititle: + elif "erhalten" in ititle and "Angebot" not in ititle: event_type = PPEventType.DEPOSIT elif ititle == "Event": if item.get("detail", {}).get("text", "") == "Bonusaktien": event_type = PPEventType.DIVIDEND - if event_type is None and sections: + # If still no event type, try to deduce it from the sections + if event_type is None and sections and eventTypeStr not in events_known_ignored: for item in sections: ititle = item.get("title") if ititle is None: continue - elif "Du hast" in ititle and "€" in ititle and "erhalten" in ititle: + elif "Du hast" in ititle and "€" in ititle and "erhalten" in ititle and "Angebot" not in ititle: event_type = PPEventType.DEPOSIT elif "Du hast" in ititle and "€" in ititle and "gesendet" in ititle: event_type = PPEventType.REMOVAL + # Some events can be TAX events sometimes + if event_type is ConditionalEventType.PRIVATE_MARKETS_ORDER and subtitle == "Vorabpauschale": + event_type = PPEventType.TAXES if event_type is PPEventType.SPLIT and subtitle == "Bonusaktien" and uebersicht_dict: for item in uebersicht_dict.get("data", []): if item.get("title") == "Event" and item.get("detail", {}).get("text", "") == "Bonusaktien": @@ -422,235 +554,74 @@ def from_dict(cls, event_dict: Dict[Any, Any]): ]: event_type = PPEventType.TAXES - ignoreEvent = False - if sections: - for item in sections: - ititle = item.get("title") - if ititle is None: - continue - if ( - ititle - in [ - "Deine Karte wurde verifiziert", - "Die Kartenüberprüfung ist fehlgeschlagen", - "Du hast dein Girokonto aktiviert", - "Du hast eine Kapitalma\u00dfnahme erhalten", - "You received an offer to participate in a capital increase", - "You're invited to a general meeting", - ] - or ititle.startswith("Du hast ein Angebot zum Verkauf von Aktien") - or ititle.startswith("You received an offer to sell shares") - ): - ignoreEvent = True - - if title == "Auszahlungskonto" and subtitle == "Geändert": - ignoreEvent = True - if title == "Neues Gerät" and subtitle == "Gekoppelt": - ignoreEvent = True - if title == "Wertpapierdepot" and subtitle == "Eröffnet": - ignoreEvent = True - if title == "Basisinformationen" and subtitle == "Erhalten": - ignoreEvent = True - if title == "E-Mail" and subtitle == "Bestätigt": - ignoreEvent = True - if eventTypeStr == "PRIVATE_MARKET_FUND_ORDER_RECEIVED": - event_type = None - ignoreEvent = True - - if event_type is not None and event_dict.get("status", "").lower() == "canceled": - event_type = None - elif ( + # Canceled Events should be ignored, even if they have an event type + if event_type is not None: + if event_dict.get("status", "").lower() == "canceled": + event_type = None + ignoreEvent = True + elif sections: + for section in sections: + if section.get("type") == "header": + header_status = section.get("data", {}).get("status", "").lower() + if header_status == "canceled": + event_type = None + ignoreEvent = True + break + + # Now print a warning if we still don't have an event type and the event is not known to be ignorable + if ( event_type is None and eventTypeStr not in events_known_ignored and title not in events_known_ignored_title and subtitle not in events_known_ignored_subtitle and not ignoreEvent ): - get_event_logger().warning(f'Ignoring unknown event "{eventdesc}"') - get_event_logger().debug("Unknown event %s: %s", eventdesc, json.dumps(event_dict, indent=4)) - + if sections: + for item in sections: + ititle = item.get("title") + if ititle is None: + continue + if ( + ititle + in [ + "Deine Karte wurde verifiziert", + "Die Kartenüberprüfung ist fehlgeschlagen", + "Du hast dein Girokonto aktiviert", + "Du hast eine Kapitalma\u00dfnahme erhalten", + "You received an offer to participate in a capital increase", + "You're invited to a general meeting", + ] + or ititle.startswith("Du hast ein Angebot zum Verkauf von Aktien") + or ititle.startswith("You received an offer to sell shares") + ): + ignoreEvent = True + + if not ignoreEvent: + get_event_logger().warning(f'Ignoring unknown event "{eventdesc}"') + get_event_logger().debug("Unknown event %s: %s", eventdesc, json.dumps(event_dict, indent=4)) + + # Return an empty Event object if we don't have an event type, as we can't parse the rest of the fields without it if event_type is None: return cls(event_type, date, title, isin, isin2, shares, shares2, value, fees, taxes, note) - # parse fees - if fees_dict: - dump_dict["subtitle"] = fees_dict["title"] - dump_dict["type"] = "fees" - fees = cls._parse_float_from_text_value(fees_dict.get("detail", {}).get("text", ""), dump_dict) - elif event_type not in [ - ConditionalEventType.SAVEBACK, - PPEventType.DEPOSIT, - PPEventType.DIVIDEND, - PPEventType.INTEREST, - PPEventType.REMOVAL, - PPEventType.SPINOFF, - PPEventType.SPLIT, - PPEventType.SWAP, - PPEventType.TAX_REFUND, - PPEventType.TAXES, - ] and subtitle not in [ - "Aufruf von Zwischenpapieren", - "Wertlos", - ]: - get_event_logger().warning("Could not parse fees from %s", eventdesc) - get_event_logger().debug("Failed to parse fees from %s", json.dumps(event_dict, indent=4)) - - # parse taxes - if taxes_dict: - dump_dict["subtitle"] = taxes_dict["title"] - dump_dict["type"] = "taxes" - taxes = cls._parse_float_from_text_value( - taxes_dict.get("detail", {}).get("text", ""), dump_dict, pref_locale - ) - if taxes and taxes < 0: - taxes = -taxes - - if isinstance(event_type, ConditionalEventType) or event_type in [ - PPEventType.DIVIDEND, - PPEventType.SPINOFF, - PPEventType.SPLIT, - PPEventType.SWAP, - PPEventType.TAXES, - ]: - # Parse ISIN - for section in sections: - action = section.get("action", None) - if action and action.get("type", {}) == "instrumentDetail": - isin = section.get("action", {}).get("payload") - break - if section.get("type", {}) == "header": - isin = section.get("data", {}).get("icon") - if isinstance(isin, dict): - isin = isin.get("asset", "") - break - if isin is None: - isin = event_dict.get("icon", "") - isin = isin[isin.find("/") + 1 :] - isin = isin.split("/", 1)[0] - - shares, shares2, value, note = cls._parse_shares_value_note(event_type, event_dict) - else: - value = v if (v := event_dict.get("amount", {}).get("value", None)) is not None and v != 0.0 else None - - if event_type in [PPEventType.DEPOSIT, PPEventType.REMOVAL]: - note = cls._parse_card_note(event_dict) - - if event_type == ConditionalEventType.PRIVATE_MARKETS_ORDER: - if value is None: - shares = 0 - else: - shares = abs(value) / 100 - if fees is not None: - shares = shares - (abs(fees) / 100) - note = event_dict["subtitle"] - - if event_type is PPEventType.SWAP and uebersicht_dict: - foundentfernt = False - for item in uebersicht_dict.get("data", []): - ititle = item.get("title") - if ititle == "Aktien entfernt": - foundentfernt = True - if not foundentfernt: - event_type = ConditionalEventType.TRADE_INVOICE - if title == "WORLDLINE S.A. ANR": - title = "Worldline" - isin = "FR0011981968" - note = None - - if ( - subtitle == "Zusammenschluss" - and title == "Deine Aktien waren von einer Kapitalmaßnahme betroffen" - and wertpapier_dict - ): - title = wertpapier_dict["detail"]["text"] - - return cls(event_type, date, title, isin, isin2, shares, shares2, value, fees, taxes, note) - - @classmethod - def _parse_shares_value_note( - cls, event_type: Optional[EventType], event_dict: Dict[Any, Any] - ) -> Tuple[ - Optional[float], - Optional[float], - Optional[float], - Optional[str], - ]: - """Parses the amount of shares, value and note - - Args: - event_dict (Dict[Any, Any]): _description_ - - Returns: - Tuple[Optional[float]]: shares, value, note - """ - ( - shares, - shares2, - note, - gesamt_dict, - uebersicht_dict, - shares_dict, - shares_dict2, - wertpapier_dict, - wertpapier_dict2, - quotation_dict, - ) = (None,) * 10 - - value: Optional[float] = v if (v := event_dict.get("amount", {}).get("value", None)) is not None else None - - title = event_dict["title"] - subtitle = event_dict["subtitle"] - eventdesc = f"{title} {subtitle} ({event_dict['id']})" - eventTypeStr = event_dict.get("eventType", "") - - dump_dict = {"eventdesc": eventdesc} - - sections = event_dict.get("details", {}).get("sections", [{}]) - - transaction_dict = next(filter(lambda x: x.get("title") in ["Transaktion", "Geschäft"], sections), None) - if transaction_dict: - # old style event - dump_dict["maintitle"] = transaction_dict["title"] - data = transaction_dict.get("data", [{}]) - shares_dict = next(filter(lambda x: x["title"] in ["Aktien", "Anteile"], data), None) - - uebersicht_dict = next(filter(lambda x: x.get("title") in ["Übersicht", "Overview"], sections), None) - if uebersicht_dict: - # new style event - for item in uebersicht_dict.get("data", []): - ititle = item.get("title") - if ititle == "Gesamt": - gesamt_dict = item - elif ititle in ["Wertpapier", "Asset"] and not wertpapier_dict: - wertpapier_dict = item - elif ititle in ["Wertpapier", "Asset"] and wertpapier_dict and not wertpapier_dict2: - wertpapier_dict2 = item - elif ititle in ["Aktien entfernt", "Aktien hinzugefügt", "Shares"] and not shares_dict: - shares_dict = item - elif ititle in ["Aktien entfernt", "Aktien hinzugefügt", "Shares"] and shares_dict and not shares_dict2: - shares_dict2 = item - elif ititle == "Transaktion" and not transaction_dict: - transaction_dict = item - sections = item.get("detail", {}).get("action", {}).get("payload", {}).get("sections", []) - - for section in sections: - if section.get("type") == "table": - for subitem in section.get("data", []): - if subitem.get("title") == "Aktien" and not shares_dict: - shares_dict = subitem - elif subitem.get("title") == "Quotation" and not quotation_dict: - quotation_dict = subitem - + # parse shares if shares_dict: dump_dict["subtitle"] = shares_dict["title"] dump_dict["type"] = "shares" pref_locale = ( "en" if ( - event_type in [PPEventType.DIVIDEND, ConditionalEventType.SAVEBACK, PPEventType.SPINOFF] + event_type + in [ + PPEventType.DIVIDEND, + ConditionalEventType.SAVEBACK, + PPEventType.SPINOFF, + PPEventType.TRANSFER_IN, + PPEventType.TRANSFER_OUT, + ] or eventTypeStr in [ - "benefits_spare_change_execution", + "BENEFITS_SPARE_CHANGE_EXECUTION", ] or subtitle in [ @@ -660,6 +631,7 @@ def _parse_shares_value_note( "Aktiensplit", "Bonusaktien", "Reverse Split", + "Tausch", "Teilrückzahlung ohne Reduzierung des Poolfaktors", "Zusammenschluss", ] @@ -689,7 +661,7 @@ def _parse_shares_value_note( elif ( ( event_type in [ConditionalEventType.SAVEBACK] - or eventTypeStr in ["benefits_spare_change_execution", "ACQUISITION_TRADE_PERK"] + or eventTypeStr in ["BENEFITS_SPARE_CHANGE_EXECUTION", "ACQUISITION_TRADE_PERK"] or subtitle == "Round up" or title == "Aktien-Bonus" ) @@ -702,27 +674,15 @@ def _parse_shares_value_note( if (eventTypeStr == "ACQUISITION_TRADE_PERK" or title == "Aktien-Bonus") and gesamt_dict: value = cls._parse_float_from_text_value(gesamt_dict.get("detail", {}).get("text", ""), dump_dict) value = -value if value is not None else None - elif ( - eventTypeStr - not in [ - "ssp_corporate_action_invoice_cash", - "private_markets_order_created", - "private_markets_trade_executed", - ] - and title != "Private Equity" - and subtitle != "Aktienprämiendividende" - and event_type not in [PPEventType.DIVIDEND, PPEventType.TAXES] - ): - get_event_logger().warning("Could not parse shares from %s", eventdesc) - get_event_logger().debug("Failed to parse shares from: %s", json.dumps(event_dict, indent=4)) - if eventTypeStr == "ACQUISITION_TRADE_PERK" or title == "Aktien-Bonus": - value = 0 - shares = 0 + + if (eventTypeStr == "ACQUISITION_TRADE_PERK" or title == "Aktien-Bonus") and shares is None: + value = 0 + shares = 0 if (event_type == PPEventType.SPINOFF or subtitle == "Wertlos") and value is None: value = 0 - if event_type in [PPEventType.SPLIT, PPEventType.SWAP] and value is None: + if event_type in [PPEventType.SPLIT, PPEventType.SWAP, PPEventType.TRANSFER_IN] and value is None: value = 0 if event_type in [PPEventType.SPINOFF, PPEventType.SWAP]: @@ -731,33 +691,165 @@ def _parse_shares_value_note( elif wertpapier_dict: note = wertpapier_dict["detail"]["text"] - return shares, shares2, value, note + if event_type == PPEventType.SPINOFF: + isin2 = isin + isin = _note_to_isin.get(note, isin2) if note else isin2 + elif event_type == PPEventType.SWAP: + if isin in _swap_old_to_new_isin: + isin2 = _swap_old_to_new_isin[isin] + elif isin in _swap_old_to_new_isin.values(): + # Duplicate event for the new ISIN side — suppress it; the old-ISIN event is canonical + event_type = None + ignoreEvent = True + else: + isin2 = (_swap_note_to_isin_overrides.get(note) or _note_to_isin.get(note, note)) if note else None - @staticmethod - def _parse_card_note(event_dict: Dict[Any, Any]) -> Optional[str]: - """Parses the note associated with card transactions + # parse fees + if fees_dict: + dump_dict["subtitle"] = fees_dict["title"] + dump_dict["type"] = "fees" + fees = cls._parse_float_from_text_value(fees_dict.get("detail", {}).get("text", ""), dump_dict) - Args: - event_dict (Dict[Any, Any]): _description_ + # parse taxes + if taxes_dict: + dump_dict["subtitle"] = taxes_dict["title"] + dump_dict["type"] = "taxes" + taxes = cls._parse_float_from_text_value(taxes_dict.get("detail", {}).get("text", ""), dump_dict, "de") + if taxes and taxes < 0: + taxes = -taxes - Returns: - Optional[str]: note - """ - eventTypeStr = event_dict.get("eventType", "") - if eventTypeStr.startswith("card_"): - return eventTypeStr + if event_type in [PPEventType.TRANSFER_IN, PPEventType.TRANSFER_OUT]: + if transaction_dict: + for item in transaction_dict.get("data", []): + if item.get("title") in ["Shares", "Aktien"]: + shares = cls._parse_float_from_text_value(item.get("detail", {}).get("text", ""), {}, "en") + + if shares is None and uebersicht_dict: + for item in uebersicht_dict.get("data", []): + # "Aktien" for newer events, "Anteile" for older Wertpapiertransfer events + if item.get("title") in ["Aktien", "Shares", "Anteile"]: + shares = cls._parse_float_from_text_value(item.get("detail", {}).get("text", ""), {}, "en") + value = 0 # Transfers have no monetary value + + if event_type in [PPEventType.DEPOSIT, PPEventType.REMOVAL]: + if eventTypeStr is not None and eventTypeStr.startswith("CARD_"): + note = eventTypeStr + + if uebersicht_dict: + for item in uebersicht_dict.get("data", []): + if item.get("title") == "Kartenzahlung": + note = "card_successful_transaction" + elif item.get("title") == "Kartenerstattung": + note = "card_refund" + + if event_type == ConditionalEventType.PRIVATE_MARKETS_ORDER: + if shares is None: + if value is None: + shares = 0 + elif fees is not None: + shares = (abs(value) - abs(fees)) / 100 + else: + shares = abs(value) / 100 + subtitle_note = event_dict["subtitle"] + if subtitle_note != "1 % Bonus" and isin == "LU3176111881": + note = "EQT" + elif subtitle_note != "1 % Bonus" and isin == "LU3170240538": + note = "Apollo" + else: + note = subtitle_note + + if event_type == PPEventType.TAXES and subtitle == "Vorabpauschale": + if isin == "LU3176111881": + note = "EQT" + elif isin == "LU3170240538": + note = "Apollo" + + if event_type is PPEventType.SWAP: + if not uebersicht_dict: + event_type = None + ignoreEvent = True + else: + foundentfernt = False + for item in uebersicht_dict.get("data", []): + ititle = item.get("title") + if ititle == "Aktien entfernt": + foundentfernt = True + if not foundentfernt: + event_type = ConditionalEventType.TRADE_INVOICE + isin2 = None + if title == "WORLDLINE S.A. ANR": + title = "Worldline" + isin = "FR0011981968" + note = None + if ( + subtitle == "Zusammenschluss" + and title == "Deine Aktien waren von einer Kapitalmaßnahme betroffen" + and wertpapier_dict + ): + title = wertpapier_dict["detail"]["text"] + + if ( + fees is None + and event_type + in [ + ConditionalEventType.PRIVATE_MARKETS_ORDER, + ConditionalEventType.TRADE_INVOICE, + ] + and subtitle + not in ["Wertlos", "Round up", "1 % Bonus", "Sparplan ausgeführt", "Aufruf von Zwischenpapieren"] + and eventTypeStr not in ["BENEFITS_SPARE_CHANGE_EXECUTION"] + ): + get_event_logger().warning("Could not parse fees from %s", eventdesc) + get_event_logger().debug("Failed to parse fees from %s", json.dumps(event_dict, indent=4)) + + if ( + shares is None + and event_type + in [ + ConditionalEventType.PRIVATE_MARKETS_ORDER, + ConditionalEventType.SAVEBACK, + ConditionalEventType.TRADE_INVOICE, + PPEventType.BUY, + PPEventType.DIVIDEND, + PPEventType.SELL, + PPEventType.SPINOFF, + PPEventType.SPLIT, + PPEventType.SWAP, + PPEventType.TRANSFER_IN, + PPEventType.TRANSFER_OUT, + ] + and subtitle not in ["Aktienprämiendividende", "Bardividende korrigiert", "Dividende Wahlweise", "Tilgung"] + ): + get_event_logger().warning("Could not parse shares from %s", eventdesc) + get_event_logger().debug("Failed to parse shares from: %s", json.dumps(event_dict, indent=4)) + + return cls(event_type, date, title, isin, isin2, shares, shares2, value, fees, taxes, note) + + @staticmethod + def _parse_isin(event_dict: Dict[Any, Any]) -> Optional[str]: + """Parses the ISIN from a transfer or corporate-action event""" sections = event_dict.get("details", {}).get("sections", [{}]) - uebersicht_dict = next(filter(lambda x: x.get("title") in ["Übersicht"], sections), None) - # Iterate over the top-level data list - if uebersicht_dict: - for item in uebersicht_dict.get("data", []): - if item.get("title") == "Kartenzahlung": - return "card_successful_transaction" - elif item.get("title") == "Kartenerstattung": - return "card_refund" - return None + for section in sections: + action = section.get("action", None) + if action and action.get("type", {}) == "instrumentDetail": + isin = action.get("payload") + break + if section.get("type", {}) == "header": + isin = section.get("data", {}).get("icon") + if isinstance(isin, dict): + isin = isin.get("asset", "") + break + else: + isin = event_dict.get("icon", "") + + if not isin: + return None + + isin = isin[isin.find("/") + 1 :] + isin = isin.split("/", 1)[0] + return isin if re.match(r"^[A-Z]{2}[A-Z0-9]{10}$", isin) else None @staticmethod def _parse_float_from_text_value( diff --git a/pytr/gui.py b/pytr/gui.py new file mode 100644 index 00000000..4fe0bfe5 --- /dev/null +++ b/pytr/gui.py @@ -0,0 +1,1621 @@ +"""Windows GUI for pytr – Trade Republic CLI tool.""" + +import asyncio +import io +import os +import queue +import re +import tempfile +import threading +import time +import tkinter as tk +from datetime import datetime, timedelta +from importlib.metadata import version +from pathlib import Path +from tkinter import filedialog, messagebox, scrolledtext, ttk +from typing import Any + +from .alarms import Alarms +from .api import BASE_DIR, CREDENTIALS_FILE, TradeRepublicApi +from .details import Details +from .dl import DL +from .event import Event +from .portfolio import PORTFOLIO_COLUMNS, Portfolio +from .savings_plans import SavingsPlans +from .timeline import Timeline +from .transactions import SUPPORTED_LANGUAGES, TransactionExporter +from .utils import get_logger + +_ANSI = re.compile(r"\x1B(?:[@-Z\\-_]|\[[0-?]*[ -/]*[@-~])") +_ISIN_RE = re.compile(r"^[A-Za-z]{2}[A-Za-z0-9]{10}$") + +_ASSET_TYPES = ["stock", "etf", "fund", "crypto", "bond", "derivative"] + +# --------------------------------------------------------------------------- +# Details: suppress raw JSON and replace with formatted output +# --------------------------------------------------------------------------- + +_STOPPED = "__stopped__" + + +class _GUIDetails(Details): + """Details subclass: two-phase fetch (exchange-agnostic first, then ticker/perf + using the exchange reported by the instrument), with stop-event support.""" + + async def details_loop(self, stop_event: threading.Event | None = None) -> None: # type: ignore[name-defined] + tr = self.tr + # Clear stale subscriptions from previous operations so recv() can't stall + # waiting for IDs that a freshly-reconnected server has never seen. + tr.subscriptions.clear() + tr._previous_responses.clear() + + def check_stop() -> None: + if stop_event and stop_event.is_set(): + raise RuntimeError(_STOPPED) + + async def drain(waiting: set) -> None: + """Keep calling recv() until all IDs in *waiting* have been answered or + cancelled by the server. Exits early if stop is requested.""" + while waiting: + check_stop() + # Detect subscriptions silently cancelled by server (C frames) + cancelled = waiting - set(tr.subscriptions.keys()) + waiting -= cancelled + if not waiting: + break + try: + sid, sub, response = await asyncio.wait_for(tr.recv(), timeout=2.0) + except asyncio.TimeoutError: + continue # re-check stop + cancellations + if sid not in waiting: + continue + t = sub["type"] + if t == "instrument": + self.instrument = response + elif t == "instrumentSuitability": + self.instrumentSuitability = response + elif t == "stockDetails": + self.stockDetails = response + elif t == "neonNews": + self.neonNews = response + elif t == "ticker": + self.ticker = response + elif t == "performance": + self.performance = response + waiting.discard(sid) + try: + await tr.unsubscribe(sid) + except Exception: + pass + + # ── Phase 1: data that doesn't need an exchange ID ────────────────── + phase1: set = { + await tr.instrument_details(self.isin), + await tr.instrument_suitability(self.isin), + await tr.stock_details(self.isin), + await tr.news(self.isin), + } + await drain(phase1) + check_stop() + + # ── Phase 2: ticker + performance using the instrument's own exchange ─ + # Using the hardcoded "LSX" exchange fails silently for crypto (and any + # asset not listed there): the server sends a C-frame, recv() discards + # it, and the loop stalls forever waiting for a response that never arrives. + exchange = "LSX" + inst = getattr(self, "instrument", None) or {} + eids = inst.get("exchangeIds") or [ex.get("id") for ex in (inst.get("exchanges") or []) if ex.get("id")] + if eids: + exchange = eids[0] + + phase2: set = { + await tr.ticker(self.isin, exchange=exchange), + await tr.performance(self.isin, exchange=exchange), + } + await drain(phase2) + + await tr.close() + + +def _print_details(d: _GUIDetails) -> None: + """Render a Details object as human-readable text to stdout.""" + W = 62 + + def section(title: str) -> None: + print(f"\n {title}") + print(f" {'─' * (W - 2)}") + + inst = getattr(d, "instrument", {}) or {} + name = inst.get("name") or inst.get("shortName") or d.isin + short = inst.get("shortName", "") + typ = inst.get("typeId", "") + + print(f"\n{'═' * W}") + print(f" {name}") + if short and short != name: + print(f" ({short})") + print(f" ISIN: {d.isin} Type: {typ}") + print(f"{'═' * W}") + + # Price + ticker = getattr(d, "ticker", {}) or {} + if ticker: + last = ticker.get("last", {}) or {} + price = last.get("price") + bid = (ticker.get("bid") or {}).get("price") + ask = (ticker.get("ask") or {}).get("price") + if price is not None: + print(f"\n Price : {price}") + if bid is not None and ask is not None: + print(f" Bid : {bid} Ask: {ask}") + + # Performance + perf = getattr(d, "performance", {}) or {} + if perf: + section("PERFORMANCE") + labels = [ + ("since1d", "1 Day"), + ("since1w", "1 Week"), + ("since1m", "1 Month"), + ("since3m", "3 Months"), + ("since6m", "6 Months"), + ("since1y", "1 Year"), + ("since3y", "3 Years"), + ("since5y", "5 Years"), + ("sinceIpo", "Since IPO"), + ] + for key, label in labels: + v = perf.get(key) + if v is not None: + pct = float(v) * 100 + sign = "+" if pct >= 0 else "" + print(f" {label:<14}: {sign}{pct:.2f}%") + + # Exchanges + exchanges = inst.get("exchanges") or [] + if exchanges: + section("EXCHANGES") + for ex in exchanges: + slug = ex.get("slug", "?") + sym = ex.get("symbolAtExchange", "") + exname = ex.get("nameAtExchange", "") + print(f" {slug:<8} {sym:<12} {exname}") + + # Tags + tags = inst.get("tags") or [] + if tags: + section("TAGS / CATEGORIES") + for tag in tags: + print(f" {tag.get('type', '?'):<20}: {tag.get('name', '?')}") + + # Stock / company details + sd = getattr(d, "stockDetails", {}) or {} + company = sd.get("company") or {} + non_empty_company = {k: v for k, v in company.items() if v is not None and v != ""} + if non_empty_company: + section("COMPANY") + for k, v in non_empty_company.items(): + vs = str(v) + if len(vs) > 80: + vs = vs[:80] + "…" + print(f" {k:<22}: {vs}") + + # Other stock detail scalars + scalar_sd = { + k: v + for k, v in sd.items() + if k != "company" and v not in (None, [], "", {}) and not isinstance(v, (dict, list)) + } + if scalar_sd: + section("STOCK DETAILS") + for k, v in scalar_sd.items(): + vs = str(v) + if len(vs) > 80: + vs = vs[:80] + "…" + print(f" {k:<22}: {vs}") + + # Suitability summary + suit = getattr(d, "instrumentSuitability", {}) or {} + if suit: + section("SUITABILITY") + for k, v in suit.items(): + if v not in (None, [], "", {}): + print(f" {k:<22}: {v}") + + # News + news_items = getattr(d, "neonNews", []) or [] + since = datetime.now() - timedelta(days=30) + recent = [ + (datetime.fromtimestamp(n["createdAt"] / 1000.0), n.get("headline", "")) + for n in news_items + if datetime.fromtimestamp(n["createdAt"] / 1000.0) > since + ] + if recent: + section("RECENT NEWS (last 30 days)") + for dt, headline in sorted(recent, reverse=True)[:15]: + print(f" {dt.strftime('%Y-%m-%d %H:%M')} {headline}") + + print() + + +# --------------------------------------------------------------------------- +# PDF generation +# --------------------------------------------------------------------------- + + +def _generate_pdf(d: _GUIDetails) -> Path: + """Build a formatted PDF from a Details object, save to a temp file, return path.""" + import io as _io + + from reportlab.lib import colors + from reportlab.lib.colors import HexColor + from reportlab.lib.pagesizes import A4 + from reportlab.lib.styles import ParagraphStyle, getSampleStyleSheet + from reportlab.lib.units import cm + from reportlab.platypus import ( + HRFlowable, + Paragraph, + SimpleDocTemplate, + Spacer, + Table, + TableStyle, + ) + + BLUE = HexColor("#1a6e9a") + STRIPE = HexColor("#f0f5fa") + + inst = getattr(d, "instrument", {}) or {} + name = inst.get("name") or inst.get("shortName") or d.isin + short = inst.get("shortName", "") + typ = inst.get("typeId", "") + + buf = _io.BytesIO() + doc = SimpleDocTemplate( + buf, + pagesize=A4, + leftMargin=2 * cm, + rightMargin=2 * cm, + topMargin=2 * cm, + bottomMargin=2 * cm, + title=f"Details: {name}", + author="pytr", + ) + + styles = getSampleStyleSheet() + H1 = ParagraphStyle("H1", parent=styles["Title"], fontSize=18, spaceAfter=2) + H2 = ParagraphStyle("H2", parent=styles["Heading2"], fontSize=11, textColor=BLUE, spaceBefore=12, spaceAfter=3) + GREY = ParagraphStyle("Grey", parent=styles["Normal"], fontSize=9, textColor=colors.grey, spaceAfter=8) + SMALL = ParagraphStyle("Small", parent=styles["Normal"], fontSize=9, spaceAfter=1) + + def tbl(data, col_widths, header=True): + t = Table(data, colWidths=col_widths, repeatRows=(1 if header else 0)) + cmds = [ + ("FONTSIZE", (0, 0), (-1, -1), 9), + ("VALIGN", (0, 0), (-1, -1), "TOP"), + ("TOPPADDING", (0, 0), (-1, -1), 3), + ("BOTTOMPADDING", (0, 0), (-1, -1), 3), + ("ROWBACKGROUNDS", (0, 1 if header else 0), (-1, -1), [colors.white, STRIPE]), + ("GRID", (0, 0), (-1, -1), 0.4, HexColor("#d0d8e0")), + ] + if header: + cmds += [ + ("BACKGROUND", (0, 0), (-1, 0), BLUE), + ("TEXTCOLOR", (0, 0), (-1, 0), colors.white), + ("FONTNAME", (0, 0), (-1, 0), "Helvetica-Bold"), + ] + else: + cmds.append(("FONTNAME", (0, 0), (0, -1), "Helvetica-Bold")) + t.setStyle(TableStyle(cmds)) + return t + + story: list[Any] = [] + + # ── Header ─────────────────────────────────────────────────────────── + story.append(Paragraph(name, H1)) + if short and short != name: + story.append(Paragraph(f"({short})", GREY)) + story.append( + Paragraph( + f"ISIN: {d.isin}    Type: {typ}    " + f"Generated: {datetime.now().strftime('%Y-%m-%d %H:%M')}", + GREY, + ) + ) + story.append(HRFlowable(width="100%", thickness=1.5, color=BLUE, spaceAfter=6)) + + # ── Price ───────────────────────────────────────────────────────────── + ticker = getattr(d, "ticker", {}) or {} + if ticker: + last = (ticker.get("last") or {}).get("price") + bid = (ticker.get("bid") or {}).get("price") + ask = (ticker.get("ask") or {}).get("price") + if last is not None: + rows = [["Current Price", str(last)]] + if bid is not None and ask is not None: + rows.append(["Bid / Ask", f"{bid} / {ask}"]) + story.append(tbl(rows, [5 * cm, None], header=False)) + story.append(Spacer(1, 6)) + + # ── Performance ─────────────────────────────────────────────────────── + perf = getattr(d, "performance", {}) or {} + if perf: + story.append(Paragraph("Performance", H2)) + labels = [ + ("since1d", "1 Day"), + ("since1w", "1 Week"), + ("since1m", "1 Month"), + ("since3m", "3 Months"), + ("since6m", "6 Months"), + ("since1y", "1 Year"), + ("since3y", "3 Years"), + ("since5y", "5 Years"), + ("sinceIpo", "Since IPO"), + ] + rows = [["Period", "Return"]] + for key, label in labels: + v = perf.get(key) + if v is not None: + pct = float(v) * 100 + rows.append([label, f"{'+' if pct >= 0 else ''}{pct:.2f}%"]) + if len(rows) > 1: + story.append(tbl(rows, [5 * cm, 4 * cm])) + + # ── Exchanges ───────────────────────────────────────────────────────── + exchanges = inst.get("exchanges") or [] + if exchanges: + story.append(Paragraph("Exchanges", H2)) + rows = [["Exchange", "Symbol", "Name"]] + for ex in exchanges[:12]: + rows.append([ex.get("slug", ""), ex.get("symbolAtExchange", ""), ex.get("nameAtExchange", "")]) + story.append(tbl(rows, [3 * cm, 4 * cm, None])) + + # ── Tags ───────────────────────────────────────────────────────────── + tags = inst.get("tags") or [] + if tags: + story.append(Paragraph("Categories & Tags", H2)) + rows = [[tag.get("type", ""), tag.get("name", "")] for tag in tags] + story.append(tbl(rows, [5 * cm, None], header=False)) + + # ── Company ─────────────────────────────────────────────────────────── + sd = getattr(d, "stockDetails", {}) or {} + company = {k: v for k, v in (sd.get("company") or {}).items() if v not in (None, "", [], {})} + if company: + story.append(Paragraph("Company", H2)) + rows1: list[list[Any]] = [] + for k, v in company.items(): + vs = str(v) + rows1.append([k, Paragraph(vs[:300] + ("…" if len(vs) > 300 else ""), SMALL)]) + story.append(tbl(rows1, [5 * cm, None], header=False)) + + # ── Stock Details ───────────────────────────────────────────────────── + scalar_sd = { + k: v + for k, v in sd.items() + if k != "company" and v not in (None, [], "", {}) and not isinstance(v, (dict, list)) + } + if scalar_sd: + story.append(Paragraph("Stock Details", H2)) + rows2: list[list[Any]] = [] + for k, v in scalar_sd.items(): + vs = str(v) + rows2.append([k, Paragraph(vs[:300] + ("…" if len(vs) > 300 else ""), SMALL)]) + story.append(tbl(rows2, [5 * cm, None], header=False)) + + # ── Suitability ─────────────────────────────────────────────────────── + suit = {k: v for k, v in (getattr(d, "instrumentSuitability", {}) or {}).items() if v not in (None, [], "", {})} + if suit: + story.append(Paragraph("Suitability", H2)) + rows = [[k, str(v)] for k, v in suit.items()] + story.append(tbl(rows, [6 * cm, None], header=False)) + + # ── News ────────────────────────────────────────────────────────────── + news_items = getattr(d, "neonNews", []) or [] + since = datetime.now() - timedelta(days=30) + recent = sorted( + [ + (datetime.fromtimestamp(n["createdAt"] / 1000.0), n.get("headline", "")) + for n in news_items + if datetime.fromtimestamp(n["createdAt"] / 1000.0) > since + ], + reverse=True, + )[:20] + if recent: + story.append(Paragraph("Recent News (last 30 days)", H2)) + rows3: list[list[Any]] = [["Date", "Headline"]] + for dt, headline in recent: + rows3.append([dt.strftime("%Y-%m-%d %H:%M"), Paragraph(headline, SMALL)]) + story.append(tbl(rows3, [3.8 * cm, None])) + + doc.build(story) + + safe = re.sub(r"[^\w\-]", "_", name)[:40] + tmp = Path(tempfile.gettempdir()) / f"pytr_{safe}_{d.isin}.pdf" + tmp.write_bytes(buf.getvalue()) + return tmp + + +# --------------------------------------------------------------------------- +# Instrument search +# --------------------------------------------------------------------------- + + +async def _search_async( + tr: TradeRepublicApi, + query: str, + asset_type: str, + stop_event: threading.Event | None = None, # type: ignore[name-defined] +) -> list: + tr.subscriptions.clear() + tr._previous_responses.clear() + + sub_id = await tr.search(query, asset_type=asset_type, page=1, page_size=20) + deadline = asyncio.get_event_loop().time() + 15.0 + try: + while True: + if stop_event and stop_event.is_set(): + raise RuntimeError(_STOPPED) + remaining = deadline - asyncio.get_event_loop().time() + if remaining <= 0: + raise asyncio.TimeoutError() + try: + recv_id, _, response = await asyncio.wait_for(tr.recv(), timeout=min(2.0, remaining)) + except asyncio.TimeoutError: + if asyncio.get_event_loop().time() >= deadline: + raise RuntimeError( + "Search timed out (15 s). No response from server.\n" + "Tip: for Bitcoin / crypto, select 'crypto' as asset type." + ) + continue # retry — re-checks stop_event at top of loop + if recv_id != sub_id: + continue + await tr.unsubscribe(recv_id) + await tr.close() + if isinstance(response, list): + return response + for key in ("results", "instruments", "items"): + if key in response: + return response[key] + return [] + except Exception: + try: + await tr.close() + except Exception: + pass + raise + + +class _SearchDialog(tk.Toplevel): + """Shows search results and lets the user pick an instrument.""" + + def __init__(self, parent: tk.Tk, results: list) -> None: + super().__init__(parent) + self.title("Select Instrument") + self.resizable(True, True) + self.minsize(500, 300) + self.grab_set() + self.transient(parent) + self.result: dict | None = None + self._items = results + self._build() + self._center(parent) + self.protocol("WM_DELETE_WINDOW", self.destroy) + self._lb.focus_set() + self.wait_window() + + def _build(self) -> None: + f = ttk.Frame(self, padding=12) + f.pack(fill=tk.BOTH, expand=True) + f.columnconfigure(0, weight=1) + f.rowconfigure(1, weight=1) + + ttk.Label(f, text="Select an instrument:", font=("Segoe UI", 10)).grid( + row=0, column=0, sticky=tk.W, pady=(0, 6) + ) + + lf = ttk.Frame(f) + lf.grid(row=1, column=0, sticky="nsew", pady=(0, 10)) + lf.columnconfigure(0, weight=1) + lf.rowconfigure(0, weight=1) + + self._lb = tk.Listbox(lf, font=("Consolas", 9), width=70, height=14, selectmode=tk.SINGLE, activestyle="dotbox") + self._lb.grid(row=0, column=0, sticky="nsew") + sb = ttk.Scrollbar(lf, command=self._lb.yview) + sb.grid(row=0, column=1, sticky="ns") + self._lb.config(yscrollcommand=sb.set) + + for item in self._items: + isin = item.get("isin") or item.get("instrumentId", "?") + name = item.get("shortName") or item.get("name", "?") + typ = item.get("typeId", "") + self._lb.insert(tk.END, f" {isin} {name:<40} {typ}") + + self._lb.bind("", lambda _: self._select()) + self._lb.bind("", lambda _: self._select()) + + bf = ttk.Frame(f) + bf.grid(row=2, column=0, sticky=tk.W) + ttk.Button(bf, text="Select", command=self._select, width=10).pack(side=tk.LEFT, padx=(0, 6)) + ttk.Button(bf, text="Cancel", command=self.destroy, width=10).pack(side=tk.LEFT) + + def _center(self, parent: tk.Tk) -> None: + self.update_idletasks() + x = parent.winfo_x() + (parent.winfo_width() - self.winfo_width()) // 2 + y = parent.winfo_y() + (parent.winfo_height() - self.winfo_height()) // 2 + self.geometry(f"+{x}+{y}") + + def _select(self) -> None: + sel = self._lb.curselection() + if not sel: + return + self.result = self._items[sel[0]] + self.destroy() + + +class _QueueWriter(io.TextIOBase): + def __init__(self, q: "queue.Queue[str]") -> None: + self._q = q + + def write(self, s: str) -> int: + if s: + self._q.put(_ANSI.sub("", s)) + return len(s) + + def flush(self) -> None: + pass + + +# --------------------------------------------------------------------------- +# Auth dialogs +# --------------------------------------------------------------------------- + + +class _OTPDialog(tk.Toplevel): + def __init__(self, parent: tk.Tk, countdown: int) -> None: + super().__init__(parent) + self.title("Verification Code") + self.resizable(False, False) + self.grab_set() + self.transient(parent) + self.result: str | None = None + self.use_sms = False + self._countdown = countdown + self._active = True + self._build() + self._center(parent) + threading.Thread(target=self._tick, daemon=True).start() + self.protocol("WM_DELETE_WINDOW", self._cancel) + self.code_entry.focus_set() + self.wait_window() + + def _build(self) -> None: + f = ttk.Frame(self, padding=24) + f.pack(fill=tk.BOTH, expand=True) + ttk.Label( + f, + text="Enter the code from the\nTrade Republic app notification:", + justify=tk.CENTER, + font=("Segoe UI", 10), + ).pack(pady=(0, 8)) + self._timer_var = tk.StringVar() + ttk.Label(f, textvariable=self._timer_var, foreground="#888").pack(pady=(0, 10)) + self.code_entry = ttk.Entry(f, width=14, font=("Segoe UI", 16), justify=tk.CENTER) + self.code_entry.pack(pady=(0, 16)) + self.code_entry.bind("", lambda _: self._submit()) + btn = ttk.Frame(f) + btn.pack(fill=tk.X) + ttk.Button(btn, text="Submit", command=self._submit).pack(side=tk.LEFT, expand=True, padx=4) + ttk.Button(btn, text="Send SMS instead", command=self._sms).pack(side=tk.LEFT, expand=True, padx=4) + ttk.Button(btn, text="Cancel", command=self._cancel).pack(side=tk.LEFT, expand=True, padx=4) + + def _center(self, parent: tk.Tk) -> None: + self.update_idletasks() + x = parent.winfo_x() + (parent.winfo_width() - self.winfo_width()) // 2 + y = parent.winfo_y() + (parent.winfo_height() - self.winfo_height()) // 2 + self.geometry(f"+{x}+{y}") + + def _tick(self) -> None: + r = self._countdown + while r > 0 and self._active: + self._timer_var.set(f"Expires in {r}s") + time.sleep(1) + r -= 1 + if self._active: + self._timer_var.set("Code expired") + + def _submit(self) -> None: + code = self.code_entry.get().strip() + if not code: + messagebox.showwarning("Required", "Please enter the code.", parent=self) + return + self._active = False + self.result = code + self.destroy() + + def _sms(self) -> None: + self._active = False + self.use_sms = True + self.destroy() + + def _cancel(self) -> None: + self._active = False + self.destroy() + + +class _SMSDialog(tk.Toplevel): + def __init__(self, parent: tk.Tk) -> None: + super().__init__(parent) + self.title("SMS Code") + self.resizable(False, False) + self.grab_set() + self.transient(parent) + self.result: str | None = None + self._build() + self._center(parent) + self.protocol("WM_DELETE_WINDOW", self._cancel) + self.code_entry.focus_set() + self.wait_window() + + def _build(self) -> None: + f = ttk.Frame(self, padding=24) + f.pack(fill=tk.BOTH, expand=True) + ttk.Label( + f, + text="An SMS was sent to your number.\nEnter the code from the SMS:", + justify=tk.CENTER, + font=("Segoe UI", 10), + ).pack(pady=(0, 12)) + self.code_entry = ttk.Entry(f, width=14, font=("Segoe UI", 16), justify=tk.CENTER) + self.code_entry.pack(pady=(0, 16)) + self.code_entry.bind("", lambda _: self._submit()) + btn = ttk.Frame(f) + btn.pack(fill=tk.X) + ttk.Button(btn, text="Submit", command=self._submit).pack(side=tk.LEFT, expand=True, padx=4) + ttk.Button(btn, text="Cancel", command=self._cancel).pack(side=tk.LEFT, expand=True, padx=4) + + def _center(self, parent: tk.Tk) -> None: + self.update_idletasks() + x = parent.winfo_x() + (parent.winfo_width() - self.winfo_width()) // 2 + y = parent.winfo_y() + (parent.winfo_height() - self.winfo_height()) // 2 + self.geometry(f"+{x}+{y}") + + def _submit(self) -> None: + code = self.code_entry.get().strip() + if not code: + messagebox.showwarning("Required", "Please enter the code.", parent=self) + return + self.result = code + self.destroy() + + def _cancel(self) -> None: + self.destroy() + + +# --------------------------------------------------------------------------- +# Scrollable frame helper +# --------------------------------------------------------------------------- + + +class _ScrollFrame(ttk.Frame): + """A frame with a vertical scrollbar.""" + + def __init__(self, parent: ttk.Notebook, **kw) -> None: + super().__init__(parent, **kw) + self.columnconfigure(0, weight=1) + self.rowconfigure(0, weight=1) + self._canvas = tk.Canvas(self, highlightthickness=0) + self._canvas.grid(row=0, column=0, sticky="nsew") + sb = ttk.Scrollbar(self, orient="vertical", command=self._canvas.yview) + sb.grid(row=0, column=1, sticky="ns") + self._canvas.configure(yscrollcommand=sb.set) + self.inner = ttk.Frame(self._canvas, padding=14) + self._win = self._canvas.create_window((0, 0), window=self.inner, anchor="nw") + self.inner.bind("", self._on_inner) + self._canvas.bind("", self._on_canvas) + self._canvas.bind_all("", self._on_wheel) + + def _on_inner(self, _e) -> None: + self._canvas.configure(scrollregion=self._canvas.bbox("all")) + + def _on_canvas(self, e) -> None: + self._canvas.itemconfig(self._win, width=e.width) + + def _on_wheel(self, e) -> None: + self._canvas.yview_scroll(-1 * (e.delta // 120), "units") + + +# --------------------------------------------------------------------------- +# Main window +# --------------------------------------------------------------------------- + + +class PytrGUI(tk.Tk): + def __init__(self) -> None: + super().__init__() + self.title("pytr – Trade Republic") + self.minsize(720, 680) + + self._tr: TradeRepublicApi | None = None + self._pending_tr: TradeRepublicApi | None = None + self._pending_countdown: int = 0 + self._pending_store: bool = False + self._pending_phone: str = "" + self._pending_pin: str = "" + self._pending_callback = None + + self._stop_event = threading.Event() + + self._out_q: queue.Queue[str] = queue.Queue() + self._redirect_output() + self._build() + self._load_credentials() + self._center() + self._poll_output() + + # ------------------------------------------------------------------ + # Output + # ------------------------------------------------------------------ + + def _redirect_output(self) -> None: + import sys + + writer = _QueueWriter(self._out_q) + sys.stdout = writer # type: ignore[assignment] + sys.stderr = writer # type: ignore[assignment] + + def _poll_output(self) -> None: + try: + while True: + text = self._out_q.get_nowait() + self._log.configure(state=tk.NORMAL) + self._log.insert(tk.END, text) + self._log.see(tk.END) + self._log.configure(state=tk.DISABLED) + except queue.Empty: + pass + self.after(100, self._poll_output) + + # ------------------------------------------------------------------ + # Layout + # ------------------------------------------------------------------ + + def _build(self) -> None: + self.columnconfigure(0, weight=1) + self.rowconfigure(1, weight=1) + self._build_creds() + nb = ttk.Notebook(self) + nb.grid(row=1, column=0, sticky="nsew", padx=8, pady=(0, 4)) + self._notebook = nb + self._build_tabs() + self._build_log() + + def _build_creds(self) -> None: + f = ttk.LabelFrame(self, text="Credentials", padding=8) + f.grid(row=0, column=0, sticky="ew", padx=8, pady=8) + for c in range(10): + f.columnconfigure(c, weight=(1 if c in (1, 3) else 0)) + + ttk.Label(f, text="Phone:").grid(row=0, column=0, sticky=tk.W, padx=(0, 4)) + self._phone_var = tk.StringVar() + ttk.Entry(f, textvariable=self._phone_var, width=18).grid(row=0, column=1, sticky=tk.EW, padx=(0, 10)) + + ttk.Label(f, text="PIN:").grid(row=0, column=2, sticky=tk.W, padx=(0, 4)) + self._pin_var = tk.StringVar() + self._pin_entry = ttk.Entry(f, textvariable=self._pin_var, show="•", width=10) + self._pin_entry.grid(row=0, column=3, sticky=tk.EW, padx=(0, 6)) + self._pin_entry.bind("", lambda _: self._start_login()) + + self._show_pin = tk.BooleanVar() + ttk.Checkbutton(f, text="Show", variable=self._show_pin, command=self._toggle_pin).grid( + row=0, column=4, padx=(0, 8) + ) + + self._store_var = tk.BooleanVar() + ttk.Checkbutton(f, text="Remember", variable=self._store_var).grid(row=0, column=5, padx=(0, 10)) + + self._login_btn = ttk.Button(f, text="Login", command=self._start_login, width=9) + self._login_btn.grid(row=0, column=6, padx=(0, 4)) + + self._stop_btn = ttk.Button(f, text="Stop", command=self._stop_operation, width=7) + self._stop_btn.grid(row=0, column=7, padx=(0, 10)) + + self._status_var = tk.StringVar(value="Not logged in") + self._status_lbl = ttk.Label(f, textvariable=self._status_var, foreground="#888", width=18) + self._status_lbl.grid(row=0, column=8, sticky=tk.W, padx=(0, 8)) + + self._progress = ttk.Progressbar(f, mode="indeterminate", length=90) + self._progress.grid(row=0, column=9) + + def _build_log(self) -> None: + f = ttk.LabelFrame(self, text="Output", padding=6) + f.grid(row=2, column=0, sticky="ew", padx=8, pady=(0, 8)) + f.columnconfigure(0, weight=1) + self._log = scrolledtext.ScrolledText(f, state=tk.DISABLED, height=10, font=("Consolas", 9), wrap=tk.WORD) + self._log.grid(row=0, column=0, sticky="ew") + footer = ttk.Frame(f) + footer.grid(row=1, column=0, sticky=tk.E, pady=(4, 0)) + ttk.Label(footer, text=f"v{version('pytr')}", foreground="#888").pack(side=tk.LEFT, padx=(0, 8)) + ttk.Button(footer, text="Clear", command=self._clear_log, width=7).pack(side=tk.LEFT) + + def _clear_log(self) -> None: + self._log.configure(state=tk.NORMAL) + self._log.delete("1.0", tk.END) + self._log.configure(state=tk.DISABLED) + + # ------------------------------------------------------------------ + # Tabs + # ------------------------------------------------------------------ + + def _build_tabs(self) -> None: + nb = self._notebook + nb.add(self._tab_portfolio(), text="Portfolio") + nb.add(self._tab_details(), text="Details") + nb.add(self._tab_dl_docs(), text="Download Docs") + nb.add(self._tab_export_tx(), text="Export Transactions") + nb.add(self._tab_alarms(), text="Price Alarms") + nb.add(self._tab_savings(), text="Savings Plans") + + # --- Portfolio --- + + def _tab_portfolio(self) -> ttk.Frame: + sf = _ScrollFrame(self._notebook) + f = sf.inner + f.columnconfigure(1, weight=1) + r = 0 + + ttk.Label(f, text="Output CSV (optional):").grid(row=r, column=0, sticky=tk.W, pady=4) + self._pf_out = tk.StringVar() + ttk.Entry(f, textvariable=self._pf_out).grid(row=r, column=1, sticky=tk.EW, padx=6) + ttk.Button(f, text="…", width=3, command=lambda: self._save_file(self._pf_out, ".csv")).grid(row=r, column=2) + r += 1 + + ttk.Label(f, text="Sort by column:").grid(row=r, column=0, sticky=tk.W, pady=4) + self._pf_sort_col = tk.StringVar(value="(none)") + ttk.Combobox( + f, + textvariable=self._pf_sort_col, + width=18, + values=["(none)"] + [c.lower() for c in PORTFOLIO_COLUMNS], + state="readonly", + ).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + + self._pf_sort_asc = tk.BooleanVar() + ttk.Checkbutton(f, text="Sort ascending", variable=self._pf_sort_asc).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + self._pf_watchlist = tk.BooleanVar() + ttk.Checkbutton(f, text="Include watchlist", variable=self._pf_watchlist).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Label(f, text="Language:").grid(row=r, column=0, sticky=tk.W, pady=4) + self._pf_lang = tk.StringVar(value="auto") + ttk.Combobox( + f, textvariable=self._pf_lang, width=10, values=["auto", *sorted(SUPPORTED_LANGUAGES)], state="readonly" + ).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + + self._pf_decimal = tk.BooleanVar() + ttk.Checkbutton(f, text="Localize decimals", variable=self._pf_decimal).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Button(f, text="▶ Run Portfolio", command=self._run_portfolio).grid( + row=r, column=1, sticky=tk.W, padx=6, pady=(14, 0) + ) + return sf + + # --- Details --- + + def _tab_details(self) -> ttk.Frame: + f = ttk.Frame(self._notebook, padding=14) + f.columnconfigure(1, weight=1) + + ttk.Label(f, text="ISIN or name:").grid(row=0, column=0, sticky=tk.W, pady=4) + self._det_query = tk.StringVar() + e = ttk.Entry(f, textvariable=self._det_query, width=32) + e.grid(row=0, column=1, sticky=tk.EW, padx=6) + e.bind("", lambda _: self._run_details()) + + ttk.Label(f, text="Asset type:").grid(row=1, column=0, sticky=tk.W, pady=4) + self._det_asset_type = tk.StringVar(value="stock") + ttk.Combobox(f, textvariable=self._det_asset_type, values=_ASSET_TYPES, state="readonly", width=14).grid( + row=1, column=1, sticky=tk.W, padx=6 + ) + + ttk.Label( + f, text="(Enter a 12-char ISIN to look up directly,\nor a name to search and select)", foreground="#888" + ).grid(row=2, column=1, sticky=tk.W, padx=6, pady=(2, 0)) + + ttk.Button(f, text="▶ Run Details", command=self._run_details).grid( + row=3, column=1, sticky=tk.W, padx=6, pady=(14, 0) + ) + return f + + # --- Download Docs --- + + def _tab_dl_docs(self) -> _ScrollFrame: + sf = _ScrollFrame(self._notebook) + f = sf.inner + f.columnconfigure(1, weight=1) + r = 0 + + def row_entry(label, var, default=""): + nonlocal r + ttk.Label(f, text=label).grid(row=r, column=0, sticky=tk.W, pady=3) + var.set(default) + ttk.Entry(f, textvariable=var).grid(row=r, column=1, sticky=tk.EW, padx=6) + r += 1 + + def row_spin(label, var, default, from_, to): + nonlocal r + ttk.Label(f, text=label).grid(row=r, column=0, sticky=tk.W, pady=3) + var.set(str(default)) + ttk.Spinbox(f, textvariable=var, from_=from_, to=to, width=8).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + + def row_check(label, var, default=False): + nonlocal r + var.set(default) + ttk.Checkbutton(f, text=label, variable=var).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + + ttk.Label(f, text="Output directory:").grid(row=r, column=0, sticky=tk.W, pady=3) + self._dl_out = tk.StringVar() + ttk.Entry(f, textvariable=self._dl_out).grid(row=r, column=1, sticky=tk.EW, padx=6) + ttk.Button(f, text="…", width=3, command=lambda: self._open_dir(self._dl_out)).grid(row=r, column=2) + r += 1 + + self._dl_format = tk.StringVar() + row_entry("Filename format:", self._dl_format, "{iso_date} {time} {title}") + self._dl_last_days = tk.StringVar() + row_spin("Last N days (0=all, -1=skip):", self._dl_last_days, 0, -1, 9999) + self._dl_days_until = tk.StringVar() + row_spin("Days until (0=all):", self._dl_days_until, 0, 0, 9999) + self._dl_workers = tk.StringVar() + row_spin("Workers:", self._dl_workers, 8, 1, 32) + + ttk.Label(f, text="Export format:").grid(row=r, column=0, sticky=tk.W, pady=3) + self._dl_export_fmt = tk.StringVar(value="csv") + ttk.Combobox(f, textvariable=self._dl_export_fmt, values=["csv", "json"], state="readonly", width=8).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Label(f, text="Language:").grid(row=r, column=0, sticky=tk.W, pady=3) + self._dl_lang = tk.StringVar(value="auto") + ttk.Combobox( + f, textvariable=self._dl_lang, values=["auto", *sorted(SUPPORTED_LANGUAGES)], state="readonly", width=10 + ).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + + self._dl_export_tx = tk.BooleanVar() + row_check("Export transactions", self._dl_export_tx, True) + self._dl_store_db = tk.BooleanVar() + row_check("Store event database", self._dl_store_db, True) + self._dl_scan_dup = tk.BooleanVar() + row_check("Scan for duplicates", self._dl_scan_dup) + self._dl_dump_raw = tk.BooleanVar() + row_check("Dump raw data", self._dl_dump_raw) + self._dl_universal = tk.BooleanVar() + row_check("Universal file names", self._dl_universal) + self._dl_flat = tk.BooleanVar() + row_check("Flat (no subfolders)", self._dl_flat) + self._dl_date_time = tk.BooleanVar() + row_check("Date with time", self._dl_date_time, True) + self._dl_decimal = tk.BooleanVar() + row_check("Localize decimals", self._dl_decimal) + self._dl_sort = tk.BooleanVar() + row_check("Sort chronologically", self._dl_sort) + + ttk.Button(f, text="▶ Run Download Docs", command=self._run_dl_docs).grid( + row=r, column=1, sticky=tk.W, padx=6, pady=(14, 0) + ) + return sf + + # --- Export Transactions --- + + def _tab_export_tx(self) -> _ScrollFrame: + sf = _ScrollFrame(self._notebook) + f = sf.inner + f.columnconfigure(1, weight=1) + r = 0 + + ttk.Label(f, text="Output directory:").grid(row=r, column=0, sticky=tk.W, pady=3) + self._ex_dir = tk.StringVar(value=".") + ttk.Entry(f, textvariable=self._ex_dir).grid(row=r, column=1, sticky=tk.EW, padx=6) + ttk.Button(f, text="…", width=3, command=lambda: self._open_dir(self._ex_dir)).grid(row=r, column=2) + r += 1 + + ttk.Label(f, text="Output file (optional):").grid(row=r, column=0, sticky=tk.W, pady=3) + self._ex_file = tk.StringVar() + ttk.Entry(f, textvariable=self._ex_file).grid(row=r, column=1, sticky=tk.EW, padx=6) + ttk.Button(f, text="…", width=3, command=lambda: self._save_file(self._ex_file, ".csv")).grid(row=r, column=2) + r += 1 + + ttk.Label(f, text="Last N days (0=all):").grid(row=r, column=0, sticky=tk.W, pady=3) + self._ex_last_days = tk.StringVar(value="0") + ttk.Spinbox(f, textvariable=self._ex_last_days, from_=-1, to=9999, width=8).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Label(f, text="Days until (0=all):").grid(row=r, column=0, sticky=tk.W, pady=3) + self._ex_days_until = tk.StringVar(value="0") + ttk.Spinbox(f, textvariable=self._ex_days_until, from_=0, to=9999, width=8).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Label(f, text="Export format:").grid(row=r, column=0, sticky=tk.W, pady=3) + self._ex_fmt = tk.StringVar(value="csv") + ttk.Combobox(f, textvariable=self._ex_fmt, values=["csv", "json"], state="readonly", width=8).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Label(f, text="Language:").grid(row=r, column=0, sticky=tk.W, pady=3) + self._ex_lang = tk.StringVar(value="auto") + ttk.Combobox( + f, textvariable=self._ex_lang, values=["auto", *sorted(SUPPORTED_LANGUAGES)], state="readonly", width=10 + ).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + + self._ex_store_db = tk.BooleanVar(value=True) + ttk.Checkbutton(f, text="Store event database", variable=self._ex_store_db).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + self._ex_scan_dup = tk.BooleanVar() + ttk.Checkbutton(f, text="Scan for duplicates", variable=self._ex_scan_dup).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + self._ex_dump_raw = tk.BooleanVar() + ttk.Checkbutton(f, text="Dump raw data", variable=self._ex_dump_raw).grid(row=r, column=1, sticky=tk.W, padx=6) + r += 1 + self._ex_date_time = tk.BooleanVar(value=True) + ttk.Checkbutton(f, text="Date with time", variable=self._ex_date_time).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + self._ex_decimal = tk.BooleanVar() + ttk.Checkbutton(f, text="Localize decimals", variable=self._ex_decimal).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + self._ex_sort = tk.BooleanVar() + ttk.Checkbutton(f, text="Sort chronologically", variable=self._ex_sort).grid( + row=r, column=1, sticky=tk.W, padx=6 + ) + r += 1 + + ttk.Button(f, text="▶ Run Export Transactions", command=self._run_export_tx).grid( + row=r, column=1, sticky=tk.W, padx=6, pady=(14, 0) + ) + return sf + + # --- Price Alarms --- + + def _tab_alarms(self) -> ttk.Frame: + f = ttk.Frame(self._notebook, padding=14) + f.columnconfigure(1, weight=1) + + get = ttk.LabelFrame(f, text="Get Price Alarms", padding=10) + get.grid(row=0, column=0, columnspan=3, sticky=tk.EW, pady=(0, 12)) + get.columnconfigure(1, weight=1) + + ttk.Label(get, text="ISINs (space-sep, empty=all):").grid(row=0, column=0, sticky=tk.W, pady=3) + self._ga_isins = tk.StringVar() + ttk.Entry(get, textvariable=self._ga_isins).grid(row=0, column=1, sticky=tk.EW, padx=6) + + ttk.Label(get, text="Save to file (empty=log):").grid(row=1, column=0, sticky=tk.W, pady=3) + self._ga_out = tk.StringVar() + ttk.Entry(get, textvariable=self._ga_out).grid(row=1, column=1, sticky=tk.EW, padx=6) + ttk.Button(get, text="…", width=3, command=lambda: self._save_file(self._ga_out, ".json")).grid(row=1, column=2) + + ttk.Button(get, text="▶ Get Price Alarms", command=self._run_get_alarms).grid( + row=2, column=1, sticky=tk.W, padx=6, pady=(10, 0) + ) + + set_ = ttk.LabelFrame(f, text="Set Price Alarms", padding=10) + set_.grid(row=1, column=0, columnspan=3, sticky=tk.EW) + set_.columnconfigure(1, weight=1) + + ttk.Label(set_, text="Input (ISIN price1 price2…):").grid(row=0, column=0, sticky=tk.W, pady=3) + self._sa_input = tk.StringVar() + ttk.Entry(set_, textvariable=self._sa_input).grid(row=0, column=1, sticky=tk.EW, padx=6) + + ttk.Label(set_, text="Input file (optional):").grid(row=1, column=0, sticky=tk.W, pady=3) + self._sa_infile = tk.StringVar() + ttk.Entry(set_, textvariable=self._sa_infile).grid(row=1, column=1, sticky=tk.EW, padx=6) + ttk.Button(set_, text="…", width=3, command=lambda: self._open_file(self._sa_infile)).grid(row=1, column=2) + + self._sa_remove = tk.BooleanVar(value=True) + ttk.Checkbutton(set_, text="Remove current alarms first", variable=self._sa_remove).grid( + row=2, column=1, sticky=tk.W, padx=6 + ) + + ttk.Button(set_, text="▶ Set Price Alarms", command=self._run_set_alarms).grid( + row=3, column=1, sticky=tk.W, padx=6, pady=(10, 0) + ) + return f + + # --- Savings Plans --- + + def _tab_savings(self) -> ttk.Frame: + f = ttk.Frame(self._notebook, padding=14) + f.columnconfigure(1, weight=1) + + ttk.Label(f, text="Save to file (empty=log):").grid(row=0, column=0, sticky=tk.W, pady=4) + self._sp_out = tk.StringVar() + ttk.Entry(f, textvariable=self._sp_out).grid(row=0, column=1, sticky=tk.EW, padx=6) + ttk.Button(f, text="…", width=3, command=lambda: self._save_file(self._sp_out, ".json")).grid(row=0, column=2) + + ttk.Label(f, text="Language:").grid(row=1, column=0, sticky=tk.W, pady=4) + self._sp_lang = tk.StringVar(value="auto") + ttk.Combobox( + f, textvariable=self._sp_lang, values=["auto", *sorted(SUPPORTED_LANGUAGES)], state="readonly", width=10 + ).grid(row=1, column=1, sticky=tk.W, padx=6) + + self._sp_decimal = tk.BooleanVar() + ttk.Checkbutton(f, text="Localize decimals", variable=self._sp_decimal).grid( + row=2, column=1, sticky=tk.W, padx=6 + ) + + ttk.Button(f, text="▶ Run Savings Plans", command=self._run_savings).grid( + row=3, column=1, sticky=tk.W, padx=6, pady=(14, 0) + ) + return f + + # ------------------------------------------------------------------ + # File dialogs + # ------------------------------------------------------------------ + + def _open_dir(self, var: tk.StringVar) -> None: + p = filedialog.askdirectory() + if p: + var.set(p) + + def _save_file(self, var: tk.StringVar, ext: str) -> None: + p = filedialog.asksaveasfilename( + defaultextension=ext, + filetypes=[(ext.lstrip(".").upper() + " files", f"*{ext}"), ("All files", "*.*")], + ) + if p: + var.set(p) + + def _open_file(self, var: tk.StringVar) -> None: + p = filedialog.askopenfilename(filetypes=[("All files", "*.*")]) + if p: + var.set(p) + + # ------------------------------------------------------------------ + # Helpers + # ------------------------------------------------------------------ + + def _center(self) -> None: + self.update_idletasks() + sw, sh = self.winfo_screenwidth(), self.winfo_screenheight() + w, h = self.winfo_width(), self.winfo_height() + self.geometry(f"+{(sw - w) // 2}+{(sh - h) // 2}") + + def _toggle_pin(self) -> None: + self._pin_entry.config(show="" if self._show_pin.get() else "•") + + def _set_status(self, msg: str, color: str = "#666") -> None: + self._status_var.set(msg) + self._status_lbl.config(foreground=color) + + def _set_busy(self, busy: bool) -> None: + if busy: + self._login_btn.config(state=tk.DISABLED) + self._progress.start(10) + else: + self._progress.stop() + self._login_btn.config(state=tk.NORMAL) + + def _load_credentials(self) -> None: + if not CREDENTIALS_FILE.is_file(): + return + try: + lines = CREDENTIALS_FILE.read_text().splitlines() + if lines: + self._phone_var.set(lines[0].strip()) + if len(lines) > 1: + self._pin_var.set(lines[1].strip()) + self._store_var.set(True) + self._set_status("Credentials loaded") + except OSError: + pass + + def _date_range(self, last: str, until: str) -> tuple[float, float]: + ld = int(last) + du = int(until) + if ld < 0: + nb = float(-1) + elif ld == 0: + nb = float(0) + else: + nb = (datetime.now().astimezone() - timedelta(days=ld)).timestamp() + na = (datetime.now().astimezone() - timedelta(days=du)).timestamp() if du > 0 else float("inf") + return nb, na + + # ------------------------------------------------------------------ + # Login flow + # ------------------------------------------------------------------ + + def _start_login(self) -> None: + phone = self._phone_var.get().strip() + pin = self._pin_var.get().strip() + if not phone: + messagebox.showwarning("Missing", "Please enter your phone number.") + return + if not pin: + messagebox.showwarning("Missing", "Please enter your PIN.") + return + self._set_busy(True) + self._set_status("Connecting…") + threading.Thread(target=self._login_worker, args=(phone, pin, None), daemon=True).start() + + def _ensure_logged_in(self, callback) -> None: + if self._tr is not None: + callback(self._tr) + return + phone = self._phone_var.get().strip() + pin = self._pin_var.get().strip() + if not phone or not pin: + messagebox.showwarning("Not logged in", "Fill in phone number and PIN, then log in first.") + return + self._set_busy(True) + self._set_status("Logging in…") + threading.Thread(target=self._login_worker, args=(phone, pin, callback), daemon=True).start() + + def _login_worker(self, phone: str, pin: str, callback) -> None: + log = get_logger(__name__) + try: + BASE_DIR.mkdir(parents=True, exist_ok=True) + store = self._store_var.get() + tr = TradeRepublicApi(phone_no=phone, pin=pin, save_cookies=store, waf_token="playwright") + + if tr.resume_websession(): + self.after(0, self._on_login_success, tr, callback) + return + + countdown = tr.initiate_weblogin() + self._pending_tr = tr + self._pending_countdown = countdown + self._pending_store = store + self._pending_phone = phone + self._pending_pin = pin + self._pending_callback = callback + self.after(0, self._show_otp) + except Exception as exc: + log.debug("Login error", exc_info=True) + self.after(0, self._on_error, str(exc)) + + def _show_otp(self) -> None: + self._set_busy(False) + dlg = _OTPDialog(self, self._pending_countdown) + if dlg.use_sms: + self._set_busy(True) + self._set_status("Requesting SMS…") + threading.Thread(target=self._resend_worker, daemon=True).start() + elif dlg.result: + self._set_busy(True) + self._set_status("Verifying…") + threading.Thread(target=self._complete_worker, args=(dlg.result,), daemon=True).start() + else: + self._set_status("Cancelled.") + + def _resend_worker(self) -> None: + try: + assert self._pending_tr is not None + self._pending_tr.resend_weblogin() + self.after(0, self._show_sms) + except Exception as exc: + self.after(0, self._on_error, str(exc)) + + def _show_sms(self) -> None: + self._set_busy(False) + dlg = _SMSDialog(self) + if dlg.result: + self._set_busy(True) + self._set_status("Verifying SMS…") + threading.Thread(target=self._complete_worker, args=(dlg.result,), daemon=True).start() + else: + self._set_status("Cancelled.") + + def _complete_worker(self, code: str) -> None: + try: + assert self._pending_tr is not None + self._pending_tr.complete_weblogin(code) + if self._pending_store: + CREDENTIALS_FILE.write_text(f"{self._pending_phone}\n{self._pending_pin}\n") + self.after(0, self._on_login_success, self._pending_tr, self._pending_callback) + except Exception as exc: + self.after(0, self._on_error, str(exc)) + + def _on_login_success(self, tr: TradeRepublicApi, callback) -> None: + self._tr = tr + self._set_busy(False) + self._set_status("Logged in ✓", "#2a7a2a") + if callback is not None: + callback(tr) + + def _stop_operation(self) -> None: + self._stop_event.set() + self._set_status("Stopping…", "#888888") + + def _on_error(self, msg: str) -> None: + self._set_busy(False) + if msg == _STOPPED: + self._set_status("Stopped.", "#888888") + return + self._set_status("Error", "#cc0000") + messagebox.showerror("Error", msg) + + def _open_pdf(self, path: str) -> None: + os.startfile(path) # type: ignore[attr-defined] + + # ------------------------------------------------------------------ + # Command runners + # ------------------------------------------------------------------ + + def _run_portfolio(self) -> None: + self._ensure_logged_in(self._do_portfolio) + + def _do_portfolio(self, tr: TradeRepublicApi) -> None: + col = self._pf_sort_col.get() + out = Path(self._pf_out.get()) if self._pf_out.get() else None + self._set_busy(True) + self._set_status("Running…") + + def w(): + try: + Portfolio( + tr, + self._pf_watchlist.get(), + lang=self._pf_lang.get(), + decimal_localization=self._pf_decimal.get(), + output=out, + sort_by_column=None if col == "(none)" else col, + sort_descending=not self._pf_sort_asc.get(), + ).get() + self.after(0, self._set_status, "Done ✓", "#2a7a2a") + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _run_details(self) -> None: + query = self._det_query.get().strip() + if not query: + messagebox.showwarning("Required", "Please enter an ISIN or a name.") + return + if _ISIN_RE.match(query): + self._ensure_logged_in(lambda tr: self._do_details(tr, query.upper())) + else: + self._ensure_logged_in(lambda tr: self._do_search_then_details(tr, query)) + + def _do_search_then_details(self, tr: TradeRepublicApi, query: str) -> None: + self._stop_event.clear() + self._set_busy(True) + self._set_status("Searching…") + asset_type = self._det_asset_type.get() + stop = self._stop_event + + def w(): + try: + results = asyncio.run(_search_async(tr, query, asset_type, stop)) + if not results: + self.after(0, messagebox.showinfo, "No results", f"No instruments found for '{query}'.") + self.after(0, self._set_busy, False) + self.after(0, self._set_status, "No results.") + return + self.after(0, self._show_search_results, tr, results) + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _show_search_results(self, tr: TradeRepublicApi, results: list) -> None: + dlg = _SearchDialog(self, results) + if dlg.result is None: + self._set_status("Cancelled.") + return + isin = dlg.result.get("isin") or dlg.result.get("instrumentId", "") + name = dlg.result.get("shortName") or dlg.result.get("name", isin) + print(f"Selected: {name} ({isin})\n") + self._do_details(tr, isin) + + def _do_details(self, tr: TradeRepublicApi, isin: str) -> None: + self._stop_event.clear() + self._set_busy(True) + self._set_status("Fetching details…") + stop = self._stop_event + + def w(): + try: + d = _GUIDetails(tr, isin) + asyncio.run(d.details_loop(stop)) + if stop.is_set(): + self.after(0, self._on_error, _STOPPED) + return + _print_details(d) + pdf_path = _generate_pdf(d) + self.after(0, self._set_status, "Done ✓ – opening PDF…", "#2a7a2a") + self.after(0, self._open_pdf, str(pdf_path)) + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _run_dl_docs(self) -> None: + out = self._dl_out.get().strip() + if not out: + messagebox.showwarning("Required", "Please select an output directory.") + return + self._ensure_logged_in(lambda tr: self._do_dl_docs(tr, Path(out))) + + def _do_dl_docs(self, tr: TradeRepublicApi, out: Path) -> None: + self._set_busy(True) + self._set_status("Downloading…") + nb, na = self._date_range(self._dl_last_days.get(), self._dl_days_until.get()) + + def w(): + try: + DL( + tr, + out, + self._dl_format.get(), + nb, + na, + self._dl_store_db.get(), + self._dl_scan_dup.get(), + self._dl_dump_raw.get(), + self._dl_export_tx.get(), + max_workers=int(self._dl_workers.get()), + universal_filepath=self._dl_universal.get(), + lang=self._dl_lang.get(), + date_with_time=self._dl_date_time.get(), + decimal_localization=self._dl_decimal.get(), + sort_export=self._dl_sort.get(), + format_export=self._dl_export_fmt.get(), + flat=self._dl_flat.get(), + ).do_dl() + self.after(0, self._set_status, "Done ✓", "#2a7a2a") + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _run_export_tx(self) -> None: + outdir = Path(self._ex_dir.get() or ".") + self._ensure_logged_in(lambda tr: self._do_export_tx(tr, outdir)) + + def _do_export_tx(self, tr: TradeRepublicApi, outdir: Path) -> None: + self._set_busy(True) + self._set_status("Exporting…") + nb, na = self._date_range(self._ex_last_days.get(), self._ex_days_until.get()) + fmt = self._ex_fmt.get() + out_file_str = self._ex_file.get().strip() + + def w(): + try: + tl = Timeline( + tr, outdir, nb, na, self._ex_store_db.get(), self._ex_scan_dup.get(), self._ex_dump_raw.get() + ) + asyncio.run(tl.tl_loop()) + path = Path(out_file_str) if out_file_str else outdir / f"account_transactions.{fmt}" + with path.open("w", encoding="utf-8") as fh: + TransactionExporter( + lang=self._ex_lang.get(), + date_with_time=self._ex_date_time.get(), + decimal_localization=self._ex_decimal.get(), + ).export(fh, [Event.from_dict(i) for i in tl.events], sort=self._ex_sort.get(), format=fmt) + self.after(0, self._set_status, "Done ✓", "#2a7a2a") + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _run_get_alarms(self) -> None: + self._ensure_logged_in(self._do_get_alarms) + + def _do_get_alarms(self, tr: TradeRepublicApi) -> None: + self._set_busy(True) + self._set_status("Getting alarms…") + isins = self._ga_isins.get().split() + out_path = self._ga_out.get().strip() + + def w(): + import sys + + try: + fh = open(out_path, "w", encoding="utf-8") if out_path else sys.stdout + try: + Alarms(tr, isins, fh).get() + finally: + if out_path: + fh.close() + self.after(0, self._set_status, "Done ✓", "#2a7a2a") + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _run_set_alarms(self) -> None: + self._ensure_logged_in(self._do_set_alarms) + + def _do_set_alarms(self, tr: TradeRepublicApi) -> None: + self._set_busy(True) + self._set_status("Setting alarms…") + inp = self._sa_input.get().split() + in_path = self._sa_infile.get().strip() + + def w(): + import sys + + try: + fh = open(in_path, "r", encoding="utf-8") if in_path else sys.stdin + try: + Alarms(tr, inp, fh, self._sa_remove.get()).set() + finally: + if in_path: + fh.close() + self.after(0, self._set_status, "Done ✓", "#2a7a2a") + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + def _run_savings(self) -> None: + self._ensure_logged_in(self._do_savings) + + def _do_savings(self, tr: TradeRepublicApi) -> None: + self._set_busy(True) + self._set_status("Getting savings plans…") + out_path = self._sp_out.get().strip() + + def w(): + import sys + + try: + fh = open(out_path, "w", encoding="utf-8") if out_path else sys.stdout + try: + SavingsPlans(tr, fh, decimal_localization=self._sp_decimal.get(), lang=self._sp_lang.get()).get() + finally: + if out_path: + fh.close() + self.after(0, self._set_status, "Done ✓", "#2a7a2a") + except Exception as exc: + self.after(0, self._on_error, str(exc)) + finally: + self.after(0, self._set_busy, False) + + threading.Thread(target=w, daemon=True).start() + + +def main() -> None: + app = PytrGUI() + app.mainloop() + + +if __name__ == "__main__": + main() diff --git a/pytr/main.py b/pytr/main.py index d277ed46..d4252993 100644 --- a/pytr/main.py +++ b/pytr/main.py @@ -2,6 +2,7 @@ import argparse import asyncio +import re import shutil import signal import sys @@ -11,12 +12,13 @@ import shtab -from pytr.account import login +from pytr.account import login, print_accounts from pytr.alarms import Alarms from pytr.details import Details from pytr.dl import DL from pytr.event import Event from pytr.portfolio import PORTFOLIO_COLUMNS, Portfolio +from pytr.rates import RATE_COLUMNS, Rates, parse_isin_input from pytr.savings_plans import SavingsPlans from pytr.timeline import Timeline from pytr.transactions import SUPPORTED_LANGUAGES, TransactionExporter @@ -78,10 +80,34 @@ def formatter(prog): parser_login_args = argparse.ArgumentParser(add_help=False) parser_login_args.add_argument("-n", "--phone_no", help="TradeRepublic phone number (international format)") parser_login_args.add_argument("-p", "--pin", help="TradeRepublic pin") - parser_login_args.add_argument( + waf_group = parser_login_args.add_mutually_exclusive_group() + waf_group.add_argument( "--waf-token", - help='AWS WAF token value or the method to obtain it. Values: "playwright", "awswaf" or a token string, e.g. an aws-waf-token cookie captured from a browser session.', - default="playwright", + help=( + "AWS WAF token string or the method to obtain it. Possible values: " + "\"playwright\" (to use playwright to obtain a token, needs the optional extra: pip install 'pytr[playwright]' && playwright install chromium), " + '"awswaf" (to use a pure Python implementation to obtain a token, no browser), ' + '"default" (let pytr determine what to do, e.g. by login method used.), ' + "or a token string, e.g. captured from a browser session." + ), + default="default", + dest="waf_token", + ) + waf_group.add_argument( + "--no-waf-token", + help="Skip the AWS WAF token entirely.", + action="store_const", + const=None, + dest="waf_token", + ) + parser_login_args.add_argument( + "--account", + help=( + "Use another account of this login, e.g. a company account. Give its type " + '(e.g. "LEGAL_ENTITY"), name or customer id as listed by "pytr accounts". ' + "Defaults to your own account." + ), + default=None, ) parser_login_args.add_argument( "--store_credentials", @@ -89,6 +115,15 @@ def formatter(prog): action="store_true", default=False, ) + parser_login_args.add_argument( + "--v2", + help=( + "Use the v2 web-login flow: confirm in the Trade Republic mobile app " + "instead of entering an SMS/notification code. Also supports authenticator-app accounts." + ), + action="store_true", + default=False, + ) # parent subparser for lang option parser_lang = argparse.ArgumentParser(add_help=False) @@ -140,6 +175,16 @@ def formatter(prog): description=info, ) + # accounts + info = "List accounts of this login, e.g. a company accounts or child accounts. Use them with --account" + parser_cmd.add_parser( + "accounts", + formatter_class=formatter, + parents=[parser_login_args], + help=info, + description=info, + ) + # portfolio info = "Show current portfolio" parser_portfolio = parser_cmd.add_parser( @@ -155,13 +200,19 @@ def formatter(prog): default=False, help="Include watchlist.", ) + parser_portfolio.add_argument( + "--ignore", + default=None, + metavar="ISINS", + help="Semicolon or comma separated list of ISINs to exclude from the portfolio, e.g. --ignore US30303M1027;DE0005140008", + ) parser_portfolio.add_argument("-o", "--output", help="Output path of CSV file", type=Path) parser_portfolio.add_argument( "--sort-by-column", - type=str.lower, - choices=[col.lower() for col in PORTFOLIO_COLUMNS], - default=None, - help="Sort results by column.", + type=str, + choices=list(PORTFOLIO_COLUMNS), + default="netValue", + help="Sort results by column (default: netValue).", ) parser_portfolio.add_argument( "--sort-ascending", @@ -170,6 +221,50 @@ def formatter(prog): help="Whether to sort in ascending order.", ) + # rates + info = "Fetch current prices for a list of ISINs given as direct list or CSV input" + parser_rates = parser_cmd.add_parser( + "rates", + formatter_class=formatter, + parents=[parser_login_args, parser_lang, parser_decimal_localization], + help=info, + description=info, + ) + parser_rates.add_argument( + "input", + nargs="*", + help="ISINs to fetch prices for; comma, semicolon or space separated, e.g. DE0005140008,US0378331005", + default=[], + ) + parser_rates.add_argument( + "-i", + "--inputfile", + help="Input file containing ISINs — comma, semicolon, whitespace or newline separated. Used when no ISINs given as positional args. Use '-' for stdin.", + type=argparse.FileType("r", encoding="utf-8"), + default=None, + nargs="?", + ) + parser_rates.add_argument( + "-o", + "--output", + help="Output path for CSV file (default: stdout).", + type=Path, + default=None, + ) + parser_rates.add_argument( + "--sort-by-column", + type=str, + choices=list(RATE_COLUMNS), + default="Name", + help="Sort results by column (default: Name).", + ) + parser_rates.add_argument( + "--sort-ascending", + action=argparse.BooleanOptionalAction, + default=True, + help="Whether to sort in ascending order.", + ) + # details info = "Get details for an ISIN" parser_details = parser_cmd.add_parser( @@ -265,6 +360,19 @@ def formatter(prog): help="Do not sort documents into folders and keep their original filenames", action="store_true", ) + parser_dl_docs.add_argument( + "--load-event-database", + help="Debug/analysis option: load events from this all_events.json instead of fetching from TR. Implies --dry-run; document URLs in the database may be expired.", + metavar="PATH", + default=None, + type=Path, + ) + parser_dl_docs.add_argument( + "--dry-run", + default=False, + help="Create folder structure and empty placeholder files without downloading", + action="store_true", + ) # export_transactions info = ( @@ -290,6 +398,13 @@ def formatter(prog): default=0, type=int, ) + parser_export_transactions.add_argument( + "--from_timestamp", + help="Include data from this exact timestamp onwards; overrides --last_days. Local time if no offset given (e.g. 2026-10-01T07:30:00), or with UTC offset (e.g. 2026-10-01T05:30:00+00:00)", + metavar="TIMESTAMP", + default=None, + type=str, + ) parser_export_transactions.add_argument( "--days_until", help="Include data up to N days ago (0 = include all days)", @@ -297,6 +412,13 @@ def formatter(prog): default=0, type=int, ) + parser_export_transactions.add_argument( + "--until_timestamp", + help="Include data up to this exact timestamp; overrides --days_until. Local time if no offset given (e.g. 2026-10-01T07:30:00), or with UTC offset (e.g. 2026-10-01T05:30:00+00:00)", + metavar="TIMESTAMP", + default=None, + type=str, + ) parser_export_transactions.add_argument( "--store-event-database", default=True, @@ -315,6 +437,13 @@ def formatter(prog): help="Dump more raw data in json format", action=argparse.BooleanOptionalAction, ) + parser_export_transactions.add_argument( + "--load-event-database", + help="Load events from this all_events.json file instead of fetching from TR (implies no login)", + metavar="PATH", + type=Path, + default=None, + ) parser_export_transactions.add_argument( "--export-format", "--format", @@ -444,7 +573,9 @@ def main(): # Compute the timestamp range to get data for not_before = 0 - if hasattr(args, "last_days"): + if hasattr(args, "from_timestamp") and args.from_timestamp is not None: + not_before = datetime.fromisoformat(args.from_timestamp).astimezone().timestamp() + elif hasattr(args, "last_days"): if args.last_days < 0: not_before = float(-1) elif args.last_days == 0: @@ -452,9 +583,13 @@ def main(): else: not_before = (datetime.now().astimezone() - timedelta(days=args.last_days)).timestamp() not_after = ( - (datetime.now().astimezone() - timedelta(days=args.days_until)).timestamp() - if hasattr(args, "days_until") and args.days_until > 0 - else float("inf") + datetime.fromisoformat(args.until_timestamp).astimezone().timestamp() + if hasattr(args, "until_timestamp") and args.until_timestamp is not None + else ( + (datetime.now().astimezone() - timedelta(days=args.days_until)).timestamp() + if hasattr(args, "days_until") and args.days_until > 0 + else float("inf") + ) ) if args.command == "login": @@ -463,6 +598,21 @@ def main(): pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, + ) + elif args.command == "accounts": + print( + print_accounts( + login( + phone_no=args.phone_no, + pin=args.pin, + store_credentials=args.store_credentials, + waf_token=args.waf_token, + v2=args.v2, + account=args.account, + ) + ) ) elif args.command == "portfolio": Portfolio( @@ -471,14 +621,38 @@ def main(): pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.include_watchlist, + instruments_to_ignore=re.split(r"[,;]", args.ignore) if args.ignore else [], lang=args.lang, decimal_localization=args.decimal_localization, output=args.output, sort_by_column=args.sort_by_column, sort_descending=not args.sort_ascending, ).get() + elif args.command == "rates": + isins = parse_isin_input(args.input, args.inputfile) + if not isins: + print("No valid ISINs found in input.") + return -1 + Rates( + login( + phone_no=args.phone_no, + pin=args.pin, + store_credentials=args.store_credentials, + waf_token=args.waf_token, + v2=args.v2, + account=args.account, + ), + isins, + output=args.output, + decimal_localization=args.decimal_localization, + lang=args.lang, + sort_by_column=args.sort_by_column, + sort_descending=not args.sort_ascending, + ).get() elif args.command == "details": Details( login( @@ -486,16 +660,22 @@ def main(): pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.isin, ).get() elif args.command == "dl_docs": DL( - login( + None + if args.load_event_database is not None + else login( phone_no=args.phone_no, pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.output, args.format, @@ -513,6 +693,8 @@ def main(): sort_export=args.sort, format_export=args.export_format, flat=args.flat, + load_event_database=args.load_event_database, + dry_run=args.dry_run, ).do_dl() elif args.command == "export_transactions": if args.outputfile is None and args.outputdir is None: @@ -520,11 +702,15 @@ def main(): return -1 tl = Timeline( - login( + None + if not_before == -1 or args.load_event_database is not None + else login( phone_no=args.phone_no, pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.outputdir, not_before, @@ -532,6 +718,7 @@ def main(): args.store_event_database, args.scan_for_duplicates, args.dump_raw_data, + load_event_database=args.load_event_database, ) asyncio.run(tl.tl_loop()) events = tl.events @@ -559,6 +746,8 @@ def main(): pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.input, args.outputfile, @@ -574,6 +763,8 @@ def main(): pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.input, args.inputfile, @@ -589,6 +780,8 @@ def main(): pin=args.pin, store_credentials=args.store_credentials, waf_token=args.waf_token, + v2=args.v2, + account=args.account, ), args.outputfile, decimal_localization=args.decimal_localization, diff --git a/pytr/portfolio.py b/pytr/portfolio.py index 7a14e45c..07c3d269 100644 --- a/pytr/portfolio.py +++ b/pytr/portfolio.py @@ -1,89 +1,57 @@ import asyncio import locale -import re from decimal import ROUND_HALF_UP, Decimal -from locale import getdefaultlocale from pathlib import Path -from typing import Optional, Union - -from babel.numbers import format_decimal +from typing import Optional +from .tickers import ( + decimal_format, + fetch_instrument_details, + fetch_tickers, + normalize_lang, +) from .utils import get_logger, preview -SUPPORTED_LANGUAGES = { - "cs", - "da", - "de", - "en", - "es", - "fr", - "it", - "nl", - "pl", - "pt", - "ru", - "zh", -} - -PORTFOLIO_COLUMNS = { +PORTFOLIO_COLUMNS = [ "Name", "ISIN", "quantity", "price", "avgCost", "netValue", -} - -bond_pattern = re.compile( - r"(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec|January|February|March|April|May|June|July|August|September|October|November|December|Januar|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember)\.?\s+20\d{2}", - re.IGNORECASE, -) +] class Portfolio: def __init__( self, tr, - include_watchlist=False, - lang="en", - decimal_localization=False, + include_watchlist: bool = False, + instruments_to_ignore: Optional[list[str]] = None, output=None, - sort_by_column=None, - sort_descending=True, + lang: str = "en", + decimal_localization: bool = False, + sort_by_column: Optional[str] = "netValue", + sort_descending: bool = True, ): self.tr = tr self.include_watchlist = include_watchlist - self.lang = lang - self.decimal_localization = decimal_localization + self.instruments_to_ignore = instruments_to_ignore or [] self.output = output + self.lang = normalize_lang(lang) + self.decimal_localization = decimal_localization self.sort_by_column = sort_by_column self.sort_descending = sort_descending - self.watchlist = None + self.watchlist: list[dict] = [] self._log = get_logger(__name__) - if self.lang == "auto": - locale = getdefaultlocale()[0] - if locale is None: - self.lang = "en" - else: - self.lang = locale.split("_")[0] - - if self.lang not in SUPPORTED_LANGUAGES: - self._log.info(f'Language not yet supported "{self.lang}", defaulting to "en"') - self.lang = "en" - - def _decimal_format(self, value: Optional[float], precision: int = 2) -> Union[str, None]: - if value is None: - return None - if self.decimal_localization: - format = "#,##0." + ("#" * precision) - return format_decimal(value, format=format, locale=self.lang) - else: - return f"{float(value):.{precision}f}".rstrip("0").rstrip(".") + def _decimal_format(self, value, precision: int = 2): + return decimal_format(value, precision, self.decimal_localization, self.lang) async def portfolio_loop(self): + self._log.info("Querying portfolio...") recv = 0 await self.tr.compact_portfolio() recv += 1 @@ -96,9 +64,17 @@ async def portfolio_loop(self): while recv > 0: subscription_id, subscription, response = await self.tr.recv() - if subscription["type"] == "compactPortfolio": + if subscription["type"] == "compactPortfolioByType": recv -= 1 - self.portfolio = response["positions"] + # New format: positions are grouped in categories[].positions + # Flatten all categories and normalize the field name: new API uses + # "isin" where the old "compactPortfolio" used "instrumentId". + self.positions = [] + for cat in response.get("categories", []): + for pos in cat.get("positions", []): + if "isin" in pos and "instrumentId" not in pos: + pos["instrumentId"] = pos["isin"] + self.positions.append(pos) elif subscription["type"] == "cash": recv -= 1 self.cash = response @@ -110,127 +86,69 @@ async def portfolio_loop(self): await self.tr.unsubscribe(subscription_id) - # a way to ignore instruments from portfolio - # e.g. set to ["US30303M1027"] if you want to exclude Meta Platforms (A) - # this should be exposed as a parameter... - instruments_to_ignore = [] - isins = set() - portfolio = list() - for pos in self.portfolio: - if pos["instrumentId"] not in instruments_to_ignore: - portfolio.append(pos) + positions = list() + for pos in self.positions: + if pos["instrumentId"] not in self.instruments_to_ignore: + positions.append(pos) isins.add(pos["instrumentId"]) - self.portfolio = portfolio + self.positions = positions # extend portfolio with watchlist elements - if self.watchlist: - for pos in self.watchlist: - if pos["instrumentId"] not in instruments_to_ignore: - isin = pos["instrumentId"] - if isin not in isins: - isins.add(isin) - self.portfolio.append(pos) - - # Populate name for each ISIN - subscriptions = {} - for pos in self.portfolio: - isin = pos["instrumentId"] - subscription_id = await self.tr.instrument_details(isin) - subscriptions[subscription_id] = pos - - while len(subscriptions) > 0: - subscription_id, subscription, response = await self.tr.recv() - - if subscription["type"] == "instrument": - await self.tr.unsubscribe(subscription_id) - pos = subscriptions.pop(subscription_id, None) - pos["name"] = response["shortName"] - pos["exchangeIds"] = response["exchangeIds"] - else: - print(f"unmatched subscription of type '{subscription['type']}':\n{preview(response)}") + for pos in self.watchlist: + if pos["instrumentId"] not in isins and pos["instrumentId"] not in self.instruments_to_ignore: + isins.add(pos["instrumentId"]) + self.positions.append(pos) - # Get tickers and populate netValue for each ISIN self._log.info("Subscribing to tickers...") - subscriptions = {} - for pos in self.portfolio: - isin = pos["instrumentId"] - if len(pos["exchangeIds"]) > 0: - subscription_id = await self.tr.ticker(isin, exchange=pos["exchangeIds"][0]) - subscriptions[subscription_id] = pos - - self._log.info("Waiting for tickers...") - while len(subscriptions) > 0: - try: - subscription_id, subscription, response = await asyncio.wait_for(self.tr.recv(), 5) - except asyncio.TimeoutError: - print("Timed out waiting for tickers") - print(f"Remaining subscriptions: {subscriptions}") - break - - if subscription["type"] == "ticker": - await self.tr.unsubscribe(subscription_id) - pos = subscriptions.pop(subscription_id, None) - pos["price"] = response["last"]["price"] - # Bond handling - # Identify bonds by parsing the name - bond names are like "... month year" - if bond_pattern.search(pos["name"]): - # Bond prices are per €100 face value - pos["price"] = Decimal(pos["price"]) / 100 + await fetch_instrument_details(self.tr, self.positions) + missing = await fetch_tickers(self.tr, self.positions) + for pos in missing: + print( + f"Missing price for {pos.get('name', pos['instrumentId'])} ({pos['instrumentId']}), removing from result." + ) - # watchlist positions don't have size/value - if "netSize" not in pos: - pos["netSize"] = "0" - pos["averageBuyIn"] = pos["price"] - pos["netValue"] = (Decimal(pos["price"]) * Decimal(pos["netSize"])).quantize( - Decimal("0.01"), rounding=ROUND_HALF_UP - ) - else: - print(f"unmatched subscription of type '{subscription['type']}':\n{preview(response)}") + self.positions = [pos for pos in self.positions if "price" in pos] - # sanitize - it can happen that we get no price, e.g. we ran into a timeout above or some instrument - # does not deliver a price. Then we kick it out of the list and log this. - portfolionew = [] - for pos in self.portfolio: - if "price" not in pos: - print(f"Missing price for {pos['name']} ({pos['instrumentId']}), removing from result.") - else: - portfolionew.append(pos) - self.portfolio = portfolionew + # Compute netValue from price and netSize (netSize comes from the portfolio, not tickers) + for pos in self.positions: + # watchlist positions don't have size/value + if "netSize" not in pos: + pos["netSize"] = "0" + pos["averageBuyIn"] = pos["price"] + pos["netValue"] = (Decimal(pos["price"]) * Decimal(pos["netSize"])).quantize( + Decimal("0.01"), rounding=ROUND_HALF_UP + ) await self.tr.close() def _get_sort_func(self): - if self.sort_by_column: - match self.sort_by_column.lower(): - case "name": - if self.lang == "de": - locale.setlocale(locale.LC_COLLATE, "de_DE.UTF-8") - return lambda x: locale.strxfrm(x["name"].lower()) - case "isin": - if self.lang == "de": - locale.setlocale(locale.LC_COLLATE, "de_DE.UTF-8") - return lambda x: locale.strxfrm(x["instrumentId"].lower()) - case "quantity": - return lambda x: Decimal(x["netSize"]) - case "price": - return lambda x: Decimal(x["price"]) - case "avgCost": - return lambda x: Decimal(x["averageBuyIn"]) - case "netValue": - return lambda x: Decimal(x["netValue"]) - case _ as m: + match self.sort_by_column: + case "Name": + if self.lang == "de": + locale.setlocale(locale.LC_COLLATE, "de_DE.UTF-8") + return lambda x: locale.strxfrm(x["name"].lower()) + case "ISIN": + if self.lang == "de": + locale.setlocale(locale.LC_COLLATE, "de_DE.UTF-8") + return lambda x: locale.strxfrm(x["instrumentId"].lower()) + case "quantity": + return lambda x: Decimal(x["netSize"]) + case "price": + return lambda x: Decimal(x["price"]) + case "avgCost": + return lambda x: Decimal(x["averageBuyIn"]) + case _ as m: + if m != "netValue": print(f"Column {m} does not exist for portfolio list, reverting to default sorting by netValue.") - return lambda x: Decimal(x["netValue"]) - else: - return lambda x: Decimal(x["netValue"]) + return lambda x: Decimal(x["netValue"]) - def portfolio_to_csv(self): + def write_csv(self): if self.output is None: return csv_lines = [] - for pos in sorted(self.portfolio, key=self._get_sort_func(), reverse=self.sort_descending): + for pos in sorted(self.positions, key=self._get_sort_func(), reverse=self.sort_descending): csv_lines.append( f"{pos['name']};" f"{pos['instrumentId']};" @@ -242,7 +160,7 @@ def portfolio_to_csv(self): Path(self.output).parent.mkdir(parents=True, exist_ok=True) with open(self.output, "w", encoding="utf-8") as f: - f.write("Name;ISIN;quantity;price;avgCost;netValue\n") + f.write(";".join(PORTFOLIO_COLUMNS) + "\n") f.write("\n".join(csv_lines) + ("\n" if csv_lines else "")) print(f"Wrote {len(csv_lines) + 1} lines to {self.output}") @@ -256,7 +174,7 @@ def overview(self): "Name ISIN avgCost * quantity = buyCost -> netValue price diff %-diff" ) - for pos in sorted(self.portfolio, key=self._get_sort_func(), reverse=self.sort_descending): + for pos in sorted(self.positions, key=self._get_sort_func(), reverse=self.sort_descending): buyCost = (Decimal(pos["averageBuyIn"]) * Decimal(pos["netSize"])).quantize( Decimal("0.01"), rounding=ROUND_HALF_UP ) @@ -295,4 +213,4 @@ def get(self): asyncio.run(self.portfolio_loop()) self.overview() - self.portfolio_to_csv() + self.write_csv() diff --git a/pytr/rates.py b/pytr/rates.py new file mode 100644 index 00000000..ba6757d8 --- /dev/null +++ b/pytr/rates.py @@ -0,0 +1,142 @@ +import asyncio +import locale +import re +from decimal import Decimal +from pathlib import Path +from typing import Optional + +from .tickers import ( + decimal_format, + fetch_instrument_details, + fetch_tickers, + normalize_lang, +) +from .utils import get_logger + +RATE_COLUMNS = [ + "Name", + "ISIN", + "price", + "ask", +] + + +class Rates: + def __init__( + self, + tr, + isins: list[str], + output=None, + lang: str = "en", + decimal_localization: bool = False, + sort_by_column: Optional[str] = "name", + sort_descending: bool = False, + ): + self.tr = tr + self.isins = isins + self.output = output + self.lang = normalize_lang(lang) + self.decimal_localization = decimal_localization + self.sort_by_column = sort_by_column + self.sort_descending = sort_descending + + self._log = get_logger(__name__) + + def _decimal_format(self, value, precision: int = 4): + return decimal_format(value, precision, self.decimal_localization, self.lang) + + async def rates_loop(self): + if not self.isins: + self._log.warning("No ISINs provided.") + return + + self.positions = [{"instrumentId": isin} for isin in self.isins] + + self._log.info("Subscribing to tickers...") + await fetch_instrument_details(self.tr, self.positions) + missing = await fetch_tickers(self.tr, self.positions) + for pos in missing: + self._log.warning( + f"Missing price for {pos.get('name', pos['instrumentId'])} ({pos['instrumentId']}), removing from result." + ) + + self.positions = [pos for pos in self.positions if "price" in pos] + + await self.tr.close() + + def _get_sort_func(self): + match self.sort_by_column: + case "ISIN": + if self.lang == "de": + locale.setlocale(locale.LC_COLLATE, "de_DE.UTF-8") + return lambda x: locale.strxfrm(x["instrumentId"].lower()) + case "ask": + return lambda x: Decimal(x["ask"]) if x.get("ask") is not None else Decimal(0) + case "price": + return lambda x: Decimal(x["price"]) + case _ as m: + if m != "Name": + print(f"Column {m} does not exist for rates list, reverting to default sorting by Name.") + if self.lang == "de": + locale.setlocale(locale.LC_COLLATE, "de_DE.UTF-8") + return lambda x: locale.strxfrm(x["name"].lower()) + + def overview(self): + print(f"{'Name':<30.30} {'ISIN':<12} {'price':>10} {'ask':>10}") + for p in sorted(self.positions, key=self._get_sort_func(), reverse=self.sort_descending): + print( + f"{p['name']:<30.30} " + f"{p['instrumentId']:<12} " + f"{self._decimal_format(p['price']):>10} " + f"{self._decimal_format(p.get('ask')):>10}" + ) + + def write_csv(self): + lines = [ + f"{p['name']};{p['instrumentId']};{self._decimal_format(p['price'])};{self._decimal_format(p.get('ask'))}" + for p in sorted(self.positions, key=self._get_sort_func(), reverse=self.sort_descending) + ] + header = ";".join(RATE_COLUMNS) + content = header + "\n" + "\n".join(lines) + ("\n" if lines else "") + Path(self.output).parent.mkdir(parents=True, exist_ok=True) + with open(self.output, "w", encoding="utf-8") as f: + f.write(content) + print(f"Wrote {len(lines) + 1} lines to {self.output}") + + def get(self): + asyncio.run(self.rates_loop()) + if self.output is None: + self.overview() + else: + self.write_csv() + + +ISIN_RE = re.compile(r"^[A-Z]{2}[A-Z0-9]{10}$") + + +def _extract_isins(tokens: list[str]) -> list[str]: + return [t for t in tokens if ISIN_RE.match(t)] + + +def _split_isin_text(text: str) -> list[str]: + """Split text on commas, semicolons, or whitespace and return non-empty tokens.""" + return [t.strip() for t in re.split(r"[,;\s]+", text) if t.strip()] + + +def parse_isin_input(input_list: list[str], fileobj) -> list[str]: + """Return ISINs from input_list (preferred) or from a file/stdin. + + Tokens may be comma, semicolon, or whitespace/newline separated. + """ + if input_list: + tokens = _split_isin_text(" ".join(input_list)) + return _extract_isins(tokens) + + if fileobj is None: + return [] + + content = fileobj.read() + if not content.strip(): + return [] + + return _extract_isins(_split_isin_text(content)) diff --git a/pytr/tickers.py b/pytr/tickers.py new file mode 100644 index 00000000..13c4afa2 --- /dev/null +++ b/pytr/tickers.py @@ -0,0 +1,109 @@ +import asyncio +import re +from decimal import Decimal +from locale import getdefaultlocale +from typing import Optional + +from babel.numbers import format_decimal + +from .utils import get_logger + +SUPPORTED_LANGUAGES = { + "cs", + "da", + "de", + "en", + "es", + "fr", + "it", + "nl", + "pl", + "pt", + "ru", + "zh", +} + +bond_pattern = re.compile( + r"(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec|January|February|March|April|May|June|July|August|September|October|November|December|Januar|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember)\.?\s+20\d{2}", + re.IGNORECASE, +) + +_log = get_logger(__name__) + + +def normalize_lang(lang: str) -> str: + """Resolve 'auto' to the system locale language, fall back to 'en' if unsupported.""" + if lang == "auto": + detected = getdefaultlocale()[0] + lang = detected.split("_")[0] if detected else "en" + if lang not in SUPPORTED_LANGUAGES: + _log.info(f'Language not yet supported "{lang}", defaulting to "en"') + lang = "en" + return lang + + +def decimal_format( + value, + precision: int = 2, + decimal_localization: bool = False, + lang: str = "en", +) -> Optional[str]: + if value is None: + return None + if decimal_localization: + fmt = "#,##0." + ("#" * precision) + return format_decimal(value, format=fmt, locale=lang) + return f"{float(value):.{precision}f}".rstrip("0").rstrip(".") + + +async def fetch_instrument_details(tr, positions: list[dict]) -> None: + """Populate pos['name'] and pos['exchangeIds'] for each position in-place.""" + subscriptions = {} + for pos in positions: + sub_id = await tr.instrument_details(pos["instrumentId"]) + subscriptions[sub_id] = pos + + while subscriptions: + sub_id, subscription, response = await tr.recv() + if subscription["type"] == "instrument": + await tr.unsubscribe(sub_id) + pos = subscriptions.pop(sub_id) + pos["name"] = response.get("shortName", pos["instrumentId"]) + pos["exchangeIds"] = response.get("exchangeIds", []) + else: + _log.debug(f"Unexpected subscription type: {subscription['type']}") + + +async def fetch_tickers(tr, positions: list[dict], timeout: float = 5.0) -> list[dict]: + """Fetch ticker prices for positions that have exchangeIds. + + Populates pos['price'] and pos['ask'] in-place. Bond prices are divided by 100. + Returns the list of positions for which no price was received. + """ + subscriptions = {} + for pos in positions: + if pos.get("exchangeIds"): + sub_id = await tr.ticker(pos["instrumentId"], exchange=pos["exchangeIds"][0]) + subscriptions[sub_id] = pos + else: + _log.warning(f"No exchange found for {pos['instrumentId']}, skipping.") + + while subscriptions: + try: + sub_id, subscription, response = await asyncio.wait_for(tr.recv(), timeout) + except asyncio.TimeoutError: + _log.warning(f"Timed out waiting for tickers: {list(subscriptions.values())}") + break + + if subscription["type"] == "ticker": + await tr.unsubscribe(sub_id) + pos = subscriptions.pop(sub_id) + pos["price"] = response["last"]["price"] + if bond_pattern.search(pos.get("name", "")): + pos["price"] = Decimal(pos["price"]) / 100 + pos["ask"] = response.get("ask", {}).get("price") + else: + _log.debug(f"Unexpected subscription type: {subscription['type']}") + + missing = [pos for pos in positions if "price" not in pos] + return missing diff --git a/pytr/timeline.py b/pytr/timeline.py index 84f5ea1c..03da6ab6 100644 --- a/pytr/timeline.py +++ b/pytr/timeline.py @@ -43,15 +43,16 @@ def __init__( scan_for_duplicates=False, dump_raw_data=False, event_callback=lambda *a, **kw: None, + load_event_database=None, ): self.tr = tr self.output_path = output_path - if not_before == -1: + if load_event_database is not None or not_before == -1: self.fetch_from_tr = False - self.not_before = float(0) else: self.fetch_from_tr = True - self.not_before = not_before + self.not_before = float(0) if not_before == -1 else not_before + self.load_event_database = load_event_database self.not_after = not_after self.store_event_database = store_event_database self.scan_for_duplicates = scan_for_duplicates @@ -74,11 +75,11 @@ def __init__( output_path.mkdir(parents=True, exist_ok=True) async def tl_loop(self): - await self.get_next_timeline_transactions(None) - - # We might not want to download anything from TR but just create/update account_transactions.csv from available data if not self.fetch_from_tr: self.finish_timeline_details() + return + + await self.get_next_timeline_transactions(None) while not self.dl_done: try: @@ -124,7 +125,7 @@ async def get_next_timeline_transactions(self, response): self.num_timelines += 1 added_last_event = False for event in response["items"]: - event_timestamp = datetime.fromisoformat(event["timestamp"][:19]).timestamp() + event_timestamp = datetime.fromisoformat(event["timestamp"][:19] + "+00:00").timestamp() if event_timestamp > self.not_before: if event_timestamp < self.not_after: event["source"] = "timelineTransaction" @@ -160,7 +161,7 @@ async def get_next_timeline_activity_log(self, response): self.num_timelines += 1 added_last_event = False for event in response["items"]: - event_timestamp = datetime.fromisoformat(event["timestamp"][:19]).timestamp() + event_timestamp = datetime.fromisoformat(event["timestamp"][:19] + "+00:00").timestamp() if event_timestamp > self.not_before: if event_timestamp < self.not_after: event["source"] = "timelineActivity" @@ -201,27 +202,29 @@ async def _request_timeline_details(self): self.detail_digits = len(str(self.all_detail)) for event in self.timeline_details.values(): - msg = None + self.requested_detail += 1 + action = event.get("action") - if action is None: - if event.get("actionLabel") is None: - msg = "Skip timeline detail: No action/actionLabel section" - elif action.get("type") != "timelineDetail": - msg = f"Skip timeline detail: Action type {action['type']} is not timelineDetail" + action_type = action.get("type") if action is not None else None + if action_type != "timelineDetail": + self.received_detail += 1 + self.events.append(event) + self.log.info( + f"{self.received_detail + self.skipped_detail:>{self.detail_digits}}/{self.all_detail}: " + f"{event['title']} -- {event['subtitle']} - {event['timestamp'][:19]}" + f" (no timeline detail, action type: {action_type!r})" + ) elif action.get("payload") != event["id"]: - msg = f"Skip timeline detail: Action payload {action['payload']} does not match id {event['id']}" - - self.requested_detail += 1 - if msg is None: - await self.tr.timeline_detail_v2(event["id"]) - else: self.received_detail += 1 self.events.append(event) self.log.warning( f"{self.received_detail + self.skipped_detail:>{self.detail_digits}}/{self.all_detail}: " - + f"{event['title']} -- {event['subtitle']} - {event['timestamp'][:19]} {msg}" + f"{event['title']} -- {event['subtitle']} - {event['timestamp'][:19]}" + f" (action payload {action['payload']!r} does not match event id {event['id']!r})" ) - self.log.debug("%s: %s", msg, json.dumps(event, indent=2)) + self.log.debug("payload mismatch: %s", json.dumps(event, indent=2)) + else: + await self.tr.timeline_detail_v2(event["id"]) if self.requested_detail % MAX_EVENT_REQUEST_BATCH == 0 and ( (self.received_detail + self.skipped_detail) < self.requested_detail @@ -281,22 +284,31 @@ def finish_timeline_details(self): else: self.log.info("Skip fetching data from TR.") - if self.store_event_database: - self.log.info("Updating event database...") - - # read old events from all_events.json + if self.store_event_database or self.load_event_database is not None: + # read old events from all_events.json (or explicit --load-event-database path) old_events = [] - all_events_path = self.output_path / "all_events.json" + all_events_path = ( + self.load_event_database + if self.load_event_database is not None + else self.output_path / "all_events.json" + ) if all_events_path.exists(): - self.log.info("Reading event database...") + self.log.info(f"Loading event database from {all_events_path}...") with open(all_events_path, "r", encoding="utf-8") as f: - old_events = json.load(f) + try: + old_events = json.load(f) + except json.JSONDecodeError: + self.log.warning(f"Event database file is empty or invalid: {all_events_path}") + if not old_events: + self.log.warning("No events found in event database.") + elif self.load_event_database is not None: + self.log.warning(f"Event database file not found: {all_events_path}") # if we have new data from a certain period, throw out old data if self.fetch_from_tr and (self.not_before != 0 or self.not_after != float("inf")): self.log.info("Throwing away outdated events...") for i in range(len(old_events) - 1, -1, -1): - ts = datetime.fromisoformat(old_events[i]["timestamp"][:19]).timestamp() + ts = datetime.fromisoformat(old_events[i]["timestamp"][:19] + "+00:00").timestamp() if ts > self.not_before and ts < self.not_after: del old_events[i] @@ -353,11 +365,24 @@ def finish_timeline_details(self): self.log.info("Sorting events...") self.events.sort(key=lambda value: datetime.fromisoformat(value["timestamp"][:19])) - if self.fetch_from_tr: + if self.fetch_from_tr and self.store_event_database: self.log.info(f"Writing {all_events_path}...") with open(all_events_path, "w", encoding="utf-8") as f: json.dump(self.events, f, ensure_ascii=False, indent=2, default=str) + self.log.info("Updated event database.") - self.log.info("Updated event database.") + if not self.fetch_from_tr: + filtered = [ + e + for e in self.events + if "details" in e + and datetime.fromisoformat(e["timestamp"][:19] + "+00:00").timestamp() >= self.not_before + and datetime.fromisoformat(e["timestamp"][:19] + "+00:00").timestamp() <= self.not_after + ] + self.log.info(f"Replaying {len(filtered)} events from database (out of {len(self.events)} total)...") + self.all_detail = len(filtered) + for event in filtered: + self.event_callback(event) + self.events = filtered self.dl_done = True diff --git a/pytr/transactions.py b/pytr/transactions.py index 2c7821e1..5920d1b0 100644 --- a/pytr/transactions.py +++ b/pytr/transactions.py @@ -141,10 +141,7 @@ def from_event(self, event: Event) -> Iterable[dict[str, Any]]: kwargs2 = kwargs.copy() kwargs2["type"] = self._translate((PPEventType.BUY if event.value < 0 else PPEventType.SELL).value) kwargs2["note"] = event.isin2 - if event.isin2 == "ORSTED A/S EM.09/25 DK 10": - kwargs2["isin"] = "DK0064307755" - else: - kwargs2["isin"] = event.isin2 + kwargs2["isin"] = event.isin2 kwargs2["shares"] = self._decimal_format(event.shares2, False) yield self._localize_keys(kwargs2) kwargs["value"] = self._decimal_format(0) @@ -156,46 +153,6 @@ def from_event(self, event: Event) -> Iterable[dict[str, Any]]: kwargs2 = kwargs.copy() kwargs2["type"] = self._translate(PPEventType.SELL.value) yield self._localize_keys(kwargs2) - - # kwargs["type"] = self._translate(PPEventType.BUY.value) - kwargs["isin2"] = event.isin - if event.note == "BlackRock Funding": - kwargs["isin"] = "US09290D1019" - elif event.note == "BYD": - kwargs["isin"] = "CNE100000296" - elif event.note == "Chipotle": - kwargs["isin"] = "US1696561059" - elif event.note == "VERSANT MEDIA GRP A O.N.": - kwargs["isin"] = "US9252831030" - elif event.note == "Eckert & Ziegler": - kwargs["isin"] = "DE0005659700" - elif event.note == "Enovix Corp. WTS 01.10.26": - kwargs["isin"] = "US2935941318" - elif event.note == "Gamestop Corp. WTS 30.10.26": - kwargs["isin"] = "US36467W1172" - elif event.note == "GLOBALSTAR INC. O.N.": - kwargs["isin"] = "US3789735079" - elif event.note == "Magnum Ice Cream": - kwargs["isin"] = "NL0015002MS2" - elif event.note == "Netflix": - kwargs["isin"] = "US64110L1061" - elif event.note == "NVIDIA": - kwargs["isin"] = "US67066G1040" - elif event.note == "Orsted": - kwargs["isin"] = "DK0060094928" - elif event.note == "ORSTED A/S -ANR-": - kwargs["isin"] = "DK0064307839" - elif event.note == "ROCKET LAB CORP. O.N.": - kwargs["isin"] = "US7731211089" - elif event.note == "TKMS": - kwargs["isin"] = "DE000TKMS001" - elif event.note == "Unilever": - kwargs["isin"] = "GB00BVZK7T90" - elif event.note == "Worldline": - kwargs["isin"] = "FR0014015MS9" - else: - kwargs["isin"] = event.isin2 - if event.shares2: kwargs["shares"] = self._decimal_format(event.shares2, False) kwargs["note"] = event.note # Special case for saveback events. Example payload: https://github.com/pytr-org/pytr/issues/116#issuecomment-2377491990 @@ -212,11 +169,6 @@ def from_event(self, event: Event) -> Iterable[dict[str, Any]]: kwargs["isin"] = None kwargs["shares"] = None elif event.event_type == ConditionalEventType.PRIVATE_MARKETS_ORDER: - if event.isin == "LU3176111881": - kwargs["note"] = "EQT" - elif event.isin == "LU3170240538": - kwargs["note"] = "Apollo" - assert event.value is not None, event kwargs["type"] = self._translate((PPEventType.BUY if event.value < 0 else PPEventType.SELL).value) if event.note == "1 % Bonus": @@ -227,50 +179,7 @@ def from_event(self, event: Event) -> Iterable[dict[str, Any]]: kwargs["value"] = self._decimal_format(-event.value) kwargs["isin"] = None kwargs["shares"] = None - elif event.event_type == PPEventType.TAXES: - if event.isin == "LU3176111881": - kwargs["note"] = "EQT" - elif event.isin == "LU3170240538": - kwargs["note"] = "Apollo" elif event.event_type == PPEventType.SWAP: - if event.note == "BlackRock Funding": - kwargs["isin2"] = "US09290D1019" - elif event.note == "BYD": - kwargs["isin2"] = "CNE100000296" - elif event.note == "Chipotle": - kwargs["isin2"] = "US1696561059" - elif event.note == "Eckert & Ziegler": - kwargs["isin2"] = "DE0005659700" - elif event.note == "Enovix Corp. WTS 01.10.26": - kwargs["isin2"] = "US2935941318" - elif event.note == "Gamestop Corp. WTS 30.10.26": - kwargs["isin2"] = "US36467W1172" - elif event.note == "GLOBALSTAR INC. O.N.": - kwargs["isin2"] = "US3789735079" - elif event.note == "Magnum Ice Cream": - kwargs["isin2"] = "NL0015002MS2" - elif event.note == "Netflix": - kwargs["isin2"] = "US64110L1061" - elif event.note == "NVIDIA": - kwargs["isin2"] = "US67066G1040" - elif event.note == "Orsted": - kwargs["isin2"] = "DK0060094928" - elif event.note == "ORSTED A/S -ANR-": - kwargs["isin2"] = "DK0064307839" - elif event.note == "ORSTED A/S EM.09/25 DK 10": - kwargs["isin2"] = "DK0064307755" - elif event.note == "ROCKET LAB CORP. O.N.": - kwargs["isin2"] = "US7731211089" - elif event.note == "TKMS": - kwargs["isin2"] = "DE000TKMS001" - elif event.note == "Unilever": - kwargs["isin2"] = "GB00BVZK7T90" - elif event.note == "MSCI World USD (Acc)" and event.isin == "LU1781541179": - kwargs["isin2"] = "IE000BI8OT95" - elif event.note == "Worldline": - kwargs["isin2"] = "FR0011981968" - else: - kwargs["isin2"] = event.note kwargs["note"] = event.title yield self._localize_keys(kwargs) diff --git a/tests/aktien_entfernt.json b/tests/aktien_entfernt.json deleted file mode 100644 index bfa39f9a..00000000 --- a/tests/aktien_entfernt.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", - "timestamp": "2025-10-28T15:46:46.286+0000", - "title": "ORSTED A/S -ANR-", - "icon": "logos/DK0064307839/v2", - "subtitle": "Wertlos", - "action": { - "type": "timelineDetail", - "payload": "c187c065-fadf-33bd-8de9-fe0ac6c0e686" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", - "sections": [ - { - "title": "Aktien wurden im Rahmen einer Kapitalmaßnahme entfernt", - "data": { - "icon": "logos/DK0064307839/v2", - "timestamp": "2025-10-28T15:46:46.286Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Wertlos", - "displayValue": { - "text": "Wertlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S -ANR-", - "displayValue": { - "text": "ORSTED A/S -ANR-" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "0.285835", - "displayValue": { - "text": "0.285835" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "28.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "9fdeded6-aa07-401a-ad47-740da1a4c41e", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktien_entfernt2.json b/tests/aktien_entfernt2.json deleted file mode 100644 index cc701610..00000000 --- a/tests/aktien_entfernt2.json +++ /dev/null @@ -1,96 +0,0 @@ - { - "id": "6919f8d9-e168-321f-b276-8766ce50f319", - "timestamp": "2026-04-03T10:48:40.913+0000", - "title": "WORLDLINE S.A. ANR", - "icon": "logos/FR0014015MS9/v2", - "subtitle": "Wertlos", - "action": { - "type": "timelineDetail", - "payload": "6919f8d9-e168-321f-b276-8766ce50f319" - }, - "eventType": "SSP_CORPORATE_ACTION_NO_CASH", - "hidden": false, - "deleted": false, - "source": "timelineActivity", - "details": { - "id": "6919f8d9-e168-321f-b276-8766ce50f319", - "sections": [ - { - "title": "Aktien wurden im Rahmen einer Kapitalmaßnahme entfernt", - "data": { - "icon": { - "asset": "logos/FR0014015MS9/v2", - "badge": null - }, - "timestamp": "2026-04-03T10:48:40.913Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Wertlos", - "displayValue": { - "text": "Wertlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "WORLDLINE S.A. ANR", - "displayValue": { - "text": "WORLDLINE S.A. ANR" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "0.299376", - "displayValue": { - "text": "0.299376" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "03.04.2026", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "806617db-1080-4301-8768-a87bf909f896", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} \ No newline at end of file diff --git a/tests/aktien_entfernt_no_eventType.json b/tests/aktien_entfernt_no_eventType.json deleted file mode 100644 index b49225b4..00000000 --- a/tests/aktien_entfernt_no_eventType.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", - "timestamp": "2025-10-28T15:46:46.286+0000", - "title": "ORSTED A/S -ANR-", - "icon": "logos/DK0064307839/v2", - "subtitle": "Wertlos", - "action": { - "type": "timelineDetail", - "payload": "c187c065-fadf-33bd-8de9-fe0ac6c0e686" - }, - "source": "timelineActivity", - "details": { - "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", - "sections": [ - { - "title": "Aktien wurden im Rahmen einer Kapitalmaßnahme entfernt", - "data": { - "icon": "logos/DK0064307839/v2", - "timestamp": "2025-10-28T15:46:46.286Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Wertlos", - "displayValue": { - "text": "Wertlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S -ANR-", - "displayValue": { - "text": "ORSTED A/S -ANR-" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "0.285835", - "displayValue": { - "text": "0.285835" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "28.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "9fdeded6-aa07-401a-ad47-740da1a4c41e", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktienbonus.json b/tests/aktienbonus.json deleted file mode 100644 index f75621c8..00000000 --- a/tests/aktienbonus.json +++ /dev/null @@ -1,94 +0,0 @@ - { - "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", - "timestamp": "2025-10-13T14:49:06.032+0000", - "title": "Aktien-Bonus", - "icon": "logos/US2546871060/v2", - "subtitle": "Eingelöst", - "action": { - "type": "timelineDetail", - "payload": "690011dc-3825-4f6d-9eaa-239ff72ba4d7" - }, - "eventType": "ACQUISITION_TRADE_PERK", - "source": "timelineActivity", - "details": { - "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", - "sections": [ - { - "title": "Walt Disney Aktienbonus", - "data": { - "icon": "logos/US2546871060/v2", - "timestamp": "2025-10-13T14:49:05.799+0000", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Vermögenswert", - "detail": { - "text": "Walt Disney", - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "", - "displayValue": { - "text": "95,56 €", - "prefix": "0.105 ×" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "10,03 €", - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "879aa27f-f32f-44c3-beec-29c5d75d3a4f", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Rechnung", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "30237d68-3418-47ef-98f2-6a32fac756c0", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktienbonus_no_eventType.json b/tests/aktienbonus_no_eventType.json deleted file mode 100644 index f8b61a9b..00000000 --- a/tests/aktienbonus_no_eventType.json +++ /dev/null @@ -1,93 +0,0 @@ -{ - "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", - "timestamp": "2025-10-13T14:49:06.032+0000", - "title": "Aktien-Bonus", - "icon": "logos/US2546871060/v2", - "subtitle": "Eingelöst", - "action": { - "type": "timelineDetail", - "payload": "690011dc-3825-4f6d-9eaa-239ff72ba4d7" - }, - "source": "timelineActivity", - "details": { - "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", - "sections": [ - { - "title": "Walt Disney Aktienbonus", - "data": { - "icon": "logos/US2546871060/v2", - "timestamp": "2025-10-13T14:49:05.799+0000", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Vermögenswert", - "detail": { - "text": "Walt Disney", - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "", - "displayValue": { - "text": "95,56 €", - "prefix": "0.105 ×" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "10,03 €", - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "879aa27f-f32f-44c3-beec-29c5d75d3a4f", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Rechnung", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "30237d68-3418-47ef-98f2-6a32fac756c0", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktiendividende.json b/tests/aktiendividende.json deleted file mode 100644 index 1d9d815f..00000000 --- a/tests/aktiendividende.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", - "timestamp": "2025-07-22T14:31:49.846+0000", - "title": "Enovix", - "icon": "logos/US2935941078/v2", - "subtitle": "Aktiendividende", - "action": { - "type": "timelineDetail", - "payload": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/US2935941078/v2", - "timestamp": "2025-07-22T14:31:49.846Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Aktiendividende", - "displayValue": { - "text": "Aktiendividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Enovix Corp. WTS 01.10.26", - "displayValue": { - "text": "Enovix Corp. WTS 01.10.26" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "0.494370", - "displayValue": { - "text": "0.494370" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "22.07.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "84c35bc3-e130-44ca-aa87-3a66b055b185", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktiendividende_no_eventType.json b/tests/aktiendividende_no_eventType.json deleted file mode 100644 index 526f762d..00000000 --- a/tests/aktiendividende_no_eventType.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", - "timestamp": "2025-07-22T14:31:49.846+0000", - "title": "Enovix", - "icon": "logos/US2935941078/v2", - "subtitle": "Aktiendividende", - "action": { - "type": "timelineDetail", - "payload": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4" - }, - "source": "timelineActivity", - "details": { - "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/US2935941078/v2", - "timestamp": "2025-07-22T14:31:49.846Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Aktiendividende", - "displayValue": { - "text": "Aktiendividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Enovix Corp. WTS 01.10.26", - "displayValue": { - "text": "Enovix Corp. WTS 01.10.26" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "0.494370", - "displayValue": { - "text": "0.494370" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "22.07.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "84c35bc3-e130-44ca-aa87-3a66b055b185", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktiendividende_only_taxes.json b/tests/aktiendividende_only_taxes.json deleted file mode 100644 index d643e052..00000000 --- a/tests/aktiendividende_only_taxes.json +++ /dev/null @@ -1,136 +0,0 @@ -{ - "id": "09fffef5-6022-32a6-a5b5-55fcd880cad6", - "timestamp": "2026-01-06T16:14:51.218+0000", - "title": "Enovix Corp. WTS 01.10.26", - "icon": "logos/US2935941078/v2", - "avatar": { - "asset": "logos/US2935941078/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aktiendividende", - "amount": { - "currency": "EUR", - "value": -0.57, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "09fffef5-6022-32a6-a5b5-55fcd880cad6" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "09fffef5-6022-32a6-a5b5-55fcd880cad6", - "sections": [ - { - "title": "Du hast -0,57 € bezahlt", - "data": { - "icon": { - "asset": "logos/US2935941318/v2", - "badge": null - }, - "timestamp": "2026-01-06T16:14:51.218Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aktiendividende", - "displayValue": { - "text": "Aktiendividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Enovix Corp. WTS 01.10.26", - "displayValue": { - "text": "Enovix Corp. WTS 01.10.26" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-0,57 €", - "displayValue": { - "text": "-0,57 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-0,57 €", - "displayValue": { - "text": "-0,57 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "06.01.2026", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "6406bb21-18b9-41d6-9ec8-cecd3babbd82", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktienpraemiendividende.json b/tests/aktienpraemiendividende.json deleted file mode 100644 index 8d61b0f1..00000000 --- a/tests/aktienpraemiendividende.json +++ /dev/null @@ -1,134 +0,0 @@ -{ - "id": "07005e09-2961-36af-a804-b56697756c08", - "timestamp": "2025-09-22T11:20:31.704+0000", - "title": "Glencore", - "icon": "logos/JE00B4T3BW64/v2", - "avatar": { - "asset": "logos/JE00B4T3BW64/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aktienprämiendividende", - "amount": { - "currency": "EUR", - "value": 3.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "07005e09-2961-36af-a804-b56697756c08" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "07005e09-2961-36af-a804-b56697756c08", - "sections": [ - { - "title": "Du hast 3,00 € erhalten", - "data": { - "icon": "logos/JE00B4T3BW64/v2", - "timestamp": "2025-09-22T11:20:31.704Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aktienprämiendividende", - "displayValue": { - "text": "Aktienprämiendividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Glencore", - "displayValue": { - "text": "Glencore" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "4,15 €", - "displayValue": { - "text": "4,15 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-1,15 €", - "displayValue": { - "text": "-1,15 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3,00 €", - "displayValue": { - "text": "3,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "22.09.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "af94328e-5e5f-4409-8aa3-da2834f5d486", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktienpraemiendividende_no_eventType.json b/tests/aktienpraemiendividende_no_eventType.json deleted file mode 100644 index 06063151..00000000 --- a/tests/aktienpraemiendividende_no_eventType.json +++ /dev/null @@ -1,133 +0,0 @@ -{ - "id": "07005e09-2961-36af-a804-b56697756c08", - "timestamp": "2025-09-22T11:20:31.704+0000", - "title": "Glencore", - "icon": "logos/JE00B4T3BW64/v2", - "avatar": { - "asset": "logos/JE00B4T3BW64/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aktienprämiendividende", - "amount": { - "currency": "EUR", - "value": 3.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "07005e09-2961-36af-a804-b56697756c08" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "07005e09-2961-36af-a804-b56697756c08", - "sections": [ - { - "title": "Du hast 3,00 € erhalten", - "data": { - "icon": "logos/JE00B4T3BW64/v2", - "timestamp": "2025-09-22T11:20:31.704Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aktienprämiendividende", - "displayValue": { - "text": "Aktienprämiendividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Glencore", - "displayValue": { - "text": "Glencore" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "4,15 €", - "displayValue": { - "text": "4,15 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-1,15 €", - "displayValue": { - "text": "-1,15 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3,00 €", - "displayValue": { - "text": "3,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "22.09.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "af94328e-5e5f-4409-8aa3-da2834f5d486", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/aktiensplit.json b/tests/aktiensplit.json deleted file mode 100644 index aaba1610..00000000 --- a/tests/aktiensplit.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "e230be28-286a-31b6-879f-5c97f8a9d85a", - "timestamp": "2024-06-26T08:06:40.347+0000", - "title": "Chipotle Mexican Grill", - "icon": "logos/US1696561059/v2", - "subtitle": "Aktiensplit", - "action": { - "type": "timelineDetail", - "payload": "e230be28-286a-31b6-879f-5c97f8a9d85a" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "e230be28-286a-31b6-879f-5c97f8a9d85a", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/US1696561059/v2", - "timestamp": "2024-06-26T08:06:40.347Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Aktiensplit", - "displayValue": { - "text": "Aktiensplit" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Chipotle", - "displayValue": { - "text": "Chipotle" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "49.000000", - "displayValue": { - "text": "49.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "26.06.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "327ea786-399b-406b-988a-0f47e7c68f38", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} \ No newline at end of file diff --git a/tests/aktiensplit_no_eventType.json b/tests/aktiensplit_no_eventType.json deleted file mode 100644 index 6cf846d8..00000000 --- a/tests/aktiensplit_no_eventType.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "f122c692-98cf-3acc-b86b-9eff6b9d9980", - "timestamp": "2025-11-17T06:07:56.460+0000", - "title": "Netflix", - "icon": "logos/US64110L1061/v2", - "subtitle": "Aktiensplit", - "action": { - "type": "timelineDetail", - "payload": "f122c692-98cf-3acc-b86b-9eff6b9d9980" - }, - "source": "timelineActivity", - "details": { - "id": "f122c692-98cf-3acc-b86b-9eff6b9d9980", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/US64110L1061/v2", - "timestamp": "2025-11-17T06:07:56.46Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Aktiensplit", - "displayValue": { - "text": "Aktiensplit" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Netflix", - "displayValue": { - "text": "Netflix" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "2.743902", - "displayValue": { - "text": "2.743902" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "17.11.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "69e378d1-bade-4c76-9886-74cb4d669d00", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} \ No newline at end of file diff --git a/tests/all_events_test.json b/tests/all_events_test.json new file mode 100644 index 00000000..cd387528 --- /dev/null +++ b/tests/all_events_test.json @@ -0,0 +1,195 @@ +[ + { + "id": "12345678", + "timestamp": "2024-02-20T16:32:07.731+0000", + "title": "Euro Stoxx 50 EUR (Dist)", + "icon": "logos/IE00B4K6B022/v2", + "badge": null, + "subtitle": "Kauforder", + "amount": {"currency": "EUR", "value": -3002.8, "fractionDigits": 2}, + "status": "EXECUTED", + "action": {"type": "timelineDetail", "payload": "12345678"}, + "eventType": "ORDER_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 3.002,80 € investiert", + "data": {"icon": "logos/IE00B4K6B022/v2", "status": "executed"}, + "action": {"type": "instrumentDetail", "payload": "IE00B4K6B022"}, + "type": "header" + }, + { + "title": "Transaktion", + "data": [ + {"title": "Anteile", "detail": {"text": "60", "type": "text"}, "style": "plain"}, + {"title": "Aktienkurs", "detail": {"text": "50,03 €", "type": "text"}, "style": "plain"}, + {"title": "Gebühr", "detail": {"text": "1,00 €", "type": "text"}, "style": "plain"}, + {"title": "Gesamt", "detail": {"text": "3.002,80 €", "type": "text"}, "style": "highlighted"} + ], + "type": "table" + } + ] + } + }, + { + "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", + "timestamp": "2025-03-14T07:03:14.000+0000", + "title": "D-Wave Quantum", + "icon": "logos/US26740W1099/v2", + "subtitle": "Stop-Sell-Order", + "amount": {"currency": "EUR", "value": 94.76, "fractionDigits": 2}, + "status": "EXECUTED", + "action": {"type": "timelineDetail", "payload": "5b0f491f-7bad-40b1-8cd1-56d83729afd4"}, + "eventType": "trading_trade_executed", + "cashAccountNumber": "123456789", + "source": "timelineTransaction", + "details": { + "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", + "sections": [ + { + "title": "Du hast 94,76 € erhalten", + "data": {"icon": "logos/US26740W1099/v2", "status": "executed"}, + "action": {"payload": "US26740W1099", "type": "instrumentDetail"}, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + {"title": "Asset", "detail": {"text": "D-Wave Quantum", "type": "text"}, "style": "plain"}, + { + "title": "Transaktion", + "detail": { + "text": "17 × 5,82 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + {"title": "Transaktion", "type": "title"}, + { + "data": [ + {"title": "Aktien", "detail": {"text": "17", "type": "text"}, "style": "plain"}, + {"title": "Aktienkurs", "detail": {"text": "5,82 €", "type": "text"}, "style": "plain"}, + {"title": "Summe", "detail": {"text": "98,94 €", "type": "text"}, "style": "plain"} + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "type": "text" + }, + "style": "plain" + }, + {"title": "Steuer", "detail": {"text": "3,18 €", "type": "text"}, "style": "plain"}, + {"title": "Gebühr", "detail": {"text": "1,00 €", "type": "text"}, "style": "plain"}, + {"title": "Summe", "detail": {"text": "94,76 €", "type": "text"}, "style": "plain"} + ], + "type": "table" + } + ] + } + }, + { + "id": "88008da6-da94-3e0e-8ea5-e3878643f5ab", + "timestamp": "2025-10-23T14:19:56.295+0000", + "title": "Comcast (A)", + "icon": "logos/US20030N1019/v2", + "subtitle": "Bardividende", + "amount": {"currency": "EUR", "value": 2.24, "fractionDigits": 2}, + "status": "EXECUTED", + "action": {"type": "timelineDetail", "payload": "88008da6-da94-3e0e-8ea5-e3878643f5ab"}, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "source": "timelineTransaction", + "details": { + "id": "88008da6-da94-3e0e-8ea5-e3878643f5ab", + "sections": [ + { + "title": "Du hast 2,24 € erhalten", + "data": {"icon": "logos/US20030N1019/v2", "status": "executed"}, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + {"title": "Event", "detail": {"text": "Bardividende", "type": "text"}, "style": "plain"}, + {"title": "Wertpapier", "detail": {"text": "Comcast (A)", "type": "text"}, "style": "plain"} + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + {"title": "Aktien", "detail": {"text": "10.640298", "type": "text"}, "style": "plain"}, + {"title": "Steuer", "detail": {"text": "-0,78 €", "type": "text"}, "style": "plain"}, + {"title": "Gesamt", "detail": {"text": "2,24 €", "type": "text"}, "style": "plain"} + ], + "type": "table" + } + ] + } + }, + { + "id": "deposit-001", + "timestamp": "2024-06-03T17:07:26.374+0000", + "title": "My Name", + "icon": "logos/timeline_plus_circle/v2", + "subtitle": null, + "amount": {"currency": "EUR", "value": 200.0, "fractionDigits": 2}, + "status": "EXECUTED", + "action": {"type": "timelineDetail", "payload": "deposit-001"}, + "eventType": "timeline_legacy_migrated_events", + "cashAccountNumber": null, + "source": "timelineTransaction", + "details": { + "id": "deposit-001", + "sections": [ + { + "title": "Du hast 200,00 € erhalten", + "data": {"icon": "logos/timeline_plus_circle/v2", "status": "executed"}, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + {"title": "Von", "detail": {"text": "My Name", "type": "text"}, "style": "plain"}, + {"title": "IBAN", "detail": {"text": "...", "type": "text"}, "style": "plain"} + ], + "type": "table" + } + ] + } + }, + { + "id": "e230be28-286a-31b6-879f-5c97f8a9d85a", + "timestamp": "2024-06-26T08:06:40.347+0000", + "title": "Chipotle Mexican Grill", + "icon": "logos/US1696561059/v2", + "subtitle": "Aktiensplit", + "action": {"type": "timelineDetail", "payload": "e230be28-286a-31b6-879f-5c97f8a9d85a"}, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "e230be28-286a-31b6-879f-5c97f8a9d85a", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten", + "data": {"icon": "logos/US1696561059/v2", "status": "executed"}, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + {"title": "Orderart", "detail": {"text": "Aktiensplit", "type": "text"}, "style": "plain"}, + {"title": "Wertpapier", "detail": {"text": "Chipotle", "type": "text"}, "style": "plain"}, + {"title": "Aktien hinzugefügt", "detail": {"text": "49.000000", "type": "text"}, "style": "plain"} + ], + "type": "table" + } + ] + } + } +] diff --git a/tests/all_events_test_golden.csv b/tests/all_events_test_golden.csv new file mode 100644 index 00000000..735a54c7 --- /dev/null +++ b/tests/all_events_test_golden.csv @@ -0,0 +1,6 @@ +Datum;Typ;Wert;Notiz;ISIN;Stück;Gebühren;Steuern;ISIN2;Stück2 +2024-02-20T16:32:07;Kauf;-3.002,8;Euro Stoxx 50 EUR (Dist);IE00B4K6B022;60;1;;; +2024-06-03T17:07:26;Einlage;200;My Name;;;;;; +2024-06-26T08:06:40;Split;0;Chipotle Mexican Grill;US1696561059;49;;;; +2025-03-14T07:03:14;Verkauf;94,76;D-Wave Quantum;US26740W1099;17;1;3,18;; +2025-10-23T14:19:56;Dividende;2,24;Comcast (A);US20030N1019;10,640298;;0,78;; diff --git a/tests/bardividende.json b/tests/bardividende.json deleted file mode 100644 index 9922874e..00000000 --- a/tests/bardividende.json +++ /dev/null @@ -1,145 +0,0 @@ -{ - "id": "88008da6-da94-3e0e-8ea5-e3878643f5ab", - "timestamp": "2025-10-23T14:19:56.295+0000", - "title": "Comcast (A)", - "icon": "logos/US20030N1019/v2", - "avatar": { - "asset": "logos/US20030N1019/v2", - "badge": null - }, - "badge": null, - "subtitle": "Bardividende", - "amount": { - "currency": "EUR", - "value": 2.24, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "88008da6-da94-3e0e-8ea5-e3878643f5ab" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "88008da6-da94-3e0e-8ea5-e3878643f5ab", - "sections": [ - { - "title": "Du hast 2,24 € erhalten", - "data": { - "icon": "logos/US20030N1019/v2", - "timestamp": "2025-10-23T14:19:56.295Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Bardividende", - "displayValue": { - "text": "Bardividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Comcast (A)", - "displayValue": { - "text": "Comcast (A)" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Aktien", - "detail": { - "text": "10.640298", - "displayValue": { - "text": "10.640298" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende pro Aktie", - "detail": { - "text": "0,33 $", - "displayValue": { - "text": "0,33 $" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-0,78 €", - "displayValue": { - "text": "-0,78 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "2,24 €", - "displayValue": { - "text": "2,24 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "23.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "974b4871-2481-4751-b183-c36c2f960e4a", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bardividende_korrigiert.json b/tests/bardividende_korrigiert.json deleted file mode 100644 index 499afa91..00000000 --- a/tests/bardividende_korrigiert.json +++ /dev/null @@ -1,145 +0,0 @@ -{ - "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", - "timestamp": "2025-03-20T15:04:31.460+0000", - "title": "Medical Properties Trust", - "icon": "logos/US58463J3041/v2", - "avatar": { - "asset": "logos/US58463J3041/v2", - "badge": null - }, - "badge": null, - "subtitle": "Bardividende korrigiert", - "amount": { - "currency": "EUR", - "value": 4.01, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "da13151b-c8c3-3c4e-a613-24b28d5b16ac" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "1234567", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", - "sections": [ - { - "title": "Du hast 4,01 € erhalten", - "data": { - "icon": "logos/US58463J3041/v2", - "timestamp": "2025-03-20T15:04:31.46Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Bardividende korrigiert", - "displayValue": { - "text": "Bardividende korrigiert" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Medical Properties Trust", - "displayValue": { - "text": "Medical Properties Trust" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Aktien", - "detail": { - "text": "40.000000", - "displayValue": { - "text": "40.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende pro Aktie", - "detail": { - "text": "0,15 $", - "displayValue": { - "text": "0,15 $" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-1,53 €", - "displayValue": { - "text": "-1,53 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "4,01 €", - "displayValue": { - "text": "4,01 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "20.03.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4b1c122a-a6e2-48aa-a9d2-900f47668de8", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bardividende_korrigiert_no_eventType.json b/tests/bardividende_korrigiert_no_eventType.json deleted file mode 100644 index 94c9ceb6..00000000 --- a/tests/bardividende_korrigiert_no_eventType.json +++ /dev/null @@ -1,144 +0,0 @@ -{ - "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", - "timestamp": "2025-03-20T15:04:31.460+0000", - "title": "Medical Properties Trust", - "icon": "logos/US58463J3041/v2", - "avatar": { - "asset": "logos/US58463J3041/v2", - "badge": null - }, - "badge": null, - "subtitle": "Bardividende korrigiert", - "amount": { - "currency": "EUR", - "value": 4.01, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "da13151b-c8c3-3c4e-a613-24b28d5b16ac" - }, - "cashAccountNumber": "1234567", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", - "sections": [ - { - "title": "Du hast 4,01 € erhalten", - "data": { - "icon": "logos/US58463J3041/v2", - "timestamp": "2025-03-20T15:04:31.46Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Bardividende korrigiert", - "displayValue": { - "text": "Bardividende korrigiert" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Medical Properties Trust", - "displayValue": { - "text": "Medical Properties Trust" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Aktien", - "detail": { - "text": "40.000000", - "displayValue": { - "text": "40.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende pro Aktie", - "detail": { - "text": "0,15 $", - "displayValue": { - "text": "0,15 $" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-1,53 €", - "displayValue": { - "text": "-1,53 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "4,01 €", - "displayValue": { - "text": "4,01 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "20.03.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4b1c122a-a6e2-48aa-a9d2-900f47668de8", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bardividende_no_eventType.json b/tests/bardividende_no_eventType.json deleted file mode 100644 index 8be64ac9..00000000 --- a/tests/bardividende_no_eventType.json +++ /dev/null @@ -1,169 +0,0 @@ -{ - "id": "de17e7cb-49cd-322f-8345-1b265dc9730d", - "timestamp": "2025-11-05T18:31:19.339+0000", - "title": "Lowe's", - "icon": "logos/US5486611073/v2", - "avatar": { - "asset": "logos/US5486611073/v2", - "badge": null - }, - "badge": null, - "subtitle": "Bardividende", - "amount": { - "currency": "EUR", - "value": 0.92, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "de17e7cb-49cd-322f-8345-1b265dc9730d" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "de17e7cb-49cd-322f-8345-1b265dc9730d", - "sections": [ - { - "title": "Du hast 0,92\u00a0\u20ac erhalten", - "data": { - "icon": "logos/US5486611073/v2", - "timestamp": "2025-11-05T18:31:19.339Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgef\u00fchrt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Bardividende", - "displayValue": { - "text": "Bardividende" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Lowe's", - "displayValue": { - "text": "Lowe's" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Gesch\u00e4ft", - "data": [ - { - "title": "Aktien", - "detail": { - "text": "1.189904", - "displayValue": { - "text": "1.189904" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende pro Aktie", - "detail": { - "text": "1,20\u00a0$", - "displayValue": { - "text": "1,20\u00a0$" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-0,32\u00a0\u20ac", - "displayValue": { - "text": "-0,32\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "0,92\u00a0\u20ac", - "displayValue": { - "text": "0,92\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "05.11.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "36b29c55-5bef-44c3-b50c-7541403a9414", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "common_empty_string", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "timelineEventId": "de17e7cb-49cd-322f-8345-1b265dc9730d", - "chat_flow_key": "NHC_0029_wealth_general_question_dividends" - } - }, - "type": "customerSupportChat" - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "highlighted" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/benefits_spare_change_execution.json b/tests/benefits_spare_change_execution.json deleted file mode 100644 index dc87da73..00000000 --- a/tests/benefits_spare_change_execution.json +++ /dev/null @@ -1,139 +0,0 @@ -{ - "id": "5b516589-a0b6-46fb-80e1-2506bef82542", - "timestamp": "2024-10-02T15:05:40.970+0000", - "title": "SuperDividend USD (Dist)", - "icon": "logos/IE00077FRP95/v2", - "avatar": { - "asset": "logos/IE00077FRP95/v2", - "badge": null - }, - "badge": null, - "subtitle": "Round up", - "amount": { - "currency": "EUR", - "value": -3.38, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "5b516589-a0b6-46fb-80e1-2506bef82542" - }, - "eventType": "benefits_spare_change_execution", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "5b516589-a0b6-46fb-80e1-2506bef82542", - "sections": [ - { - "title": "Du hast 3,38 € investiert", - "data": { - "icon": "logos/IE00077FRP95/v2", - "timestamp": "2024-10-02T15:05:40.970073Z", - "status": "executed" - }, - "action": { - "payload": "IE00077FRP95", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Round up", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "SuperDividend USD (Dist)", - "displayValue": { - "text": "SuperDividend USD (Dist)" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0.383219 x 8,82 €", - "displayValue": { - "text": "8,82 €", - "prefix": "0.383219 x " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "Kostenlos", - "displayValue": { - "text": "Kostenlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3,38 €", - "displayValue": { - "text": "3,38 €" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung Ausführung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "42368c8d-a698-4682-80dd-8ca0f0b25fea", - "postboxType": "SAVINGS_PLAN_EXECUTED_V2" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "044294ae-0534-45e3-a0ff-14d212e1c48f", - "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" - }, - { - "title": "Deaktivierung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "f21430be-32c6-4fa6-9512-7210d07f41fe", - "postboxType": "BENEFIT_DEACTIVATED" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/benefits_spare_change_execution_no_eventType.json b/tests/benefits_spare_change_execution_no_eventType.json deleted file mode 100644 index b23b6955..00000000 --- a/tests/benefits_spare_change_execution_no_eventType.json +++ /dev/null @@ -1,138 +0,0 @@ -{ - "id": "5b516589-a0b6-46fb-80e1-2506bef82542", - "timestamp": "2024-10-02T15:05:40.970+0000", - "title": "SuperDividend USD (Dist)", - "icon": "logos/IE00077FRP95/v2", - "avatar": { - "asset": "logos/IE00077FRP95/v2", - "badge": null - }, - "badge": null, - "subtitle": "Round up", - "amount": { - "currency": "EUR", - "value": -3.38, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "5b516589-a0b6-46fb-80e1-2506bef82542" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "5b516589-a0b6-46fb-80e1-2506bef82542", - "sections": [ - { - "title": "Du hast 3,38 € investiert", - "data": { - "icon": "logos/IE00077FRP95/v2", - "timestamp": "2024-10-02T15:05:40.970073Z", - "status": "executed" - }, - "action": { - "payload": "IE00077FRP95", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Round up", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "SuperDividend USD (Dist)", - "displayValue": { - "text": "SuperDividend USD (Dist)" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0.383219 x 8,82 €", - "displayValue": { - "text": "8,82 €", - "prefix": "0.383219 x " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "Kostenlos", - "displayValue": { - "text": "Kostenlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3,38 €", - "displayValue": { - "text": "3,38 €" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung Ausführung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "42368c8d-a698-4682-80dd-8ca0f0b25fea", - "postboxType": "SAVINGS_PLAN_EXECUTED_V2" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "044294ae-0534-45e3-a0ff-14d212e1c48f", - "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" - }, - { - "title": "Deaktivierung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "f21430be-32c6-4fa6-9512-7210d07f41fe", - "postboxType": "BENEFIT_DEACTIVATED" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bond_kauf.json b/tests/bond_kauf.json deleted file mode 100644 index 72856ad1..00000000 --- a/tests/bond_kauf.json +++ /dev/null @@ -1,242 +0,0 @@ - { - "id": "6c7755f0-0943-422b-b9ba-bfd9c105584a", - "timestamp": "2025-07-18T08:04:42.708+0000", - "title": "Juli 2040", - "icon": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "avatar": { - "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -100.99, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "6c7755f0-0943-422b-b9ba-bfd9c105584a" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "eventType": "TRADING_TRADE_EXECUTED", - "source": "timelineTransaction", - "details": { - "id": "6c7755f0-0943-422b-b9ba-bfd9c105584a", - "sections": [ - { - "title": "Du hast 100,99 € investiert", - "data": { - "icon": { - "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "badge": null - }, - "timestamp": "2025-07-18T08:04:42.70813202Z", - "status": "executed" - }, - "action": { - "payload": "DE0001135366", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Juli 2040", - "displayValue": { - "text": "Juli 2040" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "99,80 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Nennwert", - "detail": { - "text": "82,00 €", - "displayValue": { - "text": "82,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Quotation", - "detail": { - "text": "121,31 %", - "displayValue": { - "text": "121,31 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Stückzinsen", - "detail": { - "text": "0,19 €", - "displayValue": { - "text": "0,19 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "100,99 €", - "displayValue": { - "text": "100,99 €" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - } - ] - }, - "displayMode": "bottomSheet", - "type": "infoPage" - }, - "displayValue": { - "text": "99,80 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "100,99 €", - "displayValue": { - "text": "100,99 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "0,19 %", - "trend": "negative", - "displayValue": { - "text": "0,19 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verlust", - "detail": { - "text": "-0,19 €", - "trend": "negative", - "displayValue": { - "text": "-0,19 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation 1", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "705597e0-f359-4f1e-bd46-ed128d12d620", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Kosteninformation 2", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "ca3d15ea-d560-4bc8-85a8-73dd81ef7579", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Abrechnung 1", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "e337f3cc-2cc4-446b-99ce-7ab1b41f66a9", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Abrechnung 2", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "1ef2976f-118e-4c79-8cb0-3da858fb291d", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} \ No newline at end of file diff --git a/tests/bond_verkauf.json b/tests/bond_verkauf.json deleted file mode 100644 index 1e1edd7e..00000000 --- a/tests/bond_verkauf.json +++ /dev/null @@ -1,323 +0,0 @@ - { - "id": "e45b8873-16ce-440d-ae96-a4586cfdf9ca", - "timestamp": "2026-03-26T06:48:09.708+0000", - "title": "Juli 2040", - "icon": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "avatar": { - "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "badge": null - }, - "badge": null, - "subtitle": "Verkaufsorder", - "amount": { - "currency": "EUR", - "value": 98.21, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "e45b8873-16ce-440d-ae96-a4586cfdf9ca" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "eventType": "TRADING_TRADE_EXECUTED", - "source": "timelineTransaction", - "details": { - "id": "e45b8873-16ce-440d-ae96-a4586cfdf9ca", - "sections": [ - { - "title": "Du hast 98,21 € erhalten", - "data": { - "icon": { - "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "badge": null - }, - "timestamp": "2026-03-26T06:48:09.708126976Z", - "status": "executed" - }, - "action": { - "payload": "DE0001135366", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Verkaufen", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Juli 2040", - "displayValue": { - "text": "Juli 2040" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "96,33 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Nennwert", - "detail": { - "text": "0,27 €", - "displayValue": { - "text": "0,27 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Quotation", - "detail": { - "text": "117,09 %", - "displayValue": { - "text": "117,09 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Stückzinsen", - "detail": { - "text": "+ 2,88 €", - "displayValue": { - "text": "+ 2,88 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "+ 98,21 €", - "displayValue": { - "text": "+ 98,21 €" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - } - ] - }, - "displayMode": "bottomSheet", - "type": "infoPage" - }, - "displayValue": { - "text": "96,33 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,00 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Gezahlte Steuern 0,00 €", - "data": { - "icon": { - "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", - "badge": null - }, - "timestamp": "2026-03-26T06:48:09.708126976Z", - "status": "executed" - }, - "action": { - "payload": "DE0001135366", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Steuerbemessungsgrundlage", - "data": [ - { - "title": "Bruttogewinn", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Steuern", - "data": [ - { - "title": "Summe", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - } - ] - }, - "displayMode": "modal", - "type": "infoPage" - }, - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "98,21 €", - "displayValue": { - "text": "98,21 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "2,65 %", - "trend": "negative", - "displayValue": { - "text": "2,65 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verlust", - "detail": { - "text": "-2,59 €", - "trend": "negative", - "displayValue": { - "text": "-2,59 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung 1", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "3713df09-15f0-49ac-859b-da60279ffdb9", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Abrechnung 2", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "e71c5516-f6dc-495b-9666-b54b6e618cf4", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation 1", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "15ae9c44-e002-495e-9c21-93e07ede2a64", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Kosteninformation 2", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "d616495a-e777-4e72-877d-4663b9b52cbf", - "postboxType": "EQUITIES_SELL_EX_ANTE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bonusaktien.json b/tests/bonusaktien.json deleted file mode 100644 index 3170c715..00000000 --- a/tests/bonusaktien.json +++ /dev/null @@ -1,101 +0,0 @@ -{ - "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", - "timestamp": "2025-08-15T08:10:12.583+0000", - "title": "Eckert & Ziegler", - "icon": "logos/DE0005659700/v2", - "subtitle": "Bonusaktien", - "action": { - "type": "timelineDetail", - "payload": "9af345e0-248d-36ed-bc76-6fb96033ba1d" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/DE0005659700/v2", - "timestamp": "2025-08-15T08:10:12.583Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Bonusaktien", - "displayValue": { - "text": "Bonusaktien" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Eckert & Ziegler", - "displayValue": { - "text": "Eckert & Ziegler" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "5.706536", - "displayValue": { - "text": "5.706536" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "18.08.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "ac5a0f89-1766-4c95-b056-498be4ed550b", - "postboxType": "CA_SECURITIES_INVOICE" - }, - { - "title": "Dokumente", - "detail": "15.08.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "dc687f7d-5fa0-48b4-ba37-35b7d06df261", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bonusaktien2.json b/tests/bonusaktien2.json deleted file mode 100644 index 5298468a..00000000 --- a/tests/bonusaktien2.json +++ /dev/null @@ -1,134 +0,0 @@ -{ - "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", - "timestamp": "2025-08-15T14:53:09.730+0000", - "title": "BYD", - "icon": "logos/CNE100000296/v2", - "avatar": { - "asset": "logos/CNE100000296/v2", - "badge": null - }, - "badge": null, - "subtitle": "Bonusaktien", - "amount": { - "currency": "EUR", - "value": -8.67, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "e8aa0763-c7ac-3cbe-b72c-762fa4489450" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "0674716511", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", - "sections": [ - { - "title": "Du hast -8,67 € bezahlt", - "data": { - "icon": "logos/CNE100000296/v2", - "timestamp": "2025-08-15T14:53:09.73Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Bonusaktien", - "displayValue": { - "text": "Bonusaktien" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "BYD", - "displayValue": { - "text": "BYD" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-8,67 €", - "displayValue": { - "text": "-8,67 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-8,67 €", - "displayValue": { - "text": "-8,67 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "15.08.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "28f2dde3-c3f0-4c34-8c5d-f7ab968d3983", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bonusaktien2_no_eventType.json b/tests/bonusaktien2_no_eventType.json deleted file mode 100644 index 94cf79b7..00000000 --- a/tests/bonusaktien2_no_eventType.json +++ /dev/null @@ -1,133 +0,0 @@ -{ - "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", - "timestamp": "2025-08-15T14:53:09.730+0000", - "title": "BYD", - "icon": "logos/CNE100000296/v2", - "avatar": { - "asset": "logos/CNE100000296/v2", - "badge": null - }, - "badge": null, - "subtitle": "Bonusaktien", - "amount": { - "currency": "EUR", - "value": -8.67, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "e8aa0763-c7ac-3cbe-b72c-762fa4489450" - }, - "cashAccountNumber": "0674716511", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", - "sections": [ - { - "title": "Du hast -8,67 € bezahlt", - "data": { - "icon": "logos/CNE100000296/v2", - "timestamp": "2025-08-15T14:53:09.73Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Bonusaktien", - "displayValue": { - "text": "Bonusaktien" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "BYD", - "displayValue": { - "text": "BYD" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-8,67 €", - "displayValue": { - "text": "-8,67 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-8,67 €", - "displayValue": { - "text": "-8,67 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "15.08.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "28f2dde3-c3f0-4c34-8c5d-f7ab968d3983", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/bonusaktien_no_eventType.json b/tests/bonusaktien_no_eventType.json deleted file mode 100644 index a9b6a170..00000000 --- a/tests/bonusaktien_no_eventType.json +++ /dev/null @@ -1,100 +0,0 @@ -{ - "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", - "timestamp": "2025-08-15T08:10:12.583+0000", - "title": "Eckert & Ziegler", - "icon": "logos/DE0005659700/v2", - "subtitle": "Bonusaktien", - "action": { - "type": "timelineDetail", - "payload": "9af345e0-248d-36ed-bc76-6fb96033ba1d" - }, - "source": "timelineActivity", - "details": { - "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/DE0005659700/v2", - "timestamp": "2025-08-15T08:10:12.583Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Bonusaktien", - "displayValue": { - "text": "Bonusaktien" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Eckert & Ziegler", - "displayValue": { - "text": "Eckert & Ziegler" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "5.706536", - "displayValue": { - "text": "5.706536" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "18.08.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "ac5a0f89-1766-4c95-b056-498be4ed550b", - "postboxType": "CA_SECURITIES_INVOICE" - }, - { - "title": "Dokumente", - "detail": "15.08.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "dc687f7d-5fa0-48b4-ba37-35b7d06df261", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/buy.json b/tests/buy.json deleted file mode 100644 index ca450c0b..00000000 --- a/tests/buy.json +++ /dev/null @@ -1,163 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2024-02-20T16:32:07.731+0000", - "title": "Euro Stoxx 50 EUR (Dist)", - "icon": "logos/IE00B4K6B022/v2", - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -3002.8, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "eventType": "ORDER_EXECUTED", - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 3.002,80 € investiert", - "data": { - "icon": "logos/IE00B4K6B022/v2", - "subtitleText": null, - "timestamp": "2024-02-20T16:32:07.731+0000", - "status": "executed" - }, - "action": { - "type": "instrumentDetail", - "payload": "IE00B4K6B022" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Kauf", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Euro Stoxx 50 EUR (Dist)", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Anteile", - "detail": { - "text": "60", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "50,03 €", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3.002,80 €", - "trend": null, - "action": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": "20.02.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "", - "postboxType": "SECURITIES_SETTLEMENT", - "local filepath": "" - }, - { - "title": "Basisinformationsblatt", - "detail": "20.02.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "12345678", - "postboxType": "INFO", - "local filepath": "" - }, - { - "title": "Kosteninformation", - "detail": "20.02.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "12345678", - "postboxType": "COSTS_INFO_BUY_V2", - "local filepath": "" - } - ], - "action": null, - "type": "documents" - } - ] - } - } diff --git a/tests/buy_new.json b/tests/buy_new.json deleted file mode 100644 index 43f48bc6..00000000 --- a/tests/buy_new.json +++ /dev/null @@ -1,191 +0,0 @@ -{ - "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", - "timestamp": "2025-10-10T19:29:43.928+0000", - "title": "NVIDIA", - "icon": "logos/US67066G1040/v2", - "avatar": { - "asset": "logos/US67066G1040/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -111.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "63c6df01-c99b-4bda-aec0-c8f996fbaae1" - }, - "eventType": "trading_trade_executed", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", - "sections": [ - { - "title": "Du hast 111,00 € investiert", - "data": { - "icon": "logos/US67066G1040/v2", - "timestamp": "2025-10-10T19:29:43.928252Z", - "status": "executed" - }, - "action": { - "payload": "US67066G1040", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Kauf", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "NVIDIA", - "displayValue": { - "text": "NVIDIA" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0,685102 × 160,56 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "0,685102", - "displayValue": { - "text": "0,685102" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "160,56 €", - "displayValue": { - "text": "160,56 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "110,00 €", - "displayValue": { - "text": "110,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "160,56 €", - "prefix": "0,685102 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "111,00 €", - "displayValue": { - "text": "111,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "085e4556-22b9-4af6-977b-f34fb90d1dee", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "2ea881b8-e8e7-4d4d-8df9-07d2d9cab6a8", - "postboxType": "EQUITIES_BUY_EX_ANTE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/buy_new2.json b/tests/buy_new2.json deleted file mode 100644 index d6e0bdf6..00000000 --- a/tests/buy_new2.json +++ /dev/null @@ -1,199 +0,0 @@ -{ - "id": "471bf3aa-541e-42b5-a600-c5180b139806", - "timestamp": "2025-08-01T08:28:01.425+0000", - "title": "Rocket Lab Corp. Registered Shares DL-,0001", - "icon": "logos/US7731211089/v2", - "avatar": { - "asset": "logos/US7731211089/v2", - "badge": null - }, - "badge": null, - "subtitle": "Limit-Buy-Order", - "amount": { - "currency": "EUR", - "value": -75.6, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "471bf3aa-541e-42b5-a600-c5180b139806" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "471bf3aa-541e-42b5-a600-c5180b139806", - "sections": [ - { - "title": "Du hast 75,60 € investiert", - "data": { - "icon": "logos/US7731211089/v2", - "timestamp": "2025-08-01T08:28:01.425Z", - "status": "executed" - }, - "action": { - "payload": "US7731211089", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Limit Order", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Rocket Lab Corp. Registered Shares DL-,0001", - "displayValue": { - "text": "Rocket Lab Corp. Registered Shares DL-,0001" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "2 × 37,30 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "2", - "displayValue": { - "text": "2" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "37,30 €", - "displayValue": { - "text": "37,30 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "74,60 €", - "displayValue": { - "text": "74,60 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "37,30 €", - "prefix": "2 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "75,60 €", - "displayValue": { - "text": "75,60 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "2b2f5b5e-d6c9-4f87-ab7b-fafe426b2c84", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Auftragsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "77927fdb-67f9-40fa-908b-32dea64fcf2f", - "postboxType": "ORDER_CONFIRMATION" - }, - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "42bd93b1-8f48-489f-b1e3-6eb955191d62", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/buy_new2_no_eventType.json b/tests/buy_new2_no_eventType.json deleted file mode 100644 index d6d7d75d..00000000 --- a/tests/buy_new2_no_eventType.json +++ /dev/null @@ -1,200 +0,0 @@ -{ - "id": "471bf3aa-541e-42b5-a600-c5180b139806", - "timestamp": "2025-08-01T08:28:01.425+0000", - "title": "Rocket Lab Corp. Registered Shares DL-,0001", - "icon": "logos/US7731211089/v2", - "avatar": { - "asset": "logos/US7731211089/v2", - "badge": null - }, - "badge": null, - "subtitle": "Limit-Buy-Order", - "amount": { - "currency": "EUR", - "value": -75.6, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "471bf3aa-541e-42b5-a600-c5180b139806" - }, - "eventType": "trading_trade_executed", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "471bf3aa-541e-42b5-a600-c5180b139806", - "sections": [ - { - "title": "Du hast 75,60 € investiert", - "data": { - "icon": "logos/US7731211089/v2", - "timestamp": "2025-08-01T08:28:01.425Z", - "status": "executed" - }, - "action": { - "payload": "US7731211089", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Limit Order", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Rocket Lab Corp. Registered Shares DL-,0001", - "displayValue": { - "text": "Rocket Lab Corp. Registered Shares DL-,0001" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "2 × 37,30 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "2", - "displayValue": { - "text": "2" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "37,30 €", - "displayValue": { - "text": "37,30 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "74,60 €", - "displayValue": { - "text": "74,60 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "37,30 €", - "prefix": "2 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "75,60 €", - "displayValue": { - "text": "75,60 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "2b2f5b5e-d6c9-4f87-ab7b-fafe426b2c84", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Auftragsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "77927fdb-67f9-40fa-908b-32dea64fcf2f", - "postboxType": "ORDER_CONFIRMATION" - }, - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "42bd93b1-8f48-489f-b1e3-6eb955191d62", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/buy_new_no_eventType.json b/tests/buy_new_no_eventType.json deleted file mode 100644 index 23f17653..00000000 --- a/tests/buy_new_no_eventType.json +++ /dev/null @@ -1,190 +0,0 @@ -{ - "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", - "timestamp": "2025-10-10T19:29:43.928+0000", - "title": "NVIDIA", - "icon": "logos/US67066G1040/v2", - "avatar": { - "asset": "logos/US67066G1040/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -111.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "63c6df01-c99b-4bda-aec0-c8f996fbaae1" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", - "sections": [ - { - "title": "Du hast 111,00 € investiert", - "data": { - "icon": "logos/US67066G1040/v2", - "timestamp": "2025-10-10T19:29:43.928252Z", - "status": "executed" - }, - "action": { - "payload": "US67066G1040", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Kauf", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "NVIDIA", - "displayValue": { - "text": "NVIDIA" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0,685102 × 160,56 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "0,685102", - "displayValue": { - "text": "0,685102" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "160,56 €", - "displayValue": { - "text": "160,56 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "110,00 €", - "displayValue": { - "text": "110,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "160,56 €", - "prefix": "0,685102 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "111,00 €", - "displayValue": { - "text": "111,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "085e4556-22b9-4af6-977b-f34fb90d1dee", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "2ea881b8-e8e7-4d4d-8df9-07d2d9cab6a8", - "postboxType": "EQUITIES_BUY_EX_ANTE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/buy_no_eventType.json b/tests/buy_no_eventType.json deleted file mode 100644 index 36a2e5d4..00000000 --- a/tests/buy_no_eventType.json +++ /dev/null @@ -1,162 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2024-02-20T16:32:07.731+0000", - "title": "Euro Stoxx 50 EUR (Dist)", - "icon": "logos/IE00B4K6B022/v2", - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -3002.8, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 3.002,80 € investiert", - "data": { - "icon": "logos/IE00B4K6B022/v2", - "subtitleText": null, - "timestamp": "2024-02-20T16:32:07.731+0000", - "status": "executed" - }, - "action": { - "type": "instrumentDetail", - "payload": "IE00B4K6B022" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Kauf", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Euro Stoxx 50 EUR (Dist)", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Anteile", - "detail": { - "text": "60", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "50,03 €", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3.002,80 €", - "trend": null, - "action": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": "20.02.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "", - "postboxType": "SECURITIES_SETTLEMENT", - "local filepath": "" - }, - { - "title": "Basisinformationsblatt", - "detail": "20.02.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "12345678", - "postboxType": "INFO", - "local filepath": "" - }, - { - "title": "Kosteninformation", - "detail": "20.02.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "12345678", - "postboxType": "COSTS_INFO_BUY_V2", - "local filepath": "" - } - ], - "action": null, - "type": "documents" - } - ] - } - } diff --git a/tests/card_refund.json b/tests/card_refund.json deleted file mode 100644 index fce3dc15..00000000 --- a/tests/card_refund.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", - "timestamp": "2025-08-17T07:23:44.511+0000", - "title": "Decathlon", - "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", - "avatar": { - "asset": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 24.99, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535" - }, - "eventType": "card_refund", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", - "sections": [ - { - "title": "Du hast 24,99 € erhalten", - "data": { - "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", - "timestamp": "2025-08-17T07:23:44.511Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kartenerstattung", - "detail": { - "text": "Fertig", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "··5891", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Händler", - "detail": { - "text": "Decathlon", - "displayValue": { - "text": "Decathlon" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+24,99 €", - "displayValue": { - "text": "+24,99 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/card_refund_no_eventType.json b/tests/card_refund_no_eventType.json deleted file mode 100644 index d7450a18..00000000 --- a/tests/card_refund_no_eventType.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", - "timestamp": "2025-08-17T07:23:44.511+0000", - "title": "Decathlon", - "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", - "avatar": { - "asset": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 24.99, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", - "sections": [ - { - "title": "Du hast 24,99 € erhalten", - "data": { - "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", - "timestamp": "2025-08-17T07:23:44.511Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kartenerstattung", - "detail": { - "text": "Fertig", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "··5891", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Händler", - "detail": { - "text": "Decathlon", - "displayValue": { - "text": "Decathlon" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+24,99 €", - "displayValue": { - "text": "+24,99 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/deposit.json b/tests/deposit.json deleted file mode 100644 index 8ebe8401..00000000 --- a/tests/deposit.json +++ /dev/null @@ -1,107 +0,0 @@ -{ - "id": "...", - "timestamp": "2024-06-03T17:07:26.374+0000", - "title": "My Name", - "icon": "logos/timeline_plus_circle/v2", - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 200.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "..." - }, - "eventType": "timeline_legacy_migrated_events", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "...", - "sections": [ - { - "title": "Du hast 200,00 € erhalten", - "data": { - "icon": "logos/timeline_plus_circle/v2", - "subtitleText": null, - "timestamp": "2024-06-03T17:07:26.374+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Von", - "detail": { - "text": "My Name", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "...", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "type": "customerSupportChat", - "payload": { - "contextParams": { - "chat_flow_key": "NHC_0024_deposit_report_an_issue", - "timelineEventId": "...", - "createdAt": "2024-06-03T17:07:26.459880Z", - "amount": "200.000000", - "iban": "..." - }, - "contextCategory": "NHC" - } - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - } -} diff --git a/tests/deposit_no_eventType.json b/tests/deposit_no_eventType.json deleted file mode 100644 index d454a986..00000000 --- a/tests/deposit_no_eventType.json +++ /dev/null @@ -1,106 +0,0 @@ -{ - "id": "...", - "timestamp": "2024-06-03T17:07:26.374+0000", - "title": "My Name", - "icon": "logos/timeline_plus_circle/v2", - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 200.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "..." - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "...", - "sections": [ - { - "title": "Du hast 200,00 € erhalten", - "data": { - "icon": "logos/timeline_plus_circle/v2", - "subtitleText": null, - "timestamp": "2024-06-03T17:07:26.374+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Von", - "detail": { - "text": "My Name", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "...", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "type": "customerSupportChat", - "payload": { - "contextParams": { - "chat_flow_key": "NHC_0024_deposit_report_an_issue", - "timelineEventId": "...", - "createdAt": "2024-06-03T17:07:26.459880Z", - "amount": "200.000000", - "iban": "..." - }, - "contextCategory": "NHC" - } - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - } -} diff --git a/tests/dividende_old.json b/tests/dividende_old.json deleted file mode 100644 index b719d028..00000000 --- a/tests/dividende_old.json +++ /dev/null @@ -1,304 +0,0 @@ -{ - "id": "00000000-0000-0000-0000-000000000000", - "timestamp": "2024-12-31T23:59:59.999+0000", - "title": "MSCI World USD (Dist)", - "icon": "logos/LU0392494562/v2", - "avatar": { - "asset": "logos/LU0392494562/v2", - "badge": null - }, - "badge": null, - "subtitle": "Dividende", - "amount": { - "currency": "EUR", - "value": 30.21, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "00000000-0000-0000-0000-000000000000" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Du hast 30,21 € erhalten", - "data": { - "icon": "logos/LU0392494562/v2", - "subtitleText": null, - "timestamp": "2024-12-31T23:59:59.999+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Ereignis", - "detail": { - "text": "Ausschüttung", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "MSCI World USD (Dist)", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Anteile", - "detail": { - "text": "32", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende je Aktie", - "detail": { - "text": "1,16 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "6,83 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 30,21 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": { - "type": "infoPage", - "payload": { - "sections": [ - { - "title": "Transaktion", - "action": null, - "type": "title" - }, - { - "title": null, - "data": [ - { - "title": "Anteile", - "detail": { - "text": "32", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende je Aktie", - "detail": { - "text": "1,18 $", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wechselkurs", - "detail": { - "text": "1 € to 1,01932 $", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividende je Aktie", - "detail": { - "text": "1,16 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Dividendenzahlung", - "detail": { - "text": "+ 37,04 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": null, - "data": [ - { - "title": "Kapitalertragsteuer", - "detail": { - "text": "6,48 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Solidaritätszuschlag", - "detail": { - "text": "0,35 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "6,83 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": null, - "data": [ - { - "title": "Dividendenzahlung", - "detail": { - "text": "+ 37,04 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "6,83 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "Gratis", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 30,21 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - } - ] - } - }, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": "31.12.2024", - "action": { - "type": "browserModal", - "payload": "dummy.pdf" - }, - "id": "00000000-0000-0000-0000-000000000000", - "postboxType": "INCOME" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/dividende_wahlweise.json b/tests/dividende_wahlweise.json deleted file mode 100644 index d86405c4..00000000 --- a/tests/dividende_wahlweise.json +++ /dev/null @@ -1,134 +0,0 @@ -{ - "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", - "timestamp": "2024-07-19T13:28:04.386+0000", - "title": "National Grid", - "icon": "logos/GB00BDR05C01/v2", - "avatar": { - "asset": "logos/GB00BDR05C01/v2", - "badge": null - }, - "badge": null, - "subtitle": "Dividende Wahlweise", - "amount": { - "currency": "EUR", - "value": 3.37, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "ba69948e-fd42-30d0-924f-f94241ee3fbc" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", - "sections": [ - { - "title": "Du hast 3,37 € erhalten", - "data": { - "icon": "logos/GB00BDR05C01/v2", - "timestamp": "2024-07-19T13:28:04.386Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Dividende Wahlweise", - "displayValue": { - "text": "Dividende Wahlweise" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "National Grid", - "displayValue": { - "text": "National Grid" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "4,65 €", - "displayValue": { - "text": "4,65 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-1,28 €", - "displayValue": { - "text": "-1,28 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3,37 €", - "displayValue": { - "text": "3,37 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "19.07.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "60f383fd-f2b0-4f2f-8639-ba41a4559926", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/dividende_wahlweise_no_eventType.json b/tests/dividende_wahlweise_no_eventType.json deleted file mode 100644 index 2e1fbe44..00000000 --- a/tests/dividende_wahlweise_no_eventType.json +++ /dev/null @@ -1,133 +0,0 @@ -{ - "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", - "timestamp": "2024-07-19T13:28:04.386+0000", - "title": "National Grid", - "icon": "logos/GB00BDR05C01/v2", - "avatar": { - "asset": "logos/GB00BDR05C01/v2", - "badge": null - }, - "badge": null, - "subtitle": "Dividende Wahlweise", - "amount": { - "currency": "EUR", - "value": 3.37, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "ba69948e-fd42-30d0-924f-f94241ee3fbc" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", - "sections": [ - { - "title": "Du hast 3,37 € erhalten", - "data": { - "icon": "logos/GB00BDR05C01/v2", - "timestamp": "2024-07-19T13:28:04.386Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Dividende Wahlweise", - "displayValue": { - "text": "Dividende Wahlweise" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "National Grid", - "displayValue": { - "text": "National Grid" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "4,65 €", - "displayValue": { - "text": "4,65 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-1,28 €", - "displayValue": { - "text": "-1,28 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "3,37 €", - "displayValue": { - "text": "3,37 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "19.07.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "60f383fd-f2b0-4f2f-8639-ba41a4559926", - "postboxType": "CA_INCOME_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/events/address_changed.json b/tests/events/address_changed.json new file mode 100644 index 00000000..69ea961a --- /dev/null +++ b/tests/events/address_changed.json @@ -0,0 +1,12 @@ +{ + "id": "059ce705-3c54-4019-b008-79946d835a37", + "timestamp": "2024-09-13T14:58:01.873+0000", + "title": "Adresse", + "icon": "logos/timeline_flag/v2", + "subtitle": "Geändert", + "action": null, + "eventType": "ADDRESS_CHANGED", + "hidden": false, + "deleted": false, + "source": "timelineActivity" +} diff --git a/tests/events/aktien_entfernt.json b/tests/events/aktien_entfernt.json new file mode 100644 index 00000000..cebc56a1 --- /dev/null +++ b/tests/events/aktien_entfernt.json @@ -0,0 +1,91 @@ +{ + "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", + "timestamp": "2025-10-28T15:46:46.286+0000", + "title": "ORSTED A/S -ANR-", + "icon": "logos/DK0064307839/v2", + "subtitle": "Wertlos", + "action": { + "type": "timelineDetail", + "payload": "c187c065-fadf-33bd-8de9-fe0ac6c0e686" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", + "sections": [ + { + "title": "Aktien wurden im Rahmen einer Kapitalmaßnahme entfernt", + "data": { + "icon": "logos/DK0064307839/v2", + "timestamp": "2025-10-28T15:46:46.286Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertlos", + "displayValue": { + "text": "Wertlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S -ANR-", + "displayValue": { + "text": "ORSTED A/S -ANR-" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "0.285835", + "displayValue": { + "text": "0.285835" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "28.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "9fdeded6-aa07-401a-ad47-740da1a4c41e", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktien_entfernt2.json b/tests/events/aktien_entfernt2.json new file mode 100644 index 00000000..2925c1fd --- /dev/null +++ b/tests/events/aktien_entfernt2.json @@ -0,0 +1,96 @@ +{ + "id": "6919f8d9-e168-321f-b276-8766ce50f319", + "timestamp": "2026-04-03T10:48:40.913+0000", + "title": "WORLDLINE S.A. ANR", + "icon": "logos/FR0014015MS9/v2", + "subtitle": "Wertlos", + "action": { + "type": "timelineDetail", + "payload": "6919f8d9-e168-321f-b276-8766ce50f319" + }, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "6919f8d9-e168-321f-b276-8766ce50f319", + "sections": [ + { + "title": "Aktien wurden im Rahmen einer Kapitalmaßnahme entfernt", + "data": { + "icon": { + "asset": "logos/FR0014015MS9/v2", + "badge": null + }, + "timestamp": "2026-04-03T10:48:40.913Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertlos", + "displayValue": { + "text": "Wertlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "WORLDLINE S.A. ANR", + "displayValue": { + "text": "WORLDLINE S.A. ANR" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "0.299376", + "displayValue": { + "text": "0.299376" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "03.04.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "806617db-1080-4301-8768-a87bf909f896", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktien_entfernt_no_eventType.json b/tests/events/aktien_entfernt_no_eventType.json new file mode 100644 index 00000000..749388e7 --- /dev/null +++ b/tests/events/aktien_entfernt_no_eventType.json @@ -0,0 +1,90 @@ +{ + "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", + "timestamp": "2025-10-28T15:46:46.286+0000", + "title": "ORSTED A/S -ANR-", + "icon": "logos/DK0064307839/v2", + "subtitle": "Wertlos", + "action": { + "type": "timelineDetail", + "payload": "c187c065-fadf-33bd-8de9-fe0ac6c0e686" + }, + "source": "timelineActivity", + "details": { + "id": "c187c065-fadf-33bd-8de9-fe0ac6c0e686", + "sections": [ + { + "title": "Aktien wurden im Rahmen einer Kapitalmaßnahme entfernt", + "data": { + "icon": "logos/DK0064307839/v2", + "timestamp": "2025-10-28T15:46:46.286Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertlos", + "displayValue": { + "text": "Wertlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S -ANR-", + "displayValue": { + "text": "ORSTED A/S -ANR-" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "0.285835", + "displayValue": { + "text": "0.285835" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "28.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "9fdeded6-aa07-401a-ad47-740da1a4c41e", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktienbonus.json b/tests/events/aktienbonus.json new file mode 100644 index 00000000..efa40169 --- /dev/null +++ b/tests/events/aktienbonus.json @@ -0,0 +1,94 @@ +{ + "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", + "timestamp": "2025-10-13T14:49:06.032+0000", + "title": "Aktien-Bonus", + "icon": "logos/US2546871060/v2", + "subtitle": "Eingelöst", + "action": { + "type": "timelineDetail", + "payload": "690011dc-3825-4f6d-9eaa-239ff72ba4d7" + }, + "eventType": "ACQUISITION_TRADE_PERK", + "source": "timelineActivity", + "details": { + "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", + "sections": [ + { + "title": "Walt Disney Aktienbonus", + "data": { + "icon": "logos/US2546871060/v2", + "timestamp": "2025-10-13T14:49:05.799+0000", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Vermögenswert", + "detail": { + "text": "Walt Disney", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "", + "displayValue": { + "text": "95,56 €", + "prefix": "0.105 ×" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "10,03 €", + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "879aa27f-f32f-44c3-beec-29c5d75d3a4f", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Rechnung", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "30237d68-3418-47ef-98f2-6a32fac756c0", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktienbonus_no_eventType.json b/tests/events/aktienbonus_no_eventType.json new file mode 100644 index 00000000..ed478329 --- /dev/null +++ b/tests/events/aktienbonus_no_eventType.json @@ -0,0 +1,93 @@ +{ + "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", + "timestamp": "2025-10-13T14:49:06.032+0000", + "title": "Aktien-Bonus", + "icon": "logos/US2546871060/v2", + "subtitle": "Eingelöst", + "action": { + "type": "timelineDetail", + "payload": "690011dc-3825-4f6d-9eaa-239ff72ba4d7" + }, + "source": "timelineActivity", + "details": { + "id": "690011dc-3825-4f6d-9eaa-239ff72ba4d7", + "sections": [ + { + "title": "Walt Disney Aktienbonus", + "data": { + "icon": "logos/US2546871060/v2", + "timestamp": "2025-10-13T14:49:05.799+0000", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Vermögenswert", + "detail": { + "text": "Walt Disney", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "", + "displayValue": { + "text": "95,56 €", + "prefix": "0.105 ×" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "10,03 €", + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "879aa27f-f32f-44c3-beec-29c5d75d3a4f", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Rechnung", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "30237d68-3418-47ef-98f2-6a32fac756c0", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktiendividende.json b/tests/events/aktiendividende.json new file mode 100644 index 00000000..4841596e --- /dev/null +++ b/tests/events/aktiendividende.json @@ -0,0 +1,91 @@ +{ + "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", + "timestamp": "2025-07-22T14:31:49.846+0000", + "title": "Enovix", + "icon": "logos/US2935941078/v2", + "subtitle": "Aktiendividende", + "action": { + "type": "timelineDetail", + "payload": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/US2935941078/v2", + "timestamp": "2025-07-22T14:31:49.846Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Aktiendividende", + "displayValue": { + "text": "Aktiendividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Enovix Corp. WTS 01.10.26", + "displayValue": { + "text": "Enovix Corp. WTS 01.10.26" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.494370", + "displayValue": { + "text": "0.494370" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "22.07.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "84c35bc3-e130-44ca-aa87-3a66b055b185", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktiendividende_no_eventType.json b/tests/events/aktiendividende_no_eventType.json new file mode 100644 index 00000000..6703da7d --- /dev/null +++ b/tests/events/aktiendividende_no_eventType.json @@ -0,0 +1,90 @@ +{ + "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", + "timestamp": "2025-07-22T14:31:49.846+0000", + "title": "Enovix", + "icon": "logos/US2935941078/v2", + "subtitle": "Aktiendividende", + "action": { + "type": "timelineDetail", + "payload": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4" + }, + "source": "timelineActivity", + "details": { + "id": "c4be0e34-b591-32eb-9d1d-ad9b5c5da1e4", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/US2935941078/v2", + "timestamp": "2025-07-22T14:31:49.846Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Aktiendividende", + "displayValue": { + "text": "Aktiendividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Enovix Corp. WTS 01.10.26", + "displayValue": { + "text": "Enovix Corp. WTS 01.10.26" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.494370", + "displayValue": { + "text": "0.494370" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "22.07.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "84c35bc3-e130-44ca-aa87-3a66b055b185", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktiendividende_only_taxes.json b/tests/events/aktiendividende_only_taxes.json new file mode 100644 index 00000000..0a5dea26 --- /dev/null +++ b/tests/events/aktiendividende_only_taxes.json @@ -0,0 +1,136 @@ +{ + "id": "09fffef5-6022-32a6-a5b5-55fcd880cad6", + "timestamp": "2026-01-06T16:14:51.218+0000", + "title": "Enovix Corp. WTS 01.10.26", + "icon": "logos/US2935941078/v2", + "avatar": { + "asset": "logos/US2935941078/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aktiendividende", + "amount": { + "currency": "EUR", + "value": -0.57, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "09fffef5-6022-32a6-a5b5-55fcd880cad6" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "09fffef5-6022-32a6-a5b5-55fcd880cad6", + "sections": [ + { + "title": "Du hast -0,57 € bezahlt", + "data": { + "icon": { + "asset": "logos/US2935941318/v2", + "badge": null + }, + "timestamp": "2026-01-06T16:14:51.218Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aktiendividende", + "displayValue": { + "text": "Aktiendividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Enovix Corp. WTS 01.10.26", + "displayValue": { + "text": "Enovix Corp. WTS 01.10.26" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,57 €", + "displayValue": { + "text": "-0,57 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-0,57 €", + "displayValue": { + "text": "-0,57 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "06.01.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "6406bb21-18b9-41d6-9ec8-cecd3babbd82", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktienpraemiendividende.json b/tests/events/aktienpraemiendividende.json new file mode 100644 index 00000000..bd1b04b7 --- /dev/null +++ b/tests/events/aktienpraemiendividende.json @@ -0,0 +1,134 @@ +{ + "id": "07005e09-2961-36af-a804-b56697756c08", + "timestamp": "2025-09-22T11:20:31.704+0000", + "title": "Glencore", + "icon": "logos/JE00B4T3BW64/v2", + "avatar": { + "asset": "logos/JE00B4T3BW64/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aktienprämiendividende", + "amount": { + "currency": "EUR", + "value": 3.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "07005e09-2961-36af-a804-b56697756c08" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "07005e09-2961-36af-a804-b56697756c08", + "sections": [ + { + "title": "Du hast 3,00 € erhalten", + "data": { + "icon": "logos/JE00B4T3BW64/v2", + "timestamp": "2025-09-22T11:20:31.704Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aktienprämiendividende", + "displayValue": { + "text": "Aktienprämiendividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Glencore", + "displayValue": { + "text": "Glencore" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "4,15 €", + "displayValue": { + "text": "4,15 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-1,15 €", + "displayValue": { + "text": "-1,15 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3,00 €", + "displayValue": { + "text": "3,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "22.09.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "af94328e-5e5f-4409-8aa3-da2834f5d486", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktienpraemiendividende2.json b/tests/events/aktienpraemiendividende2.json new file mode 100644 index 00000000..430245a9 --- /dev/null +++ b/tests/events/aktienpraemiendividende2.json @@ -0,0 +1,110 @@ +{ + "id": "1d820d2e-c9d8-38de-98ab-910788874bb5", + "timestamp": "2026-07-02T10:41:56.991+0000", + "title": "Hensoldt", + "icon": "logos/DE000HAG0005/v2", + "avatar": { + "asset": "logos/DE000HAG0005/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aktienprämiendividende", + "amount": { + "currency": "EUR", + "value": 0.98, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "CANCELED", + "action": { + "type": "timelineDetail", + "payload": "1d820d2e-c9d8-38de-98ab-910788874bb5" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH_NON_DIVIDEND", + "source": "timelineTransaction", + "details": { + "id": "1d820d2e-c9d8-38de-98ab-910788874bb5", + "sections": [ + { + "title": "Du hast 0,98 € erhalten", + "data": { + "icon": { + "asset": "logos/DE000HAG0005/v2", + "badge": null + }, + "subtitleText": "2 Juli · 10:41", + "status": "canceled" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Storniert", + "functionalStyle": "CANCELED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aktienprämiendividende", + "displayValue": { + "text": "Aktienprämiendividende", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Hensoldt", + "displayValue": { + "text": "Hensoldt", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "02.07.2026", + "action": { + "payload": "https://example.com/pb1782989599488139633943454541.pdf", + "type": "browserModal" + }, + "id": "04c7d864-de68-4133-aa38-cdf77655baf2", + "postboxType": "CA_INCOME_INVOICE" + }, + { + "title": "Dokumente", + "detail": "27.05.2026", + "action": { + "payload": "https://example.com/pb17798719140201365610066326.pdf", + "type": "browserModal" + }, + "id": "964c98d8-3a87-44d1-9217-10bd675347fb", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktienpraemiendividende_no_eventType.json b/tests/events/aktienpraemiendividende_no_eventType.json new file mode 100644 index 00000000..a6f7c7aa --- /dev/null +++ b/tests/events/aktienpraemiendividende_no_eventType.json @@ -0,0 +1,133 @@ +{ + "id": "07005e09-2961-36af-a804-b56697756c08", + "timestamp": "2025-09-22T11:20:31.704+0000", + "title": "Glencore", + "icon": "logos/JE00B4T3BW64/v2", + "avatar": { + "asset": "logos/JE00B4T3BW64/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aktienprämiendividende", + "amount": { + "currency": "EUR", + "value": 3.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "07005e09-2961-36af-a804-b56697756c08" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "07005e09-2961-36af-a804-b56697756c08", + "sections": [ + { + "title": "Du hast 3,00 € erhalten", + "data": { + "icon": "logos/JE00B4T3BW64/v2", + "timestamp": "2025-09-22T11:20:31.704Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aktienprämiendividende", + "displayValue": { + "text": "Aktienprämiendividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Glencore", + "displayValue": { + "text": "Glencore" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "4,15 €", + "displayValue": { + "text": "4,15 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-1,15 €", + "displayValue": { + "text": "-1,15 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3,00 €", + "displayValue": { + "text": "3,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "22.09.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "af94328e-5e5f-4409-8aa3-da2834f5d486", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktiensplit.json b/tests/events/aktiensplit.json new file mode 100644 index 00000000..19cdb10b --- /dev/null +++ b/tests/events/aktiensplit.json @@ -0,0 +1,91 @@ +{ + "id": "e230be28-286a-31b6-879f-5c97f8a9d85a", + "timestamp": "2024-06-26T08:06:40.347+0000", + "title": "Chipotle Mexican Grill", + "icon": "logos/US1696561059/v2", + "subtitle": "Aktiensplit", + "action": { + "type": "timelineDetail", + "payload": "e230be28-286a-31b6-879f-5c97f8a9d85a" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "e230be28-286a-31b6-879f-5c97f8a9d85a", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/US1696561059/v2", + "timestamp": "2024-06-26T08:06:40.347Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Aktiensplit", + "displayValue": { + "text": "Aktiensplit" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Chipotle", + "displayValue": { + "text": "Chipotle" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "49.000000", + "displayValue": { + "text": "49.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "26.06.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "327ea786-399b-406b-988a-0f47e7c68f38", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktiensplit2.json b/tests/events/aktiensplit2.json new file mode 100644 index 00000000..f52d8921 --- /dev/null +++ b/tests/events/aktiensplit2.json @@ -0,0 +1,100 @@ +{ + "id": "bf903d2e-8353-3a00-94dd-312a876a0ab1", + "timestamp": "2026-07-02T06:31:26.598+0000", + "title": "Crowdstrike Holdings (A)", + "icon": "logos/US22788C1053/v2", + "subtitle": "Aktiensplit", + "action": { + "type": "timelineDetail", + "payload": "bf903d2e-8353-3a00-94dd-312a876a0ab1" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "bf903d2e-8353-3a00-94dd-312a876a0ab1", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten", + "data": { + "icon": { + "asset": "logos/US22788C1053/v2", + "badge": null + }, + "subtitleText": "2 Juli · 06:31", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Aktiensplit", + "displayValue": { + "text": "Aktiensplit", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Crowdstrike Holdings (A)", + "displayValue": { + "text": "Crowdstrike Holdings (A)", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.688026", + "displayValue": { + "text": "0.688026", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "02.07.2026", + "action": { + "payload": "https://example.com/pb178297411197790182675288721.pdf", + "type": "browserModal" + }, + "id": "03c70be5-854b-4994-b73c-e9230791b6af", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/aktiensplit_no_eventType.json b/tests/events/aktiensplit_no_eventType.json new file mode 100644 index 00000000..f11a9689 --- /dev/null +++ b/tests/events/aktiensplit_no_eventType.json @@ -0,0 +1,90 @@ +{ + "id": "f122c692-98cf-3acc-b86b-9eff6b9d9980", + "timestamp": "2025-11-17T06:07:56.460+0000", + "title": "Netflix", + "icon": "logos/US64110L1061/v2", + "subtitle": "Aktiensplit", + "action": { + "type": "timelineDetail", + "payload": "f122c692-98cf-3acc-b86b-9eff6b9d9980" + }, + "source": "timelineActivity", + "details": { + "id": "f122c692-98cf-3acc-b86b-9eff6b9d9980", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/US64110L1061/v2", + "timestamp": "2025-11-17T06:07:56.46Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Aktiensplit", + "displayValue": { + "text": "Aktiensplit" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Netflix", + "displayValue": { + "text": "Netflix" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "2.743902", + "displayValue": { + "text": "2.743902" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "17.11.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "69e378d1-bade-4c76-9886-74cb4d669d00", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bank_transaction_incoming.json b/tests/events/bank_transaction_incoming.json new file mode 100644 index 00000000..3324b360 --- /dev/null +++ b/tests/events/bank_transaction_incoming.json @@ -0,0 +1,118 @@ +{ + "id": "37dcd310-1b1e-430f-9a7d-adfbee85a378", + "timestamp": "2024-07-04T06:17:41.228+0000", + "title": "Max Mustermann", + "icon": "logos/contacts-C-Lightblue/v2", + "avatar": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "badge": null, + "subtitle": "Fertig", + "amount": { + "currency": "EUR", + "value": 5.15, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "37dcd310-1b1e-430f-9a7d-adfbee85a378" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "BANK_TRANSACTION_INCOMING", + "source": "timelineTransaction", + "details": { + "id": "37dcd310-1b1e-430f-9a7d-adfbee85a378", + "sections": [ + { + "title": "Du hast 5,15 € von Max Mustermann erhalten", + "data": { + "icon": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "subtitleText": "4 Juli 2024 · 06:17", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "CREATED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Referenz", + "detail": { + "text": "Baecker", + "displayValue": { + "text": "Baecker", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Absender", + "data": [ + { + "title": "Name", + "detail": { + "text": "Max Mustermann", + "displayValue": { + "text": "Max Mustermann", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "DE00123456789012345678", + "displayValue": { + "text": "DE00123456789012345678", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "detail": "04.07.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "31061d66-01ca-42af-9825-9d157ff82392", + "postboxType": "INCOMING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bank_transaction_outgoing.json b/tests/events/bank_transaction_outgoing.json new file mode 100644 index 00000000..daca705e --- /dev/null +++ b/tests/events/bank_transaction_outgoing.json @@ -0,0 +1,127 @@ +{ + "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", + "timestamp": "2024-07-21T09:35:47.370+0000", + "title": "Max Mustermann", + "icon": "logos/contacts-C-Lightblue/v2", + "avatar": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "badge": null, + "subtitle": "Gesendet", + "amount": { + "currency": "EUR", + "value": -50.3, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "01b0c632-47de-4beb-9b09-6eb8ac42e871" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "BANK_TRANSACTION_OUTGOING", + "source": "timelineTransaction", + "details": { + "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", + "sections": [ + { + "title": "Du hast -50,30 € an Max Mustermann gesendet", + "data": { + "icon": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "subtitleText": "21 Juli 2024 · 09:35", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Gesendet mit", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Referenz", + "detail": { + "text": "Sent via Trade Republic", + "displayValue": { + "text": "Sent via Trade Republic", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Empfänger", + "data": [ + { + "title": "Name", + "detail": { + "text": "Max Mustermann", + "displayValue": { + "text": "Max Mustermann", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "DE00123456789012345678", + "displayValue": { + "text": "DE00123456789012345678", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "detail": "22.07.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "325de7ad-a645-442f-bb14-09a4de5f7fbf", + "postboxType": "OUTGOING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bardividende.json b/tests/events/bardividende.json new file mode 100644 index 00000000..29684f76 --- /dev/null +++ b/tests/events/bardividende.json @@ -0,0 +1,145 @@ +{ + "id": "88008da6-da94-3e0e-8ea5-e3878643f5ab", + "timestamp": "2025-10-23T14:19:56.295+0000", + "title": "Comcast (A)", + "icon": "logos/US20030N1019/v2", + "avatar": { + "asset": "logos/US20030N1019/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bardividende", + "amount": { + "currency": "EUR", + "value": 2.24, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "88008da6-da94-3e0e-8ea5-e3878643f5ab" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "88008da6-da94-3e0e-8ea5-e3878643f5ab", + "sections": [ + { + "title": "Du hast 2,24 € erhalten", + "data": { + "icon": "logos/US20030N1019/v2", + "timestamp": "2025-10-23T14:19:56.295Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bardividende", + "displayValue": { + "text": "Bardividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Comcast (A)", + "displayValue": { + "text": "Comcast (A)" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "10.640298", + "displayValue": { + "text": "10.640298" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende pro Aktie", + "detail": { + "text": "0,33 $", + "displayValue": { + "text": "0,33 $" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,78 €", + "displayValue": { + "text": "-0,78 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "2,24 €", + "displayValue": { + "text": "2,24 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "23.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "974b4871-2481-4751-b183-c36c2f960e4a", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bardividende_korrigiert.json b/tests/events/bardividende_korrigiert.json new file mode 100644 index 00000000..5b1d04e3 --- /dev/null +++ b/tests/events/bardividende_korrigiert.json @@ -0,0 +1,145 @@ +{ + "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", + "timestamp": "2025-03-20T15:04:31.460+0000", + "title": "Medical Properties Trust", + "icon": "logos/US58463J3041/v2", + "avatar": { + "asset": "logos/US58463J3041/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bardividende korrigiert", + "amount": { + "currency": "EUR", + "value": 4.01, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "da13151b-c8c3-3c4e-a613-24b28d5b16ac" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", + "sections": [ + { + "title": "Du hast 4,01 € erhalten", + "data": { + "icon": "logos/US58463J3041/v2", + "timestamp": "2025-03-20T15:04:31.46Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bardividende korrigiert", + "displayValue": { + "text": "Bardividende korrigiert" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Medical Properties Trust", + "displayValue": { + "text": "Medical Properties Trust" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "40.000000", + "displayValue": { + "text": "40.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende pro Aktie", + "detail": { + "text": "0,15 $", + "displayValue": { + "text": "0,15 $" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-1,53 €", + "displayValue": { + "text": "-1,53 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "4,01 €", + "displayValue": { + "text": "4,01 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "20.03.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4b1c122a-a6e2-48aa-a9d2-900f47668de8", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bardividende_korrigiert2.json b/tests/events/bardividende_korrigiert2.json new file mode 100644 index 00000000..eafcddb1 --- /dev/null +++ b/tests/events/bardividende_korrigiert2.json @@ -0,0 +1,80 @@ +{ + "id": "dfe3fa0d-be9f-30aa-b50e-6efdf27ecb1d", + "timestamp": "2026-06-26T13:51:37.901+0000", + "title": "Medical Properties Trust", + "icon": "logos/US58463J3041/v2", + "avatar": { + "asset": "logos/US58463J3041/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bardividende korrigiert", + "amount": { + "currency": "EUR", + "value": 0.37, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "dfe3fa0d-be9f-30aa-b50e-6efdf27ecb1d" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH", + "source": "timelineTransaction", + "details": { + "id": "dfe3fa0d-be9f-30aa-b50e-6efdf27ecb1d", + "sections": [ + { + "type": "header", + "title": "Du hast 0,37 € erhalten", + "data": { + "status": "executed", + "icon": "logos/US58463J3041/v2", + "timestamp": "2026-06-26T13:51:37.901118Z" + } + }, + { + "type": "table", + "title": "Überblick", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Ausgeführt", + "functionalStyle": "EXECUTED" + } + }, + { + "title": "Vermögenswert", + "style": "plain", + "detail": { + "type": "text", + "text": "Medical Properties Trust" + } + } + ] + }, + { + "type": "documents", + "title": "Dokumente", + "data": [ + { + "id": "ec8f5ff2-9a6d-42f7-bdb7-e2efcdb0a991", + "title": "Dividendenbeleg", + "action": { + "type": "browserModal", + "payload": "https://example.com/pb178248205762239248901284987.pdf" + }, + "postboxType": "INVOICE" + } + ] + } + ] + } +} diff --git a/tests/events/bardividende_korrigiert_no_eventType.json b/tests/events/bardividende_korrigiert_no_eventType.json new file mode 100644 index 00000000..c90b2363 --- /dev/null +++ b/tests/events/bardividende_korrigiert_no_eventType.json @@ -0,0 +1,144 @@ +{ + "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", + "timestamp": "2025-03-20T15:04:31.460+0000", + "title": "Medical Properties Trust", + "icon": "logos/US58463J3041/v2", + "avatar": { + "asset": "logos/US58463J3041/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bardividende korrigiert", + "amount": { + "currency": "EUR", + "value": 4.01, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "da13151b-c8c3-3c4e-a613-24b28d5b16ac" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "da13151b-c8c3-3c4e-a613-24b28d5b16ac", + "sections": [ + { + "title": "Du hast 4,01 € erhalten", + "data": { + "icon": "logos/US58463J3041/v2", + "timestamp": "2025-03-20T15:04:31.46Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bardividende korrigiert", + "displayValue": { + "text": "Bardividende korrigiert" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Medical Properties Trust", + "displayValue": { + "text": "Medical Properties Trust" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "40.000000", + "displayValue": { + "text": "40.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende pro Aktie", + "detail": { + "text": "0,15 $", + "displayValue": { + "text": "0,15 $" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-1,53 €", + "displayValue": { + "text": "-1,53 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "4,01 €", + "displayValue": { + "text": "4,01 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "20.03.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4b1c122a-a6e2-48aa-a9d2-900f47668de8", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bardividende_no_eventType.json b/tests/events/bardividende_no_eventType.json new file mode 100644 index 00000000..d2efa16b --- /dev/null +++ b/tests/events/bardividende_no_eventType.json @@ -0,0 +1,144 @@ +{ + "id": "de17e7cb-49cd-322f-8345-1b265dc9730d", + "timestamp": "2025-11-05T18:31:19.339+0000", + "title": "Lowe's", + "icon": "logos/US5486611073/v2", + "avatar": { + "asset": "logos/US5486611073/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bardividende", + "amount": { + "currency": "EUR", + "value": 0.92, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "de17e7cb-49cd-322f-8345-1b265dc9730d" + }, + "cashAccountNumber": "", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "de17e7cb-49cd-322f-8345-1b265dc9730d", + "sections": [ + { + "title": "Du hast 0,92 € erhalten", + "data": { + "icon": "logos/US5486611073/v2", + "timestamp": "2025-11-05T18:31:19.339Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bardividende", + "displayValue": { + "text": "Bardividende" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Lowe's", + "displayValue": { + "text": "Lowe's" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "1.189904", + "displayValue": { + "text": "1.189904" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende pro Aktie", + "detail": { + "text": "1,20 $", + "displayValue": { + "text": "1,20 $" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,32 €", + "displayValue": { + "text": "-0,32 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "0,92 €", + "displayValue": { + "text": "0,92 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "05.11.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "36b29c55-5bef-44c3-b50c-7541403a9414", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bardividende_zero.json b/tests/events/bardividende_zero.json new file mode 100644 index 00000000..3d30b74e --- /dev/null +++ b/tests/events/bardividende_zero.json @@ -0,0 +1,154 @@ +{ + "id": "4adea6ed-6630-3d47-9c2f-0440d14a1ece", + "timestamp": "2025-05-07T15:32:27.090+0000", + "title": "L'Oreal", + "icon": "logos/FR0000120321/v2", + "avatar": { + "asset": "logos/FR0000120321/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bardividende", + "amount": { + "currency": "EUR", + "value": 0.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "4adea6ed-6630-3d47-9c2f-0440d14a1ece" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH", + "source": "timelineTransaction", + "details": { + "id": "4adea6ed-6630-3d47-9c2f-0440d14a1ece", + "sections": [ + { + "title": "Du hast 0,00 € erhalten", + "data": { + "icon": { + "asset": "logos/FR0000120321/v2", + "badge": null + }, + "subtitleText": "7 Mai 2025 · 15:32", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bardividende", + "displayValue": { + "text": "Bardividende", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "L'Oreal", + "displayValue": { + "text": "L'Oreal", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0.000125", + "displayValue": { + "text": "0.000125", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende pro Aktie", + "detail": { + "text": "7,00 €", + "displayValue": { + "text": "7,00 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "07.05.2025", + "action": { + "payload": "https://example.com/doc.pdf", + "type": "browserModal" + }, + "id": "2acf203c-9938-4f9f-b697-61625b14f289", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/benefits_spare_change_execution.json b/tests/events/benefits_spare_change_execution.json new file mode 100644 index 00000000..74ddfad4 --- /dev/null +++ b/tests/events/benefits_spare_change_execution.json @@ -0,0 +1,139 @@ +{ + "id": "5b516589-a0b6-46fb-80e1-2506bef82542", + "timestamp": "2024-10-02T15:05:40.970+0000", + "title": "SuperDividend USD (Dist)", + "icon": "logos/IE00077FRP95/v2", + "avatar": { + "asset": "logos/IE00077FRP95/v2", + "badge": null + }, + "badge": null, + "subtitle": "Round up", + "amount": { + "currency": "EUR", + "value": -3.38, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "5b516589-a0b6-46fb-80e1-2506bef82542" + }, + "eventType": "benefits_spare_change_execution", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "5b516589-a0b6-46fb-80e1-2506bef82542", + "sections": [ + { + "title": "Du hast 3,38 € investiert", + "data": { + "icon": "logos/IE00077FRP95/v2", + "timestamp": "2024-10-02T15:05:40.970073Z", + "status": "executed" + }, + "action": { + "payload": "IE00077FRP95", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Round up", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "SuperDividend USD (Dist)", + "displayValue": { + "text": "SuperDividend USD (Dist)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0.383219 x 8,82 €", + "displayValue": { + "text": "8,82 €", + "prefix": "0.383219 x " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3,38 €", + "displayValue": { + "text": "3,38 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Ausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "42368c8d-a698-4682-80dd-8ca0f0b25fea", + "postboxType": "SAVINGS_PLAN_EXECUTED_V2" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "044294ae-0534-45e3-a0ff-14d212e1c48f", + "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" + }, + { + "title": "Deaktivierung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "f21430be-32c6-4fa6-9512-7210d07f41fe", + "postboxType": "BENEFIT_DEACTIVATED" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/benefits_spare_change_execution_no_eventType.json b/tests/events/benefits_spare_change_execution_no_eventType.json new file mode 100644 index 00000000..83d37e3e --- /dev/null +++ b/tests/events/benefits_spare_change_execution_no_eventType.json @@ -0,0 +1,138 @@ +{ + "id": "5b516589-a0b6-46fb-80e1-2506bef82542", + "timestamp": "2024-10-02T15:05:40.970+0000", + "title": "SuperDividend USD (Dist)", + "icon": "logos/IE00077FRP95/v2", + "avatar": { + "asset": "logos/IE00077FRP95/v2", + "badge": null + }, + "badge": null, + "subtitle": "Round up", + "amount": { + "currency": "EUR", + "value": -3.38, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "5b516589-a0b6-46fb-80e1-2506bef82542" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "5b516589-a0b6-46fb-80e1-2506bef82542", + "sections": [ + { + "title": "Du hast 3,38 € investiert", + "data": { + "icon": "logos/IE00077FRP95/v2", + "timestamp": "2024-10-02T15:05:40.970073Z", + "status": "executed" + }, + "action": { + "payload": "IE00077FRP95", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Round up", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "SuperDividend USD (Dist)", + "displayValue": { + "text": "SuperDividend USD (Dist)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0.383219 x 8,82 €", + "displayValue": { + "text": "8,82 €", + "prefix": "0.383219 x " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3,38 €", + "displayValue": { + "text": "3,38 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Ausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "42368c8d-a698-4682-80dd-8ca0f0b25fea", + "postboxType": "SAVINGS_PLAN_EXECUTED_V2" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "044294ae-0534-45e3-a0ff-14d212e1c48f", + "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" + }, + { + "title": "Deaktivierung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "f21430be-32c6-4fa6-9512-7210d07f41fe", + "postboxType": "BENEFIT_DEACTIVATED" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bond_kauf.json b/tests/events/bond_kauf.json new file mode 100644 index 00000000..e75d4fef --- /dev/null +++ b/tests/events/bond_kauf.json @@ -0,0 +1,242 @@ +{ + "id": "6c7755f0-0943-422b-b9ba-bfd9c105584a", + "timestamp": "2025-07-18T08:04:42.708+0000", + "title": "Juli 2040", + "icon": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "avatar": { + "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -100.99, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "6c7755f0-0943-422b-b9ba-bfd9c105584a" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "TRADING_TRADE_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "6c7755f0-0943-422b-b9ba-bfd9c105584a", + "sections": [ + { + "title": "Du hast 100,99 € investiert", + "data": { + "icon": { + "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "badge": null + }, + "timestamp": "2025-07-18T08:04:42.70813202Z", + "status": "executed" + }, + "action": { + "payload": "DE0001135366", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Juli 2040", + "displayValue": { + "text": "Juli 2040" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "99,80 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Nennwert", + "detail": { + "text": "82,00 €", + "displayValue": { + "text": "82,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Quotation", + "detail": { + "text": "121,31 %", + "displayValue": { + "text": "121,31 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Stückzinsen", + "detail": { + "text": "0,19 €", + "displayValue": { + "text": "0,19 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "100,99 €", + "displayValue": { + "text": "100,99 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "99,80 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "100,99 €", + "displayValue": { + "text": "100,99 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "0,19 %", + "trend": "negative", + "displayValue": { + "text": "0,19 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verlust", + "detail": { + "text": "-0,19 €", + "trend": "negative", + "displayValue": { + "text": "-0,19 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation 1", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "705597e0-f359-4f1e-bd46-ed128d12d620", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Kosteninformation 2", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "ca3d15ea-d560-4bc8-85a8-73dd81ef7579", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Abrechnung 1", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "e337f3cc-2cc4-446b-99ce-7ab1b41f66a9", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 2", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "1ef2976f-118e-4c79-8cb0-3da858fb291d", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bond_verkauf.json b/tests/events/bond_verkauf.json new file mode 100644 index 00000000..6a70abc1 --- /dev/null +++ b/tests/events/bond_verkauf.json @@ -0,0 +1,323 @@ +{ + "id": "e45b8873-16ce-440d-ae96-a4586cfdf9ca", + "timestamp": "2026-03-26T06:48:09.708+0000", + "title": "Juli 2040", + "icon": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "avatar": { + "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "badge": null + }, + "badge": null, + "subtitle": "Verkaufsorder", + "amount": { + "currency": "EUR", + "value": 98.21, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "e45b8873-16ce-440d-ae96-a4586cfdf9ca" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "TRADING_TRADE_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "e45b8873-16ce-440d-ae96-a4586cfdf9ca", + "sections": [ + { + "title": "Du hast 98,21 € erhalten", + "data": { + "icon": { + "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "badge": null + }, + "timestamp": "2026-03-26T06:48:09.708126976Z", + "status": "executed" + }, + "action": { + "payload": "DE0001135366", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Verkaufen", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Juli 2040", + "displayValue": { + "text": "Juli 2040" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "96,33 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Nennwert", + "detail": { + "text": "0,27 €", + "displayValue": { + "text": "0,27 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Quotation", + "detail": { + "text": "117,09 %", + "displayValue": { + "text": "117,09 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Stückzinsen", + "detail": { + "text": "+ 2,88 €", + "displayValue": { + "text": "+ 2,88 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "+ 98,21 €", + "displayValue": { + "text": "+ 98,21 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "96,33 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Gezahlte Steuern 0,00 €", + "data": { + "icon": { + "asset": "logos/bondissuer-529900AQBND3S6YJLY83/v2", + "badge": null + }, + "timestamp": "2026-03-26T06:48:09.708126976Z", + "status": "executed" + }, + "action": { + "payload": "DE0001135366", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Steuerbemessungsgrundlage", + "data": [ + { + "title": "Bruttogewinn", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Steuern", + "data": [ + { + "title": "Summe", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + } + ] + }, + "displayMode": "modal", + "type": "infoPage" + }, + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "98,21 €", + "displayValue": { + "text": "98,21 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "2,65 %", + "trend": "negative", + "displayValue": { + "text": "2,65 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verlust", + "detail": { + "text": "-2,59 €", + "trend": "negative", + "displayValue": { + "text": "-2,59 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung 1", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "3713df09-15f0-49ac-859b-da60279ffdb9", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 2", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "e71c5516-f6dc-495b-9666-b54b6e618cf4", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation 1", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "15ae9c44-e002-495e-9c21-93e07ede2a64", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Kosteninformation 2", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "d616495a-e777-4e72-877d-4663b9b52cbf", + "postboxType": "EQUITIES_SELL_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bonusaktien.json b/tests/events/bonusaktien.json new file mode 100644 index 00000000..8a58222c --- /dev/null +++ b/tests/events/bonusaktien.json @@ -0,0 +1,101 @@ +{ + "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", + "timestamp": "2025-08-15T08:10:12.583+0000", + "title": "Eckert & Ziegler", + "icon": "logos/DE0005659700/v2", + "subtitle": "Bonusaktien", + "action": { + "type": "timelineDetail", + "payload": "9af345e0-248d-36ed-bc76-6fb96033ba1d" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/DE0005659700/v2", + "timestamp": "2025-08-15T08:10:12.583Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Bonusaktien", + "displayValue": { + "text": "Bonusaktien" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Eckert & Ziegler", + "displayValue": { + "text": "Eckert & Ziegler" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.706536", + "displayValue": { + "text": "5.706536" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "18.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "ac5a0f89-1766-4c95-b056-498be4ed550b", + "postboxType": "CA_SECURITIES_INVOICE" + }, + { + "title": "Dokumente", + "detail": "15.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "dc687f7d-5fa0-48b4-ba37-35b7d06df261", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bonusaktien2.json b/tests/events/bonusaktien2.json new file mode 100644 index 00000000..e93207a0 --- /dev/null +++ b/tests/events/bonusaktien2.json @@ -0,0 +1,97 @@ +{ + "id": "0940e56b-41c5-3da4-a880-501752bb2580", + "timestamp": "2025-08-13T05:22:45.443+0000", + "title": "BYD", + "icon": "logos/CNE100000296/v2", + "subtitle": "Bonusaktien", + "action": { + "type": "timelineDetail", + "payload": "0940e56b-41c5-3da4-a880-501752bb2580" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_ACTIVITY", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "0940e56b-41c5-3da4-a880-501752bb2580", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": { + "asset": "logos/CNE100000296/v2", + "badge": null + }, + "timestamp": "2025-08-13T05:22:45.443Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Bonusaktien", + "displayValue": { + "text": "Bonusaktien" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "BYD", + "displayValue": { + "text": "BYD" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "2.149301", + "displayValue": { + "text": "2.149301" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "13.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "90618b77-a507-4467-8995-24c9d411e76b", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bonusaktien_canceled.json b/tests/events/bonusaktien_canceled.json new file mode 100644 index 00000000..7acc5cc2 --- /dev/null +++ b/tests/events/bonusaktien_canceled.json @@ -0,0 +1,107 @@ +{ + "id": "d60030b9-878a-3935-9327-0ea85ca78c45", + "timestamp": "2025-08-13T05:09:14.774+0000", + "title": "BYD", + "icon": "logos/CNE100000296/v2", + "subtitle": "Bonusaktien", + "action": { + "type": "timelineDetail", + "payload": "d60030b9-878a-3935-9327-0ea85ca78c45" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_ACTIVITY", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "d60030b9-878a-3935-9327-0ea85ca78c45", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": { + "asset": "logos/CNE100000296/v2", + "badge": null + }, + "timestamp": "2025-08-13T05:09:14.774Z", + "status": "canceled" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Storniert", + "functionalStyle": "CANCELED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Bonusaktien", + "displayValue": { + "text": "Bonusaktien" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "BYD", + "displayValue": { + "text": "BYD" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "2.149301", + "displayValue": { + "text": "2.149301" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "15.04.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "facdac8e-5551-4cee-bec3-672b4108a28d", + "postboxType": "CA_SECURITIES_INVOICE" + }, + { + "title": "Dokumente", + "detail": "30.07.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "097d8cc4-09fa-4f69-8572-a7309d0144ac", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bonusaktien_no_eventType.json b/tests/events/bonusaktien_no_eventType.json new file mode 100644 index 00000000..5af4761f --- /dev/null +++ b/tests/events/bonusaktien_no_eventType.json @@ -0,0 +1,100 @@ +{ + "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", + "timestamp": "2025-08-15T08:10:12.583+0000", + "title": "Eckert & Ziegler", + "icon": "logos/DE0005659700/v2", + "subtitle": "Bonusaktien", + "action": { + "type": "timelineDetail", + "payload": "9af345e0-248d-36ed-bc76-6fb96033ba1d" + }, + "source": "timelineActivity", + "details": { + "id": "9af345e0-248d-36ed-bc76-6fb96033ba1d", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/DE0005659700/v2", + "timestamp": "2025-08-15T08:10:12.583Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Bonusaktien", + "displayValue": { + "text": "Bonusaktien" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Eckert & Ziegler", + "displayValue": { + "text": "Eckert & Ziegler" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.706536", + "displayValue": { + "text": "5.706536" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "18.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "ac5a0f89-1766-4c95-b056-498be4ed550b", + "postboxType": "CA_SECURITIES_INVOICE" + }, + { + "title": "Dokumente", + "detail": "15.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "dc687f7d-5fa0-48b4-ba37-35b7d06df261", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bonusaktien_tax_only.json b/tests/events/bonusaktien_tax_only.json new file mode 100644 index 00000000..1f9f03b6 --- /dev/null +++ b/tests/events/bonusaktien_tax_only.json @@ -0,0 +1,134 @@ +{ + "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", + "timestamp": "2025-08-15T14:53:09.730+0000", + "title": "BYD", + "icon": "logos/CNE100000296/v2", + "avatar": { + "asset": "logos/CNE100000296/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bonusaktien", + "amount": { + "currency": "EUR", + "value": -8.67, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "e8aa0763-c7ac-3cbe-b72c-762fa4489450" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", + "sections": [ + { + "title": "Du hast -8,67 € bezahlt", + "data": { + "icon": "logos/CNE100000296/v2", + "timestamp": "2025-08-15T14:53:09.73Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bonusaktien", + "displayValue": { + "text": "Bonusaktien" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "BYD", + "displayValue": { + "text": "BYD" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-8,67 €", + "displayValue": { + "text": "-8,67 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-8,67 €", + "displayValue": { + "text": "-8,67 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "15.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "28f2dde3-c3f0-4c34-8c5d-f7ab968d3983", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/bonusaktien_tax_only_no_eventType.json b/tests/events/bonusaktien_tax_only_no_eventType.json new file mode 100644 index 00000000..2cae1927 --- /dev/null +++ b/tests/events/bonusaktien_tax_only_no_eventType.json @@ -0,0 +1,133 @@ +{ + "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", + "timestamp": "2025-08-15T14:53:09.730+0000", + "title": "BYD", + "icon": "logos/CNE100000296/v2", + "avatar": { + "asset": "logos/CNE100000296/v2", + "badge": null + }, + "badge": null, + "subtitle": "Bonusaktien", + "amount": { + "currency": "EUR", + "value": -8.67, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "e8aa0763-c7ac-3cbe-b72c-762fa4489450" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "e8aa0763-c7ac-3cbe-b72c-762fa4489450", + "sections": [ + { + "title": "Du hast -8,67 € bezahlt", + "data": { + "icon": "logos/CNE100000296/v2", + "timestamp": "2025-08-15T14:53:09.73Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Bonusaktien", + "displayValue": { + "text": "Bonusaktien" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "BYD", + "displayValue": { + "text": "BYD" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-8,67 €", + "displayValue": { + "text": "-8,67 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-8,67 €", + "displayValue": { + "text": "-8,67 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "15.08.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "28f2dde3-c3f0-4c34-8c5d-f7ab968d3983", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/buy.json b/tests/events/buy.json new file mode 100644 index 00000000..41e3e97f --- /dev/null +++ b/tests/events/buy.json @@ -0,0 +1,163 @@ +{ + "id": "12345678", + "timestamp": "2024-02-20T16:32:07.731+0000", + "title": "Euro Stoxx 50 EUR (Dist)", + "icon": "logos/IE00B4K6B022/v2", + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -3002.8, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "eventType": "ORDER_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 3.002,80 € investiert", + "data": { + "icon": "logos/IE00B4K6B022/v2", + "subtitleText": null, + "timestamp": "2024-02-20T16:32:07.731+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "IE00B4K6B022" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Kauf", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Euro Stoxx 50 EUR (Dist)", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "60", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "50,03 €", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3.002,80 €", + "trend": null, + "action": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "20.02.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "", + "postboxType": "SECURITIES_SETTLEMENT", + "local filepath": "" + }, + { + "title": "Basisinformationsblatt", + "detail": "20.02.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "12345678", + "postboxType": "INFO", + "local filepath": "" + }, + { + "title": "Kosteninformation", + "detail": "20.02.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "12345678", + "postboxType": "COSTS_INFO_BUY_V2", + "local filepath": "" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/buy_new.json b/tests/events/buy_new.json new file mode 100644 index 00000000..a859a001 --- /dev/null +++ b/tests/events/buy_new.json @@ -0,0 +1,191 @@ +{ + "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", + "timestamp": "2025-10-10T19:29:43.928+0000", + "title": "NVIDIA", + "icon": "logos/US67066G1040/v2", + "avatar": { + "asset": "logos/US67066G1040/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -111.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "63c6df01-c99b-4bda-aec0-c8f996fbaae1" + }, + "eventType": "trading_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", + "sections": [ + { + "title": "Du hast 111,00 € investiert", + "data": { + "icon": "logos/US67066G1040/v2", + "timestamp": "2025-10-10T19:29:43.928252Z", + "status": "executed" + }, + "action": { + "payload": "US67066G1040", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Kauf", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "NVIDIA", + "displayValue": { + "text": "NVIDIA" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,685102 × 160,56 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,685102", + "displayValue": { + "text": "0,685102" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "160,56 €", + "displayValue": { + "text": "160,56 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "110,00 €", + "displayValue": { + "text": "110,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "160,56 €", + "prefix": "0,685102 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "111,00 €", + "displayValue": { + "text": "111,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "085e4556-22b9-4af6-977b-f34fb90d1dee", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "2ea881b8-e8e7-4d4d-8df9-07d2d9cab6a8", + "postboxType": "EQUITIES_BUY_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/buy_new2.json b/tests/events/buy_new2.json new file mode 100644 index 00000000..179da5b9 --- /dev/null +++ b/tests/events/buy_new2.json @@ -0,0 +1,199 @@ +{ + "id": "471bf3aa-541e-42b5-a600-c5180b139806", + "timestamp": "2025-08-01T08:28:01.425+0000", + "title": "Rocket Lab Corp. Registered Shares DL-,0001", + "icon": "logos/US7731211089/v2", + "avatar": { + "asset": "logos/US7731211089/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit-Buy-Order", + "amount": { + "currency": "EUR", + "value": -75.6, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "471bf3aa-541e-42b5-a600-c5180b139806" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "471bf3aa-541e-42b5-a600-c5180b139806", + "sections": [ + { + "title": "Du hast 75,60 € investiert", + "data": { + "icon": "logos/US7731211089/v2", + "timestamp": "2025-08-01T08:28:01.425Z", + "status": "executed" + }, + "action": { + "payload": "US7731211089", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Limit Order", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Rocket Lab Corp. Registered Shares DL-,0001", + "displayValue": { + "text": "Rocket Lab Corp. Registered Shares DL-,0001" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "2 × 37,30 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "2", + "displayValue": { + "text": "2" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "37,30 €", + "displayValue": { + "text": "37,30 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "74,60 €", + "displayValue": { + "text": "74,60 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "37,30 €", + "prefix": "2 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "75,60 €", + "displayValue": { + "text": "75,60 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "2b2f5b5e-d6c9-4f87-ab7b-fafe426b2c84", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "77927fdb-67f9-40fa-908b-32dea64fcf2f", + "postboxType": "ORDER_CONFIRMATION" + }, + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "42bd93b1-8f48-489f-b1e3-6eb955191d62", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/buy_new2_no_eventType.json b/tests/events/buy_new2_no_eventType.json new file mode 100644 index 00000000..0afd0133 --- /dev/null +++ b/tests/events/buy_new2_no_eventType.json @@ -0,0 +1,200 @@ +{ + "id": "471bf3aa-541e-42b5-a600-c5180b139806", + "timestamp": "2025-08-01T08:28:01.425+0000", + "title": "Rocket Lab Corp. Registered Shares DL-,0001", + "icon": "logos/US7731211089/v2", + "avatar": { + "asset": "logos/US7731211089/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit-Buy-Order", + "amount": { + "currency": "EUR", + "value": -75.6, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "471bf3aa-541e-42b5-a600-c5180b139806" + }, + "eventType": "trading_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "471bf3aa-541e-42b5-a600-c5180b139806", + "sections": [ + { + "title": "Du hast 75,60 € investiert", + "data": { + "icon": "logos/US7731211089/v2", + "timestamp": "2025-08-01T08:28:01.425Z", + "status": "executed" + }, + "action": { + "payload": "US7731211089", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Limit Order", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Rocket Lab Corp. Registered Shares DL-,0001", + "displayValue": { + "text": "Rocket Lab Corp. Registered Shares DL-,0001" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "2 × 37,30 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "2", + "displayValue": { + "text": "2" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "37,30 €", + "displayValue": { + "text": "37,30 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "74,60 €", + "displayValue": { + "text": "74,60 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "37,30 €", + "prefix": "2 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "75,60 €", + "displayValue": { + "text": "75,60 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "2b2f5b5e-d6c9-4f87-ab7b-fafe426b2c84", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "77927fdb-67f9-40fa-908b-32dea64fcf2f", + "postboxType": "ORDER_CONFIRMATION" + }, + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "42bd93b1-8f48-489f-b1e3-6eb955191d62", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/buy_new_no_eventType.json b/tests/events/buy_new_no_eventType.json new file mode 100644 index 00000000..fe76524b --- /dev/null +++ b/tests/events/buy_new_no_eventType.json @@ -0,0 +1,190 @@ +{ + "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", + "timestamp": "2025-10-10T19:29:43.928+0000", + "title": "NVIDIA", + "icon": "logos/US67066G1040/v2", + "avatar": { + "asset": "logos/US67066G1040/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -111.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "63c6df01-c99b-4bda-aec0-c8f996fbaae1" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "63c6df01-c99b-4bda-aec0-c8f996fbaae1", + "sections": [ + { + "title": "Du hast 111,00 € investiert", + "data": { + "icon": "logos/US67066G1040/v2", + "timestamp": "2025-10-10T19:29:43.928252Z", + "status": "executed" + }, + "action": { + "payload": "US67066G1040", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Kauf", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "NVIDIA", + "displayValue": { + "text": "NVIDIA" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,685102 × 160,56 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,685102", + "displayValue": { + "text": "0,685102" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "160,56 €", + "displayValue": { + "text": "160,56 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "110,00 €", + "displayValue": { + "text": "110,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "160,56 €", + "prefix": "0,685102 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "111,00 €", + "displayValue": { + "text": "111,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "085e4556-22b9-4af6-977b-f34fb90d1dee", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "2ea881b8-e8e7-4d4d-8df9-07d2d9cab6a8", + "postboxType": "EQUITIES_BUY_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/buy_no_eventType.json b/tests/events/buy_no_eventType.json new file mode 100644 index 00000000..8ecd13f4 --- /dev/null +++ b/tests/events/buy_no_eventType.json @@ -0,0 +1,162 @@ +{ + "id": "12345678", + "timestamp": "2024-02-20T16:32:07.731+0000", + "title": "Euro Stoxx 50 EUR (Dist)", + "icon": "logos/IE00B4K6B022/v2", + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -3002.8, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 3.002,80 € investiert", + "data": { + "icon": "logos/IE00B4K6B022/v2", + "subtitleText": null, + "timestamp": "2024-02-20T16:32:07.731+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "IE00B4K6B022" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Kauf", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Euro Stoxx 50 EUR (Dist)", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "60", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "50,03 €", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3.002,80 €", + "trend": null, + "action": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "20.02.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "", + "postboxType": "SECURITIES_SETTLEMENT", + "local filepath": "" + }, + { + "title": "Basisinformationsblatt", + "detail": "20.02.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "12345678", + "postboxType": "INFO", + "local filepath": "" + }, + { + "title": "Kosteninformation", + "detail": "20.02.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "12345678", + "postboxType": "COSTS_INFO_BUY_V2", + "local filepath": "" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/card_purchase_no_eventType.json b/tests/events/card_purchase_no_eventType.json new file mode 100644 index 00000000..d1a48ce1 --- /dev/null +++ b/tests/events/card_purchase_no_eventType.json @@ -0,0 +1,85 @@ +{ + "id": "a23a9d75-c017-518e-91f6-608c0ff39041", + "timestamp": "2024-11-22T09:09:09.123+0000", + "title": "Trade Republic Card", + "icon": "logos/bank_traderepublic/v2", + "avatar": { + "asset": "logos/bank_traderepublic/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -5.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "a23a9d75-c017-518e-91f6-608c0ff39041" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "a23a9d75-c017-518e-91f6-608c0ff39041", + "sections": [ + { + "title": "Du hast -5,00 € ausgegeben", + "data": { + "icon": { + "asset": "logos/bank_traderepublic/v2", + "badge": null + }, + "timestamp": "2024-11-22T09:09:09.123Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Bestellung Trade Republic Karte", + "detail": "22.11.2024", + "action": { + "payload": "https://example.com/timeline/postbox/2024/11/22/pb1732266550110904938819726779.pdf", + "type": "browserModal" + }, + "id": "bb3304f2-ab96-53e1-93d4-8aa6e2e55561", + "postboxType": "CARD_BILLING_INVOICE", + "local_filepath": "/home/max/Documents/admin/traderepublic/maxim/202601/Bestellung Trade Republic Karte/2024-11-22 09:09 Bestellung Trade Republic Karte - Trade Republic Card - None.pdf" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/card_refund.json b/tests/events/card_refund.json new file mode 100644 index 00000000..e931d879 --- /dev/null +++ b/tests/events/card_refund.json @@ -0,0 +1,88 @@ +{ + "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", + "timestamp": "2025-08-17T07:23:44.511+0000", + "title": "Decathlon", + "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", + "avatar": { + "asset": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 24.99, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535" + }, + "eventType": "card_refund", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", + "sections": [ + { + "title": "Du hast 24,99 € erhalten", + "data": { + "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", + "timestamp": "2025-08-17T07:23:44.511Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kartenerstattung", + "detail": { + "text": "Fertig", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "··5891", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Händler", + "detail": { + "text": "Decathlon", + "displayValue": { + "text": "Decathlon" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+24,99 €", + "displayValue": { + "text": "+24,99 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/card_refund_no_eventType.json b/tests/events/card_refund_no_eventType.json new file mode 100644 index 00000000..62721bc7 --- /dev/null +++ b/tests/events/card_refund_no_eventType.json @@ -0,0 +1,87 @@ +{ + "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", + "timestamp": "2025-08-17T07:23:44.511+0000", + "title": "Decathlon", + "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", + "avatar": { + "asset": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 24.99, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "bbb1c70e-d6b8-5c5f-86d4-7bf5b1890535", + "sections": [ + { + "title": "Du hast 24,99 € erhalten", + "data": { + "icon": "logos/merchant-a938525e-f1ec-4094-98f3-ad441e120e58/v2", + "timestamp": "2025-08-17T07:23:44.511Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kartenerstattung", + "detail": { + "text": "Fertig", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "··5891", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Händler", + "detail": { + "text": "Decathlon", + "displayValue": { + "text": "Decathlon" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+24,99 €", + "displayValue": { + "text": "+24,99 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/card_transaction.json b/tests/events/card_transaction.json new file mode 100644 index 00000000..0fc2a1ae --- /dev/null +++ b/tests/events/card_transaction.json @@ -0,0 +1,191 @@ +{ + "id": "b9641cbc-e892-590e-85ca-3530a461969e", + "timestamp": "2024-06-03T15:10:48.618+0000", + "title": "REWE", + "icon": "logos/merchant-4f7a75cd-9cbb-493f-b7fa-d259620b178b/v2", + "avatar": { + "asset": "logos/merchant-4f7a75cd-9cbb-493f-b7fa-d259620b178b/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -4.28, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "b9641cbc-e892-590e-85ca-3530a461969e" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "CARD_TRANSACTION", + "source": "timelineTransaction", + "details": { + "id": "b9641cbc-e892-590e-85ca-3530a461969e", + "sections": [ + { + "title": "Du hast 4,28 € ausgegeben", + "data": { + "icon": { + "asset": "logos/merchant-4f7a75cd-9cbb-493f-b7fa-d259620b178b/v2", + "badge": null + }, + "timestamp": "2024-06-03T15:10:48.618Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kartenzahlung", + "detail": { + "text": "Fertig", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Bezahlt mit", + "detail": { + "text": "Apple Pay", + "icon": "logos/bank_applepay/v2", + "action": { + "payload": { + "id": "850e7618-377e-4043-8956-4ab387928223", + "sections": [ + { + "title": "Bezahlt mit Apple Pay", + "type": "title" + }, + { + "data": [ + { + "title": "Name des Geräts", + "detail": { + "text": "Maximilians iPhone", + "displayValue": { + "text": "Maximilians iPhone" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gerätetyp", + "detail": { + "text": "Smartphone", + "displayValue": { + "text": "Smartphone" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Apple Pay-Karte", + "detail": { + "text": "··9419", + "displayValue": { + "text": "··9419" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "text": "Wenn du Apple Pay nutzt, erhält der Händler eine sichere, gerätespezifische Kartennummer. Deshalb kann es sein, dass die letzten vier Ziffern auf dem Beleg nicht mit denen auf deiner Karte übereinstimmen.", + "style": "disclaimer", + "type": "text" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Händler", + "detail": { + "text": "REWE", + "displayValue": { + "text": "REWE" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "4,28 €", + "displayValue": { + "text": "4,28 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Vorteile", + "data": [ + { + "title": "S&P 500 Information Tech USD (Acc)", + "detail": { + "title": "S&P 500 Information Tech USD (Acc)", + "timestamp": "2024-06-03T15:10:49.641732Z", + "amount": "0,05 €", + "icon": { + "asset": "logos/IE00B3WJKG14/v2", + "badge": null + }, + "status": "executed", + "action": { + "type": "benefitsSavebackOverview" + }, + "subtitle": "Saveback · 1%", + "type": "embeddedTimelineItem" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Transaktionsbeleg", + "action": { + "payload": { + "path": "api/v1/card/transactions/timelineDocuments/b9641cbc-e892-590e-85ca-3530a461969e", + "title": "Herunterladen", + "shareable": true + }, + "type": "authenticatedBrowserModal" + }, + "id": "b9641cbc-e892-590e-85ca-3530a461969e", + "postboxType": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/deposit.json b/tests/events/deposit.json new file mode 100644 index 00000000..655ce585 --- /dev/null +++ b/tests/events/deposit.json @@ -0,0 +1,78 @@ +{ + "id": "...", + "timestamp": "2024-06-03T17:07:26.374+0000", + "title": "My Name", + "icon": "logos/timeline_plus_circle/v2", + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 200.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "..." + }, + "eventType": "timeline_legacy_migrated_events", + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "...", + "sections": [ + { + "title": "Du hast 200,00 € erhalten", + "data": { + "icon": "logos/timeline_plus_circle/v2", + "subtitleText": null, + "timestamp": "2024-06-03T17:07:26.374+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Von", + "detail": { + "text": "My Name", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "...", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + } + ] + } +} diff --git a/tests/events/deposit_no_eventType.json b/tests/events/deposit_no_eventType.json new file mode 100644 index 00000000..7f63685f --- /dev/null +++ b/tests/events/deposit_no_eventType.json @@ -0,0 +1,77 @@ +{ + "id": "...", + "timestamp": "2024-06-03T17:07:26.374+0000", + "title": "My Name", + "icon": "logos/timeline_plus_circle/v2", + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 200.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "..." + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "...", + "sections": [ + { + "title": "Du hast 200,00 € erhalten", + "data": { + "icon": "logos/timeline_plus_circle/v2", + "subtitleText": null, + "timestamp": "2024-06-03T17:07:26.374+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Von", + "detail": { + "text": "My Name", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "...", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + } + ] + } +} diff --git a/tests/events/dividende_old.json b/tests/events/dividende_old.json new file mode 100644 index 00000000..cdace262 --- /dev/null +++ b/tests/events/dividende_old.json @@ -0,0 +1,304 @@ +{ + "id": "00000000-0000-0000-0000-000000000000", + "timestamp": "2024-12-31T23:59:59.999+0000", + "title": "MSCI World USD (Dist)", + "icon": "logos/LU0392494562/v2", + "avatar": { + "asset": "logos/LU0392494562/v2", + "badge": null + }, + "badge": null, + "subtitle": "Dividende", + "amount": { + "currency": "EUR", + "value": 30.21, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "00000000-0000-0000-0000-000000000000" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Du hast 30,21 € erhalten", + "data": { + "icon": "logos/LU0392494562/v2", + "subtitleText": null, + "timestamp": "2024-12-31T23:59:59.999+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Ereignis", + "detail": { + "text": "Ausschüttung", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "MSCI World USD (Dist)", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "32", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende je Aktie", + "detail": { + "text": "1,16 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "6,83 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 30,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Anteile", + "detail": { + "text": "32", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende je Aktie", + "detail": { + "text": "1,18 $", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wechselkurs", + "detail": { + "text": "1 € to 1,01932 $", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividende je Aktie", + "detail": { + "text": "1,16 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Dividendenzahlung", + "detail": { + "text": "+ 37,04 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Kapitalertragsteuer", + "detail": { + "text": "6,48 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Solidaritätszuschlag", + "detail": { + "text": "0,35 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "6,83 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Dividendenzahlung", + "detail": { + "text": "+ 37,04 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "6,83 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Gratis", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 30,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "31.12.2024", + "action": { + "type": "browserModal", + "payload": "dummy.pdf" + }, + "id": "00000000-0000-0000-0000-000000000000", + "postboxType": "INCOME" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/dividende_wahlweise.json b/tests/events/dividende_wahlweise.json new file mode 100644 index 00000000..86c30238 --- /dev/null +++ b/tests/events/dividende_wahlweise.json @@ -0,0 +1,134 @@ +{ + "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", + "timestamp": "2024-07-19T13:28:04.386+0000", + "title": "National Grid", + "icon": "logos/GB00BDR05C01/v2", + "avatar": { + "asset": "logos/GB00BDR05C01/v2", + "badge": null + }, + "badge": null, + "subtitle": "Dividende Wahlweise", + "amount": { + "currency": "EUR", + "value": 3.37, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "ba69948e-fd42-30d0-924f-f94241ee3fbc" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", + "sections": [ + { + "title": "Du hast 3,37 € erhalten", + "data": { + "icon": "logos/GB00BDR05C01/v2", + "timestamp": "2024-07-19T13:28:04.386Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Dividende Wahlweise", + "displayValue": { + "text": "Dividende Wahlweise" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "National Grid", + "displayValue": { + "text": "National Grid" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "4,65 €", + "displayValue": { + "text": "4,65 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-1,28 €", + "displayValue": { + "text": "-1,28 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3,37 €", + "displayValue": { + "text": "3,37 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "19.07.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "60f383fd-f2b0-4f2f-8639-ba41a4559926", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/dividende_wahlweise2.json b/tests/events/dividende_wahlweise2.json new file mode 100644 index 00000000..8789d06e --- /dev/null +++ b/tests/events/dividende_wahlweise2.json @@ -0,0 +1,76 @@ +{ + "id": "536a5126-a287-46c4-aee5-2c4746809d8c", + "timestamp": "2024-11-05T16:48:48.463+0000", + "title": "Unilever", + "icon": "logos/GB00B10RZP78/v2", + "subtitle": "Dividende. Cash oder Stockdividende?", + "action": { + "type": "timelineDetail", + "payload": "536a5126-a287-46c4-aee5-2c4746809d8c" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_ACTIVITY", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "536a5126-a287-46c4-aee5-2c4746809d8c", + "sections": [ + { + "title": "Du hast eine bevorstehende Dividendenzahlung", + "data": { + "icon": { + "asset": "logos/GB00B10RZP78/v2", + "badge": null + }, + "subtitleText": "5 Nov. 2024 · 16:48", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausstehend", + "functionalStyle": "PENDING", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Unilever", + "displayValue": { + "text": "Unilever", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dividende Wahlweise", + "detail": "05.11.2024", + "action": { + "payload": "https://example.com/pb173082660789413143540778822817.pdf", + "type": "browserModal" + }, + "id": "063c02e6-b4b0-4972-aea6-940df2ef0e24", + "postboxType": "CA_DIVIDEND_OPTION" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/dividende_wahlweise3.json b/tests/events/dividende_wahlweise3.json new file mode 100644 index 00000000..13a3f024 --- /dev/null +++ b/tests/events/dividende_wahlweise3.json @@ -0,0 +1,82 @@ +{ + "id": "5ba0acbb-df94-4965-a977-09739dcd36fa", + "timestamp": "2026-07-29T13:38:12.570+0000", + "title": "Rio Tinto", + "icon": "logos/AU000000RIO1/v2", + "subtitle": "Dividende. Cash oder Stockdividende?", + "action": { + "type": "timelineDetail", + "payload": "5ba0acbb-df94-4965-a977-09739dcd36fa" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_INSTRUCTION", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "5ba0acbb-df94-4965-a977-09739dcd36fa", + "sections": [ + { + "type": "header", + "title": "Du hast eine bevorstehende Dividendenzahlung", + "data": { + "status": "executed", + "icon": "logos/AU000000RIO1/v2", + "timestamp": "2026-07-29T13:38:12.570034Z" + } + }, + { + "type": "table", + "title": "Überblick", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Ausstehend", + "functionalStyle": "PENDING" + } + }, + { + "title": "Vermögenswert", + "style": "plain", + "detail": { + "type": "text", + "text": "Rio Tinto", + "displayValue": { + "text": "Rio Tinto" + } + } + }, + { + "title": "Ereignis", + "style": "plain", + "detail": { + "type": "text", + "text": "Dividende Wahlweise", + "displayValue": { + "text": "Dividende Wahlweise" + } + } + } + ] + }, + { + "type": "documents", + "title": "Dokumente", + "data": [ + { + "id": "cea3db89-128b-4069-b4f2-fd831b656231", + "title": "Dividende Wahlweise", + "action": { + "type": "browserModal", + "payload": "https://example.com/pb1785332375898143002307863481.pdf" + }, + "postboxType": "DIVIDEND_OPTION_NOTIFICATION" + } + ] + } + ] + } +} diff --git a/tests/events/dividende_wahlweise_no_eventType.json b/tests/events/dividende_wahlweise_no_eventType.json new file mode 100644 index 00000000..73654508 --- /dev/null +++ b/tests/events/dividende_wahlweise_no_eventType.json @@ -0,0 +1,133 @@ +{ + "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", + "timestamp": "2024-07-19T13:28:04.386+0000", + "title": "National Grid", + "icon": "logos/GB00BDR05C01/v2", + "avatar": { + "asset": "logos/GB00BDR05C01/v2", + "badge": null + }, + "badge": null, + "subtitle": "Dividende Wahlweise", + "amount": { + "currency": "EUR", + "value": 3.37, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "ba69948e-fd42-30d0-924f-f94241ee3fbc" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "ba69948e-fd42-30d0-924f-f94241ee3fbc", + "sections": [ + { + "title": "Du hast 3,37 € erhalten", + "data": { + "icon": "logos/GB00BDR05C01/v2", + "timestamp": "2024-07-19T13:28:04.386Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Dividende Wahlweise", + "displayValue": { + "text": "Dividende Wahlweise" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "National Grid", + "displayValue": { + "text": "National Grid" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "4,65 €", + "displayValue": { + "text": "4,65 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-1,28 €", + "displayValue": { + "text": "-1,28 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "3,37 €", + "displayValue": { + "text": "3,37 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "19.07.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "60f383fd-f2b0-4f2f-8639-ba41a4559926", + "postboxType": "CA_INCOME_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/incoming_transfer.json b/tests/events/incoming_transfer.json new file mode 100644 index 00000000..5ffd17fb --- /dev/null +++ b/tests/events/incoming_transfer.json @@ -0,0 +1,112 @@ +{ + "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", + "timestamp": "2024-09-02T17:49:12.516+0000", + "title": "Klaus Mustermann", + "icon": "logos/contacts-C-Lightblue/v2", + "avatar": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "badge": null, + "subtitle": "Fertig", + "amount": { + "currency": "EUR", + "value": 88.04, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439" + }, + "eventType": "INCOMING_TRANSFER", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", + "sections": [ + { + "title": "Du hast 88,04 € von Klaus Mustermann erhalten", + "data": { + "icon": "logos/contacts-C-Lightblue/v2", + "timestamp": "2024-09-02T17:49:12.516Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Referenz", + "detail": { + "text": "Referenz Text", + "displayValue": { + "text": "Referenz Text" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Absender", + "data": [ + { + "title": "Name", + "detail": { + "text": "Klaus Mustermann", + "displayValue": { + "text": "Klaus Mustermann" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "12345", + "displayValue": { + "text": "12345" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "detail": "02.09.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "53e0fc86-840d-4dba-8e74-2a56ab6b73d4", + "postboxType": "INCOMING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/incoming_transfer_delegation.json b/tests/events/incoming_transfer_delegation.json new file mode 100644 index 00000000..4e181cb3 --- /dev/null +++ b/tests/events/incoming_transfer_delegation.json @@ -0,0 +1,96 @@ +{ + "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", + "timestamp": "2024-09-10T13:18:31.478+0000", + "title": "Vorname Nachname", + "icon": "logos/contacts-M-Magenta/v2", + "badge": null, + "subtitle": "Fertig", + "amount": { + "currency": "EUR", + "value": 3000.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a" + }, + "eventType": "INCOMING_TRANSFER_DELEGATION", + "source": "timelineTransaction", + "details": { + "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", + "sections": [ + { + "title": "Du hast €3000.00 von Vorname Nachname erhalten", + "data": { + "icon": "logos/contacts-M-Magenta/v2", + "timestamp": "2024-09-10T13:18:31.475+0000", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + } + }, + { + "title": "Referenz", + "style": "plain", + "detail": { + "text": "Received by TradeRepublic", + "type": "text" + } + } + ], + "type": "table" + }, + { + "title": "Absender", + "data": [ + { + "title": "Name", + "style": "plain", + "detail": { + "text": "Vorname Nachname", + "type": "text" + } + }, + { + "title": "IBAN", + "style": "plain", + "detail": { + "text": "DEXX XXXX XXXX XXXX XXXX XX", + "type": "text" + } + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4254e648-e0da-4e0a-94be-c95499b35d9a", + "postboxType": "INCOMING_TRANSFER", + "local filepath": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/incoming_transfer_delegation_no_eventType.json b/tests/events/incoming_transfer_delegation_no_eventType.json new file mode 100644 index 00000000..7863f33d --- /dev/null +++ b/tests/events/incoming_transfer_delegation_no_eventType.json @@ -0,0 +1,95 @@ +{ + "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", + "timestamp": "2024-09-10T13:18:31.478+0000", + "title": "Vorname Nachname", + "icon": "logos/contacts-M-Magenta/v2", + "badge": null, + "subtitle": "Fertig", + "amount": { + "currency": "EUR", + "value": 3000.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a" + }, + "source": "timelineTransaction", + "details": { + "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", + "sections": [ + { + "title": "Du hast €3000.00 von Vorname Nachname erhalten", + "data": { + "icon": "logos/contacts-M-Magenta/v2", + "timestamp": "2024-09-10T13:18:31.475+0000", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + } + }, + { + "title": "Referenz", + "style": "plain", + "detail": { + "text": "Received by TradeRepublic", + "type": "text" + } + } + ], + "type": "table" + }, + { + "title": "Absender", + "data": [ + { + "title": "Name", + "style": "plain", + "detail": { + "text": "Vorname Nachname", + "type": "text" + } + }, + { + "title": "IBAN", + "style": "plain", + "detail": { + "text": "DEXX XXXX XXXX XXXX XXXX XX", + "type": "text" + } + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4254e648-e0da-4e0a-94be-c95499b35d9a", + "postboxType": "INCOMING_TRANSFER", + "local filepath": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/incoming_transfer_no_eventType.json b/tests/events/incoming_transfer_no_eventType.json new file mode 100644 index 00000000..f0356573 --- /dev/null +++ b/tests/events/incoming_transfer_no_eventType.json @@ -0,0 +1,111 @@ +{ + "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", + "timestamp": "2024-09-02T17:49:12.516+0000", + "title": "Klaus Mustermann", + "icon": "logos/contacts-C-Lightblue/v2", + "avatar": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "badge": null, + "subtitle": "Fertig", + "amount": { + "currency": "EUR", + "value": 88.04, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", + "sections": [ + { + "title": "Du hast 88,04 € von Klaus Mustermann erhalten", + "data": { + "icon": "logos/contacts-C-Lightblue/v2", + "timestamp": "2024-09-02T17:49:12.516Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Referenz", + "detail": { + "text": "Referenz Text", + "displayValue": { + "text": "Referenz Text" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Absender", + "data": [ + { + "title": "Name", + "detail": { + "text": "Klaus Mustermann", + "displayValue": { + "text": "Klaus Mustermann" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "12345", + "displayValue": { + "text": "12345" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "detail": "02.09.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "53e0fc86-840d-4dba-8e74-2a56ab6b73d4", + "postboxType": "INCOMING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/interest_payout_created.json b/tests/events/interest_payout_created.json new file mode 100644 index 00000000..0880d139 --- /dev/null +++ b/tests/events/interest_payout_created.json @@ -0,0 +1,313 @@ +{ + "id": "90234752-d42e-4820-85c8-91d7731dcbcd", + "timestamp": "2024-07-01T04:51:32.833+0000", + "title": "Zinsen", + "icon": "logos/timeline_interest_new/v2", + "avatar": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 13.56, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "90234752-d42e-4820-85c8-91d7731dcbcd" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "INTEREST_PAYOUT_CREATED", + "source": "timelineTransaction", + "details": { + "id": "90234752-d42e-4820-85c8-91d7731dcbcd", + "sections": [ + { + "title": "Du hast 13,56 EUR erhalten", + "data": { + "icon": "logos/timeline_interest_new/v2", + "subtitleText": null, + "timestamp": "2024-07-01T04:51:32.833+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "3.75% ist seit 12 Juni in Kraft", + "description": "", + "button": { + "title": "Mehr Details", + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "3.75% ist seit 12 Juni in Kraft", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Durchschnittssaldo", + "detail": { + "text": "6.277,70 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Jährliche Rate bis 11 Juni", + "detail": { + "text": "4 %", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Jährliche Rate ab 12 Juni", + "detail": { + "text": "3.75 %", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Angefallen", + "detail": { + "text": "18,77 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + } + }, + "action": null, + "type": "banner" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Durchschnittssaldo", + "detail": { + "text": "6.277,70 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Vermögenswert", + "detail": { + "text": "Guthaben", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Angefallen", + "detail": { + "text": "+ 18,77 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "5,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 13,56 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Kapitalertragsteuer", + "detail": { + "text": "4,60 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Kirchensteuer", + "detail": { + "text": "0,36 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Solidaritätszuschlag", + "detail": { + "text": "0,25 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "5,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Angefallen", + "detail": { + "text": "+ 18,77 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "5,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 13,56 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "01.07.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "4c97b25f-227f-4b5e-b21a-4bffe353fa5e", + "postboxType": "INTEREST_PAYOUT_INVOICE" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/ipo-spacex.json b/tests/events/ipo-spacex.json new file mode 100644 index 00000000..a9060a40 --- /dev/null +++ b/tests/events/ipo-spacex.json @@ -0,0 +1,198 @@ +{ + "id": "e742c3cb-c17c-4905-845c-ab42189da291", + "timestamp": "2026-06-06T04:20:02.120+0000", + "title": "SpaceX", + "icon": "logos/US84615Q1031/v2", + "avatar": { + "asset": "logos/US84615Q1031/v2", + "badge": null + }, + "badge": null, + "subtitle": "IPO", + "amount": { + "currency": "EUR", + "value": -33.33, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "e742c3cb-c17c-4905-845c-ab42189da291" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "IPO_TRADE_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "e742c3cb-c17c-4905-845c-ab42189da291", + "sections": [ + { + "title": "Du hast 33,33 € investiert", + "data": { + "icon": { + "asset": "logos/US84615Q1031/v2", + "badge": null + }, + "timestamp": "2026-06-06T04:20:02.081244Z", + "status": "executed" + }, + "action": { + "payload": "US84615Q1031", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Deine Zuteilung für SpaceX", + "description": "Du hast SpaceX Aktien im Wert von 32,33 € erhalten. Nicht investiertes Geld wurde erstattet.", + "type": "banner" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "IPO", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "SpaceX", + "displayValue": { + "text": "SpaceX" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,276891 × 116,762806 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktienkurs", + "detail": { + "text": "116,762806 €", + "displayValue": { + "text": "116,762806 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien", + "detail": { + "text": "0,276891", + "displayValue": { + "text": "0,276891" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "32,33 €", + "displayValue": { + "text": "32,33 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "116,762806 €", + "prefix": "0,276891 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "33,33 €", + "displayValue": { + "text": "33,33 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "1ae44e9f-08ae-46a4-80da-19e6c84f6a1c", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "a1566adc-c184-40f3-8062-87b3cf60197d", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Prospekt", + "action": { + "payload": "https://assets.traderepublic.com/assets/files/TR_EU_Prospectus_yD8uWbXoKs2.pdf", + "type": "browserModal" + }, + "id": "4b3b1e09-fd8d-38d7-9291-00de9b6a2cd1", + "postboxType": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/junior_p2p_transfer.json b/tests/events/junior_p2p_transfer.json new file mode 100644 index 00000000..b0160497 --- /dev/null +++ b/tests/events/junior_p2p_transfer.json @@ -0,0 +1,96 @@ +{ + "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", + "timestamp": "2025-09-17T19:35:32.658+0000", + "title": "Maria Mueller", + "icon": "logos/contacts-C-Grey/v2", + "avatar": { + "asset": "logos/contacts-C-Grey/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -50.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "324a06e3-9693-473e-a22c-e9f3a14b8951" + }, + "eventType": "junior_p2p_transfer", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", + "sections": [ + { + "title": "Du hast 50,00 € gesendet", + "data": { + "icon": "logos/contacts-C-Grey/v2", + "timestamp": "2025-09-17T19:35:32.656185Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Überweisen", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Empfänger", + "detail": { + "text": "Maria Mueller", + "trend": "positive", + "displayValue": { + "text": "Maria Mueller" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "50,00 €", + "trend": "positive", + "displayValue": { + "text": "50,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "data": { + "text": "Betreff" + }, + "type": "note" + } + ] + } +} diff --git a/tests/events/junior_p2p_transfer_no_eventType.json b/tests/events/junior_p2p_transfer_no_eventType.json new file mode 100644 index 00000000..4573dd31 --- /dev/null +++ b/tests/events/junior_p2p_transfer_no_eventType.json @@ -0,0 +1,95 @@ +{ + "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", + "timestamp": "2025-09-17T19:35:32.658+0000", + "title": "Maria Mueller", + "icon": "logos/contacts-C-Grey/v2", + "avatar": { + "asset": "logos/contacts-C-Grey/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -50.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "324a06e3-9693-473e-a22c-e9f3a14b8951" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", + "sections": [ + { + "title": "Du hast 50,00 € gesendet", + "data": { + "icon": "logos/contacts-C-Grey/v2", + "timestamp": "2025-09-17T19:35:32.656185Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Überweisen", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Empfänger", + "detail": { + "text": "Maria Mueller", + "trend": "positive", + "displayValue": { + "text": "Maria Mueller" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "50,00 €", + "trend": "positive", + "displayValue": { + "text": "50,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "data": { + "text": "Betreff" + }, + "type": "note" + } + ] + } +} diff --git a/tests/events/kartenzahlung.json b/tests/events/kartenzahlung.json new file mode 100644 index 00000000..ffbcb867 --- /dev/null +++ b/tests/events/kartenzahlung.json @@ -0,0 +1,103 @@ +{ + "id": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6", + "timestamp": "2025-10-21T17:30:01.281+0000", + "title": "Coop Pronto", + "icon": "logos/merchant-fallback-groceries/v2", + "avatar": { + "asset": "logos/merchant-fallback-groceries/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -12.16, + "fractionDigits": 2 + }, + "subAmount": { + "currency": "CHF", + "value": -11.2, + "fractionDigits": 2 + }, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6" + }, + "eventType": "card_successful_transaction", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6", + "sections": [ + { + "title": "Du hast 12,16 € ausgegeben", + "data": { + "icon": "logos/merchant-fallback-groceries/v2", + "timestamp": "2025-10-21T17:30:01.281Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kartenzahlung", + "detail": { + "text": "Fertig", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "··5891", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Händler", + "detail": { + "text": "Coop Pronto", + "displayValue": { + "text": "Coop Pronto" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Betrag", + "detail": { + "text": "11,20 CHF", + "displayValue": { + "text": "11,20 CHF" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "12,16 €", + "displayValue": { + "text": "12,16 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/kartenzahlung_no_eventType.json b/tests/events/kartenzahlung_no_eventType.json new file mode 100644 index 00000000..2a282c9a --- /dev/null +++ b/tests/events/kartenzahlung_no_eventType.json @@ -0,0 +1,87 @@ +{ + "id": "809a35a2-99d6-5fcd-ba87-fd618f90710a", + "timestamp": "2025-11-05T11:00:07.718+0000", + "title": "Baecker", + "icon": "logos/merchant-fallback-restaurants/v2", + "avatar": { + "asset": "logos/merchant-fallback-restaurants/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -2.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "809a35a2-99d6-5fcd-ba87-fd618f90710a" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "809a35a2-99d6-5fcd-ba87-fd618f90710a", + "sections": [ + { + "title": "Du hast 2,00 € ausgegeben", + "data": { + "icon": "logos/merchant-fallback-restaurants/v2", + "timestamp": "2025-11-05T11:00:07.718Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kartenzahlung", + "detail": { + "text": "Fertig", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "··5891", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Händler", + "detail": { + "text": "Baecker", + "displayValue": { + "text": "Baecker" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "2,00 €", + "displayValue": { + "text": "2,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/kartenzahlung_null_eventType.json b/tests/events/kartenzahlung_null_eventType.json new file mode 100644 index 00000000..c4eb44d4 --- /dev/null +++ b/tests/events/kartenzahlung_null_eventType.json @@ -0,0 +1,103 @@ +{ + "id": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6", + "timestamp": "2025-10-21T17:30:01.281+0000", + "title": "Coop Pronto", + "icon": "logos/merchant-fallback-groceries/v2", + "avatar": { + "asset": "logos/merchant-fallback-groceries/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -12.16, + "fractionDigits": 2 + }, + "subAmount": { + "currency": "CHF", + "value": -11.2, + "fractionDigits": 2 + }, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6" + }, + "eventType": null, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6", + "sections": [ + { + "title": "Du hast 12,16 € ausgegeben", + "data": { + "icon": "logos/merchant-fallback-groceries/v2", + "timestamp": "2025-10-21T17:30:01.281Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kartenzahlung", + "detail": { + "text": "Fertig", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "··5891", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Händler", + "detail": { + "text": "Coop Pronto", + "displayValue": { + "text": "Coop Pronto" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Betrag", + "detail": { + "text": "11,20 CHF", + "displayValue": { + "text": "11,20 CHF" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "12,16 €", + "displayValue": { + "text": "12,16 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/kauforder_abgelehnt.json b/tests/events/kauforder_abgelehnt.json new file mode 100644 index 00000000..31a9244c --- /dev/null +++ b/tests/events/kauforder_abgelehnt.json @@ -0,0 +1,99 @@ +{ + "id": "7385dbae-c8c4-4e59-bc40-da708a074e96", + "timestamp": "2026-03-03T11:35:17.995+0000", + "title": "Silver 3x Lev USD (Acc)", + "icon": "logos/IE00B7XD2195/v2", + "subtitle": "Kauforder abgelehnt", + "action": { + "type": "timelineDetail", + "payload": "7385dbae-c8c4-4e59-bc40-da708a074e96" + }, + "eventType": "TRADING_ORDER_REJECTED", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "7385dbae-c8c4-4e59-bc40-da708a074e96", + "sections": [ + { + "title": "Deine Kauforder wurde abgelehnt", + "data": { + "icon": "logos/IE00B7XD2195/v2", + "timestamp": "2026-03-03T11:34:47.966Z", + "status": "executed" + }, + "action": { + "payload": "IE00B7XD2195", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Abgelehnt", + "functionalStyle": "CANCELED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Silver 3x Lev USD (Acc)", + "displayValue": { + "text": "Silver 3x Lev USD (Acc)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,505689 × --", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,505689", + "displayValue": { + "text": "0,505689" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "--", + "prefix": "0,505689 × " + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/legacy_verkauforder_neu_abgerechnet.json b/tests/events/legacy_verkauforder_neu_abgerechnet.json new file mode 100644 index 00000000..9e69f572 --- /dev/null +++ b/tests/events/legacy_verkauforder_neu_abgerechnet.json @@ -0,0 +1,303 @@ +{ + "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", + "timestamp": "2025-02-21T11:14:54.026+0000", + "title": "Marie Brizard Wine and Spirits", + "icon": "logos/FR0000060873/v2", + "avatar": { + "asset": "logos/FR0000060873/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit Verkauf-Order neu abgerechnet", + "amount": { + "currency": "EUR", + "value": 91.34, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e" + }, + "eventType": "timeline_legacy_migrated_events", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", + "sections": [ + { + "title": "Du hast 91,34 € erhalten", + "data": { + "icon": "logos/FR0000060873/v2", + "subtitleText": null, + "timestamp": "2025-02-21T11:14:54.026+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "FR0000060873" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Limit Verkauf", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Marie Brizard Wine and Spirits", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "8,48 %", + "trend": "negative", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verlust", + "detail": { + "text": "8,56 €", + "trend": "negative", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "horizontalTable" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "27", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "3,42 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 91,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Anteile", + "detail": { + "text": "27", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "3,42 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Order", + "detail": { + "text": "+ 92,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Order", + "detail": { + "text": "+ 92,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 91,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung 2", + "detail": "27.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "b0f0a8e4-b8cf-4878-aa70-3e772d163f49", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 1", + "detail": "21.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "42b598ad-9c8e-440e-868e-37cfc3c44dcc", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Auftragsbestätigung", + "detail": "21.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "0f9ee818-3567-4a82-8986-448e62c4b92d", + "postboxType": "CONFIRM_ORDER_CREATE_V2" + }, + { + "title": "Kosteninformation", + "detail": "21.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "4868af5a-277c-4f31-a8a9-e703e5f24fb2", + "postboxType": "COSTS_INFO_SELL_V2" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/legacy_verkauforder_neu_abgerechnet_no_eventType.json b/tests/events/legacy_verkauforder_neu_abgerechnet_no_eventType.json new file mode 100644 index 00000000..3ff9dc94 --- /dev/null +++ b/tests/events/legacy_verkauforder_neu_abgerechnet_no_eventType.json @@ -0,0 +1,302 @@ +{ + "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", + "timestamp": "2025-02-21T11:14:54.026+0000", + "title": "Marie Brizard Wine and Spirits", + "icon": "logos/FR0000060873/v2", + "avatar": { + "asset": "logos/FR0000060873/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit Verkauf-Order neu abgerechnet", + "amount": { + "currency": "EUR", + "value": 91.34, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", + "sections": [ + { + "title": "Du hast 91,34 € erhalten", + "data": { + "icon": "logos/FR0000060873/v2", + "subtitleText": null, + "timestamp": "2025-02-21T11:14:54.026+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "FR0000060873" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Limit Verkauf", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Marie Brizard Wine and Spirits", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "8,48 %", + "trend": "negative", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verlust", + "detail": { + "text": "8,56 €", + "trend": "negative", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "horizontalTable" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "27", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "3,42 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 91,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Anteile", + "detail": { + "text": "27", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "3,42 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Order", + "detail": { + "text": "+ 92,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Order", + "detail": { + "text": "+ 92,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 91,34 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung 2", + "detail": "27.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "b0f0a8e4-b8cf-4878-aa70-3e772d163f49", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 1", + "detail": "21.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "42b598ad-9c8e-440e-868e-37cfc3c44dcc", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Auftragsbestätigung", + "detail": "21.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "0f9ee818-3567-4a82-8986-448e62c4b92d", + "postboxType": "CONFIRM_ORDER_CREATE_V2" + }, + { + "title": "Kosteninformation", + "detail": "21.02.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "4868af5a-277c-4f31-a8a9-e703e5f24fb2", + "postboxType": "COSTS_INFO_SELL_V2" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/legacy_zinsen.json b/tests/events/legacy_zinsen.json new file mode 100644 index 00000000..d9d2aff9 --- /dev/null +++ b/tests/events/legacy_zinsen.json @@ -0,0 +1,252 @@ +{ + "id": "de16f265-0c83-4c40-86b8-9926be9650ae", + "timestamp": "2024-09-01T16:39:48.119+0000", + "title": "Zinsen", + "icon": "logos/timeline_interest_new/v2", + "avatar": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 11.76, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "de16f265-0c83-4c40-86b8-9926be9650ae" + }, + "eventType": "timeline_legacy_migrated_events", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "de16f265-0c83-4c40-86b8-9926be9650ae", + "sections": [ + { + "title": "Du hast 11,76 EUR erhalten", + "data": { + "icon": "logos/timeline_interest_new/v2", + "subtitleText": null, + "timestamp": "2024-09-01T16:39:48.119+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Durchschnittssaldo", + "detail": { + "text": "5.036,99 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Jahressatz", + "detail": { + "text": "3.75 %", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Vermögenswert", + "detail": { + "text": "Guthaben", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Angefallen", + "detail": { + "text": "+ 16,27 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "4,51 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 11,76 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Kapitalertragsteuer", + "detail": { + "text": "3,99 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Kirchensteuer", + "detail": { + "text": "0,31 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Solidaritätszuschlag", + "detail": { + "text": "0,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "4,51 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Angefallen", + "detail": { + "text": "+ 16,27 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "4,51 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 11,76 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "01.09.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "e4850346-b2a5-43ee-96ea-e093750badff", + "postboxType": "INTEREST_PAYOUT_INVOICE" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/legacy_zinsen_no_eventType.json b/tests/events/legacy_zinsen_no_eventType.json new file mode 100644 index 00000000..3b89dfc1 --- /dev/null +++ b/tests/events/legacy_zinsen_no_eventType.json @@ -0,0 +1,251 @@ +{ + "id": "de16f265-0c83-4c40-86b8-9926be9650ae", + "timestamp": "2024-09-01T16:39:48.119+0000", + "title": "Zinsen", + "icon": "logos/timeline_interest_new/v2", + "avatar": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 11.76, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "de16f265-0c83-4c40-86b8-9926be9650ae" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "de16f265-0c83-4c40-86b8-9926be9650ae", + "sections": [ + { + "title": "Du hast 11,76 EUR erhalten", + "data": { + "icon": "logos/timeline_interest_new/v2", + "subtitleText": null, + "timestamp": "2024-09-01T16:39:48.119+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Durchschnittssaldo", + "detail": { + "text": "5.036,99 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Jahressatz", + "detail": { + "text": "3.75 %", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Vermögenswert", + "detail": { + "text": "Guthaben", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Angefallen", + "detail": { + "text": "+ 16,27 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "4,51 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 11,76 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Kapitalertragsteuer", + "detail": { + "text": "3,99 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Kirchensteuer", + "detail": { + "text": "0,31 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Solidaritätszuschlag", + "detail": { + "text": "0,21 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "4,51 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Angefallen", + "detail": { + "text": "+ 16,27 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "4,51 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 11,76 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "01.09.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "e4850346-b2a5-43ee-96ea-e093750badff", + "postboxType": "INTEREST_PAYOUT_INVOICE" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/limit-sell-order.json b/tests/events/limit-sell-order.json new file mode 100644 index 00000000..d3205a22 --- /dev/null +++ b/tests/events/limit-sell-order.json @@ -0,0 +1,252 @@ +{ + "id": "12345678", + "timestamp": "2025-05-20T08:03:45.106+0000", + "title": "D-Wave Quantum", + "icon": "logos/US26740W1099/v2", + "badge": null, + "subtitle": "Limit-Sell-Order", + "amount": { + "currency": "EUR", + "value": 114.91, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "eventType": "trading_trade_executed", + "cashAccountNumber": "12345678", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 114,91 € erhalten", + "data": { + "icon": "logos/US26740W1099/v2", + "subtitleText": null, + "timestamp": "2025-05-20T08:03:45.106+0000", + "status": "executed" + }, + "action": { + "payload": "US26740W1099", + "type": "instrumentDetail", + "overrideAction": null + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Limit Order", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "action": null, + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "D-Wave Quantum", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "", + "trend": null, + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Aktien", + "detail": { + "text": "11", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "12,12 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "133,27 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + } + ] + }, + "type": "infoPage", + "overrideAction": null + }, + "displayValue": { + "text": "12,12 €", + "prefix": "11 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "17,36 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "114,91 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "89,42 %", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "62,44 €", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Auftragsbestätigung", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "12345678", + "postboxType": "ORDER_CONFIRMATION" + }, + { + "title": "Kosteninformation", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "12345678", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Abrechnung", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "c973a255-89aa-48ba-931a-4ff94fbb56ec", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/limit-sell-order_no_eventType.json b/tests/events/limit-sell-order_no_eventType.json new file mode 100644 index 00000000..87aab866 --- /dev/null +++ b/tests/events/limit-sell-order_no_eventType.json @@ -0,0 +1,240 @@ +{ + "id": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf", + "timestamp": "2025-11-05T12:03:19.648+0000", + "title": "Teva Pharmaceutical Industries (ADR)", + "icon": "logos/US8816242098/v2", + "avatar": { + "asset": "logos/US8816242098/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit-Sell-Order", + "amount": { + "currency": "EUR", + "value": 139.74, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf" + }, + "cashAccountNumber": "", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf", + "sections": [ + { + "title": "Du hast 139,74 € erhalten", + "data": { + "icon": "logos/US8816242098/v2", + "timestamp": "2025-11-05T12:03:19.648Z", + "status": "executed" + }, + "action": { + "payload": "US8816242098", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Limit Order", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Teva Pharmaceutical Industries (ADR)", + "displayValue": { + "text": "Teva Pharmaceutical Industries (ADR)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "8 × 18,55 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "8", + "displayValue": { + "text": "8" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "18,55 €", + "displayValue": { + "text": "18,55 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "148,40 €", + "displayValue": { + "text": "148,40 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "18,55 €", + "prefix": "8 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "7,66 €", + "displayValue": { + "text": "7,66 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "139,74 €", + "displayValue": { + "text": "139,74 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "22,96 %", + "trend": "positive", + "displayValue": { + "text": "22,96 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "27,52 €", + "trend": "positive", + "displayValue": { + "text": "27,52 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "eb32bdce-1b2a-4a56-882a-24cb814ee867", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "96eccb8a-cca0-47aa-a2aa-ee5427d8eb26", + "postboxType": "ORDER_CONFIRMATION" + }, + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "88b2b6cc-aa38-46e4-bb93-6b54b1dfee32", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/limit-sell-order_old.json b/tests/events/limit-sell-order_old.json new file mode 100644 index 00000000..b05dec67 --- /dev/null +++ b/tests/events/limit-sell-order_old.json @@ -0,0 +1,225 @@ +{ + "id": "12345678", + "timestamp": "2025-05-14T07:01:32.079+0000", + "title": "Daimler Truck Holding", + "icon": "logos/DE000DTR0CK8/v2", + "badge": null, + "subtitle": "Limit-Sell-Order", + "amount": { + "currency": "EUR", + "value": 119.37, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "eventType": "trading_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 119,37 € erhalten", + "data": { + "icon": "logos/DE000DTR0CK8/v2", + "subtitleText": null, + "timestamp": "2025-05-14T07:01:32.079+0000", + "status": "executed" + }, + "action": { + "payload": "DE000DTR0CK8", + "type": "instrumentDetail", + "overrideAction": null + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "action": null, + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Limit Order", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Daimler Truck Holding", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "0,43 %", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "0,51 €", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "horizontalTable" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "3", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "40,17 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,14 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "119,37 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "dd153475-fc29-4ab0-ba00-3ce83247de39", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "ef30342c-838f-4b1f-9ed8-c9d629f3d3a9", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "e1fd1815-65fd-43da-9d80-c51d8aa8eb01", + "postboxType": "ORDER_CONFIRMATION" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/limit-sell-order_old_no_eventType.json b/tests/events/limit-sell-order_old_no_eventType.json new file mode 100644 index 00000000..af2e0f60 --- /dev/null +++ b/tests/events/limit-sell-order_old_no_eventType.json @@ -0,0 +1,224 @@ +{ + "id": "12345678", + "timestamp": "2025-05-14T07:01:32.079+0000", + "title": "Daimler Truck Holding", + "icon": "logos/DE000DTR0CK8/v2", + "badge": null, + "subtitle": "Limit-Sell-Order", + "amount": { + "currency": "EUR", + "value": 119.37, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 119,37 € erhalten", + "data": { + "icon": "logos/DE000DTR0CK8/v2", + "subtitleText": null, + "timestamp": "2025-05-14T07:01:32.079+0000", + "status": "executed" + }, + "action": { + "payload": "DE000DTR0CK8", + "type": "instrumentDetail", + "overrideAction": null + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "action": null, + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Limit Order", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Daimler Truck Holding", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "0,43 %", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "0,51 €", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "horizontalTable" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Aktien", + "detail": { + "text": "3", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "40,17 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,14 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "119,37 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "dd153475-fc29-4ab0-ba00-3ce83247de39", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "ef30342c-838f-4b1f-9ed8-c9d629f3d3a9", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "detail": null, + "action": { + "payload": "", + "type": "browserModal", + "overrideAction": null + }, + "id": "e1fd1815-65fd-43da-9d80-c51d8aa8eb01", + "postboxType": "ORDER_CONFIRMATION" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/neues_geraet.json b/tests/events/neues_geraet.json new file mode 100644 index 00000000..6005727e --- /dev/null +++ b/tests/events/neues_geraet.json @@ -0,0 +1,12 @@ +{ + "id": "5f054afa-2eb5-409b-805d-6d3d9d45ffad", + "timestamp": "2026-02-18T17:45:01.178+0000", + "title": "Neues Gerät", + "icon": "logos/timeline_computers/v2", + "subtitle": null, + "action": null, + "eventType": null, + "hidden": false, + "deleted": false, + "source": "timelineActivity" +} diff --git a/tests/events/outgoing_transfer.json b/tests/events/outgoing_transfer.json new file mode 100644 index 00000000..7aa82a9d --- /dev/null +++ b/tests/events/outgoing_transfer.json @@ -0,0 +1,121 @@ +{ + "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", + "timestamp": "2024-07-21T09:35:47.370+0000", + "title": "Hans Mustermann", + "icon": "logos/contacts-C-Lightblue/v2", + "avatar": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "badge": null, + "subtitle": "Gesendet", + "amount": { + "currency": "EUR", + "value": -50.3, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "01b0c632-47de-4beb-9b09-6eb8ac42e871" + }, + "eventType": "OUTGOING_TRANSFER", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", + "sections": [ + { + "title": "Du hast -50,30 € an Hans Mustermann gesendet", + "data": { + "icon": "logos/contacts-C-Lightblue/v2", + "timestamp": "2024-07-21T09:35:47.37Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Gesendet mit", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Referenz", + "detail": { + "text": "Sent via Trade Republic", + "displayValue": { + "text": "Sent via Trade Republic" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Empfänger", + "data": [ + { + "title": "Name", + "detail": { + "text": "Hans Mustermann", + "displayValue": { + "text": "Hans Mustermann" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "DE12345", + "displayValue": { + "text": "DE12345" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "detail": "22.07.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "325de7ad-a645-442f-bb14-09a4de5f7fbf", + "postboxType": "OUTGOING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/outgoing_transfer_delegation.json b/tests/events/outgoing_transfer_delegation.json new file mode 100644 index 00000000..10476a65 --- /dev/null +++ b/tests/events/outgoing_transfer_delegation.json @@ -0,0 +1,171 @@ +{ + "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", + "timestamp": "2025-08-18T12:16:06.806+0000", + "title": "Nina", + "icon": "logos/contacts-N-Grey/v2", + "avatar": { + "asset": "logos/contacts-N-Grey/v2", + "badge": null + }, + "badge": null, + "subtitle": "Gesendet", + "amount": { + "currency": "EUR", + "value": -67.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "e5f930fc-4bb0-47de-919d-94a2d0b3f438" + }, + "eventType": "OUTGOING_TRANSFER_DELEGATION", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", + "sections": [ + { + "title": "Du hast 67,00 € an Nina gesendet", + "data": { + "icon": "logos/contacts-N-Grey/v2", + "timestamp": "2025-08-18T12:16:06.803132Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Überweisung", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Empfänger", + "detail": { + "text": "Nina", + "displayValue": { + "text": "Nina" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "", + "action": { + "payload": { + "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", + "sections": [ + { + "title": "IBAN", + "data": [ + { + "title": "", + "detail": { + "icon": "logos/bank_default/v2", + "style": "highlighted", + "type": "listItemAvatarDefault" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "67,00 €", + "displayValue": { + "text": "67,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "data": { + "text": "text" + }, + "type": "note" + }, + { + "title": "Empfänger", + "data": [ + { + "title": "Empfänger", + "detail": { + "text": "Nina", + "displayValue": { + "text": "Nina" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "", + "displayValue": { + "text": "" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "194eed58-5c67-4b4c-8e62-9d7814038fdf", + "postboxType": "OUTGOING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/outgoing_transfer_delegation_no_eventType.json b/tests/events/outgoing_transfer_delegation_no_eventType.json new file mode 100644 index 00000000..a30e2e03 --- /dev/null +++ b/tests/events/outgoing_transfer_delegation_no_eventType.json @@ -0,0 +1,170 @@ +{ + "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", + "timestamp": "2025-08-18T12:16:06.806+0000", + "title": "Nina", + "icon": "logos/contacts-N-Grey/v2", + "avatar": { + "asset": "logos/contacts-N-Grey/v2", + "badge": null + }, + "badge": null, + "subtitle": "Gesendet", + "amount": { + "currency": "EUR", + "value": -67.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "e5f930fc-4bb0-47de-919d-94a2d0b3f438" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", + "sections": [ + { + "title": "Du hast 67,00 € an Nina gesendet", + "data": { + "icon": "logos/contacts-N-Grey/v2", + "timestamp": "2025-08-18T12:16:06.803132Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Überweisung", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Empfänger", + "detail": { + "text": "Nina", + "displayValue": { + "text": "Nina" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "", + "action": { + "payload": { + "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", + "sections": [ + { + "title": "IBAN", + "data": [ + { + "title": "", + "detail": { + "icon": "logos/bank_default/v2", + "style": "highlighted", + "type": "listItemAvatarDefault" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "67,00 €", + "displayValue": { + "text": "67,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "data": { + "text": "text" + }, + "type": "note" + }, + { + "title": "Empfänger", + "data": [ + { + "title": "Empfänger", + "detail": { + "text": "Nina", + "displayValue": { + "text": "Nina" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "", + "displayValue": { + "text": "" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "194eed58-5c67-4b4c-8e62-9d7814038fdf", + "postboxType": "OUTGOING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/outgoing_transfer_legacy.json b/tests/events/outgoing_transfer_legacy.json new file mode 100644 index 00000000..13e902f8 --- /dev/null +++ b/tests/events/outgoing_transfer_legacy.json @@ -0,0 +1,78 @@ +{ + "id": "...", + "timestamp": "2025-04-11T06:44:43.596+0000", + "title": "My Name", + "icon": "logos/timeline_minus_circle/v2", + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -750.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "..." + }, + "eventType": "timeline_legacy_migrated_events", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "...", + "sections": [ + { + "title": "Du hast 750,00 € gesendet", + "data": { + "icon": "logos/timeline_minus_circle/v2", + "subtitleText": null, + "timestamp": "2025-04-11T06:44:43.596+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "An", + "detail": { + "text": "My Name", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "...", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + } + ] + } +} diff --git a/tests/events/outgoing_transfer_legacy_no_eventType.json b/tests/events/outgoing_transfer_legacy_no_eventType.json new file mode 100644 index 00000000..7b43c095 --- /dev/null +++ b/tests/events/outgoing_transfer_legacy_no_eventType.json @@ -0,0 +1,77 @@ +{ + "id": "...", + "timestamp": "2025-04-11T06:44:43.596+0000", + "title": "My Name", + "icon": "logos/timeline_minus_circle/v2", + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": -750.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "..." + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "...", + "sections": [ + { + "title": "Du hast 750,00 € gesendet", + "data": { + "icon": "logos/timeline_minus_circle/v2", + "subtitleText": null, + "timestamp": "2025-04-11T06:44:43.596+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "An", + "detail": { + "text": "My Name", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "...", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + } + ] + } +} diff --git a/tests/events/outgoing_transfer_no_eventType.json b/tests/events/outgoing_transfer_no_eventType.json new file mode 100644 index 00000000..cf31a10d --- /dev/null +++ b/tests/events/outgoing_transfer_no_eventType.json @@ -0,0 +1,120 @@ +{ + "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", + "timestamp": "2024-07-21T09:35:47.370+0000", + "title": "Hans Mustermann", + "icon": "logos/contacts-C-Lightblue/v2", + "avatar": { + "asset": "logos/contacts-C-Lightblue/v2", + "badge": null + }, + "badge": null, + "subtitle": "Gesendet", + "amount": { + "currency": "EUR", + "value": -50.3, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "01b0c632-47de-4beb-9b09-6eb8ac42e871" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", + "sections": [ + { + "title": "Du hast -50,30 € an Hans Mustermann gesendet", + "data": { + "icon": "logos/contacts-C-Lightblue/v2", + "timestamp": "2024-07-21T09:35:47.37Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Gesendet mit", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Referenz", + "detail": { + "text": "Sent via Trade Republic", + "displayValue": { + "text": "Sent via Trade Republic" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Empfänger", + "data": [ + { + "title": "Name", + "detail": { + "text": "Hans Mustermann", + "displayValue": { + "text": "Hans Mustermann" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "IBAN", + "detail": { + "text": "DE12345", + "displayValue": { + "text": "DE12345" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Transaktionsbestätigung", + "detail": "22.07.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "325de7ad-a645-442f-bb14-09a4de5f7fbf", + "postboxType": "OUTGOING_TRANSFER" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/payment_inbound_credit_card.json b/tests/events/payment_inbound_credit_card.json new file mode 100644 index 00000000..9b6d020a --- /dev/null +++ b/tests/events/payment_inbound_credit_card.json @@ -0,0 +1,113 @@ +{ + "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", + "timestamp": "2022-08-27T05:06:30.471+0000", + "title": "Einzahlung", + "icon": "logos/bank_mastercard/v2", + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 1000.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "5b04b073-c06f-4ab1-bd01-de51b56162dc" + }, + "eventType": "PAYMENT_INBOUND_CREDIT_CARD", + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", + "sections": [ + { + "title": "Du hast 1.000,00 € über Kreditkarte hinzugefügt", + "data": { + "icon": "logos/bank_mastercard/v2", + "subtitleText": null, + "timestamp": "2022-08-27T05:06:30.471+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "·· 7431", + "icon": "logos/bank_mastercard/v2", + "type": "iconWithText" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Gebühr", + "detail": { + "text": "7,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Betrag", + "detail": { + "text": "1.000,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Einzahlung", + "detail": "27.08.2022", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "4f6f159f-08f1-4573-9b69-2418d57ca37a", + "postboxType": "PAYMENT_INBOUND_INVOICE", + "local_filepath": "" + } + ], + "action": null, + "type": "documents" + } + ] + }, + "has_docs": true +} diff --git a/tests/events/payment_inbound_credit_card_no_eventType.json b/tests/events/payment_inbound_credit_card_no_eventType.json new file mode 100644 index 00000000..852f43c5 --- /dev/null +++ b/tests/events/payment_inbound_credit_card_no_eventType.json @@ -0,0 +1,112 @@ +{ + "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", + "timestamp": "2022-08-27T05:06:30.471+0000", + "title": "Einzahlung", + "icon": "logos/bank_mastercard/v2", + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 1000.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "5b04b073-c06f-4ab1-bd01-de51b56162dc" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", + "sections": [ + { + "title": "Du hast 1.000,00 € über Kreditkarte hinzugefügt", + "data": { + "icon": "logos/bank_mastercard/v2", + "subtitleText": null, + "timestamp": "2022-08-27T05:06:30.471+0000", + "status": "executed" + }, + "action": null, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "·· 7431", + "icon": "logos/bank_mastercard/v2", + "type": "iconWithText" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Gebühr", + "detail": { + "text": "7,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Betrag", + "detail": { + "text": "1.000,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Einzahlung", + "detail": "27.08.2022", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "4f6f159f-08f1-4573-9b69-2418d57ca37a", + "postboxType": "PAYMENT_INBOUND_INVOICE", + "local_filepath": "" + } + ], + "action": null, + "type": "documents" + } + ] + }, + "has_docs": true +} diff --git a/tests/events/private_markets_order.json b/tests/events/private_markets_order.json new file mode 100644 index 00000000..08ccbc24 --- /dev/null +++ b/tests/events/private_markets_order.json @@ -0,0 +1,149 @@ +{ + "id": "12345678", + "timestamp": "2025-09-18T07:15:25.065+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "avatar": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -101.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "" + }, + "eventType": "private_markets_order_created", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "", + "sections": [ + { + "title": "Du hast 101,00 € investiert", + "data": { + "icon": "logos/LU3176111881/v2", + "timestamp": "2025-09-18T07:15:25.065819Z", + "status": "executed" + }, + "action": { + "payload": "LU3176111881", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Erstellt", + "functionalStyle": "CREATED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "100,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Summe", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "101,00 €", + "displayValue": { + "text": "101,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "", + "postboxType": "EQUITIES_BUY_EX_ANTE", + "local_filepath": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_order_bonus.json b/tests/events/private_markets_order_bonus.json new file mode 100644 index 00000000..86dcff16 --- /dev/null +++ b/tests/events/private_markets_order_bonus.json @@ -0,0 +1,152 @@ +{ + "id": "12345678", + "timestamp": "2025-09-18T07:15:25.085+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "avatar": { + "asset": "logos/LU3176111881/v2", + "badge": { + "asset": "logos/timeline_one_percent/v2", + "type": "icon" + } + }, + "badge": null, + "subtitle": "1 % Bonus", + "amount": { + "currency": "EUR", + "value": -1.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "eventType": "private_markets_order_created", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 1,00 € erhalten", + "data": { + "icon": "logos/LU3176111881/v2", + "timestamp": "2025-09-18T07:15:25.085181Z", + "status": "executed" + }, + "action": { + "payload": "LU3176111881", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "1% Bonus", + "detail": { + "text": "Erstellt", + "functionalStyle": "CREATED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "1,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "12345678", + "postboxType": "EQUITIES_BUY_EX_ANTE", + "local_filepath": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_order_bonus_no_eventType.json b/tests/events/private_markets_order_bonus_no_eventType.json new file mode 100644 index 00000000..0a1076b1 --- /dev/null +++ b/tests/events/private_markets_order_bonus_no_eventType.json @@ -0,0 +1,151 @@ +{ + "id": "12345678", + "timestamp": "2025-09-18T07:15:25.085+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "avatar": { + "asset": "logos/LU3176111881/v2", + "badge": { + "asset": "logos/timeline_one_percent/v2", + "type": "icon" + } + }, + "badge": null, + "subtitle": "1 % Bonus", + "amount": { + "currency": "EUR", + "value": -1.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "12345678" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "12345678", + "sections": [ + { + "title": "Du hast 1,00 € erhalten", + "data": { + "icon": "logos/LU3176111881/v2", + "timestamp": "2025-09-18T07:15:25.085181Z", + "status": "executed" + }, + "action": { + "payload": "LU3176111881", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "1% Bonus", + "detail": { + "text": "Erstellt", + "functionalStyle": "CREATED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "1,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "12345678", + "postboxType": "EQUITIES_BUY_EX_ANTE", + "local_filepath": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_order_no_eventType.json b/tests/events/private_markets_order_no_eventType.json new file mode 100644 index 00000000..73a69daf --- /dev/null +++ b/tests/events/private_markets_order_no_eventType.json @@ -0,0 +1,149 @@ +{ + "id": "12345678", + "timestamp": "2025-09-18T07:15:25.065+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "avatar": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -101.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "" + }, + "cashAccountNumber": "12345678", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "", + "sections": [ + { + "title": "Du hast 101,00 € investiert", + "data": { + "icon": "logos/LU3176111881/v2", + "timestamp": "2025-09-18T07:15:25.065819Z", + "status": "executed" + }, + "action": { + "payload": "LU3176111881", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Erstellt", + "functionalStyle": "CREATED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "100,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Summe", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "101,00 €", + "displayValue": { + "text": "101,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "", + "postboxType": "EQUITIES_BUY_EX_ANTE", + "local_filepath": "" + } + ], + "type": "documents" + } + ] + }, + "has_docs": true +} diff --git a/tests/events/private_markets_trade.json b/tests/events/private_markets_trade.json new file mode 100644 index 00000000..aacf0636 --- /dev/null +++ b/tests/events/private_markets_trade.json @@ -0,0 +1,180 @@ +{ + "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", + "timestamp": "2025-09-18T07:14:56.634+0000", + "title": "Private Equity", + "icon": "logos/LU3170240538/v2", + "avatar": { + "asset": "logos/LU3170240538/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -101.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6" + }, + "eventType": "private_markets_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", + "sections": [ + { + "title": "Du hast 101,00 € investiert", + "data": { + "icon": "logos/LU3170240538/v2", + "timestamp": "2025-09-18T07:14:56.623029Z", + "status": "executed" + }, + "action": { + "payload": "LU3170240538", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "1 × 100,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "1", + "displayValue": { + "text": "1" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "100,00 €", + "prefix": "1 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "101,00 €", + "displayValue": { + "text": "101,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "a7730267-753e-46a0-8213-54de9cf184e0", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "d0e63e45-6c50-4ce2-adce-83c32841a227", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_trade_bonus.json b/tests/events/private_markets_trade_bonus.json new file mode 100644 index 00000000..27a01450 --- /dev/null +++ b/tests/events/private_markets_trade_bonus.json @@ -0,0 +1,183 @@ +{ + "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", + "timestamp": "2025-09-18T07:14:56.652+0000", + "title": "Private Equity", + "icon": "logos/LU3170240538/v2", + "avatar": { + "asset": "logos/LU3170240538/v2", + "badge": { + "asset": "logos/timeline_one_percent/v2", + "type": "icon" + } + }, + "badge": null, + "subtitle": "1 % Bonus", + "amount": { + "currency": "EUR", + "value": -1.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "9fcaac4e-7675-4121-ab6d-2bf583798ba1" + }, + "eventType": "private_markets_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", + "sections": [ + { + "title": "Du hast 1,00 € erhalten", + "data": { + "icon": "logos/LU3170240538/v2", + "timestamp": "2025-09-18T07:14:56.636046Z", + "status": "executed" + }, + "action": { + "payload": "LU3170240538", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "1% Bonus", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,01 × 100,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,01", + "displayValue": { + "text": "0,01" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "100,00 €", + "prefix": "0,01 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "f8c6da6f-7885-450c-a27b-eb972ac3468b", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "fd93fc58-7179-4092-9466-655c58386513", + "postboxType": "EQUITIES_BUY_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_trade_bonus_no_eventType.json b/tests/events/private_markets_trade_bonus_no_eventType.json new file mode 100644 index 00000000..f6f2fee9 --- /dev/null +++ b/tests/events/private_markets_trade_bonus_no_eventType.json @@ -0,0 +1,182 @@ +{ + "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", + "timestamp": "2025-09-18T07:14:56.652+0000", + "title": "Private Equity", + "icon": "logos/LU3170240538/v2", + "avatar": { + "asset": "logos/LU3170240538/v2", + "badge": { + "asset": "logos/timeline_one_percent/v2", + "type": "icon" + } + }, + "badge": null, + "subtitle": "1 % Bonus", + "amount": { + "currency": "EUR", + "value": -1.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "9fcaac4e-7675-4121-ab6d-2bf583798ba1" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", + "sections": [ + { + "title": "Du hast 1,00 € erhalten", + "data": { + "icon": "logos/LU3170240538/v2", + "timestamp": "2025-09-18T07:14:56.636046Z", + "status": "executed" + }, + "action": { + "payload": "LU3170240538", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "1% Bonus", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,01 × 100,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,01", + "displayValue": { + "text": "0,01" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "100,00 €", + "prefix": "0,01 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "f8c6da6f-7885-450c-a27b-eb972ac3468b", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "fd93fc58-7179-4092-9466-655c58386513", + "postboxType": "EQUITIES_BUY_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_trade_no_eventType.json b/tests/events/private_markets_trade_no_eventType.json new file mode 100644 index 00000000..1bf14ea0 --- /dev/null +++ b/tests/events/private_markets_trade_no_eventType.json @@ -0,0 +1,179 @@ +{ + "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", + "timestamp": "2025-09-18T07:14:56.634+0000", + "title": "Private Equity", + "icon": "logos/LU3170240538/v2", + "avatar": { + "asset": "logos/LU3170240538/v2", + "badge": null + }, + "badge": null, + "subtitle": "Kauforder", + "amount": { + "currency": "EUR", + "value": -101.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", + "sections": [ + { + "title": "Du hast 101,00 € investiert", + "data": { + "icon": "logos/LU3170240538/v2", + "timestamp": "2025-09-18T07:14:56.623029Z", + "status": "executed" + }, + "action": { + "payload": "LU3170240538", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Kauf", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "1 × 100,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "1", + "displayValue": { + "text": "1" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "100,00 €", + "prefix": "1 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "101,00 €", + "displayValue": { + "text": "101,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "a7730267-753e-46a0-8213-54de9cf184e0", + "postboxType": "EQUITIES_BUY_EX_ANTE" + }, + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "d0e63e45-6c50-4ce2-adce-83c32841a227", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_verkaufsorder.json b/tests/events/private_markets_verkaufsorder.json new file mode 100644 index 00000000..bff08949 --- /dev/null +++ b/tests/events/private_markets_verkaufsorder.json @@ -0,0 +1,223 @@ +{ + "id": "86417e07-754d-45a6-a429-72c1437bc159", + "timestamp": "2026-06-08T14:15:00.000+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "avatar": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "badge": null, + "subtitle": "Verkaufsorder", + "amount": { + "currency": "EUR", + "value": 103.54, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "86417e07-754d-45a6-a429-72c1437bc159" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "PRIVATE_MARKET_FUND_TRADE_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "86417e07-754d-45a6-a429-72c1437bc159", + "sections": [ + { + "title": "Du hast 103,54 € erhalten", + "data": { + "icon": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "timestamp": "2026-06-08T14:15:00Z", + "status": "executed" + }, + "action": { + "payload": "LU3176111881", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Verkaufen", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "1,01 × 105,7252 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktienkurs", + "detail": { + "text": "105,7252 €", + "displayValue": { + "text": "105,7252 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien", + "detail": { + "text": "1,01", + "displayValue": { + "text": "1,01" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "103,54 €", + "displayValue": { + "text": "103,54 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "105,7252 €", + "prefix": "1,01 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Abzug für 1 %-Bonus", + "detail": { + "text": "1,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Abzug für 1 %-Bonus", + "type": "title" + }, + { + "text": "Du hast einen Bonus erhalten, der abgezogen werden muss, da du vor 18 Sept. 2027 verkaufst.", + "type": "text" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "1,24 €", + "displayValue": { + "text": "1,24 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "103,54 €", + "displayValue": { + "text": "103,54 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "7d8b50fe-e2fe-4d8a-859a-58e0d5354e82", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "b5ac9e63-b975-4a94-93dc-5652c0333522", + "postboxType": "EQUITIES_SELL_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_verkaufsorder_erstellt.json b/tests/events/private_markets_verkaufsorder_erstellt.json new file mode 100644 index 00000000..cf5a2f88 --- /dev/null +++ b/tests/events/private_markets_verkaufsorder_erstellt.json @@ -0,0 +1,183 @@ +{ + "id": "86417e07-754d-45a6-a429-72c1437bc159", + "timestamp": "2026-03-26T06:48:51.517+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "subtitle": "Verkaufsorder", + "action": { + "type": "timelineDetail", + "payload": "86417e07-754d-45a6-a429-72c1437bc159" + }, + "eventType": "PRIVATE_MARKET_FUND_ORDER_RECEIVED", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "86417e07-754d-45a6-a429-72c1437bc159", + "sections": [ + { + "title": "Du erhältst 104,10 €", + "data": { + "icon": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "timestamp": "2026-03-26T06:48:51.517335Z", + "status": "executed" + }, + "action": { + "payload": "LU3176111881", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Order erstellt", + "description": "Ausführung bis 9 Juni geplant. Der Betrag ist abhängig vom Fondskurs zum Ausführungszeitpunkt. Eine Ausführung kann nicht garantiert werden.", + "type": "banner" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Verkaufen", + "detail": { + "text": "Erstellt", + "functionalStyle": "CREATED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "106,10 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Summe", + "detail": { + "text": "106,10 €", + "displayValue": { + "text": "106,10 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "106,10 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Abzug für 1 %-Bonus", + "detail": { + "text": "1,00 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Abzug für 1 %-Bonus", + "type": "title" + }, + { + "text": "Du hast einen Bonus erhalten, der abgezogen werden muss, da du vor 18 Sept. 2027 verkaufst.", + "type": "text" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "104,10 €", + "displayValue": { + "text": "104,10 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Löschen", + "data": { + "title": "Löschen", + "action": { + "payload": "b7a2dcd2-daf5-4c4b-9f05-7f8b36a54136", + "type": "deletePrivateMarketsOrder" + } + }, + "type": "actionButtons" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "b5ac9e63-b975-4a94-93dc-5652c0333522", + "postboxType": "EQUITIES_SELL_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/private_markets_vorabpauschale.json b/tests/events/private_markets_vorabpauschale.json new file mode 100644 index 00000000..bc3ef4c4 --- /dev/null +++ b/tests/events/private_markets_vorabpauschale.json @@ -0,0 +1,137 @@ +{ + "id": "0319ae86-b98e-388d-9dd6-5a64b5373388", + "timestamp": "2026-03-09T07:56:12.429+0000", + "title": "Private Equity", + "icon": "logos/LU3176111881/v2", + "avatar": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "badge": null, + "subtitle": "Vorabpauschale", + "amount": { + "currency": "EUR", + "value": -0.07, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "0319ae86-b98e-388d-9dd6-5a64b5373388" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH_NON_DIVIDEND", + "source": "timelineTransaction", + "details": { + "id": "0319ae86-b98e-388d-9dd6-5a64b5373388", + "sections": [ + { + "title": "Du hast 0,07 € bezahlt", + "data": { + "icon": { + "asset": "logos/LU3176111881/v2", + "badge": null + }, + "timestamp": "2026-03-09T07:56:12.429Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Vorabpauschale", + "displayValue": { + "text": "Vorabpauschale" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Private Equity", + "displayValue": { + "text": "Private Equity" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,07 €", + "displayValue": { + "text": "-0,07 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-0,07 €", + "displayValue": { + "text": "-0,07 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Vorabpauschale", + "detail": "09.03.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "a1f523f2-c944-4617-bfe1-316a77226331", + "postboxType": "CA_VOPA_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/reverse_split.json b/tests/events/reverse_split.json new file mode 100644 index 00000000..20812de6 --- /dev/null +++ b/tests/events/reverse_split.json @@ -0,0 +1,116 @@ +{ + "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", + "timestamp": "2025-02-11T08:13:48.877+0000", + "title": "Globalstar", + "icon": "logos/US3789734080/v2", + "subtitle": "Reverse Split", + "action": { + "type": "timelineDetail", + "payload": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/US3789734080/v2", + "badge": null + }, + "timestamp": "2025-02-11T08:13:48.877Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Reverse Split", + "displayValue": { + "text": "Reverse Split" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Globalstar", + "displayValue": { + "text": "Globalstar" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "110.403067", + "displayValue": { + "text": "110.403067" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "GLOBALSTAR INC. O.N.", + "displayValue": { + "text": "GLOBALSTAR INC. O.N." + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "7.360204", + "displayValue": { + "text": "7.360204" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "11.02.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4c005c61-08ae-4205-9b77-02b886c0a5e5", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/reverse_split_new_isin.json b/tests/events/reverse_split_new_isin.json new file mode 100644 index 00000000..ac90922a --- /dev/null +++ b/tests/events/reverse_split_new_isin.json @@ -0,0 +1,124 @@ +{ + "id": "e93246ae-ee22-3124-988b-7c249e8c3add", + "timestamp": "2026-06-30T16:46:52.404+0000", + "title": "Honeywell International", + "icon": "logos/US4385162056/v2", + "subtitle": "Reverse Split", + "action": { + "type": "timelineDetail", + "payload": "e93246ae-ee22-3124-988b-7c249e8c3add" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "e93246ae-ee22-3124-988b-7c249e8c3add", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/US4385162056/v2", + "badge": null + }, + "timestamp": "2026-06-30T16:46:52.404Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Reverse Split", + "displayValue": { + "text": "Reverse Split", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Honeywell International", + "displayValue": { + "text": "Honeywell International", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "0.966682", + "displayValue": { + "text": "0.966682", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Honeywell International", + "displayValue": { + "text": "Honeywell International", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.483341", + "displayValue": { + "text": "0.483341", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "30.06.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "b699fbb6-31e6-404b-94a7-892080058427", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/reverse_split_no_eventType.json b/tests/events/reverse_split_no_eventType.json new file mode 100644 index 00000000..36998c15 --- /dev/null +++ b/tests/events/reverse_split_no_eventType.json @@ -0,0 +1,115 @@ +{ + "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", + "timestamp": "2025-02-11T08:13:48.877+0000", + "title": "Globalstar", + "icon": "logos/US3789734080/v2", + "subtitle": "Reverse Split", + "action": { + "type": "timelineDetail", + "payload": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5" + }, + "source": "timelineActivity", + "details": { + "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/US3789734080/v2", + "badge": null + }, + "timestamp": "2025-02-11T08:13:48.877Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Reverse Split", + "displayValue": { + "text": "Reverse Split" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Globalstar", + "displayValue": { + "text": "Globalstar" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "110.403067", + "displayValue": { + "text": "110.403067" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "GLOBALSTAR INC. O.N.", + "displayValue": { + "text": "GLOBALSTAR INC. O.N." + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "7.360204", + "displayValue": { + "text": "7.360204" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "11.02.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4c005c61-08ae-4205-9b77-02b886c0a5e5", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/reverse_split_old_isin.json b/tests/events/reverse_split_old_isin.json new file mode 100644 index 00000000..75581eae --- /dev/null +++ b/tests/events/reverse_split_old_isin.json @@ -0,0 +1,124 @@ +{ + "id": "8ffd17fe-afc2-3520-8eea-28828c8a8168", + "timestamp": "2026-06-30T16:46:52.404+0000", + "title": "Honeywell International", + "icon": "logos/US4385161066/v2", + "subtitle": "Reverse Split", + "action": { + "type": "timelineDetail", + "payload": "8ffd17fe-afc2-3520-8eea-28828c8a8168" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "8ffd17fe-afc2-3520-8eea-28828c8a8168", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/US4385161066/v2", + "badge": null + }, + "timestamp": "2026-06-30T16:46:52.404Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Reverse Split", + "displayValue": { + "text": "Reverse Split", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Honeywell International", + "displayValue": { + "text": "Honeywell International", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "0.966682", + "displayValue": { + "text": "0.966682", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Honeywell International", + "displayValue": { + "text": "Honeywell International", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.483341", + "displayValue": { + "text": "0.483341", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "30.06.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "873a5c81-5f95-4d44-a8c7-f475fba6dd4c", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/saveback.json b/tests/events/saveback.json new file mode 100644 index 00000000..70ee6365 --- /dev/null +++ b/tests/events/saveback.json @@ -0,0 +1,117 @@ +{ + "id": "836369c0-f623-4ad0-a259-8bd3807a6be6", + "timestamp": "2025-04-02T13:54:23.344+0000", + "title": "S&P 500 Information Tech USD (Acc)", + "icon": "logos/IE00B3WJKG14/v2", + "badge": null, + "subtitle": "Saveback", + "amount": { + "currency": "EUR", + "value": -15.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "836369c0-f623-4ad0-a259-8bd3807a6be6" + }, + "eventType": "benefits_saveback_execution", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "836369c0-f623-4ad0-a259-8bd3807a6be6", + "sections": [ + { + "title": "Du hast 15,00 € erhalten", + "data": { + "icon": "logos/IE00B3WJKG14/v2", + "timestamp": "2025-04-02T13:54:23.344+0000", + "status": "executed" + }, + "action": { + "payload": "IE00B3WJKG14", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Saveback", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "S&P 500 Information Tech USD (Acc)", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "", + "displayValue": { + "text": "27,45 €", + "prefix": "0.546348 x " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "15,00 €", + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Wertpapierabrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "8886fc15-a3e4-40c1-9604-e8e27f8ed992", + "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "001c5873-ddf6-42be-9eaa-19df21ef82f8", + "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/saveback_aggregate.json b/tests/events/saveback_aggregate.json new file mode 100644 index 00000000..975972b8 --- /dev/null +++ b/tests/events/saveback_aggregate.json @@ -0,0 +1,230 @@ +{ + "id": "94582990-1af6-457e-a0ae-161e4f2607f1", + "timestamp": "2024-07-02T13:53:44.125+0000", + "title": "S&P 500 Information Tech USD (Acc)", + "icon": "logos/IE00B3WJKG14/v2", + "avatar": { + "asset": "logos/IE00B3WJKG14/v2", + "badge": null + }, + "badge": null, + "subtitle": "Saveback", + "amount": { + "currency": "EUR", + "value": -15.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "94582990-1af6-457e-a0ae-161e4f2607f1" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "SAVEBACK_AGGREGATE", + "source": "timelineTransaction", + "details": { + "id": "94582990-1af6-457e-a0ae-161e4f2607f1", + "sections": [ + { + "title": "Du hast 15,00 € erhalten", + "data": { + "icon": { + "asset": "logos/IE00B3WJKG14/v2", + "badge": null + }, + "subtitleText": "Juli 2 · 13:53", + "status": "executed" + }, + "action": { + "payload": "IE00B3WJKG14", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Saveback", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "S&P 500 Information Tech USD (Acc)", + "displayValue": { + "text": "S&P 500 Information Tech USD (Acc)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Angefallen", + "detail": { + "text": "+ 15,00 €", + "action": { + "payload": { + "id": "94582990-1af6-457e-a0ae-161e4f2607f1", + "sections": [ + { + "title": "Saveback-Übersicht", + "type": "title" + }, + { + "data": [ + { + "title": "", + "detail": { + "content": { + "type": "default", + "title": "1 % Saveback", + "subtitle": "17,00 € zulässig", + "truncate": false + }, + "trailing": { + "type": "value", + "title": "15,00 €" + }, + "type": "listItem" + }, + "style": "plain" + }, + { + "title": "", + "detail": { + "content": { + "type": "default", + "title": "2% Crypto Saveback", + "subtitle": "Keine zulässigen Ausgaben", + "truncate": false + }, + "trailing": { + "type": "value", + "title": "0,00 €" + }, + "type": "listItem" + }, + "style": "plain" + }, + { + "title": "", + "detail": { + "content": { + "type": "default", + "title": "Gesamt", + "truncate": false + }, + "trailing": { + "type": "value", + "title": "15,00 €" + }, + "type": "listItem" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "text": "Du erhältst Saveback auf die ersten 1.500 € an zulässigen Transaktionen pro Monat. Erfahre mehr über Saveback.", + "style": "disclaimer", + "type": "text" + } + ] + }, + "displayMode": "bottomSheet", + "type": "infoPage" + }, + "displayValue": { + "text": "+ 15,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0.501924 x 29,89 €", + "displayValue": { + "text": "29,89 €", + "prefix": "0.501924 x " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 15,00 €", + "displayValue": { + "text": "+ 15,00 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Ausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "45e2b36b-81a3-408c-822a-318b49c49cb5", + "postboxType": "SAVINGS_PLAN_EXECUTED_V2" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "c3037321-6365-4e2c-98e7-be0b8b5b0406", + "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" + }, + { + "title": "Aktivierung", + "action": { + "payload": { + "path": "/api/v1/benefits/saveback/documents/config/817422da-529a-4e76-8b38-aa242d085756", + "title": "Herunterladen", + "shareable": true + }, + "type": "authenticatedBrowserModal" + }, + "id": "817422da-529a-4e76-8b38-aa242d085756", + "postboxType": "BENEFIT_ACTIVATED" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/saveback_no_eventType.json b/tests/events/saveback_no_eventType.json new file mode 100644 index 00000000..c761b66a --- /dev/null +++ b/tests/events/saveback_no_eventType.json @@ -0,0 +1,147 @@ +{ + "id": "b5999007-483d-4013-b582-347471a42a6a", + "timestamp": "2025-11-03T15:30:22.202+0000", + "title": "Lockheed Martin", + "icon": "logos/US5398301094/v2", + "avatar": { + "asset": "logos/US5398301094/v2", + "badge": null + }, + "badge": null, + "subtitle": "Saveback", + "amount": { + "currency": "EUR", + "value": -15.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "b5999007-483d-4013-b582-347471a42a6a" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "b5999007-483d-4013-b582-347471a42a6a", + "sections": [ + { + "title": "Du hast 15,00 € erhalten", + "data": { + "icon": "logos/US5398301094/v2", + "timestamp": "2025-11-03T15:30:22.202665Z", + "status": "executed" + }, + "action": { + "payload": "US5398301094", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Saveback", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Lockheed Martin", + "displayValue": { + "text": "Lockheed Martin" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0.035252 x 425,50 €", + "displayValue": { + "text": "425,50 €", + "prefix": "0.035252 x " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "15,00 €", + "displayValue": { + "text": "15,00 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Wertpapierabrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "0117fe00-93e5-47c2-9f7f-85f72d51da48", + "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" + }, + { + "title": "Aktivierung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "6387ff2c-656c-4f9a-a238-4a151dff6212", + "postboxType": "BENEFIT_ACTIVATED" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "29cca886-9baa-4153-947f-8dba06e618c9", + "postboxType": "COSTS_INFO_SAVINGS_PLAN" + }, + { + "title": "Auftragsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "3da1d209-7d52-4017-8397-1b9817f68432", + "postboxType": "SAVINGS_PLAN_CREATED" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/savings_plan_invoice_created.json b/tests/events/savings_plan_invoice_created.json new file mode 100644 index 00000000..ce796c7f --- /dev/null +++ b/tests/events/savings_plan_invoice_created.json @@ -0,0 +1,188 @@ +{ + "id": "7a4b762d-3366-46b0-9f4b-1c7e6cdd1d67", + "timestamp": "2024-06-17T08:16:25.998+0000", + "title": "Volkswagen (Vz.)", + "icon": "logos/DE0007664039/v2", + "avatar": { + "asset": "logos/DE0007664039/v2", + "badge": null + }, + "badge": null, + "subtitle": "Sparplan ausgeführt", + "amount": { + "currency": "EUR", + "value": -1.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "7a4b762d-3366-46b0-9f4b-1c7e6cdd1d67" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "SAVINGS_PLAN_INVOICE_CREATED", + "source": "timelineTransaction", + "details": { + "id": "7a4b762d-3366-46b0-9f4b-1c7e6cdd1d67", + "sections": [ + { + "title": "Du hast 1,00 € investiert", + "data": { + "icon": "logos/DE0007664039/v2", + "subtitleText": null, + "timestamp": "2024-06-17T08:16:25.998+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "DE0007664039" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Sparplan", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Volkswagen (Vz.)", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Guthaben", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Sparplan", + "data": [ + { + "title": "", + "detail": { + "title": "Volkswagen (Vz.)", + "timestamp": "2024-06-17T08:16:25.998Z", + "amount": "1,00 €", + "icon": "logos/DE0007664039/v2", + "status": "executed", + "action": { + "type": "openSavingsPlanOverview", + "payload": { + "savingsPlanId": "d2e09e56-10c3-4352-9023-f799e75ab880" + } + }, + "subtitle": "Wöchentlich", + "type": "embeddedTimelineItem" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "0,00961", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteilspreis", + "detail": { + "text": "104,05 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Gratis", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Ausführung", + "detail": "17.06.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "cd07b3c9-d32b-4a94-b005-b05b6c4d645d", + "postboxType": "SAVINGS_PLAN_EXECUTED_V2" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/savingsplan.json b/tests/events/savingsplan.json new file mode 100644 index 00000000..f7910590 --- /dev/null +++ b/tests/events/savingsplan.json @@ -0,0 +1,205 @@ +{ + "id": "8bd087f0-0091-4791-bff5-d47d8196aee4", + "timestamp": "2025-10-23T08:26:13.657+0000", + "title": "DroneShield", + "icon": "logos/AU000000DRO2/v2", + "avatar": { + "asset": "logos/AU000000DRO2/v2", + "badge": null + }, + "badge": null, + "subtitle": "Sparplan ausgeführt", + "amount": { + "currency": "EUR", + "value": -19.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "8bd087f0-0091-4791-bff5-d47d8196aee4" + }, + "eventType": "trading_savingsplan_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "8bd087f0-0091-4791-bff5-d47d8196aee4", + "sections": [ + { + "title": "Du hast 19,00 € gespart", + "data": { + "icon": "logos/AU000000DRO2/v2", + "timestamp": "2025-10-23T08:26:13.65787Z", + "status": "executed" + }, + "action": { + "payload": "AU000000DRO2", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Sparplan", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "DroneShield", + "displayValue": { + "text": "DroneShield" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "6,921675 × 2,75 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "6,921675", + "displayValue": { + "text": "6,921675" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "2,75 €", + "displayValue": { + "text": "2,75 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "19,00 €", + "displayValue": { + "text": "19,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "2,75 €", + "prefix": "6,921675 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "19,00 €", + "displayValue": { + "text": "19,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Sparplan", + "data": [ + { + "title": "", + "detail": { + "title": "DroneShield", + "timestamp": "2025-10-23T08:26:13.65787Z", + "amount": "19,00 €", + "icon": "logos/AU000000DRO2/v2", + "status": "executed", + "action": { + "payload": { + "savingsPlanId": "31e81415-c9ed-48b2-996b-5f3a2a6c32b1" + }, + "type": "openSavingsPlanOverview" + }, + "subtitle": "Wöchentlich", + "type": "embeddedTimelineItem" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnungsausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "f58e3844-a6f9-4f81-9bd0-8b49d8e5984e", + "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/savingsplan_no_eventType.json b/tests/events/savingsplan_no_eventType.json new file mode 100644 index 00000000..cda9fd78 --- /dev/null +++ b/tests/events/savingsplan_no_eventType.json @@ -0,0 +1,204 @@ +{ + "id": "78862117-79a9-4330-b594-ec62c3685a16", + "timestamp": "2025-11-03T15:58:11.121+0000", + "title": "TSMC (ADR)", + "icon": "logos/US8740391003/v2", + "avatar": { + "asset": "logos/US8740391003/v2", + "badge": null + }, + "badge": null, + "subtitle": "Sparplan ausgeführt", + "amount": { + "currency": "EUR", + "value": -10.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "78862117-79a9-4330-b594-ec62c3685a16" + }, + "cashAccountNumber": "", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "78862117-79a9-4330-b594-ec62c3685a16", + "sections": [ + { + "title": "Du hast 10,00 € gespart", + "data": { + "icon": "logos/US8740391003/v2", + "timestamp": "2025-11-03T15:58:11.121982Z", + "status": "executed" + }, + "action": { + "payload": "US8740391003", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Sparplan", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "TSMC (ADR)", + "displayValue": { + "text": "TSMC (ADR)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,037523 × 266,50 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,037523", + "displayValue": { + "text": "0,037523" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "266,50 €", + "displayValue": { + "text": "266,50 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "10,00 €", + "displayValue": { + "text": "10,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "266,50 €", + "prefix": "0,037523 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "10,00 €", + "displayValue": { + "text": "10,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Sparplan", + "data": [ + { + "title": "", + "detail": { + "title": "TSMC (ADR)", + "timestamp": "2025-11-03T15:58:11.121982Z", + "amount": "10,00 €", + "icon": "logos/US8740391003/v2", + "status": "executed", + "action": { + "payload": { + "savingsPlanId": "407449dc-fce1-48c3-93a6-e86919e5b385" + }, + "type": "openSavingsPlanOverview" + }, + "subtitle": "Wöchentlich", + "type": "embeddedTimelineItem" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnungsausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "548c51bd-f5c3-45f4-b794-b68bb90dc10c", + "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/securities_transfer_incoming.json b/tests/events/securities_transfer_incoming.json new file mode 100644 index 00000000..74bd58bf --- /dev/null +++ b/tests/events/securities_transfer_incoming.json @@ -0,0 +1,83 @@ +{ + "id": "756ce232-a67d-4d85-a431-57483426450a", + "timestamp": "2025-10-13T12:43:03.988+0000", + "title": "MSCI EM USD (Acc)", + "icon": "logos/IE00BTJRMP35/v2", + "subtitle": "Aktien erhalten", + "action": { + "type": "timelineDetail", + "payload": "756ce232-a67d-4d85-a431-57483426450a" + }, + "cashAccountNumber": "123456789", + "eventType": "SSP_SECURITIES_TRANSFER_INCOMING", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "756ce232-a67d-4d85-a431-57483426450a", + "sections": [ + { + "type": "header", + "title": "You received 7 shares", + "data": { + "status": "executed", + "icon": "logos/IE00BTJRMP35/v2", + "timestamp": "2025-10-13T12:43:03.988647Z" + } + }, + { + "type": "table", + "title": "Overview", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Completed", + "functionalStyle": "EXECUTED" + } + }, + { + "title": "Asset", + "style": "plain", + "detail": { + "type": "text", + "text": "MSCI EM USD (Acc)" + } + }, + { + "title": "Action", + "style": "plain", + "detail": { + "type": "text", + "text": "Securities transfer" + } + } + ] + }, + { + "type": "table", + "title": "Transaction", + "data": [ + { + "title": "Shares", + "style": "plain", + "detail": { + "type": "text", + "text": "7" + } + }, + { + "title": "Fee", + "style": "plain", + "detail": { + "type": "text", + "text": "Free" + } + } + ] + } + ] + } +} diff --git a/tests/events/securities_transfer_incoming_no_eventType.json b/tests/events/securities_transfer_incoming_no_eventType.json new file mode 100644 index 00000000..05f4e291 --- /dev/null +++ b/tests/events/securities_transfer_incoming_no_eventType.json @@ -0,0 +1,82 @@ +{ + "id": "756ce232-a67d-4d85-a431-57483426450a", + "timestamp": "2025-10-13T12:43:03.988+0000", + "title": "MSCI EM USD (Acc)", + "icon": "logos/IE00BTJRMP35/v2", + "subtitle": "Aktien erhalten", + "action": { + "type": "timelineDetail", + "payload": "756ce232-a67d-4d85-a431-57483426450a" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "756ce232-a67d-4d85-a431-57483426450a", + "sections": [ + { + "type": "header", + "title": "You received 7 shares", + "data": { + "status": "executed", + "icon": "logos/IE00BTJRMP35/v2", + "timestamp": "2025-10-13T12:43:03.988647Z" + } + }, + { + "type": "table", + "title": "Overview", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Completed", + "functionalStyle": "EXECUTED" + } + }, + { + "title": "Asset", + "style": "plain", + "detail": { + "type": "text", + "text": "MSCI EM USD (Acc)" + } + }, + { + "title": "Action", + "style": "plain", + "detail": { + "type": "text", + "text": "Securities transfer" + } + } + ] + }, + { + "type": "table", + "title": "Transaction", + "data": [ + { + "title": "Shares", + "style": "plain", + "detail": { + "type": "text", + "text": "7" + } + }, + { + "title": "Fee", + "style": "plain", + "detail": { + "type": "text", + "text": "Free" + } + } + ] + } + ] + } +} diff --git a/tests/events/sell_stop.json b/tests/events/sell_stop.json new file mode 100644 index 00000000..ca89ef77 --- /dev/null +++ b/tests/events/sell_stop.json @@ -0,0 +1,241 @@ +{ + "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", + "timestamp": "2025-03-14T07:03:14.000+0000", + "title": "D-Wave Quantum", + "icon": "logos/US26740W1099/v2", + "avatar": { + "asset": "logos/US26740W1099/v2", + "badge": null + }, + "badge": null, + "subtitle": "Stop-Sell-Order", + "amount": { + "currency": "EUR", + "value": 94.76, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "5b0f491f-7bad-40b1-8cd1-56d83729afd4" + }, + "eventType": "trading_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", + "sections": [ + { + "title": "Du hast 94,76 € erhalten", + "data": { + "icon": "logos/US26740W1099/v2", + "timestamp": "2025-03-14T07:03:09.282Z", + "status": "executed" + }, + "action": { + "payload": "US26740W1099", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Stop Order", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "D-Wave Quantum", + "displayValue": { + "text": "D-Wave Quantum" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "17 × 5,82 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "17", + "displayValue": { + "text": "17" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "5,82 €", + "displayValue": { + "text": "5,82 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "98,94 €", + "displayValue": { + "text": "98,94 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "5,82 €", + "prefix": "17 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "3,18 €", + "displayValue": { + "text": "3,18 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "94,76 €", + "displayValue": { + "text": "94,76 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "13,28 %", + "trend": "positive", + "displayValue": { + "text": "13,28 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "11,48 €", + "trend": "positive", + "displayValue": { + "text": "11,48 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "21a756dc-3eae-475a-a874-203b1a38b1a5", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "39232eec-df7d-401d-a4cd-7c398e048ba2", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "17c2c342-067f-4dd6-8e11-c1c53ccb9a24", + "postboxType": "ORDER_CONFIRMATION" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/sell_stop_no_eventType.json b/tests/events/sell_stop_no_eventType.json new file mode 100644 index 00000000..f140e3de --- /dev/null +++ b/tests/events/sell_stop_no_eventType.json @@ -0,0 +1,240 @@ +{ + "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", + "timestamp": "2025-03-14T07:03:14.000+0000", + "title": "D-Wave Quantum", + "icon": "logos/US26740W1099/v2", + "avatar": { + "asset": "logos/US26740W1099/v2", + "badge": null + }, + "badge": null, + "subtitle": "Stop-Sell-Order", + "amount": { + "currency": "EUR", + "value": 94.76, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "5b0f491f-7bad-40b1-8cd1-56d83729afd4" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", + "sections": [ + { + "title": "Du hast 94,76 € erhalten", + "data": { + "icon": "logos/US26740W1099/v2", + "timestamp": "2025-03-14T07:03:09.282Z", + "status": "executed" + }, + "action": { + "payload": "US26740W1099", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Stop Order", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "D-Wave Quantum", + "displayValue": { + "text": "D-Wave Quantum" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "17 × 5,82 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "17", + "displayValue": { + "text": "17" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "5,82 €", + "displayValue": { + "text": "5,82 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "98,94 €", + "displayValue": { + "text": "98,94 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "5,82 €", + "prefix": "17 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "3,18 €", + "displayValue": { + "text": "3,18 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "94,76 €", + "displayValue": { + "text": "94,76 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "13,28 %", + "trend": "positive", + "displayValue": { + "text": "13,28 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "11,48 €", + "trend": "positive", + "displayValue": { + "text": "11,48 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "21a756dc-3eae-475a-a874-203b1a38b1a5", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "39232eec-df7d-401d-a4cd-7c398e048ba2", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Auftragsbestätigung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "17c2c342-067f-4dd6-8e11-c1c53ccb9a24", + "postboxType": "ORDER_CONFIRMATION" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/spare_change_aggregate.json b/tests/events/spare_change_aggregate.json new file mode 100644 index 00000000..cc0475f8 --- /dev/null +++ b/tests/events/spare_change_aggregate.json @@ -0,0 +1,170 @@ +{ + "id": "b210331f-cea3-46ae-ab1a-3ea3f608f6fb", + "timestamp": "2024-06-10T13:52:18.218+0000", + "title": "S&P 500 Information Tech USD (Acc)", + "icon": "logos/IE00B3WJKG14/v2", + "avatar": { + "asset": "logos/IE00B3WJKG14/v2", + "badge": null + }, + "badge": null, + "subtitle": "Round up", + "amount": { + "currency": "EUR", + "value": -5.81, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "b210331f-cea3-46ae-ab1a-3ea3f608f6fb" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "SPARE_CHANGE_AGGREGATE", + "source": "timelineTransaction", + "details": { + "id": "b210331f-cea3-46ae-ab1a-3ea3f608f6fb", + "sections": [ + { + "title": "Du hast 5,81 € investiert", + "data": { + "icon": { + "asset": "logos/IE00B3WJKG14/v2", + "badge": null + }, + "subtitleText": "Juni 10 · 13:52", + "status": "executed" + }, + "action": { + "payload": "IE00B3WJKG14", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Round up", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "S&P 500 Information Tech USD (Acc)", + "displayValue": { + "text": "S&P 500 Information Tech USD (Acc)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Angefallen", + "detail": { + "text": "5,81 €", + "displayValue": { + "text": "5,81 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0.208318 x 27,89 €", + "displayValue": { + "text": "27,89 €", + "prefix": "0.208318 x " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "5,81 €", + "displayValue": { + "text": "5,81 €" + }, + "type": "text" + }, + "style": "highlighted" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung Ausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "654f9f73-3534-4fff-895b-d1f769e8f9d6", + "postboxType": "SAVINGS_PLAN_EXECUTED_V2" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "0c163f1a-432c-4c1b-b685-303d4e9a9df1", + "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" + }, + { + "title": "Aktivierung", + "action": { + "payload": { + "path": "/api/v1/benefits/sparechange/documents/config/5d0b1b02-54ab-43dd-b99b-8f1bb9a2612b", + "title": "Herunterladen", + "shareable": true + }, + "type": "authenticatedBrowserModal" + }, + "id": "5d0b1b02-54ab-43dd-b99b-8f1bb9a2612b", + "postboxType": "BENEFIT_ACTIVATED" + }, + { + "title": "Aktivierung", + "action": { + "payload": { + "path": "/api/v1/benefits/sparechange/documents/config/9561fc08-3e6c-4199-a546-e0a481004d83", + "title": "Herunterladen", + "shareable": true + }, + "type": "authenticatedBrowserModal" + }, + "id": "9561fc08-3e6c-4199-a546-e0a481004d83", + "postboxType": "BENEFIT_ACTIVATED" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/spinoff.json b/tests/events/spinoff.json new file mode 100644 index 00000000..391ee65a --- /dev/null +++ b/tests/events/spinoff.json @@ -0,0 +1,91 @@ +{ + "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", + "timestamp": "2025-10-20T11:25:29.214+0000", + "title": "ThyssenKrupp", + "icon": "logos/DE0007500001/v2", + "subtitle": "Spin-off", + "action": { + "type": "timelineDetail", + "payload": "30759295-1d4b-3e2a-b248-8bf6779cf30c" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/DE0007500001/v2", + "timestamp": "2025-10-20T11:25:29.214Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Spin-off", + "displayValue": { + "text": "Spin-off" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "TKMS", + "displayValue": { + "text": "TKMS" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.309986", + "displayValue": { + "text": "0.309986" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "20.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "9151d59c-29d8-4537-bb82-9d32824fbb04", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/spinoff_no_eventType.json b/tests/events/spinoff_no_eventType.json new file mode 100644 index 00000000..d705b71b --- /dev/null +++ b/tests/events/spinoff_no_eventType.json @@ -0,0 +1,90 @@ +{ + "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", + "timestamp": "2025-10-20T11:25:29.214+0000", + "title": "ThyssenKrupp", + "icon": "logos/DE0007500001/v2", + "subtitle": "Spin-off", + "action": { + "type": "timelineDetail", + "payload": "30759295-1d4b-3e2a-b248-8bf6779cf30c" + }, + "source": "timelineActivity", + "details": { + "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/DE0007500001/v2", + "timestamp": "2025-10-20T11:25:29.214Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Spin-off", + "displayValue": { + "text": "Spin-off" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "TKMS", + "displayValue": { + "text": "TKMS" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "0.309986", + "displayValue": { + "text": "0.309986" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "20.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "9151d59c-29d8-4537-bb82-9d32824fbb04", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/spinoff_only_taxes.json b/tests/events/spinoff_only_taxes.json similarity index 100% rename from tests/spinoff_only_taxes.json rename to tests/events/spinoff_only_taxes.json diff --git a/tests/events/ssp_tax_correction.json b/tests/events/ssp_tax_correction.json new file mode 100644 index 00000000..4d127cca --- /dev/null +++ b/tests/events/ssp_tax_correction.json @@ -0,0 +1,106 @@ +{ + "id": "cee48a8c-226f-35ec-ae86-1efd19beace1", + "timestamp": "2024-06-11T22:45:15.000+0000", + "title": "Steuerkorrektur", + "icon": "logos/timeline_person/v2", + "avatar": { + "asset": "logos/timeline_person/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 3.47, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "cee48a8c-226f-35ec-ae86-1efd19beace1" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "SSP_TAX_CORRECTION", + "source": "timelineTransaction", + "details": { + "id": "cee48a8c-226f-35ec-ae86-1efd19beace1", + "sections": [ + { + "title": "Du hast 3,47 € erhalten", + "data": { + "icon": { + "asset": "logos/timeline_person/v2", + "badge": null + }, + "subtitleText": "11 Juni 2024 · 22:45", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Steuerkorrektur", + "displayValue": { + "text": "Steuerkorrektur", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Gesamt", + "detail": { + "text": "3,47 €", + "displayValue": { + "text": "3,47 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Steuerabrechnung", + "detail": "28.06.2024", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "cdbc5f0c-4b16-4bd2-ad90-eb225e691aad", + "postboxType": "TAX_OPTIMIZATION_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/steuerkorrektur.json b/tests/events/steuerkorrektur.json new file mode 100644 index 00000000..3f8acecf --- /dev/null +++ b/tests/events/steuerkorrektur.json @@ -0,0 +1,101 @@ +{ + "id": "8a39d3f4-90bc-39ad-8a11-694308472b62", + "timestamp": "2025-10-28T00:00:16.000+0000", + "title": "Steuerkorrektur", + "icon": "logos/timeline_person/v2", + "avatar": { + "asset": "logos/timeline_person/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 2.87, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "8a39d3f4-90bc-39ad-8a11-694308472b62" + }, + "eventType": "ssp_tax_correction_invoice", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "8a39d3f4-90bc-39ad-8a11-694308472b62", + "sections": [ + { + "title": "Du hast 2,87 € erhalten", + "data": { + "icon": "logos/timeline_person/v2", + "timestamp": "2025-10-28T00:00:16Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Steuerkorrektur", + "displayValue": { + "text": "Steuerkorrektur" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Gesamt", + "detail": { + "text": "2,87 €", + "displayValue": { + "text": "2,87 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Steuerabrechnung", + "detail": "28.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "8bdb11ab-9406-4d11-845f-81e2371d87a0", + "postboxType": "TAX_OPTIMIZATION_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/steuerkorrektur_no_eventType.json b/tests/events/steuerkorrektur_no_eventType.json new file mode 100644 index 00000000..5690cfa6 --- /dev/null +++ b/tests/events/steuerkorrektur_no_eventType.json @@ -0,0 +1,100 @@ +{ + "id": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3", + "timestamp": "2025-11-04T23:31:58.000+0000", + "title": "Steuerkorrektur", + "icon": "logos/timeline_person/v2", + "avatar": { + "asset": "logos/timeline_person/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 0.76, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3" + }, + "cashAccountNumber": "", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3", + "sections": [ + { + "title": "Du hast 0,76 € erhalten", + "data": { + "icon": "logos/timeline_person/v2", + "timestamp": "2025-11-04T23:31:58Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Steuerkorrektur", + "displayValue": { + "text": "Steuerkorrektur" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Gesamt", + "detail": { + "text": "0,76 €", + "displayValue": { + "text": "0,76 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Steuerabrechnung", + "detail": "04.11.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "b1cbfe63-4737-4112-a8c7-033f69d1ed49", + "postboxType": "TAX_OPTIMIZATION_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/tausch_informative.json b/tests/events/tausch_informative.json new file mode 100644 index 00000000..67120f11 --- /dev/null +++ b/tests/events/tausch_informative.json @@ -0,0 +1,48 @@ +{ + "id": "bbf2affb-30ab-45bd-a7d6-d3047360e905", + "timestamp": "2025-11-04T08:59:35.225+0000", + "title": "L'Oreal", + "icon": "logos/FR0000120321/v2", + "subtitle": "Tausch", + "action": { + "type": "timelineDetail", + "payload": "bbf2affb-30ab-45bd-a7d6-d3047360e905" + }, + "source": "timelineActivity", + "details": { + "id": "bbf2affb-30ab-45bd-a7d6-d3047360e905", + "sections": [ + { + "title": "Du hast eine Kapitalmaßnahme erhalten", + "data": { + "icon": "logos/FR0000120321/v2", + "timestamp": "2025-11-04T08:59:35.225Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Information", + "text": "Das beigefügte Dokument enthält wichtige Informationen zu deiner L'Oreal-Investition. Bitte überprüfe das Dokument.", + "type": "text" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kapitalmaßnahmen", + "detail": "04.11.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "e68a0462-3569-4eea-a33c-f5b10154986a", + "postboxType": "CA_GENERIC_OPTIONS_NOTIFICATION" + } + ], + "type": "documents" + } + ] + }, + "eventType": "SSP_CORPORATE_ACTION_INFORMATIVE" +} diff --git a/tests/events/tausch_informative_no_eventType.json b/tests/events/tausch_informative_no_eventType.json new file mode 100644 index 00000000..7ca0f830 --- /dev/null +++ b/tests/events/tausch_informative_no_eventType.json @@ -0,0 +1,47 @@ +{ + "id": "bbf2affb-30ab-45bd-a7d6-d3047360e905", + "timestamp": "2025-11-04T08:59:35.225+0000", + "title": "L'Oreal", + "icon": "logos/FR0000120321/v2", + "subtitle": "Tausch", + "action": { + "type": "timelineDetail", + "payload": "bbf2affb-30ab-45bd-a7d6-d3047360e905" + }, + "source": "timelineActivity", + "details": { + "id": "bbf2affb-30ab-45bd-a7d6-d3047360e905", + "sections": [ + { + "title": "Du hast eine Kapitalmaßnahme erhalten", + "data": { + "icon": "logos/FR0000120321/v2", + "timestamp": "2025-11-04T08:59:35.225Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Information", + "text": "Das beigefügte Dokument enthält wichtige Informationen zu deiner L'Oreal-Investition. Bitte überprüfe das Dokument.", + "type": "text" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kapitalmaßnahmen", + "detail": "04.11.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "e68a0462-3569-4eea-a33c-f5b10154986a", + "postboxType": "CA_GENERIC_OPTIONS_NOTIFICATION" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/tausch_new_isin.json b/tests/events/tausch_new_isin.json new file mode 100644 index 00000000..d40147c0 --- /dev/null +++ b/tests/events/tausch_new_isin.json @@ -0,0 +1,124 @@ +{ + "id": "cb25d019-05f3-3a6c-8785-e410b70df9cd", + "timestamp": "2026-08-13T15:22:52.025+0000", + "title": "Fresenius SE & Co. KGaA Namens-Aktien o.N.", + "icon": "logos/DE000FRE5EN2/v2", + "subtitle": "Tausch", + "action": { + "type": "timelineDetail", + "payload": "cb25d019-05f3-3a6c-8785-e410b70df9cd" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "cb25d019-05f3-3a6c-8785-e410b70df9cd", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/DE000FRE5EN2/v2", + "badge": null + }, + "subtitleText": "13 Aug. · 15:22", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Tausch", + "displayValue": { + "text": "Tausch", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Fresenius", + "displayValue": { + "text": "Fresenius", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "5.431472", + "displayValue": { + "text": "5.431472", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Fresenius SE & Co. KGaA Namens-Aktien o.N.", + "displayValue": { + "text": "Fresenius SE & Co. KGaA Namens-Aktien o.N.", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.431472", + "displayValue": { + "text": "5.431472", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "13.08.2026", + "action": { + "payload": "https://example.com/document.pdf", + "type": "browserModal" + }, + "id": "5310c3d8-e7b5-4ad7-97fb-a48b39f5f579", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/tausch_old_isin.json b/tests/events/tausch_old_isin.json new file mode 100644 index 00000000..e8023feb --- /dev/null +++ b/tests/events/tausch_old_isin.json @@ -0,0 +1,124 @@ +{ + "id": "d569e3ae-4a62-3bda-9798-4b21ff0a5820", + "timestamp": "2026-08-13T15:22:52.025+0000", + "title": "Fresenius", + "icon": "logos/DE0005785604/v2", + "subtitle": "Tausch", + "action": { + "type": "timelineDetail", + "payload": "d569e3ae-4a62-3bda-9798-4b21ff0a5820" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "d569e3ae-4a62-3bda-9798-4b21ff0a5820", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/DE0005785604/v2", + "badge": null + }, + "subtitleText": "13 Aug. · 15:22", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Tausch", + "displayValue": { + "text": "Tausch", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Fresenius", + "displayValue": { + "text": "Fresenius", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "5.431472", + "displayValue": { + "text": "5.431472", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Fresenius SE & Co. KGaA Namens-Aktien o.N.", + "displayValue": { + "text": "Fresenius SE & Co. KGaA Namens-Aktien o.N.", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.431472", + "displayValue": { + "text": "5.431472", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "13.08.2026", + "action": { + "payload": "https://example.com/document.pdf", + "type": "browserModal" + }, + "id": "22b5d029-0f5c-46ad-b07f-c5ad0ae11ee2", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/teilrueckzahlung.json b/tests/events/teilrueckzahlung.json new file mode 100644 index 00000000..9b0ada72 --- /dev/null +++ b/tests/events/teilrueckzahlung.json @@ -0,0 +1,113 @@ +{ + "id": "c351c859-99e9-3d10-9049-f3b4daf30799", + "timestamp": "2025-10-23T14:46:49.868+0000", + "title": "ORSTED A/S EM.09/25 DK 10", + "icon": "logos/DK0064307755/v2", + "subtitle": "Teilrückzahlung ohne Reduzierung des Poolfaktors", + "action": { + "type": "timelineDetail", + "payload": "c351c859-99e9-3d10-9049-f3b4daf30799" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "c351c859-99e9-3d10-9049-f3b4daf30799", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": "logos/DK0064307755/v2", + "timestamp": "2025-10-23T14:46:49.868Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors", + "displayValue": { + "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S EM.09/25 DK 10", + "displayValue": { + "text": "ORSTED A/S EM.09/25 DK 10" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "17.000000", + "displayValue": { + "text": "17.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Orsted", + "displayValue": { + "text": "Orsted" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "17.000000", + "displayValue": { + "text": "17.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "23.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "6ea247d9-0b29-4637-b669-932f22ee745b", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/teilrueckzahlung_no_eventType.json b/tests/events/teilrueckzahlung_no_eventType.json new file mode 100644 index 00000000..706f5b36 --- /dev/null +++ b/tests/events/teilrueckzahlung_no_eventType.json @@ -0,0 +1,112 @@ +{ + "id": "c351c859-99e9-3d10-9049-f3b4daf30799", + "timestamp": "2025-10-23T14:46:49.868+0000", + "title": "ORSTED A/S EM.09/25 DK 10", + "icon": "logos/DK0064307755/v2", + "subtitle": "Teilrückzahlung ohne Reduzierung des Poolfaktors", + "action": { + "type": "timelineDetail", + "payload": "c351c859-99e9-3d10-9049-f3b4daf30799" + }, + "source": "timelineActivity", + "details": { + "id": "c351c859-99e9-3d10-9049-f3b4daf30799", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": "logos/DK0064307755/v2", + "timestamp": "2025-10-23T14:46:49.868Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors", + "displayValue": { + "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S EM.09/25 DK 10", + "displayValue": { + "text": "ORSTED A/S EM.09/25 DK 10" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "17.000000", + "displayValue": { + "text": "17.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Orsted", + "displayValue": { + "text": "Orsted" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "17.000000", + "displayValue": { + "text": "17.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "23.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "6ea247d9-0b29-4637-b669-932f22ee745b", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/tilgung.json b/tests/events/tilgung.json similarity index 98% rename from tests/tilgung.json rename to tests/events/tilgung.json index 6427c712..be725500 100644 --- a/tests/tilgung.json +++ b/tests/events/tilgung.json @@ -17,7 +17,7 @@ "payload": "32a408dd-5d8e-4991-a7c3-0b2fd1dc062c" }, "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "0123456789", + "cashAccountNumber": "123456789", "hidden": false, "deleted": false, "source": "timelineTransaction", diff --git a/tests/tilgung_no_eventType.json b/tests/events/tilgung_no_eventType.json similarity index 98% rename from tests/tilgung_no_eventType.json rename to tests/events/tilgung_no_eventType.json index d9bdddfd..eec8472f 100644 --- a/tests/tilgung_no_eventType.json +++ b/tests/events/tilgung_no_eventType.json @@ -16,7 +16,7 @@ "type": "timelineDetail", "payload": "32a408dd-5d8e-4991-a7c3-0b2fd1dc062c" }, - "cashAccountNumber": "0123456789", + "cashAccountNumber": "123456789", "hidden": false, "deleted": false, "source": "timelineTransaction", diff --git a/tests/events/trade_corrected.json b/tests/events/trade_corrected.json new file mode 100644 index 00000000..ddf36646 --- /dev/null +++ b/tests/events/trade_corrected.json @@ -0,0 +1,376 @@ +{ + "id": "20f25b9c-272c-4063-9681-674beba243b1", + "timestamp": "2024-12-16T09:59:01.938+0000", + "title": "Worldline", + "icon": "logos/FR0011981968/v2", + "avatar": { + "asset": "logos/FR0011981968/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit Verkauf-Order neu abgerechnet", + "amount": { + "currency": "EUR", + "value": 105.85, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "20f25b9c-272c-4063-9681-674beba243b1" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "TRADE_CORRECTED", + "source": "timelineTransaction", + "details": { + "id": "20f25b9c-272c-4063-9681-674beba243b1", + "sections": [ + { + "title": "Du hast 105,85 € erhalten", + "data": { + "icon": "logos/FR0011981968/v2", + "subtitleText": null, + "timestamp": "2024-12-16T09:59:01.938+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "FR0011981968" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Limit Verkauf", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Worldline", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "8,03 %", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "8,08 €", + "trend": "positive", + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "horizontalTable" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "13", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "8,36 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "1,80 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 105,85 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": { + "type": "infoPage", + "payload": { + "sections": [ + { + "title": "Transaktion", + "action": null, + "type": "title" + }, + { + "title": null, + "data": [ + { + "title": "Anteile", + "detail": { + "text": "13", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "8,36 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Order", + "detail": { + "text": "+ 108,65 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Kapitalertragsteuer", + "detail": { + "text": "1,60 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Kirchensteuer", + "detail": { + "text": "0,12 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Solidaritätszuschlag", + "detail": { + "text": "0,08 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "1,80 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": null, + "data": [ + { + "title": "Order", + "detail": { + "text": "+ 108,65 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "1,80 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "+ 105,85 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + } + ] + } + }, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung 2", + "detail": "27.06.2025", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "39adca91-1233-4be3-96ce-6c9600a6a306", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 1", + "detail": "16.12.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "08797e22-8186-49a7-9340-e570be775a60", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Auftragsbestätigung", + "detail": "16.12.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "c4881377-47fc-41eb-8666-b595406bd8b0", + "postboxType": "CONFIRM_ORDER_CREATE_V2" + }, + { + "title": "Kosteninformation", + "detail": "16.12.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "09b6e758-7be7-459d-ba09-6b2dc6d27a6c", + "postboxType": "COSTS_INFO_SELL_V2" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/events/trade_invoice.json b/tests/events/trade_invoice.json new file mode 100644 index 00000000..460603aa --- /dev/null +++ b/tests/events/trade_invoice.json @@ -0,0 +1,173 @@ +{ + "id": "902268aa-34fd-4066-95d1-17463a0e86d3", + "timestamp": "2024-06-04T06:23:45.768+0000", + "title": "DWS Group", + "icon": "logos/DE000DWS1007/v2", + "avatar": { + "asset": "logos/DE000DWS1007/v2", + "badge": null + }, + "badge": null, + "subtitle": "Limit-Buy-Order", + "amount": { + "currency": "EUR", + "value": -221.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "902268aa-34fd-4066-95d1-17463a0e86d3" + }, + "cashAccountNumber": null, + "hidden": false, + "deleted": false, + "eventType": "TRADE_INVOICE", + "source": "timelineTransaction", + "details": { + "id": "902268aa-34fd-4066-95d1-17463a0e86d3", + "sections": [ + { + "title": "Du hast 221,00 € investiert", + "data": { + "icon": "logos/DE000DWS1007/v2", + "subtitleText": null, + "timestamp": "2024-06-04T06:23:45.768+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "DE000DWS1007" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Limit Kauf", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "DWS Group", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Anteile", + "detail": { + "text": "5", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "44,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "221,00 €", + "trend": null, + "action": null, + "displayValue": null, + "type": "text" + }, + "style": "highlighted" + } + ], + "action": null, + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "04.06.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "94863a69-7895-4f2f-91a8-9da7633cbe20", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Auftragsbestätigung", + "detail": "04.06.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "b88ab265-c8ca-4fce-8271-85ab41c20a0e", + "postboxType": "CONFIRM_ORDER_CREATE_V2" + }, + { + "title": "Kosteninformation", + "detail": "04.06.2024", + "action": { + "type": "browserModal", + "payload": "" + }, + "id": "779fadd7-e5df-47c4-8db2-d77ed91aa659", + "postboxType": "COSTS_INFO_BUY_V2" + } + ], + "action": null, + "type": "documents" + } + ] + } +} diff --git a/tests/trade_perk.json b/tests/events/trade_perk.json similarity index 100% rename from tests/trade_perk.json rename to tests/events/trade_perk.json diff --git a/tests/trade_perk_no_eventType.json b/tests/events/trade_perk_no_eventType.json similarity index 100% rename from tests/trade_perk_no_eventType.json rename to tests/events/trade_perk_no_eventType.json diff --git a/tests/events/trading_savingsplan_executed.json b/tests/events/trading_savingsplan_executed.json new file mode 100644 index 00000000..897b3733 --- /dev/null +++ b/tests/events/trading_savingsplan_executed.json @@ -0,0 +1,219 @@ +{ + "id": "a98f640c-6dd6-4af4-a5f5-b3984da9e0c2", + "timestamp": "2025-02-10T09:23:13.824+0000", + "title": "BASF", + "icon": "logos/DE000BASF111/v2", + "avatar": { + "asset": "logos/DE000BASF111/v2", + "badge": null + }, + "badge": null, + "subtitle": "Sparplan ausgeführt", + "amount": { + "currency": "EUR", + "value": -15.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "a98f640c-6dd6-4af4-a5f5-b3984da9e0c2" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "TRADING_SAVINGSPLAN_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "a98f640c-6dd6-4af4-a5f5-b3984da9e0c2", + "sections": [ + { + "title": "Du hast 15,00 € gespart", + "data": { + "icon": { + "asset": "logos/DE000BASF111/v2", + "badge": null + }, + "timestamp": "2025-02-10T09:23:13.824796Z", + "status": "executed" + }, + "action": { + "payload": "DE000BASF111", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Sparplan", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "BASF", + "displayValue": { + "text": "BASF", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,316355 × 47,415 €", + "action": { + "type": "infoPage", + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktienkurs", + "detail": { + "text": "47,415 €", + "displayValue": { + "text": "47,415 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien", + "detail": { + "text": "0,316355", + "displayValue": { + "text": "0,316355", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "15,00 €", + "displayValue": { + "text": "15,00 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "displayMode": "bottomSheet" + }, + "displayValue": { + "text": "47,415 €", + "prefix": "0,316355 × ", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "15,00 €", + "displayValue": { + "text": "15,00 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Sparplan", + "data": [ + { + "title": "", + "detail": { + "title": "BASF", + "timestamp": "2025-02-10T09:23:13.824796Z", + "amount": "15,00 €", + "icon": { + "asset": "logos/DE000BASF111/v2", + "badge": null + }, + "status": "executed", + "action": { + "payload": { + "savingsPlanId": "cbe1cadc-d169-4c2e-b175-450731c51eb2" + }, + "type": "openSavingsPlanOverview" + }, + "subtitle": "Wöchentlich", + "type": "embeddedTimelineItem" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnungsausführung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "ededaa5b-2bbf-4ffc-b80b-3ddd50bf5b08", + "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/trading_savingsplan_execution_pending.json b/tests/events/trading_savingsplan_execution_pending.json new file mode 100644 index 00000000..d6d62079 --- /dev/null +++ b/tests/events/trading_savingsplan_execution_pending.json @@ -0,0 +1,143 @@ +{ + "id": "be638bf9-7bd9-400a-b401-548571f72f23", + "timestamp": "2026-09-16T01:05:56.903+0000", + "title": "Enovix", + "icon": "logos/US2935941078/v2", + "avatar": { + "asset": "logos/US2935941078/v2", + "badge": null + }, + "badge": null, + "subtitle": "Sparplan ausstehend", + "amount": { + "currency": "EUR", + "value": -20.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "be638bf9-7bd9-400a-b401-548571f72f23" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "TRADING_SAVINGSPLAN_EXECUTION_PENDING", + "presentation": null, + "source": "timelineTransaction", + "details": { + "id": "be638bf9-7bd9-400a-b401-548571f72f23", + "sections": [ + { + "title": "Du sparst 20,00€", + "data": { + "icon": { + "asset": "logos/US2935941078/v2", + "badge": null + }, + "subtitleText": "16 Sept. · 01:05", + "status": "executed" + }, + "action": { + "payload": "US2935941078", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Für heute geplant", + "description": "Dein Sparplan ist derzeit in Bearbeitung und soll heute abgeschlossen werden. Bitte warte bis zum Ende des Tages.", + "type": "banner" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Sparplan", + "detail": { + "text": "Ausstehend", + "functionalStyle": "PENDING", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Zahlung", + "detail": { + "text": "Cash", + "icon": "logos/bank_traderepublic/v2", + "type": "iconWithText" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Enovix", + "displayValue": { + "text": "Enovix", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "Kostenlos", + "displayValue": { + "text": "Kostenlos", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "20,00€", + "displayValue": { + "text": "20,00€", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Sparplan", + "data": [ + { + "title": "", + "detail": { + "title": "Enovix", + "timestamp": "2026-09-16T01:05:56.903723487Z", + "amount": "20,00€", + "icon": { + "asset": "logos/US2935941078/v2", + "badge": null + }, + "status": "executed", + "action": { + "payload": { + "savingsPlanId": "fcb4bfbb-6159-4a74-b73f-b0282a86d567" + }, + "type": "openSavingsPlanOverview" + }, + "subtitle": "Wöchentlich", + "type": "embeddedTimelineItem" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + } +} diff --git a/tests/events/transfer_in.json b/tests/events/transfer_in.json new file mode 100644 index 00000000..6912104c --- /dev/null +++ b/tests/events/transfer_in.json @@ -0,0 +1,93 @@ +{ + "id": "c511b534-0c1a-4390-ac9c-8572eb47430c", + "timestamp": "2024-06-14T16:40:07.424+0000", + "title": "British American Tobacco", + "icon": "logos/GB0002875804/v2", + "subtitle": "Aktien erhalten", + "action": { + "type": "timelineDetail", + "payload": "c511b534-0c1a-4390-ac9c-8572eb47430c" + }, + "source": "timelineActivity", + "details": { + "id": "c511b534-0c1a-4390-ac9c-8572eb47430c", + "sections": [ + { + "title": "Du hast Aktien im Wert von 1.0 erhalten", + "data": { + "icon": { + "asset": "logos/GB0002875804/v2", + "badge": null + }, + "timestamp": "2024-06-14T16:40:07.424Z", + "status": "executed" + }, + "action": { + "payload": "GB0002875804", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Auftragsart", + "detail": { + "text": "Wertpapierübertrag", + "displayValue": { + "text": "Wertpapierübertrag" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien", + "detail": { + "text": "1.0", + "displayValue": { + "text": "1.0" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "British American Tobacco", + "displayValue": { + "text": "British American Tobacco" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Ausführungsmitteilung", + "detail": "18.06.2024", + "id": "c511b534-0c1a-4390-ac9c-8572eb47430c", + "postboxType": "TRANSFER_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/transfer_out.json b/tests/events/transfer_out.json new file mode 100644 index 00000000..214b6e96 --- /dev/null +++ b/tests/events/transfer_out.json @@ -0,0 +1,106 @@ +{ + "id": "9cadff27-504a-3326-9102-cfd67a0ac5c2", + "timestamp": "2025-09-18T17:03:45.166+0000", + "title": "Novo-Nordisk (B)", + "icon": "logos/DK0062498333/v2", + "subtitle": "Aktien übertragen", + "action": { + "type": "timelineDetail", + "payload": "9cadff27-504a-3326-9102-cfd67a0ac5c2" + }, + "source": "timelineActivity", + "details": { + "id": "9cadff27-504a-3326-9102-cfd67a0ac5c2", + "sections": [ + { + "type": "header", + "title": "You transferred 42 shares", + "data": { + "status": "executed", + "icon": "logos/DK0062498333/v2", + "timestamp": "2025-09-18T17:03:45.166804327Z" + } + }, + { + "type": "table", + "title": "Overview", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Completed", + "functionalStyle": "EXECUTED" + } + }, + { + "title": "Asset", + "style": "plain", + "detail": { + "type": "text", + "text": "Novo-Nordisk (B)" + } + }, + { + "title": "Action", + "style": "plain", + "detail": { + "type": "text", + "text": "Securities transfer" + } + }, + { + "title": "Transfer to", + "style": "plain", + "detail": { + "type": "text", + "text": "BAADER BANK AKTIENGESELLSCHAFT" + } + }, + { + "title": "BIC", + "style": "plain", + "detail": { + "type": "text", + "text": "BDWBDEMMXXX" + } + } + ] + }, + { + "type": "table", + "title": "Transaction", + "data": [ + { + "title": "Shares", + "style": "plain", + "detail": { + "type": "text", + "text": "42" + } + }, + { + "title": "Fee", + "style": "plain", + "detail": { + "type": "text", + "text": "Free" + } + } + ] + }, + { + "type": "documents", + "title": "Documents", + "data": [ + { + "id": "d7b428e6-218d-3197-8d8b-57a22d164ce8", + "title": "Execution Notice", + "postboxType": "TRANSFER_INVOICE_TYPE" + } + ] + } + ] + } +} diff --git a/tests/events/transfer_out_cancelled.json b/tests/events/transfer_out_cancelled.json new file mode 100644 index 00000000..f4f2c80c --- /dev/null +++ b/tests/events/transfer_out_cancelled.json @@ -0,0 +1,92 @@ +{ + "id": "83af5c46-caa7-4e07-a504-ef0fbe367925", + "timestamp": "2024-11-16T11:55:12.959+0000", + "title": "MSCI World USD (Dist)", + "icon": "logos/IE00BK1PV551/v2", + "subtitle": "Aktien übertragen", + "action": { + "type": "timelineDetail", + "payload": "83af5c46-caa7-4e07-a504-ef0fbe367925" + }, + "source": "timelineActivity", + "details": { + "id": "83af5c46-caa7-4e07-a504-ef0fbe367925", + "sections": [ + { + "type": "header", + "title": "You transferred 14 shares", + "data": { + "status": "canceled", + "icon": "logos/IE00BK1PV551/v2", + "timestamp": "2024-11-16T11:55:12.959548322Z" + } + }, + { + "type": "banner", + "title": "Shares not accepted", + "description": "Your outgoing transfer was rejected since your receiving bank didn't accept your shares within 21 days." + }, + { + "type": "table", + "title": "Overview", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Rejected", + "functionalStyle": "CANCELED" + } + }, + { + "title": "Asset", + "style": "plain", + "detail": { + "type": "text", + "text": "MSCI World USD (Dist)" + } + }, + { + "title": "Action", + "style": "plain", + "detail": { + "type": "text", + "text": "Securities transfer" + } + }, + { + "title": "BIC", + "style": "plain", + "detail": { + "type": "text", + "text": "BDWBDEMMXXX" + } + } + ] + }, + { + "type": "table", + "title": "Transaction", + "data": [ + { + "title": "Shares", + "style": "plain", + "detail": { + "type": "text", + "text": "14" + } + }, + { + "title": "Fee", + "style": "plain", + "detail": { + "type": "text", + "text": "Free" + } + } + ] + } + ] + } +} diff --git a/tests/events/verkaufsorder.json b/tests/events/verkaufsorder.json new file mode 100644 index 00000000..5abd8983 --- /dev/null +++ b/tests/events/verkaufsorder.json @@ -0,0 +1,250 @@ +{ + "id": "986af7e0-f0c1-4fac-8d24-b334ce51275a", + "timestamp": "2025-05-12T18:38:36.065+0000", + "title": "Tencent Holdings (ADR)", + "icon": "logos/US88032Q1094/v2", + "avatar": { + "asset": "logos/US88032Q1094/v2", + "badge": null + }, + "badge": null, + "subtitle": "Verkaufsorder", + "amount": { + "currency": "EUR", + "value": 200.93, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "986af7e0-f0c1-4fac-8d24-b334ce51275a" + }, + "eventType": "trading_trade_executed", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "986af7e0-f0c1-4fac-8d24-b334ce51275a", + "sections": [ + { + "title": "Du hast 200,93 € erhalten", + "data": { + "icon": "logos/US88032Q1094/v2", + "timestamp": "2025-05-12T18:38:36.065535045Z", + "status": "executed" + }, + "action": { + "payload": "US88032Q1094", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verkaufen", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Tencent Holdings (ADR)", + "displayValue": { + "text": "Tencent Holdings (ADR)" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "3,454506 × 58,50 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "3,454506", + "displayValue": { + "text": "3,454506" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "58,50 €", + "displayValue": { + "text": "58,50 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "202,09 €", + "displayValue": { + "text": "202,09 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "58,50 €", + "prefix": "3,454506 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,16 €", + "displayValue": { + "text": "0,16 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "200,93 €", + "displayValue": { + "text": "200,93 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "0,31 %", + "trend": "positive", + "displayValue": { + "text": "0,31 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gewinn", + "detail": { + "text": "0,62 €", + "trend": "positive", + "displayValue": { + "text": "0,62 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Kosteninformation 1", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "8b7b76a5-32f6-4243-ae06-d0002bc549d4", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Kosteninformation 2", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "cbb6b836-d19a-4760-88a5-b33ec707431c", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Abrechnung 1", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4b15144e-0886-4114-9d01-d95f064f950d", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 2", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "74f4790f-2f36-484f-ba06-7d4df50f1f32", + "postboxType": "SECURITIES_SETTLEMENT" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/verkaufsorder_abrechnung12.json b/tests/events/verkaufsorder_abrechnung12.json new file mode 100644 index 00000000..f905a468 --- /dev/null +++ b/tests/events/verkaufsorder_abrechnung12.json @@ -0,0 +1,138 @@ +{ + "id": "7ca12567-d1a3-4b9e-9ff9-860a8b1039da", + "timestamp": "2026-05-18T15:37:40.852+0000", + "title": "Zalando", + "icon": "logos/DE000ZAL1111/v2", + "avatar": { + "asset": "logos/DE000ZAL1111/v2", + "badge": null + }, + "badge": null, + "subtitle": "Verkaufsorder", + "amount": { + "currency": "EUR", + "value": 93.07, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "7ca12567-d1a3-4b9e-9ff9-860a8b1039da" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "TRADING_TRADE_EXECUTED", + "source": "timelineTransaction", + "details": { + "id": "7ca12567-d1a3-4b9e-9ff9-860a8b1039da", + "sections": [ + { + "title": "Du hast 93,07 € erhalten", + "data": { + "icon": { + "asset": "logos/DE000ZAL1111/v2", + "badge": null + }, + "timestamp": "2026-05-18T15:37:40.85271Z", + "status": "executed" + }, + "action": { + "payload": "DE000ZAL1111", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Verkaufen", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Zalando", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien", + "detail": { + "text": "4,795804", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "93,07 €", + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung 1", + "action": { + "payload": "https://example.com/pb177912741843111361132997312.pdf", + "type": "browserModal" + }, + "id": "c296d1ff-1c41-4d78-9f78-ebfd36c1aa4a", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Abrechnung 2", + "action": { + "payload": "https://example.com/pb177912741845833861871511777.pdf", + "type": "browserModal" + }, + "id": "878d892d-e423-4276-bd92-1be56378ddae", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation 1", + "action": { + "payload": "https://example.com/pb17791186615264608177800718.pdf", + "type": "browserModal" + }, + "id": "6fefbcb8-b090-42fe-9a2e-082c448be84b", + "postboxType": "EQUITIES_SELL_EX_ANTE" + }, + { + "title": "Kosteninformation 2", + "action": { + "payload": "https://example.com/pb177911866152618856175389832.pdf", + "type": "browserModal" + }, + "id": "7f65bb06-b16a-4cc1-8ba3-a4423ec4b9a0", + "postboxType": "EQUITIES_SELL_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/verkaufsorder_no_eventType.json b/tests/events/verkaufsorder_no_eventType.json new file mode 100644 index 00000000..15c75022 --- /dev/null +++ b/tests/events/verkaufsorder_no_eventType.json @@ -0,0 +1,231 @@ +{ + "id": "c082a8d2-8816-4d33-829b-6cb78584df34", + "timestamp": "2025-11-04T16:27:25.185+0000", + "title": "Home Depot", + "icon": "logos/US4370761029/v2", + "avatar": { + "asset": "logos/US4370761029/v2", + "badge": null + }, + "badge": null, + "subtitle": "Verkaufsorder", + "amount": { + "currency": "EUR", + "value": 100.0, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "c082a8d2-8816-4d33-829b-6cb78584df34" + }, + "cashAccountNumber": "", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "c082a8d2-8816-4d33-829b-6cb78584df34", + "sections": [ + { + "title": "Du hast 100,00 € erhalten", + "data": { + "icon": "logos/US4370761029/v2", + "timestamp": "2025-11-04T16:27:25.185Z", + "status": "executed" + }, + "action": { + "payload": "US4370761029", + "type": "instrumentDetail" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Portfolio", + "detail": { + "text": "Brokerage", + "displayValue": { + "text": "Brokerage" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verkaufen", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Home Depot", + "displayValue": { + "text": "Home Depot" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Transaktion", + "detail": { + "text": "0,305182 × 330,95 €", + "action": { + "payload": { + "id": "00000000-0000-0000-0000-000000000000", + "sections": [ + { + "title": "Transaktion", + "type": "title" + }, + { + "data": [ + { + "title": "Aktien", + "detail": { + "text": "0,305182", + "displayValue": { + "text": "0,305182" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktienkurs", + "detail": { + "text": "330,95 €", + "displayValue": { + "text": "330,95 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "101,00 €", + "displayValue": { + "text": "101,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + } + ] + }, + "type": "infoPage" + }, + "displayValue": { + "text": "330,95 €", + "prefix": "0,305182 × " + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gebühr", + "detail": { + "text": "1,00 €", + "displayValue": { + "text": "1,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Summe", + "detail": { + "text": "100,00 €", + "displayValue": { + "text": "100,00 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Performance", + "data": [ + { + "title": "Rendite", + "detail": { + "text": "19,22 %", + "trend": "negative", + "displayValue": { + "text": "19,22 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Verlust", + "detail": { + "text": "-16,12 €", + "trend": "negative", + "displayValue": { + "text": "-16,12 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "horizontalTable" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "b5d0cd84-ed10-4e52-9582-61b313e45593", + "postboxType": "SECURITIES_SETTLEMENT" + }, + { + "title": "Kosteninformation", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "df64bd22-637b-4d24-b201-eafa7bc6a2d1", + "postboxType": "EQUITIES_SELL_EX_ANTE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/vorabpauschale.json b/tests/events/vorabpauschale.json new file mode 100644 index 00000000..d25ffa38 --- /dev/null +++ b/tests/events/vorabpauschale.json @@ -0,0 +1,134 @@ +{ + "id": "574bc726-c7c2-3439-9708-1801f30259c0", + "timestamp": "2025-01-28T14:54:28.155+0000", + "title": "MSCI China USD (Acc)", + "icon": "logos/IE00BJ5JPG56/v2", + "avatar": { + "asset": "logos/IE00BJ5JPG56/v2", + "badge": null + }, + "badge": null, + "subtitle": "Vorabpauschale", + "amount": { + "currency": "EUR", + "value": -0.19, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "574bc726-c7c2-3439-9708-1801f30259c0" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "574bc726-c7c2-3439-9708-1801f30259c0", + "sections": [ + { + "title": "Du hast -0,19 € bezahlt", + "data": { + "icon": "logos/IE00BJ5JPG56/v2", + "timestamp": "2025-01-28T14:54:28.155Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Vorabpauschale", + "displayValue": { + "text": "Vorabpauschale" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "MSCI China USD (Acc)", + "displayValue": { + "text": "MSCI China USD (Acc)" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,19 €", + "displayValue": { + "text": "-0,19 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-0,19 €", + "displayValue": { + "text": "-0,19 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Vorabpauschale", + "detail": "28.02.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4e227b8e-63c5-49a1-8e0b-adf8aaa6b81a", + "postboxType": "CA_VOPA_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/vorabpauschale_negative.json b/tests/events/vorabpauschale_negative.json new file mode 100644 index 00000000..3ebcbbec --- /dev/null +++ b/tests/events/vorabpauschale_negative.json @@ -0,0 +1,142 @@ +{ + "id": "61373a0b-3574-31be-855f-53edf4976c8f", + "timestamp": "2025-01-28T14:30:05.259+0000", + "title": "S&P 400 US Mid Cap (Acc)", + "icon": "logos/IE00B4YBJ215/v2", + "avatar": { + "asset": "logos/IE00B4YBJ215/v2", + "badge": null + }, + "badge": null, + "subtitle": "Vorabpauschale", + "amount": { + "currency": "EUR", + "value": -0.04, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "61373a0b-3574-31be-855f-53edf4976c8f" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH", + "source": "timelineTransaction", + "details": { + "id": "61373a0b-3574-31be-855f-53edf4976c8f", + "sections": [ + { + "title": "Du hast -0,04 € bezahlt", + "data": { + "icon": { + "asset": "logos/IE00B4YBJ215/v2", + "badge": null + }, + "subtitleText": "28 Jan. 2025 · 14:30", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Vorabpauschale", + "displayValue": { + "text": "Vorabpauschale", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "S&P 400 US Mid Cap (Acc)", + "displayValue": { + "text": "S&P 400 US Mid Cap (Acc)", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,04 €", + "displayValue": { + "text": "-0,04 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-0,04 €", + "displayValue": { + "text": "-0,04 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Vorabpauschale", + "detail": "28.01.2025", + "action": { + "payload": "https://example.com/vorabpauschale.pdf", + "type": "browserModal" + }, + "id": "2e2ce1bd-6149-4ad6-9483-a57e619ca5d7", + "postboxType": "CA_VOPA_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/vorabpauschale_no_eventType.json b/tests/events/vorabpauschale_no_eventType.json new file mode 100644 index 00000000..78b534c5 --- /dev/null +++ b/tests/events/vorabpauschale_no_eventType.json @@ -0,0 +1,133 @@ +{ + "id": "574bc726-c7c2-3439-9708-1801f30259c0", + "timestamp": "2025-01-28T14:54:28.155+0000", + "title": "MSCI China USD (Acc)", + "icon": "logos/IE00BJ5JPG56/v2", + "avatar": { + "asset": "logos/IE00BJ5JPG56/v2", + "badge": null + }, + "badge": null, + "subtitle": "Vorabpauschale", + "amount": { + "currency": "EUR", + "value": -0.19, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "574bc726-c7c2-3439-9708-1801f30259c0" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "574bc726-c7c2-3439-9708-1801f30259c0", + "sections": [ + { + "title": "Du hast -0,19 € bezahlt", + "data": { + "icon": "logos/IE00BJ5JPG56/v2", + "timestamp": "2025-01-28T14:54:28.155Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Vorabpauschale", + "displayValue": { + "text": "Vorabpauschale" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "MSCI China USD (Acc)", + "displayValue": { + "text": "MSCI China USD (Acc)" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bruttoertrag", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "-0,19 €", + "displayValue": { + "text": "-0,19 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-0,19 €", + "displayValue": { + "text": "-0,19 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Vorabpauschale", + "detail": "28.02.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "4e227b8e-63c5-49a1-8e0b-adf8aaa6b81a", + "postboxType": "CA_VOPA_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/wertpapiertransfer_in.json b/tests/events/wertpapiertransfer_in.json new file mode 100644 index 00000000..59b0f477 --- /dev/null +++ b/tests/events/wertpapiertransfer_in.json @@ -0,0 +1,82 @@ +{ + "id": "6471c9c6-445d-4309-bb41-a29d8b3d24ba", + "timestamp": "2023-06-13T20:38:45.991+0000", + "title": "Metro", + "icon": "logos/DE000BFB0019/v2", + "subtitle": "Wertpapiertransfer", + "action": { + "type": "timelineDetail", + "payload": "6471c9c6-445d-4309-bb41-a29d8b3d24ba" + }, + "source": "timelineActivity", + "details": { + "id": "6471c9c6-445d-4309-bb41-a29d8b3d24ba", + "sections": [ + { + "title": "Du hast 76 Aktien erhalten", + "data": { + "icon": "logos/DE000BFB0019/v2", + "subtitleText": null, + "timestamp": "2023-06-13T20:38:45.991+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "DE000BFB0019" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertpapiertransfer", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteile", + "detail": { + "text": "76", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteil", + "detail": { + "text": "Metro", + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "13.06.2023", + "id": "3f4fcb77-fe00-45f6-bd03-23621e27a1f6", + "postboxType": "SHAREBOOKING" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/wertpapiertransfer_in_legacy.json b/tests/events/wertpapiertransfer_in_legacy.json new file mode 100644 index 00000000..d539a9e8 --- /dev/null +++ b/tests/events/wertpapiertransfer_in_legacy.json @@ -0,0 +1,83 @@ +{ + "id": "a1b2c3d4-e5f6-7890-ab12-cd34ef567890", + "timestamp": "2022-04-10T10:15:30.000+0000", + "title": "Metro", + "icon": "logos/DE000BFB0019/v2", + "subtitle": "Wertpapiertransfer", + "eventType": "timeline_legacy_migrated_events", + "action": { + "type": "timelineDetail", + "payload": "a1b2c3d4-e5f6-7890-ab12-cd34ef567890" + }, + "source": "timelineActivity", + "details": { + "id": "a1b2c3d4-e5f6-7890-ab12-cd34ef567890", + "sections": [ + { + "title": "Du hast 76 Aktien erhalten", + "data": { + "icon": "logos/DE000BFB0019/v2", + "subtitleText": null, + "timestamp": "2022-04-10T10:15:30.000+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "DE000BFB0019" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertpapiertransfer", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteile", + "detail": { + "text": "76", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteil", + "detail": { + "text": "Metro", + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "10.04.2022", + "id": "b2c3d4e5-f6a7-8901-bc23-de45fg678901", + "postboxType": "SHAREBOOKING" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/wertpapiertransfer_out.json b/tests/events/wertpapiertransfer_out.json new file mode 100644 index 00000000..6b08dc26 --- /dev/null +++ b/tests/events/wertpapiertransfer_out.json @@ -0,0 +1,82 @@ +{ + "id": "7582dac7-556e-5410-cc52-b30e9c4e35cb", + "timestamp": "2024-03-15T14:22:33.456+0000", + "title": "Netflix", + "icon": "logos/US64110L1061/v2", + "subtitle": "Wertpapiertransfer", + "action": { + "type": "timelineDetail", + "payload": "7582dac7-556e-5410-cc52-b30e9c4e35cb" + }, + "source": "timelineActivity", + "details": { + "id": "7582dac7-556e-5410-cc52-b30e9c4e35cb", + "sections": [ + { + "title": "Du hast 4 Aktien gesendet", + "data": { + "icon": "logos/US64110L1061/v2", + "subtitleText": null, + "timestamp": "2024-03-15T14:22:33.456+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "US64110L1061" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertpapiertransfer", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteile", + "detail": { + "text": "4", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteil", + "detail": { + "text": "Netflix", + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "15.03.2024", + "id": "4g5gdc88-gf11-56g7-ce04-34732f38b2g7", + "postboxType": "SHAREBOOKING" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/wertpapiertransfer_out_legacy.json b/tests/events/wertpapiertransfer_out_legacy.json new file mode 100644 index 00000000..19283798 --- /dev/null +++ b/tests/events/wertpapiertransfer_out_legacy.json @@ -0,0 +1,83 @@ +{ + "id": "b2c3d4e5-f6a7-8901-bc23-de45fg678901", + "timestamp": "2022-05-20T16:45:00.000+0000", + "title": "Netflix", + "icon": "logos/US64110L1061/v2", + "subtitle": "Wertpapiertransfer", + "eventType": "timeline_legacy_migrated_events", + "action": { + "type": "timelineDetail", + "payload": "b2c3d4e5-f6a7-8901-bc23-de45fg678901" + }, + "source": "timelineActivity", + "details": { + "id": "b2c3d4e5-f6a7-8901-bc23-de45fg678901", + "sections": [ + { + "title": "Du hast 4 Aktien gesendet", + "data": { + "icon": "logos/US64110L1061/v2", + "subtitleText": null, + "timestamp": "2022-05-20T16:45:00.000+0000", + "status": "executed" + }, + "action": { + "type": "instrumentDetail", + "payload": "US64110L1061" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Completed", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Wertpapiertransfer", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteile", + "detail": { + "text": "4", + "type": "text" + }, + "style": "plain" + }, + { + "title": "Anteil", + "detail": { + "text": "Netflix", + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Abrechnung", + "detail": "20.05.2022", + "id": "c3d4e5f6-a7b8-9012-cd34-ef56gh789012", + "postboxType": "SHAREBOOKING" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zinsen.json b/tests/events/zinsen.json new file mode 100644 index 00000000..1b05c07e --- /dev/null +++ b/tests/events/zinsen.json @@ -0,0 +1,180 @@ +{ + "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", + "timestamp": "2025-07-01T06:46:37.846+0000", + "title": "Zinsen", + "icon": "logos/timeline_interest_new/v2", + "avatar": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "badge": null, + "subtitle": "2 % p.a.", + "amount": { + "currency": "EUR", + "value": 4.87, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36" + }, + "eventType": "INTEREST_PAYOUT", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", + "sections": [ + { + "title": "Du hast 4,87 € erhalten", + "data": { + "icon": "logos/timeline_interest_new/v2", + "timestamp": "2025-07-01T06:46:42.342175Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Durchschnittssaldo", + "detail": { + "text": "3.900,38 €", + "displayValue": { + "text": "3.900,38 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Jährliche Rate", + "detail": { + "text": "2.00 %", + "displayValue": { + "text": "2.00 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Cash", + "displayValue": { + "text": "Cash" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Status", + "steps": [ + { + "leading": { + "avatar": { + "status": "completed", + "type": "bullet" + }, + "connection": { + "order": "first" + } + }, + "content": { + "title": "Zinsberechnung", + "timestamp": "2025-07-01T06:46:42.342175Z" + } + }, + { + "leading": { + "avatar": { + "status": "completed", + "type": "bullet" + }, + "connection": { + "order": "last" + } + }, + "content": { + "title": "Zinszahlung", + "timestamp": "2025-07-01T06:46:42.342175Z" + } + } + ], + "type": "steps" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Angesammelt", + "detail": { + "text": "6,74 €", + "displayValue": { + "text": "6,74 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "1,87 €", + "displayValue": { + "text": "1,87 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "4,87 €", + "displayValue": { + "text": "4,87 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "3a982728-a476-44cd-bce9-aaa520b55f6f", + "postboxType": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zinsen2.json b/tests/events/zinsen2.json new file mode 100644 index 00000000..c3ec6d82 --- /dev/null +++ b/tests/events/zinsen2.json @@ -0,0 +1,111 @@ +{ + "id": "019fbb5c-1c9a-7ce5-86d0-ab2193a92104", + "timestamp": "2026-08-01T03:26:43.866+0000", + "title": "Zinsen", + "icon": "logos/timeline_interest_new/v2", + "avatar": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "badge": null, + "subtitle": null, + "amount": { + "currency": "EUR", + "value": 6.41, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "019fbb5c-1c9a-7ce5-86d0-ab2193a92104" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "INTEREST_PAYOUT", + "source": "timelineTransaction", + "details": { + "id": "019fbb5c-1c9a-7ce5-86d0-ab2193a92104", + "sections": [ + { + "title": "Du hast 6,41 € erhalten", + "data": { + "icon": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "subtitleText": "1 Aug. · 07:12", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Zinsen", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Angesammelt", + "detail": { + "text": "8,86 €", + "displayValue": { + "text": "8,86 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "2,45 €", + "displayValue": { + "text": "2,45 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "6,41 €", + "displayValue": { + "text": "6,41 €", + "textDataSensitivity": "PUBLIC" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Bescheinigung", + "action": { + "payload": "", + "type": "authenticatedBrowserModal" + }, + "id": "019fbb5c-1c9a-7ce5-86d0-ab2193a92104", + "postboxType": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zinsen_no_eventType.json b/tests/events/zinsen_no_eventType.json new file mode 100644 index 00000000..cbed4d40 --- /dev/null +++ b/tests/events/zinsen_no_eventType.json @@ -0,0 +1,179 @@ +{ + "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", + "timestamp": "2025-07-01T06:46:37.846+0000", + "title": "Zinsen", + "icon": "logos/timeline_interest_new/v2", + "avatar": { + "asset": "logos/timeline_interest_new/v2", + "badge": null + }, + "badge": null, + "subtitle": "2 % p.a.", + "amount": { + "currency": "EUR", + "value": 4.87, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", + "sections": [ + { + "title": "Du hast 4,87 € erhalten", + "data": { + "icon": "logos/timeline_interest_new/v2", + "timestamp": "2025-07-01T06:46:42.342175Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Durchschnittssaldo", + "detail": { + "text": "3.900,38 €", + "displayValue": { + "text": "3.900,38 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Jährliche Rate", + "detail": { + "text": "2.00 %", + "displayValue": { + "text": "2.00 %" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Asset", + "detail": { + "text": "Cash", + "displayValue": { + "text": "Cash" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Status", + "steps": [ + { + "leading": { + "avatar": { + "status": "completed", + "type": "bullet" + }, + "connection": { + "order": "first" + } + }, + "content": { + "title": "Zinsberechnung", + "timestamp": "2025-07-01T06:46:42.342175Z" + } + }, + { + "leading": { + "avatar": { + "status": "completed", + "type": "bullet" + }, + "connection": { + "order": "last" + } + }, + "content": { + "title": "Zinszahlung", + "timestamp": "2025-07-01T06:46:42.342175Z" + } + } + ], + "type": "steps" + }, + { + "title": "Transaktion", + "data": [ + { + "title": "Angesammelt", + "detail": { + "text": "6,74 €", + "displayValue": { + "text": "6,74 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuern", + "detail": { + "text": "1,87 €", + "displayValue": { + "text": "1,87 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "4,87 €", + "displayValue": { + "text": "4,87 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokument", + "data": [ + { + "title": "Abrechnung", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "3a982728-a476-44cd-bce9-aaa520b55f6f", + "postboxType": "" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zusammenschluss.json b/tests/events/zusammenschluss.json new file mode 100644 index 00000000..1f5df481 --- /dev/null +++ b/tests/events/zusammenschluss.json @@ -0,0 +1,113 @@ +{ + "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", + "timestamp": "2025-05-29T13:04:58.676+0000", + "title": "Rocket Lab USA", + "icon": "logos/US7731221062/v2", + "subtitle": "Zusammenschluss", + "action": { + "type": "timelineDetail", + "payload": "1957e12e-a7f6-396c-97e4-5237b113c45a" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": "logos/US7731221062/v2", + "timestamp": "2025-05-29T13:04:58.676Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Zusammenschluss", + "displayValue": { + "text": "Zusammenschluss" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Rocket Lab USA", + "displayValue": { + "text": "Rocket Lab USA" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "5.943100", + "displayValue": { + "text": "5.943100" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ROCKET LAB CORP. O.N.", + "displayValue": { + "text": "ROCKET LAB CORP. O.N." + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.943100", + "displayValue": { + "text": "5.943100" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "29.05.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "86a172b6-39e7-4d8f-9637-24b4feed62c6", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zusammenschluss2.json b/tests/events/zusammenschluss2.json new file mode 100644 index 00000000..89346337 --- /dev/null +++ b/tests/events/zusammenschluss2.json @@ -0,0 +1,119 @@ +{ + "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", + "timestamp": "2025-05-29T13:04:58.676+0000", + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "icon": "logos/US7731221062/v2", + "subtitle": "Zusammenschluss", + "action": { + "type": "timelineDetail", + "payload": "1957e12e-a7f6-396c-97e4-5237b113c45a" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_ACTIVITY", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": { + "asset": "logos/US7731221062/v2", + "badge": null + }, + "timestamp": "2025-05-29T13:04:58.676Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Zusammenschluss", + "displayValue": { + "text": "Zusammenschluss" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Rocket Lab USA", + "displayValue": { + "text": "Rocket Lab USA" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "5.943100", + "displayValue": { + "text": "5.943100" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ROCKET LAB CORP. O.N.", + "displayValue": { + "text": "ROCKET LAB CORP. O.N." + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.943100", + "displayValue": { + "text": "5.943100" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "29.05.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "86a172b6-39e7-4d8f-9637-24b4feed62c6", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zusammenschluss_no_eventType.json b/tests/events/zusammenschluss_no_eventType.json new file mode 100644 index 00000000..002805a1 --- /dev/null +++ b/tests/events/zusammenschluss_no_eventType.json @@ -0,0 +1,112 @@ +{ + "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", + "timestamp": "2025-05-29T13:04:58.676+0000", + "title": "Rocket Lab USA", + "icon": "logos/US7731221062/v2", + "subtitle": "Zusammenschluss", + "action": { + "type": "timelineDetail", + "payload": "1957e12e-a7f6-396c-97e4-5237b113c45a" + }, + "source": "timelineActivity", + "details": { + "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", + "sections": [ + { + "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", + "data": { + "icon": "logos/US7731221062/v2", + "timestamp": "2025-05-29T13:04:58.676Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Zusammenschluss", + "displayValue": { + "text": "Zusammenschluss" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Rocket Lab USA", + "displayValue": { + "text": "Rocket Lab USA" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "5.943100", + "displayValue": { + "text": "5.943100" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ROCKET LAB CORP. O.N.", + "displayValue": { + "text": "ROCKET LAB CORP. O.N." + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "5.943100", + "displayValue": { + "text": "5.943100" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "29.05.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "86a172b6-39e7-4d8f-9637-24b4feed62c6", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zwischenpapiere.json b/tests/events/zwischenpapiere.json new file mode 100644 index 00000000..e9d8ee77 --- /dev/null +++ b/tests/events/zwischenpapiere.json @@ -0,0 +1,167 @@ +{ + "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", + "timestamp": "2025-10-21T07:39:39.830+0000", + "title": "ORSTED A/S -ANR-", + "icon": "logos/DK0064307839/v2", + "avatar": { + "asset": "logos/DK0064307839/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aufruf von Zwischenpapieren", + "amount": { + "currency": "EUR", + "value": -151.59, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497" + }, + "eventType": "ssp_corporate_action_invoice_cash", + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", + "sections": [ + { + "title": "Du hast -151,59 € bezahlt", + "data": { + "icon": "logos/DK0064307839/v2", + "timestamp": "2025-10-21T07:39:39.83Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aufruf von Zwischenpapieren", + "displayValue": { + "text": "Aufruf von Zwischenpapieren" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S -ANR-", + "displayValue": { + "text": "ORSTED A/S -ANR-" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "119.000000", + "displayValue": { + "text": "119.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S EM.09/25 DK 10", + "displayValue": { + "text": "ORSTED A/S EM.09/25 DK 10" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "17.000000", + "displayValue": { + "text": "17.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bezugspreis", + "detail": { + "text": "-151,59 €", + "displayValue": { + "text": "-151,59 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-151,59 €", + "displayValue": { + "text": "-151,59 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "21.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "bab90597-6a6a-4925-ac20-51d7dd4eea04", + "postboxType": "CA_INCOME_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zwischenpapiere2.json b/tests/events/zwischenpapiere2.json new file mode 100644 index 00000000..c1c6dc10 --- /dev/null +++ b/tests/events/zwischenpapiere2.json @@ -0,0 +1,170 @@ +{ + "id": "6e123939-427f-3a4b-ba6a-ea4621ec4287", + "timestamp": "2026-04-03T09:37:06.806+0000", + "title": "WORLDLINE S.A. ANR", + "icon": "logos/FR0014015MS9/v2", + "avatar": { + "asset": "logos/FR0014015MS9/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aufruf von Zwischenpapieren", + "amount": { + "currency": "EUR", + "value": -1.21, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "6e123939-427f-3a4b-ba6a-ea4621ec4287" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH_AND_STOCK", + "source": "timelineTransaction", + "details": { + "id": "6e123939-427f-3a4b-ba6a-ea4621ec4287", + "sections": [ + { + "title": "Du hast 1,21 € bezahlt", + "data": { + "icon": { + "asset": "logos/FR0014015MS9/v2", + "badge": null + }, + "timestamp": "2026-04-03T09:37:06.806Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aufruf von Zwischenpapieren", + "displayValue": { + "text": "Aufruf von Zwischenpapieren" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "WORLDLINE S.A. ANR", + "displayValue": { + "text": "WORLDLINE S.A. ANR" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "1.000000", + "displayValue": { + "text": "1.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Worldline", + "displayValue": { + "text": "Worldline" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "6.000000", + "displayValue": { + "text": "6.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bezugspreis", + "detail": { + "text": "-1,21 €", + "displayValue": { + "text": "-1,21 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-1,21 €", + "displayValue": { + "text": "-1,21 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "03.04.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "a3753865-4171-46f8-95b1-c31d2f67ac3c", + "postboxType": "CA_INCOME_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zwischenpapiere3.json b/tests/events/zwischenpapiere3.json new file mode 100644 index 00000000..4e560637 --- /dev/null +++ b/tests/events/zwischenpapiere3.json @@ -0,0 +1,159 @@ +{ + "id": "85b193b7-37d0-3850-8ab4-3f4a5c49efa7", + "timestamp": "2026-04-03T10:38:58.939+0000", + "title": "WORLDLINE S.A. ANR", + "icon": "logos/FR0014015MS9/v2", + "avatar": { + "asset": "logos/FR0014015MS9/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aufruf von Zwischenpapieren", + "amount": { + "currency": "EUR", + "value": -261.39, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "85b193b7-37d0-3850-8ab4-3f4a5c49efa7" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "eventType": "SSP_CORPORATE_ACTION_CASH_AND_STOCK", + "source": "timelineTransaction", + "details": { + "id": "85b193b7-37d0-3850-8ab4-3f4a5c49efa7", + "sections": [ + { + "title": "Du hast 261,39 € bezahlt", + "data": { + "icon": { + "asset": "logos/FR0014015MS9/v2", + "badge": null + }, + "timestamp": "2026-04-03T10:38:58.939Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aufruf von Zwischenpapieren", + "displayValue": { + "text": "Aufruf von Zwischenpapieren" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "WORLDLINE S.A. ANR", + "displayValue": { + "text": "WORLDLINE S.A. ANR" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "Worldline", + "displayValue": { + "text": "Worldline" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "1294.000000", + "displayValue": { + "text": "1294.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bezugspreis", + "detail": { + "text": "-261,39 €", + "displayValue": { + "text": "-261,39 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-261,39 €", + "displayValue": { + "text": "-261,39 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "03.04.2026", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "77ac06a1-260f-472b-ae42-83eec5ec679a", + "postboxType": "CA_INCOME_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zwischenpapiere_no_eventType.json b/tests/events/zwischenpapiere_no_eventType.json new file mode 100644 index 00000000..9300170c --- /dev/null +++ b/tests/events/zwischenpapiere_no_eventType.json @@ -0,0 +1,166 @@ +{ + "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", + "timestamp": "2025-10-21T07:39:39.830+0000", + "title": "ORSTED A/S -ANR-", + "icon": "logos/DK0064307839/v2", + "avatar": { + "asset": "logos/DK0064307839/v2", + "badge": null + }, + "badge": null, + "subtitle": "Aufruf von Zwischenpapieren", + "amount": { + "currency": "EUR", + "value": -151.59, + "fractionDigits": 2 + }, + "subAmount": null, + "status": "EXECUTED", + "action": { + "type": "timelineDetail", + "payload": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497" + }, + "cashAccountNumber": "123456789", + "hidden": false, + "deleted": false, + "source": "timelineTransaction", + "details": { + "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", + "sections": [ + { + "title": "Du hast -151,59 € bezahlt", + "data": { + "icon": "logos/DK0064307839/v2", + "timestamp": "2025-10-21T07:39:39.83Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Event", + "detail": { + "text": "Aufruf von Zwischenpapieren", + "displayValue": { + "text": "Aufruf von Zwischenpapieren" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S -ANR-", + "displayValue": { + "text": "ORSTED A/S -ANR-" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien entfernt", + "detail": { + "text": "119.000000", + "displayValue": { + "text": "119.000000" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S EM.09/25 DK 10", + "displayValue": { + "text": "ORSTED A/S EM.09/25 DK 10" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "17.000000", + "displayValue": { + "text": "17.000000" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Geschäft", + "data": [ + { + "title": "Bezugspreis", + "detail": { + "text": "-151,59 €", + "displayValue": { + "text": "-151,59 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Steuer", + "detail": { + "text": "0,00 €", + "displayValue": { + "text": "0,00 €" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Gesamt", + "detail": { + "text": "-151,59 €", + "displayValue": { + "text": "-151,59 €" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "21.10.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "bab90597-6a6a-4925-ac20-51d7dd4eea04", + "postboxType": "CA_INCOME_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zwischenvertrieb.json b/tests/events/zwischenvertrieb.json new file mode 100644 index 00000000..e5b994e3 --- /dev/null +++ b/tests/events/zwischenvertrieb.json @@ -0,0 +1,91 @@ +{ + "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", + "timestamp": "2025-09-19T12:02:49.989+0000", + "title": "Orsted", + "icon": "logos/DK0060094928/v2", + "subtitle": "Zwischenvertrieb von Wertpapieren", + "action": { + "type": "timelineDetail", + "payload": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402" + }, + "eventType": "ssp_corporate_action_invoice_shares", + "source": "timelineActivity", + "details": { + "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/DK0060094928/v2", + "timestamp": "2025-09-19T12:02:49.989Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Zwischenvertrieb von Wertpapieren", + "displayValue": { + "text": "Zwischenvertrieb von Wertpapieren" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S -ANR-", + "displayValue": { + "text": "ORSTED A/S -ANR-" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "119.285835", + "displayValue": { + "text": "119.285835" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "19.09.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "aebaf075-9a89-4d0d-836a-be61e4ad7725", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/events/zwischenvertrieb2.json b/tests/events/zwischenvertrieb2.json new file mode 100644 index 00000000..cdcc4133 --- /dev/null +++ b/tests/events/zwischenvertrieb2.json @@ -0,0 +1,83 @@ +{ + "id": "11eb2e1f-e50c-3bb3-900d-d03028fed19d", + "timestamp": "2026-03-17T10:45:33.497+0000", + "title": "Worldline", + "icon": "logos/FR0011981968/v2", + "subtitle": "Zwischenvertrieb von Wertpapieren", + "action": { + "type": "timelineDetail", + "payload": "11eb2e1f-e50c-3bb3-900d-d03028fed19d" + }, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "11eb2e1f-e50c-3bb3-900d-d03028fed19d", + "sections": [ + { + "type": "header", + "title": "You received shares", + "data": { + "status": "executed", + "icon": "logos/FR0011981968/v2", + "timestamp": "2026-03-17T10:45:33.497510Z" + } + }, + { + "type": "table", + "title": "Overview", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Completed", + "functionalStyle": "EXECUTED" + } + }, + { + "title": "Event", + "style": "plain", + "detail": { + "type": "text", + "text": "Intermediate securities distribution" + } + }, + { + "title": "Asset", + "style": "plain", + "detail": { + "type": "text", + "text": "Worldline" + } + }, + { + "title": "Shares", + "style": "plain", + "detail": { + "type": "text", + "text": "1.299376" + } + } + ] + }, + { + "type": "documents", + "title": "Documents", + "data": [ + { + "id": "17d6cca1-9c15-4817-b865-fc119780e7ae", + "title": "Intermediate securities distribution", + "action": { + "type": "browserModal", + "payload": "" + }, + "postboxType": "INTERMEDIATE_SECURITIES_DISTRIBUTION" + } + ] + } + ] + } +} diff --git a/tests/events/zwischenvertrieb3.json b/tests/events/zwischenvertrieb3.json new file mode 100644 index 00000000..ac2bbb88 --- /dev/null +++ b/tests/events/zwischenvertrieb3.json @@ -0,0 +1,69 @@ +{ + "id": "e613ddd9-8fab-307d-bc39-44d2985fc5d4", + "timestamp": "2026-06-29T09:09:14.897+0000", + "title": "OHB", + "icon": "logos/DE0005936124/v2", + "subtitle": "Zwischenvertrieb von Wertpapieren", + "action": { + "type": "timelineDetail", + "payload": "e613ddd9-8fab-307d-bc39-44d2985fc5d4" + }, + "trailing": null, + "eventType": "SSP_CORPORATE_ACTION_NO_CASH", + "hidden": false, + "deleted": false, + "source": "timelineActivity", + "details": { + "id": "e613ddd9-8fab-307d-bc39-44d2985fc5d4", + "sections": [ + { + "type": "header", + "title": "Du hast Aktien erhalten", + "data": { + "status": "executed", + "icon": "logos/DE0005936124/v2", + "timestamp": "2026-06-29T09:09:14.897948Z" + } + }, + { + "type": "table", + "title": "Überblick", + "data": [ + { + "title": "Status", + "style": "plain", + "detail": { + "type": "status", + "text": "Abgeschlossen", + "functionalStyle": "EXECUTED" + } + }, + { + "title": "Ereignis", + "style": "plain", + "detail": { + "type": "text", + "text": "Zwischenausschüttung von Wertpapieren" + } + }, + { + "title": "Vermögenswert", + "style": "plain", + "detail": { + "type": "text", + "text": "OHB" + } + }, + { + "title": "Aktien", + "style": "plain", + "detail": { + "type": "text", + "text": "1.026415" + } + } + ] + } + ] + } +} diff --git a/tests/events/zwischenvertrieb_no_eventType.json b/tests/events/zwischenvertrieb_no_eventType.json new file mode 100644 index 00000000..72421633 --- /dev/null +++ b/tests/events/zwischenvertrieb_no_eventType.json @@ -0,0 +1,90 @@ +{ + "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", + "timestamp": "2025-09-19T12:02:49.989+0000", + "title": "Orsted", + "icon": "logos/DK0060094928/v2", + "subtitle": "Zwischenvertrieb von Wertpapieren", + "action": { + "type": "timelineDetail", + "payload": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402" + }, + "source": "timelineActivity", + "details": { + "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", + "sections": [ + { + "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", + "data": { + "icon": "logos/DK0060094928/v2", + "timestamp": "2025-09-19T12:02:49.989Z", + "status": "executed" + }, + "type": "header" + }, + { + "title": "Übersicht", + "data": [ + { + "title": "Status", + "detail": { + "text": "Ausgeführt", + "functionalStyle": "EXECUTED", + "type": "status" + }, + "style": "plain" + }, + { + "title": "Orderart", + "detail": { + "text": "Zwischenvertrieb von Wertpapieren", + "displayValue": { + "text": "Zwischenvertrieb von Wertpapieren" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Wertpapier", + "detail": { + "text": "ORSTED A/S -ANR-", + "displayValue": { + "text": "ORSTED A/S -ANR-" + }, + "type": "text" + }, + "style": "plain" + }, + { + "title": "Aktien hinzugefügt", + "detail": { + "text": "119.285835", + "displayValue": { + "text": "119.285835" + }, + "type": "text" + }, + "style": "plain" + } + ], + "type": "table" + }, + { + "title": "Dokumente", + "data": [ + { + "title": "Dokumente", + "detail": "19.09.2025", + "action": { + "payload": "", + "type": "browserModal" + }, + "id": "aebaf075-9a89-4d0d-836a-be61e4ad7725", + "postboxType": "CA_SECURITIES_INVOICE" + } + ], + "type": "documents" + } + ] + } +} diff --git a/tests/incoming_transfer.json b/tests/incoming_transfer.json deleted file mode 100644 index 23f87686..00000000 --- a/tests/incoming_transfer.json +++ /dev/null @@ -1,112 +0,0 @@ - { - "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", - "timestamp": "2024-09-02T17:49:12.516+0000", - "title": "Klaus Mustermann", - "icon": "logos/contacts-C-Lightblue/v2", - "avatar": { - "asset": "logos/contacts-C-Lightblue/v2", - "badge": null - }, - "badge": null, - "subtitle": "Fertig", - "amount": { - "currency": "EUR", - "value": 88.04, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439" - }, - "eventType": "INCOMING_TRANSFER", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", - "sections": [ - { - "title": "Du hast 88,04 € von Klaus Mustermann erhalten", - "data": { - "icon": "logos/contacts-C-Lightblue/v2", - "timestamp": "2024-09-02T17:49:12.516Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Referenz", - "detail": { - "text": "Referenz Text", - "displayValue": { - "text": "Referenz Text" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Absender", - "data": [ - { - "title": "Name", - "detail": { - "text": "Klaus Mustermann", - "displayValue": { - "text": "Klaus Mustermann" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "12345", - "displayValue": { - "text": "12345" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "detail": "02.09.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "53e0fc86-840d-4dba-8e74-2a56ab6b73d4", - "postboxType": "INCOMING_TRANSFER" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/incoming_transfer_delegation.json b/tests/incoming_transfer_delegation.json deleted file mode 100644 index 0cfbfc7f..00000000 --- a/tests/incoming_transfer_delegation.json +++ /dev/null @@ -1,96 +0,0 @@ -{ - "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", - "timestamp": "2024-09-10T13:18:31.478+0000", - "title": "Vorname Nachname", - "icon": "logos/contacts-M-Magenta/v2", - "badge": null, - "subtitle": "Fertig", - "amount": { - "currency": "EUR", - "value": 3000.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a" - }, - "eventType": "INCOMING_TRANSFER_DELEGATION", - "source": "timelineTransaction", - "details": { - "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", - "sections": [ - { - "title": "Du hast €3000.00 von Vorname Nachname erhalten", - "data": { - "icon": "logos/contacts-M-Magenta/v2", - "timestamp": "2024-09-10T13:18:31.475+0000", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "style": "plain", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - } - }, - { - "title": "Referenz", - "style": "plain", - "detail": { - "text": "Received by TradeRepublic", - "type": "text" - } - } - ], - "type": "table" - }, - { - "title": "Absender", - "data": [ - { - "title": "Name", - "style": "plain", - "detail": { - "text": "Vorname Nachname", - "type": "text" - } - }, - { - "title": "IBAN", - "style": "plain", - "detail": { - "text": "DEXX XXXX XXXX XXXX XXXX XX", - "type": "text" - } - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4254e648-e0da-4e0a-94be-c95499b35d9a", - "postboxType": "INCOMING_TRANSFER", - "local filepath": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/incoming_transfer_delegation_no_eventType.json b/tests/incoming_transfer_delegation_no_eventType.json deleted file mode 100644 index a628b0c3..00000000 --- a/tests/incoming_transfer_delegation_no_eventType.json +++ /dev/null @@ -1,95 +0,0 @@ -{ - "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", - "timestamp": "2024-09-10T13:18:31.478+0000", - "title": "Vorname Nachname", - "icon": "logos/contacts-M-Magenta/v2", - "badge": null, - "subtitle": "Fertig", - "amount": { - "currency": "EUR", - "value": 3000.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a" - }, - "source": "timelineTransaction", - "details": { - "id": "d8a5aa3d-12a4-465a-90ad-3fca36eff19a", - "sections": [ - { - "title": "Du hast €3000.00 von Vorname Nachname erhalten", - "data": { - "icon": "logos/contacts-M-Magenta/v2", - "timestamp": "2024-09-10T13:18:31.475+0000", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "style": "plain", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - } - }, - { - "title": "Referenz", - "style": "plain", - "detail": { - "text": "Received by TradeRepublic", - "type": "text" - } - } - ], - "type": "table" - }, - { - "title": "Absender", - "data": [ - { - "title": "Name", - "style": "plain", - "detail": { - "text": "Vorname Nachname", - "type": "text" - } - }, - { - "title": "IBAN", - "style": "plain", - "detail": { - "text": "DEXX XXXX XXXX XXXX XXXX XX", - "type": "text" - } - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4254e648-e0da-4e0a-94be-c95499b35d9a", - "postboxType": "INCOMING_TRANSFER", - "local filepath": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/incoming_transfer_no_eventType.json b/tests/incoming_transfer_no_eventType.json deleted file mode 100644 index 8de8d026..00000000 --- a/tests/incoming_transfer_no_eventType.json +++ /dev/null @@ -1,111 +0,0 @@ - { - "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", - "timestamp": "2024-09-02T17:49:12.516+0000", - "title": "Klaus Mustermann", - "icon": "logos/contacts-C-Lightblue/v2", - "avatar": { - "asset": "logos/contacts-C-Lightblue/v2", - "badge": null - }, - "badge": null, - "subtitle": "Fertig", - "amount": { - "currency": "EUR", - "value": 88.04, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "6aec5a4c-f424-4b9e-a1c2-1ac2faac3439", - "sections": [ - { - "title": "Du hast 88,04 € von Klaus Mustermann erhalten", - "data": { - "icon": "logos/contacts-C-Lightblue/v2", - "timestamp": "2024-09-02T17:49:12.516Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Referenz", - "detail": { - "text": "Referenz Text", - "displayValue": { - "text": "Referenz Text" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Absender", - "data": [ - { - "title": "Name", - "detail": { - "text": "Klaus Mustermann", - "displayValue": { - "text": "Klaus Mustermann" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "12345", - "displayValue": { - "text": "12345" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "detail": "02.09.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "53e0fc86-840d-4dba-8e74-2a56ab6b73d4", - "postboxType": "INCOMING_TRANSFER" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/junior_p2p_transfer.json b/tests/junior_p2p_transfer.json deleted file mode 100644 index 8b040ea7..00000000 --- a/tests/junior_p2p_transfer.json +++ /dev/null @@ -1,96 +0,0 @@ -{ - "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", - "timestamp": "2025-09-17T19:35:32.658+0000", - "title": "Maria Mueller", - "icon": "logos/contacts-C-Grey/v2", - "avatar": { - "asset": "logos/contacts-C-Grey/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": -50.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "324a06e3-9693-473e-a22c-e9f3a14b8951" - }, - "eventType": "junior_p2p_transfer", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", - "sections": [ - { - "title": "Du hast 50,00 € gesendet", - "data": { - "icon": "logos/contacts-C-Grey/v2", - "timestamp": "2025-09-17T19:35:32.656185Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Überweisen", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Empfänger", - "detail": { - "text": "Maria Mueller", - "trend": "positive", - "displayValue": { - "text": "Maria Mueller" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "50,00 €", - "trend": "positive", - "displayValue": { - "text": "50,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "data": { - "text": "Betreff" - }, - "type": "note" - } - ] - } -} diff --git a/tests/junior_p2p_transfer_no_eventType.json b/tests/junior_p2p_transfer_no_eventType.json deleted file mode 100644 index a5a78f1a..00000000 --- a/tests/junior_p2p_transfer_no_eventType.json +++ /dev/null @@ -1,95 +0,0 @@ -{ - "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", - "timestamp": "2025-09-17T19:35:32.658+0000", - "title": "Maria Mueller", - "icon": "logos/contacts-C-Grey/v2", - "avatar": { - "asset": "logos/contacts-C-Grey/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": -50.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "324a06e3-9693-473e-a22c-e9f3a14b8951" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "324a06e3-9693-473e-a22c-e9f3a14b8951", - "sections": [ - { - "title": "Du hast 50,00 € gesendet", - "data": { - "icon": "logos/contacts-C-Grey/v2", - "timestamp": "2025-09-17T19:35:32.656185Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Überweisen", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Empfänger", - "detail": { - "text": "Maria Mueller", - "trend": "positive", - "displayValue": { - "text": "Maria Mueller" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "50,00 €", - "trend": "positive", - "displayValue": { - "text": "50,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "data": { - "text": "Betreff" - }, - "type": "note" - } - ] - } -} diff --git a/tests/kartenzahlung.json b/tests/kartenzahlung.json deleted file mode 100644 index ae89f68d..00000000 --- a/tests/kartenzahlung.json +++ /dev/null @@ -1,103 +0,0 @@ -{ - "id": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6", - "timestamp": "2025-10-21T17:30:01.281+0000", - "title": "Coop Pronto", - "icon": "logos/merchant-fallback-groceries/v2", - "avatar": { - "asset": "logos/merchant-fallback-groceries/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": -12.16, - "fractionDigits": 2 - }, - "subAmount": { - "currency": "CHF", - "value": -11.2, - "fractionDigits": 2 - }, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6" - }, - "eventType": "card_successful_transaction", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "39a1ecdf-0c09-5e5f-8e31-ba666f1eefe6", - "sections": [ - { - "title": "Du hast 12,16 € ausgegeben", - "data": { - "icon": "logos/merchant-fallback-groceries/v2", - "timestamp": "2025-10-21T17:30:01.281Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kartenzahlung", - "detail": { - "text": "Fertig", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "··5891", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Händler", - "detail": { - "text": "Coop Pronto", - "displayValue": { - "text": "Coop Pronto" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Betrag", - "detail": { - "text": "11,20 CHF", - "displayValue": { - "text": "11,20 CHF" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "12,16 €", - "displayValue": { - "text": "12,16 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/kartenzahlung_no_eventType.json b/tests/kartenzahlung_no_eventType.json deleted file mode 100644 index 3e6750df..00000000 --- a/tests/kartenzahlung_no_eventType.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "809a35a2-99d6-5fcd-ba87-fd618f90710a", - "timestamp": "2025-11-05T11:00:07.718+0000", - "title": "Baecker", - "icon": "logos/merchant-fallback-restaurants/v2", - "avatar": { - "asset": "logos/merchant-fallback-restaurants/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": -2.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "809a35a2-99d6-5fcd-ba87-fd618f90710a" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "809a35a2-99d6-5fcd-ba87-fd618f90710a", - "sections": [ - { - "title": "Du hast 2,00\u00a0\u20ac ausgegeben", - "data": { - "icon": "logos/merchant-fallback-restaurants/v2", - "timestamp": "2025-11-05T11:00:07.718Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Kartenzahlung", - "detail": { - "text": "Fertig", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "\u00b7\u00b75891", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "H\u00e4ndler", - "detail": { - "text": "Baecker", - "displayValue": { - "text": "Baecker" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "2,00\u00a0\u20ac", - "displayValue": { - "text": "2,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/legacy_verkauforder_neu_abgerechnet.json b/tests/legacy_verkauforder_neu_abgerechnet.json deleted file mode 100644 index 5c0220c9..00000000 --- a/tests/legacy_verkauforder_neu_abgerechnet.json +++ /dev/null @@ -1,303 +0,0 @@ -{ - "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", - "timestamp": "2025-02-21T11:14:54.026+0000", - "title": "Marie Brizard Wine and Spirits", - "icon": "logos/FR0000060873/v2", - "avatar": { - "asset": "logos/FR0000060873/v2", - "badge": null - }, - "badge": null, - "subtitle": "Limit Verkauf-Order neu abgerechnet", - "amount": { - "currency": "EUR", - "value": 91.34, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e" - }, - "eventType": "timeline_legacy_migrated_events", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", - "sections": [ - { - "title": "Du hast 91,34 € erhalten", - "data": { - "icon": "logos/FR0000060873/v2", - "subtitleText": null, - "timestamp": "2025-02-21T11:14:54.026+0000", - "status": "executed" - }, - "action": { - "type": "instrumentDetail", - "payload": "FR0000060873" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Limit Verkauf", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Marie Brizard Wine and Spirits", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "8,48 %", - "trend": "negative", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verlust", - "detail": { - "text": "8,56 €", - "trend": "negative", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "horizontalTable" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Anteile", - "detail": { - "text": "27", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "3,42 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 91,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": { - "type": "infoPage", - "payload": { - "sections": [ - { - "title": "Transaktion", - "action": null, - "type": "title" - }, - { - "title": null, - "data": [ - { - "title": "Anteile", - "detail": { - "text": "27", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "3,42 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Order", - "detail": { - "text": "+ 92,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": null, - "data": [ - { - "title": "Order", - "detail": { - "text": "+ 92,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 91,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - } - ] - } - }, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung 2", - "detail": "27.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "b0f0a8e4-b8cf-4878-aa70-3e772d163f49", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Abrechnung 1", - "detail": "21.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "42b598ad-9c8e-440e-868e-37cfc3c44dcc", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Auftragsbestätigung", - "detail": "21.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "0f9ee818-3567-4a82-8986-448e62c4b92d", - "postboxType": "CONFIRM_ORDER_CREATE_V2" - }, - { - "title": "Kosteninformation", - "detail": "21.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "4868af5a-277c-4f31-a8a9-e703e5f24fb2", - "postboxType": "COSTS_INFO_SELL_V2" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/legacy_verkauforder_neu_abgerechnet_no_eventType.json b/tests/legacy_verkauforder_neu_abgerechnet_no_eventType.json deleted file mode 100644 index 18c562be..00000000 --- a/tests/legacy_verkauforder_neu_abgerechnet_no_eventType.json +++ /dev/null @@ -1,302 +0,0 @@ -{ - "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", - "timestamp": "2025-02-21T11:14:54.026+0000", - "title": "Marie Brizard Wine and Spirits", - "icon": "logos/FR0000060873/v2", - "avatar": { - "asset": "logos/FR0000060873/v2", - "badge": null - }, - "badge": null, - "subtitle": "Limit Verkauf-Order neu abgerechnet", - "amount": { - "currency": "EUR", - "value": 91.34, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "d0506e95-27ae-44b5-a4fb-aabfd70bd28e", - "sections": [ - { - "title": "Du hast 91,34 € erhalten", - "data": { - "icon": "logos/FR0000060873/v2", - "subtitleText": null, - "timestamp": "2025-02-21T11:14:54.026+0000", - "status": "executed" - }, - "action": { - "type": "instrumentDetail", - "payload": "FR0000060873" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Limit Verkauf", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Marie Brizard Wine and Spirits", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "8,48 %", - "trend": "negative", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verlust", - "detail": { - "text": "8,56 €", - "trend": "negative", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "horizontalTable" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Anteile", - "detail": { - "text": "27", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "3,42 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 91,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": { - "type": "infoPage", - "payload": { - "sections": [ - { - "title": "Transaktion", - "action": null, - "type": "title" - }, - { - "title": null, - "data": [ - { - "title": "Anteile", - "detail": { - "text": "27", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "3,42 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Order", - "detail": { - "text": "+ 92,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": null, - "data": [ - { - "title": "Order", - "detail": { - "text": "+ 92,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 91,34 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - } - ] - } - }, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung 2", - "detail": "27.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "b0f0a8e4-b8cf-4878-aa70-3e772d163f49", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Abrechnung 1", - "detail": "21.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "42b598ad-9c8e-440e-868e-37cfc3c44dcc", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Auftragsbestätigung", - "detail": "21.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "0f9ee818-3567-4a82-8986-448e62c4b92d", - "postboxType": "CONFIRM_ORDER_CREATE_V2" - }, - { - "title": "Kosteninformation", - "detail": "21.02.2025", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "4868af5a-277c-4f31-a8a9-e703e5f24fb2", - "postboxType": "COSTS_INFO_SELL_V2" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/legacy_zinsen.json b/tests/legacy_zinsen.json deleted file mode 100644 index b7563a41..00000000 --- a/tests/legacy_zinsen.json +++ /dev/null @@ -1,252 +0,0 @@ -{ - "id": "de16f265-0c83-4c40-86b8-9926be9650ae", - "timestamp": "2024-09-01T16:39:48.119+0000", - "title": "Zinsen", - "icon": "logos/timeline_interest_new/v2", - "avatar": { - "asset": "logos/timeline_interest_new/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 11.76, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "de16f265-0c83-4c40-86b8-9926be9650ae" - }, - "eventType": "timeline_legacy_migrated_events", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "de16f265-0c83-4c40-86b8-9926be9650ae", - "sections": [ - { - "title": "Du hast 11,76 EUR erhalten", - "data": { - "icon": "logos/timeline_interest_new/v2", - "subtitleText": null, - "timestamp": "2024-09-01T16:39:48.119+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Durchschnittssaldo", - "detail": { - "text": "5.036,99 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Jahressatz", - "detail": { - "text": "3.75 %", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Vermögenswert", - "detail": { - "text": "Guthaben", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Angefallen", - "detail": { - "text": "+ 16,27 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "4,51 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 11,76 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": { - "type": "infoPage", - "payload": { - "sections": [ - { - "title": "Transaktion", - "action": null, - "type": "title" - }, - { - "title": null, - "data": [ - { - "title": "Kapitalertragsteuer", - "detail": { - "text": "3,99 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Kirchensteuer", - "detail": { - "text": "0,31 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Solidaritätszuschlag", - "detail": { - "text": "0,21 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "4,51 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": null, - "data": [ - { - "title": "Angefallen", - "detail": { - "text": "+ 16,27 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "4,51 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 11,76 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - } - ] - } - }, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": "01.09.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "e4850346-b2a5-43ee-96ea-e093750badff", - "postboxType": "INTEREST_PAYOUT_INVOICE" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/legacy_zinsen_no_eventType.json b/tests/legacy_zinsen_no_eventType.json deleted file mode 100644 index 7902f7d8..00000000 --- a/tests/legacy_zinsen_no_eventType.json +++ /dev/null @@ -1,251 +0,0 @@ -{ - "id": "de16f265-0c83-4c40-86b8-9926be9650ae", - "timestamp": "2024-09-01T16:39:48.119+0000", - "title": "Zinsen", - "icon": "logos/timeline_interest_new/v2", - "avatar": { - "asset": "logos/timeline_interest_new/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 11.76, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "de16f265-0c83-4c40-86b8-9926be9650ae" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "de16f265-0c83-4c40-86b8-9926be9650ae", - "sections": [ - { - "title": "Du hast 11,76 EUR erhalten", - "data": { - "icon": "logos/timeline_interest_new/v2", - "subtitleText": null, - "timestamp": "2024-09-01T16:39:48.119+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Durchschnittssaldo", - "detail": { - "text": "5.036,99 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Jahressatz", - "detail": { - "text": "3.75 %", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Vermögenswert", - "detail": { - "text": "Guthaben", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Angefallen", - "detail": { - "text": "+ 16,27 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "4,51 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 11,76 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": { - "type": "infoPage", - "payload": { - "sections": [ - { - "title": "Transaktion", - "action": null, - "type": "title" - }, - { - "title": null, - "data": [ - { - "title": "Kapitalertragsteuer", - "detail": { - "text": "3,99 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Kirchensteuer", - "detail": { - "text": "0,31 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Solidaritätszuschlag", - "detail": { - "text": "0,21 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "4,51 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": null, - "data": [ - { - "title": "Angefallen", - "detail": { - "text": "+ 16,27 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "4,51 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "+ 11,76 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - } - ] - } - }, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": "01.09.2024", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "e4850346-b2a5-43ee-96ea-e093750badff", - "postboxType": "INTEREST_PAYOUT_INVOICE" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/limit-sell-order.json b/tests/limit-sell-order.json deleted file mode 100644 index 7778f1fe..00000000 --- a/tests/limit-sell-order.json +++ /dev/null @@ -1,280 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-05-20T08:03:45.106+0000", - "title": "D-Wave Quantum", - "icon": "logos/US26740W1099/v2", - "badge": null, - "subtitle": "Limit-Sell-Order", - "amount": { - "currency": "EUR", - "value": 114.91, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "eventType": "trading_trade_executed", - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 114,91 € erhalten", - "data": { - "icon": "logos/US26740W1099/v2", - "subtitleText": null, - "timestamp": "2025-05-20T08:03:45.106+0000", - "status": "executed" - }, - "action": { - "payload": "US26740W1099", - "type": "instrumentDetail", - "overrideAction": null - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Limit Order", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "action": null, - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "D-Wave Quantum", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "", - "trend": null, - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "action": null, - "type": "title" - }, - { - "title": null, - "data": [ - { - "title": "Aktien", - "detail": { - "text": "11", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "12,12 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "133,27 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - }, - "type": "infoPage", - "overrideAction": null - }, - "displayValue": { - "text": "12,12 €", - "prefix": "11 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "17,36 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "114,91 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "89,42 %", - "trend": "positive", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "62,44 €", - "trend": "positive", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Auftragsbestätigung", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "12345678", - "postboxType": "ORDER_CONFIRMATION" - }, - { - "title": "Kosteninformation", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "12345678", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Abrechnung", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "c973a255-89aa-48ba-931a-4ff94fbb56ec", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "action": null, - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "chat_flow_key": "NHC_0029_wealth_buying_selling_past_trade_execution", - "timelineEventId": "12345678", - "primId": "" - } - }, - "type": "customerSupportChat", - "overrideAction": null - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - } - } diff --git a/tests/limit-sell-order_no_eventType.json b/tests/limit-sell-order_no_eventType.json deleted file mode 100644 index 73c05f0c..00000000 --- a/tests/limit-sell-order_no_eventType.json +++ /dev/null @@ -1,268 +0,0 @@ -{ - "id": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf", - "timestamp": "2025-11-05T12:03:19.648+0000", - "title": "Teva Pharmaceutical Industries (ADR)", - "icon": "logos/US8816242098/v2", - "avatar": { - "asset": "logos/US8816242098/v2", - "badge": null - }, - "badge": null, - "subtitle": "Limit-Sell-Order", - "amount": { - "currency": "EUR", - "value": 139.74, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf", - "sections": [ - { - "title": "Du hast 139,74\u00a0\u20ac erhalten", - "data": { - "icon": "logos/US8816242098/v2", - "timestamp": "2025-11-05T12:03:19.648Z", - "status": "executed" - }, - "action": { - "payload": "US8816242098", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Limit Order", - "detail": { - "text": "Ausgef\u00fchrt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Teva Pharmaceutical Industries (ADR)", - "displayValue": { - "text": "Teva Pharmaceutical Industries (ADR)" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "8 \u00d7 18,55\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "8", - "displayValue": { - "text": "8" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "18,55\u00a0\u20ac", - "displayValue": { - "text": "18,55\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "148,40\u00a0\u20ac", - "displayValue": { - "text": "148,40\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "18,55\u00a0\u20ac", - "prefix": "8 \u00d7 " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "7,66\u00a0\u20ac", - "displayValue": { - "text": "7,66\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "139,74\u00a0\u20ac", - "displayValue": { - "text": "139,74\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "22,96 %", - "trend": "positive", - "displayValue": { - "text": "22,96 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "27,52\u00a0\u20ac", - "trend": "positive", - "displayValue": { - "text": "27,52\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "eb32bdce-1b2a-4a56-882a-24cb814ee867", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Auftragsbest\u00e4tigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "96eccb8a-cca0-47aa-a2aa-ee5427d8eb26", - "postboxType": "ORDER_CONFIRMATION" - }, - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "88b2b6cc-aa38-46e4-bb93-6b54b1dfee32", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "chat_flow_key": "NHC_0029_wealth_buying_selling_past_trade_execution", - "timelineEventId": "89c3a1b3-7af2-4256-ba1b-6a28338ebadf", - "instrumentType": "stock", - "instrumentId": "US8816242098", - "primId": "N1549193313" - } - }, - "type": "customerSupportChat" - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/limit-sell-order_old.json b/tests/limit-sell-order_old.json deleted file mode 100644 index 61eb6e2e..00000000 --- a/tests/limit-sell-order_old.json +++ /dev/null @@ -1,225 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-05-14T07:01:32.079+0000", - "title": "Daimler Truck Holding", - "icon": "logos/DE000DTR0CK8/v2", - "badge": null, - "subtitle": "Limit-Sell-Order", - "amount": { - "currency": "EUR", - "value": 119.37, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "eventType": "trading_trade_executed", - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 119,37 € erhalten", - "data": { - "icon": "logos/DE000DTR0CK8/v2", - "subtitleText": null, - "timestamp": "2025-05-14T07:01:32.079+0000", - "status": "executed" - }, - "action": { - "payload": "DE000DTR0CK8", - "type": "instrumentDetail", - "overrideAction": null - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "action": null, - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Limit Order", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Daimler Truck Holding", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "0,43 %", - "trend": "positive", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "0,51 €", - "trend": "positive", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "horizontalTable" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Aktien", - "detail": { - "text": "3", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "40,17 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,14 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "119,37 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "dd153475-fc29-4ab0-ba00-3ce83247de39", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "ef30342c-838f-4b1f-9ed8-c9d629f3d3a9", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Auftragsbestätigung", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "e1fd1815-65fd-43da-9d80-c51d8aa8eb01", - "postboxType": "ORDER_CONFIRMATION" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/limit-sell-order_old_no_eventType.json b/tests/limit-sell-order_old_no_eventType.json deleted file mode 100644 index 2a127b29..00000000 --- a/tests/limit-sell-order_old_no_eventType.json +++ /dev/null @@ -1,224 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-05-14T07:01:32.079+0000", - "title": "Daimler Truck Holding", - "icon": "logos/DE000DTR0CK8/v2", - "badge": null, - "subtitle": "Limit-Sell-Order", - "amount": { - "currency": "EUR", - "value": 119.37, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 119,37 € erhalten", - "data": { - "icon": "logos/DE000DTR0CK8/v2", - "subtitleText": null, - "timestamp": "2025-05-14T07:01:32.079+0000", - "status": "executed" - }, - "action": { - "payload": "DE000DTR0CK8", - "type": "instrumentDetail", - "overrideAction": null - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "action": null, - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Limit Order", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Daimler Truck Holding", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "0,43 %", - "trend": "positive", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "0,51 €", - "trend": "positive", - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "horizontalTable" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Aktien", - "detail": { - "text": "3", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "40,17 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,14 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "119,37 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "dd153475-fc29-4ab0-ba00-3ce83247de39", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "ef30342c-838f-4b1f-9ed8-c9d629f3d3a9", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Auftragsbestätigung", - "detail": null, - "action": { - "payload": "", - "type": "browserModal", - "overrideAction": null - }, - "id": "e1fd1815-65fd-43da-9d80-c51d8aa8eb01", - "postboxType": "ORDER_CONFIRMATION" - } - ], - "action": null, - "type": "documents" - } - ] - } -} diff --git a/tests/outgoing_transfer.json b/tests/outgoing_transfer.json deleted file mode 100644 index 05e67f81..00000000 --- a/tests/outgoing_transfer.json +++ /dev/null @@ -1,121 +0,0 @@ - { - "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", - "timestamp": "2024-07-21T09:35:47.370+0000", - "title": "Hans Mustermann", - "icon": "logos/contacts-C-Lightblue/v2", - "avatar": { - "asset": "logos/contacts-C-Lightblue/v2", - "badge": null - }, - "badge": null, - "subtitle": "Gesendet", - "amount": { - "currency": "EUR", - "value": -50.3, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "01b0c632-47de-4beb-9b09-6eb8ac42e871" - }, - "eventType": "OUTGOING_TRANSFER", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", - "sections": [ - { - "title": "Du hast -50,30 € an Hans Mustermann gesendet", - "data": { - "icon": "logos/contacts-C-Lightblue/v2", - "timestamp": "2024-07-21T09:35:47.37Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Gesendet mit", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Referenz", - "detail": { - "text": "Sent via Trade Republic", - "displayValue": { - "text": "Sent via Trade Republic" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Empfänger", - "data": [ - { - "title": "Name", - "detail": { - "text": "Hans Mustermann", - "displayValue": { - "text": "Hans Mustermann" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "DE12345", - "displayValue": { - "text": "DE12345" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "detail": "22.07.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "325de7ad-a645-442f-bb14-09a4de5f7fbf", - "postboxType": "OUTGOING_TRANSFER" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/outgoing_transfer_delegation.json b/tests/outgoing_transfer_delegation.json deleted file mode 100644 index c5b7898b..00000000 --- a/tests/outgoing_transfer_delegation.json +++ /dev/null @@ -1,171 +0,0 @@ -{ - "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", - "timestamp": "2025-08-18T12:16:06.806+0000", - "title": "Nina", - "icon": "logos/contacts-N-Grey/v2", - "avatar": { - "asset": "logos/contacts-N-Grey/v2", - "badge": null - }, - "badge": null, - "subtitle": "Gesendet", - "amount": { - "currency": "EUR", - "value": -67.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "e5f930fc-4bb0-47de-919d-94a2d0b3f438" - }, - "eventType": "OUTGOING_TRANSFER_DELEGATION", - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", - "sections": [ - { - "title": "Du hast 67,00 € an Nina gesendet", - "data": { - "icon": "logos/contacts-N-Grey/v2", - "timestamp": "2025-08-18T12:16:06.803132Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Überweisung", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Empfänger", - "detail": { - "text": "Nina", - "displayValue": { - "text": "Nina" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "", - "action": { - "payload": { - "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", - "sections": [ - { - "title": "IBAN", - "data": [ - { - "title": "", - "detail": { - "icon": "logos/bank_default/v2", - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "67,00 €", - "displayValue": { - "text": "67,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "data": { - "text": "text" - }, - "type": "note" - }, - { - "title": "Empfänger", - "data": [ - { - "title": "Empfänger", - "detail": { - "text": "Nina", - "displayValue": { - "text": "Nina" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "", - "displayValue": { - "text": "" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "194eed58-5c67-4b4c-8e62-9d7814038fdf", - "postboxType": "OUTGOING_TRANSFER" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/outgoing_transfer_delegation_no_eventType.json b/tests/outgoing_transfer_delegation_no_eventType.json deleted file mode 100644 index 753109de..00000000 --- a/tests/outgoing_transfer_delegation_no_eventType.json +++ /dev/null @@ -1,170 +0,0 @@ -{ - "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", - "timestamp": "2025-08-18T12:16:06.806+0000", - "title": "Nina", - "icon": "logos/contacts-N-Grey/v2", - "avatar": { - "asset": "logos/contacts-N-Grey/v2", - "badge": null - }, - "badge": null, - "subtitle": "Gesendet", - "amount": { - "currency": "EUR", - "value": -67.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "e5f930fc-4bb0-47de-919d-94a2d0b3f438" - }, - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", - "sections": [ - { - "title": "Du hast 67,00 € an Nina gesendet", - "data": { - "icon": "logos/contacts-N-Grey/v2", - "timestamp": "2025-08-18T12:16:06.803132Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Überweisung", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Empfänger", - "detail": { - "text": "Nina", - "displayValue": { - "text": "Nina" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "", - "action": { - "payload": { - "id": "e5f930fc-4bb0-47de-919d-94a2d0b3f438", - "sections": [ - { - "title": "IBAN", - "data": [ - { - "title": "", - "detail": { - "icon": "logos/bank_default/v2", - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "67,00 €", - "displayValue": { - "text": "67,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "data": { - "text": "text" - }, - "type": "note" - }, - { - "title": "Empfänger", - "data": [ - { - "title": "Empfänger", - "detail": { - "text": "Nina", - "displayValue": { - "text": "Nina" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "", - "displayValue": { - "text": "" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "194eed58-5c67-4b4c-8e62-9d7814038fdf", - "postboxType": "OUTGOING_TRANSFER" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/outgoing_transfer_legacy.json b/tests/outgoing_transfer_legacy.json deleted file mode 100644 index 71534e0c..00000000 --- a/tests/outgoing_transfer_legacy.json +++ /dev/null @@ -1,78 +0,0 @@ -{ - "id": "...", - "timestamp": "2025-04-11T06:44:43.596+0000", - "title": "My Name", - "icon": "logos/timeline_minus_circle/v2", - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": -750.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "..." - }, - "eventType": "timeline_legacy_migrated_events", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "...", - "sections": [ - { - "title": "Du hast 750,00\u00a0\u20ac gesendet", - "data": { - "icon": "logos/timeline_minus_circle/v2", - "subtitleText": null, - "timestamp": "2025-04-11T06:44:43.596+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "An", - "detail": { - "text": "My Name", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "...", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - } -} diff --git a/tests/outgoing_transfer_legacy_no_eventType.json b/tests/outgoing_transfer_legacy_no_eventType.json deleted file mode 100644 index 1d08714f..00000000 --- a/tests/outgoing_transfer_legacy_no_eventType.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "id": "...", - "timestamp": "2025-04-11T06:44:43.596+0000", - "title": "My Name", - "icon": "logos/timeline_minus_circle/v2", - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": -750.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "..." - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "...", - "sections": [ - { - "title": "Du hast 750,00\u00a0\u20ac gesendet", - "data": { - "icon": "logos/timeline_minus_circle/v2", - "subtitleText": null, - "timestamp": "2025-04-11T06:44:43.596+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "An", - "detail": { - "text": "My Name", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "...", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - } -} diff --git a/tests/outgoing_transfer_no_eventType.json b/tests/outgoing_transfer_no_eventType.json deleted file mode 100644 index c1c7c4d7..00000000 --- a/tests/outgoing_transfer_no_eventType.json +++ /dev/null @@ -1,120 +0,0 @@ - { - "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", - "timestamp": "2024-07-21T09:35:47.370+0000", - "title": "Hans Mustermann", - "icon": "logos/contacts-C-Lightblue/v2", - "avatar": { - "asset": "logos/contacts-C-Lightblue/v2", - "badge": null - }, - "badge": null, - "subtitle": "Gesendet", - "amount": { - "currency": "EUR", - "value": -50.3, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "01b0c632-47de-4beb-9b09-6eb8ac42e871" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "01b0c632-47de-4beb-9b09-6eb8ac42e871", - "sections": [ - { - "title": "Du hast -50,30 € an Hans Mustermann gesendet", - "data": { - "icon": "logos/contacts-C-Lightblue/v2", - "timestamp": "2024-07-21T09:35:47.37Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Gesendet mit", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Referenz", - "detail": { - "text": "Sent via Trade Republic", - "displayValue": { - "text": "Sent via Trade Republic" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Empfänger", - "data": [ - { - "title": "Name", - "detail": { - "text": "Hans Mustermann", - "displayValue": { - "text": "Hans Mustermann" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "IBAN", - "detail": { - "text": "DE12345", - "displayValue": { - "text": "DE12345" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Transaktionsbestätigung", - "detail": "22.07.2024", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "325de7ad-a645-442f-bb14-09a4de5f7fbf", - "postboxType": "OUTGOING_TRANSFER" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/payment_inbound_credit_card.json b/tests/payment_inbound_credit_card.json deleted file mode 100644 index 0ebfaaf2..00000000 --- a/tests/payment_inbound_credit_card.json +++ /dev/null @@ -1,141 +0,0 @@ -{ - "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", - "timestamp": "2022-08-27T05:06:30.471+0000", - "title": "Einzahlung", - "icon": "logos/bank_mastercard/v2", - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 1000.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "5b04b073-c06f-4ab1-bd01-de51b56162dc" - }, - "eventType": "PAYMENT_INBOUND_CREDIT_CARD", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", - "sections": [ - { - "title": "Du hast 1.000,00 € über Kreditkarte hinzugefügt", - "data": { - "icon": "logos/bank_mastercard/v2", - "subtitleText": null, - "timestamp": "2022-08-27T05:06:30.471+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Completed", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "·· 7431", - "icon": "logos/bank_mastercard/v2", - "type": "iconWithText" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Gebühr", - "detail": { - "text": "7,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Betrag", - "detail": { - "text": "1.000,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung Einzahlung", - "detail": "27.08.2022", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "4f6f159f-08f1-4573-9b69-2418d57ca37a", - "postboxType": "PAYMENT_INBOUND_INVOICE", - "local_filepath": "" - } - ], - "action": null, - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "type": "customerSupportChat", - "payload": { - "contextParams": { - "chat_flow_key": "NHC_0024_deposit_report_an_issue", - "timelineEventId": "5b04b073-c06f-4ab1-bd01-de51b56162dc", - "createdAt": "2022-08-27T05:06:30.505105Z", - "amount": "1000.000000" - }, - "contextCategory": "NHC" - } - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - }, - "has_docs": true -} \ No newline at end of file diff --git a/tests/payment_inbound_credit_card_no_eventType.json b/tests/payment_inbound_credit_card_no_eventType.json deleted file mode 100644 index 3d22ed46..00000000 --- a/tests/payment_inbound_credit_card_no_eventType.json +++ /dev/null @@ -1,140 +0,0 @@ -{ - "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", - "timestamp": "2022-08-27T05:06:30.471+0000", - "title": "Einzahlung", - "icon": "logos/bank_mastercard/v2", - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 1000.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "5b04b073-c06f-4ab1-bd01-de51b56162dc" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "5b04b073-c06f-4ab1-bd01-de51b56162dc", - "sections": [ - { - "title": "Du hast 1.000,00 € über Kreditkarte hinzugefügt", - "data": { - "icon": "logos/bank_mastercard/v2", - "subtitleText": null, - "timestamp": "2022-08-27T05:06:30.471+0000", - "status": "executed" - }, - "action": null, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Completed", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "·· 7431", - "icon": "logos/bank_mastercard/v2", - "type": "iconWithText" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Gebühr", - "detail": { - "text": "7,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Betrag", - "detail": { - "text": "1.000,00 €", - "trend": null, - "action": null, - "displayValue": null, - "type": "text" - }, - "style": "highlighted" - } - ], - "action": null, - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung Einzahlung", - "detail": "27.08.2022", - "action": { - "type": "browserModal", - "payload": "" - }, - "id": "4f6f159f-08f1-4573-9b69-2418d57ca37a", - "postboxType": "PAYMENT_INBOUND_INVOICE", - "local_filepath": "" - } - ], - "action": null, - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "type": "customerSupportChat", - "payload": { - "contextParams": { - "chat_flow_key": "NHC_0024_deposit_report_an_issue", - "timelineEventId": "5b04b073-c06f-4ab1-bd01-de51b56162dc", - "createdAt": "2022-08-27T05:06:30.505105Z", - "amount": "1000.000000" - }, - "contextCategory": "NHC" - } - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "action": null, - "type": "table" - } - ] - }, - "has_docs": true -} \ No newline at end of file diff --git a/tests/private_markets_order.json b/tests/private_markets_order.json deleted file mode 100644 index 7fdb5940..00000000 --- a/tests/private_markets_order.json +++ /dev/null @@ -1,149 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-09-18T07:15:25.065+0000", - "title": "Private Equity", - "icon": "logos/LU3176111881/v2", - "avatar": { - "asset": "logos/LU3176111881/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -101.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "" - }, - "eventType": "private_markets_order_created", - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "", - "sections": [ - { - "title": "Du hast 101,00\u00a0\u20ac investiert", - "data": { - "icon": "logos/LU3176111881/v2", - "timestamp": "2025-09-18T07:15:25.065819Z", - "status": "executed" - }, - "action": { - "payload": "LU3176111881", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Erstellt", - "functionalStyle": "CREATED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "100,00\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Summe", - "detail": { - "text": "100,00\u00a0\u20ac", - "displayValue": { - "text": "100,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "100,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "101,00\u00a0\u20ac", - "displayValue": { - "text": "101,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "", - "postboxType": "EQUITIES_BUY_EX_ANTE", - "local_filepath": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_order_bonus.json b/tests/private_markets_order_bonus.json deleted file mode 100644 index a191749c..00000000 --- a/tests/private_markets_order_bonus.json +++ /dev/null @@ -1,152 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-09-18T07:15:25.085+0000", - "title": "Private Equity", - "icon": "logos/LU3176111881/v2", - "avatar": { - "asset": "logos/LU3176111881/v2", - "badge": { - "asset": "logos/timeline_one_percent/v2", - "type": "icon" - } - }, - "badge": null, - "subtitle": "1 % Bonus", - "amount": { - "currency": "EUR", - "value": -1.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "eventType": "private_markets_order_created", - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 1,00\u00a0\u20ac erhalten", - "data": { - "icon": "logos/LU3176111881/v2", - "timestamp": "2025-09-18T07:15:25.085181Z", - "status": "executed" - }, - "action": { - "payload": "LU3176111881", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "1% Bonus", - "detail": { - "text": "Erstellt", - "functionalStyle": "CREATED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "1,00\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Summe", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "0,00\u00a0\u20ac", - "displayValue": { - "text": "0,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "12345678", - "postboxType": "EQUITIES_BUY_EX_ANTE", - "local_filepath": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_order_bonus_no_eventType.json b/tests/private_markets_order_bonus_no_eventType.json deleted file mode 100644 index 0a9b06ca..00000000 --- a/tests/private_markets_order_bonus_no_eventType.json +++ /dev/null @@ -1,151 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-09-18T07:15:25.085+0000", - "title": "Private Equity", - "icon": "logos/LU3176111881/v2", - "avatar": { - "asset": "logos/LU3176111881/v2", - "badge": { - "asset": "logos/timeline_one_percent/v2", - "type": "icon" - } - }, - "badge": null, - "subtitle": "1 % Bonus", - "amount": { - "currency": "EUR", - "value": -1.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "12345678" - }, - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "12345678", - "sections": [ - { - "title": "Du hast 1,00\u00a0\u20ac erhalten", - "data": { - "icon": "logos/LU3176111881/v2", - "timestamp": "2025-09-18T07:15:25.085181Z", - "status": "executed" - }, - "action": { - "payload": "LU3176111881", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "1% Bonus", - "detail": { - "text": "Erstellt", - "functionalStyle": "CREATED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "1,00\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Summe", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "0,00\u00a0\u20ac", - "displayValue": { - "text": "0,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "12345678", - "postboxType": "EQUITIES_BUY_EX_ANTE", - "local_filepath": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_order_no_eventType.json b/tests/private_markets_order_no_eventType.json deleted file mode 100644 index 54024a07..00000000 --- a/tests/private_markets_order_no_eventType.json +++ /dev/null @@ -1,178 +0,0 @@ -{ - "id": "12345678", - "timestamp": "2025-09-18T07:15:25.065+0000", - "title": "Private Equity", - "icon": "logos/LU3176111881/v2", - "avatar": { - "asset": "logos/LU3176111881/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -101.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "" - }, - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "", - "sections": [ - { - "title": "Du hast 101,00\u00a0\u20ac investiert", - "data": { - "icon": "logos/LU3176111881/v2", - "timestamp": "2025-09-18T07:15:25.065819Z", - "status": "executed" - }, - "action": { - "payload": "LU3176111881", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Erstellt", - "functionalStyle": "CREATED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "100,00\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Summe", - "detail": { - "text": "100,00\u00a0\u20ac", - "displayValue": { - "text": "100,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "100,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "101,00\u00a0\u20ac", - "displayValue": { - "text": "101,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "", - "postboxType": "EQUITIES_BUY_EX_ANTE", - "local_filepath": "" - } - ], - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "chat_flow_key": "NHC_0029_wealth_private_buying_selling_open_order", - "timelineEventId": "", - "orderType": "BUY", - "instrumentId": "LU3176111881", - "orderCreationDate": "2025-09-18", - "orderCutoffDate": "2025-10-14" - } - }, - "type": "customerSupportChat" - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "has_docs": true -} diff --git a/tests/private_markets_trade.json b/tests/private_markets_trade.json deleted file mode 100644 index 0dc095d7..00000000 --- a/tests/private_markets_trade.json +++ /dev/null @@ -1,180 +0,0 @@ -{ - "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", - "timestamp": "2025-09-18T07:14:56.634+0000", - "title": "Private Equity", - "icon": "logos/LU3170240538/v2", - "avatar": { - "asset": "logos/LU3170240538/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -101.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6" - }, - "eventType": "private_markets_trade_executed", - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", - "sections": [ - { - "title": "Du hast 101,00 € investiert", - "data": { - "icon": "logos/LU3170240538/v2", - "timestamp": "2025-09-18T07:14:56.623029Z", - "status": "executed" - }, - "action": { - "payload": "LU3170240538", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "1 × 100,00 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "1", - "displayValue": { - "text": "1" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "100,00 €", - "displayValue": { - "text": "100,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "100,00 €", - "displayValue": { - "text": "100,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "100,00 €", - "prefix": "1 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "101,00 €", - "displayValue": { - "text": "101,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "a7730267-753e-46a0-8213-54de9cf184e0", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "d0e63e45-6c50-4ce2-adce-83c32841a227", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_trade_bonus.json b/tests/private_markets_trade_bonus.json deleted file mode 100644 index 821e1cf3..00000000 --- a/tests/private_markets_trade_bonus.json +++ /dev/null @@ -1,183 +0,0 @@ -{ - "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", - "timestamp": "2025-09-18T07:14:56.652+0000", - "title": "Private Equity", - "icon": "logos/LU3170240538/v2", - "avatar": { - "asset": "logos/LU3170240538/v2", - "badge": { - "asset": "logos/timeline_one_percent/v2", - "type": "icon" - } - }, - "badge": null, - "subtitle": "1 % Bonus", - "amount": { - "currency": "EUR", - "value": -1.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "9fcaac4e-7675-4121-ab6d-2bf583798ba1" - }, - "eventType": "private_markets_trade_executed", - "cashAccountNumber": "0674716511", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", - "sections": [ - { - "title": "Du hast 1,00 € erhalten", - "data": { - "icon": "logos/LU3170240538/v2", - "timestamp": "2025-09-18T07:14:56.636046Z", - "status": "executed" - }, - "action": { - "payload": "LU3170240538", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "1% Bonus", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0,01 × 100,00 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "0,01", - "displayValue": { - "text": "0,01" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "100,00 €", - "displayValue": { - "text": "100,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "100,00 €", - "prefix": "0,01 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "f8c6da6f-7885-450c-a27b-eb972ac3468b", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "fd93fc58-7179-4092-9466-655c58386513", - "postboxType": "EQUITIES_BUY_EX_ANTE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_trade_bonus_no_eventType.json b/tests/private_markets_trade_bonus_no_eventType.json deleted file mode 100644 index 6e12c101..00000000 --- a/tests/private_markets_trade_bonus_no_eventType.json +++ /dev/null @@ -1,182 +0,0 @@ -{ - "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", - "timestamp": "2025-09-18T07:14:56.652+0000", - "title": "Private Equity", - "icon": "logos/LU3170240538/v2", - "avatar": { - "asset": "logos/LU3170240538/v2", - "badge": { - "asset": "logos/timeline_one_percent/v2", - "type": "icon" - } - }, - "badge": null, - "subtitle": "1 % Bonus", - "amount": { - "currency": "EUR", - "value": -1.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "9fcaac4e-7675-4121-ab6d-2bf583798ba1" - }, - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "9fcaac4e-7675-4121-ab6d-2bf583798ba1", - "sections": [ - { - "title": "Du hast 1,00 € erhalten", - "data": { - "icon": "logos/LU3170240538/v2", - "timestamp": "2025-09-18T07:14:56.636046Z", - "status": "executed" - }, - "action": { - "payload": "LU3170240538", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "1% Bonus", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0,01 × 100,00 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "0,01", - "displayValue": { - "text": "0,01" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "100,00 €", - "displayValue": { - "text": "100,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "100,00 €", - "prefix": "0,01 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "f8c6da6f-7885-450c-a27b-eb972ac3468b", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "fd93fc58-7179-4092-9466-655c58386513", - "postboxType": "EQUITIES_BUY_EX_ANTE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_trade_no_eventType.json b/tests/private_markets_trade_no_eventType.json deleted file mode 100644 index 7f7a1aaa..00000000 --- a/tests/private_markets_trade_no_eventType.json +++ /dev/null @@ -1,179 +0,0 @@ -{ - "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", - "timestamp": "2025-09-18T07:14:56.634+0000", - "title": "Private Equity", - "icon": "logos/LU3170240538/v2", - "avatar": { - "asset": "logos/LU3170240538/v2", - "badge": null - }, - "badge": null, - "subtitle": "Kauforder", - "amount": { - "currency": "EUR", - "value": -101.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6" - }, - "cashAccountNumber": "12345678", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "053da9f8-ab00-4839-b95f-d2ed83fc5dc6", - "sections": [ - { - "title": "Du hast 101,00 € investiert", - "data": { - "icon": "logos/LU3170240538/v2", - "timestamp": "2025-09-18T07:14:56.623029Z", - "status": "executed" - }, - "action": { - "payload": "LU3170240538", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Kauf", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "1 × 100,00 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "1", - "displayValue": { - "text": "1" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "100,00 €", - "displayValue": { - "text": "100,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "100,00 €", - "displayValue": { - "text": "100,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "100,00 €", - "prefix": "1 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "101,00 €", - "displayValue": { - "text": "101,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "a7730267-753e-46a0-8213-54de9cf184e0", - "postboxType": "EQUITIES_BUY_EX_ANTE" - }, - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "d0e63e45-6c50-4ce2-adce-83c32841a227", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_verkaufs_order_erstellt.json b/tests/private_markets_verkaufs_order_erstellt.json deleted file mode 100644 index 9c5e4b2e..00000000 --- a/tests/private_markets_verkaufs_order_erstellt.json +++ /dev/null @@ -1,183 +0,0 @@ -{ - "id": "86417e07-754d-45a6-a429-72c1437bc159", - "timestamp": "2026-03-26T06:48:51.517+0000", - "title": "Private Equity", - "icon": "logos/LU3176111881/v2", - "subtitle": "Verkaufsorder", - "action": { - "type": "timelineDetail", - "payload": "86417e07-754d-45a6-a429-72c1437bc159" - }, - "eventType": "PRIVATE_MARKET_FUND_ORDER_RECEIVED", - "hidden": false, - "deleted": false, - "source": "timelineActivity", - "details": { - "id": "86417e07-754d-45a6-a429-72c1437bc159", - "sections": [ - { - "title": "Du erhältst 104,10 €", - "data": { - "icon": { - "asset": "logos/LU3176111881/v2", - "badge": null - }, - "timestamp": "2026-03-26T06:48:51.517335Z", - "status": "executed" - }, - "action": { - "payload": "LU3176111881", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Order erstellt", - "description": "Ausführung bis 9 Juni geplant. Der Betrag ist abhängig vom Fondskurs zum Ausführungszeitpunkt. Eine Ausführung kann nicht garantiert werden.", - "type": "banner" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Verkaufen", - "detail": { - "text": "Erstellt", - "functionalStyle": "CREATED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "106,10 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Summe", - "detail": { - "text": "106,10 €", - "displayValue": { - "text": "106,10 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "displayMode": "bottomSheet", - "type": "infoPage" - }, - "displayValue": { - "text": "106,10 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Abzug für 1 %-Bonus", - "detail": { - "text": "1,00 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Abzug für 1 %-Bonus", - "type": "title" - }, - { - "text": "Du hast einen Bonus erhalten, der abgezogen werden muss, da du vor 18 Sept. 2027 verkaufst.", - "type": "text" - } - ] - }, - "displayMode": "bottomSheet", - "type": "infoPage" - }, - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "104,10 €", - "displayValue": { - "text": "104,10 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Löschen", - "data": { - "title": "Löschen", - "action": { - "payload": "b7a2dcd2-daf5-4c4b-9f05-7f8b36a54136", - "type": "deletePrivateMarketsOrder" - } - }, - "type": "actionButtons" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "b5ac9e63-b975-4a94-93dc-5652c0333522", - "postboxType": "EQUITIES_SELL_EX_ANTE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/private_markets_vorabpauschale.json b/tests/private_markets_vorabpauschale.json deleted file mode 100644 index 554fd13e..00000000 --- a/tests/private_markets_vorabpauschale.json +++ /dev/null @@ -1,137 +0,0 @@ - { - "id": "0319ae86-b98e-388d-9dd6-5a64b5373388", - "timestamp": "2026-03-09T07:56:12.429+0000", - "title": "Private Equity", - "icon": "logos/LU3176111881/v2", - "avatar": { - "asset": "logos/LU3176111881/v2", - "badge": null - }, - "badge": null, - "subtitle": "Vorabpauschale", - "amount": { - "currency": "EUR", - "value": -0.07, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "0319ae86-b98e-388d-9dd6-5a64b5373388" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "eventType": "SSP_CORPORATE_ACTION_CASH_NON_DIVIDEND", - "source": "timelineTransaction", - "details": { - "id": "0319ae86-b98e-388d-9dd6-5a64b5373388", - "sections": [ - { - "title": "Du hast 0,07 € bezahlt", - "data": { - "icon": { - "asset": "logos/LU3176111881/v2", - "badge": null - }, - "timestamp": "2026-03-09T07:56:12.429Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Vorabpauschale", - "displayValue": { - "text": "Vorabpauschale" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Private Equity", - "displayValue": { - "text": "Private Equity" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-0,07 €", - "displayValue": { - "text": "-0,07 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-0,07 €", - "displayValue": { - "text": "-0,07 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Vorabpauschale", - "detail": "09.03.2026", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "a1f523f2-c944-4617-bfe1-316a77226331", - "postboxType": "CA_VOPA_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/reverse_split.json b/tests/reverse_split.json deleted file mode 100644 index ff34126a..00000000 --- a/tests/reverse_split.json +++ /dev/null @@ -1,116 +0,0 @@ -{ - "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", - "timestamp": "2025-02-11T08:13:48.877+0000", - "title": "Globalstar", - "icon": "logos/US3789734080/v2", - "subtitle": "Reverse Split", - "action": { - "type": "timelineDetail", - "payload": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": { - "asset": "logos/US3789734080/v2", - "badge": null - }, - "timestamp": "2025-02-11T08:13:48.877Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Reverse Split", - "displayValue": { - "text": "Reverse Split" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Globalstar", - "displayValue": { - "text": "Globalstar" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "110.403067", - "displayValue": { - "text": "110.403067" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "GLOBALSTAR INC. O.N.", - "displayValue": { - "text": "GLOBALSTAR INC. O.N." - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "7.360204", - "displayValue": { - "text": "7.360204" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "11.02.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4c005c61-08ae-4205-9b77-02b886c0a5e5", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/reverse_split_no_eventType.json b/tests/reverse_split_no_eventType.json deleted file mode 100644 index e0f400ee..00000000 --- a/tests/reverse_split_no_eventType.json +++ /dev/null @@ -1,115 +0,0 @@ -{ - "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", - "timestamp": "2025-02-11T08:13:48.877+0000", - "title": "Globalstar", - "icon": "logos/US3789734080/v2", - "subtitle": "Reverse Split", - "action": { - "type": "timelineDetail", - "payload": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5" - }, - "source": "timelineActivity", - "details": { - "id": "f07b77c6-eed4-334b-8236-c9fdf49cf5d5", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": { - "asset": "logos/US3789734080/v2", - "badge": null - }, - "timestamp": "2025-02-11T08:13:48.877Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Reverse Split", - "displayValue": { - "text": "Reverse Split" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Globalstar", - "displayValue": { - "text": "Globalstar" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "110.403067", - "displayValue": { - "text": "110.403067" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "GLOBALSTAR INC. O.N.", - "displayValue": { - "text": "GLOBALSTAR INC. O.N." - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "7.360204", - "displayValue": { - "text": "7.360204" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "11.02.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4c005c61-08ae-4205-9b77-02b886c0a5e5", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/saveback.json b/tests/saveback.json deleted file mode 100644 index 16a9966f..00000000 --- a/tests/saveback.json +++ /dev/null @@ -1,117 +0,0 @@ -{ - "id": "836369c0-f623-4ad0-a259-8bd3807a6be6", - "timestamp": "2025-04-02T13:54:23.344+0000", - "title": "S&P 500 Information Tech USD (Acc)", - "icon": "logos/IE00B3WJKG14/v2", - "badge": null, - "subtitle": "Saveback", - "amount": { - "currency": "EUR", - "value": -15.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "836369c0-f623-4ad0-a259-8bd3807a6be6" - }, - "eventType": "benefits_saveback_execution", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "836369c0-f623-4ad0-a259-8bd3807a6be6", - "sections": [ - { - "title": "Du hast 15,00\u00a0\u20ac erhalten", - "data": { - "icon": "logos/IE00B3WJKG14/v2", - "timestamp": "2025-04-02T13:54:23.344+0000", - "status": "executed" - }, - "action": { - "payload": "IE00B3WJKG14", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Saveback", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "S&P 500 Information Tech USD (Acc)", - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "", - "displayValue": { - "text": "27,45\u00a0\u20ac", - "prefix": "0.546348 x " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "Kostenlos", - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "15,00\u00a0\u20ac", - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Wertpapierabrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "8886fc15-a3e4-40c1-9604-e8e27f8ed992", - "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "001c5873-ddf6-42be-9eaa-19df21ef82f8", - "postboxType": "COSTS_INFO_SAVINGS_PLAN_V2" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/saveback_no_eventType.json b/tests/saveback_no_eventType.json deleted file mode 100644 index 11ff0fa8..00000000 --- a/tests/saveback_no_eventType.json +++ /dev/null @@ -1,147 +0,0 @@ -{ - "id": "b5999007-483d-4013-b582-347471a42a6a", - "timestamp": "2025-11-03T15:30:22.202+0000", - "title": "Lockheed Martin", - "icon": "logos/US5398301094/v2", - "avatar": { - "asset": "logos/US5398301094/v2", - "badge": null - }, - "badge": null, - "subtitle": "Saveback", - "amount": { - "currency": "EUR", - "value": -15.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "b5999007-483d-4013-b582-347471a42a6a" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "b5999007-483d-4013-b582-347471a42a6a", - "sections": [ - { - "title": "Du hast 15,00\u00a0\u20ac erhalten", - "data": { - "icon": "logos/US5398301094/v2", - "timestamp": "2025-11-03T15:30:22.202665Z", - "status": "executed" - }, - "action": { - "payload": "US5398301094", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Saveback", - "detail": { - "text": "Abgeschlossen", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Lockheed Martin", - "displayValue": { - "text": "Lockheed Martin" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0.035252 x 425,50\u00a0\u20ac", - "displayValue": { - "text": "425,50\u00a0\u20ac", - "prefix": "0.035252 x " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "Kostenlos", - "displayValue": { - "text": "Kostenlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "15,00\u00a0\u20ac", - "displayValue": { - "text": "15,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "highlighted" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Wertpapierabrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "0117fe00-93e5-47c2-9f7f-85f72d51da48", - "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" - }, - { - "title": "Aktivierung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "6387ff2c-656c-4f9a-a238-4a151dff6212", - "postboxType": "BENEFIT_ACTIVATED" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "29cca886-9baa-4153-947f-8dba06e618c9", - "postboxType": "COSTS_INFO_SAVINGS_PLAN" - }, - { - "title": "Auftragsbest\u00e4tigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "3da1d209-7d52-4017-8397-1b9817f68432", - "postboxType": "SAVINGS_PLAN_CREATED" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/savingsplan.json b/tests/savingsplan.json deleted file mode 100644 index ceb41e2e..00000000 --- a/tests/savingsplan.json +++ /dev/null @@ -1,205 +0,0 @@ - { - "id": "8bd087f0-0091-4791-bff5-d47d8196aee4", - "timestamp": "2025-10-23T08:26:13.657+0000", - "title": "DroneShield", - "icon": "logos/AU000000DRO2/v2", - "avatar": { - "asset": "logos/AU000000DRO2/v2", - "badge": null - }, - "badge": null, - "subtitle": "Sparplan ausgeführt", - "amount": { - "currency": "EUR", - "value": -19.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "8bd087f0-0091-4791-bff5-d47d8196aee4" - }, - "eventType": "trading_savingsplan_executed", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "8bd087f0-0091-4791-bff5-d47d8196aee4", - "sections": [ - { - "title": "Du hast 19,00 € gespart", - "data": { - "icon": "logos/AU000000DRO2/v2", - "timestamp": "2025-10-23T08:26:13.65787Z", - "status": "executed" - }, - "action": { - "payload": "AU000000DRO2", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Sparplan", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "DroneShield", - "displayValue": { - "text": "DroneShield" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "6,921675 × 2,75 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "6,921675", - "displayValue": { - "text": "6,921675" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "2,75 €", - "displayValue": { - "text": "2,75 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "19,00 €", - "displayValue": { - "text": "19,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "2,75 €", - "prefix": "6,921675 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "Kostenlos", - "displayValue": { - "text": "Kostenlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "19,00 €", - "displayValue": { - "text": "19,00 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Sparplan", - "data": [ - { - "title": "", - "detail": { - "title": "DroneShield", - "timestamp": "2025-10-23T08:26:13.65787Z", - "amount": "19,00 €", - "icon": "logos/AU000000DRO2/v2", - "status": "executed", - "action": { - "payload": { - "savingsPlanId": "31e81415-c9ed-48b2-996b-5f3a2a6c32b1" - }, - "type": "openSavingsPlanOverview" - }, - "subtitle": "Wöchentlich", - "type": "embeddedTimelineItem" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnungsausführung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "f58e3844-a6f9-4f81-9bd0-8b49d8e5984e", - "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/savingsplan_no_eventType.json b/tests/savingsplan_no_eventType.json deleted file mode 100644 index 6da7c956..00000000 --- a/tests/savingsplan_no_eventType.json +++ /dev/null @@ -1,231 +0,0 @@ -{ - "id": "78862117-79a9-4330-b594-ec62c3685a16", - "timestamp": "2025-11-03T15:58:11.121+0000", - "title": "TSMC (ADR)", - "icon": "logos/US8740391003/v2", - "avatar": { - "asset": "logos/US8740391003/v2", - "badge": null - }, - "badge": null, - "subtitle": "Sparplan ausgef\u00fchrt", - "amount": { - "currency": "EUR", - "value": -10.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "78862117-79a9-4330-b594-ec62c3685a16" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "78862117-79a9-4330-b594-ec62c3685a16", - "sections": [ - { - "title": "Du hast 10,00\u00a0\u20ac gespart", - "data": { - "icon": "logos/US8740391003/v2", - "timestamp": "2025-11-03T15:58:11.121982Z", - "status": "executed" - }, - "action": { - "payload": "US8740391003", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Sparplan", - "detail": { - "text": "Ausgef\u00fchrt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Zahlung", - "detail": { - "text": "Cash", - "icon": "logos/bank_traderepublic/v2", - "type": "iconWithText" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "TSMC (ADR)", - "displayValue": { - "text": "TSMC (ADR)" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0,037523 \u00d7 266,50\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "0,037523", - "displayValue": { - "text": "0,037523" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "266,50\u00a0\u20ac", - "displayValue": { - "text": "266,50\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "10,00\u00a0\u20ac", - "displayValue": { - "text": "10,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "266,50\u00a0\u20ac", - "prefix": "0,037523 \u00d7 " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "Kostenlos", - "displayValue": { - "text": "Kostenlos" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "10,00\u00a0\u20ac", - "displayValue": { - "text": "10,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Sparplan", - "data": [ - { - "title": "", - "detail": { - "title": "TSMC (ADR)", - "timestamp": "2025-11-03T15:58:11.121982Z", - "amount": "10,00\u00a0\u20ac", - "icon": "logos/US8740391003/v2", - "status": "executed", - "action": { - "payload": { - "savingsPlanId": "407449dc-fce1-48c3-93a6-e86919e5b385" - }, - "type": "openSavingsPlanOverview" - }, - "subtitle": "W\u00f6chentlich", - "type": "embeddedTimelineItem" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnungsausf\u00fchrung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "548c51bd-f5c3-45f4-b794-b68bb90dc10c", - "postboxType": "SECURITIES_SETTLEMENT_SAVINGS_PLAN" - } - ], - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "chat_flow_key": "NHC_0029_wealth_Failed_savings_plan_execution", - "timelineEventId": "78862117-79a9-4330-b594-ec62c3685a16", - "savingsPlanId": "407449dc-fce1-48c3-93a6-e86919e5b385", - "primId": "N1546849464" - } - }, - "type": "customerSupportChat" - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/sell_stop.json b/tests/sell_stop.json deleted file mode 100644 index 855fe6c8..00000000 --- a/tests/sell_stop.json +++ /dev/null @@ -1,241 +0,0 @@ - { - "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", - "timestamp": "2025-03-14T07:03:14.000+0000", - "title": "D-Wave Quantum", - "icon": "logos/US26740W1099/v2", - "avatar": { - "asset": "logos/US26740W1099/v2", - "badge": null - }, - "badge": null, - "subtitle": "Stop-Sell-Order", - "amount": { - "currency": "EUR", - "value": 94.76, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "5b0f491f-7bad-40b1-8cd1-56d83729afd4" - }, - "eventType": "trading_trade_executed", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", - "sections": [ - { - "title": "Du hast 94,76 € erhalten", - "data": { - "icon": "logos/US26740W1099/v2", - "timestamp": "2025-03-14T07:03:09.282Z", - "status": "executed" - }, - "action": { - "payload": "US26740W1099", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Stop Order", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "D-Wave Quantum", - "displayValue": { - "text": "D-Wave Quantum" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "17 × 5,82 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "17", - "displayValue": { - "text": "17" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "5,82 €", - "displayValue": { - "text": "5,82 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "98,94 €", - "displayValue": { - "text": "98,94 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "5,82 €", - "prefix": "17 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "3,18 €", - "displayValue": { - "text": "3,18 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "94,76 €", - "displayValue": { - "text": "94,76 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "13,28 %", - "trend": "positive", - "displayValue": { - "text": "13,28 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "11,48 €", - "trend": "positive", - "displayValue": { - "text": "11,48 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "21a756dc-3eae-475a-a874-203b1a38b1a5", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "39232eec-df7d-401d-a4cd-7c398e048ba2", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Auftragsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "17c2c342-067f-4dd6-8e11-c1c53ccb9a24", - "postboxType": "ORDER_CONFIRMATION" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/sell_stop_no_eventType.json b/tests/sell_stop_no_eventType.json deleted file mode 100644 index 3fbeebc0..00000000 --- a/tests/sell_stop_no_eventType.json +++ /dev/null @@ -1,240 +0,0 @@ - { - "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", - "timestamp": "2025-03-14T07:03:14.000+0000", - "title": "D-Wave Quantum", - "icon": "logos/US26740W1099/v2", - "avatar": { - "asset": "logos/US26740W1099/v2", - "badge": null - }, - "badge": null, - "subtitle": "Stop-Sell-Order", - "amount": { - "currency": "EUR", - "value": 94.76, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "5b0f491f-7bad-40b1-8cd1-56d83729afd4" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "5b0f491f-7bad-40b1-8cd1-56d83729afd4", - "sections": [ - { - "title": "Du hast 94,76 € erhalten", - "data": { - "icon": "logos/US26740W1099/v2", - "timestamp": "2025-03-14T07:03:09.282Z", - "status": "executed" - }, - "action": { - "payload": "US26740W1099", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Stop Order", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "D-Wave Quantum", - "displayValue": { - "text": "D-Wave Quantum" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "17 × 5,82 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "17", - "displayValue": { - "text": "17" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "5,82 €", - "displayValue": { - "text": "5,82 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "98,94 €", - "displayValue": { - "text": "98,94 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "5,82 €", - "prefix": "17 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "3,18 €", - "displayValue": { - "text": "3,18 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "94,76 €", - "displayValue": { - "text": "94,76 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "13,28 %", - "trend": "positive", - "displayValue": { - "text": "13,28 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "11,48 €", - "trend": "positive", - "displayValue": { - "text": "11,48 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "21a756dc-3eae-475a-a874-203b1a38b1a5", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "39232eec-df7d-401d-a4cd-7c398e048ba2", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Auftragsbestätigung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "17c2c342-067f-4dd6-8e11-c1c53ccb9a24", - "postboxType": "ORDER_CONFIRMATION" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/spinoff.json b/tests/spinoff.json deleted file mode 100644 index 60fe8028..00000000 --- a/tests/spinoff.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", - "timestamp": "2025-10-20T11:25:29.214+0000", - "title": "ThyssenKrupp", - "icon": "logos/DE0007500001/v2", - "subtitle": "Spin-off", - "action": { - "type": "timelineDetail", - "payload": "30759295-1d4b-3e2a-b248-8bf6779cf30c" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/DE0007500001/v2", - "timestamp": "2025-10-20T11:25:29.214Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Spin-off", - "displayValue": { - "text": "Spin-off" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "TKMS", - "displayValue": { - "text": "TKMS" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "0.309986", - "displayValue": { - "text": "0.309986" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "20.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "9151d59c-29d8-4537-bb82-9d32824fbb04", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/spinoff_no_eventType.json b/tests/spinoff_no_eventType.json deleted file mode 100644 index c2574aaf..00000000 --- a/tests/spinoff_no_eventType.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", - "timestamp": "2025-10-20T11:25:29.214+0000", - "title": "ThyssenKrupp", - "icon": "logos/DE0007500001/v2", - "subtitle": "Spin-off", - "action": { - "type": "timelineDetail", - "payload": "30759295-1d4b-3e2a-b248-8bf6779cf30c" - }, - "source": "timelineActivity", - "details": { - "id": "30759295-1d4b-3e2a-b248-8bf6779cf30c", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/DE0007500001/v2", - "timestamp": "2025-10-20T11:25:29.214Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Spin-off", - "displayValue": { - "text": "Spin-off" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "TKMS", - "displayValue": { - "text": "TKMS" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "0.309986", - "displayValue": { - "text": "0.309986" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "20.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "9151d59c-29d8-4537-bb82-9d32824fbb04", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/steuerkorrektur.json b/tests/steuerkorrektur.json deleted file mode 100644 index 6963813e..00000000 --- a/tests/steuerkorrektur.json +++ /dev/null @@ -1,101 +0,0 @@ - { - "id": "8a39d3f4-90bc-39ad-8a11-694308472b62", - "timestamp": "2025-10-28T00:00:16.000+0000", - "title": "Steuerkorrektur", - "icon": "logos/timeline_person/v2", - "avatar": { - "asset": "logos/timeline_person/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 2.87, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "8a39d3f4-90bc-39ad-8a11-694308472b62" - }, - "eventType": "ssp_tax_correction_invoice", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "8a39d3f4-90bc-39ad-8a11-694308472b62", - "sections": [ - { - "title": "Du hast 2,87 € erhalten", - "data": { - "icon": "logos/timeline_person/v2", - "timestamp": "2025-10-28T00:00:16Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Steuerkorrektur", - "displayValue": { - "text": "Steuerkorrektur" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Gesamt", - "detail": { - "text": "2,87 €", - "displayValue": { - "text": "2,87 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Steuerabrechnung", - "detail": "28.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "8bdb11ab-9406-4d11-845f-81e2371d87a0", - "postboxType": "TAX_OPTIMIZATION_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/steuerkorrektur_no_eventType.json b/tests/steuerkorrektur_no_eventType.json deleted file mode 100644 index 1af6036b..00000000 --- a/tests/steuerkorrektur_no_eventType.json +++ /dev/null @@ -1,125 +0,0 @@ -{ - "id": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3", - "timestamp": "2025-11-04T23:31:58.000+0000", - "title": "Steuerkorrektur", - "icon": "logos/timeline_person/v2", - "avatar": { - "asset": "logos/timeline_person/v2", - "badge": null - }, - "badge": null, - "subtitle": null, - "amount": { - "currency": "EUR", - "value": 0.76, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3", - "sections": [ - { - "title": "Du hast 0,76\u00a0\u20ac erhalten", - "data": { - "icon": "logos/timeline_person/v2", - "timestamp": "2025-11-04T23:31:58Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgef\u00fchrt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Steuerkorrektur", - "displayValue": { - "text": "Steuerkorrektur" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Gesch\u00e4ft", - "data": [ - { - "title": "Gesamt", - "detail": { - "text": "0,76\u00a0\u20ac", - "displayValue": { - "text": "0,76\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Steuerabrechnung", - "detail": "04.11.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "b1cbfe63-4737-4112-a8c7-033f69d1ed49", - "postboxType": "TAX_OPTIMIZATION_INVOICE" - } - ], - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "common_empty_string", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "timelineEventId": "0a3c14cf-0688-374e-99fc-3b690e1a7ea3", - "chat_flow_key": "NHC_0029_tax_optimization_picker" - } - }, - "type": "customerSupportChat" - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "highlighted" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/tausch_no_eventType.json b/tests/tausch_no_eventType.json deleted file mode 100644 index 801e1017..00000000 --- a/tests/tausch_no_eventType.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "id": "bbf2affb-30ab-45bd-a7d6-d3047360e905", - "timestamp": "2025-11-04T08:59:35.225+0000", - "title": "L'Oreal", - "icon": "logos/FR0000120321/v2", - "subtitle": "Tausch", - "action": { - "type": "timelineDetail", - "payload": "bbf2affb-30ab-45bd-a7d6-d3047360e905" - }, - "source": "timelineActivity", - "details": { - "id": "bbf2affb-30ab-45bd-a7d6-d3047360e905", - "sections": [ - { - "title": "Du hast eine Kapitalma\u00dfnahme erhalten", - "data": { - "icon": "logos/FR0000120321/v2", - "timestamp": "2025-11-04T08:59:35.225Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Information", - "text": "Das beigef\u00fcgte Dokument enth\u00e4lt wichtige Informationen zu deiner L'Oreal-Investition. Bitte \u00fcberpr\u00fcfe das Dokument.", - "type": "text" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kapitalma\u00dfnahmen", - "detail": "04.11.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "e68a0462-3569-4eea-a33c-f5b10154986a", - "postboxType": "CA_GENERIC_OPTIONS_NOTIFICATION" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/teilrueckzahlung.json b/tests/teilrueckzahlung.json deleted file mode 100644 index de4912b7..00000000 --- a/tests/teilrueckzahlung.json +++ /dev/null @@ -1,113 +0,0 @@ -{ - "id": "c351c859-99e9-3d10-9049-f3b4daf30799", - "timestamp": "2025-10-23T14:46:49.868+0000", - "title": "ORSTED A/S EM.09/25 DK 10", - "icon": "logos/DK0064307755/v2", - "subtitle": "Teilrückzahlung ohne Reduzierung des Poolfaktors", - "action": { - "type": "timelineDetail", - "payload": "c351c859-99e9-3d10-9049-f3b4daf30799" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "c351c859-99e9-3d10-9049-f3b4daf30799", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": "logos/DK0064307755/v2", - "timestamp": "2025-10-23T14:46:49.868Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors", - "displayValue": { - "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S EM.09/25 DK 10", - "displayValue": { - "text": "ORSTED A/S EM.09/25 DK 10" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "17.000000", - "displayValue": { - "text": "17.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Orsted", - "displayValue": { - "text": "Orsted" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "17.000000", - "displayValue": { - "text": "17.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "23.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "6ea247d9-0b29-4637-b669-932f22ee745b", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/teilrueckzahlung_no_eventType.json b/tests/teilrueckzahlung_no_eventType.json deleted file mode 100644 index c5c30f28..00000000 --- a/tests/teilrueckzahlung_no_eventType.json +++ /dev/null @@ -1,112 +0,0 @@ -{ - "id": "c351c859-99e9-3d10-9049-f3b4daf30799", - "timestamp": "2025-10-23T14:46:49.868+0000", - "title": "ORSTED A/S EM.09/25 DK 10", - "icon": "logos/DK0064307755/v2", - "subtitle": "Teilrückzahlung ohne Reduzierung des Poolfaktors", - "action": { - "type": "timelineDetail", - "payload": "c351c859-99e9-3d10-9049-f3b4daf30799" - }, - "source": "timelineActivity", - "details": { - "id": "c351c859-99e9-3d10-9049-f3b4daf30799", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": "logos/DK0064307755/v2", - "timestamp": "2025-10-23T14:46:49.868Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors", - "displayValue": { - "text": "Teilrückzahlung ohne Reduzierung des Poolfaktors" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S EM.09/25 DK 10", - "displayValue": { - "text": "ORSTED A/S EM.09/25 DK 10" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "17.000000", - "displayValue": { - "text": "17.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Orsted", - "displayValue": { - "text": "Orsted" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "17.000000", - "displayValue": { - "text": "17.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "23.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "6ea247d9-0b29-4637-b669-932f22ee745b", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/test_accounts.py b/tests/test_accounts.py new file mode 100644 index 00000000..5c843f4b --- /dev/null +++ b/tests/test_accounts.py @@ -0,0 +1,511 @@ +"""Pin how pytr reaches an account of the login other than its own, e.g. a company account.""" + +import asyncio +import json as jsonlib +from typing import Any + +import pytest +import requests + +import pytr.account as account_module +from pytr.api import TradeRepublicApi +from pytr.main import get_main_parser + +HOST = "https://api.traderepublic.com" +SESSION_V1 = f"{HOST}/api/v1/auth/web/session" +SESSION_V2 = f"{HOST}/api/v2/auth/web/session" +RELATIONSHIPS = f"{HOST}/api/v1/customer/relationships/detailed" +ACCOUNT = f"{HOST}/api/v2/auth/account" + +SELF = { + "customerId": "id-self", + "firstName": "Erika", + "lastName": "Mustermann", + "relationshipType": "SELF", + "accountState": "ACTIVE", + "accountType": "ADULT", +} +COMPANY = { + "customerId": "id-company", + "relationshipType": "LEGAL_ENTITY_ACTOR", + "accountState": "ACTIVE", + "accountType": "LEGAL_ENTITY", + "accountName": "Mustermann Holding GmbH", +} +SECOND_COMPANY = {**COMPANY, "customerId": "id-second", "accountName": "Mustermann Immobilien UG"} +BOTH = {"relationships": [SELF, COMPANY]} + + +class _Response: + def __init__(self, payload: Any = None, status_code: int = 200): + self.status_code = status_code + self._payload = {} if payload is None else payload + + def __bool__(self) -> bool: + # Like requests.Response: falsy for 4xx and 5xx. + return self.status_code < 400 + + def raise_for_status(self) -> None: + if self.status_code >= 400: + raise requests.HTTPError(f"{self.status_code} Client Error", response=self) # type: ignore[arg-type] + + def json(self) -> Any: + return self._payload + + +class _Session: + """Records requests instead of sending them. Replies come from a queue; an unexpected request fails.""" + + def __init__(self, replies: list[Any]): + self.calls: list[dict[str, Any]] = [] + self.replies = list(replies) + self.headers = dict(TradeRepublicApi._default_headers) + + def _record(self, method: str, url: str, json: Any = None, headers: Any = None) -> _Response: + self.calls.append({"method": method, "url": url, "json": json, "headers": headers or {}}) + assert self.replies, f"unexpected request: {method} {url}" + reply = self.replies.pop(0) + status, payload = reply if isinstance(reply, tuple) else (200, reply) + return _Response(payload, status) + + def post(self, url, json=None, headers=None): + return self._record("POST", url, json, headers) + + def get(self, url, headers=None): + return self._record("GET", url, None, headers) + + def request(self, method, url, data=None): + return self._record(method, url, data, None) + + +class _Websocket: + """Answers each subscription with the messages listed for its topic: (code, topic answered, payload).""" + + close_code = None + + def __init__(self, answers: dict[str, list[tuple[str, str, Any]]]): + self.sent: list[str] = [] + self._answers = answers + self._ids: dict[str, str] = {} + self._inbox: asyncio.Queue[str] = asyncio.Queue() + + async def send(self, message: str) -> None: + self.sent.append(message) + command, subscription_id, *payload = message.split(" ", 2) + if command != "sub": + return + topic = jsonlib.loads(payload[0])["type"] + self._ids[topic] = subscription_id + for code, answered_topic, body in self._answers.get(topic, []): + await self._inbox.put(f"{self._ids[answered_topic]} {code} {jsonlib.dumps(body)}") + + async def recv(self) -> str: + return await self._inbox.get() + + def subscriptions(self) -> list[dict[str, Any]]: + return [jsonlib.loads(m.split(" ", 2)[2]) for m in self.sent if m.startswith("sub ")] + + +def _api(replies, session_is_fresh=True): + tr = TradeRepublicApi(phone_no="+490000000000", pin="0000", waf_token=None, save_cookies=False) + tr._websession = _Session(replies) + # These are class attributes; keep what one test subscribes to out of the next. + tr.subscriptions = {} + tr._previous_responses = {} + tr._subscription_id_counter = 1 + if session_is_fresh: + tr._session_expires_at = float("inf") + return tr + + +def _switched(extra_replies=()): + """An API whose session acts for the company account.""" + tr = _api([BOTH, {}, *extra_replies]) + tr.switch_account("LEGAL_ENTITY") + tr._websession.calls.clear() + return tr + + +def _with_websocket(tr, answers): + ws = _Websocket(answers) + + async def get_ws(): + return ws + + tr._get_ws = get_ws + return ws + + +def _calls(tr): + return [(c["method"], c["url"]) for c in tr._websession.calls] + + +# --- listing the accounts ------------------------------------------------------------ + + +def test_relationships_lists_the_accounts_of_the_login(): + tr = _api([BOTH]) + + assert tr.relationships() == [SELF, COMPANY] + assert _calls(tr) == [("GET", RELATIONSHIPS)] + + +@pytest.mark.parametrize("payload", [{}, {"relationships": None}]) +def test_relationships_of_a_login_without_any_is_empty(payload): + assert _api([payload]).relationships() == [] + + +# --- switching ----------------------------------------------------------------------- + + +def test_switch_account_asks_for_a_session_acting_for_the_other_customer(): + tr = _api([BOTH, {}]) + tr._sec_acc_no = "own-depot" + + chosen = tr.switch_account("LEGAL_ENTITY") + + assert chosen == COMPANY + assert _calls(tr) == [("GET", RELATIONSHIPS), ("POST", SESSION_V2)] + assert tr._websession.calls[1]["json"] == {"subjectId": "id-company"} + assert tr._subject_id == "id-company" + # The securities account of the own account must not leak into the other one. + assert tr._sec_acc_no is None + + +def test_switch_account_sends_the_headers_of_the_v2_login_calls(): + tr = _api([BOTH, {}]) + + tr.switch_account("LEGAL_ENTITY") + + for header in ("X-TR-Device-Info", "X-TR-App-Version", "X-Tr-Platform"): + assert tr._websession.calls[1]["headers"].get(header) + + +def test_switch_account_saves_the_new_cookies(): + tr = _api([BOTH, {}]) + saved = [] + tr.save_websession = lambda: saved.append(tr._subject_id) + + tr.switch_account("LEGAL_ENTITY") + + assert saved == ["id-company"] + + +@pytest.mark.parametrize( + "account", + ["id-company", "legal_entity", "LEGAL_ENTITY_ACTOR", "mustermann holding gmbh", " Mustermann Holding GmbH "], +) +def test_switch_account_finds_the_account_by_id_type_or_name(account): + tr = _api([BOTH, {}]) + + assert tr.switch_account(account) == COMPANY + + +@pytest.mark.parametrize("account", ["Erika", "erika mustermann", "ADULT", "self"]) +def test_switch_account_finds_a_person_by_first_or_full_name(account): + tr = _api([BOTH, {}]) + + assert tr.switch_account(account) == SELF + + +@pytest.mark.parametrize("account", ["Mustermann", "Holding", "LEGAL", "id-", ""]) +def test_switch_account_does_not_match_on_parts_of_a_name(account): + tr = _api([BOTH]) + + with pytest.raises(ValueError, match="was not found"): + tr.switch_account(account) + + +def test_switch_account_without_a_name_returns_to_the_own_account(): + tr = _switched([BOTH, {}]) + + assert tr.switch_account() == SELF + assert tr._websession.calls[1]["json"] == {"subjectId": "id-self"} + assert tr._subject_id is None + + +def test_switch_account_reports_a_login_without_an_own_account(): + tr = _api([{"relationships": [COMPANY]}]) + + with pytest.raises(ValueError, match="Your own account was not found"): + tr.switch_account() + + +def test_switch_account_rejects_an_unknown_account_and_names_the_known_ones(): + tr = _api([BOTH]) + + with pytest.raises(ValueError, match="'nope' was not found.*LEGAL_ENTITY \\(Mustermann Holding GmbH\\)"): + tr.switch_account("nope") + + assert _calls(tr) == [("GET", RELATIONSHIPS)] + + +def test_switch_account_rejects_an_ambiguous_account_until_given_its_id(): + """Two companies share their type, so the type alone does not say which one is meant.""" + accounts = {"relationships": [SELF, COMPANY, SECOND_COMPANY]} + tr = _api([accounts, accounts, {}]) + + with pytest.raises(ValueError, match="more than one account, use its customer id"): + tr.switch_account("LEGAL_ENTITY") + + assert tr.switch_account("id-second") == SECOND_COMPANY + + +def test_switch_account_rejects_an_account_without_a_customer_id(): + tr = _api([{"relationships": [SELF, {"accountType": "LEGAL_ENTITY", "accountName": "Nameless"}]}]) + + with pytest.raises(ValueError, match="was not found"): + tr.switch_account("LEGAL_ENTITY") + + +def test_switch_account_copes_with_fields_that_are_not_text(): + odd = {"customerId": 42, "firstName": 1, "lastName": None, "relationshipType": "LEGAL_ENTITY_ACTOR"} + tr = _api([{"relationships": [SELF, odd]}, {}]) + + assert tr.switch_account("42") == odd + + +def test_a_refused_switch_leaves_the_session_as_it_was(): + tr = _api([BOTH, (403, {})]) + tr._sec_acc_no = "own-depot" + tr._session_expires_at = expires_at = 10**10 + tr.save_websession = lambda: pytest.fail("must not save the cookies of a refused switch") + + with pytest.raises(requests.HTTPError): + tr.switch_account("LEGAL_ENTITY") + + assert (tr._subject_id, tr._sec_acc_no, tr._session_expires_at) == (None, "own-depot", expires_at) + + +def test_switch_account_refuses_while_the_websocket_is_connected(): + """An open websocket keeps answering for the account it was authenticated with.""" + tr = _api([]) + tr._ws = _Websocket({}) + + with pytest.raises(ValueError, match="websocket"): + tr.switch_account("LEGAL_ENTITY") + + assert tr._websession.calls == [] + + +# --- keeping the session on the chosen account --------------------------------------- + + +def test_the_switch_counts_as_a_session_refresh(): + tr = _api([BOTH, {}, {}]) + tr._session_expires_at = 10**10 # far enough ahead that only the switch can have moved it + + tr.switch_account("LEGAL_ENTITY") + tr._web_request("/api/v1/whatever") + + assert tr._session_expires_at < 10**10 + assert _calls(tr) == [("GET", RELATIONSHIPS), ("POST", SESSION_V2), ("GET", f"{HOST}/api/v1/whatever")] + + +def test_session_refresh_stays_on_the_chosen_account(): + """A refresh without the subject would silently return the session to the own account.""" + tr = _switched([{}, {}]) + tr._session_expires_at = 0 + + tr._web_request("/api/v1/whatever") + + assert _calls(tr) == [("POST", SESSION_V2), ("GET", f"{HOST}/api/v1/whatever")] + assert tr._websession.calls[0]["json"] == {"subjectId": "id-company"} + + +def test_a_new_process_starts_on_the_own_account(): + """Its first request refreshes without a subject, whatever account the saved cookies act for.""" + tr = _api([{}, {}], session_is_fresh=False) + + tr.settings() + + assert _calls(tr) == [("GET", SESSION_V1), ("GET", ACCOUNT)] + + +# --- portfolio ----------------------------------------------------------------------- + +PAIRS = { + "authAccountId": "id-company", + "accounts": [ + {"securitiesAccountNumber": "depot-other", "cashAccountNumber": "cash-other", "productType": "OTHER"}, + {"securitiesAccountNumber": "depot-company", "cashAccountNumber": "cash-company", "productType": "DEFAULT"}, + ], +} + + +def test_compact_portfolio_reads_the_securities_account_from_account_pairs_after_a_switch(): + tr = _switched() + ws = _with_websocket(tr, {"accountPairs": [("A", "accountPairs", PAIRS)]}) + + asyncio.run(tr.compact_portfolio()) + + assert ws.subscriptions() == [ + {"type": "accountPairs"}, + {"type": "compactPortfolioByType", "secAccNo": "depot-company"}, + ] + # The account settings are refused for this account, so they are not asked for. + assert _calls(tr) == [] + assert "unsub 1" in ws.sent + + +def test_compact_portfolio_takes_the_first_pair_when_none_is_the_default_product(): + tr = _switched() + pairs = {"accounts": [{"cashAccountNumber": "c"}, {"securitiesAccountNumber": "depot-a", "productType": "X"}]} + ws = _with_websocket(tr, {"accountPairs": [("A", "accountPairs", pairs)]}) + + asyncio.run(tr.compact_portfolio()) + + assert ws.subscriptions()[-1]["secAccNo"] == "depot-a" + + +def test_compact_portfolio_keeps_the_answers_to_other_subscriptions(): + """Looking up the securities account must not swallow what the caller subscribed to before.""" + tr = _switched() + _with_websocket( + tr, + { + "cash": [], + "accountPairs": [("A", "cash", [{"amount": 1}]), ("A", "accountPairs", PAIRS)], + "compactPortfolioByType": [("A", "compactPortfolioByType", {"categories": []})], + }, + ) + + async def cash_then_portfolio(): + await tr.cash() + await tr.compact_portfolio() + return [await tr.recv(), await tr.recv()] + + received = asyncio.run(asyncio.wait_for(cash_then_portfolio(), 5)) + + assert [(subscription["type"], payload) for _, subscription, payload in received] == [ + ("cash", [{"amount": 1}]), + ("compactPortfolioByType", {"categories": []}), + ] + + +@pytest.mark.parametrize( + "answers", + [ + [], # no answer at all + [("A", "accountPairs", {"authAccountId": "id-company", "accounts": []})], + [("A", "accountPairs", {"authAccountId": "id-company", "accounts": None})], + ], +) +def test_compact_portfolio_reports_a_missing_securities_account_after_a_switch(answers, monkeypatch): + tr = _switched() + ws = _with_websocket(tr, {"accountPairs": answers}) + lookup = tr._sec_acc_no_from_account_pairs + monkeypatch.setattr(tr, "_sec_acc_no_from_account_pairs", lambda: lookup(timeout=0.05)) + + with pytest.raises(ValueError, match="securities account number from account pairs"): + asyncio.run(tr.compact_portfolio()) + + assert "unsub 1" in ws.sent + + +def test_compact_portfolio_is_unchanged_for_the_own_account(): + tr = _api([{"securitiesAccountNumber": "own-depot"}]) + ws = _with_websocket(tr, {}) + + asyncio.run(tr.compact_portfolio()) + + assert _calls(tr) == [("GET", ACCOUNT)] + assert ws.subscriptions() == [{"type": "compactPortfolioByType", "secAccNo": "own-depot"}] + + +def test_compact_portfolio_still_reports_account_settings_without_a_securities_account(): + tr = _api([{}]) + ws = _with_websocket(tr, {}) + + with pytest.raises(ValueError, match="securities account number from account settings"): + asyncio.run(tr.compact_portfolio()) + + assert ws.sent == [] + + +# --- pytr accounts ------------------------------------------------------------------- + + +def test_print_accounts_prints_what_account_accepts(): + tr = _api([{"relationships": [SELF, COMPANY, {"customerId": "id-bare"}]}]) + + assert account_module.print_accounts(tr).splitlines() == [ + "TYPE NAME CUSTOMER ID STATE", + "ADULT Erika Mustermann id-self your own account", + "LEGAL_ENTITY Mustermann Holding GmbH id-company ACTIVE", + "UNKNOWN id-bare", + ] + + +def test_print_accounts_of_a_login_without_relationships_is_empty(): + assert account_module.print_accounts(_api([{}])) == "" + + +def test_the_accounts_command_exists_and_takes_the_login_arguments(): + args = get_main_parser().parse_args(["accounts", "--v2"]) + + assert (args.command, args.v2, args.account) == ("accounts", True, None) + + +def test_every_command_that_logs_in_takes_an_account(): + parser = get_main_parser() + + for command in (["login"], ["portfolio"], ["details", "DE0000000000"], ["dl_docs", "out"], ["get_price_alarms"]): + assert parser.parse_args([*command, "--account", "LEGAL_ENTITY"]).account == "LEGAL_ENTITY" + + +# --- login() ------------------------------------------------------------------------- + + +class _LoggedIn: + """Stands in for a TradeRepublicApi whose saved session could be resumed.""" + + def __init__(self, switch_error=None): + self._switch_error = switch_error + self.events: list[Any] = [] + + def resume_websession(self): + return True + + def settings(self): + self.events.append("settings") + return {} + + def switch_account(self, account=None): + self.events.append(("switch", account)) + if self._switch_error: + raise self._switch_error + + +def _login(monkeypatch, tmp_path, tr, **kwargs): + # login() creates the directory it stores credentials in; keep it off the real one. + monkeypatch.setattr(account_module, "BASE_DIR", tmp_path / "pytr") + monkeypatch.setattr(account_module, "CREDENTIALS_FILE", tmp_path / "pytr" / "credentials") + monkeypatch.setattr(account_module, "TradeRepublicApi", lambda **_: tr) + return account_module.login(phone_no="+490000000000", pin="0000", **kwargs) + + +def test_login_does_not_switch_by_default(monkeypatch, tmp_path): + tr = _LoggedIn() + + assert _login(monkeypatch, tmp_path, tr) is tr + assert tr.events == ["settings"] + + +def test_login_switches_to_the_requested_account(monkeypatch, tmp_path): + tr = _LoggedIn() + + assert _login(monkeypatch, tmp_path, tr, account="LEGAL_ENTITY") is tr + # The settings are read first: they are refused once the session acts for the other account. + assert tr.events == ["settings", ("switch", "LEGAL_ENTITY")] + + +@pytest.mark.parametrize( + "error", + [ValueError("'nope' was not found"), requests.HTTPError("403", response=_Response({}, 403))], # type: ignore[arg-type] +) +def test_login_exits_when_the_account_cannot_be_used(monkeypatch, tmp_path, error): + with pytest.raises(SystemExit) as excinfo: + _login(monkeypatch, tmp_path, _LoggedIn(switch_error=error), account="nope") + + assert excinfo.value.code == 1 diff --git a/tests/test_api_urls.py b/tests/test_api_urls.py new file mode 100644 index 00000000..816bfbc1 --- /dev/null +++ b/tests/test_api_urls.py @@ -0,0 +1,385 @@ +"""Pin the web login endpoints, their required headers and the login process state machine.""" + +import base64 +import importlib +import json as jsonlib +import re +from typing import Any + +import pytest +import requests + +import pytr.api +from pytr.api import ( + APP_VERSION, + ENV_APP_VERSION, + ENV_PLATFORM, + ENV_USER_AGENT, + USER_AGENT, + WEB_PLATFORM, + TradeRepublicApi, +) + +LOGIN = "https://api.traderepublic.com/api/v2/auth/web/login" +LOGIN_V1 = "https://api.traderepublic.com/api/v1/auth/web/login" +PROCESS = "https://api.traderepublic.com/api/v2/auth/web/login/processes/pid-1" + + +def _error(code: str) -> dict[str, Any]: + return {"errors": [{"errorCode": code, "errorMessage": None, "meta": None}]} + + +class _Response: + def __init__(self, url: str, payload: Any = None, status_code: int = 200): + self.url = url + self.status_code = status_code + self._payload = {} if payload is None else payload + + def raise_for_status(self) -> None: + if self.status_code >= 400: + # Mirrors requests: the message carries the URL, and with it the process id. + raise requests.HTTPError(f"{self.status_code} Client Error for url: {self.url}") + + def json(self) -> Any: + return self._payload + + +class _Session: + """Records requests instead of sending them. Replies come from a queue.""" + + def __init__(self, replies: list[Any]): + self.calls: list[dict[str, Any]] = [] + self._replies = list(replies) + self.cookies = None + self.headers = dict(TradeRepublicApi._default_headers) + + def _record(self, method: str, url: str, json: Any = None, headers: Any = None) -> _Response: + self.calls.append({"method": method, "url": url, "json": json, "headers": headers or {}}) + reply = self._replies.pop(0) if self._replies else {} + status, payload = reply if isinstance(reply, tuple) else (200, reply) + return _Response(url, payload, status) + + def post(self, url, json=None, headers=None): + return self._record("POST", url, json, headers) + + def get(self, url, headers=None): + return self._record("GET", url, None, headers) + + def request(self, method, url, data=None): + return self._record(method, url, None, None) + + +def _api(replies, use_v2_login=True): + tr = TradeRepublicApi(phone_no="+490000000000", pin="0000", waf_token=None, use_v2_login=use_v2_login) + tr._websession = _Session(replies) + return tr + + +def _urls(tr): + return [c["url"] for c in tr._websession.calls] + + +# --- initiate_weblogin --------------------------------------------------------------- + + +def test_initiate_weblogin_uses_v2(): + tr = _api([{"processId": "pid-1", "countdownInSeconds": 60}, {"status": "PENDING"}]) + + countdown = tr.initiate_weblogin() + + assert tr._websession.calls[0]["url"] == LOGIN + assert tr._websession.calls[0]["json"] == {"phoneNumber": "+490000000000", "pin": "0000"} + assert tr._process_id == "pid-1" + assert countdown == 61 + + +def test_initiate_weblogin_without_countdown_defaults_to_120(): + tr = _api([{"processId": "pid-1"}, {"status": "PENDING"}]) + + assert tr.initiate_weblogin() == 121 + + +def test_initiate_weblogin_reads_required_action_from_the_process(): + """The second factor sits on the login process, not in the login response.""" + tr = _api([{"processId": "pid-1"}, {"requiredAction": "AUTHENTICATOR_VERIFICATION"}]) + + tr.initiate_weblogin() + + assert _urls(tr)[1] == PROCESS + assert tr.weblogin_needs_authenticator is True + + +def test_initiate_weblogin_falls_back_to_in_app_when_process_unreadable(): + tr = _api([{"processId": "pid-1"}, (500, _error("UNKNOWN_ERROR"))]) + + tr.initiate_weblogin() + + assert tr.weblogin_needs_authenticator is False + + +def test_initiate_weblogin_rejects_a_null_process_id(): + tr = _api([{"processId": None}]) + + with pytest.raises(ValueError, match="without a confirmation step"): + tr.initiate_weblogin() + + +# --- complete_weblogin --------------------------------------------------------------- + + +def test_complete_weblogin_posts_code_to_authenticator_verification(): + tr = _api([{}, {"status": "CONFIRMED"}]) + tr._process_id = "pid-1" + tr._required_action = "AUTHENTICATOR_VERIFICATION" + + tr.complete_weblogin("123456") + + call = tr._websession.calls[0] + assert call["method"] == "POST" + assert call["url"] == f"{PROCESS}/authenticator-verification" + assert call["json"] == {"code": "123456"} + + +def test_complete_weblogin_requires_a_code_when_authenticator_is_needed(): + tr = _api([]) + tr._process_id = "pid-1" + tr._required_action = "AUTHENTICATOR_VERIFICATION" + + with pytest.raises(ValueError, match="authenticator app"): + tr.complete_weblogin(None) + + +def test_complete_weblogin_polls_the_process_for_in_app_confirmation(): + tr = _api([{"status": "PENDING"}, {"status": "CONFIRMED"}]) + tr._process_id = "pid-1" + + tr.complete_weblogin(None) + + assert [c["method"] for c in tr._websession.calls] == ["GET", "GET"] + assert set(_urls(tr)) == {PROCESS} + + +# --- login process state machine ----------------------------------------------------- + + +@pytest.mark.parametrize("status", ["CONFIRMED", "COMPLETED"]) +def test_poll_accepts_both_terminal_states(status): + tr = _api([{"status": status}]) + tr._process_id = "pid-1" + + tr._await_weblogin_confirmation(interval=0) + + +def test_poll_reports_a_rejected_login(): + tr = _api([(410, _error("ALREADY_PROCESSED"))]) + tr._process_id = "pid-1" + + with pytest.raises(ValueError, match="rejected"): + tr._await_weblogin_confirmation(interval=0) + + +def test_poll_reports_an_expired_login(): + tr = _api([(410, _error("PROCESS_GONE"))]) + tr._process_id = "pid-1" + + with pytest.raises(ValueError, match="expired"): + tr._await_weblogin_confirmation(interval=0) + + +def test_poll_times_out_at_the_server_side_expiry(): + tr = _api([{"status": "PENDING", "expiresAt": "2020-01-01T00:00:00Z"}]) + tr._process_id = "pid-1" + + with pytest.raises(TimeoutError): + tr._await_weblogin_confirmation(interval=0) + + +def test_deadline_prefers_expires_at_over_the_fallback(): + tr = _api([]) + + assert tr._weblogin_deadline({"expiresAt": "2999-01-01T00:00:00Z"}) > tr._weblogin_deadline({}) + 60 + + +def test_login_errors_do_not_leak_the_process_id(): + """raise_for_status() would put the URL, and with it the process id, into the message.""" + tr = _api([(410, _error("PROCESS_GONE"))]) + tr._process_id = "pid-1" + + with pytest.raises(ValueError) as excinfo: + tr._await_weblogin_confirmation(interval=0) + + assert "pid-1" not in str(excinfo.value) + assert "http" not in str(excinfo.value) + + +def test_resend_weblogin_warns_instead_of_calling_a_removed_endpoint(): + tr = _api([]) + + tr.resend_weblogin() + + assert tr._websession.calls == [] + + +# --- required headers ---------------------------------------------------------------- + +REQUIRED_HEADERS = ("X-TR-Device-Info", "X-TR-App-Version", "X-Tr-Platform") + + +def _every_login_call(): + """Every v2 login call pytr makes: start, poll, authenticator verification.""" + poll = _api([{"processId": "pid-1"}, {"status": "PENDING"}, {"status": "CONFIRMED"}]) + poll.initiate_weblogin() + poll.complete_weblogin(None) + + verify = _api([{}, {"status": "CONFIRMED"}]) + verify._process_id = "pid-1" + verify._required_action = "AUTHENTICATOR_VERIFICATION" + verify.complete_weblogin("123456") + + return poll._websession.calls + verify._websession.calls + + +def test_every_v2_login_call_sends_the_required_headers(): + """Without them Trade Republic answers 400 MISSING_REQUIRED_HEADER.""" + calls = _every_login_call() + + assert [c["url"] for c in calls] == [LOGIN, PROCESS, PROCESS, f"{PROCESS}/authenticator-verification", PROCESS] + for call in calls: + for header in REQUIRED_HEADERS: + assert call["headers"].get(header), f"{header} missing on {call['method']} {call['url']}" + + +def test_every_v1_login_call_sends_the_required_headers(): + """v1 login endpoints also reject requests missing X-TR-Device-Info with 400 MISSING_REQUIRED_HEADER.""" + tr = _api([{"processId": "pid-1", "countdownInSeconds": 60}, {}, {}], use_v2_login=False) + + countdown = tr.initiate_weblogin() + tr.resend_weblogin() + tr.complete_weblogin("1234") + + assert countdown == 61 + assert [c["url"] for c in tr._websession.calls] == [ + LOGIN_V1, + f"{LOGIN_V1}/pid-1/resend", + f"{LOGIN_V1}/pid-1/1234", + ] + for call in tr._websession.calls: + for header in REQUIRED_HEADERS: + assert call["headers"].get(header), f"{header} missing on {call['method']} {call['url']}" + + +def test_device_info_is_base64_encoded_json(): + device = jsonlib.loads(base64.b64decode(_api([])._login_headers()["X-TR-Device-Info"])) + + # The frontend hashes a canvas fingerprint with SHA-512; same length, same alphabet. + assert re.fullmatch(r"[0-9a-f]{128}", device["stableDeviceId"]) + assert device["browser"] == "Chrome" + # Taken from the User-Agent, so the two cannot drift apart. + assert device["browserVersion"] in TradeRepublicApi._default_headers["User-Agent"] + + +def test_device_info_is_the_same_for_every_login(): + """The frontend builds it once per page load; ours must not wander between runs.""" + assert _api([])._login_headers()["X-TR-Device-Info"] == _api([])._login_headers()["X-TR-Device-Info"] + + +def test_app_version_and_platform_come_from_the_web_frontend(): + headers = _api([])._login_headers() + + # A build version of the frontend, not a pytr version. + assert re.fullmatch(r"\d+\.\d+\.\d+", headers["X-TR-App-Version"]) + assert headers["X-Tr-Platform"] == "web-pro" + + +# --- environment overrides ----------------------------------------------------------- + +CHROME_149 = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/149.0.0.0 Safari/537.36" + + +FIREFOX_128 = "Mozilla/5.0 (X11; Linux x86_64; rv:128.0) Gecko/20100101 Firefox/128.0" + + +@pytest.fixture +def reimported_with(monkeypatch): + """pytr.api re-imported under a patched environment. + + X-TR-App-Version and X-Tr-Platform are read per call, so those overrides need + nothing special. The User-Agent is baked into _default_headers when the class + body runs, so seeing a different one means importing the module again. + """ + + def _load(**environment): + for name, value in environment.items(): + monkeypatch.setenv(name, value) + return importlib.reload(pytr.api) + + yield _load + monkeypatch.undo() + importlib.reload(pytr.api) + + +def _api_of(module): + return module.TradeRepublicApi(phone_no="+490000000000", pin="0000", waf_token=None, use_v2_login=True) + + +def _device_info_of(module): + return jsonlib.loads(base64.b64decode(_api_of(module)._login_headers()["X-TR-Device-Info"])) + + +def test_app_version_can_be_overridden_from_the_environment(monkeypatch): + """A frontend release makes the built-in stale; 426 must be fixable without a release.""" + monkeypatch.setenv(ENV_APP_VERSION, "2.9999.1") + + assert _api([])._login_headers()["X-TR-App-Version"] == "2.9999.1" + + +def test_platform_can_be_overridden_from_the_environment(monkeypatch): + monkeypatch.setenv(ENV_PLATFORM, "web") + + assert _api([])._login_headers()["X-Tr-Platform"] == "web" + + +def test_user_agent_can_be_overridden_from_the_environment(reimported_with): + module = reimported_with(**{ENV_USER_AGENT: CHROME_149}) + + assert module.TradeRepublicApi._default_headers["User-Agent"] == CHROME_149 + assert _api_of(module)._websession.headers["User-Agent"] == CHROME_149 + + +def test_an_empty_override_keeps_the_built_in_default(monkeypatch, reimported_with): + """An empty assignment must not send an empty header for any of the three.""" + monkeypatch.setenv(ENV_APP_VERSION, "") + monkeypatch.setenv(ENV_PLATFORM, "") + + headers = _api([])._login_headers() + assert headers["X-TR-App-Version"] == APP_VERSION + assert headers["X-Tr-Platform"] == WEB_PLATFORM + + module = reimported_with(**{ENV_USER_AGENT: ""}) + assert module.TradeRepublicApi._default_headers["User-Agent"] == USER_AGENT + + +def test_device_info_follows_the_overridden_user_agent(reimported_with): + """browserVersion is scraped from the User-Agent; the two must not drift apart.""" + assert _device_info_of(reimported_with(**{ENV_USER_AGENT: CHROME_149}))["browserVersion"] == "149.0.0.0" + + +def test_a_non_chrome_user_agent_leaves_the_browser_version_empty(reimported_with): + """The frontend omits what the browser does not provide, and TR accepts that.""" + assert _device_info_of(reimported_with(**{ENV_USER_AGENT: FIREFOX_128}))["browserVersion"] == "" + + +# --- endpoints that must NOT move ---------------------------------------------------- + + +def test_settings_stays_on_v2_account_and_v1_session(): + """Neither endpoint was part of the v1 login removal.""" + tr = _api([{}, {}]) + tr._session_expires_at = 0 + + tr.settings() + + assert _urls(tr) == [ + "https://api.traderepublic.com/api/v1/auth/web/session", + "https://api.traderepublic.com/api/v2/auth/account", + ] diff --git a/tests/test_dl_paths.py b/tests/test_dl_paths.py new file mode 100644 index 00000000..a6c424fa --- /dev/null +++ b/tests/test_dl_paths.py @@ -0,0 +1,394 @@ +"""Tests for dl_docs download target path computation. + +Loads real fixtures from tests/events/, calls dl_callback(), and checks +the local_filepath assigned to each downloadable document. +No network or TR connection needed — DL is constructed without one. +""" + +import json +import logging +from pathlib import Path + +import pytest + +from pytr.dl import DL + +EVENTS_DIR = Path(__file__).parent / "events" +FMT = "{iso_date} {time} {title}" + + +def make_dl(tmp_path: Path) -> DL: + dl = DL.__new__(DL) + dl.tr = None + dl.output_path = tmp_path + dl.filename_fmt = FMT + dl.flat = False + dl.universal_filepath = True + dl.dry_run = True + dl.filepaths = [] + dl.doc_urls = [] + dl.futures = [] + dl.events_with_docs = [] + dl.events_without_docs = [] + dl.docs_request = 0 + dl.done = 0 + dl.events_processed = 0 + dl.session = None + dl.log = logging.getLogger("test_dl_paths") + return dl + + +def collect_paths(fixture_name: str, tmp_path: Path) -> list[str]: + """Run dl_callback on a fixture; return relative posix paths of assigned documents.""" + dl = make_dl(tmp_path) + with open(EVENTS_DIR / fixture_name, encoding="utf-8") as f: + event = json.load(f) + dl.dl_callback(event) + result = [] + for section in event["details"]["sections"]: + if section["type"] != "documents": + continue + for doc in section["data"]: + if "local_filepath" in doc: + result.append(Path(doc["local_filepath"]).relative_to(tmp_path).as_posix()) + return result + + +test_data: list[dict] = [ + # --- Trades: eventType-mapped --- + { + "filename": "buy.json", + # ORDER_EXECUTED → Trades/; three distinct doc types + # Note: universal_filepath=True replaces ":" with "_" in the time component + "paths": [ + "Trades/2024-02-20 16_32 Abrechnung - Euro Stoxx 50 EUR (Dist) - Kauforder.pdf", + "Trades/Basisinformationsblatt/2024-02-20 16_32 Basisinformationsblatt - Euro Stoxx 50 EUR (Dist) - Kauforder.pdf", + "Trades/Kosteninformation/2024-02-20 16_32 Kosteninformation - Euro Stoxx 50 EUR (Dist) - Kauforder.pdf", + ], + }, + { + "filename": "trade_invoice.json", + # TRADE_INVOICE → Trades/ + "paths": [ + "Trades/2024-06-04 06_23 Abrechnung - DWS Group - Limit-Buy-Order.pdf", + "Trades/Auftragsbestätigung/2024-06-04 06_23 Auftragsbestätigung - DWS Group - Limit-Buy-Order.pdf", + "Trades/Kosteninformation/2024-06-04 06_23 Kosteninformation - DWS Group - Limit-Buy-Order.pdf", + ], + }, + { + "filename": "buy_new.json", + # trading_trade_executed (normalised → TRADING_TRADE_EXECUTED) → Trades/ + "paths": [ + "Trades/2025-10-10 19_29 Abrechnung - NVIDIA - Kauforder.pdf", + "Trades/Kosteninformation/2025-10-10 19_29 Kosteninformation - NVIDIA - Kauforder.pdf", + ], + }, + { + "filename": "limit-sell-order.json", + # trading_trade_executed → Trades/ + "paths": [ + "Trades/Auftragsbestätigung/2025-05-20 08_03 Auftragsbestätigung - D-Wave Quantum - Limit-Sell-Order.pdf", + "Trades/Kosteninformation/2025-05-20 08_03 Kosteninformation - D-Wave Quantum - Limit-Sell-Order.pdf", + "Trades/2025-05-20 08_03 Abrechnung - D-Wave Quantum - Limit-Sell-Order.pdf", + ], + }, + { + "filename": "bond_kauf.json", + # TRADING_TRADE_EXECUTED; fixture has "Kosteninformation 1/2", "Abrechnung 1/2" + # Number in title already differentiates → no dedup suffix + "paths": [ + "Trades/Kosteninformation/2025-07-18 08_04 Kosteninformation 1 - Juli 2040 - Kauforder.pdf", + "Trades/Kosteninformation/2025-07-18 08_04 Kosteninformation 2 - Juli 2040 - Kauforder.pdf", + "Trades/2025-07-18 08_04 Abrechnung 1 - Juli 2040 - Kauforder.pdf", + "Trades/2025-07-18 08_04 Abrechnung 2 - Juli 2040 - Kauforder.pdf", + ], + }, + { + "filename": "verkaufsorder_abrechnung12.json", + # TRADING_TRADE_EXECUTED; "Abrechnung 1/2", "Kosteninformation 1/2" + # Number in title already differentiates → no dedup suffix; Abrechnung flat in Trades/ + "paths": [ + "Trades/2026-05-18 15_37 Abrechnung 1 - Zalando - Verkaufsorder.pdf", + "Trades/2026-05-18 15_37 Abrechnung 2 - Zalando - Verkaufsorder.pdf", + "Trades/Kosteninformation/2026-05-18 15_37 Kosteninformation 1 - Zalando - Verkaufsorder.pdf", + "Trades/Kosteninformation/2026-05-18 15_37 Kosteninformation 2 - Zalando - Verkaufsorder.pdf", + ], + }, + { + "filename": "trade_corrected.json", + # TRADE_CORRECTED → Trades/; fixture docs named "Abrechnung 2" / "Abrechnung 1" + # Number in title already differentiates → no dedup suffix + "paths": [ + "Trades/2024-12-16 09_59 Abrechnung 2 - Worldline - Limit Verkauf-Order neu abgerechnet.pdf", + "Trades/2024-12-16 09_59 Abrechnung 1 - Worldline - Limit Verkauf-Order neu abgerechnet.pdf", + "Trades/Auftragsbestätigung/2024-12-16 09_59 Auftragsbestätigung - Worldline - Limit Verkauf-Order neu abgerechnet.pdf", + "Trades/Kosteninformation/2024-12-16 09_59 Kosteninformation - Worldline - Limit Verkauf-Order neu abgerechnet.pdf", + ], + }, + { + "filename": "savingsplan.json", + # trading_savingsplan_executed → Sparplan/; Abrechnungsausführung → normalised to Abrechnung + "paths": [ + "Sparplan/2025-10-23 08_26 Abrechnung - DroneShield - Sparplan ausgeführt.pdf", + ], + }, + { + "filename": "trading_savingsplan_executed.json", + # TRADING_SAVINGSPLAN_EXECUTED → Sparplan/ + "paths": [ + "Sparplan/2025-02-10 09_23 Abrechnung - BASF - Sparplan ausgeführt.pdf", + ], + }, + { + "filename": "savings_plan_invoice_created.json", + # SAVINGS_PLAN_INVOICE_CREATED → Sparplan/; Abrechnung Ausführung → normalised to Abrechnung + "paths": [ + "Sparplan/2024-06-17 08_16 Abrechnung - Volkswagen (Vz.) - Sparplan ausgeführt.pdf", + ], + }, + { + "filename": "ipo-spacex.json", + # IPO_TRADE_EXECUTED → Trades/ + "paths": [ + "Trades/2026-06-06 04_20 Abrechnung - SpaceX - IPO.pdf", + "Trades/Kosteninformation/2026-06-06 04_20 Kosteninformation - SpaceX - IPO.pdf", + "Trades/Prospekt/2026-06-06 04_20 Prospekt - SpaceX - IPO.pdf", + ], + }, + # --- Trades: no-eventType / legacy subtitle fallback --- + { + "filename": "buy_no_eventType.json", + # No eventType, subtitle=Kauforder → subtitle_subfolder_mapping → Trades/ + "paths": [ + "Trades/2024-02-20 16_32 Abrechnung - Euro Stoxx 50 EUR (Dist) - Kauforder.pdf", + "Trades/Basisinformationsblatt/2024-02-20 16_32 Basisinformationsblatt - Euro Stoxx 50 EUR (Dist) - Kauforder.pdf", + "Trades/Kosteninformation/2024-02-20 16_32 Kosteninformation - Euro Stoxx 50 EUR (Dist) - Kauforder.pdf", + ], + }, + { + "filename": "legacy_verkauforder_neu_abgerechnet.json", + # TIMELINE_LEGACY_MIGRATED_EVENTS, subtitle → Trades/ + # fixture docs named "Abrechnung 2" / "Abrechnung 1"; number differentiates → no dedup suffix + "paths": [ + "Trades/2025-02-21 11_14 Abrechnung 2 - Marie Brizard Wine and Spirits - Limit Verkauf-Order neu abgerechnet.pdf", + "Trades/2025-02-21 11_14 Abrechnung 1 - Marie Brizard Wine and Spirits - Limit Verkauf-Order neu abgerechnet.pdf", + "Trades/Auftragsbestätigung/2025-02-21 11_14 Auftragsbestätigung - Marie Brizard Wine and Spirits - Limit Verkauf-Order neu abgerechnet.pdf", + "Trades/Kosteninformation/2025-02-21 11_14 Kosteninformation - Marie Brizard Wine and Spirits - Limit Verkauf-Order neu abgerechnet.pdf", + ], + }, + # --- Dividends --- + { + "filename": "dividende_wahlweise2.json", + # SSP_CORPORATE_ACTION_ACTIVITY → Misc, subtitle override → Dividende/; flat (like Dokumente) + "paths": [ + "Dividende/2024-11-05 16_48 Dividende Wahlweise - Unilever - Dividende. Cash oder Stockdividende.pdf", + ], + }, + { + "filename": "dividende_wahlweise3.json", + # SSP_CORPORATE_ACTION_INSTRUCTION → Misc, subtitle override → Dividende/; flat (like Dokumente) + "paths": [ + "Dividende/2026-07-29 13_38 Dividende Wahlweise - Rio Tinto - Dividende. Cash oder Stockdividende.pdf", + ], + }, + { + "filename": "bardividende.json", + # ssp_corporate_action_invoice_cash → Dividende/; doc type Dokumente → flat under subfolder + "paths": [ + "Dividende/2025-10-23 14_19 Comcast (A) - Bardividende.pdf", + ], + }, + { + "filename": "bardividende_no_eventType.json", + # No eventType, subtitle=Bardividende → Dividende/ + "paths": [ + "Dividende/2025-11-05 18_31 Lowe's - Bardividende.pdf", + ], + }, + { + "filename": "bardividende_korrigiert2.json", + # SSP_CORPORATE_ACTION_CASH → Dividende/; doc title Dividendenbeleg → flat (like Dokumente) + "paths": [ + "Dividende/2026-06-26 13_51 Dividendenbeleg - Medical Properties Trust - Bardividende korrigiert.pdf", + ], + }, + { + "filename": "aktiendividende.json", + # ssp_corporate_action_invoice_shares → Misc, but subtitle Aktiendividende overrides → Dividende/ + "paths": [ + "Dividende/2025-07-22 14_31 Enovix - Aktiendividende.pdf", + ], + }, + { + "filename": "aktienpraemiendividende.json", + # ssp_corporate_action_invoice_cash → Dividende/ (via subtitle_subfolder_mapping); doc: Dokumente → flat + "paths": [ + "Dividende/2025-09-22 11_20 Glencore - Aktienprämiendividende.pdf", + ], + }, + { + "filename": "aktienpraemiendividende2.json", + # SSP_CORPORATE_ACTION_CASH_NON_DIVIDEND → Misc, subtitle Aktienprämiendividende overrides → Dividende/ + # Two Dokumente docs → second gets counter " 2" appended + "paths": [ + "Dividende/2026-07-02 10_41 Hensoldt - Aktienprämiendividende.pdf", + "Dividende/2026-07-02 10_41 Hensoldt - Aktienprämiendividende 2.pdf", + ], + }, + { + "filename": "vorabpauschale.json", + # ssp_corporate_action_invoice_cash → Dividende/; doc title Vorabpauschale (not Dokumente) → subdir + "paths": [ + "Dividende/Vorabpauschale/2025-01-28 14_54 Vorabpauschale - MSCI China USD (Acc) - Vorabpauschale.pdf", + ], + }, + # --- Transfers / payments --- + { + "filename": "bank_transaction_incoming.json", + # BANK_TRANSACTION_INCOMING → Einzahlungen/; flat (like Dokumente) + "paths": [ + "Einzahlungen/2024-07-04 06_17 Transaktionsbestätigung - Max Mustermann - Fertig.pdf", + ], + }, + { + "filename": "bank_transaction_outgoing.json", + # BANK_TRANSACTION_OUTGOING → Auszahlungen/; flat (like Dokumente) + "paths": [ + "Auszahlungen/2024-07-21 09_35 Transaktionsbestätigung - Max Mustermann - Gesendet.pdf", + ], + }, + { + "filename": "incoming_transfer.json", + # INCOMING_TRANSFER → Einzahlungen/; flat (like Dokumente) + "paths": [ + "Einzahlungen/2024-09-02 17_49 Transaktionsbestätigung - Klaus Mustermann - Fertig.pdf", + ], + }, + { + "filename": "outgoing_transfer.json", + # OUTGOING_TRANSFER → Auszahlungen/; flat (like Dokumente) + "paths": [ + "Auszahlungen/2024-07-21 09_35 Transaktionsbestätigung - Hans Mustermann - Gesendet.pdf", + ], + }, + # --- Interest --- + { + "filename": "interest_payout_created.json", + # INTEREST_PAYOUT_CREATED → Zinsen/; flat + "paths": [ + "Zinsen/2024-07-01 04_51 Abrechnung - Zinsen.pdf", + ], + }, + { + "filename": "legacy_zinsen.json", + # TIMELINE_LEGACY_MIGRATED_EVENTS, title=Zinsen → title_subfolder_mapping → Zinsen/; flat + "paths": [ + "Zinsen/2024-09-01 16_39 Abrechnung - Zinsen.pdf", + ], + }, + { + "filename": "legacy_zinsen_no_eventType.json", + # no eventType, title=Zinsen → title_subfolder_mapping → Zinsen/; flat + "paths": [ + "Zinsen/2024-09-01 16_39 Abrechnung - Zinsen.pdf", + ], + }, + # --- Steuerkorrektur --- + { + "filename": "steuerkorrektur.json", + # ssp_tax_correction_invoice → Steuerkorrekturen/; Steuerabrechnung → flat (like Dokumente) + "paths": [ + "Steuerkorrekturen/2025-10-28 00_00 Steuerkorrektur.pdf", + ], + }, + { + "filename": "ssp_tax_correction.json", + # SSP_TAX_CORRECTION → Steuerkorrekturen/ + "paths": [ + "Steuerkorrekturen/2024-06-11 22_45 Steuerkorrektur.pdf", + ], + }, + { + "filename": "steuerkorrektur_no_eventType.json", + # No eventType, title=Steuerkorrektur → title_subfolder_mapping → Steuerkorrekturen/ + "paths": [ + "Steuerkorrekturen/2025-11-04 23_31 Steuerkorrektur.pdf", + ], + }, + # --- Saveback / RoundUp --- + { + "filename": "saveback_aggregate.json", + # SAVEBACK_AGGREGATE → Saveback/; Abrechnung Ausführung → normalised to Abrechnung + "paths": [ + "Saveback/2024-07-02 13_53 Abrechnung - S&P 500 Information Tech USD (Acc) - Saveback.pdf", + "Saveback/Kosteninformation/2024-07-02 13_53 Kosteninformation - S&P 500 Information Tech USD (Acc) - Saveback.pdf", + ], + }, + { + "filename": "spare_change_aggregate.json", + # SPARE_CHANGE_AGGREGATE → RoundUp/; Abrechnung Ausführung → normalised to Abrechnung + "paths": [ + "RoundUp/2024-06-10 13_52 Abrechnung - S&P 500 Information Tech USD (Acc) - Round up.pdf", + "RoundUp/Kosteninformation/2024-06-10 13_52 Kosteninformation - S&P 500 Information Tech USD (Acc) - Round up.pdf", + ], + }, + # --- Corporate actions --- + { + "filename": "aktienbonus.json", + # ACQUISITION_TRADE_PERK → Misc/; title becomes subdir + "paths": [ + "Misc/Aktien-Bonus/2025-10-13 14_49 Kosteninformation - Aktien-Bonus - Eingelöst.pdf", + "Misc/Aktien-Bonus/2025-10-13 14_49 Rechnung - Aktien-Bonus - Eingelöst.pdf", + ], + }, + { + "filename": "trade_perk.json", + # ACQUISITION_TRADE_PERK → Misc/; title becomes subdir + "paths": [ + "Misc/Aktien-Bonus/2025-04-01 14_09 Rechnung - Aktien-Bonus - Eingelöst.pdf", + "Misc/Aktien-Bonus/2025-04-01 14_09 Kosteninformation - Aktien-Bonus - Eingelöst.pdf", + ], + }, + # --- Corporate actions --- + { + "filename": "aktiensplit.json", + # ssp_corporate_action_invoice_shares → Misc/; Dokumente + Misc → subtitle becomes subdir + "paths": [ + "Misc/Aktiensplit/2024-06-26 08_06 Chipotle Mexican Grill.pdf", + ], + }, + { + "filename": "aktiensplit2.json", + # SSP_CORPORATE_ACTION_NO_CASH → Misc/; Dokumente + Misc → subtitle becomes subdir + "paths": [ + "Misc/Aktiensplit/2026-07-02 06_31 Crowdstrike Holdings (A).pdf", + ], + }, + { + "filename": "spinoff.json", + # ssp_corporate_action_invoice_shares → Misc/; Dokumente + Misc → subtitle becomes subdir + "paths": [ + "Misc/Spin-off/2025-10-20 11_25 ThyssenKrupp.pdf", + ], + }, + { + "filename": "private_markets_trade.json", + # private_markets_trade_executed (normalised → PRIVATE_MARKETS_TRADE_EXECUTED) → Trades/ + "paths": [ + "Trades/Kosteninformation/2025-09-18 07_14 Kosteninformation - Private Equity - Kauforder.pdf", + "Trades/2025-09-18 07_14 Abrechnung - Private Equity - Kauforder.pdf", + ], + }, + { + "filename": "private_markets_vorabpauschale.json", + # SSP_CORPORATE_ACTION_CASH_NON_DIVIDEND → Misc/; doc: Vorabpauschale (not Dokumente) → subdir + "paths": [ + "Misc/Vorabpauschale/2026-03-09 07_56 Vorabpauschale - Private Equity - Vorabpauschale.pdf", + ], + }, +] + + +@pytest.mark.parametrize("case", test_data, ids=[c["filename"] for c in test_data]) +def test_dl_paths(case, tmp_path): + assert collect_paths(case["filename"], tmp_path) == case["paths"] diff --git a/tests/test_events.py b/tests/test_events.py index 1bd47a8a..8743c816 100644 --- a/tests/test_events.py +++ b/tests/test_events.py @@ -1,2055 +1,2728 @@ import json +from pathlib import Path + +import pytest from pytr.event import ConditionalEventType, Event, PPEventType from pytr.transactions import TransactionExporter +EVENTS_DIR = Path(__file__).parent / "events" + +test_data: list[dict] = [ + { + "filename": "address_changed.json", + "event_type": None, + }, + { + "filename": "aktien_entfernt.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "ORSTED A/S -ANR-", + "isin": "DK0064307839", + "shares": 0.285835, + "value": 0, + "transactions": [ + { + "Datum": "2025-10-28T15:46:46", + "Typ": "Verkauf", + "Wert": 0, + "Notiz": "ORSTED A/S -ANR-", + "ISIN": "DK0064307839", + "Stück": 0.285835, + } + ], + }, + { + "filename": "aktien_entfernt_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "ORSTED A/S -ANR-", + "isin": "DK0064307839", + "shares": 0.285835, + "value": 0, + "transactions": [ + { + "Datum": "2025-10-28T15:46:46", + "Typ": "Verkauf", + "Wert": 0, + "Notiz": "ORSTED A/S -ANR-", + "ISIN": "DK0064307839", + "Stück": 0.285835, + } + ], + }, + { + "filename": "aktien_entfernt2.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "WORLDLINE S.A. ANR", + "isin": "FR0014015MS9", + "shares": 0.299376, + "value": 0, + "transactions": [ + { + "Datum": "2026-04-03T10:48:40", + "Typ": "Verkauf", + "Wert": 0, + "Notiz": "WORLDLINE S.A. ANR", + "ISIN": "FR0014015MS9", + "Stück": 0.299376, + } + ], + }, + { + "filename": "aktienbonus.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "Aktien-Bonus", + "isin": "US2546871060", + "shares": 0.105, + "value": -10.03, + "transactions": [ + { + "Datum": "2025-10-13T14:49:06", + "Typ": "Kauf", + "Wert": -10.03, + "Notiz": "Aktien-Bonus", + "ISIN": "US2546871060", + "Stück": 0.105, + }, + { + "Datum": "2025-10-13T14:49:06", + "Typ": "Einlage", + "Wert": 10.03, + "Notiz": "Aktien-Bonus", + }, + ], + }, + { + "filename": "aktienbonus_no_eventType.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "Aktien-Bonus", + "isin": "US2546871060", + "shares": 0.105, + "value": -10.03, + "transactions": [ + { + "Datum": "2025-10-13T14:49:06", + "Typ": "Kauf", + "Wert": -10.03, + "Notiz": "Aktien-Bonus", + "ISIN": "US2546871060", + "Stück": 0.105, + }, + { + "Datum": "2025-10-13T14:49:06", + "Typ": "Einlage", + "Wert": 10.03, + "Notiz": "Aktien-Bonus", + }, + ], + }, + { + "filename": "aktiendividende.json", + "event_type": PPEventType.SPINOFF, + "title": "Enovix", + "isin": "US2935941318", + "isin2": "US2935941078", + "shares": 0.494370, + "value": 0, + "note": "Enovix Corp. WTS 01.10.26", + "transactions": [ + { + "Datum": "2025-07-22T14:31:49", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "Enovix Corp. WTS 01.10.26", + "ISIN": "US2935941318", + "Stück": 0.494370, + "ISIN2": "US2935941078", + } + ], + }, + { + "filename": "aktiendividende_no_eventType.json", + "event_type": PPEventType.SPINOFF, + "title": "Enovix", + "isin": "US2935941318", + "isin2": "US2935941078", + "shares": 0.494370, + "value": 0, + "note": "Enovix Corp. WTS 01.10.26", + "transactions": [ + { + "Datum": "2025-07-22T14:31:49", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "Enovix Corp. WTS 01.10.26", + "ISIN": "US2935941318", + "Stück": 0.494370, + "ISIN2": "US2935941078", + } + ], + }, + { + "filename": "aktiendividende_only_taxes.json", + "event_type": PPEventType.TAXES, + "title": "Enovix Corp. WTS 01.10.26", + "isin": "US2935941318", + "value": -0.57, + "taxes": 0.57, + "transactions": [ + { + "Datum": "2026-01-06T16:14:51", + "Typ": "Steuern", + "Wert": -0.57, + "Notiz": "Enovix Corp. WTS 01.10.26", + "ISIN": "US2935941318", + "Steuern": 0.57, + } + ], + }, + { + "filename": "aktienpraemiendividende.json", + "event_type": PPEventType.DIVIDEND, + "title": "Glencore", + "isin": "JE00B4T3BW64", + "value": 3, + "taxes": 1.15, + "transactions": [ + { + "Datum": "2025-09-22T11:20:31", + "Typ": "Dividende", + "Wert": 3.0, + "Notiz": "Glencore", + "ISIN": "JE00B4T3BW64", + "Steuern": 1.15, + } + ], + }, + { + "filename": "aktienpraemiendividende2.json", + "event_type": None, + }, + { + "filename": "aktienpraemiendividende_no_eventType.json", + "event_type": PPEventType.DIVIDEND, + "title": "Glencore", + "isin": "JE00B4T3BW64", + "value": 3, + "taxes": 1.15, + "transactions": [ + { + "Datum": "2025-09-22T11:20:31", + "Typ": "Dividende", + "Wert": 3.0, + "Notiz": "Glencore", + "ISIN": "JE00B4T3BW64", + "Steuern": 1.15, + } + ], + }, + { + "filename": "aktiensplit.json", + "event_type": PPEventType.SPLIT, + "title": "Chipotle Mexican Grill", + "isin": "US1696561059", + "shares": 49, + "value": 0, + "transactions": [ + { + "Datum": "2024-06-26T08:06:40", + "Typ": "Split", + "Wert": 0, + "Notiz": "Chipotle Mexican Grill", + "ISIN": "US1696561059", + "Stück": 49, + } + ], + }, + { + "filename": "aktiensplit2.json", + "event_type": PPEventType.SPLIT, + "title": "Crowdstrike Holdings (A)", + "isin": "US22788C1053", + "shares": 0.688026, + "value": 0, + "transactions": [ + { + "Datum": "2026-07-02T06:31:26", + "Typ": "Split", + "Wert": 0, + "Notiz": "Crowdstrike Holdings (A)", + "ISIN": "US22788C1053", + "Stück": 0.688026, + } + ], + }, + { + "filename": "aktiensplit_no_eventType.json", + "event_type": PPEventType.SPLIT, + "title": "Netflix", + "isin": "US64110L1061", + "shares": 2.743902, + "value": 0, + "transactions": [ + { + "Datum": "2025-11-17T06:07:56", + "Typ": "Split", + "Wert": 0, + "Notiz": "Netflix", + "ISIN": "US64110L1061", + "Stück": 2.743902, + } + ], + }, + { + "filename": "bardividende.json", + "event_type": PPEventType.DIVIDEND, + "title": "Comcast (A)", + "isin": "US20030N1019", + "shares": 10.640298, + "value": 2.24, + "taxes": 0.78, + "transactions": [ + { + "Datum": "2025-10-23T14:19:56", + "Typ": "Dividende", + "Wert": 2.24, + "Notiz": "Comcast (A)", + "ISIN": "US20030N1019", + "Stück": 10.640298, + "Steuern": 0.78, + } + ], + }, + { + "filename": "bardividende_no_eventType.json", + "event_type": PPEventType.DIVIDEND, + "title": "Lowe's", + "isin": "US5486611073", + "shares": 1.189904, + "value": 0.92, + "taxes": 0.32, + "transactions": [ + { + "Datum": "2025-11-05T18:31:19", + "Typ": "Dividende", + "Wert": 0.92, + "Notiz": "Lowe's", + "ISIN": "US5486611073", + "Stück": 1.189904, + "Steuern": 0.32, + } + ], + }, + { + "filename": "bardividende_zero.json", + "event_type": PPEventType.DIVIDEND, + "title": "L'Oreal", + "isin": "FR0000120321", + "shares": 0.000125, + "value": 0, + "transactions": [ + { + "Datum": "2025-05-07T15:32:27", + "Typ": "Dividende", + "Wert": 0.0, + "Notiz": "L'Oreal", + "ISIN": "FR0000120321", + "Stück": 0.000125, + } + ], + }, + { + "filename": "bardividende_korrigiert.json", + "event_type": PPEventType.DIVIDEND, + "title": "Medical Properties Trust", + "isin": "US58463J3041", + "shares": 40, + "value": 4.01, + "taxes": 1.53, + "transactions": [ + { + "Datum": "2025-03-20T15:04:31", + "Typ": "Dividende", + "Wert": 4.01, + "Notiz": "Medical Properties Trust", + "ISIN": "US58463J3041", + "Stück": 40.0, + "Steuern": 1.53, + } + ], + }, + { + "filename": "bardividende_korrigiert_no_eventType.json", + "event_type": PPEventType.DIVIDEND, + "title": "Medical Properties Trust", + "isin": "US58463J3041", + "shares": 40, + "value": 4.01, + "taxes": 1.53, + "transactions": [ + { + "Datum": "2025-03-20T15:04:31", + "Typ": "Dividende", + "Wert": 4.01, + "Notiz": "Medical Properties Trust", + "ISIN": "US58463J3041", + "Stück": 40.0, + "Steuern": 1.53, + } + ], + }, + { + "filename": "bardividende_korrigiert2.json", + "event_type": PPEventType.DIVIDEND, + "title": "Medical Properties Trust", + "isin": "US58463J3041", + "value": 0.37, + "transactions": [ + { + "Datum": "2026-06-26T13:51:37", + "Typ": "Dividende", + "Wert": 0.37, + "Notiz": "Medical Properties Trust", + "ISIN": "US58463J3041", + } + ], + }, + { + "filename": "benefits_spare_change_execution.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "SuperDividend USD (Dist)", + "isin": "IE00077FRP95", + "shares": 0.383219, + "value": -3.38, + "transactions": [ + { + "Datum": "2024-10-02T15:05:40", + "Typ": "Kauf", + "Wert": -3.38, + "Notiz": "SuperDividend USD (Dist)", + "ISIN": "IE00077FRP95", + "Stück": 0.383219, + } + ], + }, + { + "filename": "benefits_spare_change_execution_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "SuperDividend USD (Dist)", + "isin": "IE00077FRP95", + "shares": 0.383219, + "value": -3.38, + "transactions": [ + { + "Datum": "2024-10-02T15:05:40", + "Typ": "Kauf", + "Wert": -3.38, + "Notiz": "SuperDividend USD (Dist)", + "ISIN": "IE00077FRP95", + "Stück": 0.383219, + } + ], + }, + { + "filename": "bonusaktien.json", + "event_type": PPEventType.SPLIT, + "title": "Eckert & Ziegler", + "isin": "DE0005659700", + "shares": 5.706536, + "value": 0, + "transactions": [ + { + "Datum": "2025-08-15T08:10:12", + "Typ": "Split", + "Wert": 0, + "Notiz": "Eckert & Ziegler", + "ISIN": "DE0005659700", + "Stück": 5.706536, + } + ], + }, + { + "filename": "bonusaktien_no_eventType.json", + "event_type": PPEventType.SPLIT, + "title": "Eckert & Ziegler", + "isin": "DE0005659700", + "shares": 5.706536, + "value": 0, + "transactions": [ + { + "Datum": "2025-08-15T08:10:12", + "Typ": "Split", + "Wert": 0, + "Notiz": "Eckert & Ziegler", + "ISIN": "DE0005659700", + "Stück": 5.706536, + } + ], + }, + { + "filename": "bonusaktien_tax_only.json", + "event_type": PPEventType.TAXES, + "title": "BYD", + "isin": "CNE100000296", + "value": -8.67, + "taxes": 8.67, + "transactions": [ + { + "Datum": "2025-08-15T14:53:09", + "Typ": "Steuern", + "Wert": -8.67, + "Notiz": "BYD", + "ISIN": "CNE100000296", + "Steuern": 8.67, + } + ], + }, + { + "filename": "bonusaktien2.json", + "event_type": PPEventType.SPLIT, + "title": "BYD", + "isin": "CNE100000296", + "shares": 2.149301, + "value": 0, + "transactions": [ + { + "Datum": "2025-08-13T05:22:45", + "Typ": "Split", + "Wert": 0, + "Notiz": "BYD", + "ISIN": "CNE100000296", + "Stück": 2.149301, + } + ], + }, + { + "filename": "bonusaktien_canceled.json", + "event_type": None, + "title": "BYD", + "isin": None, + "shares": None, + "value": None, + "transactions": [], + }, + { + "filename": "bonusaktien_tax_only_no_eventType.json", + "event_type": PPEventType.TAXES, + "title": "BYD", + "isin": "CNE100000296", + "value": -8.67, + "taxes": 8.67, + "transactions": [ + { + "Datum": "2025-08-15T14:53:09", + "Typ": "Steuern", + "Wert": -8.67, + "Notiz": "BYD", + "ISIN": "CNE100000296", + "Steuern": 8.67, + } + ], + }, + { + "filename": "bond_kauf.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Juli 2040", + "isin": "DE0001135366", + "shares": 82.27, + "value": -100.99, + "fees": 1.0, + "transactions": [ + { + "Datum": "2025-07-18T08:04:42", + "Typ": "Kauf", + "Wert": -100.99, + "Notiz": "Juli 2040", + "ISIN": "DE0001135366", + "Stück": 82.27, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "bond_verkauf.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Juli 2040", + "isin": "DE0001135366", + "shares": 82.27, + "value": 98.21, + "fees": 1.0, + "transactions": [ + { + "Datum": "2026-03-26T06:48:09", + "Typ": "Verkauf", + "Wert": 98.21, + "Notiz": "Juli 2040", + "ISIN": "DE0001135366", + "Stück": 82.27, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "buy.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Euro Stoxx 50 EUR (Dist)", + "isin": "IE00B4K6B022", + "shares": 60, + "value": -3002.8, + "fees": 1.0, + "transactions": [ + { + "Datum": "2024-02-20T16:32:07", + "Typ": "Kauf", + "Wert": -3002.8, + "Notiz": "Euro Stoxx 50 EUR (Dist)", + "ISIN": "IE00B4K6B022", + "Stück": 60.0, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "buy_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Euro Stoxx 50 EUR (Dist)", + "isin": "IE00B4K6B022", + "shares": 60, + "value": -3002.8, + "fees": 1.0, + "transactions": [ + { + "Datum": "2024-02-20T16:32:07", + "Typ": "Kauf", + "Wert": -3002.8, + "Notiz": "Euro Stoxx 50 EUR (Dist)", + "ISIN": "IE00B4K6B022", + "Stück": 60.0, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "buy_new.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "NVIDIA", + "isin": "US67066G1040", + "shares": 0.685102, + "value": -111, + "fees": 1.0, + "transactions": [ + { + "Datum": "2025-10-10T19:29:43", + "Typ": "Kauf", + "Wert": -111, + "Notiz": "NVIDIA", + "ISIN": "US67066G1040", + "Stück": 0.685102, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "buy_new_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "NVIDIA", + "isin": "US67066G1040", + "shares": 0.685102, + "value": -111, + "fees": 1.0, + "transactions": [ + { + "Datum": "2025-10-10T19:29:43", + "Typ": "Kauf", + "Wert": -111, + "Notiz": "NVIDIA", + "ISIN": "US67066G1040", + "Stück": 0.685102, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "buy_new2.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Rocket Lab Corp. Registered Shares DL-,0001", + "isin": "US7731211089", + "shares": 2, + "value": -75.6, + "fees": 1.0, + "transactions": [ + { + "Datum": "2025-08-01T08:28:01", + "Typ": "Kauf", + "Wert": -75.6, + "Notiz": "Rocket Lab Corp. Registered Shares DL-,0001", + "ISIN": "US7731211089", + "Stück": 2, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "buy_new2_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Rocket Lab Corp. Registered Shares DL-,0001", + "isin": "US7731211089", + "shares": 2, + "value": -75.6, + "fees": 1.0, + "transactions": [ + { + "Datum": "2025-08-01T08:28:01", + "Typ": "Kauf", + "Wert": -75.6, + "Notiz": "Rocket Lab Corp. Registered Shares DL-,0001", + "ISIN": "US7731211089", + "Stück": 2, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "card_refund.json", + "event_type": PPEventType.DEPOSIT, + "title": "Decathlon", + "value": 24.99, + "note": "card_refund", + "transactions": [ + { + "Datum": "2025-08-17T07:23:44", + "Typ": "Einlage", + "Wert": 24.99, + "Notiz": "Kartenerstattung - Decathlon", + } + ], + }, + { + "filename": "card_refund_no_eventType.json", + "event_type": PPEventType.DEPOSIT, + "title": "Decathlon", + "value": 24.99, + "note": "card_refund", + "transactions": [ + { + "Datum": "2025-08-17T07:23:44", + "Typ": "Einlage", + "Wert": 24.99, + "Notiz": "Kartenerstattung - Decathlon", + } + ], + }, + { + "filename": "deposit.json", + "event_type": PPEventType.DEPOSIT, + "title": "My Name", + "value": 200, + "transactions": [ + { + "Datum": "2024-06-03T17:07:26", + "Typ": "Einlage", + "Wert": 200.0, + "Notiz": "My Name", + } + ], + }, + { + "filename": "deposit_no_eventType.json", + "event_type": PPEventType.DEPOSIT, + "title": "My Name", + "value": 200, + "transactions": [ + { + "Datum": "2024-06-03T17:07:26", + "Typ": "Einlage", + "Wert": 200.0, + "Notiz": "My Name", + } + ], + }, + { + "filename": "dividende_old.json", + "event_type": PPEventType.DIVIDEND, + "title": "MSCI World USD (Dist)", + "isin": "LU0392494562", + "shares": 32, + "value": 30.21, + "taxes": 6.83, + "transactions": [ + { + "Datum": "2024-12-31T23:59:59", + "Typ": "Dividende", + "Wert": 30.21, + "Notiz": "MSCI World USD (Dist)", + "ISIN": "LU0392494562", + "Stück": 32.0, + "Steuern": 6.83, + } + ], + }, + { + "filename": "dividende_wahlweise.json", + "event_type": PPEventType.DIVIDEND, + "title": "National Grid", + "isin": "GB00BDR05C01", + "value": 3.37, + "taxes": 1.28, + "transactions": [ + { + "Datum": "2024-07-19T13:28:04", + "Typ": "Dividende", + "Wert": 3.37, + "Notiz": "National Grid", + "ISIN": "GB00BDR05C01", + "Steuern": 1.28, + } + ], + }, + { + "filename": "dividende_wahlweise_no_eventType.json", + "event_type": PPEventType.DIVIDEND, + "title": "National Grid", + "isin": "GB00BDR05C01", + "value": 3.37, + "taxes": 1.28, + "transactions": [ + { + "Datum": "2024-07-19T13:28:04", + "Typ": "Dividende", + "Wert": 3.37, + "Notiz": "National Grid", + "ISIN": "GB00BDR05C01", + "Steuern": 1.28, + } + ], + }, + { + "filename": "dividende_wahlweise2.json", + "event_type": None, + }, + { + "filename": "dividende_wahlweise3.json", + "event_type": None, + }, + { + "filename": "incoming_transfer.json", + "event_type": PPEventType.DEPOSIT, + "title": "Klaus Mustermann", + "value": 88.04, + "transactions": [ + { + "Datum": "2024-09-02T17:49:12", + "Typ": "Einlage", + "Wert": 88.04, + "Notiz": "Klaus Mustermann", + } + ], + }, + { + "filename": "incoming_transfer_no_eventType.json", + "event_type": PPEventType.DEPOSIT, + "title": "Klaus Mustermann", + "value": 88.04, + "transactions": [ + { + "Datum": "2024-09-02T17:49:12", + "Typ": "Einlage", + "Wert": 88.04, + "Notiz": "Klaus Mustermann", + } + ], + }, + { + "filename": "incoming_transfer_delegation.json", + "event_type": PPEventType.DEPOSIT, + "title": "Vorname Nachname", + "value": 3000.0, + "transactions": [ + { + "Datum": "2024-09-10T13:18:31", + "Typ": "Einlage", + "Wert": 3000.0, + "Notiz": "Vorname Nachname", + } + ], + }, + { + "filename": "incoming_transfer_delegation_no_eventType.json", + "event_type": PPEventType.DEPOSIT, + "title": "Vorname Nachname", + "value": 3000.0, + "transactions": [ + { + "Datum": "2024-09-10T13:18:31", + "Typ": "Einlage", + "Wert": 3000.0, + "Notiz": "Vorname Nachname", + } + ], + }, + { + "filename": "ipo-spacex.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "SpaceX", + "isin": "US84615Q1031", + "shares": 0.276891, + "value": -33.33, + "fees": 1.0, + "transactions": [ + { + "Datum": "2026-06-06T04:20:02", + "Typ": "Kauf", + "Wert": -33.33, + "Notiz": "SpaceX", + "ISIN": "US84615Q1031", + "Stück": 0.276891, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "junior_p2p_transfer.json", + "event_type": PPEventType.REMOVAL, + "title": "Maria Mueller", + "value": -50, + "transactions": [ + { + "Datum": "2025-09-17T19:35:32", + "Typ": "Entnahme", + "Wert": -50.0, + "Notiz": "Maria Mueller", + } + ], + }, + { + "filename": "junior_p2p_transfer_no_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "Maria Mueller", + "value": -50, + "transactions": [ + { + "Datum": "2025-09-17T19:35:32", + "Typ": "Entnahme", + "Wert": -50.0, + "Notiz": "Maria Mueller", + } + ], + }, + { + "filename": "kartenzahlung.json", + "event_type": PPEventType.REMOVAL, + "title": "Coop Pronto", + "value": -12.16, + "note": "card_successful_transaction", + "transactions": [ + { + "Datum": "2025-10-21T17:30:01", + "Typ": "Entnahme", + "Wert": -12.16, + "Notiz": "Kartentransaktion - Coop Pronto", + } + ], + }, + { + "filename": "kartenzahlung_null_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "Coop Pronto", + "value": -12.16, + "note": "card_successful_transaction", + "transactions": [ + { + "Datum": "2025-10-21T17:30:01", + "Typ": "Entnahme", + "Wert": -12.16, + "Notiz": "Kartentransaktion - Coop Pronto", + } + ], + }, + { + "filename": "kartenzahlung_no_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "Baecker", + "value": -2, + "note": "card_successful_transaction", + "transactions": [ + { + "Datum": "2025-11-05T11:00:07", + "Typ": "Entnahme", + "Wert": -2.0, + "Notiz": "Kartentransaktion - Baecker", + } + ], + }, + { + "filename": "kauforder_abgelehnt.json", + "event_type": None, + }, + { + "filename": "legacy_verkauforder_neu_abgerechnet.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Marie Brizard Wine and Spirits", + "isin": "FR0000060873", + "shares": 27, + "value": 91.34, + "fees": 1, + "transactions": [ + { + "Datum": "2025-02-21T11:14:54", + "Typ": "Verkauf", + "Wert": 91.34, + "Notiz": "Marie Brizard Wine and Spirits", + "ISIN": "FR0000060873", + "Stück": 27.0, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "legacy_verkauforder_neu_abgerechnet_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Marie Brizard Wine and Spirits", + "isin": "FR0000060873", + "shares": 27, + "value": 91.34, + "fees": 1, + "transactions": [ + { + "Datum": "2025-02-21T11:14:54", + "Typ": "Verkauf", + "Wert": 91.34, + "Notiz": "Marie Brizard Wine and Spirits", + "ISIN": "FR0000060873", + "Stück": 27.0, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "legacy_zinsen.json", + "event_type": PPEventType.INTEREST, + "title": "Zinsen", + "value": 11.76, + "taxes": 4.51, + "transactions": [ + { + "Datum": "2024-09-01T16:39:48", + "Typ": "Zinsen", + "Wert": 11.76, + "Notiz": "Zinsen", + "Steuern": 4.51, + } + ], + }, + { + "filename": "legacy_zinsen_no_eventType.json", + "event_type": PPEventType.INTEREST, + "title": "Zinsen", + "value": 11.76, + "taxes": 4.51, + "transactions": [ + { + "Datum": "2024-09-01T16:39:48", + "Typ": "Zinsen", + "Wert": 11.76, + "Notiz": "Zinsen", + "Steuern": 4.51, + } + ], + }, + { + "filename": "limit-sell-order.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "D-Wave Quantum", + "isin": "US26740W1099", + "shares": 11, + "value": 114.91, + "fees": 1, + "taxes": 17.36, + "transactions": [ + { + "Datum": "2025-05-20T08:03:45", + "Typ": "Verkauf", + "Wert": 114.91, + "Notiz": "D-Wave Quantum", + "ISIN": "US26740W1099", + "Stück": 11.0, + "Gebühren": 1.0, + "Steuern": 17.36, + } + ], + }, + { + "filename": "limit-sell-order_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Teva Pharmaceutical Industries (ADR)", + "isin": "US8816242098", + "shares": 8, + "value": 139.74, + "fees": 1, + "taxes": 7.66, + "transactions": [ + { + "Datum": "2025-11-05T12:03:19", + "Typ": "Verkauf", + "Wert": 139.74, + "Notiz": "Teva Pharmaceutical Industries (ADR)", + "ISIN": "US8816242098", + "Stück": 8.0, + "Gebühren": 1.0, + "Steuern": 7.66, + } + ], + }, + { + "filename": "limit-sell-order_old.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Daimler Truck Holding", + "isin": "DE000DTR0CK8", + "shares": 3, + "value": 119.37, + "fees": 1, + "taxes": 0.14, + "transactions": [ + { + "Datum": "2025-05-14T07:01:32", + "Typ": "Verkauf", + "Wert": 119.37, + "Notiz": "Daimler Truck Holding", + "ISIN": "DE000DTR0CK8", + "Stück": 3.0, + "Gebühren": 1.0, + "Steuern": 0.14, + } + ], + }, + { + "filename": "limit-sell-order_old_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Daimler Truck Holding", + "isin": "DE000DTR0CK8", + "shares": 3, + "value": 119.37, + "fees": 1, + "taxes": 0.14, + "transactions": [ + { + "Datum": "2025-05-14T07:01:32", + "Typ": "Verkauf", + "Wert": 119.37, + "Notiz": "Daimler Truck Holding", + "ISIN": "DE000DTR0CK8", + "Stück": 3.0, + "Gebühren": 1.0, + "Steuern": 0.14, + } + ], + }, + { + "filename": "neues_geraet.json", + "event_type": None, + }, + { + "filename": "outgoing_transfer.json", + "event_type": PPEventType.REMOVAL, + "title": "Hans Mustermann", + "value": -50.3, + "transactions": [ + { + "Datum": "2024-07-21T09:35:47", + "Typ": "Entnahme", + "Wert": -50.3, + "Notiz": "Hans Mustermann", + } + ], + }, + { + "filename": "outgoing_transfer_no_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "Hans Mustermann", + "value": -50.3, + "transactions": [ + { + "Datum": "2024-07-21T09:35:47", + "Typ": "Entnahme", + "Wert": -50.3, + "Notiz": "Hans Mustermann", + } + ], + }, + { + "filename": "outgoing_transfer_delegation.json", + "event_type": PPEventType.REMOVAL, + "title": "Nina", + "value": -67, + "transactions": [ + { + "Datum": "2025-08-18T12:16:06", + "Typ": "Entnahme", + "Wert": -67.0, + "Notiz": "Nina", + } + ], + }, + { + "filename": "outgoing_transfer_delegation_no_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "Nina", + "value": -67, + "transactions": [ + { + "Datum": "2025-08-18T12:16:06", + "Typ": "Entnahme", + "Wert": -67.0, + "Notiz": "Nina", + } + ], + }, + { + "filename": "outgoing_transfer_legacy.json", + "event_type": PPEventType.REMOVAL, + "title": "My Name", + "value": -750, + "transactions": [ + { + "Datum": "2025-04-11T06:44:43", + "Typ": "Entnahme", + "Wert": -750.0, + "Notiz": "My Name", + } + ], + }, + { + "filename": "outgoing_transfer_legacy_no_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "My Name", + "value": -750, + "transactions": [ + { + "Datum": "2025-04-11T06:44:43", + "Typ": "Entnahme", + "Wert": -750.0, + "Notiz": "My Name", + } + ], + }, + { + "filename": "transfer_out.json", + "event_type": PPEventType.TRANSFER_OUT, + "title": "Novo-Nordisk (B)", + "isin": "DK0062498333", + "shares": 42.0, + "value": 0, + "transactions": [ + { + "Datum": "2025-09-18T17:03:45", + "Typ": "Umbuchung (Ausgang)", + "Wert": 0, + "Notiz": "Novo-Nordisk (B)", + "ISIN": "DK0062498333", + "Stück": 42.0, + } + ], + }, + { + "filename": "transfer_in.json", + "event_type": PPEventType.TRANSFER_IN, + "title": "British American Tobacco", + "isin": "GB0002875804", + "shares": 1.0, + "value": 0, + "transactions": [ + { + "Datum": "2024-06-14T16:40:07", + "Typ": "Umbuchung (Eingang)", + "Wert": 0, + "Notiz": "British American Tobacco", + "ISIN": "GB0002875804", + "Stück": 1.0, + } + ], + }, + { + "filename": "wertpapiertransfer_in.json", + "event_type": PPEventType.TRANSFER_IN, + "title": "Metro", + "isin": "DE000BFB0019", + "shares": 76.0, + "value": 0, + "transactions": [ + { + "Datum": "2023-06-13T20:38:45", + "Typ": "Umbuchung (Eingang)", + "Wert": 0, + "Notiz": "Metro", + "ISIN": "DE000BFB0019", + "Stück": 76.0, + } + ], + }, + { + "filename": "wertpapiertransfer_out.json", + "event_type": PPEventType.TRANSFER_OUT, + "title": "Netflix", + "isin": "US64110L1061", + "shares": 4.0, + "value": 0, + "transactions": [ + { + "Datum": "2024-03-15T14:22:33", + "Typ": "Umbuchung (Ausgang)", + "Wert": 0, + "Notiz": "Netflix", + "ISIN": "US64110L1061", + "Stück": 4.0, + } + ], + }, + { + "filename": "wertpapiertransfer_in_legacy.json", + "event_type": PPEventType.TRANSFER_IN, + "title": "Metro", + "isin": "DE000BFB0019", + "shares": 76.0, + "value": 0, + "transactions": [ + { + "Datum": "2022-04-10T10:15:30", + "Typ": "Umbuchung (Eingang)", + "Wert": 0, + "Notiz": "Metro", + "ISIN": "DE000BFB0019", + "Stück": 76.0, + } + ], + }, + { + "filename": "wertpapiertransfer_out_legacy.json", + "event_type": PPEventType.TRANSFER_OUT, + "title": "Netflix", + "isin": "US64110L1061", + "shares": 4.0, + "value": 0, + "transactions": [ + { + "Datum": "2022-05-20T16:45:00", + "Typ": "Umbuchung (Ausgang)", + "Wert": 0, + "Notiz": "Netflix", + "ISIN": "US64110L1061", + "Stück": 4.0, + } + ], + }, + { + "filename": "transfer_out_cancelled.json", + "event_type": None, + "title": "MSCI World USD (Dist)", + "isin": None, + "shares": None, + "value": None, + "transactions": [], + }, + { + "filename": "payment_inbound_credit_card.json", + "event_type": PPEventType.DEPOSIT, + "title": "Einzahlung", + "value": 1000, + "fees": 7, + "transactions": [ + { + "Datum": "2022-08-27T05:06:30", + "Typ": "Einlage", + "Wert": 1000.0, + "Notiz": "Einzahlung", + "Gebühren": 7.0, + } + ], + }, + { + "filename": "payment_inbound_credit_card_no_eventType.json", + "event_type": PPEventType.DEPOSIT, + "title": "Einzahlung", + "value": 1000, + "fees": 7, + "transactions": [ + { + "Datum": "2022-08-27T05:06:30", + "Typ": "Einlage", + "Wert": 1000.0, + "Notiz": "Einzahlung", + "Gebühren": 7.0, + } + ], + }, + { + "filename": "private_markets_order.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3176111881", + "shares": 1, + "value": -101, + "fees": 1, + "note": "EQT", + "transactions": [ + { + "Datum": "2025-09-18T07:15:25", + "Typ": "Kauf", + "Wert": -101.0, + "Notiz": "EQT - Private Equity", + "ISIN": "LU3176111881", + "Stück": 1.0, + "Gebühren": 1.0, + }, + ], + }, + { + "filename": "private_markets_order_no_eventType.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3176111881", + "shares": 1, + "value": -101, + "fees": 1, + "note": "EQT", + "transactions": [ + { + "Datum": "2025-09-18T07:15:25", + "Typ": "Kauf", + "Wert": -101.0, + "Notiz": "EQT - Private Equity", + "ISIN": "LU3176111881", + "Stück": 1.0, + "Gebühren": 1.0, + }, + ], + }, + { + "filename": "private_markets_order_bonus.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3176111881", + "shares": 0.01, + "value": -1, + "note": "1 % Bonus", + "transactions": [ + { + "Datum": "2025-09-18T07:15:25", + "Typ": "Kauf", + "Wert": -1.0, + "Notiz": "1 % Bonus - Private Equity", + "ISIN": "LU3176111881", + "Stück": 0.01, + }, + { + "Datum": "2025-09-18T07:15:25", + "Typ": "Einlage", + "Wert": 1.0, + "Notiz": "1 % Bonus - Private Equity", + }, + ], + }, + { + "filename": "private_markets_order_bonus_no_eventType.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3176111881", + "shares": 0.01, + "value": -1, + "note": "1 % Bonus", + "transactions": [ + { + "Datum": "2025-09-18T07:15:25", + "Typ": "Kauf", + "Wert": -1.0, + "Notiz": "1 % Bonus - Private Equity", + "ISIN": "LU3176111881", + "Stück": 0.01, + }, + { + "Datum": "2025-09-18T07:15:25", + "Typ": "Einlage", + "Wert": 1.0, + "Notiz": "1 % Bonus - Private Equity", + }, + ], + }, + { + "filename": "private_markets_trade.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3170240538", + "shares": 1, + "value": -101, + "fees": 1, + "note": "Apollo", + "transactions": [ + { + "Datum": "2025-09-18T07:14:56", + "Typ": "Kauf", + "Wert": -101.0, + "Notiz": "Apollo - Private Equity", + "ISIN": "LU3170240538", + "Stück": 1.0, + "Gebühren": 1.0, + }, + ], + }, + { + "filename": "private_markets_trade_no_eventType.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3170240538", + "shares": 1, + "value": -101, + "fees": 1, + "note": "Apollo", + "transactions": [ + { + "Datum": "2025-09-18T07:14:56", + "Typ": "Kauf", + "Wert": -101.0, + "Notiz": "Apollo - Private Equity", + "ISIN": "LU3170240538", + "Stück": 1.0, + "Gebühren": 1.0, + }, + ], + }, + { + "filename": "private_markets_trade_bonus.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "isin": "LU3170240538", + "title": "Private Equity", + "shares": 0.01, + "value": -1, + "note": "1 % Bonus", + "transactions": [ + { + "Datum": "2025-09-18T07:14:56", + "Typ": "Kauf", + "Wert": -1, + "Notiz": "1 % Bonus - Private Equity", + "ISIN": "LU3170240538", + "Stück": 0.01, + }, + { + "Datum": "2025-09-18T07:14:56", + "Typ": "Einlage", + "Wert": 1, + "Notiz": "1 % Bonus - Private Equity", + }, + ], + }, + { + "filename": "private_markets_trade_bonus_no_eventType.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "isin": "LU3170240538", + "title": "Private Equity", + "shares": 0.01, + "value": -1, + "note": "1 % Bonus", + "transactions": [ + { + "Datum": "2025-09-18T07:14:56", + "Typ": "Kauf", + "Wert": -1, + "Notiz": "1 % Bonus - Private Equity", + "ISIN": "LU3170240538", + "Stück": 0.01, + }, + { + "Datum": "2025-09-18T07:14:56", + "Typ": "Einlage", + "Wert": 1, + "Notiz": "1 % Bonus - Private Equity", + }, + ], + }, + { + "filename": "private_markets_verkaufsorder_erstellt.json", + }, + { + "filename": "private_markets_verkaufsorder.json", + "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, + "title": "Private Equity", + "isin": "LU3176111881", + "shares": 1.01, + "value": 103.54, + "fees": 1, + "taxes": 1.24, + "note": "EQT", + "transactions": [ + { + "Datum": "2026-06-08T14:15:00", + "Typ": "Verkauf", + "Wert": 103.54, + "Notiz": "EQT - Private Equity", + "ISIN": "LU3176111881", + "Stück": 1.01, + "Gebühren": 1.0, + "Steuern": 1.24, + }, + ], + }, + { + "filename": "private_markets_vorabpauschale.json", + "event_type": PPEventType.TAXES, + "title": "Private Equity", + "isin": "LU3176111881", + "value": -0.07, + "taxes": 0.07, + "note": "EQT", + "transactions": [ + { + "Datum": "2026-03-09T07:56:12", + "Typ": "Steuern", + "Wert": -0.07, + "Notiz": "EQT - Private Equity", + "ISIN": "LU3176111881", + "Steuern": 0.07, + } + ], + }, + { + "filename": "reverse_split.json", + "event_type": PPEventType.SWAP, + "title": "Globalstar", + "isin": "US3789734080", + "isin2": "US3789735079", + "shares": 110.403067, + "shares2": 7.360204, + "value": 0, + "note": "GLOBALSTAR INC. O.N.", + "transactions": [ + { + "Datum": "2025-02-11T08:13:48", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Globalstar", + "ISIN": "US3789734080", + "Stück": 110.403067, + "ISIN2": "US3789735079", + "Stück2": 7.360204, + }, + ], + }, + { + "filename": "reverse_split_no_eventType.json", + "event_type": PPEventType.SWAP, + "title": "Globalstar", + "isin": "US3789734080", + "isin2": "US3789735079", + "shares": 110.403067, + "shares2": 7.360204, + "value": 0, + "note": "GLOBALSTAR INC. O.N.", + "transactions": [ + { + "Datum": "2025-02-11T08:13:48", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Globalstar", + "ISIN": "US3789734080", + "Stück": 110.403067, + "ISIN2": "US3789735079", + "Stück2": 7.360204, + }, + ], + }, + { + "filename": "reverse_split_old_isin.json", + "event_type": PPEventType.SWAP, + "title": "Honeywell International", + "isin": "US4385161066", + "isin2": "US4385162056", + "shares": 0.966682, + "shares2": 0.483341, + "value": 0, + "note": "Honeywell International", + "transactions": [ + { + "Datum": "2026-06-30T16:46:52", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Honeywell International", + "ISIN": "US4385161066", + "Stück": 0.966682, + "ISIN2": "US4385162056", + "Stück2": 0.483341, + }, + ], + }, + { + "filename": "reverse_split_new_isin.json", + "event_type": None, # new-ISIN side of a paired swap — suppressed in favour of reverse_split_old_isin.json + }, + { + "filename": "tausch_old_isin.json", + "event_type": PPEventType.SWAP, + "title": "Fresenius", + "isin": "DE0005785604", + "isin2": "DE000FRE5EN2", + "shares": 5.431472, + "shares2": 5.431472, + "value": 0, + "note": "Fresenius SE & Co. KGaA Namens-Aktien o.N.", + "transactions": [ + { + "Datum": "2026-08-13T15:22:52", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Fresenius", + "ISIN": "DE0005785604", + "Stück": 5.431472, + "ISIN2": "DE000FRE5EN2", + "Stück2": 5.431472, + }, + ], + }, + { + "filename": "tausch_new_isin.json", + "event_type": None, # new-ISIN side of a paired swap — suppressed in favour of tausch_old_isin.json + }, + { + "filename": "saveback.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "S&P 500 Information Tech USD (Acc)", + "isin": "IE00B3WJKG14", + "shares": 0.546348, + "value": -15, + "transactions": [ + { + "Datum": "2025-04-02T13:54:23", + "Typ": "Kauf", + "Wert": -15.0, + "Notiz": "S&P 500 Information Tech USD (Acc)", + "ISIN": "IE00B3WJKG14", + "Stück": 0.546348, + }, + { + "Datum": "2025-04-02T13:54:23", + "Typ": "Einlage", + "Wert": 15.0, + "Notiz": "S&P 500 Information Tech USD (Acc)", + }, + ], + }, + { + "filename": "saveback_no_eventType.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "Lockheed Martin", + "isin": "US5398301094", + "shares": 0.035252, + "value": -15, + "transactions": [ + { + "Datum": "2025-11-03T15:30:22", + "Typ": "Kauf", + "Wert": -15.0, + "Notiz": "Lockheed Martin", + "ISIN": "US5398301094", + "Stück": 0.035252, + }, + { + "Datum": "2025-11-03T15:30:22", + "Typ": "Einlage", + "Wert": 15.0, + "Notiz": "Lockheed Martin", + }, + ], + }, + { + "filename": "savingsplan.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "DroneShield", + "isin": "AU000000DRO2", + "shares": 6.921675, + "value": -19, + "transactions": [ + { + "Datum": "2025-10-23T08:26:13", + "Typ": "Kauf", + "Wert": -19.0, + "Notiz": "DroneShield", + "ISIN": "AU000000DRO2", + "Stück": 6.921675, + } + ], + }, + { + "filename": "savingsplan_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "TSMC (ADR)", + "isin": "US8740391003", + "shares": 0.037523, + "value": -10, + "transactions": [ + { + "Datum": "2025-11-03T15:58:11", + "Typ": "Kauf", + "Wert": -10.0, + "Notiz": "TSMC (ADR)", + "ISIN": "US8740391003", + "Stück": 0.037523, + } + ], + }, + { + "filename": "securities_transfer_incoming.json", + "event_type": PPEventType.TRANSFER_IN, + "title": "MSCI EM USD (Acc)", + "isin": "IE00BTJRMP35", + "shares": 7, + "value": 0, + "transactions": [ + { + "Datum": "2025-10-13T12:43:03", + "Typ": "Umbuchung (Eingang)", + "Wert": 0, + "Notiz": "MSCI EM USD (Acc)", + "ISIN": "IE00BTJRMP35", + "Stück": 7.0, + } + ], + }, + { + "filename": "securities_transfer_incoming_no_eventType.json", + "event_type": PPEventType.TRANSFER_IN, + "title": "MSCI EM USD (Acc)", + "isin": "IE00BTJRMP35", + "shares": 7, + "value": 0, + "transactions": [ + { + "Datum": "2025-10-13T12:43:03", + "Typ": "Umbuchung (Eingang)", + "Wert": 0, + "Notiz": "MSCI EM USD (Acc)", + "ISIN": "IE00BTJRMP35", + "Stück": 7.0, + } + ], + }, + { + "filename": "sell_stop.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "D-Wave Quantum", + "isin": "US26740W1099", + "shares": 17, + "value": 94.76, + "fees": 1, + "taxes": 3.18, + "transactions": [ + { + "Datum": "2025-03-14T07:03:14", + "Typ": "Verkauf", + "Wert": 94.76, + "Notiz": "D-Wave Quantum", + "ISIN": "US26740W1099", + "Gebühren": 1.0, + "Steuern": 3.18, + "Stück": 17.0, + } + ], + }, + { + "filename": "sell_stop_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "D-Wave Quantum", + "isin": "US26740W1099", + "shares": 17, + "value": 94.76, + "fees": 1, + "taxes": 3.18, + "transactions": [ + { + "Datum": "2025-03-14T07:03:14", + "Typ": "Verkauf", + "Wert": 94.76, + "Notiz": "D-Wave Quantum", + "ISIN": "US26740W1099", + "Gebühren": 1.0, + "Steuern": 3.18, + "Stück": 17.0, + } + ], + }, + { + "filename": "spinoff.json", + "event_type": PPEventType.SPINOFF, + "title": "ThyssenKrupp", + "isin": "DE000TKMS001", + "isin2": "DE0007500001", + "shares": 0.309986, + "value": 0, + "note": "TKMS", + "transactions": [ + { + "Datum": "2025-10-20T11:25:29", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "TKMS", + "ISIN": "DE000TKMS001", + "Stück": 0.309986, + "ISIN2": "DE0007500001", + } + ], + }, + { + "filename": "spinoff_no_eventType.json", + "event_type": PPEventType.SPINOFF, + "title": "ThyssenKrupp", + "isin": "DE000TKMS001", + "isin2": "DE0007500001", + "shares": 0.309986, + "value": 0, + "note": "TKMS", + "transactions": [ + { + "Datum": "2025-10-20T11:25:29", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "TKMS", + "ISIN": "DE000TKMS001", + "Stück": 0.309986, + "ISIN2": "DE0007500001", + } + ], + }, + { + "filename": "spinoff_only_taxes.json", + "event_type": PPEventType.TAXES, + "title": "Gamestop Corp. WTS 30.10.26", + "isin": "US36467W1172", + "value": -0.56, + "taxes": 0.56, + "transactions": [ + { + "Datum": "2025-12-19T15:24:37", + "Typ": "Steuern", + "Wert": -0.56, + "Notiz": "Gamestop Corp. WTS 30.10.26", + "ISIN": "US36467W1172", + "Steuern": 0.56, + } + ], + }, + { + "filename": "steuerkorrektur.json", + "event_type": PPEventType.TAX_REFUND, + "title": "Steuerkorrektur", + "value": 2.87, + "transactions": [ + { + "Datum": "2025-10-28T00:00:16", + "Typ": "Steuerrückerstattung", + "Wert": 2.87, + "Notiz": "Steuerkorrektur", + } + ], + }, + { + "filename": "steuerkorrektur_no_eventType.json", + "event_type": PPEventType.TAX_REFUND, + "title": "Steuerkorrektur", + "value": 0.76, + "transactions": [ + { + "Datum": "2025-11-04T23:31:58", + "Typ": "Steuerrückerstattung", + "Wert": 0.76, + "Notiz": "Steuerkorrektur", + } + ], + }, + { + "filename": "tausch_informative_no_eventType.json", + "event_type": None, + }, + { + "filename": "tausch_informative.json", + "event_type": None, + }, + { + "filename": "teilrueckzahlung.json", + "event_type": PPEventType.SWAP, + "title": "ORSTED A/S EM.09/25 DK 10", + "isin": "DK0064307755", + "isin2": "DK0060094928", + "shares": 17, + "shares2": 17, + "value": 0, + "note": "Orsted", + "transactions": [ + { + "Datum": "2025-10-23T14:46:49", + "Typ": "Swap", + "Wert": 0, + "Notiz": "ORSTED A/S EM.09/25 DK 10", + "ISIN": "DK0064307755", + "Stück": 17.0, + "ISIN2": "DK0060094928", + "Stück2": 17.0, + }, + ], + }, + { + "filename": "teilrueckzahlung_no_eventType.json", + "event_type": PPEventType.SWAP, + "title": "ORSTED A/S EM.09/25 DK 10", + "isin": "DK0064307755", + "isin2": "DK0060094928", + "shares": 17, + "shares2": 17, + "value": 0, + "note": "Orsted", + "transactions": [ + { + "Datum": "2025-10-23T14:46:49", + "Typ": "Swap", + "Wert": 0, + "Notiz": "ORSTED A/S EM.09/25 DK 10", + "ISIN": "DK0064307755", + "Stück": 17.0, + "ISIN2": "DK0060094928", + "Stück2": 17.0, + }, + ], + }, + { + "filename": "tilgung.json", + "event_type": PPEventType.DIVIDEND, + "title": "Long 1,2345 $", + "isin": "DE000SX12345", + "shares": 100, + "value": 0.1, + "transactions": [ + { + "Datum": "2025-01-10T10:00:00", + "Typ": "Dividende", + "Wert": 0.1, + "Notiz": "Long 1,2345 $", + "ISIN": "DE000SX12345", + "Stück": 100.0, + } + ], + }, + { + "filename": "tilgung_no_eventType.json", + "event_type": PPEventType.DIVIDEND, + "title": "Long 1,2345 $", + "isin": "DE000SX12345", + "shares": 100, + "value": 0.1, + "transactions": [ + { + "Datum": "2025-01-10T10:00:00", + "Typ": "Dividende", + "Wert": 0.1, + "Notiz": "Long 1,2345 $", + "ISIN": "DE000SX12345", + "Stück": 100.0, + } + ], + }, + { + "filename": "trade_perk.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "Aktien-Bonus", + "isin": "US0378331005", + "shares": 0.0487, + "value": -10.03, + "transactions": [ + { + "Datum": "2025-04-01T14:09:45", + "Typ": "Kauf", + "Wert": -10.03, + "Notiz": "Aktien-Bonus", + "ISIN": "US0378331005", + "Stück": 0.0487, + }, + { + "Datum": "2025-04-01T14:09:45", + "Typ": "Einlage", + "Wert": 10.03, + "Notiz": "Aktien-Bonus", + }, + ], + }, + { + "filename": "trade_perk_no_eventType.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "Aktien-Bonus", + "isin": "US0378331005", + "shares": 0.0487, + "value": -10.03, + "transactions": [ + { + "Datum": "2025-04-01T14:09:45", + "Typ": "Kauf", + "Wert": -10.03, + "Notiz": "Aktien-Bonus", + "ISIN": "US0378331005", + "Stück": 0.0487, + }, + { + "Datum": "2025-04-01T14:09:45", + "Typ": "Einlage", + "Wert": 10.03, + "Notiz": "Aktien-Bonus", + }, + ], + }, + { + "filename": "verkaufsorder.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Tencent Holdings (ADR)", + "isin": "US88032Q1094", + "shares": 3.454506, + "value": 200.93, + "fees": 1, + "taxes": 0.16, + "transactions": [ + { + "Datum": "2025-05-12T18:38:36", + "Typ": "Verkauf", + "Wert": 200.93, + "Notiz": "Tencent Holdings (ADR)", + "ISIN": "US88032Q1094", + "Stück": 3.454506, + "Gebühren": 1.0, + "Steuern": 0.16, + } + ], + }, + { + "filename": "verkaufsorder_no_eventType.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Home Depot", + "isin": "US4370761029", + "shares": 0.305182, + "value": 100, + "fees": 1, + "transactions": [ + { + "Datum": "2025-11-04T16:27:25", + "Typ": "Verkauf", + "Wert": 100.0, + "Notiz": "Home Depot", + "ISIN": "US4370761029", + "Stück": 0.305182, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "verkaufsorder_abrechnung12.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Zalando", + "isin": "DE000ZAL1111", + "shares": 4.795804, + "value": 93.07, + "fees": 1.0, + "transactions": [ + { + "Datum": "2026-05-18T15:37:40", + "Typ": "Verkauf", + "Wert": 93.07, + "Notiz": "Zalando", + "ISIN": "DE000ZAL1111", + "Stück": 4.795804, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "vorabpauschale.json", + "event_type": PPEventType.TAXES, + "title": "MSCI China USD (Acc)", + "isin": "IE00BJ5JPG56", + "value": -0.19, + "taxes": 0.19, + "transactions": [ + { + "Datum": "2025-01-28T14:54:28", + "Typ": "Steuern", + "Wert": -0.19, + "Notiz": "MSCI China USD (Acc)", + "ISIN": "IE00BJ5JPG56", + "Steuern": 0.19, + } + ], + }, + { + "filename": "vorabpauschale_no_eventType.json", + "event_type": PPEventType.TAXES, + "title": "MSCI China USD (Acc)", + "isin": "IE00BJ5JPG56", + "value": -0.19, + "taxes": 0.19, + "transactions": [ + { + "Datum": "2025-01-28T14:54:28", + "Typ": "Steuern", + "Wert": -0.19, + "Notiz": "MSCI China USD (Acc)", + "ISIN": "IE00BJ5JPG56", + "Steuern": 0.19, + } + ], + }, + { + "filename": "zinsen.json", + "event_type": PPEventType.INTEREST, + "title": "Zinsen", + "value": 4.87, + "taxes": 1.87, + "transactions": [ + { + "Datum": "2025-07-01T06:46:37", + "Typ": "Zinsen", + "Wert": 4.87, + "Notiz": "Zinsen", + "Steuern": 1.87, + } + ], + }, + { + "filename": "zinsen_no_eventType.json", + "event_type": PPEventType.INTEREST, + "title": "Zinsen", + "value": 4.87, + "taxes": 1.87, + "transactions": [ + { + "Datum": "2025-07-01T06:46:37", + "Typ": "Zinsen", + "Wert": 4.87, + "Notiz": "Zinsen", + "Steuern": 1.87, + } + ], + }, + { + "filename": "zinsen2.json", + "event_type": PPEventType.INTEREST, + "title": "Zinsen", + "value": 6.41, + "taxes": 2.45, + "transactions": [ + { + "Datum": "2026-08-01T03:26:43", + "Typ": "Zinsen", + "Wert": 6.41, + "Notiz": "Zinsen", + "Steuern": 2.45, + } + ], + }, + { + "filename": "zusammenschluss.json", + "event_type": PPEventType.SWAP, + "title": "Rocket Lab USA", + "isin": "US7731221062", + "isin2": "US7731211089", + "shares": 5.943100, + "shares2": 5.943100, + "value": 0, + "note": "ROCKET LAB CORP. O.N.", + "transactions": [ + { + "Datum": "2025-05-29T13:04:58", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Rocket Lab USA", + "ISIN": "US7731221062", + "Stück": 5.9431, + "ISIN2": "US7731211089", + "Stück2": 5.9431, + }, + ], + }, + { + "filename": "zusammenschluss_no_eventType.json", + "event_type": PPEventType.SWAP, + "title": "Rocket Lab USA", + "isin": "US7731221062", + "isin2": "US7731211089", + "shares": 5.943100, + "shares2": 5.943100, + "value": 0, + "note": "ROCKET LAB CORP. O.N.", + "transactions": [ + { + "Datum": "2025-05-29T13:04:58", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Rocket Lab USA", + "ISIN": "US7731221062", + "Stück": 5.9431, + "ISIN2": "US7731211089", + "Stück2": 5.9431, + }, + ], + }, + { + "filename": "zusammenschluss2.json", + "event_type": PPEventType.SWAP, + "title": "Rocket Lab USA", + "isin": "US7731221062", + "isin2": "US7731211089", + "shares": 5.943100, + "shares2": 5.943100, + "value": 0, + "note": "ROCKET LAB CORP. O.N.", + "transactions": [ + { + "Datum": "2025-05-29T13:04:58", + "Typ": "Swap", + "Wert": 0, + "Notiz": "Rocket Lab USA", + "ISIN": "US7731221062", + "Stück": 5.9431, + "ISIN2": "US7731211089", + "Stück2": 5.9431, + }, + ], + }, + { + "filename": "zwischenpapiere.json", + "event_type": PPEventType.SWAP, + "title": "ORSTED A/S -ANR-", + "isin": "DK0064307839", + "isin2": "DK0064307755", + "shares": 119, + "shares2": 17, + "value": -151.59, + "note": "ORSTED A/S EM.09/25 DK 10", + "transactions": [ + { + "Datum": "2025-10-21T07:39:39", + "Typ": "Swap", + "Wert": -151.59, + "ISIN": "DK0064307839", + "Notiz": "ORSTED A/S -ANR-", + "Stück": 119.0, + "ISIN2": "DK0064307755", + "Stück2": 17.0, + }, + ], + }, + { + "filename": "zwischenpapiere2.json", + "event_type": PPEventType.SWAP, + "title": "WORLDLINE S.A. ANR", + "isin": "FR0014015MS9", + "isin2": "FR0011981968", + "shares": 1, + "shares2": 6, + "value": -1.21, + "note": "Worldline", + "transactions": [ + { + "Datum": "2026-04-03T09:37:06", + "Typ": "Swap", + "Wert": -1.21, + "ISIN": "FR0014015MS9", + "Notiz": "WORLDLINE S.A. ANR", + "Stück": 1.0, + "ISIN2": "FR0011981968", + "Stück2": 6.0, + }, + ], + }, + { + "filename": "zwischenpapiere3.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Worldline", + "isin": "FR0011981968", + "shares": 1294, + "value": -261.39, + "transactions": [ + { + "Datum": "2026-04-03T10:38:58", + "Typ": "Kauf", + "Wert": -261.39, + "ISIN": "FR0011981968", + "Notiz": "Worldline", + "Stück": 1294.0, + }, + ], + }, + { + "filename": "zwischenpapiere_no_eventType.json", + "event_type": PPEventType.SWAP, + "title": "ORSTED A/S -ANR-", + "isin": "DK0064307839", + "isin2": "DK0064307755", + "shares": 119, + "shares2": 17, + "value": -151.59, + "note": "ORSTED A/S EM.09/25 DK 10", + "transactions": [ + { + "Datum": "2025-10-21T07:39:39", + "Typ": "Swap", + "Wert": -151.59, + "ISIN": "DK0064307839", + "Notiz": "ORSTED A/S -ANR-", + "Stück": 119.0, + "ISIN2": "DK0064307755", + "Stück2": 17.0, + }, + ], + }, + { + "filename": "zwischenvertrieb.json", + "event_type": PPEventType.SPINOFF, + "title": "Orsted", + "isin": "DK0064307839", + "isin2": "DK0060094928", + "shares": 119.285835, + "value": 0, + "note": "ORSTED A/S -ANR-", + "transactions": [ + { + "Datum": "2025-09-19T12:02:49", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "ORSTED A/S -ANR-", + "ISIN": "DK0064307839", + "Stück": 119.285835, + "ISIN2": "DK0060094928", + } + ], + }, + { + "filename": "zwischenvertrieb_no_eventType.json", + "event_type": PPEventType.SPINOFF, + "title": "Orsted", + "isin": "DK0064307839", + "isin2": "DK0060094928", + "shares": 119.285835, + "value": 0, + "note": "ORSTED A/S -ANR-", + "transactions": [ + { + "Datum": "2025-09-19T12:02:49", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "ORSTED A/S -ANR-", + "ISIN": "DK0064307839", + "Stück": 119.285835, + "ISIN2": "DK0060094928", + } + ], + }, + { + "filename": "zwischenvertrieb2.json", + "event_type": PPEventType.SPINOFF, + "title": "Worldline", + "isin": "FR0014015MS9", + "isin2": "FR0011981968", + "shares": 1.299376, + "value": 0, + "note": "Worldline", + "transactions": [ + { + "Datum": "2026-03-17T10:45:33", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "Worldline", + "ISIN": "FR0014015MS9", + "Stück": 1.299376, + "ISIN2": "FR0011981968", + } + ], + }, + { + "filename": "zwischenvertrieb3.json", + "event_type": PPEventType.SPINOFF, + "title": "OHB", + "isin": "DE000A41YFG5", + "isin2": "DE0005936124", + "shares": 1.026415, + "value": 0, + "note": "OHB", + "transactions": [ + { + "Datum": "2026-06-29T09:09:14", + "Typ": "Spinoff", + "Wert": 0, + "Notiz": "OHB", + "ISIN": "DE000A41YFG5", + "Stück": 1.026415, + "ISIN2": "DE0005936124", + } + ], + }, + { + "filename": "bank_transaction_incoming.json", + "event_type": PPEventType.DEPOSIT, + "title": "Max Mustermann", + "value": 5.15, + "transactions": [ + { + "Datum": "2024-07-04T06:17:41", + "Typ": "Einlage", + "Wert": 5.15, + "Notiz": "Max Mustermann", + } + ], + }, + { + "filename": "bank_transaction_outgoing.json", + "event_type": PPEventType.REMOVAL, + "title": "Max Mustermann", + "value": -50.3, + "transactions": [ + { + "Datum": "2024-07-21T09:35:47", + "Typ": "Entnahme", + "Wert": -50.3, + "Notiz": "Max Mustermann", + } + ], + }, + { + "filename": "card_transaction.json", + "event_type": PPEventType.REMOVAL, + "title": "REWE", + "value": -4.28, + "note": "card_successful_transaction", + "transactions": [ + { + "Datum": "2024-06-03T15:10:48", + "Typ": "Entnahme", + "Wert": -4.28, + "Notiz": "Kartentransaktion - REWE", + } + ], + }, + { + "filename": "card_purchase_no_eventType.json", + "event_type": PPEventType.REMOVAL, + "title": "Trade Republic Card", + "value": -5.0, + "transactions": [ + { + "Datum": "2024-11-22T09:09:09", + "Typ": "Entnahme", + "Wert": -5.0, + "Notiz": "Trade Republic Card", + } + ], + }, + { + "filename": "interest_payout_created.json", + "event_type": PPEventType.INTEREST, + "title": "Zinsen", + "value": 13.56, + "taxes": 5.21, + "transactions": [ + { + "Datum": "2024-07-01T04:51:32", + "Typ": "Zinsen", + "Wert": 13.56, + "Notiz": "Zinsen", + "Steuern": 5.21, + } + ], + }, + { + "filename": "saveback_aggregate.json", + "event_type": ConditionalEventType.SAVEBACK, + "title": "S&P 500 Information Tech USD (Acc)", + "isin": "IE00B3WJKG14", + "value": -15.0, + "shares": 0.501924, + "transactions": [ + { + "Datum": "2024-07-02T13:53:44", + "Typ": "Kauf", + "Wert": -15.0, + "Notiz": "S&P 500 Information Tech USD (Acc)", + "ISIN": "IE00B3WJKG14", + "Stück": 0.501924, + }, + { + "Datum": "2024-07-02T13:53:44", + "Typ": "Einlage", + "Wert": 15.0, + "Notiz": "S&P 500 Information Tech USD (Acc)", + }, + ], + }, + { + "filename": "savings_plan_invoice_created.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Volkswagen (Vz.)", + "isin": "DE0007664039", + "value": -1.0, + "shares": 0.00961, + "transactions": [ + { + "Datum": "2024-06-17T08:16:25", + "Typ": "Kauf", + "Wert": -1.0, + "Notiz": "Volkswagen (Vz.)", + "ISIN": "DE0007664039", + "Stück": 0.00961, + } + ], + }, + { + "filename": "spare_change_aggregate.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "S&P 500 Information Tech USD (Acc)", + "isin": "IE00B3WJKG14", + "value": -5.81, + "shares": 0.208318, + "transactions": [ + { + "Datum": "2024-06-10T13:52:18", + "Typ": "Kauf", + "Wert": -5.81, + "Notiz": "S&P 500 Information Tech USD (Acc)", + "ISIN": "IE00B3WJKG14", + "Stück": 0.208318, + } + ], + }, + { + "filename": "ssp_tax_correction.json", + "event_type": PPEventType.TAX_REFUND, + "title": "Steuerkorrektur", + "value": 3.47, + "transactions": [ + { + "Datum": "2024-06-11T22:45:15", + "Typ": "Steuerrückerstattung", + "Wert": 3.47, + "Notiz": "Steuerkorrektur", + } + ], + }, + { + "filename": "trade_corrected.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "Worldline", + "isin": "FR0011981968", + "value": 105.85, + "shares": 13.0, + "fees": 1.0, + "taxes": 1.8, + "transactions": [ + { + "Datum": "2024-12-16T09:59:01", + "Typ": "Verkauf", + "Wert": 105.85, + "Notiz": "Worldline", + "ISIN": "FR0011981968", + "Stück": 13.0, + "Gebühren": 1.0, + "Steuern": 1.8, + } + ], + }, + { + "filename": "trade_invoice.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "DWS Group", + "isin": "DE000DWS1007", + "value": -221.0, + "shares": 5.0, + "fees": 1.0, + "transactions": [ + { + "Datum": "2024-06-04T06:23:45", + "Typ": "Kauf", + "Wert": -221.0, + "Notiz": "DWS Group", + "ISIN": "DE000DWS1007", + "Stück": 5.0, + "Gebühren": 1.0, + } + ], + }, + { + "filename": "trading_savingsplan_executed.json", + "event_type": ConditionalEventType.TRADE_INVOICE, + "title": "BASF", + "isin": "DE000BASF111", + "value": -15.0, + "shares": 0.316355, + "transactions": [ + { + "Datum": "2025-02-10T09:23:13", + "Typ": "Kauf", + "Wert": -15.0, + "Notiz": "BASF", + "ISIN": "DE000BASF111", + "Stück": 0.316355, + } + ], + }, + { + "filename": "trading_savingsplan_execution_pending.json", + "event_type": None, + }, + { + "filename": "vorabpauschale_negative.json", + "event_type": PPEventType.TAXES, + "title": "S&P 400 US Mid Cap (Acc)", + "isin": "IE00B4YBJ215", + "value": -0.04, + "taxes": 0.04, + "transactions": [ + { + "Datum": "2025-01-28T14:30:05", + "Typ": "Steuern", + "Wert": -0.04, + "Notiz": "S&P 400 US Mid Cap (Acc)", + "ISIN": "IE00B4YBJ215", + "Steuern": 0.04, + } + ], + }, +] -def test_events(): - test_data = [ - { - "filename": "aktien_entfernt.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "ORSTED A/S -ANR-", - "isin": "DK0064307839", - "shares": 0.285835, - "value": 0, - "transactions": [ - { - "Datum": "2025-10-28T15:46:46", - "Typ": "Verkauf", - "Wert": 0, - "Notiz": "ORSTED A/S -ANR-", - "ISIN": "DK0064307839", - "Stück": 0.285835, - } - ], - }, - { - "filename": "aktien_entfernt_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "ORSTED A/S -ANR-", - "isin": "DK0064307839", - "shares": 0.285835, - "value": 0, - "transactions": [ - { - "Datum": "2025-10-28T15:46:46", - "Typ": "Verkauf", - "Wert": 0, - "Notiz": "ORSTED A/S -ANR-", - "ISIN": "DK0064307839", - "Stück": 0.285835, - } - ], - }, - { - "filename": "aktien_entfernt2.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "WORLDLINE S.A. ANR", - "isin": "FR0014015MS9", - "shares": 0.299376, - "value": 0, - "transactions": [ - { - "Datum": "2026-04-03T10:48:40", - "Typ": "Verkauf", - "Wert": 0, - "Notiz": "WORLDLINE S.A. ANR", - "ISIN": "FR0014015MS9", - "Stück": 0.299376, - } - ], - }, - { - "filename": "aktienbonus.json", - "event_type": ConditionalEventType.SAVEBACK, - "title": "Aktien-Bonus", - "isin": "US2546871060", - "shares": 0.105, - "value": -10.03, - "transactions": [ - { - "Datum": "2025-10-13T14:49:06", - "Typ": "Kauf", - "Wert": -10.03, - "Notiz": "Aktien-Bonus", - "ISIN": "US2546871060", - "Stück": 0.105, - }, - { - "Datum": "2025-10-13T14:49:06", - "Typ": "Einlage", - "Wert": 10.03, - "Notiz": "Aktien-Bonus", - }, - ], - }, - { - "filename": "aktienbonus_no_eventType.json", - "event_type": ConditionalEventType.SAVEBACK, - "title": "Aktien-Bonus", - "isin": "US2546871060", - "shares": 0.105, - "value": -10.03, - "transactions": [ - { - "Datum": "2025-10-13T14:49:06", - "Typ": "Kauf", - "Wert": -10.03, - "Notiz": "Aktien-Bonus", - "ISIN": "US2546871060", - "Stück": 0.105, - }, - { - "Datum": "2025-10-13T14:49:06", - "Typ": "Einlage", - "Wert": 10.03, - "Notiz": "Aktien-Bonus", - }, - ], - }, - { - "filename": "aktiendividende.json", - "event_type": PPEventType.SPINOFF, - "title": "Enovix", - "isin": "US2935941078", - "shares": 0.494370, - "value": 0, - "note": "Enovix Corp. WTS 01.10.26", - "transactions": [ - { - "Datum": "2025-07-22T14:31:49", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "Enovix Corp. WTS 01.10.26", - "ISIN": "US2935941318", - "Stück": 0.494370, - "ISIN2": "US2935941078", - } - ], - }, - { - "filename": "aktiendividende_no_eventType.json", - "event_type": PPEventType.SPINOFF, - "title": "Enovix", - "isin": "US2935941078", - "shares": 0.494370, - "value": 0, - "note": "Enovix Corp. WTS 01.10.26", - "transactions": [ - { - "Datum": "2025-07-22T14:31:49", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "Enovix Corp. WTS 01.10.26", - "ISIN": "US2935941318", - "Stück": 0.494370, - "ISIN2": "US2935941078", - } - ], - }, - { - "filename": "aktiendividende_only_taxes.json", - "event_type": PPEventType.TAXES, - "title": "Enovix Corp. WTS 01.10.26", - "isin": "US2935941318", - "value": -0.57, - "taxes": 0.57, - "transactions": [ - { - "Datum": "2026-01-06T16:14:51", - "Typ": "Steuern", - "Wert": -0.57, - "Notiz": "Enovix Corp. WTS 01.10.26", - "ISIN": "US2935941318", - "Steuern": 0.57, - } - ], - }, - { - "filename": "aktienpraemiendividende.json", - "event_type": PPEventType.DIVIDEND, - "title": "Glencore", - "isin": "JE00B4T3BW64", - "value": 3, - "taxes": 1.15, - "transactions": [ - { - "Datum": "2025-09-22T11:20:31", - "Typ": "Dividende", - "Wert": 3.0, - "Notiz": "Glencore", - "ISIN": "JE00B4T3BW64", - "Steuern": 1.15, - } - ], - }, - { - "filename": "aktienpraemiendividende_no_eventType.json", - "event_type": PPEventType.DIVIDEND, - "title": "Glencore", - "isin": "JE00B4T3BW64", - "value": 3, - "taxes": 1.15, - "transactions": [ - { - "Datum": "2025-09-22T11:20:31", - "Typ": "Dividende", - "Wert": 3.0, - "Notiz": "Glencore", - "ISIN": "JE00B4T3BW64", - "Steuern": 1.15, - } - ], - }, - { - "filename": "aktiensplit.json", - "event_type": PPEventType.SPLIT, - "title": "Chipotle Mexican Grill", - "isin": "US1696561059", - "shares": 49, - "value": 0, - "transactions": [ - { - "Datum": "2024-06-26T08:06:40", - "Typ": "Split", - "Wert": 0, - "Notiz": "Chipotle Mexican Grill", - "ISIN": "US1696561059", - "Stück": 49, - } - ], - }, - { - "filename": "aktiensplit_no_eventType.json", - "event_type": PPEventType.SPLIT, - "title": "Netflix", - "isin": "US64110L1061", - "shares": 2.743902, - "value": 0, - "transactions": [ - { - "Datum": "2025-11-17T06:07:56", - "Typ": "Split", - "Wert": 0, - "Notiz": "Netflix", - "ISIN": "US64110L1061", - "Stück": 2.743902, - } - ], - }, - { - "filename": "bardividende.json", - "event_type": PPEventType.DIVIDEND, - "title": "Comcast (A)", - "isin": "US20030N1019", - "shares": 10.640298, - "value": 2.24, - "taxes": 0.78, - "transactions": [ - { - "Datum": "2025-10-23T14:19:56", - "Typ": "Dividende", - "Wert": 2.24, - "Notiz": "Comcast (A)", - "ISIN": "US20030N1019", - "Stück": 10.640298, - "Steuern": 0.78, - } - ], - }, - { - "filename": "bardividende_no_eventType.json", - "event_type": PPEventType.DIVIDEND, - "title": "Lowe's", - "isin": "US5486611073", - "shares": 1.189904, - "value": 0.92, - "taxes": 0.32, - "transactions": [ - { - "Datum": "2025-11-05T18:31:19", - "Typ": "Dividende", - "Wert": 0.92, - "Notiz": "Lowe's", - "ISIN": "US5486611073", - "Stück": 1.189904, - "Steuern": 0.32, - } - ], - }, - { - "filename": "bardividende_korrigiert.json", - "event_type": PPEventType.DIVIDEND, - "title": "Medical Properties Trust", - "isin": "US58463J3041", - "shares": 40, - "value": 4.01, - "taxes": 1.53, - "transactions": [ - { - "Datum": "2025-03-20T15:04:31", - "Typ": "Dividende", - "Wert": 4.01, - "Notiz": "Medical Properties Trust", - "ISIN": "US58463J3041", - "Stück": 40.0, - "Steuern": 1.53, - } - ], - }, - { - "filename": "bardividende_korrigiert_no_eventType.json", - "event_type": PPEventType.DIVIDEND, - "title": "Medical Properties Trust", - "isin": "US58463J3041", - "shares": 40, - "value": 4.01, - "taxes": 1.53, - "transactions": [ - { - "Datum": "2025-03-20T15:04:31", - "Typ": "Dividende", - "Wert": 4.01, - "Notiz": "Medical Properties Trust", - "ISIN": "US58463J3041", - "Stück": 40.0, - "Steuern": 1.53, - } - ], - }, - { - "filename": "benefits_spare_change_execution.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "SuperDividend USD (Dist)", - "isin": "IE00077FRP95", - "shares": 0.383219, - "value": -3.38, - "transactions": [ - { - "Datum": "2024-10-02T15:05:40", - "Typ": "Kauf", - "Wert": -3.38, - "Notiz": "SuperDividend USD (Dist)", - "ISIN": "IE00077FRP95", - "Stück": 0.383219, - } - ], - }, - { - "filename": "benefits_spare_change_execution_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "SuperDividend USD (Dist)", - "isin": "IE00077FRP95", - "shares": 0.383219, - "value": -3.38, - "transactions": [ - { - "Datum": "2024-10-02T15:05:40", - "Typ": "Kauf", - "Wert": -3.38, - "Notiz": "SuperDividend USD (Dist)", - "ISIN": "IE00077FRP95", - "Stück": 0.383219, - } - ], - }, - { - "filename": "bonusaktien.json", - "event_type": PPEventType.SPLIT, - "title": "Eckert & Ziegler", - "isin": "DE0005659700", - "shares": 5.706536, - "value": 0, - "transactions": [ - { - "Datum": "2025-08-15T08:10:12", - "Typ": "Split", - "Wert": 0, - "Notiz": "Eckert & Ziegler", - "ISIN": "DE0005659700", - "Stück": 5.706536, - } - ], - }, - { - "filename": "bonusaktien_no_eventType.json", - "event_type": PPEventType.SPLIT, - "title": "Eckert & Ziegler", - "isin": "DE0005659700", - "shares": 5.706536, - "value": 0, - "transactions": [ - { - "Datum": "2025-08-15T08:10:12", - "Typ": "Split", - "Wert": 0, - "Notiz": "Eckert & Ziegler", - "ISIN": "DE0005659700", - "Stück": 5.706536, - } - ], - }, - { - "filename": "bonusaktien2.json", - "event_type": PPEventType.TAXES, - "title": "BYD", - "isin": "CNE100000296", - "value": -8.67, - "taxes": 8.67, - "transactions": [ - { - "Datum": "2025-08-15T14:53:09", - "Typ": "Steuern", - "Wert": -8.67, - "Notiz": "BYD", - "ISIN": "CNE100000296", - "Steuern": 8.67, - } - ], - }, - { - "filename": "bonusaktien2_no_eventType.json", - "event_type": PPEventType.TAXES, - "title": "BYD", - "isin": "CNE100000296", - "value": -8.67, - "taxes": 8.67, - "transactions": [ - { - "Datum": "2025-08-15T14:53:09", - "Typ": "Steuern", - "Wert": -8.67, - "Notiz": "BYD", - "ISIN": "CNE100000296", - "Steuern": 8.67, - } - ], - }, - { - "filename": "bond_kauf.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Juli 2040", - "isin": "DE0001135366", - "shares": 82.27, - "value": -100.99, - "fees": 1.0, - "transactions": [ - { - "Datum": "2025-07-18T08:04:42", - "Typ": "Kauf", - "Wert": -100.99, - "Notiz": "Juli 2040", - "ISIN": "DE0001135366", - "Stück": 82.27, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "bond_verkauf.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Juli 2040", - "isin": "DE0001135366", - "shares": 82.27, - "value": 98.21, - "fees": 1.0, - "transactions": [ - { - "Datum": "2026-03-26T06:48:09", - "Typ": "Verkauf", - "Wert": 98.21, - "Notiz": "Juli 2040", - "ISIN": "DE0001135366", - "Stück": 82.27, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "buy.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Euro Stoxx 50 EUR (Dist)", - "isin": "IE00B4K6B022", - "shares": 60, - "value": -3002.8, - "fees": 1.0, - "transactions": [ - { - "Datum": "2024-02-20T16:32:07", - "Typ": "Kauf", - "Wert": -3002.8, - "Notiz": "Euro Stoxx 50 EUR (Dist)", - "ISIN": "IE00B4K6B022", - "Stück": 60.0, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "buy_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Euro Stoxx 50 EUR (Dist)", - "isin": "IE00B4K6B022", - "shares": 60, - "value": -3002.8, - "fees": 1.0, - "transactions": [ - { - "Datum": "2024-02-20T16:32:07", - "Typ": "Kauf", - "Wert": -3002.8, - "Notiz": "Euro Stoxx 50 EUR (Dist)", - "ISIN": "IE00B4K6B022", - "Stück": 60.0, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "buy_new.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "NVIDIA", - "isin": "US67066G1040", - "shares": 0.685102, - "value": -111, - "fees": 1.0, - "transactions": [ - { - "Datum": "2025-10-10T19:29:43", - "Typ": "Kauf", - "Wert": -111, - "Notiz": "NVIDIA", - "ISIN": "US67066G1040", - "Stück": 0.685102, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "buy_new_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "NVIDIA", - "isin": "US67066G1040", - "shares": 0.685102, - "value": -111, - "fees": 1.0, - "transactions": [ - { - "Datum": "2025-10-10T19:29:43", - "Typ": "Kauf", - "Wert": -111, - "Notiz": "NVIDIA", - "ISIN": "US67066G1040", - "Stück": 0.685102, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "buy_new2.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Rocket Lab Corp. Registered Shares DL-,0001", - "isin": "US7731211089", - "shares": 2, - "value": -75.6, - "fees": 1.0, - "transactions": [ - { - "Datum": "2025-08-01T08:28:01", - "Typ": "Kauf", - "Wert": -75.6, - "Notiz": "Rocket Lab Corp. Registered Shares DL-,0001", - "ISIN": "US7731211089", - "Stück": 2, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "buy_new2_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Rocket Lab Corp. Registered Shares DL-,0001", - "isin": "US7731211089", - "shares": 2, - "value": -75.6, - "fees": 1.0, - "transactions": [ - { - "Datum": "2025-08-01T08:28:01", - "Typ": "Kauf", - "Wert": -75.6, - "Notiz": "Rocket Lab Corp. Registered Shares DL-,0001", - "ISIN": "US7731211089", - "Stück": 2, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "card_refund.json", - "event_type": PPEventType.DEPOSIT, - "title": "Decathlon", - "value": 24.99, - "note": "card_refund", - "transactions": [ - { - "Datum": "2025-08-17T07:23:44", - "Typ": "Einlage", - "Wert": 24.99, - "Notiz": "Kartenerstattung - Decathlon", - } - ], - }, - { - "filename": "card_refund_no_eventType.json", - "event_type": PPEventType.DEPOSIT, - "title": "Decathlon", - "value": 24.99, - "note": "card_refund", - "transactions": [ - { - "Datum": "2025-08-17T07:23:44", - "Typ": "Einlage", - "Wert": 24.99, - "Notiz": "Kartenerstattung - Decathlon", - } - ], - }, - { - "filename": "deposit.json", - "event_type": PPEventType.DEPOSIT, - "title": "My Name", - "value": 200, - "transactions": [ - { - "Datum": "2024-06-03T17:07:26", - "Typ": "Einlage", - "Wert": 200.0, - "Notiz": "My Name", - } - ], - }, - { - "filename": "deposit_no_eventType.json", - "event_type": PPEventType.DEPOSIT, - "title": "My Name", - "value": 200, - "transactions": [ - { - "Datum": "2024-06-03T17:07:26", - "Typ": "Einlage", - "Wert": 200.0, - "Notiz": "My Name", - } - ], - }, - { - "filename": "dividende_old.json", - "event_type": PPEventType.DIVIDEND, - "title": "MSCI World USD (Dist)", - "isin": "LU0392494562", - "shares": 32, - "value": 30.21, - "taxes": 6.83, - "transactions": [ - { - "Datum": "2024-12-31T23:59:59", - "Typ": "Dividende", - "Wert": 30.21, - "Notiz": "MSCI World USD (Dist)", - "ISIN": "LU0392494562", - "Stück": 32.0, - "Steuern": 6.83, - } - ], - }, - { - "filename": "dividende_wahlweise.json", - "event_type": PPEventType.DIVIDEND, - "title": "National Grid", - "isin": "GB00BDR05C01", - "value": 3.37, - "taxes": 1.28, - "transactions": [ - { - "Datum": "2024-07-19T13:28:04", - "Typ": "Dividende", - "Wert": 3.37, - "Notiz": "National Grid", - "ISIN": "GB00BDR05C01", - "Steuern": 1.28, - } - ], - }, - { - "filename": "dividende_wahlweise_no_eventType.json", - "event_type": PPEventType.DIVIDEND, - "title": "National Grid", - "isin": "GB00BDR05C01", - "value": 3.37, - "taxes": 1.28, - "transactions": [ - { - "Datum": "2024-07-19T13:28:04", - "Typ": "Dividende", - "Wert": 3.37, - "Notiz": "National Grid", - "ISIN": "GB00BDR05C01", - "Steuern": 1.28, - } - ], - }, - { - "filename": "incoming_transfer.json", - "event_type": PPEventType.DEPOSIT, - "title": "Klaus Mustermann", - "value": 88.04, - "transactions": [ - { - "Datum": "2024-09-02T17:49:12", - "Typ": "Einlage", - "Wert": 88.04, - "Notiz": "Klaus Mustermann", - } - ], - }, - { - "filename": "incoming_transfer_no_eventType.json", - "event_type": PPEventType.DEPOSIT, - "title": "Klaus Mustermann", - "value": 88.04, - "transactions": [ - { - "Datum": "2024-09-02T17:49:12", - "Typ": "Einlage", - "Wert": 88.04, - "Notiz": "Klaus Mustermann", - } - ], - }, - { - "filename": "incoming_transfer_delegation.json", - "event_type": PPEventType.DEPOSIT, - "title": "Vorname Nachname", - "value": 3000.0, - "transactions": [ - { - "Datum": "2024-09-10T13:18:31", - "Typ": "Einlage", - "Wert": 3000.0, - "Notiz": "Vorname Nachname", - } - ], - }, - { - "filename": "incoming_transfer_delegation_no_eventType.json", - "event_type": PPEventType.DEPOSIT, - "title": "Vorname Nachname", - "value": 3000.0, - "transactions": [ - { - "Datum": "2024-09-10T13:18:31", - "Typ": "Einlage", - "Wert": 3000.0, - "Notiz": "Vorname Nachname", - } - ], - }, - { - "filename": "junior_p2p_transfer.json", - "event_type": PPEventType.REMOVAL, - "title": "Maria Mueller", - "value": -50, - "transactions": [ - { - "Datum": "2025-09-17T19:35:32", - "Typ": "Entnahme", - "Wert": -50.0, - "Notiz": "Maria Mueller", - } - ], - }, - { - "filename": "junior_p2p_transfer_no_eventType.json", - "event_type": PPEventType.REMOVAL, - "title": "Maria Mueller", - "value": -50, - "transactions": [ - { - "Datum": "2025-09-17T19:35:32", - "Typ": "Entnahme", - "Wert": -50.0, - "Notiz": "Maria Mueller", - } - ], - }, - { - "filename": "kartenzahlung.json", - "event_type": PPEventType.REMOVAL, - "title": "Coop Pronto", - "value": -12.16, - "note": "card_successful_transaction", - "transactions": [ - { - "Datum": "2025-10-21T17:30:01", - "Typ": "Entnahme", - "Wert": -12.16, - "Notiz": "Kartentransaktion - Coop Pronto", - } - ], - }, - { - "filename": "kartenzahlung_no_eventType.json", - "event_type": PPEventType.REMOVAL, - "title": "Baecker", - "value": -2, - "note": "card_successful_transaction", - "transactions": [ - { - "Datum": "2025-11-05T11:00:07", - "Typ": "Entnahme", - "Wert": -2.0, - "Notiz": "Kartentransaktion - Baecker", - } - ], - }, - { - "filename": "legacy_verkauforder_neu_abgerechnet.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Marie Brizard Wine and Spirits", - "isin": "FR0000060873", - "shares": 27, - "value": 91.34, - "fees": 1, - "transactions": [ - { - "Datum": "2025-02-21T11:14:54", - "Typ": "Verkauf", - "Wert": 91.34, - "Notiz": "Marie Brizard Wine and Spirits", - "ISIN": "FR0000060873", - "Stück": 27.0, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "legacy_verkauforder_neu_abgerechnet_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Marie Brizard Wine and Spirits", - "isin": "FR0000060873", - "shares": 27, - "value": 91.34, - "fees": 1, - "transactions": [ - { - "Datum": "2025-02-21T11:14:54", - "Typ": "Verkauf", - "Wert": 91.34, - "Notiz": "Marie Brizard Wine and Spirits", - "ISIN": "FR0000060873", - "Stück": 27.0, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "legacy_zinsen.json", - "event_type": PPEventType.INTEREST, - "title": "Zinsen", - "value": 11.76, - "taxes": 4.51, - "transactions": [ - { - "Datum": "2024-09-01T16:39:48", - "Typ": "Zinsen", - "Wert": 11.76, - "Notiz": "Zinsen", - "Steuern": 4.51, - } - ], - }, - { - "filename": "legacy_zinsen_no_eventType.json", - "event_type": PPEventType.INTEREST, - "title": "Zinsen", - "value": 11.76, - "taxes": 4.51, - "transactions": [ - { - "Datum": "2024-09-01T16:39:48", - "Typ": "Zinsen", - "Wert": 11.76, - "Notiz": "Zinsen", - "Steuern": 4.51, - } - ], - }, - { - "filename": "limit-sell-order.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "D-Wave Quantum", - "isin": "US26740W1099", - "shares": 11, - "value": 114.91, - "fees": 1, - "taxes": 17.36, - "transactions": [ - { - "Datum": "2025-05-20T08:03:45", - "Typ": "Verkauf", - "Wert": 114.91, - "Notiz": "D-Wave Quantum", - "ISIN": "US26740W1099", - "Stück": 11.0, - "Gebühren": 1.0, - "Steuern": 17.36, - } - ], - }, - { - "filename": "limit-sell-order_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Teva Pharmaceutical Industries (ADR)", - "isin": "US8816242098", - "shares": 8, - "value": 139.74, - "fees": 1, - "taxes": 7.66, - "transactions": [ - { - "Datum": "2025-11-05T12:03:19", - "Typ": "Verkauf", - "Wert": 139.74, - "Notiz": "Teva Pharmaceutical Industries (ADR)", - "ISIN": "US8816242098", - "Stück": 8.0, - "Gebühren": 1.0, - "Steuern": 7.66, - } - ], - }, - { - "filename": "limit-sell-order_old.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Daimler Truck Holding", - "isin": "DE000DTR0CK8", - "shares": 3, - "value": 119.37, - "fees": 1, - "taxes": 0.14, - "transactions": [ - { - "Datum": "2025-05-14T07:01:32", - "Typ": "Verkauf", - "Wert": 119.37, - "Notiz": "Daimler Truck Holding", - "ISIN": "DE000DTR0CK8", - "Stück": 3.0, - "Gebühren": 1.0, - "Steuern": 0.14, - } - ], - }, - { - "filename": "limit-sell-order_old_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Daimler Truck Holding", - "isin": "DE000DTR0CK8", - "shares": 3, - "value": 119.37, - "fees": 1, - "taxes": 0.14, - "transactions": [ - { - "Datum": "2025-05-14T07:01:32", - "Typ": "Verkauf", - "Wert": 119.37, - "Notiz": "Daimler Truck Holding", - "ISIN": "DE000DTR0CK8", - "Stück": 3.0, - "Gebühren": 1.0, - "Steuern": 0.14, - } - ], - }, - { - "filename": "outgoing_transfer.json", - "event_type": PPEventType.REMOVAL, - "title": "Hans Mustermann", - "value": -50.3, - "transactions": [ - { - "Datum": "2024-07-21T09:35:47", - "Typ": "Entnahme", - "Wert": -50.3, - "Notiz": "Hans Mustermann", - } - ], - }, - { - "filename": "outgoing_transfer_no_eventType.json", - "event_type": PPEventType.REMOVAL, - "title": "Hans Mustermann", - "value": -50.3, - "transactions": [ - { - "Datum": "2024-07-21T09:35:47", - "Typ": "Entnahme", - "Wert": -50.3, - "Notiz": "Hans Mustermann", - } - ], - }, - { - "filename": "outgoing_transfer_delegation.json", - "event_type": PPEventType.REMOVAL, - "title": "Nina", - "value": -67, - "transactions": [ - { - "Datum": "2025-08-18T12:16:06", - "Typ": "Entnahme", - "Wert": -67.0, - "Notiz": "Nina", - } - ], - }, - { - "filename": "outgoing_transfer_delegation_no_eventType.json", - "event_type": PPEventType.REMOVAL, - "title": "Nina", - "value": -67, - "transactions": [ - { - "Datum": "2025-08-18T12:16:06", - "Typ": "Entnahme", - "Wert": -67.0, - "Notiz": "Nina", - } - ], - }, - { - "filename": "outgoing_transfer_legacy.json", - "event_type": PPEventType.REMOVAL, - "title": "My Name", - "value": -750, - "transactions": [ - { - "Datum": "2025-04-11T06:44:43", - "Typ": "Entnahme", - "Wert": -750.0, - "Notiz": "My Name", - } - ], - }, - { - "filename": "outgoing_transfer_legacy_no_eventType.json", - "event_type": PPEventType.REMOVAL, - "title": "My Name", - "value": -750, - "transactions": [ - { - "Datum": "2025-04-11T06:44:43", - "Typ": "Entnahme", - "Wert": -750.0, - "Notiz": "My Name", - } - ], - }, - { - "filename": "payment_inbound_credit_card.json", - "event_type": PPEventType.DEPOSIT, - "title": "Einzahlung", - "value": 1000, - "fees": 7, - "transactions": [ - { - "Datum": "2022-08-27T05:06:30", - "Typ": "Einlage", - "Wert": 1000.0, - "Notiz": "Einzahlung", - "Gebühren": 7.0, - } - ], - }, - { - "filename": "payment_inbound_credit_card_no_eventType.json", - "event_type": PPEventType.DEPOSIT, - "title": "Einzahlung", - "value": 1000, - "fees": 7, - "transactions": [ - { - "Datum": "2022-08-27T05:06:30", - "Typ": "Einlage", - "Wert": 1000.0, - "Notiz": "Einzahlung", - "Gebühren": 7.0, - } - ], - }, - { - "filename": "private_markets_order.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "title": "Private Equity", - "isin": "LU3176111881", - "shares": 1, - "value": -101, - "fees": 1, - "note": "Kauforder", - "transactions": [ - { - "Datum": "2025-09-18T07:15:25", - "Typ": "Kauf", - "Wert": -101.0, - "Notiz": "EQT", - "ISIN": "LU3176111881", - "Stück": 1.0, - "Gebühren": 1.0, - }, - ], - }, - { - "filename": "private_markets_order_no_eventType.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "title": "Private Equity", - "isin": "LU3176111881", - "shares": 1, - "value": -101, - "fees": 1, - "note": "Kauforder", - "transactions": [ - { - "Datum": "2025-09-18T07:15:25", - "Typ": "Kauf", - "Wert": -101.0, - "Notiz": "EQT", - "ISIN": "LU3176111881", - "Stück": 1.0, - "Gebühren": 1.0, - }, - ], - }, - { - "filename": "private_markets_order_bonus.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "title": "Private Equity", - "isin": "LU3176111881", - "shares": 0.01, - "value": -1, - "note": "1 % Bonus", - "transactions": [ - { - "Datum": "2025-09-18T07:15:25", - "Typ": "Kauf", - "Wert": -1.0, - "Notiz": "EQT", - "ISIN": "LU3176111881", - "Stück": 0.01, - }, - { - "Datum": "2025-09-18T07:15:25", - "Typ": "Einlage", - "Wert": 1.0, - "Notiz": "EQT", - }, - ], - }, - { - "filename": "private_markets_order_bonus_no_eventType.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "title": "Private Equity", - "isin": "LU3176111881", - "shares": 0.01, - "value": -1, - "note": "1 % Bonus", - "transactions": [ - { - "Datum": "2025-09-18T07:15:25", - "Typ": "Kauf", - "Wert": -1.0, - "Notiz": "EQT", - "ISIN": "LU3176111881", - "Stück": 0.01, - }, - { - "Datum": "2025-09-18T07:15:25", - "Typ": "Einlage", - "Wert": 1.0, - "Notiz": "EQT", - }, - ], - }, - { - "filename": "private_markets_trade.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "title": "Private Equity", - "isin": "LU3170240538", - "shares": 1, - "value": -101, - "fees": 1, - "note": "Kauforder", - "transactions": [ - { - "Datum": "2025-09-18T07:14:56", - "Typ": "Kauf", - "Wert": -101.0, - "Notiz": "Apollo", - "ISIN": "LU3170240538", - "Stück": 1.0, - "Gebühren": 1.0, - }, - ], - }, - { - "filename": "private_markets_trade_no_eventType.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "title": "Private Equity", - "isin": "LU3170240538", - "shares": 1, - "value": -101, - "fees": 1, - "note": "Kauforder", - "transactions": [ - { - "Datum": "2025-09-18T07:14:56", - "Typ": "Kauf", - "Wert": -101.0, - "Notiz": "Apollo", - "ISIN": "LU3170240538", - "Stück": 1.0, - "Gebühren": 1.0, - }, - ], - }, - { - "filename": "private_markets_trade_bonus.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "isin": "LU3170240538", - "title": "Private Equity", - "shares": 0.01, - "value": -1, - "note": "1 % Bonus", - "transactions": [ - { - "Datum": "2025-09-18T07:14:56", - "Typ": "Kauf", - "Wert": -1, - "Notiz": "Apollo", - "ISIN": "LU3170240538", - "Stück": 0.01, - }, - { - "Datum": "2025-09-18T07:14:56", - "Typ": "Einlage", - "Wert": 1, - "Notiz": "Apollo", - }, - ], - }, - { - "filename": "private_markets_trade_bonus_no_eventType.json", - "event_type": ConditionalEventType.PRIVATE_MARKETS_ORDER, - "isin": "LU3170240538", - "title": "Private Equity", - "shares": 0.01, - "value": -1, - "note": "1 % Bonus", - "transactions": [ - { - "Datum": "2025-09-18T07:14:56", - "Typ": "Kauf", - "Wert": -1, - "Notiz": "Apollo", - "ISIN": "LU3170240538", - "Stück": 0.01, - }, - { - "Datum": "2025-09-18T07:14:56", - "Typ": "Einlage", - "Wert": 1, - "Notiz": "Apollo", - }, - ], - }, - { - "filename": "private_markets_verkaufs_order_erstellt.json", - }, - { - "filename": "private_markets_vorabpauschale.json", - "event_type": PPEventType.TAXES, - "title": "Private Equity", - "isin": "LU3176111881", - "value": -0.07, - "taxes": 0.07, - "transactions": [ - { - "Datum": "2026-03-09T07:56:12", - "Typ": "Steuern", - "Wert": -0.07, - "Notiz": "EQT", - "ISIN": "LU3176111881", - "Steuern": 0.07, - } - ], - }, - { - "filename": "reverse_split.json", - "event_type": PPEventType.SWAP, - "title": "Globalstar", - "isin": "US3789734080", - "shares": 110.403067, - "shares2": 7.360204, - "value": 0, - "note": "GLOBALSTAR INC. O.N.", - "transactions": [ - { - "Datum": "2025-02-11T08:13:48", - "Typ": "Swap", - "Wert": 0, - "Notiz": "Globalstar", - "ISIN": "US3789734080", - "Stück": 110.403067, - "ISIN2": "US3789735079", - "Stück2": 7.360204, - }, - ], - }, - { - "filename": "reverse_split_no_eventType.json", - "event_type": PPEventType.SWAP, - "title": "Globalstar", - "isin": "US3789734080", - "shares": 110.403067, - "shares2": 7.360204, - "value": 0, - "note": "GLOBALSTAR INC. O.N.", - "transactions": [ - { - "Datum": "2025-02-11T08:13:48", - "Typ": "Swap", - "Wert": 0, - "Notiz": "Globalstar", - "ISIN": "US3789734080", - "Stück": 110.403067, - "ISIN2": "US3789735079", - "Stück2": 7.360204, - }, - ], - }, - { - "filename": "saveback.json", - "event_type": ConditionalEventType.SAVEBACK, - "title": "S&P 500 Information Tech USD (Acc)", - "isin": "IE00B3WJKG14", - "shares": 0.546348, - "value": -15, - "transactions": [ - { - "Datum": "2025-04-02T13:54:23", - "Typ": "Kauf", - "Wert": -15.0, - "Notiz": "S&P 500 Information Tech USD (Acc)", - "ISIN": "IE00B3WJKG14", - "Stück": 0.546348, - }, - { - "Datum": "2025-04-02T13:54:23", - "Typ": "Einlage", - "Wert": 15.0, - "Notiz": "S&P 500 Information Tech USD (Acc)", - }, - ], - }, - { - "filename": "saveback_no_eventType.json", - "event_type": ConditionalEventType.SAVEBACK, - "title": "Lockheed Martin", - "isin": "US5398301094", - "shares": 0.035252, - "value": -15, - "transactions": [ - { - "Datum": "2025-11-03T15:30:22", - "Typ": "Kauf", - "Wert": -15.0, - "Notiz": "Lockheed Martin", - "ISIN": "US5398301094", - "Stück": 0.035252, - }, - { - "Datum": "2025-11-03T15:30:22", - "Typ": "Einlage", - "Wert": 15.0, - "Notiz": "Lockheed Martin", - }, - ], - }, - { - "filename": "savingsplan.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "DroneShield", - "isin": "AU000000DRO2", - "shares": 6.921675, - "value": -19, - "transactions": [ - { - "Datum": "2025-10-23T08:26:13", - "Typ": "Kauf", - "Wert": -19.0, - "Notiz": "DroneShield", - "ISIN": "AU000000DRO2", - "Stück": 6.921675, - } - ], - }, - { - "filename": "savingsplan_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "TSMC (ADR)", - "isin": "US8740391003", - "shares": 0.037523, - "value": -10, - "transactions": [ - { - "Datum": "2025-11-03T15:58:11", - "Typ": "Kauf", - "Wert": -10.0, - "Notiz": "TSMC (ADR)", - "ISIN": "US8740391003", - "Stück": 0.037523, - } - ], - }, - { - "filename": "sell_stop.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "D-Wave Quantum", - "isin": "US26740W1099", - "shares": 17, - "value": 94.76, - "fees": 1, - "taxes": 3.18, - "transactions": [ - { - "Datum": "2025-03-14T07:03:14", - "Typ": "Verkauf", - "Wert": 94.76, - "Notiz": "D-Wave Quantum", - "ISIN": "US26740W1099", - "Gebühren": 1.0, - "Steuern": 3.18, - "Stück": 17.0, - } - ], - }, - { - "filename": "sell_stop_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "D-Wave Quantum", - "isin": "US26740W1099", - "shares": 17, - "value": 94.76, - "fees": 1, - "taxes": 3.18, - "transactions": [ - { - "Datum": "2025-03-14T07:03:14", - "Typ": "Verkauf", - "Wert": 94.76, - "Notiz": "D-Wave Quantum", - "ISIN": "US26740W1099", - "Gebühren": 1.0, - "Steuern": 3.18, - "Stück": 17.0, - } - ], - }, - { - "filename": "spinoff.json", - "event_type": PPEventType.SPINOFF, - "title": "ThyssenKrupp", - "isin": "DE0007500001", - "shares": 0.309986, - "value": 0, - "note": "TKMS", - "transactions": [ - { - "Datum": "2025-10-20T11:25:29", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "TKMS", - "ISIN": "DE000TKMS001", - "Stück": 0.309986, - "ISIN2": "DE0007500001", - } - ], - }, - { - "filename": "spinoff_no_eventType.json", - "event_type": PPEventType.SPINOFF, - "title": "ThyssenKrupp", - "isin": "DE0007500001", - "shares": 0.309986, - "value": 0, - "note": "TKMS", - "transactions": [ - { - "Datum": "2025-10-20T11:25:29", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "TKMS", - "ISIN": "DE000TKMS001", - "Stück": 0.309986, - "ISIN2": "DE0007500001", - } - ], - }, - { - "filename": "spinoff_only_taxes.json", - "event_type": PPEventType.TAXES, - "title": "Gamestop Corp. WTS 30.10.26", - "isin": "US36467W1172", - "value": -0.56, - "taxes": 0.56, - "transactions": [ - { - "Datum": "2025-12-19T15:24:37", - "Typ": "Steuern", - "Wert": -0.56, - "Notiz": "Gamestop Corp. WTS 30.10.26", - "ISIN": "US36467W1172", - "Steuern": 0.56, - } - ], - }, - { - "filename": "steuerkorrektur.json", - "event_type": PPEventType.TAX_REFUND, - "title": "Steuerkorrektur", - "value": 2.87, - "transactions": [ - { - "Datum": "2025-10-28T00:00:16", - "Typ": "Steuerrückerstattung", - "Wert": 2.87, - "Notiz": "Steuerkorrektur", - } - ], - }, - { - "filename": "steuerkorrektur_no_eventType.json", - "event_type": PPEventType.TAX_REFUND, - "title": "Steuerkorrektur", - "value": 0.76, - "transactions": [ - { - "Datum": "2025-11-04T23:31:58", - "Typ": "Steuerrückerstattung", - "Wert": 0.76, - "Notiz": "Steuerkorrektur", - } - ], - }, - { - "filename": "tausch_no_eventType.json", - "title": "L'Oreal", - }, - { - "filename": "teilrueckzahlung.json", - "event_type": PPEventType.SWAP, - "title": "ORSTED A/S EM.09/25 DK 10", - "isin": "DK0064307755", - "shares": 17, - "shares2": 17, - "value": 0, - "note": "Orsted", - "transactions": [ - { - "Datum": "2025-10-23T14:46:49", - "Typ": "Swap", - "Wert": 0, - "Notiz": "ORSTED A/S EM.09/25 DK 10", - "ISIN": "DK0064307755", - "Stück": 17.0, - "ISIN2": "DK0060094928", - "Stück2": 17.0, - }, - ], - }, - { - "filename": "teilrueckzahlung_no_eventType.json", - "event_type": PPEventType.SWAP, - "title": "ORSTED A/S EM.09/25 DK 10", - "isin": "DK0064307755", - "shares": 17, - "shares2": 17, - "value": 0, - "note": "Orsted", - "transactions": [ - { - "Datum": "2025-10-23T14:46:49", - "Typ": "Swap", - "Wert": 0, - "Notiz": "ORSTED A/S EM.09/25 DK 10", - "ISIN": "DK0064307755", - "Stück": 17.0, - "ISIN2": "DK0060094928", - "Stück2": 17.0, - }, - ], - }, - { - "filename": "tilgung.json", - "event_type": PPEventType.DIVIDEND, - "title": "Long 1,2345 $", - "isin": "DE000SX12345", - "shares": 100, - "value": 0.1, - "transactions": [ - { - "Datum": "2025-01-10T10:00:00", - "Typ": "Dividende", - "Wert": 0.1, - "Notiz": "Long 1,2345 $", - "ISIN": "DE000SX12345", - "Stück": 100.0, - } - ], - }, - { - "filename": "tilgung_no_eventType.json", - "event_type": PPEventType.DIVIDEND, - "title": "Long 1,2345 $", - "isin": "DE000SX12345", - "shares": 100, - "value": 0.1, - "transactions": [ - { - "Datum": "2025-01-10T10:00:00", - "Typ": "Dividende", - "Wert": 0.1, - "Notiz": "Long 1,2345 $", - "ISIN": "DE000SX12345", - "Stück": 100.0, - } - ], - }, - { - "filename": "trade_perk.json", - "event_type": ConditionalEventType.SAVEBACK, - "title": "Aktien-Bonus", - "isin": "US0378331005", - "shares": 0.0487, - "value": -10.03, - "transactions": [ - { - "Datum": "2025-04-01T14:09:45", - "Typ": "Kauf", - "Wert": -10.03, - "Notiz": "Aktien-Bonus", - "ISIN": "US0378331005", - "Stück": 0.0487, - }, - { - "Datum": "2025-04-01T14:09:45", - "Typ": "Einlage", - "Wert": 10.03, - "Notiz": "Aktien-Bonus", - }, - ], - }, - { - "filename": "trade_perk_no_eventType.json", - "event_type": ConditionalEventType.SAVEBACK, - "title": "Aktien-Bonus", - "isin": "US0378331005", - "shares": 0.0487, - "value": -10.03, - "transactions": [ - { - "Datum": "2025-04-01T14:09:45", - "Typ": "Kauf", - "Wert": -10.03, - "Notiz": "Aktien-Bonus", - "ISIN": "US0378331005", - "Stück": 0.0487, - }, - { - "Datum": "2025-04-01T14:09:45", - "Typ": "Einlage", - "Wert": 10.03, - "Notiz": "Aktien-Bonus", - }, - ], - }, - { - "filename": "verkaufsorder.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Tencent Holdings (ADR)", - "isin": "US88032Q1094", - "shares": 3.454506, - "value": 200.93, - "fees": 1, - "taxes": 0.16, - "transactions": [ - { - "Datum": "2025-05-12T18:38:36", - "Typ": "Verkauf", - "Wert": 200.93, - "Notiz": "Tencent Holdings (ADR)", - "ISIN": "US88032Q1094", - "Stück": 3.454506, - "Gebühren": 1.0, - "Steuern": 0.16, - } - ], - }, - { - "filename": "verkaufsorder_no_eventType.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Home Depot", - "isin": "US4370761029", - "shares": 0.305182, - "value": 100, - "fees": 1, - "transactions": [ - { - "Datum": "2025-11-04T16:27:25", - "Typ": "Verkauf", - "Wert": 100.0, - "Notiz": "Home Depot", - "ISIN": "US4370761029", - "Stück": 0.305182, - "Gebühren": 1.0, - } - ], - }, - { - "filename": "vorabpauschale.json", - "event_type": PPEventType.TAXES, - "title": "MSCI China USD (Acc)", - "isin": "IE00BJ5JPG56", - "value": -0.19, - "taxes": 0.19, - "transactions": [ - { - "Datum": "2025-01-28T14:54:28", - "Typ": "Steuern", - "Wert": -0.19, - "Notiz": "MSCI China USD (Acc)", - "ISIN": "IE00BJ5JPG56", - "Steuern": 0.19, - } - ], - }, - { - "filename": "vorabpauschale_no_eventType.json", - "event_type": PPEventType.TAXES, - "title": "MSCI China USD (Acc)", - "isin": "IE00BJ5JPG56", - "value": -0.19, - "taxes": 0.19, - "transactions": [ - { - "Datum": "2025-01-28T14:54:28", - "Typ": "Steuern", - "Wert": -0.19, - "Notiz": "MSCI China USD (Acc)", - "ISIN": "IE00BJ5JPG56", - "Steuern": 0.19, - } - ], - }, - { - "filename": "zinsen.json", - "event_type": PPEventType.INTEREST, - "title": "Zinsen", - "value": 4.87, - "taxes": 1.87, - "transactions": [ - { - "Datum": "2025-07-01T06:46:37", - "Typ": "Zinsen", - "Wert": 4.87, - "Notiz": "Zinsen", - "Steuern": 1.87, - } - ], - }, - { - "filename": "zinsen_no_eventType.json", - "event_type": PPEventType.INTEREST, - "title": "Zinsen", - "value": 4.87, - "taxes": 1.87, - "transactions": [ - { - "Datum": "2025-07-01T06:46:37", - "Typ": "Zinsen", - "Wert": 4.87, - "Notiz": "Zinsen", - "Steuern": 1.87, - } - ], - }, - { - "filename": "zusammenschluss.json", - "event_type": PPEventType.SWAP, - "title": "Rocket Lab USA", - "isin": "US7731221062", - "shares": 5.943100, - "shares2": 5.943100, - "value": 0, - "note": "ROCKET LAB CORP. O.N.", - "transactions": [ - { - "Datum": "2025-05-29T13:04:58", - "Typ": "Swap", - "Wert": 0, - "Notiz": "Rocket Lab USA", - "ISIN": "US7731221062", - "Stück": 5.9431, - "ISIN2": "US7731211089", - "Stück2": 5.9431, - }, - ], - }, - { - "filename": "zusammenschluss_no_eventType.json", - "event_type": PPEventType.SWAP, - "title": "Rocket Lab USA", - "isin": "US7731221062", - "shares": 5.943100, - "shares2": 5.943100, - "value": 0, - "note": "ROCKET LAB CORP. O.N.", - "transactions": [ - { - "Datum": "2025-05-29T13:04:58", - "Typ": "Swap", - "Wert": 0, - "Notiz": "Rocket Lab USA", - "ISIN": "US7731221062", - "Stück": 5.9431, - "ISIN2": "US7731211089", - "Stück2": 5.9431, - }, - ], - }, - { - "filename": "zusammenschluss2.json", - "event_type": PPEventType.SWAP, - "title": "Rocket Lab USA", - "isin": "US7731221062", - "shares": 5.943100, - "shares2": 5.943100, - "value": 0, - "note": "ROCKET LAB CORP. O.N.", - "transactions": [ - { - "Datum": "2025-05-29T13:04:58", - "Typ": "Swap", - "Wert": 0, - "Notiz": "Rocket Lab USA", - "ISIN": "US7731221062", - "Stück": 5.9431, - "ISIN2": "US7731211089", - "Stück2": 5.9431, - }, - ], - }, - { - "filename": "zwischenpapiere.json", - "event_type": PPEventType.SWAP, - "title": "ORSTED A/S -ANR-", - "isin": "DK0064307839", - "shares": 119, - "shares2": 17, - "value": -151.59, - "note": "ORSTED A/S EM.09/25 DK 10", - "transactions": [ - { - "Datum": "2025-10-21T07:39:39", - "Typ": "Swap", - "Wert": -151.59, - "ISIN": "DK0064307839", - "Notiz": "ORSTED A/S -ANR-", - "Stück": 119.0, - "ISIN2": "DK0064307755", - "Stück2": 17.0, - }, - ], - }, - { - "filename": "zwischenpapiere2.json", - "event_type": PPEventType.SWAP, - "title": "WORLDLINE S.A. ANR", - "isin": "FR0014015MS9", - "shares": 1, - "shares2": 6, - "value": -1.21, - "note": "Worldline", - "transactions": [ - { - "Datum": "2026-04-03T09:37:06", - "Typ": "Swap", - "Wert": -1.21, - "ISIN": "FR0014015MS9", - "Notiz": "WORLDLINE S.A. ANR", - "Stück": 1.0, - "ISIN2": "FR0011981968", - "Stück2": 6.0, - }, - ], - }, - { - "filename": "zwischenpapiere3.json", - "event_type": ConditionalEventType.TRADE_INVOICE, - "title": "Worldline", - "isin": "FR0011981968", - "shares": 1294, - "value": -261.39, - "transactions": [ - { - "Datum": "2026-04-03T10:38:58", - "Typ": "Kauf", - "Wert": -261.39, - "ISIN": "FR0011981968", - "Notiz": "Worldline", - "Stück": 1294.0, - }, - ], - }, - { - "filename": "zwischenpapiere_no_eventType.json", - "event_type": PPEventType.SWAP, - "title": "ORSTED A/S -ANR-", - "isin": "DK0064307839", - "shares": 119, - "shares2": 17, - "value": -151.59, - "note": "ORSTED A/S EM.09/25 DK 10", - "transactions": [ - { - "Datum": "2025-10-21T07:39:39", - "Typ": "Swap", - "Wert": -151.59, - "ISIN": "DK0064307839", - "Notiz": "ORSTED A/S -ANR-", - "Stück": 119.0, - "ISIN2": "DK0064307755", - "Stück2": 17.0, - }, - ], - }, - { - "filename": "zwischenvertrieb.json", - "event_type": PPEventType.SPINOFF, - "title": "Orsted", - "isin": "DK0060094928", - "shares": 119.285835, - "value": 0, - "note": "ORSTED A/S -ANR-", - "transactions": [ - { - "Datum": "2025-09-19T12:02:49", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "ORSTED A/S -ANR-", - "ISIN": "DK0064307839", - "Stück": 119.285835, - "ISIN2": "DK0060094928", - } - ], - }, - { - "filename": "zwischenvertrieb_no_eventType.json", - "event_type": PPEventType.SPINOFF, - "title": "Orsted", - "isin": "DK0060094928", - "shares": 119.285835, - "value": 0, - "note": "ORSTED A/S -ANR-", - "transactions": [ - { - "Datum": "2025-09-19T12:02:49", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "ORSTED A/S -ANR-", - "ISIN": "DK0064307839", - "Stück": 119.285835, - "ISIN2": "DK0060094928", - } - ], - }, - { - "filename": "zwischenvertrieb2.json", - "event_type": PPEventType.SPINOFF, - "title": "Worldline", - "isin": "FR0011981968", - "shares": 1.299376, - "value": 0, - "note": "Worldline", - "transactions": [ - { - "Datum": "2026-03-17T10:45:33", - "Typ": "Spinoff", - "Wert": 0, - "Notiz": "Worldline", - "ISIN": "FR0014015MS9", - "Stück": 1.299376, - "ISIN2": "FR0011981968", - } - ], - }, - ] - # Create an instance of EventCsvFormatter +@pytest.mark.parametrize("case", test_data, ids=[c["filename"] for c in test_data]) +def test_events(case): formatter = TransactionExporter(lang="de") - for row in test_data: - # Load the sample JSON file - with open("tests/" + row["filename"], "r", encoding="utf-8") as file: - sample_data = json.load(file) + with open(EVENTS_DIR / case["filename"], encoding="utf-8") as f: + sample_data = json.load(f) - # Parse the JSON data using the from_dict function - event = Event.from_dict(sample_data) + event = Event.from_dict(sample_data) - # Assert event type - assert event.event_type == row.get("event_type") + assert event.event_type == case.get("event_type") - # if event type is none, nothing else is to check, results will be discarded - if row.get("event_type") is None: - continue + if case.get("event_type") is None: + return - # Assert the expected values - assert event.title == row.get("title") - assert event.isin == row.get("isin") - assert event.isin2 == row.get("isin2") - assert event.shares == row.get("shares") - assert event.shares2 == row.get("shares2") - assert event.value == row.get("value") - assert event.fees == row.get("fees") - assert event.taxes == row.get("taxes") - assert event.note == row.get("note") + assert event.title == case.get("title") + assert event.isin == case.get("isin") + assert event.isin2 == case.get("isin2") + assert event.shares == case.get("shares") + assert event.shares2 == case.get("shares2") + assert event.value == case.get("value") + assert event.fees == case.get("fees") + assert event.taxes == case.get("taxes") + assert event.note == case.get("note") - # Format the event to CSV - transactions = list(formatter.from_event(event)) + transactions = list(formatter.from_event(event)) - # Assert that the output is not an empty string - rowtransactions = row.get("transactions", []) - for entry in rowtransactions: - entry.setdefault("Datum", None) - entry.setdefault("Typ", None) - entry.setdefault("Wert", None) - entry.setdefault("Notiz", None) - entry.setdefault("ISIN", None) - entry.setdefault("Stück", None) - entry.setdefault("Gebühren", None) - entry.setdefault("Steuern", None) - entry.setdefault("ISIN2", None) - entry.setdefault("Stück2", None) - assert transactions == rowtransactions + rowtransactions = case.get("transactions", []) + for entry in rowtransactions: + entry.setdefault("Datum", None) + entry.setdefault("Typ", None) + entry.setdefault("Wert", None) + entry.setdefault("Notiz", None) + entry.setdefault("ISIN", None) + entry.setdefault("Stück", None) + entry.setdefault("Gebühren", None) + entry.setdefault("Steuern", None) + entry.setdefault("ISIN2", None) + entry.setdefault("Stück2", None) + assert transactions == rowtransactions diff --git a/tests/test_export_transactions.py b/tests/test_export_transactions.py new file mode 100644 index 00000000..cdd17042 --- /dev/null +++ b/tests/test_export_transactions.py @@ -0,0 +1,284 @@ +""" +Tests for export_transactions via --load-event-database (no TR login or connection). +Uses tests/all_events_test.json with 5 events: buy, sell, dividend, deposit, split. +""" + +import asyncio +import csv +import io +import subprocess +import sys +from datetime import datetime, timedelta, timezone +from pathlib import Path + +from pytr.event import Event +from pytr.timeline import Timeline +from pytr.transactions import TransactionExporter + +ALL_EVENTS_FILE = Path(__file__).parent / "all_events_test.json" +GOLDEN_CSV = Path(__file__).parent / "all_events_test_golden.csv" + + +def load_events(output_dir): + tl = Timeline( + tr=None, + output_path=output_dir, + store_event_database=False, + load_event_database=ALL_EVENTS_FILE, + ) + asyncio.run(tl.tl_loop()) + return tl.events + + +def export_csv(events): + parsed = [Event.from_dict(e) for e in events] + buf = io.StringIO() + TransactionExporter(lang="de").export(buf, parsed, sort=True, format="csv") + buf.seek(0) + return list(csv.DictReader(buf, delimiter=";")) + + +def test_no_tr_connection(tmp_path, monkeypatch): + """Timeline must not touch self.tr at all when load_event_database is set.""" + import pytr.timeline as tl_module + + original_init = tl_module.Timeline.__init__ + connection_attempted = [] + + def patched_init(self, *args, **kwargs): + original_init(self, *args, **kwargs) + + class NoConnection: + def __getattr__(self, name): + connection_attempted.append(name) + raise AssertionError(f"TR connection attempted: tr.{name}()") + + self.tr = NoConnection() + + monkeypatch.setattr(tl_module.Timeline, "__init__", patched_init) + + tl = tl_module.Timeline( + tr=None, + output_path=tmp_path, + store_event_database=False, + load_event_database=ALL_EVENTS_FILE, + ) + asyncio.run(tl.tl_loop()) + + assert not connection_attempted, f"TR was contacted via: {connection_attempted}" + + +def test_all_events_loaded(tmp_path): + """All 5 events from the file are loaded into tl.events.""" + events = load_events(tmp_path) + assert len(events) == 5 + + +def test_events_sorted_by_timestamp(tmp_path): + """Events are returned in chronological order.""" + events = load_events(tmp_path) + timestamps = [datetime.fromisoformat(e["timestamp"][:19]) for e in events] + assert timestamps == sorted(timestamps) + + +def test_no_database_written(tmp_path): + """No all_events.json is written to output_dir when loading from an external file.""" + load_events(tmp_path) + assert not (tmp_path / "all_events.json").exists() + + +def test_csv_row_count(tmp_path): + """CSV contains at least one row per event.""" + rows = export_csv(load_events(tmp_path)) + assert len(rows) >= 5 + + +def test_csv_transaction_types(tmp_path): + """CSV contains the expected transaction types for all 5 event kinds.""" + rows = export_csv(load_events(tmp_path)) + types = {r["Typ"] for r in rows} + assert "Kauf" in types + assert "Verkauf" in types + assert "Dividende" in types + assert "Einlage" in types + + +def test_csv_buy_row(tmp_path): + """BUY row has correct ISIN, shares, value and fees.""" + rows = export_csv(load_events(tmp_path)) + buy = next(r for r in rows if r["Typ"] == "Kauf") + assert buy["ISIN"] == "IE00B4K6B022" + assert float(buy["Stück"].replace(",", ".")) == 60.0 + assert float(buy["Wert"].replace(",", ".")) == -3002.8 + assert float(buy["Gebühren"].replace(",", ".")) == 1.0 + + +def test_csv_sell_row(tmp_path): + """SELL row has correct ISIN, shares, value, fees and taxes.""" + rows = export_csv(load_events(tmp_path)) + sell = next(r for r in rows if r["Typ"] == "Verkauf") + assert sell["ISIN"] == "US26740W1099" + assert float(sell["Stück"].replace(",", ".")) == 17.0 + assert float(sell["Wert"].replace(",", ".")) == 94.76 + assert float(sell["Gebühren"].replace(",", ".")) == 1.0 + assert float(sell["Steuern"].replace(",", ".")) == 3.18 + + +def test_csv_dividend_row(tmp_path): + """DIVIDEND row has correct ISIN, shares, value and taxes.""" + rows = export_csv(load_events(tmp_path)) + div = next(r for r in rows if r["Typ"] == "Dividende") + assert div["ISIN"] == "US20030N1019" + assert float(div["Wert"].replace(",", ".")) == 2.24 + assert float(div["Steuern"].replace(",", ".")) == 0.78 + + +def test_csv_deposit_row(tmp_path): + """DEPOSIT row has correct value.""" + rows = export_csv(load_events(tmp_path)) + deposit = next(r for r in rows if r["Typ"] == "Einlage") + assert float(deposit["Wert"].replace(",", ".")) == 200.0 + + +def test_cli_golden(tmp_path): + """CLI output matches the golden CSV exactly.""" + out_file = tmp_path / "account_transactions.csv" + result = subprocess.run( + [ + sys.executable, + "-m", + "pytr", + "export_transactions", + "--load-event-database", + str(ALL_EVENTS_FILE), + "-l", + "de", + "--decimal-localization", + "-s", + str(out_file), + ], + capture_output=True, + text=True, + ) + assert result.returncode == 0, f"pytr exited with {result.returncode}:\n{result.stderr}" + actual = out_file.read_text(encoding="utf-8") + expected = GOLDEN_CSV.read_text(encoding="utf-8") + assert actual == expected + + +# --------------------------------------------------------------------------- +# Timestamp / cutoff filtering tests +# +# Event timestamps in all_events_test.json (all UTC): +# buy 2024-02-20T16:32:07 +# deposit 2024-06-03T17:07:26 +# split 2024-06-26T08:06:40 +# sell 2025-03-14T07:03:14 +# dividend 2025-10-23T14:19:56 +# --------------------------------------------------------------------------- + +UTC = timezone.utc + + +def _ts(iso_utc: str) -> float: + """Parse an ISO string with explicit UTC offset to a POSIX timestamp.""" + return datetime.fromisoformat(iso_utc).timestamp() + + +def load_events_filtered(output_dir, not_before=0.0, not_after=float("inf")): + tl = Timeline( + tr=None, + output_path=output_dir, + store_event_database=False, + load_event_database=ALL_EVENTS_FILE, + not_before=not_before, + not_after=not_after, + ) + asyncio.run(tl.tl_loop()) + return tl.events + + +def event_ids(events): + return {e["id"] for e in events} + + +def test_not_before_utc_excludes_early_events(tmp_path): + """not_before after deposit cuts buy and deposit, keeps split/sell/dividend.""" + # 2024-06-03T18:00:00Z is after deposit (17:07 UTC) and buy (Feb) + not_before = _ts("2024-06-03T18:00:00+00:00") + events = load_events_filtered(tmp_path, not_before=not_before) + ids = event_ids(events) + assert "12345678" not in ids # buy (2024-02-20) + assert "deposit-001" not in ids # deposit (2024-06-03 17:07) + assert "e230be28-286a-31b6-879f-5c97f8a9d85a" in ids # split + assert "5b0f491f-7bad-40b1-8cd1-56d83729afd4" in ids # sell + assert "88008da6-da94-3e0e-8ea5-e3878643f5ab" in ids # dividend + + +def test_not_after_utc_excludes_late_events(tmp_path): + """not_after before 2025 cuts sell and dividend, keeps buy/deposit/split.""" + not_after = _ts("2025-01-01T00:00:00+00:00") + events = load_events_filtered(tmp_path, not_after=not_after) + ids = event_ids(events) + assert "12345678" in ids # buy + assert "deposit-001" in ids # deposit + assert "e230be28-286a-31b6-879f-5c97f8a9d85a" in ids # split + assert "5b0f491f-7bad-40b1-8cd1-56d83729afd4" not in ids # sell (2025) + assert "88008da6-da94-3e0e-8ea5-e3878643f5ab" not in ids # dividend (2025) + + +def test_not_before_and_not_after_bracket(tmp_path): + """Bracket to 2024 only: buy, deposit, split in; sell, dividend out.""" + not_before = _ts("2024-01-01T00:00:00+00:00") + not_after = _ts("2024-12-31T23:59:59+00:00") + events = load_events_filtered(tmp_path, not_before=not_before, not_after=not_after) + ids = event_ids(events) + assert "12345678" in ids # buy + assert "deposit-001" in ids # deposit + assert "e230be28-286a-31b6-879f-5c97f8a9d85a" in ids # split + assert "5b0f491f-7bad-40b1-8cd1-56d83729afd4" not in ids # sell + assert "88008da6-da94-3e0e-8ea5-e3878643f5ab" not in ids # dividend + + +def test_last_days_cutoff(tmp_path): + """last_days computed the same way main.py does: cuts old events, keeps recent ones. + + The newest event is dividend at 2025-10-23. We pick last_days so that the + cutoff falls between the sell (2025-03-14) and dividend (2025-10-23), i.e. + relative to 'now' we keep only the dividend. We calculate not_before the + same way main.py does to stay timezone-independent. + """ + # Anchor: dividend is at 2025-10-23T14:19:56 UTC. + # We want not_before to land between sell (2025-03-14) and dividend (2025-10-23). + # Use a fixed reference: 2026-10-12 (today) minus 400 days → 2025-09-07, which is + # after sell but before dividend. + reference_now = datetime(2026, 10, 12, tzinfo=UTC) + not_before = (reference_now - timedelta(days=400)).timestamp() + + events = load_events_filtered(tmp_path, not_before=not_before) + ids = event_ids(events) + assert "88008da6-da94-3e0e-8ea5-e3878643f5ab" in ids # dividend (2025-10-23, after cutoff) + assert "5b0f491f-7bad-40b1-8cd1-56d83729afd4" not in ids # sell (2025-03-14, before cutoff) + assert "12345678" not in ids # buy (2024, before cutoff) + + +def test_from_timestamp_naive_vs_utc_offset(tmp_path): + """A naive ISO string (local time) and the same instant as +HH:MM produce the same POSIX value. + + This mirrors the main.py conversion: datetime.fromisoformat(s).astimezone().timestamp() + We pick a UTC instant, convert to local time for the naive string, and assert both paths + give the same POSIX timestamp. + """ + utc_instant = datetime(2025, 3, 14, 7, 3, 14, tzinfo=UTC) + posix_utc = utc_instant.timestamp() + + # Path 1: explicit UTC offset string (as a user would pass --from_timestamp 2025-03-14T07:03:14+00:00) + from_utc_str = "2025-03-14T07:03:14+00:00" + posix_from_utc = datetime.fromisoformat(from_utc_str).astimezone().timestamp() + assert posix_from_utc == posix_utc + + # Path 2: naive local-time string (user passes local clock reading of the same instant) + local_dt = utc_instant.astimezone() # convert to local TZ + naive_local_str = local_dt.strftime("%Y-%m-%dT%H:%M:%S") # drop tzinfo, as a user would type + posix_from_naive = datetime.fromisoformat(naive_local_str).astimezone().timestamp() + assert posix_from_naive == posix_utc diff --git a/tests/verkaufsorder.json b/tests/verkaufsorder.json deleted file mode 100644 index a2f5c024..00000000 --- a/tests/verkaufsorder.json +++ /dev/null @@ -1,250 +0,0 @@ - { - "id": "986af7e0-f0c1-4fac-8d24-b334ce51275a", - "timestamp": "2025-05-12T18:38:36.065+0000", - "title": "Tencent Holdings (ADR)", - "icon": "logos/US88032Q1094/v2", - "avatar": { - "asset": "logos/US88032Q1094/v2", - "badge": null - }, - "badge": null, - "subtitle": "Verkaufsorder", - "amount": { - "currency": "EUR", - "value": 200.93, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "986af7e0-f0c1-4fac-8d24-b334ce51275a" - }, - "eventType": "trading_trade_executed", - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "986af7e0-f0c1-4fac-8d24-b334ce51275a", - "sections": [ - { - "title": "Du hast 200,93 € erhalten", - "data": { - "icon": "logos/US88032Q1094/v2", - "timestamp": "2025-05-12T18:38:36.065535045Z", - "status": "executed" - }, - "action": { - "payload": "US88032Q1094", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verkaufen", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Tencent Holdings (ADR)", - "displayValue": { - "text": "Tencent Holdings (ADR)" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "3,454506 × 58,50 €", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "3,454506", - "displayValue": { - "text": "3,454506" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "58,50 €", - "displayValue": { - "text": "58,50 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "202,09 €", - "displayValue": { - "text": "202,09 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "58,50 €", - "prefix": "3,454506 × " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,16 €", - "displayValue": { - "text": "0,16 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gebühr", - "detail": { - "text": "1,00 €", - "displayValue": { - "text": "1,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "200,93 €", - "displayValue": { - "text": "200,93 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "0,31 %", - "trend": "positive", - "displayValue": { - "text": "0,31 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gewinn", - "detail": { - "text": "0,62 €", - "trend": "positive", - "displayValue": { - "text": "0,62 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Kosteninformation 1", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "8b7b76a5-32f6-4243-ae06-d0002bc549d4", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Kosteninformation 2", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "cbb6b836-d19a-4760-88a5-b33ec707431c", - "postboxType": "EQUITIES_SELL_EX_ANTE" - }, - { - "title": "Abrechnung 1", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4b15144e-0886-4114-9d01-d95f064f950d", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Abrechnung 2", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "74f4790f-2f36-484f-ba06-7d4df50f1f32", - "postboxType": "SECURITIES_SETTLEMENT" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/verkaufsorder_no_eventType.json b/tests/verkaufsorder_no_eventType.json deleted file mode 100644 index d96f5d59..00000000 --- a/tests/verkaufsorder_no_eventType.json +++ /dev/null @@ -1,259 +0,0 @@ -{ - "id": "c082a8d2-8816-4d33-829b-6cb78584df34", - "timestamp": "2025-11-04T16:27:25.185+0000", - "title": "Home Depot", - "icon": "logos/US4370761029/v2", - "avatar": { - "asset": "logos/US4370761029/v2", - "badge": null - }, - "badge": null, - "subtitle": "Verkaufsorder", - "amount": { - "currency": "EUR", - "value": 100.0, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "c082a8d2-8816-4d33-829b-6cb78584df34" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "c082a8d2-8816-4d33-829b-6cb78584df34", - "sections": [ - { - "title": "Du hast 100,00\u00a0\u20ac erhalten", - "data": { - "icon": "logos/US4370761029/v2", - "timestamp": "2025-11-04T16:27:25.185Z", - "status": "executed" - }, - "action": { - "payload": "US4370761029", - "type": "instrumentDetail" - }, - "type": "header" - }, - { - "title": "\u00dcbersicht", - "data": [ - { - "title": "Portfolio", - "detail": { - "text": "Brokerage", - "displayValue": { - "text": "Brokerage" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verkaufen", - "detail": { - "text": "Ausgef\u00fchrt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Home Depot", - "displayValue": { - "text": "Home Depot" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Transaktion", - "detail": { - "text": "0,305182 \u00d7 330,95\u00a0\u20ac", - "action": { - "payload": { - "id": "00000000-0000-0000-0000-000000000000", - "sections": [ - { - "title": "Transaktion", - "type": "title" - }, - { - "data": [ - { - "title": "Aktien", - "detail": { - "text": "0,305182", - "displayValue": { - "text": "0,305182" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktienkurs", - "detail": { - "text": "330,95\u00a0\u20ac", - "displayValue": { - "text": "330,95\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "101,00\u00a0\u20ac", - "displayValue": { - "text": "101,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - }, - "type": "infoPage" - }, - "displayValue": { - "text": "330,95\u00a0\u20ac", - "prefix": "0,305182 \u00d7 " - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,00\u00a0\u20ac", - "displayValue": { - "text": "0,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Geb\u00fchr", - "detail": { - "text": "1,00\u00a0\u20ac", - "displayValue": { - "text": "1,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Summe", - "detail": { - "text": "100,00\u00a0\u20ac", - "displayValue": { - "text": "100,00\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Performance", - "data": [ - { - "title": "Rendite", - "detail": { - "text": "19,22 %", - "trend": "negative", - "displayValue": { - "text": "19,22 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Verlust", - "detail": { - "text": "-16,12\u00a0\u20ac", - "trend": "negative", - "displayValue": { - "text": "-16,12\u00a0\u20ac" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "horizontalTable" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "b5d0cd84-ed10-4e52-9582-61b313e45593", - "postboxType": "SECURITIES_SETTLEMENT" - }, - { - "title": "Kosteninformation", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "df64bd22-637b-4d24-b201-eafa7bc6a2d1", - "postboxType": "EQUITIES_SELL_EX_ANTE" - } - ], - "type": "documents" - }, - { - "title": "", - "data": [ - { - "title": "", - "detail": { - "icon": "", - "action": { - "payload": { - "contextCategory": "NHC", - "contextParams": { - "chat_flow_key": "NHC_0029_wealth_buying_selling_past_trade_execution", - "timelineEventId": "c082a8d2-8816-4d33-829b-6cb78584df34", - "instrumentType": "stock", - "instrumentId": "US4370761029", - "groupId": "c082a8d2-8816-4d33-829b-6cb78584df34" - } - }, - "type": "customerSupportChat" - }, - "style": "highlighted", - "type": "listItemAvatarDefault" - }, - "style": "plain" - } - ], - "type": "table" - } - ] - } -} diff --git a/tests/vorabpauschale.json b/tests/vorabpauschale.json deleted file mode 100644 index c09779d7..00000000 --- a/tests/vorabpauschale.json +++ /dev/null @@ -1,134 +0,0 @@ -{ - "id": "574bc726-c7c2-3439-9708-1801f30259c0", - "timestamp": "2025-01-28T14:54:28.155+0000", - "title": "MSCI China USD (Acc)", - "icon": "logos/IE00BJ5JPG56/v2", - "avatar": { - "asset": "logos/IE00BJ5JPG56/v2", - "badge": null - }, - "badge": null, - "subtitle": "Vorabpauschale", - "amount": { - "currency": "EUR", - "value": -0.19, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "574bc726-c7c2-3439-9708-1801f30259c0" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "574bc726-c7c2-3439-9708-1801f30259c0", - "sections": [ - { - "title": "Du hast -0,19 € bezahlt", - "data": { - "icon": "logos/IE00BJ5JPG56/v2", - "timestamp": "2025-01-28T14:54:28.155Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Vorabpauschale", - "displayValue": { - "text": "Vorabpauschale" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "MSCI China USD (Acc)", - "displayValue": { - "text": "MSCI China USD (Acc)" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-0,19 €", - "displayValue": { - "text": "-0,19 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-0,19 €", - "displayValue": { - "text": "-0,19 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Vorabpauschale", - "detail": "28.02.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4e227b8e-63c5-49a1-8e0b-adf8aaa6b81a", - "postboxType": "CA_VOPA_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/vorabpauschale_no_eventType.json b/tests/vorabpauschale_no_eventType.json deleted file mode 100644 index f583fb54..00000000 --- a/tests/vorabpauschale_no_eventType.json +++ /dev/null @@ -1,133 +0,0 @@ -{ - "id": "574bc726-c7c2-3439-9708-1801f30259c0", - "timestamp": "2025-01-28T14:54:28.155+0000", - "title": "MSCI China USD (Acc)", - "icon": "logos/IE00BJ5JPG56/v2", - "avatar": { - "asset": "logos/IE00BJ5JPG56/v2", - "badge": null - }, - "badge": null, - "subtitle": "Vorabpauschale", - "amount": { - "currency": "EUR", - "value": -0.19, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "574bc726-c7c2-3439-9708-1801f30259c0" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "574bc726-c7c2-3439-9708-1801f30259c0", - "sections": [ - { - "title": "Du hast -0,19 € bezahlt", - "data": { - "icon": "logos/IE00BJ5JPG56/v2", - "timestamp": "2025-01-28T14:54:28.155Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Vorabpauschale", - "displayValue": { - "text": "Vorabpauschale" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "MSCI China USD (Acc)", - "displayValue": { - "text": "MSCI China USD (Acc)" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bruttoertrag", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "-0,19 €", - "displayValue": { - "text": "-0,19 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-0,19 €", - "displayValue": { - "text": "-0,19 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Vorabpauschale", - "detail": "28.02.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "4e227b8e-63c5-49a1-8e0b-adf8aaa6b81a", - "postboxType": "CA_VOPA_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zinsen.json b/tests/zinsen.json deleted file mode 100644 index c8926342..00000000 --- a/tests/zinsen.json +++ /dev/null @@ -1,180 +0,0 @@ - { - "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", - "timestamp": "2025-07-01T06:46:37.846+0000", - "title": "Zinsen", - "icon": "logos/timeline_interest_new/v2", - "avatar": { - "asset": "logos/timeline_interest_new/v2", - "badge": null - }, - "badge": null, - "subtitle": "2 % p.a.", - "amount": { - "currency": "EUR", - "value": 4.87, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36" - }, - "eventType": "INTEREST_PAYOUT", - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", - "sections": [ - { - "title": "Du hast 4,87 € erhalten", - "data": { - "icon": "logos/timeline_interest_new/v2", - "timestamp": "2025-07-01T06:46:42.342175Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Durchschnittssaldo", - "detail": { - "text": "3.900,38 €", - "displayValue": { - "text": "3.900,38 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Jährliche Rate", - "detail": { - "text": "2.00 %", - "displayValue": { - "text": "2.00 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Cash", - "displayValue": { - "text": "Cash" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Status", - "steps": [ - { - "leading": { - "avatar": { - "status": "completed", - "type": "bullet" - }, - "connection": { - "order": "first" - } - }, - "content": { - "title": "Zinsberechnung", - "timestamp": "2025-07-01T06:46:42.342175Z" - } - }, - { - "leading": { - "avatar": { - "status": "completed", - "type": "bullet" - }, - "connection": { - "order": "last" - } - }, - "content": { - "title": "Zinszahlung", - "timestamp": "2025-07-01T06:46:42.342175Z" - } - } - ], - "type": "steps" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Angesammelt", - "detail": { - "text": "6,74 €", - "displayValue": { - "text": "6,74 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "1,87 €", - "displayValue": { - "text": "1,87 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "4,87 €", - "displayValue": { - "text": "4,87 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "3a982728-a476-44cd-bce9-aaa520b55f6f", - "postboxType": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zinsen_no_eventType.json b/tests/zinsen_no_eventType.json deleted file mode 100644 index bd114697..00000000 --- a/tests/zinsen_no_eventType.json +++ /dev/null @@ -1,179 +0,0 @@ - { - "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", - "timestamp": "2025-07-01T06:46:37.846+0000", - "title": "Zinsen", - "icon": "logos/timeline_interest_new/v2", - "avatar": { - "asset": "logos/timeline_interest_new/v2", - "badge": null - }, - "badge": null, - "subtitle": "2 % p.a.", - "amount": { - "currency": "EUR", - "value": 4.87, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36" - }, - "cashAccountNumber": null, - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "2d35c2c1-f231-4b5d-bee1-deae7e33bf36", - "sections": [ - { - "title": "Du hast 4,87 € erhalten", - "data": { - "icon": "logos/timeline_interest_new/v2", - "timestamp": "2025-07-01T06:46:42.342175Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Durchschnittssaldo", - "detail": { - "text": "3.900,38 €", - "displayValue": { - "text": "3.900,38 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Jährliche Rate", - "detail": { - "text": "2.00 %", - "displayValue": { - "text": "2.00 %" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Asset", - "detail": { - "text": "Cash", - "displayValue": { - "text": "Cash" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Status", - "steps": [ - { - "leading": { - "avatar": { - "status": "completed", - "type": "bullet" - }, - "connection": { - "order": "first" - } - }, - "content": { - "title": "Zinsberechnung", - "timestamp": "2025-07-01T06:46:42.342175Z" - } - }, - { - "leading": { - "avatar": { - "status": "completed", - "type": "bullet" - }, - "connection": { - "order": "last" - } - }, - "content": { - "title": "Zinszahlung", - "timestamp": "2025-07-01T06:46:42.342175Z" - } - } - ], - "type": "steps" - }, - { - "title": "Transaktion", - "data": [ - { - "title": "Angesammelt", - "detail": { - "text": "6,74 €", - "displayValue": { - "text": "6,74 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuern", - "detail": { - "text": "1,87 €", - "displayValue": { - "text": "1,87 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "4,87 €", - "displayValue": { - "text": "4,87 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokument", - "data": [ - { - "title": "Abrechnung", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "3a982728-a476-44cd-bce9-aaa520b55f6f", - "postboxType": "" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zusammenschluss.json b/tests/zusammenschluss.json deleted file mode 100644 index 79879a5e..00000000 --- a/tests/zusammenschluss.json +++ /dev/null @@ -1,113 +0,0 @@ -{ - "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", - "timestamp": "2025-05-29T13:04:58.676+0000", - "title": "Rocket Lab USA", - "icon": "logos/US7731221062/v2", - "subtitle": "Zusammenschluss", - "action": { - "type": "timelineDetail", - "payload": "1957e12e-a7f6-396c-97e4-5237b113c45a" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": "logos/US7731221062/v2", - "timestamp": "2025-05-29T13:04:58.676Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Zusammenschluss", - "displayValue": { - "text": "Zusammenschluss" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Rocket Lab USA", - "displayValue": { - "text": "Rocket Lab USA" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "5.943100", - "displayValue": { - "text": "5.943100" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ROCKET LAB CORP. O.N.", - "displayValue": { - "text": "ROCKET LAB CORP. O.N." - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "5.943100", - "displayValue": { - "text": "5.943100" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "29.05.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "86a172b6-39e7-4d8f-9637-24b4feed62c6", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zusammenschluss2.json b/tests/zusammenschluss2.json deleted file mode 100644 index 0d643655..00000000 --- a/tests/zusammenschluss2.json +++ /dev/null @@ -1,119 +0,0 @@ - { - "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", - "timestamp": "2025-05-29T13:04:58.676+0000", - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "icon": "logos/US7731221062/v2", - "subtitle": "Zusammenschluss", - "action": { - "type": "timelineDetail", - "payload": "1957e12e-a7f6-396c-97e4-5237b113c45a" - }, - "trailing": null, - "eventType": "SSP_CORPORATE_ACTION_ACTIVITY", - "hidden": false, - "deleted": false, - "source": "timelineActivity", - "details": { - "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": { - "asset": "logos/US7731221062/v2", - "badge": null - }, - "timestamp": "2025-05-29T13:04:58.676Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Zusammenschluss", - "displayValue": { - "text": "Zusammenschluss" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Rocket Lab USA", - "displayValue": { - "text": "Rocket Lab USA" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "5.943100", - "displayValue": { - "text": "5.943100" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ROCKET LAB CORP. O.N.", - "displayValue": { - "text": "ROCKET LAB CORP. O.N." - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "5.943100", - "displayValue": { - "text": "5.943100" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "29.05.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "86a172b6-39e7-4d8f-9637-24b4feed62c6", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} \ No newline at end of file diff --git a/tests/zusammenschluss_no_eventType.json b/tests/zusammenschluss_no_eventType.json deleted file mode 100644 index 95f4a1b3..00000000 --- a/tests/zusammenschluss_no_eventType.json +++ /dev/null @@ -1,112 +0,0 @@ -{ - "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", - "timestamp": "2025-05-29T13:04:58.676+0000", - "title": "Rocket Lab USA", - "icon": "logos/US7731221062/v2", - "subtitle": "Zusammenschluss", - "action": { - "type": "timelineDetail", - "payload": "1957e12e-a7f6-396c-97e4-5237b113c45a" - }, - "source": "timelineActivity", - "details": { - "id": "1957e12e-a7f6-396c-97e4-5237b113c45a", - "sections": [ - { - "title": "Deine Aktien waren von einer Kapitalmaßnahme betroffen", - "data": { - "icon": "logos/US7731221062/v2", - "timestamp": "2025-05-29T13:04:58.676Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Zusammenschluss", - "displayValue": { - "text": "Zusammenschluss" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Rocket Lab USA", - "displayValue": { - "text": "Rocket Lab USA" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "5.943100", - "displayValue": { - "text": "5.943100" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ROCKET LAB CORP. O.N.", - "displayValue": { - "text": "ROCKET LAB CORP. O.N." - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "5.943100", - "displayValue": { - "text": "5.943100" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "29.05.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "86a172b6-39e7-4d8f-9637-24b4feed62c6", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zwischenpapiere.json b/tests/zwischenpapiere.json deleted file mode 100644 index 6a5205b0..00000000 --- a/tests/zwischenpapiere.json +++ /dev/null @@ -1,167 +0,0 @@ -{ - "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", - "timestamp": "2025-10-21T07:39:39.830+0000", - "title": "ORSTED A/S -ANR-", - "icon": "logos/DK0064307839/v2", - "avatar": { - "asset": "logos/DK0064307839/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aufruf von Zwischenpapieren", - "amount": { - "currency": "EUR", - "value": -151.59, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497" - }, - "eventType": "ssp_corporate_action_invoice_cash", - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", - "sections": [ - { - "title": "Du hast -151,59 € bezahlt", - "data": { - "icon": "logos/DK0064307839/v2", - "timestamp": "2025-10-21T07:39:39.83Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aufruf von Zwischenpapieren", - "displayValue": { - "text": "Aufruf von Zwischenpapieren" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S -ANR-", - "displayValue": { - "text": "ORSTED A/S -ANR-" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "119.000000", - "displayValue": { - "text": "119.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S EM.09/25 DK 10", - "displayValue": { - "text": "ORSTED A/S EM.09/25 DK 10" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "17.000000", - "displayValue": { - "text": "17.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bezugspreis", - "detail": { - "text": "-151,59 €", - "displayValue": { - "text": "-151,59 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-151,59 €", - "displayValue": { - "text": "-151,59 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "21.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "bab90597-6a6a-4925-ac20-51d7dd4eea04", - "postboxType": "CA_INCOME_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zwischenpapiere2.json b/tests/zwischenpapiere2.json deleted file mode 100644 index 776e1d61..00000000 --- a/tests/zwischenpapiere2.json +++ /dev/null @@ -1,170 +0,0 @@ - { - "id": "6e123939-427f-3a4b-ba6a-ea4621ec4287", - "timestamp": "2026-04-03T09:37:06.806+0000", - "title": "WORLDLINE S.A. ANR", - "icon": "logos/FR0014015MS9/v2", - "avatar": { - "asset": "logos/FR0014015MS9/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aufruf von Zwischenpapieren", - "amount": { - "currency": "EUR", - "value": -1.21, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "6e123939-427f-3a4b-ba6a-ea4621ec4287" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "eventType": "SSP_CORPORATE_ACTION_CASH_AND_STOCK", - "source": "timelineTransaction", - "details": { - "id": "6e123939-427f-3a4b-ba6a-ea4621ec4287", - "sections": [ - { - "title": "Du hast 1,21 € bezahlt", - "data": { - "icon": { - "asset": "logos/FR0014015MS9/v2", - "badge": null - }, - "timestamp": "2026-04-03T09:37:06.806Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aufruf von Zwischenpapieren", - "displayValue": { - "text": "Aufruf von Zwischenpapieren" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "WORLDLINE S.A. ANR", - "displayValue": { - "text": "WORLDLINE S.A. ANR" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "1.000000", - "displayValue": { - "text": "1.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Worldline", - "displayValue": { - "text": "Worldline" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "6.000000", - "displayValue": { - "text": "6.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bezugspreis", - "detail": { - "text": "-1,21 €", - "displayValue": { - "text": "-1,21 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-1,21 €", - "displayValue": { - "text": "-1,21 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "03.04.2026", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "a3753865-4171-46f8-95b1-c31d2f67ac3c", - "postboxType": "CA_INCOME_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zwischenpapiere3.json b/tests/zwischenpapiere3.json deleted file mode 100644 index 1f8a80b0..00000000 --- a/tests/zwischenpapiere3.json +++ /dev/null @@ -1,159 +0,0 @@ - { - "id": "85b193b7-37d0-3850-8ab4-3f4a5c49efa7", - "timestamp": "2026-04-03T10:38:58.939+0000", - "title": "WORLDLINE S.A. ANR", - "icon": "logos/FR0014015MS9/v2", - "avatar": { - "asset": "logos/FR0014015MS9/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aufruf von Zwischenpapieren", - "amount": { - "currency": "EUR", - "value": -261.39, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "85b193b7-37d0-3850-8ab4-3f4a5c49efa7" - }, - "cashAccountNumber": "123456789", - "hidden": false, - "deleted": false, - "eventType": "SSP_CORPORATE_ACTION_CASH_AND_STOCK", - "source": "timelineTransaction", - "details": { - "id": "85b193b7-37d0-3850-8ab4-3f4a5c49efa7", - "sections": [ - { - "title": "Du hast 261,39 € bezahlt", - "data": { - "icon": { - "asset": "logos/FR0014015MS9/v2", - "badge": null - }, - "timestamp": "2026-04-03T10:38:58.939Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aufruf von Zwischenpapieren", - "displayValue": { - "text": "Aufruf von Zwischenpapieren" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "WORLDLINE S.A. ANR", - "displayValue": { - "text": "WORLDLINE S.A. ANR" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "Worldline", - "displayValue": { - "text": "Worldline" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "1294.000000", - "displayValue": { - "text": "1294.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bezugspreis", - "detail": { - "text": "-261,39 €", - "displayValue": { - "text": "-261,39 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-261,39 €", - "displayValue": { - "text": "-261,39 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "03.04.2026", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "77ac06a1-260f-472b-ae42-83eec5ec679a", - "postboxType": "CA_INCOME_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} \ No newline at end of file diff --git a/tests/zwischenpapiere_no_eventType.json b/tests/zwischenpapiere_no_eventType.json deleted file mode 100644 index 6ef7a7cb..00000000 --- a/tests/zwischenpapiere_no_eventType.json +++ /dev/null @@ -1,166 +0,0 @@ -{ - "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", - "timestamp": "2025-10-21T07:39:39.830+0000", - "title": "ORSTED A/S -ANR-", - "icon": "logos/DK0064307839/v2", - "avatar": { - "asset": "logos/DK0064307839/v2", - "badge": null - }, - "badge": null, - "subtitle": "Aufruf von Zwischenpapieren", - "amount": { - "currency": "EUR", - "value": -151.59, - "fractionDigits": 2 - }, - "subAmount": null, - "status": "EXECUTED", - "action": { - "type": "timelineDetail", - "payload": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497" - }, - "cashAccountNumber": "", - "hidden": false, - "deleted": false, - "source": "timelineTransaction", - "details": { - "id": "f2b4bb94-b1dd-37ef-880e-1f3714b3b497", - "sections": [ - { - "title": "Du hast -151,59 € bezahlt", - "data": { - "icon": "logos/DK0064307839/v2", - "timestamp": "2025-10-21T07:39:39.83Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Event", - "detail": { - "text": "Aufruf von Zwischenpapieren", - "displayValue": { - "text": "Aufruf von Zwischenpapieren" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S -ANR-", - "displayValue": { - "text": "ORSTED A/S -ANR-" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien entfernt", - "detail": { - "text": "119.000000", - "displayValue": { - "text": "119.000000" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S EM.09/25 DK 10", - "displayValue": { - "text": "ORSTED A/S EM.09/25 DK 10" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "17.000000", - "displayValue": { - "text": "17.000000" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Geschäft", - "data": [ - { - "title": "Bezugspreis", - "detail": { - "text": "-151,59 €", - "displayValue": { - "text": "-151,59 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Steuer", - "detail": { - "text": "0,00 €", - "displayValue": { - "text": "0,00 €" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Gesamt", - "detail": { - "text": "-151,59 €", - "displayValue": { - "text": "-151,59 €" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "21.10.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "bab90597-6a6a-4925-ac20-51d7dd4eea04", - "postboxType": "CA_INCOME_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zwischenvertrieb.json b/tests/zwischenvertrieb.json deleted file mode 100644 index b1e1fb3e..00000000 --- a/tests/zwischenvertrieb.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", - "timestamp": "2025-09-19T12:02:49.989+0000", - "title": "Orsted", - "icon": "logos/DK0060094928/v2", - "subtitle": "Zwischenvertrieb von Wertpapieren", - "action": { - "type": "timelineDetail", - "payload": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402" - }, - "eventType": "ssp_corporate_action_invoice_shares", - "source": "timelineActivity", - "details": { - "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/DK0060094928/v2", - "timestamp": "2025-09-19T12:02:49.989Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Zwischenvertrieb von Wertpapieren", - "displayValue": { - "text": "Zwischenvertrieb von Wertpapieren" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S -ANR-", - "displayValue": { - "text": "ORSTED A/S -ANR-" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "119.285835", - "displayValue": { - "text": "119.285835" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "19.09.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "aebaf075-9a89-4d0d-836a-be61e4ad7725", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -} diff --git a/tests/zwischenvertrieb2.json b/tests/zwischenvertrieb2.json deleted file mode 100644 index 22b88726..00000000 --- a/tests/zwischenvertrieb2.json +++ /dev/null @@ -1,83 +0,0 @@ -{ - "id": "11eb2e1f-e50c-3bb3-900d-d03028fed19d", - "timestamp": "2026-03-17T10:45:33.497+0000", - "title": "Worldline", - "icon": "logos/FR0011981968/v2", - "subtitle": "Zwischenvertrieb von Wertpapieren", - "action": { - "type": "timelineDetail", - "payload": "11eb2e1f-e50c-3bb3-900d-d03028fed19d" - }, - "eventType": "SSP_CORPORATE_ACTION_NO_CASH", - "hidden": false, - "deleted": false, - "source": "timelineActivity", - "details": { - "id": "11eb2e1f-e50c-3bb3-900d-d03028fed19d", - "sections": [ - { - "type": "header", - "title": "You received shares", - "data": { - "status": "executed", - "icon": "logos/FR0011981968/v2", - "timestamp": "2026-03-17T10:45:33.497510Z" - } - }, - { - "type": "table", - "title": "Overview", - "data": [ - { - "title": "Status", - "style": "plain", - "detail": { - "type": "status", - "text": "Completed", - "functionalStyle": "EXECUTED" - } - }, - { - "title": "Event", - "style": "plain", - "detail": { - "type": "text", - "text": "Intermediate securities distribution" - } - }, - { - "title": "Asset", - "style": "plain", - "detail": { - "type": "text", - "text": "Worldline" - } - }, - { - "title": "Shares", - "style": "plain", - "detail": { - "type": "text", - "text": "1.299376" - } - } - ] - }, - { - "type": "documents", - "title": "Documents", - "data": [ - { - "id": "17d6cca1-9c15-4817-b865-fc119780e7ae", - "title": "Intermediate securities distribution", - "action": { - "type": "browserModal", - "payload": "" - }, - "postboxType": "INTERMEDIATE_SECURITIES_DISTRIBUTION" - } - ] - } - ] - } -} diff --git a/tests/zwischenvertrieb_no_eventType.json b/tests/zwischenvertrieb_no_eventType.json deleted file mode 100644 index dfe0fa29..00000000 --- a/tests/zwischenvertrieb_no_eventType.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", - "timestamp": "2025-09-19T12:02:49.989+0000", - "title": "Orsted", - "icon": "logos/DK0060094928/v2", - "subtitle": "Zwischenvertrieb von Wertpapieren", - "action": { - "type": "timelineDetail", - "payload": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402" - }, - "source": "timelineActivity", - "details": { - "id": "79d5c1c7-cfa7-36a0-b4d9-8bf202490402", - "sections": [ - { - "title": "Du hast Aktien aus einer Kapitalmaßnahme erhalten\n", - "data": { - "icon": "logos/DK0060094928/v2", - "timestamp": "2025-09-19T12:02:49.989Z", - "status": "executed" - }, - "type": "header" - }, - { - "title": "Übersicht", - "data": [ - { - "title": "Status", - "detail": { - "text": "Ausgeführt", - "functionalStyle": "EXECUTED", - "type": "status" - }, - "style": "plain" - }, - { - "title": "Orderart", - "detail": { - "text": "Zwischenvertrieb von Wertpapieren", - "displayValue": { - "text": "Zwischenvertrieb von Wertpapieren" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Wertpapier", - "detail": { - "text": "ORSTED A/S -ANR-", - "displayValue": { - "text": "ORSTED A/S -ANR-" - }, - "type": "text" - }, - "style": "plain" - }, - { - "title": "Aktien hinzugefügt", - "detail": { - "text": "119.285835", - "displayValue": { - "text": "119.285835" - }, - "type": "text" - }, - "style": "plain" - } - ], - "type": "table" - }, - { - "title": "Dokumente", - "data": [ - { - "title": "Dokumente", - "detail": "19.09.2025", - "action": { - "payload": "", - "type": "browserModal" - }, - "id": "aebaf075-9a89-4d0d-836a-be61e4ad7725", - "postboxType": "CA_SECURITIES_INVOICE" - } - ], - "type": "documents" - } - ] - } -}