Alpha Vantage API と Google スプレッドシートを使用して暗号通貨レートを1時間ごとに監視
中級
これはFinance, AI分野の自動化ワークフローで、9個のノードを含みます。主にTelegram, HttpRequest, GoogleSheets, ScheduleTriggerなどのノードを使用、AI技術を活用したスマート自動化を実現。 Alpha Vantage APIとGoogleスプレッドシートで暗号通貨の為替レートを1時間ごとに監視
前提条件
- •Telegram Bot Token
- •ターゲットAPIの認証情報が必要な場合あり
- •Google Sheets API認証情報
ワークフロープレビュー
ノード接続関係を可視化、ズームとパンをサポート
ワークフローをエクスポート
以下のJSON設定をn8nにインポートして、このワークフローを使用できます
{
"id": "LRLFh0lVw2OIPJdW",
"meta": {
"instanceId": "",
"templateCredsSetupCompleted": true
},
"name": "📈 Hourly Monitoring of Crypto Rates with Alpha Vantage API and Google Sheets",
"tags": [],
"nodes": [
{
"id": "95d9375b-c423-4346-8dd4-3cba09a62caa",
"name": "BTC為替レート",
"type": "n8n-nodes-base.httpRequest",
"position": [
-520,
-60
],
"parameters": {
"url": "https://www.alphavantage.co/query",
"options": {},
"sendQuery": true,
"authentication": "genericCredentialType",
"genericAuthType": "httpQueryAuth",
"queryParameters": {
"parameters": [
{
"name": "function",
"value": "CURRENCY_EXCHANGE_RATE"
},
{
"name": "from_currency",
"value": "BTC"
},
{
"name": "to_currency",
"value": "EUR"
}
]
}
},
"credentials": {
"httpQueryAuth": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 4.2
},
{
"id": "5d2a06c6-d2d8-4f55-b9ea-615d5c88612a",
"name": "毎時実行",
"type": "n8n-nodes-base.scheduleTrigger",
"position": [
-860,
40
],
"parameters": {
"rule": {
"interval": [
{
"field": "hours"
}
]
}
},
"typeVersion": 1.2
},
{
"id": "ede798c5-aec6-4040-9ed8-b9f2cf6ea66f",
"name": "BTCレート保存",
"type": "n8n-nodes-base.googleSheets",
"position": [
-320,
-60
],
"parameters": {
"columns": {
"value": {
"Ask_Price": "={{ $json['Realtime Currency Exchange Rate']['9. Ask Price'] }}",
"Bid_Price": "={{ $json['Realtime Currency Exchange Rate']['8. Bid Price'] }}",
"Time_Zone": "={{ $json['Realtime Currency Exchange Rate']['7. Time Zone'] }}",
"Exchange_Rate": "={{ $json['Realtime Currency Exchange Rate']['5. Exchange Rate'] }}",
"Last_Refreshed": "={{ $json['Realtime Currency Exchange Rate']['6. Last Refreshed'] }}",
"To_Currency_Code": "={{ $json['Realtime Currency Exchange Rate']['3. To_Currency Code'] }}",
"To_Currency_Name": "={{ $json['Realtime Currency Exchange Rate']['4. To_Currency Name'] }}",
"From_Currency_Code": "={{ $json['Realtime Currency Exchange Rate']['1. From_Currency Code'] }}",
"From_Currency_Name": "={{ $json['Realtime Currency Exchange Rate']['2. From_Currency Name'] }}"
},
"schema": [
{
"id": "Last_Refreshed",
"type": "string",
"display": true,
"required": false,
"displayName": "Last_Refreshed",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Time_Zone",
"type": "string",
"display": true,
"required": false,
"displayName": "Time_Zone",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From_Currency_Code",
"type": "string",
"display": true,
"required": false,
"displayName": "From_Currency_Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From_Currency_Name",
"type": "string",
"display": true,
"required": false,
"displayName": "From_Currency_Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To_Currency_Code",
"type": "string",
"display": true,
"required": false,
"displayName": "To_Currency_Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To_Currency_Name",
"type": "string",
"display": true,
"required": false,
"displayName": "To_Currency_Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Exchange_Rate",
"type": "string",
"display": true,
"required": false,
"displayName": "Exchange_Rate",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Last_Refreshed",
"type": "string",
"display": true,
"required": false,
"displayName": "Last_Refreshed",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Time_Zone",
"type": "string",
"display": true,
"required": false,
"displayName": "Time_Zone",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Bid_Price",
"type": "string",
"display": true,
"required": false,
"displayName": "Bid_Price",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Ask_Price",
"type": "string",
"display": true,
"required": false,
"displayName": "Ask_Price",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "append",
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "",
"cachedResultName": "BTC"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1vtjhgdulJn8niwZE0RQeQL8L1kb00L4z2TOuQK_9mV0",
"cachedResultUrl": "",
"cachedResultName": "AlphaVantage"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 4.6
},
{
"id": "2fb8320b-aeb4-4e23-91c5-ff2ceebc8970",
"name": "ETHレート保存",
"type": "n8n-nodes-base.googleSheets",
"position": [
-320,
120
],
"parameters": {
"columns": {
"value": {
"Ask_Price": "={{ $json['Realtime Currency Exchange Rate']['9. Ask Price'] }}",
"Bid_Price": "={{ $json['Realtime Currency Exchange Rate']['8. Bid Price'] }}",
"Time_Zone": "={{ $json['Realtime Currency Exchange Rate']['7. Time Zone'] }}",
"Exchange_Rate": "={{ $json['Realtime Currency Exchange Rate']['5. Exchange Rate'] }}",
"Last_Refreshed": "={{ $json['Realtime Currency Exchange Rate']['6. Last Refreshed'] }}",
"To_Currency_Code": "={{ $json['Realtime Currency Exchange Rate']['3. To_Currency Code'] }}",
"To_Currency_Name": "={{ $json['Realtime Currency Exchange Rate']['4. To_Currency Name'] }}",
"From_Currency_Code": "={{ $json['Realtime Currency Exchange Rate']['1. From_Currency Code'] }}",
"From_Currency_Name": "={{ $json['Realtime Currency Exchange Rate']['2. From_Currency Name'] }}"
},
"schema": [
{
"id": "Last_Refreshed",
"type": "string",
"display": true,
"required": false,
"displayName": "Last_Refreshed",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Time_Zone",
"type": "string",
"display": true,
"required": false,
"displayName": "Time_Zone",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From_Currency_Code",
"type": "string",
"display": true,
"required": false,
"displayName": "From_Currency_Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "From_Currency_Name",
"type": "string",
"display": true,
"required": false,
"displayName": "From_Currency_Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To_Currency_Code",
"type": "string",
"display": true,
"required": false,
"displayName": "To_Currency_Code",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "To_Currency_Name",
"type": "string",
"display": true,
"required": false,
"displayName": "To_Currency_Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Exchange_Rate",
"type": "string",
"display": true,
"required": false,
"displayName": "Exchange_Rate",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Last_Refreshed",
"type": "string",
"display": true,
"required": false,
"displayName": "Last_Refreshed",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Time_Zone",
"type": "string",
"display": true,
"required": false,
"displayName": "Time_Zone",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Bid_Price",
"type": "string",
"display": true,
"required": false,
"displayName": "Bid_Price",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Ask_Price",
"type": "string",
"display": true,
"required": false,
"displayName": "Ask_Price",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "append",
"sheetName": {
"__rl": true,
"mode": "list",
"value": 1591416661,
"cachedResultUrl": "",
"cachedResultName": "ETH"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1vtjhgdulJn8niwZE0RQeQL8L1kb00L4z2TOuQK_9mV0",
"cachedResultUrl": "",
"cachedResultName": "AlphaVantage"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 4.6
},
{
"id": "b0630581-e5cc-4e64-bbb3-2c362b766a8a",
"name": "ETH為替レート",
"type": "n8n-nodes-base.httpRequest",
"position": [
-520,
120
],
"parameters": {
"url": "https://www.alphavantage.co/query",
"options": {},
"sendQuery": true,
"authentication": "genericCredentialType",
"genericAuthType": "httpQueryAuth",
"queryParameters": {
"parameters": [
{
"name": "function",
"value": "CURRENCY_EXCHANGE_RATE"
},
{
"name": "from_currency",
"value": "ETH"
},
{
"name": "to_currency",
"value": "EUR"
}
]
}
},
"credentials": {
"httpQueryAuth": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 4.2
},
{
"id": "329e3c49-9b8f-49ca-83da-5e7ec00f17f0",
"name": "BTC通知",
"type": "n8n-nodes-base.telegram",
"position": [
-80,
-60
],
"webhookId": "5f997b2e-aff9-427e-a92d-a0133903a3a4",
"parameters": {
"text": "=<b>🔄 BTC to EUR Rate Update</b>\n\n<b>From:</b> {{ $json[\"From_Currency_Name\"] }} ({{ $json[\"From_Currency_Code\"] }})\n<b>To:</b> {{ $json[\"To_Currency_Name\"] }} ({{ $json[\"To_Currency_Code\"] }})\n\n<b>💱 Exchange Rate:</b> {{ $json[\"Exchange_Rate\"] }}\n<b>📉 Bid:</b> {{ $json[\"Bid_Price\"] }}\n<b>📈 Ask:</b> {{ $json[\"Ask_Price\"] }}\n\n<b>🕒 Last Updated:</b> {{ $json[\"Last_Refreshed\"] }} ({{ $json[\"Time_Zone\"] }})",
"chatId": "1698247520",
"additionalFields": {
"parse_mode": "HTML",
"appendAttribution": false
}
},
"credentials": {
"telegramApi": {
"id": "BlqWlzuNU8B4t9Pw",
"name": "Assistant Bot"
}
},
"notesInFlow": true,
"typeVersion": 1.2
},
{
"id": "e9920828-9a99-4899-9313-037fc78933dc",
"name": "ETH通知",
"type": "n8n-nodes-base.telegram",
"position": [
-80,
120
],
"webhookId": "5f997b2e-aff9-427e-a92d-a0133903a3a4",
"parameters": {
"text": "=<b>🔄 ETH to EUR Rate Update</b>\n\n<b>From:</b> {{ $json[\"From_Currency_Name\"] }} ({{ $json[\"From_Currency_Code\"] }})\n<b>To:</b> {{ $json[\"To_Currency_Name\"] }} ({{ $json[\"To_Currency_Code\"] }})\n\n<b>💱 Exchange Rate:</b> {{ $json[\"Exchange_Rate\"] }}\n<b>📉 Bid:</b> {{ $json[\"Bid_Price\"] }}\n<b>📈 Ask:</b> {{ $json[\"Ask_Price\"] }}\n\n<b>🕒 Last Updated:</b> {{ $json[\"Last_Refreshed\"] }} ({{ $json[\"Time_Zone\"] }})",
"chatId": "1698247520",
"additionalFields": {
"parse_mode": "HTML",
"appendAttribution": false
}
},
"credentials": {
"telegramApi": {
"id": "",
"name": ""
}
},
"notesInFlow": true,
"typeVersion": 1.2
},
{
"id": "3d674add-ca49-4e6f-b3e4-7aaa82f67953",
"name": "付箋1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-900,
-500
],
"parameters": {
"color": 7,
"width": 220,
"height": 760,
"content": "### 1. Workflow Trigger every hour\n\nTrigger the collection of ETH and BTC price every hour.\n\n#### How to setup?\n*Nothing to do.*"
},
"typeVersion": 1
},
{
"id": "4095c6c9-9cbd-446c-884c-ed713760ddff",
"name": "付箋",
"type": "n8n-nodes-base.stickyNote",
"position": [
-660,
-500
],
"parameters": {
"color": 7,
"width": 920,
"height": 760,
"content": "### 2. Collect BTC and ETH price from Alpha Vantage Insight API\nThis starts by calling the CURRENCY_EXCHANGE_RATE function of the **Alpha Vantage Insight API** to get the exchange rate to euros.\n#### How to setup?\n- **Set up API credentials**\n 1. Get your free API key from [Alpha Vantage](https://www.alphavantage.co/support/#api-key)\n 2. Fill in the API key in the HTTP Request node using query parameters authentication\n- **Load records in the Google Sheet Node**:\n 1. Add your Google Sheet API credentials to access the Google Sheet file\n 2. Select the file using the list, an URL or an ID\n 3. Select the sheet in which you want to record your working sessions\n 4. Map the fields: `From_Currency_Code`, `From_Currency_Name`, `To_Currency_Code`, `To_Currency_Name`, `Exchange_Rate`, `Bid_Price`, `Ask_Price`, `Last_Refreshed`, `Time_Zone`\t\t\t\t\t\t\t\t\t\t\t\t\n [Learn more about the Google Sheet Node](https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.googlesheets)\n- **Send Telegram notification**\n 1. Add your Telegram credentials\n 2. Fill in the Chat ID and message content\n 3. Use dynamic variables for formatting the exchange rate alert\n"
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "cd5a0fe2-298c-40a5-b184-be90d8c220d1",
"connections": {
"ede798c5-aec6-4040-9ed8-b9f2cf6ea66f": {
"main": [
[
{
"node": "329e3c49-9b8f-49ca-83da-5e7ec00f17f0",
"type": "main",
"index": 0
}
]
]
},
"2fb8320b-aeb4-4e23-91c5-ff2ceebc8970": {
"main": [
[
{
"node": "e9920828-9a99-4899-9313-037fc78933dc",
"type": "main",
"index": 0
}
]
]
},
"5d2a06c6-d2d8-4f55-b9ea-615d5c88612a": {
"main": [
[
{
"node": "95d9375b-c423-4346-8dd4-3cba09a62caa",
"type": "main",
"index": 0
},
{
"node": "b0630581-e5cc-4e64-bbb3-2c362b766a8a",
"type": "main",
"index": 0
}
]
]
},
"95d9375b-c423-4346-8dd4-3cba09a62caa": {
"main": [
[
{
"node": "ede798c5-aec6-4040-9ed8-b9f2cf6ea66f",
"type": "main",
"index": 0
}
]
]
},
"b0630581-e5cc-4e64-bbb3-2c362b766a8a": {
"main": [
[
{
"node": "2fb8320b-aeb4-4e23-91c5-ff2ceebc8970",
"type": "main",
"index": 0
}
]
]
}
}
}よくある質問
このワークフローの使い方は?
上記のJSON設定コードをコピーし、n8nインスタンスで新しいワークフローを作成して「JSONからインポート」を選択、設定を貼り付けて認証情報を必要に応じて変更してください。
このワークフローはどんな場面に適していますか?
中級 - 財務, 人工知能
有料ですか?
このワークフローは完全無料です。ただし、ワークフローで使用するサードパーティサービス(OpenAI APIなど)は別途料金が発生する場合があります。
関連ワークフロー
イベントスクレイピングと Google Sheets(EU)
Google Sheetsを使用してEUイベントをスクレイピング
If
Set
Code
+
If
Set
Code
20 ノードSamir Saci
人工知能
🗞️ AIドライブの持続可能性マーケティングブリーフィング(Gmail、GPT-4o使用)
🗞️ AI駆動型持続可能性マーケティングブリーフィング(Gmail、GPT-4oを使用)
If
Set
Code
+
If
Set
Code
21 ノードSamir Saci
人工知能
CrunchBase投資家データ
投資家インテリジェンスの自動化:CrunchBaseからGoogleシートデータコレクター
Code
Http Request
Google Sheets
+
Code
Http Request
Google Sheets
8 ノードYaron Been
財務
AAVE ポートフォリオ専門 AI アシスタント
Telegram + メール + GPT-4o + Moralis
Set
Code
Gmail
+
Set
Code
Gmail
23 ノードDon Jayamaha Jr
財務
スマート资金管理器
基于Telegram、Google SheetsとOpenAIのAI驱动收据と支出追踪器
If
Set
Code
+
If
Set
Code
50 ノードKhairul Muhtadin
財務
X/Twitter 上の暗号資産ニュース AI イニシエーター
XとTelegramへ自動のにコインニュースをAI要約で投稿
Code
Twitter
Telegram
+
Code
Twitter
Telegram
20 ノードTianyi
財務
ワークフロー情報
難易度
中級
ノード数9
カテゴリー2
ノードタイプ5
作成者
Samir Saci
@samirsaciAutomation, AI and Analytics for Supply Chain & Business Optimization Helping businesses streamline operations using n8n, AI agents, and data science to enhance efficiency and sustainability. Linkedin: www.linkedin.com/in/samir-saci
外部リンク
n8n.ioで表示 →
このワークフローを共有