{
  "name": "Create and manage ERC-20 tokens with a Telegram bot and 1Shot API wallets",
  "nodes": [
    {
      "id": "190f0744-a2ae-44c7-bb83-6fe2a88d5313",
      "name": "Telegram Trigger",
      "type": "n8n-nodes-base.telegramTrigger",
      "position": [
        0,
        256
      ]
    },
    {
      "id": "0033526f-8621-4682-a54e-91ac5cfbb468",
      "name": "Create a User Wallet",
      "type": "n8n-nodes-1shot.oneShot",
      "position": [
        1120,
        784
      ]
    },
    {
      "id": "2881403f-63ea-4cee-83e8-d465ed3f3af8",
      "name": "Send User Wallet Address",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1568,
        784
      ]
    },
    {
      "id": "6607bc9e-1e64-4592-9815-8f7fca3b49d4",
      "name": "Switch on User Button Choice",
      "type": "n8n-nodes-base.switch",
      "position": [
        672,
        -48
      ]
    },
    {
      "id": "de644b74-bbb9-4122-95dd-03e4a18e1402",
      "name": "Send Action Keyboard Options",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1344,
        592
      ]
    },
    {
      "id": "430f6c1b-f7f7-48c3-bf44-e9326dfa8fc3",
      "name": "Get the name of the token",
      "type": "n8n-nodes-base.telegram",
      "position": [
        896,
        -416
      ]
    },
    {
      "id": "50d56b8e-6685-4cab-a57d-b14f2301275b",
      "name": "Get the token Symbol",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1120,
        -416
      ]
    },
    {
      "id": "01f7be1b-e7a2-44a0-bd60-2864b4e6967e",
      "name": "Creation Confirmation",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1552,
        -416
      ]
    },
    {
      "id": "bee6518b-9f87-4951-bf9d-36c6e18922a0",
      "name": "Reply with Token Address",
      "type": "n8n-nodes-base.telegram",
      "position": [
        2224,
        -512
      ]
    },
    {
      "id": "c25342da-c718-4fa7-874b-2f0427d03838",
      "name": "Try Again",
      "type": "n8n-nodes-base.telegram",
      "position": [
        2000,
        -320
      ]
    },
    {
      "id": "05bc850b-8d8a-45d6-a0ab-b0c866755b45",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -272,
        -32
      ],
      "parameters": {
        "width": 624,
        "height": 448,
        "content": "## Telegram Entrypoint\n\nTrigger the workflows on either a message from a user in a DM or a callback query from a inline keyboard\n\nIMPORTANT - for this template, the chatid is used at the immutable id "
      }
    },
    {
      "id": "388e847c-322f-42c4-a020-d09abe4f893c",
      "name": "Check for Existing User",
      "type": "n8n-nodes-base.dataTable",
      "position": [
        672,
        688
      ]
    },
    {
      "id": "aee06c0a-1e0c-4a8b-aed9-6663d003d4c5",
      "name": "Only respond to /start Messages",
      "type": "n8n-nodes-base.if",
      "position": [
        448,
        688
      ]
    },
    {
      "id": "6ae12b5c-0a77-4132-9bd3-29153053f512",
      "name": "Does the User Have A Wallet",
      "type": "n8n-nodes-base.if",
      "position": [
        896,
        688
      ]
    },
    {
      "id": "4cd5acd3-4c0f-4372-8855-129c85459f69",
      "name": "Record User Wallet",
      "type": "n8n-nodes-base.dataTable",
      "position": [
        1344,
        784
      ]
    },
    {
      "id": "b27531d9-e778-4764-a523-ab1b0bdd02f2",
      "name": "Callback or Message",
      "type": "n8n-nodes-base.switch",
      "position": [
        224,
        256
      ]
    },
    {
      "id": "63d96d7c-6c2f-4fef-9e24-2cbbc3e78788",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        368,
        -256
      ],
      "parameters": {
        "width": 448,
        "height": 432,
        "content": "## Handle Keyboard Options\n\nThe keyboard callback options are set in \"Send Action Keyboard Options\". This node switches on the user selections.\n\nThe branch should only be triggered once the user has a"
      }
    },
    {
      "id": "ee684de6-f4c8-4208-87e5-71a4d78f3a3b",
      "name": "Get User's Tokens",
      "type": "n8n-nodes-base.dataTable",
      "position": [
        896,
        416
      ]
    },
    {
      "id": "7a8f9854-2baf-4bdf-9cca-164efd8efb6d",
      "name": "Generate Message",
      "type": "n8n-nodes-base.code",
      "position": [
        1120,
        416
      ]
    },
    {
      "id": "1b8a011d-3600-4cad-af9a-49dc8ad10628",
      "name": "Record New Token",
      "type": "n8n-nodes-base.dataTable",
      "position": [
        2000,
        -512
      ]
    },
    {
      "id": "64ca9c9e-7053-4574-847f-d743e3e99d6c",
      "name": "Lookup User Wallet",
      "type": "n8n-nodes-base.dataTable",
      "position": [
        448,
        -32
      ]
    },
    {
      "id": "9bb3a6ab-fdd9-4ab2-b2f2-e87bda8947a2",
      "name": "Get User Wallet Balance",
      "type": "n8n-nodes-1shot.oneShot",
      "position": [
        1120,
        592
      ]
    },
    {
      "id": "62abadc9-492f-497b-901a-9e989a1891ca",
      "name": "Which Token?",
      "type": "n8n-nodes-base.telegram",
      "position": [
        896,
        32
      ]
    },
    {
      "id": "6129c127-91e0-4a57-9390-b371151af114",
      "name": "How Many?",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1120,
        32
      ]
    },
    {
      "id": "3b54f188-dbf6-4981-9183-3a6f86f20478",
      "name": "To What Address?",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1344,
        32
      ]
    },
    {
      "id": "51776ea7-0b98-4f7d-9b3c-621027b26cae",
      "name": "Reply with TX Hash",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1792,
        -64
      ]
    },
    {
      "id": "ccc1a477-b8db-409f-905d-15fffbd4b4db",
      "name": "Send Token List",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1344,
        416
      ]
    },
    {
      "id": "9774fd62-ec06-4ffd-9331-06a386638e4b",
      "name": "Send Tokens",
      "type": "n8n-nodes-1shot.oneShotSynch",
      "position": [
        1568,
        32
      ]
    },
    {
      "id": "64b90b35-5bb8-4dd9-933e-b7ea3b426320",
      "name": "Failure to Send Tokens",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1792,
        128
      ]
    },
    {
      "id": "6f5c8f10-d163-4334-a3d8-8bad4a2b16a5",
      "name": "Deploy User Token",
      "type": "n8n-nodes-1shot.oneShotSynch",
      "position": [
        1760,
        -416
      ]
    },
    {
      "id": "3d2b990f-663a-4f40-9e10-2774c43c7a3e",
      "name": "Max Supply",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1328,
        -416
      ]
    },
    {
      "id": "3cfa9fa7-d866-428b-a17c-cd8bdb040e1c",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        848,
        -656
      ],
      "parameters": {
        "width": 1568,
        "height": 480,
        "content": "## Deploy ERC-20 Tokens with the 1Shot Token Factory\n\nThis template uses the [1Shot Token Factory](https://github.com/1Shot-API/1Shot-Token-Factory) to deploy standard ERC-20 tokens. You can clone thi"
      }
    },
    {
      "id": "56963c95-cb8e-4bd0-926a-f0036afe7580",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -320,
        -1024
      ],
      "parameters": {
        "width": 664,
        "height": 988,
        "content": "# Create Your Own Telegram Crypto Bot\nThis workflow template can be used as a starting point for your own Telegram bot that creates wallets for your users that they can use for making onchain transact"
      }
    },
    {
      "id": "e42798a1-f205-4aaf-b6d7-eea01323dfcc",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        336,
        576
      ],
      "parameters": {
        "width": 1488,
        "height": 688,
        "content": "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n## Main User Entrypoint\n\nThe user can only trigger the bot by sending the `/start` command; customize this for your purposes. \n\n### Wallets\n\nThe first time a user triggers your "
      }
    },
    {
      "id": "50ae176c-1735-4eae-a92d-924cd51d802f",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        848,
        304
      ],
      "parameters": {
        "width": 704,
        "height": 256,
        "content": "## Send the User's Currently Deployed Token Addresses\n\nThis branch is triggered when the user clicks the inline keyboard option `See My Tokens`. "
      }
    },
    {
      "id": "7ebaa184-2854-429b-bb6d-c66c668266e4",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        848,
        -160
      ],
      "parameters": {
        "width": 1136,
        "height": 448,
        "content": "## Send Tokens Using the User's Wallet\n\nThis branch is triggered when the user asks to send tokens using the inline keyboard. The transaction will be submitted from their wallet against their token us"
      }
    }
  ],
  "connections": {
    "How Many?": {
      "main": [
        [
          {
            "node": "To What Address?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Max Supply": {
      "main": [
        [
          {
            "node": "Creation Confirmation",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send Tokens": {
      "main": [
        [
          {
            "node": "Reply with TX Hash",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Failure to Send Tokens",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Which Token?": {
      "main": [
        [
          {
            "node": "How Many?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Message": {
      "main": [
        [
          {
            "node": "Send Token List",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Record New Token": {
      "main": [
        [
          {
            "node": "Reply with Token Address",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Telegram Trigger": {
      "main": [
        [
          {
            "node": "Callback or Message",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "To What Address?": {
      "main": [
        [
          {
            "node": "Send Tokens",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Deploy User Token": {
      "main": [
        [
          {
            "node": "Record New Token",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Try Again",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get User's Tokens": {
      "main": [
        [
          {
            "node": "Generate Message",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Lookup User Wallet": {
      "main": [
        [
          {
            "node": "Switch on User Button Choice",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Record User Wallet": {
      "main": [
        [
          {
            "node": "Send User Wallet Address",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Callback or Message": {
      "main": [
        [
          {
            "node": "Lookup User Wallet",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Only respond to /start Messages",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create a User Wallet": {
      "main": [
        [
          {
            "node": "Record User Wallet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get the token Symbol": {
      "main": [
        [
          {
            "node": "Max Supply",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Creation Confirmation": {
      "main": [
        [
          {
            "node": "Deploy User Token",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check for Existing User": {
      "main": [
        [
          {
            "node": "Does the User Have A Wallet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get User Wallet Balance": {
      "main": [
        [
          {
            "node": "Send Action Keyboard Options",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get the name of the token": {
      "main": [
        [
          {
            "node": "Get the token Symbol",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Does the User Have A Wallet": {
      "main": [
        [
          {
            "node": "Get User Wallet Balance",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Create a User Wallet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Switch on User Button Choice": {
      "main": [
        [
          {
            "node": "Get the name of the token",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Which Token?",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Get User's Tokens",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Only respond to /start Messages": {
      "main": [
        [
          {
            "node": "Check for Existing User",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}