Invoking a REST service rule
Call a REST service rule from an external system to invoke an action in your application or retrieve data from Pega Platform. For example, you can call a REST service to get the details of a case or assignment. You can specify the application context in which to run the API by using the application alias URL.
- To call a REST service rule, use
api
in the URL, and append the three-part key to the rule to the URL. Use the following syntax:https://appname.pegacloud.io/contextroot/api/packageName/version/resourcepathURL
Although you can still call a REST service by specifying/PRRestService
, as a best practice, useapi
. - To call an authenticated REST service in the context of the access group of a
specific application, specify the application alias in the endpoint URL:If your application does not have an application alias, the system uses the application identifier.
- For non-multitenant environments, enter: http://host/prweb/<servletname>/app/appAlias/api/<service package>/...
- For multitenant environments, enter: http://host/prweb/<servletname>/app/appAlias/api/TenantHash/<service package>/...
- For calls without a servlet, enter: http://host/prweb/app/appAlias/api/<service package>/...
- For API service packages, enter: http://host/prweb/app/appAlias/api/...
Previous topic Automatically purging invocation history Next topic JSON data transforms