{
  "id": "9JFtqA07DKDwrEbx",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "For Article",
  "tags": [],
  "nodes": [
    {
      "id": "2e8c56df-0296-4e92-bb8b-9c2345e9bef5",
      "name": "When clicking \u2018Execute workflow\u2019",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -672,
        -96
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "029520ac-bae1-4887-962f-39c73924f2d5",
      "name": "Download file",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        -176,
        80
      ],
      "parameters": {
        "fileId": {
          "__rl": true,
          "mode": "list",
          "value": "1pR8Q3jMubCag1x4GD8EaRGGMmZW73mBK",
          "cachedResultUrl": "https://drive.google.com/YOUR_AWS_SECRET_KEY_HERE/view?usp=drivesdk",
          "cachedResultName": "photo_2025-07-03 11.39.11.jpeg"
        },
        "options": {},
        "operation": "download"
      },
      "credentials": {
        "googleDriveOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 3
    },
    {
      "id": "b468fa9d-87c0-4042-9bbd-3516051cf56e",
      "name": "Upload media",
      "type": "@postpulse/n8n-nodes-postpulse.postPulse",
      "position": [
        16,
        80
      ],
      "parameters": {
        "resource": "media"
      },
      "credentials": {
        "postPulseOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "6c013f10-77bb-44d0-8157-93e938fa6022",
      "name": "Get connected accounts",
      "type": "@postpulse/n8n-nodes-postpulse.postPulse",
      "position": [
        -416,
        -256
      ],
      "parameters": {
        "resource": "account"
      },
      "credentials": {
        "postPulseOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "2b2ae5bf-1cf2-49da-9759-dcc583f7ccbf",
      "name": "Merge",
      "type": "n8n-nodes-base.merge",
      "position": [
        256,
        -96
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "combineBy": "combineAll"
      },
      "typeVersion": 3.2
    },
    {
      "id": "060d2c58-c18f-46f1-b38e-9c2f5d431874",
      "name": "Schedule a post",
      "type": "@postpulse/n8n-nodes-postpulse.postPulse",
      "position": [
        464,
        -96
      ],
      "parameters": {
        "isDraft": true,
        "publications": {
          "publication": [
            {
              "posts": {
                "post": [
                  {
                    "content": "test",
                    "attachmentPaths": {
                      "path": [
                        {
                          "value": "={{ $json.path }}"
                        }
                      ]
                    }
                  }
                ]
              },
              "platformSettings": "{\"type\" : \"THREADS\"}",
              "socialMediaAccountId": "={{ $json.id }}"
            }
          ]
        },
        "scheduledTime": "2025-08-24T16:43:49"
      },
      "credentials": {
        "postPulseOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "bf42898a-1909-4c34-8535-1b5fdf6efa48",
      "name": "Get row(s) in sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -416,
        80
      ],
      "parameters": {
        "options": {},
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1SteMNdf6j4x4BHgfBo7RlMue2V7MdTRUPZxcxDEZ9S4/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1SteMNdf6j4x4BHgfBo7RlMue2V7MdTRUPZxcxDEZ9S4",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1SteMNdf6j4x4BHgfBo7RlMue2V7MdTRUPZxcxDEZ9S4/edit?usp=drivesdk",
          "cachedResultName": "n8n test"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.7
    },
    {
      "id": "314ba60b-bd90-4180-8b3f-0c7c1b6e867f",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -688,
        -400
      ],
      "parameters": {
        "width": 528,
        "height": 112,
        "content": "## Automated Social Media Post Scheduling \nThis workflow automatically schedules social media posts by fetching data from Google Sheets and media from Google Drive."
      },
      "typeVersion": 1
    },
    {
      "id": "ec8f33d3-6ce7-4885-a0fd-aca106bdf491",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -464,
        -96
      ],
      "parameters": {
        "height": 112,
        "content": "## Get Data \nCollect the account IDs for publication and the media file URL from Google Sheets."
      },
      "typeVersion": 1
    },
    {
      "id": "cec76a97-e611-4ca7-a699-477c2bc17909",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -336,
        240
      ],
      "parameters": {
        "width": 368,
        "height": 96,
        "content": "## Prepare Media \nDownload the media file from Google Drive and upload it to PostPulse for future publication."
      },
      "typeVersion": 1
    },
    {
      "id": "f379f02e-5ebb-4a3c-9172-c76e0d761304",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        144,
        -256
      ],
      "parameters": {
        "height": 112,
        "content": "## Merge Data \nCombine the account IDs and the uploaded media file URL into a single data set."
      },
      "typeVersion": 1
    },
    {
      "id": "277a0252-f9ae-40b6-a62b-17b5715daa5f",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        448,
        -256
      ],
      "parameters": {
        "height": 112,
        "content": "## Schedule the Post \nUse the combined data to create and schedule a post in PostPulse."
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "0c73f7af-31d8-44ff-ba61-ecf587fafdaf",
  "connections": {
    "Merge": {
      "main": [
        [
          {
            "node": "Schedule a post",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload media": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Download file": {
      "main": [
        [
          {
            "node": "Upload media",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get row(s) in sheet": {
      "main": [
        [
          {
            "node": "Download file",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get connected accounts": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking \u2018Execute workflow\u2019": {
      "main": [
        [
          {
            "node": "Get connected accounts",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get row(s) in sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}