Finanzen-Insights-Automatisierung: Marktkapitalisierung-über-Bright-Data-zu-Telegram-versenden

Fortgeschritten

Dies ist ein Crypto Trading-Bereich Automatisierungsworkflow mit 14 Nodes. Hauptsächlich werden If, Code, Wait, Telegram, FormTrigger und andere Nodes verwendet. Verwenden Sie Bright Data, um Marktkapitalisierungsdaten von Yahoo Finance zu extrahieren und in Telegram zu visualisieren

Voraussetzungen
  • Telegram Bot Token
  • Möglicherweise sind Ziel-API-Anmeldedaten erforderlich
  • Google Sheets API-Anmeldedaten

Kategorie

Workflow-Vorschau
Visualisierung der Node-Verbindungen, mit Zoom und Pan
Workflow exportieren
Kopieren Sie die folgende JSON-Konfiguration und importieren Sie sie in n8n
{
  "id": "k2FvKOkV5UgBEnCu",
  "meta": {
    "instanceId": "bc8ca75c203589705ae2e446cad7181d6f2a7cc1766f958ef9f34810e53b8cb2"
  },
  "name": "Financial Insight Automation: Market Cap to Telegram via Bright Data",
  "tags": [],
  "nodes": [
    {
      "id": "7cebf294-ed28-4cce-935f-8182c953aa5d",
      "name": "🟩 Formular-Trigger",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        -1440,
        16
      ],
      "webhookId": "92772d3e-a1e1-4912-996a-7e799f129fb8",
      "parameters": {
        "options": {},
        "formTitle": "Yahoo",
        "formFields": {
          "values": [
            {
              "fieldLabel": "keyword"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "21b115c8-d3a7-4c6e-b3af-aab2e2c7f7d1",
      "name": "🚀 Trigger Scraping1 (HTTP Request to Bright Data)",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1184,
        16
      ],
      "parameters": {
        "url": "https://api.brightdata.com/datasets/v3/trigger",
        "method": "POST",
        "options": {},
        "jsonBody": "=[\n  {\n    \"keyword\": \"{{ $json.keyword }}\"\n  } \n]",
        "sendBody": true,
        "sendQuery": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "queryParameters": {
          "parameters": [
            {
              "name": "dataset_id",
              "value": "gd_lmrpz3vxmz972ghd7"
            },
            {
              "name": "include_errors",
              "value": "true"
            },
            {
              "name": "type",
              "value": "discover_new"
            },
            {
              "name": "discover_by",
              "value": "keyword"
            },
            {
              "name": "limit_per_input",
              "value": "2"
            }
          ]
        },
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer BRIGHT_DATA_API_KEY"
            }
          ]
        }
      },
      "typeVersion": 4.2,
      "alwaysOutputData": true
    },
    {
      "id": "75b8a695-9ad8-4d55-8cee-e6ebfda0defd",
      "name": "Haftnotiz",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1488,
        -144
      ],
      "parameters": {
        "color": 7,
        "width": 448,
        "height": 368,
        "content": "🟩 Form Trigger (On form submission1)\n➤ User form se keyword deta hai (e.g. \"AI\", \"Crypto\", \"MSFT\")\n\n🚀 Trigger Scraping1 (HTTP Request to Bright Data)\n➤ Bright Data API ko call karta hai:\n➤ discover_by: keyword, type: discover_new\n➤ Dataset ID: gd_lmrpz3vxmz972ghd7"
      },
      "typeVersion": 1
    },
    {
      "id": "db304f8b-91e1-4d33-acc9-0ba8351160da",
      "name": "🕐 Warte 1 Minute1",
      "type": "n8n-nodes-base.wait",
      "position": [
        -720,
        16
      ],
      "webhookId": "10b45556-5e91-4387-abd0-f9078b220286",
      "parameters": {
        "unit": "minutes",
        "amount": 1
      },
      "typeVersion": 1.1
    },
    {
      "id": "c0a0422f-a712-4be9-b46d-c35e6b5956ce",
      "name": "🟡 Lieferstatus von Snap ID1 prüfen",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -960,
        16
      ],
      "parameters": {
        "url": "=https://api.brightdata.com/datasets/v3/progress/{{ $json.snapshot_id }}",
        "options": {},
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer BRIGHT_DATA_API_KEY"
            }
          ]
        }
      },
      "typeVersion": 4.2,
      "alwaysOutputData": true
    },
    {
      "id": "a23cf845-6bff-4a40-a87f-5d0bac918acc",
      "name": "🟢 Endstatus prüfen",
      "type": "n8n-nodes-base.if",
      "position": [
        -480,
        16
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "35ed620d-b5d5-4e97-bcc5-52b283d85616",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.status }}",
              "rightValue": "ready"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "4d719ca5-ae7f-44b2-8b63-ed8a729ebbbb",
      "name": "🔽 final data given (Snapshot Fetch)",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -240,
        0
      ],
      "parameters": {
        "url": "=https://api.brightdata.com/datasets/v3/snapshot/{{ $json.snapshot_id }}",
        "options": {},
        "sendQuery": true,
        "sendHeaders": true,
        "queryParameters": {
          "parameters": [
            {
              "name": "format",
              "value": "json"
            }
          ]
        },
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer BRIGHT_DATA_API_KEY"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "6efc936b-cfa4-431f-81a0-fd6536bd3072",
      "name": "Haftnotiz1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1008,
        -240
      ],
      "parameters": {
        "color": 3,
        "width": 688,
        "height": 464,
        "content": "⏳ Zone 2: Monitor & Fetch Results\n(Sticky Name: ⏱️ Scraping Monitor & Result Pull)\n\nIncludes:\n\nWait Node – 1 minute delay for job completion\n\nStatus Check Node – Check if status == \"ready\"\n\nIF Node – Loop or continue\n\nSnapshot API – Pull final result"
      },
      "typeVersion": 1
    },
    {
      "id": "438a38f6-c401-4b75-94c6-e15992a97e76",
      "name": "📊 Gefilterte Ausgabe & In Tabelle speichern",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -16,
        0
      ],
      "parameters": {
        "columns": {
          "value": {
            "ask": "={{ $json.ask }}",
            "bid": "={{ $json.bid }}",
            "eps": "={{ $json.eps }}",
            "url": "={{ $json.url }}",
            "beta": "={{ $json.pe_ratio }}",
            "name": "={{ $json.name }}",
            "open": "={{ $json.open }}",
            "input": "={{ $json.input }}",
            "volume": "={{ $json.volume }}",
            "similar": "={{ $json.similar }}",
            "summary": "={{ $json.summary }}",
            "currency": "={{ $json.currency }}",
            "exchange": "={{ $json.exchange }}",
            "day_range": "={{ $json.day_range }}",
            "eps_trend": "={{ $json.eps_trend }}",
            "timestamp": "={{ $json.timestamp }}",
            "avg_volume": "={{ $json.avg_volume }}",
            "company_id": "={{ $json.company_id }}",
            "financials": "={{ $json.financials }}",
            "market_cap": "={{ $json.market_cap }}",
            "target_est": "={{ $json.target_est }}",
            "week_range": "={{ $json.week_range }}",
            "entity_type": "={{ $json.entity_type }}",
            "recent_news": "={{ $json.recent_news }}",
            "stock_ticker": "={{ $json.stock_ticker }}",
            "top_analysts": "={{ $json.top_analysts }}",
            "closing_price": "={{ $json.closing_price }}",
            "earnings_date": "={{ $json.earnings_date }}",
            "eps_revisions": "={{ $json.eps_revisions }}",
            "dividend_yield": "={{ $json.dividend_yield }}",
            "previous_close": "={{ $json.previous_close }}",
            "discovery_input": "={{ $json.discovery_input }}",
            "earnings_history": "={{ $json.earnings_history }}",
            "growth_estimates": "={{ $json.growth_estimates }}",
            "revenue_estimate": "={{ $json.revenue_estimate }}",
            "earnings_estimate": "={{ $json.earnings_estimate }}",
            "people_also_watch": "={{ $json.people_also_watch }}",
            "fanacials_currency": "={{ $json.fanacials_currency }}",
            "stock_market_index": "={{ $json.stock_market_index }}",
            "analyst_price_target": "={{ $json.analyst_price_target }}",
            "financials_quarterly": "={{ $json.financials_quarterly }}",
            "company_profile_phone": "={{ $json.company_profile_phone }}",
            "company_profile_sector": "={{ $json.company_profile_sector }}",
            "company_profile_address": "={{ $json.company_profile_address }}",
            "company_profile_website": "={{ $json.company_profile_website }}",
            "upgrades_and_downgrades": "={{ $json.upgrades_and_downgrades }}",
            "company_profile_industry": "={{ $json.company_profile_industry }}",
            "company_profile_employees": "={{ $json.company_profile_key_executives }}",
            "company_profile_description": "={{ $json.company_profile_description }}",
            "company_profile_key_executives": "={{ $json.company_profile_key_executives }}"
          },
          "schema": [
            {
              "id": "name",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": []
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/YOUR_SHEET_ID/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "url",
          "value": "=https://docs.google.com/spreadsheets/d/YOUR_SHEET_ID/edit?gid=0#gid=0"
        }
      },
      "credentials": {},
      "typeVersion": 4.6
    },
    {
      "id": "eb1997f3-3a09-417b-9ea6-86861ec5c1df",
      "name": "Haftnotiz2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -288,
        -256
      ],
      "parameters": {
        "color": 4,
        "width": 432,
        "height": 480,
        "content": "📊 Zone 3: Filter & Output\n(Sticky Name: 📊 Filtered Output & Save to Sheet)\n\nIncludes:\n\nOptional IF Node – Market Cap > $1B\n\nCode Node – Format complex arrays to human readable\n\nGoogle Sheets Node – Append data to final sheet\n\n"
      },
      "typeVersion": 1
    },
    {
      "id": "87619346-06ed-4311-a7e0-bcb82f554aca",
      "name": "🧮 Diagramm-Payload generieren",
      "type": "n8n-nodes-base.code",
      "position": [
        240,
        0
      ],
      "parameters": {
        "jsCode": "const itemsOut = [];\n\nconst labels = [];\nconst data = [];\n\nfor (const item of items) {\n  const name = item.json.name;\n  let cap = item.json.market_cap;\n  if (cap === undefined || cap === null) cap = \"0\";\n  cap = String(cap);\n\n  let value = 0;\n  if (cap.includes(\"T\")) value = parseFloat(cap) * 1e12;\n  else if (cap.includes(\"B\")) value = parseFloat(cap) * 1e9;\n  else if (cap.includes(\"M\")) value = parseFloat(cap) * 1e6;\n  else value = parseFloat(cap);\n\n  labels.push(name);\n  data.push(Math.round(value / 1e9));\n}\n\nconst chartPayload = {\n  type: 'bar',\n  data: {\n    labels,\n    datasets: [{\n      label: 'Market Cap (in Billion $)',\n      data,\n      backgroundColor: [\n        'rgba(75, 192, 192, 0.8)',\n        'rgba(153, 102, 255, 0.8)',\n        'rgba(255, 159, 64, 0.8)',\n        'rgba(255, 99, 132, 0.8)',\n        'rgba(54, 162, 235, 0.8)',\n        'rgba(201, 203, 207, 0.8)'\n      ],\n      borderColor: 'rgba(0,0,0,0.1)',\n      borderWidth: 1\n    }]\n  },\n  options: {\n    indexAxis: 'y',\n    responsive: true,\n    plugins: {\n      legend: {\n        display: false\n      },\n      title: {\n        display: true,\n        text: '📊 Company Market Cap Overview',\n        font: {\n          size: 20\n        },\n        padding: {\n          top: 10,\n          bottom: 20\n        }\n      },\n      tooltip: {\n        callbacks: {\n          label: function(context) {\n            return context.dataset.label + ': $' + context.raw + 'B';\n          }\n        }\n      }\n    },\n    scales: {\n      x: {\n        title: {\n          display: true,\n          text: 'Market Cap (in Billions $)'\n        },\n        grid: {\n          display: true\n        }\n      },\n      y: {\n        ticks: {\n          font: {\n            size: 12\n          }\n        }\n      }\n    }\n  }\n};\n\nitemsOut.push({ json: { chart: chartPayload } });\nreturn itemsOut;"
      },
      "typeVersion": 2
    },
    {
      "id": "a4c79ae7-ef35-4509-91f5-71107fcfee20",
      "name": "🌐 PNG aus Diagramm generieren",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        448,
        0
      ],
      "parameters": {
        "url": "=https://quickchart.io/chart?c={{ JSON.stringify($json.chart) }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "405f8c35-7747-442b-a14f-898a2b366d0e",
      "name": "📤 Sende Diagramm an Telegram",
      "type": "n8n-nodes-base.telegram",
      "position": [
        656,
        0
      ],
      "webhookId": "d7190374-fdad-4ccd-ab58-77794a247fb1",
      "parameters": {
        "chatId": "YOUR_TELEGRAM_CHAT_ID",
        "operation": "sendPhoto",
        "binaryData": true,
        "additionalFields": {}
      },
      "credentials": {},
      "typeVersion": 1.2
    },
    {
      "id": "01b96865-6ae1-43d8-962d-2a7141f9254f",
      "name": "Haftnotiz3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        208,
        -256
      ],
      "parameters": {
        "width": 624,
        "height": 480,
        "content": "1.🧮 Generate Chart Payload (Code Node)\nPrepare chart data (labels + values) for market cap in billions using QuickChart format.\n\n2.🌐 Generate PNG from Chart (HTTP Request Node)\nPurpose: Use QuickChart.io API to generate PNG image from chart JSON.\n\n3.📤 Send Chart on Telegram (Telegram Node)\nPurpose: Send chart image with caption to client/group."
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "514d9f62-1953-40f2-bf5d-9b00b95ded68",
  "connections": {
    "7cebf294-ed28-4cce-935f-8182c953aa5d": {
      "main": [
        [
          {
            "node": "21b115c8-d3a7-4c6e-b3af-aab2e2c7f7d1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "db304f8b-91e1-4d33-acc9-0ba8351160da": {
      "main": [
        [
          {
            "node": "a23cf845-6bff-4a40-a87f-5d0bac918acc",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "a23cf845-6bff-4a40-a87f-5d0bac918acc": {
      "main": [
        [
          {
            "node": "4d719ca5-ae7f-44b2-8b63-ed8a729ebbbb",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "c0a0422f-a712-4be9-b46d-c35e6b5956ce",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "87619346-06ed-4311-a7e0-bcb82f554aca": {
      "main": [
        [
          {
            "node": "a4c79ae7-ef35-4509-91f5-71107fcfee20",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "a4c79ae7-ef35-4509-91f5-71107fcfee20": {
      "main": [
        [
          {
            "node": "405f8c35-7747-442b-a14f-898a2b366d0e",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "438a38f6-c401-4b75-94c6-e15992a97e76": {
      "main": [
        [
          {
            "node": "87619346-06ed-4311-a7e0-bcb82f554aca",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "4d719ca5-ae7f-44b2-8b63-ed8a729ebbbb": {
      "main": [
        [
          {
            "node": "438a38f6-c401-4b75-94c6-e15992a97e76",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "c0a0422f-a712-4be9-b46d-c35e6b5956ce": {
      "main": [
        [
          {
            "node": "db304f8b-91e1-4d33-acc9-0ba8351160da",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "21b115c8-d3a7-4c6e-b3af-aab2e2c7f7d1": {
      "main": [
        [
          {
            "node": "c0a0422f-a712-4be9-b46d-c35e6b5956ce",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Häufig gestellte Fragen

Wie verwende ich diesen Workflow?

Kopieren Sie den obigen JSON-Code, erstellen Sie einen neuen Workflow in Ihrer n8n-Instanz und wählen Sie "Aus JSON importieren". Fügen Sie die Konfiguration ein und passen Sie die Anmeldedaten nach Bedarf an.

Für welche Szenarien ist dieser Workflow geeignet?

Fortgeschritten - Krypto-Handel

Ist es kostenpflichtig?

Dieser Workflow ist völlig kostenlos. Beachten Sie jedoch, dass Drittanbieterdienste (wie OpenAI API), die im Workflow verwendet werden, möglicherweise kostenpflichtig sind.

Workflow-Informationen
Schwierigkeitsgrad
Fortgeschritten
Anzahl der Nodes14
Kategorie1
Node-Typen8
Schwierigkeitsbeschreibung

Für erfahrene Benutzer, mittelkomplexe Workflows mit 6-15 Nodes

Externe Links
Auf n8n.io ansehen

Diesen Workflow teilen

Kategorien

Kategorien: 34