{
  "name": "Convert YouTube videos to MP3 with RapidAPI, Google Drive storage & sheets logging",
  "nodes": [
    {
      "id": "85bb7486-da1a-4dcd-979d-819d435ab2e0",
      "name": "On form submission",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        -500,
        -20
      ]
    },
    {
      "id": "90b93ccf-0eec-4a9e-82b8-c2974e590353",
      "name": "HTTP Request",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -280,
        -20
      ]
    },
    {
      "id": "035ea1e7-c4e6-446e-8e70-0944e1e62156",
      "name": "Google Drive",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        580,
        -340
      ]
    },
    {
      "id": "9c713a2f-c2c5-43a7-aeec-409682233334",
      "name": "Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1200,
        -140
      ]
    },
    {
      "id": "8aebafbf-69d8-476a-97f4-62d0122fa818",
      "name": "Google Sheets1",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        720,
        220
      ]
    },
    {
      "id": "076854cf-088b-4227-847e-be673d3e2cd5",
      "name": "If",
      "type": "n8n-nodes-base.if",
      "position": [
        0,
        -20
      ]
    },
    {
      "id": "ba810d66-e827-48a4-a72d-a94dd0c3e20b",
      "name": "Wait",
      "type": "n8n-nodes-base.wait",
      "position": [
        260,
        220
      ]
    },
    {
      "id": "9db89edc-1c9c-4678-9261-23397f2ad5b1",
      "name": "Code",
      "type": "n8n-nodes-base.code",
      "position": [
        880,
        -280
      ]
    },
    {
      "id": "a5fb5ed7-bd31-40d1-b4f7-8e7f4b0dd869",
      "name": "Download mp3",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        280,
        -340
      ]
    },
    {
      "id": "8fb7d07e-37a2-4fd9-8a40-af03e14cdbb8",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1360,
        -420
      ],
      "parameters": {
        "width": 660,
        "height": 1160,
        "content": "# **Youtube to MP3 Converter**\n\n## Description:\nThis workflow is designed to convert YouTube videos to MP3 files and store relevant data such as download links and file size in a Google Sheet. It star"
      }
    },
    {
      "id": "b9831f59-f02a-4f44-82c5-0237146c6180",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -600,
        -180
      ],
      "parameters": {
        "width": null,
        "height": 320,
        "content": " **On form submission**  \n   - Triggered when the user submits a form with a YouTube video URL, required for processing."
      }
    },
    {
      "id": "76930924-5f65-4219-9170-e927e3dd0e15",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -340,
        -480
      ],
      "parameters": {
        "width": null,
        "height": 620,
        "content": "**HTTP Request**  \n   - Sends a POST request to the API endpoint `https://youtube-to-mp3-downloader1.p.rapidapi.com/output.php` to convert the provided YouTube video URL to MP3.\n   - It includes neces"
      }
    },
    {
      "id": "64ac5edf-deec-4228-8c57-0fd93b3416e2",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -60,
        -180
      ],
      "parameters": {
        "width": null,
        "height": 320,
        "content": " **If**  \n   - Filters the workflow to continue only if the status of the conversion is \"done.\""
      }
    },
    {
      "id": "92097d91-1648-4e93-a7cf-2d7b6329d8f7",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        220,
        -460
      ],
      "parameters": {
        "width": null,
        "height": 300,
        "content": " **Download mp3**  \n   - Initiates the download of the MP3 file once it is processed and ready."
      }
    },
    {
      "id": "66c2544b-672e-4823-b33d-b9605cfd1306",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        520,
        -440
      ],
      "parameters": {
        "width": null,
        "height": 260,
        "content": " **Google Drive**  \n   - Uploads the converted MP3 file to Google Drive."
      }
    },
    {
      "id": "4ac295fe-8b12-4e7e-bbfc-9644397bf7c4",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        840,
        -420
      ],
      "parameters": {
        "width": null,
        "height": 260,
        "content": " **Code**  \n   - Converts the file size from bytes to megabytes (MB) to be included in the data logged in Google Sheets.\n"
      }
    },
    {
      "id": "8da832b5-3c4b-4687-84f0-15a6a960da9a",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1140,
        -260
      ],
      "parameters": {
        "width": null,
        "height": 260,
        "content": "**Google Sheets**  \n   - Logs the successful conversion details (URL, download link, size, etc.) in a Google Sheet.\n"
      }
    },
    {
      "id": "8517413c-868a-490c-b31d-8a002dc821df",
      "name": "Sticky Note8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        680,
        60
      ],
      "parameters": {
        "width": null,
        "height": 280,
        "content": "**Google Sheets1**  \n   - Logs the initial status and URL information in the same Google Sheet before the download link is available.\n"
      }
    },
    {
      "id": "190cb65d-fbe1-4019-a0a1-60c6afa8b132",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        200,
        120
      ],
      "parameters": {
        "width": null,
        "height": 240,
        "content": " **Wait**  \n   - Pauses the process until the conversion is done, and then moves to the next step."
      }
    }
  ],
  "connections": {
    "If": {
      "main": [
        [
          {
            "node": "Download mp3",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code": {
      "main": [
        [
          {
            "node": "Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait": {
      "main": [
        [
          {
            "node": "Google Sheets1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download mp3": {
      "main": [
        [
          {
            "node": "Google Drive",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Google Drive": {
      "main": [
        [
          {
            "node": "Code",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "HTTP Request": {
      "main": [
        [
          {
            "node": "If",
            "type": "main",
            "index": 0
          }
        ],
        []
      ]
    },
    "On form submission": {
      "main": [
        [
          {
            "node": "HTTP Request",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}