{
  "name": "Create lyric posters from Spotify tracks with Musixmatch and OpenAI",
  "nodes": [
    {
      "id": "c75dcdee-942c-449b-b185-c5c9e937af29",
      "name": "Match track by metadata in Musixmatch",
      "type": "@musixmatch/n8n-nodes-musixmatch.musixmatchTool",
      "position": [
        448,
        496
      ]
    },
    {
      "id": "0b5ae95f-c49f-404b-be02-b6f7ba5d28e1",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        240,
        496
      ]
    },
    {
      "id": "f49b7641-3820-47cb-b127-f2b59d660e1f",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -784,
        96
      ],
      "parameters": {
        "width": 400,
        "height": 468,
        "content": "## How it works\nThis workflow generates a printable lyrics poster from any Spotify song. A user submits a Spotify track URL via form, the workflow fetches the song metadata, retrieves lyrics from Musi"
      }
    },
    {
      "id": "20ba9aa3-bcd7-4b80-ba1a-9260816e0b5e",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -272,
        96
      ],
      "parameters": {
        "width": 184,
        "height": 144,
        "content": "## Input\nCollects Spotify URL and extracts track ID"
      }
    },
    {
      "id": "ac40f1a8-32f9-4891-83f7-d516f66ccb7f",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        352,
        96
      ],
      "parameters": {
        "width": 296,
        "height": 144,
        "content": "## AI Processing\nMatches track, retrieves lyrics, selects best line, builds image prompt"
      }
    },
    {
      "id": "546eb78a-21a4-403b-9443-8599d691b57d",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        912,
        96
      ],
      "parameters": {
        "width": 188,
        "height": 144,
        "content": "## Output\nGenerates image and returns to user"
      }
    },
    {
      "id": "c023bc26-38f7-4ffd-99b9-c9444e11dff8",
      "name": "Collect Spotify URL from form",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        -240,
        272
      ]
    },
    {
      "id": "7f4ea76a-0710-49ad-824b-25f88d71e27b",
      "name": "Extract Spotify track ID",
      "type": "n8n-nodes-base.code",
      "position": [
        -32,
        272
      ]
    },
    {
      "id": "ca818415-08d5-423a-b64a-4f40afef695e",
      "name": "Get track metadata from Spotify",
      "type": "n8n-nodes-base.spotify",
      "position": [
        192,
        272
      ]
    },
    {
      "id": "f812d8b3-3b07-4571-8889-eac8ebaff7e4",
      "name": "Select lyric and build image prompt",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        384,
        272
      ]
    },
    {
      "id": "b2a94d26-069a-46ab-aeed-2e3af43cf504",
      "name": "Get lyrics from Musixmatch",
      "type": "@musixmatch/n8n-nodes-musixmatch.musixmatchTool",
      "position": [
        592,
        496
      ]
    },
    {
      "id": "6aa0f26c-4585-4896-aca3-6d16435b0831",
      "name": "Generate poster with OpenAI",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        752,
        272
      ]
    },
    {
      "id": "ef650269-cf70-44e3-bf32-f49a4a91007d",
      "name": "Return poster to user",
      "type": "n8n-nodes-base.form",
      "position": [
        960,
        272
      ]
    }
  ],
  "connections": {
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Select lyric and build image prompt",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Extract Spotify track ID": {
      "main": [
        [
          {
            "node": "Get track metadata from Spotify",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get lyrics from Musixmatch": {
      "ai_tool": [
        [
          {
            "node": "Select lyric and build image prompt",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Generate poster with OpenAI": {
      "main": [
        [
          {
            "node": "Return poster to user",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Collect Spotify URL from form": {
      "main": [
        [
          {
            "node": "Extract Spotify track ID",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get track metadata from Spotify": {
      "main": [
        [
          {
            "node": "Select lyric and build image prompt",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Select lyric and build image prompt": {
      "main": [
        [
          {
            "node": "Generate poster with OpenAI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Match track by metadata in Musixmatch": {
      "ai_tool": [
        [
          {
            "node": "Select lyric and build image prompt",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  }
}