In this guide, you will learn how to integrate the ProcessMaker app into third-party applications using web hooks to initiate new process requests. This integration allows you to seamlessly kick off workflow processes within the ProcessMaker environment from your own application.
By the end of this guide, you will have accomplished the following:
Prerequisites
Before proceeding with the guide, it's important to assess your skill level as a developer. The following skills and knowledge are highly recommended to ensure a smooth implementation: web hooks and API.
Steps to Integrate ProcessMaker using Web Hooks
By following the steps below, seamlessly integrate your ProcessMaker's workflow/process into your application to initiate new requests.
Step 1: Configure Web Hook in ProcessMaker
To seamlessly integrate ProcessMaker workflow/processes using web hooks begin by generating the web hook. Follow this example to generate the ProcessMaker web hook.
Based on the screen/form variables that you've defined within the ProcessMaker platform for your process, ensure to adjust the below example with your defined ProcessMaker form variables.
Example that shows the JSON data you need to send to the webhook:
Payload
{"companyName":"InsuCare","email":"john.doe@insucare.com","serviceArea":"123 Boeing Avenue","typeBusiness":"Insurance","country":"United States","products":"Laptop"}
Postman Example
Below is an illustrative example demonstrating the utilization of the web hook through Postman to trigger the API and initiate a request.
Step 2: Integrate the Web Hook into Your Application
Now, that you have the web hook link, identify the appropriate location within your application to integrate the ProcessMaker workflow/process form. This could be a specific page, a modal window, or any other suitable area.
Below is a straightforward illustration showcasing how the integration can be implemented within a web application. Feel free to utilize the provided sample HTML code as a starting point:
Step 3: Customize the Form and Attributes (Optional)
You can customize the form attributes according to your requirements. For example, you can adjust the form fields, font size, and other attributes of the form to fit your application's design and layout.
Step 4: Test and Verify the Integration
Save your changes and reload your Web application. Ensure to change the web hook generated in the previous step inside the html template. Test the functionality of the form, such as submitting a new request to ensure that everything works as expected.
Output Preview: ProcessMaker Integration using web hooks into a third-party application
After you have completed the steps above, verify the form inside your application, initiate requests, and make sure it sends the information to the web hook.
Conclusion
By following the steps outlined in this guide, you can integrate the ProcessMaker's forms into your Web application using Web Hooks to initiate new requests.
Requirement
Function
Version
ProcessMaker Platform
Access to the ProcessMaker app with administrative privileges.
4.6+
Code Editor
Choose a code editor of your choice that suits your preferences. Popular code editors for development include Visual Studio Code, Sublime Text, and Atom.