N
n8n Store
Workflow Market
Track Crypto Prices & FX Rates with CoinGecko & ExchangeRate-API to Notion

Track Crypto Prices & FX Rates with CoinGecko & ExchangeRate-API to Notion

by dae2210 views

描述

分类

🤖 AI & Machine Learning

使用的节点

n8n-nodes-base.coden8n-nodes-base.mergen8n-nodes-base.notionn8n-nodes-base.stickyNoten8n-nodes-base.httpRequestn8n-nodes-base.httpRequestn8n-nodes-base.scheduleTrigger
价格免费
浏览量0
最后更新11/28/2025
workflow.json
{
  "meta": {
    "instanceId": "2000c64071c20843606b95c63795bb0797c41036047055a6586498e855b96efc"
  },
  "nodes": [
    {
      "id": "8d9c79de-0c8b-4398-9a0b-83b2bf7750d5",
      "name": "Every 60 Minutes",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -144,
        112
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "minutes"
            }
          ]
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "702634ad-a504-4fad-9602-dad4cc589e1d",
      "name": "Get Fiat Exchange Rates",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        0,
        48
      ],
      "parameters": {
        "url": "https://api.exchangerate-api.com/v4/latest/USD",
        "options": {}
      },
      "typeVersion": 4.1
    },
    {
      "id": "9abbada7-3fda-47b8-9cb2-5bcf6d595cea",
      "name": "Get Crypto Prices",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        0,
        192
      ],
      "parameters": {
        "url": "https://api.coingecko.com/api/v3/simple/price?ids=bitcoin,ethereum&vs_currencies=usd&include_24hr_change=true",
        "options": {}
      },
      "typeVersion": 4.1
    },
    {
      "id": "101e0111-e84c-40fb-92f0-6db1c574a023",
      "name": "Merge",
      "type": "n8n-nodes-base.merge",
      "position": [
        208,
        128
      ],
      "parameters": {},
      "typeVersion": 3.2
    },
    {
      "id": "05be9717-9af2-4e50-8a2f-933213ef63f0",
      "name": "Build Notion Page",
      "type": "n8n-nodes-base.code",
      "position": [
        400,
        128
      ],
      "parameters": {
        "jsCode": "let fx,cg;for(const it of $input.all()){ if(it.json?.rates) fx=it.json; if(it.json?.bitcoin) cg=it.json; }\nconst page={\n  properties:{\n    Title:{ title:[{ text:{ content:`Crypto+FX — ${new Date().toLocaleString('en-US',{timeZone:'Africa/Lagos'})}`}}]},\n    BTC:{ number: cg?.bitcoin?.usd ?? null },\n    BTC_24h:{ number: cg?.bitcoin?.usd_24h_change ?? null },\n    ETH:{ number: cg?.ethereum?.usd ?? null },\n    ETH_24h:{ number: cg?.ethereum?.usd_24h_change ?? null },\n    USD_EUR:{ number: fx?.rates?.EUR ?? null },\n    USD_NGN:{ number: fx?.rates?.NGN ?? null }\n  }\n};\nreturn [{json:page}];"
      },
      "typeVersion": 2
    },
    {
      "id": "325a38f3-e4c9-4d09-9e80-37e723c785f2",
      "name": "Create in Notion",
      "type": "n8n-nodes-base.notion",
      "position": [
        672,
        128
      ],
      "parameters": {
        "pageId": {
          "__rl": true,
          "mode": "url",
          "value": ""
        },
        "simple": false,
        "options": {}
      },
      "typeVersion": 2
    },
    {
      "id": "45915593-1f21-48fc-bc2e-868c336fee7e",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -592,
        -176
      ],
      "parameters": {
        "width": 736,
        "height": 512,
        "content": "## 📊 Crypto + FX → Notion Dashboard\n\n**What it does:**  \nCreates a **Notion page entry** every hour with BTC/ETH prices, 24h % changes, and USD→EUR / USD→NGN rates.\n\n**Trigger:**  \nHourly (adjustable cron).\n\n**Nodes:**  \nSchedule → ExchangeRate-API → CoinGecko → Merge → **Code (build properties)** → **Notion (Create Page)**\n\n**Setup:**  \n- Create a Notion database with **Title + Number fields**:\n  - BTC, BTC_24h, ETH, ETH_24h, USD_EUR, USD_NGN  \n- Copy the **Database ID** into the Notion node.  \n- Run once to confirm rows are added correctly.\n\n**Example Row in Notion:**  \nTitle: *Crypto+FX — Monday 09:00*  \nBTC: 112,417 | ETH: 4,334.57 | USD→EUR: 0.854 | USD→NGN: ₦1,524.54\n\n**Author:** David Olusola  \n**Trading & 1:1 consulting:** [[email protected]](mailto:[email protected])\n"
      },
      "typeVersion": 1
    }
  ],
  "pinData": {},
  "connections": {
    "Merge": {
      "main": [
        [
          {
            "node": "Build Notion Page",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Every 60 Minutes": {
      "main": [
        [
          {
            "node": "Get Fiat Exchange Rates",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get Crypto Prices",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Build Notion Page": {
      "main": [
        [
          {
            "node": "Create in Notion",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Crypto Prices": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Fiat Exchange Rates": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 1
          }
        ]
      ]
    }
  }
}

相关工作流