Skip to content

Automate Pinterest pin generation with n8n

Automate Pinterest pin generation with n8n by turning a Google Sheets row into a rendered image and a published pin, then writing the result back to the same sheet. This guide explains Pinterest pin generation as a repeatable pipeline: spreadsheet data in, dynamic pin image out, paced posting, and an audit trail in pinterest_post_url. It is written for anyone who already has a product or content list in a sheet and wants each row to become a distinct pin without designing every image by hand.

Pipeline overview and prerequisites

The workflow has seven nodes in order: a manual or scheduled trigger, a Google Sheets read, Loop Over Items, a Templated render step, a 60-second Wait, a Pinterest posting step, and a Google Sheets update. The sheet is the control plane. Adding a row with complete data is what creates a new pin; leaving pinterest_post_url blank until the end keeps the sheet as both input and log. Before building, confirm you have access to n8n, a Templated template with named layers, a connected Pinterest account, and the account and board identifiers needed for the posting step. Test with one row first, because most failures are mapping or identifier problems that are easier to see at single-row scale.

Sheet schema and field map

Create one row per pin with columns image_url, title, subtitle, pinterest_link, and pinterest_post_url. Use image_url for a source image addressable by URL, title for the overlay headline, subtitle for secondary text such as a price, pinterest_link for the destination link, and leave pinterest_post_url empty for write-back. Keep column names exact, because the later mappings reference them directly. A useful check before connecting n8n is to validate one row end to end on paper: does its image_url load, does its title fit the template layer, and does its pinterest_link point to the intended page? If any of those fail, the automation will faithfully reproduce the error at scale.

Node-by-node walkthrough

In n8n, add a Google Sheets node using Get Row(s) in Sheet, authenticate, select the spreadsheet, and pull the rows. Pipe that output into Loop Over Items so each row is processed independently and a failure on one row does not silently skip the rest. For the Templated step, either use its node or an HTTP Request node against the render endpoint described in the source, select the template you designed, and map image_layer to the row's image_url, title_layer to title, and subtitle_layer to the subtitle or price value. The render step returns a url field for the rendered PNG, and that url is the value passed forward as the pin image. Check the render output before posting: if url is missing or empty, stop the branch rather than posting a pin without an image.

Pacing with the Wait node

Place a Wait node set to 60 seconds between iterations. The source presents this pacing as protection against aggressive rate limiting and bot detection when many pins are posted quickly; treat that as a source assertion rather than a verified platform rule, and use the wait as a conservative cadence control. In practice, the wait makes small tests feel slow, but it separates a pipeline that can run daily from one that bursts many posts in a short window. If you increase volume, keep the wait in place and change it deliberately, recording the cadence you chose so a later failure can be compared against it.

Post to Pinterest

For the posting step, use an HTTP Request node with the exact contract shown in the Pinterest posting request and ID lookup calls example below. The request uses publishNow set to true, a single Pinterest platform target, and the rendered image URL from the Templated step. Before wiring it, fetch the two identifiers the payload needs: use the integrations lookup to find the connected Pinterest account and its accountId, then use the boards lookup with that accountId to find the boardId for the target board. Both identifiers can also be read from the integrations dashboard once Pinterest is connected. Verify boardId belongs to the selected accountId before running the loop, because a mismatched pair is a common cause of a failed post that looks like a rendering problem.

Write-back and audit trail

After posting, add a final Google Sheets node using Update Row and write the resulting Pinterest URL into pinterest_post_url for the row just processed. This closes the loop: the sheet now shows which rows have produced a live pin and which are still pending. If the write-back fails, treat the pin as posted but unlogged, and retry only the update rather than reposting, so you do not create a duplicate pin for the same row. A simple audit check is to filter for rows where pinterest_post_url is empty after a run; those rows need investigation before the next run.

What you end up with

When the pipeline works, Pinterest becomes a content pipeline rather than a manual job. Add a row and get a pin, with a unique rendered image, a paced post, and a tracked URL in the same sheet. The same shape can be extended by changing the platform target in the payload, but each new platform needs its own account, board or equivalent target, and payload fields checked separately. For catalog-driven sites, the highest-value habit is keeping the sheet clean: one row per pin, exact column names, and no posting until the render url and both identifiers are confirmed.

Field map from sheet to template to Pinterest payload
Sheet columnTemplated layerPinterest payload fieldNotes
image_urlimage_layermediaItems[].url via rendered urlSource image is rendered by Templated; the rendered url, not image_url, is posted.
titletitle_layercontent and platformSpecificData.titleTitle is used in both the post content and the Pinterest title field.
subtitlesubtitle_layercontentSource also allows price as the secondary text value.
pinterest_link—platformSpecificData.linkDestination link for the pin.
pinterest_post_url—Written back from posting responseLeft blank on input; filled by the Update Row step.

Mapping follows the source walkthrough; layer names are template-specific placeholders from the source.

Node-by-node input and output contract
NodeInputOutputFailure check
TriggerManual or scheduleStarts workflowConfirm trigger fires once per run.
Google Sheets (read)Spreadsheet selectionRows with image_url, title, subtitle, pinterest_link, pinterest_post_urlConfirm column names match exactly.
Loop Over ItemsAll rowsOne row per iterationConfirm each row is processed independently.
Templatedimage_url, title, subtitle/priceRendered urlStop if url is missing.
WaitRendered urlSame item after 60 secondsConfirm wait is between iterations, not before the first render.
Pinterest postingRendered url, accountId, boardId, title, pinterest_linkLive Pinterest URLConfirm accountId and boardId pair before posting.
Google Sheets (update)Live Pinterest URL and row identitypinterest_post_url filledRetry update only; do not repost on write-back failure.

Node contract summarized from the source walkthrough; no runtime test evidence supplied.

Failure matrix
FailureLikely causeCheck and recovery
Missing accountId or boardIdIdentifiers not fetched or mismatchedRe-run integrations and boards lookups; confirm boardId belongs to accountId.
Render returns no urlTemplate layer mapping or source image problemCheck image_url loads and layer mappings; fix the row or template before posting.
Posting fails after successful renderWrong board, account, or payload fieldCompare payload against the contract example; verify boardId, title, and link values.
Rate-limit or pacing concernToo many posts in a short windowKeep the 60-second Wait; reduce batch size and retest with one row.
Write-back failsRow identity or sheet update errorRetry only the Update Row step; do not repost the pin.
Duplicate pin riskRe-running a row that already postedCheck pinterest_post_url before processing; skip rows already filled.

Failure guidance derived from the source steps; Pinterest platform limits are source assertions, not independently verified.

Pinterest posting request and ID lookup calls
POST {{API_BASE_URL}}/v1/posts
Header: x-access-key: YOUR_ACCESS_KEY

{
  "content": "A short example update.",
  "platforms": [
    {
      "platform": "pinterest",
      "accountId": "YOUR_PINTEREST_ACCOUNT_ID",
      "platformSpecificData": {
        "boardId": "YOUR_BOARD_ID",
        "title": "{{ $json.title }}",
        "link": "{{ $json.pinterest_link }}"
      }
    }
  ],
  "mediaItems": [
    { "type": "image", "url": "{{ $node['Templated'].json.url }}" }
  ],
  "publishNow": true
}

GET {{API_BASE_URL}}/v1/connect/integrations

GET {{API_BASE_URL}}/v1/connect/pinterest/boards?accountId=...