{ "name": "Outlevo: Meetings in the next 24 hours to Microsoft Teams", "nodes": [ { "id": "6ea754c0-0262-45aa-bb53-372b5d6ab37e", "name": "How to set it up", "type": "n8n-nodes-base.stickyNote", "typeVersion": 1, "position": [ -40, -364 ], "parameters": { "content": "## How to set it up\n\n**Credentials** (n8n asks for each on first open):\n- **Outlevo API key**: a Header Auth credential, name `Authorization`, value `Bearer olv_live_…` (Settings → API keys in Outlevo).\n- **Microsoft Teams**: connect your Microsoft Teams account.\n\n**API key scopes**: `outcomes:read`.\n\n**Pick in the node**:\n- **Post to Teams**: the team and the channel\n\nThen switch the workflow to **Active**.", "height": 304, "width": 620 } }, { "id": "aa76a737-5366-4644-ba29-2f754c05b55a", "name": "Every morning", "type": "n8n-nodes-base.scheduleTrigger", "typeVersion": 1.2, "position": [ 0, 0 ], "parameters": { "rule": { "interval": [ { "field": "days", "daysInterval": 1, "triggerAtHour": 7 } ] } } }, { "id": "6e688770-b565-4b1f-8fd6-64d1bb6965dd", "name": "Booked meetings", "type": "n8n-nodes-base.httpRequest", "typeVersion": 4.2, "position": [ 240, 0 ], "parameters": { "method": "GET", "url": "=https://api.outlevo.com/v1/meetings", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendQuery": true, "queryParameters": { "parameters": [ { "name": "status", "value": "booked" }, { "name": "limit", "value": "200" } ] }, "options": {} }, "credentials": { "httpHeaderAuth": { "id": "", "name": "Outlevo API key (Authorization: Bearer olv_live_…)" } } }, { "id": "09839892-34cd-423b-a75e-2460007a9260", "name": "Write the digest", "type": "n8n-nodes-base.code", "typeVersion": 2, "position": [ 480, 0 ], "parameters": { "mode": "runOnceForAllItems", "jsCode": "const now = Date.now();\nconst list = ($input.first().json.data || []).filter((m) => { const t = Date.parse(m.starts_at); return t >= now && t < now + 864e5; }).sort((a, b) => String(a.starts_at).localeCompare(String(b.starts_at)));\nif (!list.length) return [];\nconst lines = list.map((m) => `• ${new Date(m.starts_at).toISOString().slice(11, 16)} UTC ${m.attendee_name || 'Someone'}${m.attendee_title ? ` (${m.attendee_title})` : ''} at ${m.company_name || m.company_domain || 'their company'}`);\nreturn [{ json: { text: `📅 ${list.length} meeting(s) in the next 24 hours:\\n${lines.join('\\n')}\\nhttps://app.outlevo.com/meetings`, subject: `${list.length} meeting(s) today` } }];\n" } }, { "id": "454f7400-17e2-4cce-a36b-b2a21662971f", "name": "Post to Teams", "type": "n8n-nodes-base.microsoftTeams", "typeVersion": 2, "position": [ 720, 0 ], "parameters": { "resource": "channelMessage", "operation": "create", "teamId": { "__rl": true, "mode": "list", "value": "" }, "channelId": { "__rl": true, "mode": "list", "value": "" }, "contentType": "html", "message": "={{ $json.text.split('&').join('&').split('<').join('<').split('>').join('>').split('\\n').join('
') }}", "options": { "includeLinkToWorkflow": false } }, "credentials": { "microsoftTeamsOAuth2Api": { "id": "", "name": "Microsoft Teams" } } } ], "connections": { "Every morning": { "main": [ [ { "node": "Booked meetings", "type": "main", "index": 0 } ] ] }, "Booked meetings": { "main": [ [ { "node": "Write the digest", "type": "main", "index": 0 } ] ] }, "Write the digest": { "main": [ [ { "node": "Post to Teams", "type": "main", "index": 0 } ] ] } }, "settings": { "executionOrder": "v1" }, "pinData": {}, "meta": { "templateCredsSetupCompleted": false } }