8
n8n 한국어amn8n.com

WordPress 게시물 데이터를 Google Sheets에 내보내기 (WP Rest API 기반)

중급

이것은Market Research분야의자동화 워크플로우로, 15개의 노드를 포함합니다.주로 Set, Code, Form, Merge, FormTrigger 등의 노드를 사용하며. 카테고리와 태그가 있는 WordPress 게시물을 SEO 감사를 위해 Google Sheets에 내보내기

사전 요구사항
  • 대상 API의 인증 정보가 필요할 수 있음
  • Google Sheets API 인증 정보

카테고리

워크플로우 미리보기
노드 연결 관계를 시각적으로 표시하며, 확대/축소 및 이동을 지원합니다
워크플로우 내보내기
다음 JSON 구성을 복사하여 n8n에 가져오면 이 워크플로우를 사용할 수 있습니다
{
  "id": "XnO085uXrhMERPvb",
  "meta": {
    "instanceId": "2295c029f4cb86c8f849f9c87dade323734dc279619eb9e2704f8473c381e4d1",
    "templateCredsSetupCompleted": true
  },
  "name": "WordPress post data export to Google Sheets (based on WP Rest API)",
  "tags": [],
  "nodes": [
    {
      "id": "bfc25242-766f-4b7d-ab23-a0829de1fe83",
      "name": "폼 제출 시",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        -1120,
        -320
      ],
      "webhookId": "57b1b81e-feae-464e-9459-04b0e3efcaa1",
      "parameters": {
        "options": {},
        "formTitle": "WP SEO Audit",
        "formFields": {
          "values": [
            {
              "fieldLabel": "URL",
              "placeholder": "http://yourdomain.com",
              "requiredField": true
            },
            {
              "fieldType": "number",
              "fieldLabel": "Post limit",
              "placeholder": "Default =10"
            }
          ]
        }
      },
      "typeVersion": 2.3
    },
    {
      "id": "3a5f6f97-c79a-4fed-b32a-fe7695e569f1",
      "name": "게시물 가져오기",
      "type": "n8n-nodes-base.httpRequest",
      "onError": "continueErrorOutput",
      "position": [
        -400,
        -128
      ],
      "parameters": {
        "url": "={{ $json.URL }}/wp-json/wp/v2/posts?per_page={{ $json['Post limit'] }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "2201ba9e-40b8-4bcc-988c-e8dce2578dda",
      "name": "카테고리 가져오기",
      "type": "n8n-nodes-base.httpRequest",
      "onError": "continueErrorOutput",
      "position": [
        -400,
        -320
      ],
      "parameters": {
        "url": "={{ $('On form submission').item.json.URL }}/wp-json/wp/v2/categories?per_page={{ $json.per_page }}",
        "options": {},
        "sendBody": true,
        "bodyParameters": {
          "parameters": [
            {}
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "f6c0f099-2c27-45df-91b3-0fd1ea15d165",
      "name": "태그 가져오기",
      "type": "n8n-nodes-base.httpRequest",
      "onError": "continueErrorOutput",
      "position": [
        -400,
        -512
      ],
      "parameters": {
        "url": "={{ $('On form submission').item.json.URL }}/wp-json/wp/v2/tags?per_page={{ $json.per_page }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "6a924b56-3613-4b7f-a7c8-819bbe38387b",
      "name": "병합",
      "type": "n8n-nodes-base.merge",
      "position": [
        16,
        -352
      ],
      "parameters": {
        "numberInputs": 3
      },
      "notesInFlow": false,
      "typeVersion": 3.2
    },
    {
      "id": "bc6731ac-f1aa-4594-a1a6-98275d976ea3",
      "name": "WP API 오류",
      "type": "n8n-nodes-base.form",
      "position": [
        -48,
        -928
      ],
      "webhookId": "ee9fe2bd-db09-469a-b3b1-cd335e4e6daf",
      "parameters": {
        "options": {},
        "operation": "completion",
        "completionTitle": "WordPress API Error",
        "completionMessage": "Please check if your WP-Api is enabled"
      },
      "typeVersion": 2.3
    },
    {
      "id": "46d785e4-fc5f-49ba-8aa6-ee6436621131",
      "name": "게시물에 태그 및 카테고리 이름 할당",
      "type": "n8n-nodes-base.code",
      "position": [
        224,
        -336
      ],
      "parameters": {
        "jsCode": "const tagItems = $items('Get Tags');         // [{ json: { id, name, ... }}, ...]\nconst categoryItems = $items('Get Categories'); // [{ json: { id, name, ... }}, ...]\nconst postItems = $items('Get Posts');       // [{ json: { categories: [ids], tags: [ids], ... }}, ...]\n\n// Build lookup maps\nconst tagsById = Object.fromEntries(\n  tagItems\n    .filter(i => i?.json?.id != null && i?.json?.name != null)\n    .map(i => [String(i.json.id), i.json.name])\n);\n\nconst categoriesById = Object.fromEntries(\n  categoryItems\n    .filter(i => i?.json?.id != null && i?.json?.name != null)\n    .map(i => [String(i.json.id), i.json.name])\n);\n\n// Helper: normalize a field that might be number | string | array into an array of strings\nconst toIdArray = (val) => {\n  if (val == null) return [];\n  if (Array.isArray(val)) return val.map(v => String(v));\n  return [String(val)];\n};\n\n// Enrich posts with names instead of IDs\nconst out = postItems.map(item => {\n  const post = item.json;\n\n  const categoryIds = toIdArray(post.categories);\n  const tagIds = toIdArray(post.tags);\n\n  const categoryNames = categoryIds\n    .map(id => categoriesById[id])\n    .filter(Boolean);\n\n  const tagNames = tagIds\n    .map(id => tagsById[id])\n    .filter(Boolean);\n\n  return {\n    json: {\n      ...post,\n      categoryNames,\n      tagNames,\n    },\n    // keep binary if present\n    binary: item.binary,\n  };\n});\n\nreturn out;"
      },
      "typeVersion": 2
    },
    {
      "id": "989f3e60-1a1b-454c-b5f8-cdd27bf5c379",
      "name": "태그, 카테고리가 포함된 게시물을 Google 시트에 추가",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        480,
        -336
      ],
      "parameters": {
        "columns": {
          "value": {
            "URL": "={{ $json.link }}",
            "Tags": "={{ $json.tagNames }}",
            "Title": "={{ $json.title.rendered }}",
            "Categories": "={{ $json.categoryNames }}"
          },
          "schema": [
            {
              "id": "URL",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "URL",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Title",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "Title",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Categories",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "Categories",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Tags",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Tags",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1nZ3WHn_QedbuNYlFVfPildBZETNYYJFT0yYFIgJy2Mg/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1nZ3WHn_QedbuNYlFVfPildBZETNYYJFT0yYFIgJy2Mg",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1nZ3WHn_QedbuNYlFVfPildBZETNYYJFT0yYFIgJy2Mg/edit?usp=drivesdk",
          "cachedResultName": "[WP]"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "sgj6aGeryqEVmS3h",
          "name": "GSheets - Piotr.Sikora.Ck@gmail.com"
        }
      },
      "typeVersion": 4.7
    },
    {
      "id": "88750e8c-ad3c-4f40-b3f5-83618faa5de4",
      "name": "스티커 메모",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        400,
        -640
      ],
      "parameters": {
        "color": 4,
        "height": 496,
        "content": "## Add posts, with tags, categories to Google Sheet\n\nRemember o create **Googe Sheet** with filds:\n- **URL**\n- **Title**\n- **Categories**\n- **Tags**"
      },
      "typeVersion": 1
    },
    {
      "id": "ed1593aa-3c25-42d4-a8cc-020843039197",
      "name": "스티커 메모1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -112,
        -1072
      ],
      "parameters": {
        "color": 3,
        "height": 304,
        "content": "## WP API Errror\n\nAPI is not avalable"
      },
      "typeVersion": 1
    },
    {
      "id": "f23af13c-7b4d-46b4-af31-f33726fd8356",
      "name": "스티커 메모2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -480,
        -928
      ],
      "parameters": {
        "color": 5,
        "width": 256,
        "height": 960,
        "content": "## Fetch API data\n\nFetch the following resources:\n- **Posts**\n- **Categories**\n- **Tags**\n\n\nPlease note that the `per_page` parameter is statically assigned for the posts and categories endpoints, with its value set to 100.\n\nIf you require a different number of results, adjust the parameter in the appropriate nodes accordingly."
      },
      "typeVersion": 1
    },
    {
      "id": "06d3d9a1-40bc-43e3-82a4-8bf08e640a9a",
      "name": "스티커 메모3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        144,
        -640
      ],
      "parameters": {
        "color": 6,
        "height": 496,
        "content": "## Append categories and tags names\n\nWhat this does:\n- Reads Get Tags, Get Categories, and Get Posts.\n- Builds fast lookup maps.\n- Appends `categoryNames` and `tagNames` directly into each post.\n- Returns the modified posts ready for next steps."
      },
      "typeVersion": 1
    },
    {
      "id": "c51ef4bd-2234-486b-b0f1-2d40f0d00e00",
      "name": "폼",
      "type": "n8n-nodes-base.form",
      "position": [
        688,
        -336
      ],
      "webhookId": "32930177-d74b-4ab5-98b6-7726b70811f5",
      "parameters": {
        "options": {},
        "operation": "completion",
        "completionTitle": "List created",
        "completionMessage": "Please check linked document to see details"
      },
      "typeVersion": 2.3
    },
    {
      "id": "b5e7141e-b922-496f-afd7-1c75a29dc408",
      "name": "스티커 메모4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -848,
        -656
      ],
      "parameters": {
        "color": 7,
        "height": 368,
        "content": "## Config per_page\n\nConfigure `per_page` parametter."
      },
      "typeVersion": 1
    },
    {
      "id": "7a062203-6a2e-4521-a98d-f1435f52ad17",
      "name": "설정",
      "type": "n8n-nodes-base.set",
      "position": [
        -784,
        -448
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "39de8718-83b1-4060-9dc9-23b1a0a20857",
              "name": "per_page",
              "type": "number",
              "value": 100
            }
          ]
        }
      },
      "typeVersion": 3.4
    }
  ],
  "active": false,
  "pinData": {
    "On form submission": [
      {
        "json": {
          "URL": "http://juttle.app",
          "formMode": "test",
          "Post limit": 1,
          "submittedAt": "2025-10-22T10:15:02.313+02:00"
        }
      }
    ]
  },
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "91e580eb-4b6f-45ea-a1fc-68998aa694db",
  "connections": {
    "6a924b56-3613-4b7f-a7c8-819bbe38387b": {
      "main": [
        [
          {
            "node": "46d785e4-fc5f-49ba-8aa6-ee6436621131",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "7a062203-6a2e-4521-a98d-f1435f52ad17": {
      "main": [
        [
          {
            "node": "f6c0f099-2c27-45df-91b3-0fd1ea15d165",
            "type": "main",
            "index": 0
          },
          {
            "node": "2201ba9e-40b8-4bcc-988c-e8dce2578dda",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "f6c0f099-2c27-45df-91b3-0fd1ea15d165": {
      "main": [
        [
          {
            "node": "6a924b56-3613-4b7f-a7c8-819bbe38387b",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "bc6731ac-f1aa-4594-a1a6-98275d976ea3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3a5f6f97-c79a-4fed-b32a-fe7695e569f1": {
      "main": [
        [
          {
            "node": "6a924b56-3613-4b7f-a7c8-819bbe38387b",
            "type": "main",
            "index": 2
          }
        ],
        [
          {
            "node": "bc6731ac-f1aa-4594-a1a6-98275d976ea3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2201ba9e-40b8-4bcc-988c-e8dce2578dda": {
      "main": [
        [
          {
            "node": "6a924b56-3613-4b7f-a7c8-819bbe38387b",
            "type": "main",
            "index": 1
          }
        ],
        [
          {
            "node": "bc6731ac-f1aa-4594-a1a6-98275d976ea3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "bfc25242-766f-4b7d-ab23-a0829de1fe83": {
      "main": [
        [
          {
            "node": "3a5f6f97-c79a-4fed-b32a-fe7695e569f1",
            "type": "main",
            "index": 0
          },
          {
            "node": "7a062203-6a2e-4521-a98d-f1435f52ad17",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "46d785e4-fc5f-49ba-8aa6-ee6436621131": {
      "main": [
        [
          {
            "node": "989f3e60-1a1b-454c-b5f8-cdd27bf5c379",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "989f3e60-1a1b-454c-b5f8-cdd27bf5c379": {
      "main": [
        [
          {
            "node": "c51ef4bd-2234-486b-b0f1-2d40f0d00e00",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
자주 묻는 질문

이 워크플로우를 어떻게 사용하나요?

위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.

이 워크플로우는 어떤 시나리오에 적합한가요?

중급 - 시장 조사

유료인가요?

이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.

워크플로우 정보
난이도
중급
노드 수15
카테고리1
노드 유형8
난이도 설명

일정 경험을 가진 사용자를 위한 6-15개 노드의 중간 복잡도 워크플로우

외부 링크
n8n.io에서 보기

이 워크플로우 공유

카테고리

카테고리: 34