Skip to main content

Testing the Prediction Studio APIs

2 Tâches

10 mins

Visible par : All users Applies to: Pega Customer Decision Hub '26
Débutant
Anglais

Scénario

The Prediction Studio APIs facilitate the monitoring and management of predictions remotely, using the scripting language of your choice. They offer endpoints for various operations, such as getting a list of Predictions and their attributes, introducing a challenge model, and more. These operations are categorized under Data export, Models, Reporting, Predictions, and Prediction Studio. As a System Admin, you generate the client credentials that provide access to the APIs, and then inspect the API responses.

Use the following credentials to log in to the exercise system:

Role User name Password
System Admin SystemAdmin rules

Your assignment consists of the following tasks:

Task 1: Generate a Client ID and a Client Secret

Generate a Client ID and a Client Secret for access to the Prediction Studio APIs.

Task 2: Inspect the API responses

Use REST calls to try out the Prediction Studio APIs.

Vous devez initier votre votre propre instance Pega pour compléter ce Défi.

L'initialisation peut prendre jusqu'à 5 minutes, donc soyez patient.

Présentation du défi

Détail des tâches

1 Generate a Client ID and a Client Secret

  1. Log in as a System Architect:
    1. In the User name field, enter SystemAdmin.
    2. In the Password field, enter rules.
  2. In the header of Infinity Studio, click Create > Security > OAuth 2.0 Client Registration to create a new OAuth 2.0 Client Registration.
  3. In the OAuth 2.0 Client Registration Short description field, enter Prediction APIs.
  4. In the Client Name field, enter PegaClient.
  5. Click Create and open.
  6. Configure the Client Registration:
    1. In the Supported grant types section, select Client credentials, and then, in the Operator ID field, enter or select DataScientist.
    2. In the Client Credentials section, click View & download, and then click Download credentials.
    3. Securely store the PegaClient_ClientCredentials text file that contains the Client ID and the Client Secret for later reference.
  7. Close the dialog boxes, and then click Save to complete the OAuth 2.0 Client Registration.

2 Inspect the API responses

  1. In the left navigation of Infinity Studio, click Channels > Pega API.
  2. In the Service package field, select Prediction APIs, and then click Authorize.
  3. In the ClientCredentials (OAuth2, clientCredentials) section, enter the Client ID and the Client Secret from the PegaClient_ClientCredentials text file that you saved in the previous task, and then click Authorize.
Credentials
  1. Confirm that the client is authorized, and then click Close.
  2. In the Predictions section, click the GET /V3/prediction API to list the models that are part of the application.
Get Prediction API
  1. Click Try it out, and then click Execute.
  2. Review the content of the server response body, and take note of the predictionId of the Predict Web Propensity prediction.
Predict Web Propensity
  1. In the Prediction section, click the GET /v3/predictions/{predictionID} API to get a description of the prediction, and then click Try it out.
Prediction
  1. In the predictionID field, enter DATA-DECISION-REQUEST-CUSTOMER-CDH!PREDICTWEBPROPENSITY to get a description of the Predict Web Propensity prediction, and then click Execute.
  2. In the server response body, review the adaptive models that drive the prediction, and take note of the modelID that acts at the customer level, and the modelling technique.
  3. In the Models section, click the GET /V2/models/{modelID} API to get a description of a model, and click Try it out.
  4. In the modelID field, enter Data-Decision-Request-Customer-CDH!Web_Click_Through_Rate_GB_Customer, and click Execute.
  5. In the server response body, review the labels and the predictors.
Server response
  1. In the upper right corner, click the user icon and select Log off.


Disponible dans la mission suivante :

If you are having problems with your training, please review the Pega Academy Support FAQs.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice