Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions pytr/event.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,8 @@ class PPEventType(EventType):
"GESH_CORPORATE_ACTION",
"INPAYMENTS_SEPA_MANDATE_CREATED",
"INSTRUCTION_CORPORATE_ACTION",
"IPO_SUBSCRIPTION_CANCELLED",
"IPO_SUBSCRIPTION_CREATED",
"JUNIOR_ONBOARDING_GUARDIAN_B_CONSENT",
"MATURITY",
"NEW_TR_IBAN",
Expand Down
165 changes: 165 additions & 0 deletions tests/events/ipo-anthropic-cancelled.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,165 @@
{
"id": "1ef4d656-f308-467f-a132-32b346165860",
"timestamp": "2026-11-11T15:32:39.667+0000",
"title": "Anthropic",
"icon": "logos/US03703U1079/v2",
"avatar": {
"asset": "logos/US03703U1079/v2",
"badge": null
},
"badge": null,
"subtitle": "Kauforder",
"amount": {
"currency": "EUR",
"value": -10.0,
"fractionDigits": 2
},
"subAmount": null,
"status": "CANCELED",
"action": {
"type": "timelineDetail",
"payload": "1ef4d656-f308-467f-a132-32b346165860"
},
"cashAccountNumber": "123456789",
"hidden": false,
"deleted": false,
"eventType": "IPO_SUBSCRIPTION_CANCELLED",
"actor": null,
"presentation": {
"leading": {
"type": "avatar",
"icon": "logos/US03703U1079/v2"
},
"content": {
"type": "default",
"title": "Anthropic",
"subtitle": "11 Nov. • Kauforder"
},
"trailing": {
"type": "value",
"title": "10,00 €",
"titleColor": "default",
"strikethrough": true,
"titleDataSensitivity": "SENSITIVE"
},
"action": {
"type": "timelineDetail",
"payload": "1ef4d656-f308-467f-a132-32b346165860"
},
"type": "listItem"
},
"source": "timelineTransaction",
"details": {
"id": "1ef4d656-f308-467f-a132-32b346165860",
"sections": [
{
"title": "Du hast 10,00 € investiert",
"data": {
"icon": {
"asset": "logos/US03703U1079/v2",
"badge": null
},
"subtitleText": "11 Nov. · 15:32",
"status": "canceled"
},
"action": {
"payload": "US03703U1079",
"type": "instrumentDetail"
},
"type": "header"
},
{
"title": "Abonnement gekündigt",
"description": "Das Abo wurde gekündigt und du hast den vollständigen Abobetrag in Höhe von 10,00 € zurückerhalten.",
"type": "banner"
},
{
"title": "Übersicht",
"data": [
{
"title": "IPO",
"detail": {
"text": "Storniert",
"functionalStyle": "CANCELED",
"type": "status"
},
"style": "plain"
},
{
"title": "Asset",
"detail": {
"text": "Anthropic",
"displayValue": {
"text": "Anthropic",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
},
{
"title": "Transaktion",
"detail": {
"text": "9,00 €",
"displayValue": {
"text": "9,00 €",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
},
{
"title": "Gebühr",
"detail": {
"text": "1,00 €",
"displayValue": {
"text": "1,00 €",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
},
{
"title": "Summe",
"detail": {
"text": "10,00 €",
"displayValue": {
"text": "10,00 €",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
}
],
"type": "table"
},
{
"title": "Dokumente",
"data": [
{
"title": "Kosteninformation",
"action": {
"payload": "https://example.com/document.pdf",
"type": "browserModal"
},
"id": "80d2c90d-5cba-4327-801c-41f03a4236e3",
"postboxType": "EQUITIES_BUY_EX_ANTE"
},
{
"title": "Prospekt",
"action": {
"payload": "https://assets.traderepublic.com/assets/files/TR_EU_Prospectus_3xkgCuxPiZw.pdf",
"type": "browserModal"
},
"id": "4b3b1e09-fd8d-38d7-9291-00de9b6a2cd1",
"postboxType": ""
}
],
"type": "documents"
}
]
}
}
165 changes: 165 additions & 0 deletions tests/events/ipo-anthropic-created.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,165 @@
{
"id": "c734b1d3-4a6c-435a-a3aa-e97bedbb6104",
"timestamp": "2026-11-18T07:42:22.017+0000",
"title": "Anthropic",
"icon": "logos/US03703U1079/v2",
"avatar": {
"asset": "logos/US03703U1079/v2",
"badge": null
},
"badge": null,
"subtitle": "Kauforder",
"amount": {
"currency": "EUR",
"value": -10.0,
"fractionDigits": 2
},
"subAmount": null,
"status": "EXECUTED",
"action": {
"type": "timelineDetail",
"payload": "c734b1d3-4a6c-435a-a3aa-e97bedbb6104"
},
"cashAccountNumber": "123456789",
"hidden": false,
"deleted": false,
"eventType": "IPO_SUBSCRIPTION_CREATED",
"actor": null,
"presentation": {
"leading": {
"type": "avatar",
"icon": "logos/US03703U1079/v2"
},
"content": {
"type": "default",
"title": "Anthropic",
"subtitle": "18 Nov. • Kauforder"
},
"trailing": {
"type": "value",
"title": "10,00 €",
"titleColor": "default",
"strikethrough": false,
"titleDataSensitivity": "SENSITIVE"
},
"action": {
"type": "timelineDetail",
"payload": "c734b1d3-4a6c-435a-a3aa-e97bedbb6104"
},
"type": "listItem"
},
"source": "timelineTransaction",
"details": {
"id": "c734b1d3-4a6c-435a-a3aa-e97bedbb6104",
"sections": [
{
"title": "Du hast 10,00 € investiert",
"data": {
"icon": {
"asset": "logos/US03703U1079/v2",
"badge": null
},
"subtitleText": "18 Nov. · 07:42",
"status": "executed"
},
"action": {
"payload": "US03703U1079",
"type": "instrumentDetail"
},
"type": "header"
},
{
"title": "Auftrag platziert",
"description": "Du erhältst Aktien im Wert von bis zu 9,00 €. Über die tatsächliche Zuteilung informieren wir dich am Tag des Börsengangs.",
"type": "banner"
},
{
"title": "Übersicht",
"data": [
{
"title": "IPO Zeichnung",
"detail": {
"text": "Erstellt",
"functionalStyle": "CREATED",
"type": "status"
},
"style": "plain"
},
{
"title": "Asset",
"detail": {
"text": "Anthropic",
"displayValue": {
"text": "Anthropic",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
},
{
"title": "Transaktion",
"detail": {
"text": "9,00 €",
"displayValue": {
"text": "9,00 €",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
},
{
"title": "Gebühr",
"detail": {
"text": "1,00 €",
"displayValue": {
"text": "1,00 €",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
},
{
"title": "Summe",
"detail": {
"text": "10,00 €",
"displayValue": {
"text": "10,00 €",
"textDataSensitivity": "PUBLIC"
},
"type": "text"
},
"style": "plain"
}
],
"type": "table"
},
{
"title": "Dokumente",
"data": [
{
"title": "Kosteninformation",
"action": {
"payload": "https://example.com/document.pdf",
"type": "browserModal"
},
"id": "1e1479aa-68de-4f49-bb0c-2a8053267cb4",
"postboxType": "EQUITIES_BUY_EX_ANTE"
},
{
"title": "Prospekt",
"action": {
"payload": "https://assets.traderepublic.com/assets/files/TR_EU_Prospectus_3xkgCuxPiZw.pdf",
"type": "browserModal"
},
"id": "4b3b1e09-fd8d-38d7-9291-00de9b6a2cd1",
"postboxType": ""
}
],
"type": "documents"
}
]
}
}
18 changes: 18 additions & 0 deletions tests/test_events.py
Original file line number Diff line number Diff line change
Expand Up @@ -876,6 +876,24 @@
}
],
},
{
"filename": "ipo-anthropic-cancelled.json",
"event_type": None,
"title": "Anthropic",
"isin": None,
"shares": None,
"value": None,
"transactions": [],
},
{
"filename": "ipo-anthropic-created.json",
"event_type": None,
"title": "Anthropic",
"isin": None,
"shares": None,
"value": None,
"transactions": [],
},
{
"filename": "junior_p2p_transfer.json",
"event_type": PPEventType.REMOVAL,
Expand Down
Loading