Create a Floder to MID Server by Flow Designer

chunn
Tera Expert

Hi,Can you tell me?

I Want to  create a folder on the MID server with the incident number as the folder name when an incident is raised in ServiceNow by Flow Designer.

by the way How does MID Server appear in Flow Designer?

Best!

6 REPLIES 6

Appli
Mega Sage
Mega Sage

Hi, activating Integration Hub adds integration steps to the Action Designer interface; so you can make your own Action in Flow Designer with, for example, PowerShell step that allows to execute the script on the target host. Trigger for the flow - new record created in Incident table, Input for the action will be INC ID, command to run - creating a new folder.

Hope it helps

Hope it helps

Hi, Thank you for your reply.

Can you tell me the detailed steps?

Now My PDI Integration Hub is activated. How can I do  about PowerShell Step.

Hi, let me try

1) Add MID server to the instance (might be done already)

2) Specify User Credentials to login to MID server

3) Go to Flow Designer, Create new Action (for example with a name "Create_Folder") there with one input variable of String type

4) Add PowerShell step (should be available under INTEGRATIONS)

5) Choose input variable for the step, set Inline Script as Script type and put the command to be executed. Like the one below that will create a new folder (with the Incident ID' name) in the C: drive. 

New-Item -Path "c:\" -Name "$variable" -ItemType "directory"

Save and Publish an Action

6) Create a new Flow that has a trigger (Incident created) and one action created above.  Incident number from Trigger will be an input for the action created above. Save and Publish the flow.

7) Test by raising a new Incident 🙂

Hope it helps

Hope it helps

Hi, thank you very much for help to me.

4) Add PowerShell step (should be available under INTEGRATIONS)

I have not the PowerShell step under Integrations . I need to what install the plugin .

6) step 

create a new flow and how to relate to one action created above.

Best!