{
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "58c6003f-3311-448b-a949-4fbc22b38e2e",
      "name": "When clicking \u2018Test workflow\u2019",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -560,
        80
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "67e4f66c-256f-4e45-b98e-d2872a416ff5",
      "name": "Get all Users",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        80,
        100
      ],
      "parameters": {
        "url": "={{ $json.n8n_url }}",
        "options": {
          "pagination": {
            "pagination": {
              "parameters": {
                "parameters": [
                  {
                    "name": "cursor",
                    "value": "={{ $response.body.nextCursor }}"
                  }
                ]
              },
              "completeExpression": "={{ !$response.body.nextCursor }}",
              "paginationCompleteWhen": "other"
            }
          }
        },
        "sendQuery": true,
        "authentication": "predefinedCredentialType",
        "queryParameters": {
          "parameters": [
            {
              "name": "limit",
              "value": "5"
            }
          ]
        },
        "nodeCredentialType": "n8nApi"
      },
      "credentials": {
        "n8nApi": {
          "name": "<your credential>"
        },
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "2a66ddc7-5fde-4e2b-9ad6-7c68968214ae",
      "name": "Get all rows",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        80,
        -180
      ],
      "parameters": {
        "options": {},
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/15A3ZWzIBfONL4U_1XGJvtsS8HtMQ69qrpxd5C5L6Akg/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "15A3ZWzIBfONL4U_1XGJvtsS8HtMQ69qrpxd5C5L6Akg",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/15A3ZWzIBfONL4U_1XGJvtsS8HtMQ69qrpxd5C5L6Akg/edit?usp=drivesdk",
          "cachedResultName": "n8n-submission"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.5
    },
    {
      "id": "f220c6db-eafb-4bb5-9cbe-43edcf563a67",
      "name": "Get non-users",
      "type": "n8n-nodes-base.merge",
      "position": [
        620,
        -100
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "advanced": true,
        "joinMode": "keepNonMatches",
        "mergeByFields": {
          "values": [
            {
              "field1": "Email Address",
              "field2": "email"
            }
          ]
        },
        "outputDataFrom": "input1"
      },
      "typeVersion": 3
    },
    {
      "id": "906e8dde-4c58-4e93-9e07-3064a5dd60dd",
      "name": "Invite Users",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1100,
        -100
      ],
      "parameters": {
        "url": "={{ $('Edit Fields').item.json.n8n_url }}",
        "method": "POST",
        "options": {},
        "jsonBody": "={{ [$json] }}",
        "sendBody": true,
        "specifyBody": "json",
        "authentication": "predefinedCredentialType",
        "nodeCredentialType": "n8nApi"
      },
      "credentials": {
        "n8nApi": {
          "name": "<your credential>"
        },
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "195d0c33-611a-4a16-b62c-8ba1f4f31e19",
      "name": "Schedule Trigger",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -560,
        -160
      ],
      "parameters": {
        "rule": {
          "interval": [
            {}
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "dd453b5b-f238-43b1-8c44-2c3ed3a3d7ba",
      "name": "Edit Fields",
      "type": "n8n-nodes-base.set",
      "position": [
        -220,
        -20
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "c3a7a1ee-d1a2-4a29-b4b3-dcadf0fc16e2",
              "name": "n8n_url",
              "type": "string",
              "value": "https://{n8n-url}/api/v1/users"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "07e678c7-7c98-4f09-89d8-5e4d7d442a8f",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -280,
        -160
      ],
      "parameters": {
        "color": 4,
        "width": 230,
        "height": 300,
        "content": "## \uc774 \ub178\ub4dc\ub97c \ud3b8\uc9d1\ud558\uc138\uc694 \ud83d\udc47  \nn8n_url\uc744 \uadc0\ud558\uc758 \uc778\uc2a4\ud134\uc2a4 URL\ub85c \ubcc0\uacbd\ud558\uc138\uc694  \nhttps://docs.n8n.io/api/authentication/#call-the-api-using-your-key"
      },
      "typeVersion": 1
    },
    {
      "id": "2bfb10b6-220b-4c73-a15f-190412f2dda2",
      "name": "Create users list",
      "type": "n8n-nodes-base.set",
      "position": [
        880,
        -100
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "36282722-07ec-47b1-ab08-c649b7901ed7",
              "name": "email",
              "type": "string",
              "value": "={{ $json['Email Address'] }}"
            },
            {
              "id": "9b073e1d-8c16-45b1-b333-97dfe635eb73",
              "name": "role",
              "type": "string",
              "value": "global:member"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "221ca946-e305-4283-bca1-4289b8a7db28",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1000,
        -300
      ],
      "parameters": {
        "color": 4,
        "width": 371.1995072042308,
        "height": 600.88409546716,
        "content": "## n8n\uc5d0\uc11c Google \uc2a4\ud504\ub808\ub4dc\uc2dc\ud2b8\ub85c\ubd80\ud130 \uc0ac\uc6a9\uc790\ub97c \ucd08\ub300\ud558\uae30\n\uc774 \uc6cc\ud06c\ud50c\ub85c\ub294 n8n\uc5d0\uc11c \ubaa8\ub4e0 \uc0ac\uc6a9\uc790\ub97c \uac00\uc838\uc640 Google \uc2a4\ud504\ub808\ub4dc\uc2dc\ud2b8\uc758 \ud589\uacfc \ube44\uad50\ud558\uc5ec \uc0c8\ub85c\uc6b4 \uc0ac\uc6a9\uc790\ub97c \uc0dd\uc131\ud569\ub2c8\ub2e4.\n\n\uc0c8\ub85c\uc6b4 \uc0ac\uc6a9\uc790\uac00 \uc0dd\uc131\ub418\uba74 \ucd08\ub300 \uc774\uba54\uc77c\uc774 \ubcf4\ub0b4\uc9d1\ub2c8\ub2e4.\n\n\uc6cc\ud06c\ud50c\ub85c\ub97c \uc218\ub3d9\uc73c\ub85c \uc2e4\ud589\ud558\uac70\ub098 \uc77c\uc815\uc5d0 \ub530\ub77c \uc2e4\ud589\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.\n\n## \uc2a4\ud504\ub808\ub4dc\uc2dc\ud2b8 \ud15c\ud50c\ub9bf\n\n\uc2dc\ud2b8 \uc5f4\uc740 Squarespace \ub274\uc2a4\ub808\ud130 \ube14\ub85d \uc5f0\uacb0\uc5d0\uc11c \uc601\uac10\uc744 \ubc1b\uc558\uc73c\ub098, \uc0c8 \uc5f4 \ud615\uc2dd\uc744 \uc801\uc6a9\ud558\uae30 \uc704\ud574 \ub178\ub4dc\ub97c \ubcc0\uacbd\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.\n\n\uc5ec\uae30\uc5d0\uc11c [\uc0d8\ud50c \uc2dc\ud2b8](https://docs.google.com/spreadsheets/d/1wi2Ucb4b35e0-fuf-96sMnyzTft0ADz3MwdE_cG_WnQ/edit?usp=sharing)\ub97c \ubcf5\uc81c\ud558\uc138\uc694.\n- \uc81c\ucd9c\uc77c\n- \uc774\uba54\uc77c \uc8fc\uc18c\n- \uc774\ub984"
      },
      "typeVersion": 1
    },
    {
      "id": "c956e102-7fe3-4ee4-90e0-32cb11556c2c",
      "name": "Combine all paginated results",
      "type": "n8n-nodes-base.code",
      "position": [
        320,
        100
      ],
      "parameters": {
        "jsCode": "let results = [];\nfor (let i = 0; i < $input.all().length; i++) {\n  results = results.concat($input.all()[i].json.data);\n}\n\nreturn results;"
      },
      "typeVersion": 2
    }
  ],
  "connections": {
    "Edit Fields": {
      "main": [
        [
          {
            "node": "Get all rows",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get all Users",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get all rows": {
      "main": [
        [
          {
            "node": "Get non-users",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get all Users": {
      "main": [
        [
          {
            "node": "Combine all paginated results",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get non-users": {
      "main": [
        [
          {
            "node": "Create users list",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "Edit Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create users list": {
      "main": [
        [
          {
            "node": "Invite Users",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Combine all paginated results": {
      "main": [
        [
          {
            "node": "Get non-users",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "When clicking \u2018Test workflow\u2019": {
      "main": [
        [
          {
            "node": "Edit Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}