grandfathermagic

Google drive to an email

Jun 28th, 2024
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JSON 16.24 KB | None | 0 0
  1. {
  2.     "name": "Integration Google Drive, Gmail",
  3.     "flow": [
  4.         {
  5.             "id": 3,
  6.             "module": "google-drive:watchFilesInAFolder",
  7.             "version": 4,
  8.             "parameters": {
  9.                 "limit": 30,
  10.                 "select": "create",
  11.                 "folderId": "/ID",
  12.                 "mimeType": "all",
  13.                 "__IMTCONN__": 2056608,
  14.                 "destination": "drive"
  15.             },
  16.             "mapper": {},
  17.             "metadata": {
  18.                 "designer": {
  19.                     "x": 0,
  20.                     "y": 0
  21.                 },
  22.                 "restore": {
  23.                     "parameters": {
  24.                         "select": {
  25.                             "label": "By Created Time"
  26.                         },
  27.                         "folderId": {
  28.                             "path": [
  29.                                 "שם התיקייה"
  30.                             ]
  31.                         },
  32.                         "mimeType": {
  33.                             "label": "All"
  34.                         },
  35.                         "__IMTCONN__": {
  36.                             "data": {
  37.                                 "scoped": "true",
  38.                                 "connection": "google-restricted"
  39.                             },
  40.                             "label": "My Google connectionכאן נכנס שם החשבון שלנו "
  41.                         },
  42.                         "destination": {
  43.                             "label": "My Drive"
  44.                         }
  45.                     }
  46.                 },
  47.                 "parameters": [
  48.                     {
  49.                         "name": "__IMTCONN__",
  50.                         "type": "account:google-restricted",
  51.                         "label": "Connection",
  52.                         "required": true
  53.                     },
  54.                     {
  55.                         "name": "select",
  56.                         "type": "select",
  57.                         "label": "Watch Files",
  58.                         "required": true,
  59.                         "validate": {
  60.                             "enum": [
  61.                                 "create",
  62.                                 "modify"
  63.                             ]
  64.                         }
  65.                     },
  66.                     {
  67.                         "name": "destination",
  68.                         "type": "select",
  69.                         "label": "Choose a Drive",
  70.                         "required": true,
  71.                         "validate": {
  72.                             "enum": [
  73.                                 "drive",
  74.                                 "share",
  75.                                 "team"
  76.                             ]
  77.                         }
  78.                     },
  79.                     {
  80.                         "name": "mimeType",
  81.                         "type": "select",
  82.                         "label": "File Types to Watch",
  83.                         "required": true,
  84.                         "validate": {
  85.                             "enum": [
  86.                                 "all",
  87.                                 "document",
  88.                                 "spreadsheet",
  89.                                 "slide",
  90.                                 "drawing"
  91.                             ]
  92.                         }
  93.                     },
  94.                     {
  95.                         "name": "limit",
  96.                         "type": "uinteger",
  97.                         "label": "Limit",
  98.                         "required": true
  99.                     },
  100.                     {
  101.                         "name": "folderId",
  102.                         "type": "folder",
  103.                         "label": "Select the Folder to be Watched",
  104.                         "required": true
  105.                     }
  106.                 ]
  107.             }
  108.         },
  109.         {
  110.             "id": 5,
  111.             "module": "google-drive:getAFile",
  112.             "version": 4,
  113.             "parameters": {
  114.                 "__IMTCONN__": 2056608
  115.             },
  116.             "mapper": {
  117.                 "file": "{{3.id}}",
  118.                 "select": "map",
  119.                 "formatDrawings": "image/jpeg",
  120.                 "formatDocuments": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
  121.                 "formatSpreadsheets": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
  122.                 "formatPresentations": "application/vnd.openxmlformats-officedocument.presentationml.presentation"
  123.             },
  124.             "metadata": {
  125.                 "designer": {
  126.                     "x": 300,
  127.                     "y": 0
  128.                 },
  129.                 "restore": {
  130.                     "expect": {
  131.                         "select": {
  132.                             "label": "Enter manually"
  133.                         },
  134.                         "formatDrawings": {
  135.                             "label": "JPEG"
  136.                         },
  137.                         "formatDocuments": {
  138.                             "label": "MS Word Document"
  139.                         },
  140.                         "formatSpreadsheets": {
  141.                             "label": "MS Excel"
  142.                         },
  143.                         "formatPresentations": {
  144.                             "label": "MS PowerPoint"
  145.                         }
  146.                     },
  147.                     "parameters": {
  148.                         "__IMTCONN__": {
  149.                             "data": {
  150.                                 "scoped": "true",
  151.                                 "connection": "google-restricted"
  152.                             },
  153.                             "label": "My Google connection (שם החשבון שלנו)"
  154.                         }
  155.                     }
  156.                 },
  157.                 "parameters": [
  158.                     {
  159.                         "name": "__IMTCONN__",
  160.                         "type": "account:google-restricted",
  161.                         "label": "Connection",
  162.                         "required": true
  163.                     }
  164.                 ],
  165.                 "expect": [
  166.                     {
  167.                         "name": "select",
  168.                         "type": "select",
  169.                         "label": "Enter a File ID",
  170.                         "required": true,
  171.                         "validate": {
  172.                             "enum": [
  173.                                 "map",
  174.                                 "value"
  175.                             ]
  176.                         }
  177.                     },
  178.                     {
  179.                         "name": "formatDocuments",
  180.                         "type": "select",
  181.                         "label": "Convert Google Documents Files to Format",
  182.                         "required": true,
  183.                         "validate": {
  184.                             "enum": [
  185.                                 "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
  186.                                 "application/pdf",
  187.                                 "application/vnd.oasis.opendocument.text",
  188.                                 "text/html",
  189.                                 "text/plain",
  190.                                 "application/rtf"
  191.                             ]
  192.                         }
  193.                     },
  194.                     {
  195.                         "name": "formatSpreadsheets",
  196.                         "type": "select",
  197.                         "label": "Convert Google Spreadsheets Files to Format",
  198.                         "required": true,
  199.                         "validate": {
  200.                             "enum": [
  201.                                 "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
  202.                                 "application/x-vnd.oasis.opendocument.spreadsheet",
  203.                                 "application/pdf"
  204.                             ]
  205.                         }
  206.                     },
  207.                     {
  208.                         "name": "formatPresentations",
  209.                         "type": "select",
  210.                         "label": "Convert Google Slides Files to Format",
  211.                         "required": true,
  212.                         "validate": {
  213.                             "enum": [
  214.                                 "application/vnd.openxmlformats-officedocument.presentationml.presentation",
  215.                                 "application/pdf"
  216.                             ]
  217.                         }
  218.                     },
  219.                     {
  220.                         "name": "formatDrawings",
  221.                         "type": "select",
  222.                         "label": "Convert Google Drawings Files to Format",
  223.                         "required": true,
  224.                         "validate": {
  225.                             "enum": [
  226.                                 "image/jpeg",
  227.                                 "image/png",
  228.                                 "image/svg+xml",
  229.                                 "application/pdf"
  230.                             ]
  231.                         }
  232.                     },
  233.                     {
  234.                         "name": "file",
  235.                         "type": "text",
  236.                         "label": "File ID",
  237.                         "required": true
  238.                     }
  239.                 ]
  240.             }
  241.         },
  242.         {
  243.             "id": 4,
  244.             "module": "builtin:BasicAggregator",
  245.             "version": 1,
  246.             "parameters": {
  247.                 "target": "2.attachments",
  248.                 "feeder": 3
  249.             },
  250.             "mapper": {
  251.                 "fileName": "{{5.name}}",
  252.                 "data": "{{5.data}}"
  253.             },
  254.             "metadata": {
  255.                 "designer": {
  256.                     "x": 600,
  257.                     "y": 0
  258.                 },
  259.                 "restore": {
  260.                     "extra": {
  261.                         "feeder": {
  262.                             "label": "Google Drive - Watch Files in a Folder "
  263.                         },
  264.                         "target": {
  265.                             "label": "Attachments"
  266.                         }
  267.                     }
  268.                 },
  269.                 "expect": [
  270.                     {
  271.                         "name": "fileName",
  272.                         "type": "filename",
  273.                         "label": "File name",
  274.                         "required": true
  275.                     },
  276.                     {
  277.                         "name": "data",
  278.                         "type": "buffer",
  279.                         "label": "Data",
  280.                         "required": true
  281.                     }
  282.                 ],
  283.                 "advanced": true
  284.             },
  285.             "flags": {
  286.                 "stopIfEmpty": true
  287.             }
  288.         },
  289.         {
  290.             "id": 2,
  291.             "module": "google-email:ActionCreateDraft",
  292.             "version": 2,
  293.             "parameters": {
  294.                 "account": 2056608
  295.             },
  296.             "mapper": {
  297.                 "folder": "[Gmail]/Drafts",
  298.                 "to": "[email protected]",
  299.                 "subject": "{{3.name}}דוח חדש",
  300.                 "html": "היי מצורף קובץ חדש לטובת הדוח",
  301.                 "attachments": "{{4.array}}",
  302.                 "cc": [],
  303.                 "bcc": []
  304.             },
  305.             "metadata": {
  306.                 "designer": {
  307.                     "x": 900,
  308.                     "y": 0
  309.                 },
  310.                 "restore": {
  311.                     "parameters": {
  312.                         "account": {
  313.                             "label": "My Google connection ([email protected])",
  314.                             "data": {
  315.                                 "scoped": "true",
  316.                                 "connection": "google-restricted"
  317.                             }
  318.                         }
  319.                     },
  320.                     "expect": {
  321.                         "folder": {
  322.                             "mode": "chose",
  323.                             "path": [
  324.                                 "Drafts",
  325.                                 "Drafts"
  326.                             ]
  327.                         },
  328.                         "to": {
  329.                             "mode": "edit"
  330.                         },
  331.                         "attachments": {
  332.                             "mode": "edit"
  333.                         },
  334.                         "cc": {
  335.                             "mode": "chose"
  336.                         },
  337.                         "bcc": {
  338.                             "mode": "chose"
  339.                         }
  340.                     }
  341.                 },
  342.                 "parameters": [
  343.                     {
  344.                         "name": "account",
  345.                         "type": "account:google-restricted",
  346.                         "label": "Connection",
  347.                         "required": true
  348.                     }
  349.                 ],
  350.                 "expect": [
  351.                     {
  352.                         "name": "folder",
  353.                         "type": "folder",
  354.                         "label": "Folder",
  355.                         "required": true
  356.                     },
  357.                     {
  358.                         "name": "to",
  359.                         "type": "array",
  360.                         "label": "To",
  361.                         "spec": {
  362.                             "name": "value",
  363.                             "type": "email",
  364.                             "label": "Email address",
  365.                             "required": true
  366.                         }
  367.                     },
  368.                     {
  369.                         "name": "subject",
  370.                         "type": "text",
  371.                         "label": "Subject"
  372.                     },
  373.                     {
  374.                         "name": "html",
  375.                         "type": "text",
  376.                         "label": "Content"
  377.                     },
  378.                     {
  379.                         "name": "attachments",
  380.                         "type": "array",
  381.                         "label": "Attachments",
  382.                         "spec": [
  383.                             {
  384.                                 "name": "fileName",
  385.                                 "label": "File name",
  386.                                 "type": "filename",
  387.                                 "required": true,
  388.                                 "semantic": "file:name"
  389.                             },
  390.                             {
  391.                                 "name": "data",
  392.                                 "label": "Data",
  393.                                 "type": "buffer",
  394.                                 "required": true,
  395.                                 "semantic": "file:data"
  396.                             }
  397.                         ]
  398.                     },
  399.                     {
  400.                         "name": "cc",
  401.                         "type": "array",
  402.                         "label": "Copy recipient",
  403.                         "spec": {
  404.                             "name": "value",
  405.                             "type": "email",
  406.                             "label": "Email address",
  407.                             "required": true
  408.                         }
  409.                     },
  410.                     {
  411.                         "name": "bcc",
  412.                         "type": "array",
  413.                         "label": "Blind copy recipient",
  414.                         "spec": {
  415.                             "name": "value",
  416.                             "type": "email",
  417.                             "label": "Email address",
  418.                             "required": true
  419.                         }
  420.                     }
  421.                 ],
  422.                 "advanced": true
  423.             }
  424.         }
  425.     ],
  426.     "metadata": {
  427.         "instant": false,
  428.         "version": 1,
  429.         "scenario": {
  430.             "roundtrips": 1,
  431.             "maxErrors": 3,
  432.             "autoCommit": true,
  433.             "autoCommitTriggerLast": true,
  434.             "sequential": false,
  435.             "slots": null,
  436.             "confidential": false,
  437.             "dataloss": false,
  438.             "dlq": false,
  439.             "freshVariables": false
  440.         },
  441.         "designer": {
  442.             "orphans": []
  443.         },
  444.         "zone": "eu2.make.com"
  445.     }
  446. }
Add Comment
Please, Sign In to add comment