/ Tech Request - 2 Create Notion Item.md
Tech Request - 2 Create Notion Item.md
1 --- 2 type: make-scenario-migration 3 status: pending 4 make-id: 4227715 5 active: true 6 invalid: false 7 trigger: webhook 8 apps: [gateway, json, notion] 9 executions: ~low 10 last-edit: 2026-04-05 11 --- 12 13 # Tech Request - 2. Create Notion Item 14 15 **Status:** Active 16 **Make ID:** 4227715 17 **Trigger:** Custom Webhook (Slack modal submission callback) 18 19 --- 20 21 ## Module Sequence 22 23 1. **Custom Webhook** → receives Slack modal submission (Slack sends `view_submission` payload to the webhook URL set in the Slack app's Interactivity settings) 24 2. **Webhook Respond** → immediately returns HTTP 200 with empty body (clears the modal) 25 3. **JSON Parse** → parses the `payload` field from the Slack modal submission (Slack sends the form values as a JSON string in a `payload` URL-encoded form field) 26 4. **Notion — Create Item** → creates new page in **Project Workflow** database with: 27 - Name: Task Name from modal 28 - Date: Due Date from modal 29 - Status: (default, e.g. "Not Started") 30 - Client: "Calivus Labs" (hardcoded) 31 - Type: "Task" (hardcoded) 32 - Department: "Operations" (hardcoded or from modal) 33 34 --- 35 36 ## n8n Node Mapping 37 38 | Make Module | n8n Node | Notes | 39 |---|---|---| 40 | Custom Webhook | Webhook node | Receives Slack `view_submission` POST | 41 | Webhook Respond (200 empty) | Respond to Webhook node | Closes the modal in Slack | 42 | JSON Parse (payload) | Set node / Code node | Parse `body.payload` (URL-decoded JSON string) to extract modal field values | 43 | Notion Create Item | Notion node | Create Database Item in "Project Workflow" DB | 44 45 --- 46 47 ## Key Details 48 49 - This is Part 2 of the Tech Request flow (Part 1: scenario 4227711 opens the modal) 50 - Slack sends modal submissions as `application/x-www-form-urlencoded` with a `payload` key containing a JSON string — must parse carefully in n8n 51 - Notion database: "Project Workflow" — get database ID from Notion URL 52 - Hardcoded values: Client="Calivus Labs", Type="Task", Department="Operations" 53 - This URL must be set as the Slack app's **Interactivity Request URL** (separate from the slash command URL) 54 55 --- 56 57 ## Migration Checklist 58 59 - [ ] Identify the Notion "Project Workflow" database ID 60 - [ ] Recreate Notion credential (OAuth) in n8n 61 - [ ] Build workflow: Webhook → Respond to Webhook → Set/Code (parse payload JSON) → Notion Create 62 - [ ] Update Slack app Interactivity Request URL to new n8n webhook endpoint 63 - [ ] Test: submit the modal from Part 1 → Notion item created 64 - [ ] Confirm all fields map correctly (Name, Date, Status, Client, Type, Department) 65 - [ ] Mark active in n8n, deactivate Make scenario