Zappy Docs

Creating Custom Zappy Actions

Creating a Custom Action

Action is the building block of process automation. Zappy Task Editor comes with various built-in Template Actions. You can read The Zappy Activities Guide for more details and examples, additionally, you can create custom activities to better automate processes based on your requirements.

There are two major steps required to create a custom action:

  1. Write your own code for custom action.

  2. Add an external assembly (.dll or. nupkg) in Zappy Task Editor.


Note: Please note that the following component is required to create a custom action:

• Microsoft Visual Studio with .NET desktop development.

How to write Custom Action Code:

To better understand how to write code for a custom action, we are going to create one action which asks the user for a string and then displays it in the message box.

  1. Launch Microsoft Visual Studio.
  2. Click File- > New -> Project.
  3. Click on Visual C#. The list of all dependencies of C# will display. Select Class Library (.NET Framework) and then click OK.
  1. Give the name for your newly created project. You Must add “Zappy” before Project Name. In our case, Project name is “CustomAction” so we used “Zappy.CustomAction” as the name of this Project.

After you click on OK, you will get the code as shown below.

  1. In Solution Explore Click Project -> Add Reference -> Manage NuGet Packages….
  1. Search for the Zappy.SharedInterface, Install this Interface.
  1. Rename “Class.cs” according to your action behavior or keep it as it is, then inherits the “TemplateAction” as shown below.
  1. Write the code for your custom activity and Execute.
    Please consider the sample code in the below code snippet.
  1. Add external assembly in “Zappy task editor”. You can do this in two ways.
    A] Add Nuget package in the zappy task editor
    1.Right click on Zappy Icon > Option > Nuget Manager
      2. Click on Install **Nuget Package** button                 
    3. Select the ***. nupkg** package which is recently created. 
    4. Launch Zappy task editor. custom activity is added at the end of all activities.

B] Add *.dll file in zappy task editor
1.Right click on *Zappy Icon -> Option -> Nuget Manager

      2.Click on **Load Dll** Button 
       3.   Select the ***.dll** file to load. 
       4.   Launch zappy task editor. Activity is added at the end of all activities.

Updated about a year ago

Creating Custom Zappy Actions

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.