{
  "nodes": [
    {
      "name": "Get Content Ideas",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        200,
        300
      ],
      "parameters": {
        "range": "Sheet1!A:C",
        "sheetId": "REPLACE_WITH_SHEETID"
      },
      "typeVersion": 1
    },
    {
      "name": "Generate Post with OpenAI",
      "type": "n8n-nodes-base.openAi",
      "position": [
        500,
        300
      ],
      "parameters": {
        "model": "gpt-4",
        "prompt": "Create a social media post for {{$node[\"Get Content Ideas\"].json[\"Platform\"]}} based on this idea: {{$node[\"Get Content Ideas\"].json[\"Idea\"]}}. Keep it engaging and concise."
      },
      "typeVersion": 1
    },
    {
      "name": "Check Platform",
      "type": "n8n-nodes-base.if",
      "position": [
        800,
        300
      ],
      "parameters": {
        "conditions": {
          "string": [
            {
              "value1": "{{$node[\"Get Content Ideas\"].json[\"Platform\"]}}",
              "value2": "Twitter",
              "operation": "equal"
            }
          ]
        }
      },
      "typeVersion": 1
    },
    {
      "name": "Post to Twitter",
      "type": "n8n-nodes-base.twitter",
      "position": [
        1000,
        200
      ],
      "parameters": {
        "text": "{{$node[\"Generate Post with OpenAI\"].json[\"text\"]}}"
      },
      "typeVersion": 1
    },
    {
      "name": "Update Google Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1200,
        300
      ],
      "parameters": {
        "range": "Sheet1!D:F",
        "values": "Posted,{{$node[\"Generate Post with OpenAI\"].json[\"text\"]}},{{Date.now()}}",
        "sheetId": "REPLACE_WITH_SHEETID",
        "updateOperation": "append"
      },
      "typeVersion": 1
    },
    {
      "id": "a9a6b7e3-2d92-5076-aa8d-3d4ec64a326c",
      "name": "Publication · Overview and setup",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -800,
        0
      ],
      "parameters": {
        "content": "# get content ideas and generate post with openai and post to twitter\n\n## Purpose and structure\nThis folder contains the **get content ideas and generate post with openai and post to twitter** workflow. Its executable nodes use `googleSheets`, `if`, `openAi`, `twitter`. The table and connection map below are derived from the JSON, not an inferred guarantee of behavior.\n\n## Setup\nImport inactive. Configure your own credentials and replace REPLACE_WITH_* values. Review external destinations and Code nodes before running.\n\n## Entry points\nInspect connections; no recognized trigger.\n\n## Verification\nSanitized source candidate; not runtime-tested. This overview is generated from node metadata. Read the folder README for the connection map, credential types, and license.\n\n## Attribution\nhttps://github.com/Zie619/n8n-workflows/blob/94007c1445d9258a7da116646b79473e7c7c3282/workflows/Openai/0785_Openai_Twitter_Create.json\nMIT; preserve source notices.",
        "width": 700,
        "height": 800,
        "color": 1
      }
    }
  ],
  "connections": {
    "Check Platform": {
      "main": [
        [
          {
            "node": "Post to Twitter",
            "type": "main"
          }
        ]
      ]
    },
    "Post to Twitter": {
      "main": [
        [
          {
            "node": "Update Google Sheet",
            "type": "main"
          }
        ]
      ]
    },
    "Get Content Ideas": {
      "main": [
        [
          {
            "node": "Generate Post with OpenAI",
            "type": "main"
          }
        ]
      ]
    },
    "Generate Post with OpenAI": {
      "main": [
        [
          {
            "node": "Check Platform",
            "type": "main"
          }
        ]
      ]
    }
  },
  "active": false
}
