Discussion
Pegasystems Inc.
JP
Last activity: 20 Dec 2021 11:44 EST
How to call an activity from batch file
Hi,
In this post I am sharing how to call an activity from outside of PRPC such as batch file for Windows, shell for UNIX. In summary, the easiest way to do this is to wrap your activity in a Service HTTP and call it from either wget or curl command.
URL:
http://<host>:<port>/prweb/PRHTTPService/<service package>/<service class>/<service method>?<parameter name=parameter value>&<parameter name=parameter value>
Steps:
1. Create an activity.
2. Create a Service Package.
3. Create a Service HTTP rule.
4. Call it from wget or curl.
I have documented How-to as attached. Hope this helps. FYI, I also shared how to do reverse - call batch file from an activity in another post (https://collaborate.pega.com/discussion/how-call-os-command-activity).
Thanks,