Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Pega Customer Service chat security configuration API

Updated on January 29, 2021

Pega Customer Service chat security configuration API to access and modify chat parameters in Pega Cloud, including the rate of new messages, the connection requests, and the allowed domains in the Pega Customer Service chat server.

Pega Customer Service Implementation Guide Pega Customer Service Implementation Guide Pega Customer Service Implementation Guide

The security configuration API includes the following methods:

Get configuration
Pulls the security configuration of your Pega Customer Service chat instance from the database.
Post configuration
Updates the security configuration of your Pega Customer Service chat in the database.

Authentication

Both Get and Post configuration uses the request header parameter for authentication. The Pega Customer Service chat company identifier is included in the company provision mail in the following format:

authorization: privateAPIKey FPK4mmKXmwtKFyzNe4aN0XU

Authentication error codes

Error codeDescription
401Authorization missing
402Authorization is invalid

Get configuration method

Use the Get configurationfunction to pull the security configuration for your organization from the chat database.

Endpoint

GET/{{chatserverURL}}/chat/api/securityConfiguration

Response parameters

ParameterRequiredDescription
Websocket RatelimitOptionalThe number of WebSocket connections that can be established for an IP address in one second.
Message RatelimitOptionalThe number of WebSocket messages that can be transferred in the socket in one second.
Allowed originsOptionalDomains from which chat servers permit chat requests, separated by commas. The parameter does not support the asterisk (*).

Example response

{
   "company":{
      "Websocket Ratelimit":2,
      "Message Ratelimit":6,
      "Allowed origins":[
         "http://expressjs.com",
         "http://www.sustainablesites.com"
      ]
   }
}

Post configuration function

Use the Post configuration function to update the security configuration for your company in the chat database.

Endpoint

POST/{{chatserverURL}}/chat/api/securityConfigurationUpdate

Headers

Content-Type: application/JSON

Request parameters

ParameterRequiredDescription
websocketRatelimitOptionalThe number of WebSocket connections that can be established for an IP address in one second. The minimum value for websocketRateLimit is one, and the maximum is five.
messageRatelimitOptionalThe number of WebSocket messages that can be transferred with in the socket in one second. The minimum value for messageRateLimit is three and the maximum is eight.
allowedOriginsOptionalDomains from which chat servers permit chat requests, separated by commas. The parameter does not support the asterisk (*).

Example request

    {
      "websocketRateLimit":5,
      "messageRatelimit":7,
      "allowedOrigins":[
         "http://expressjs.com",
         "http://www.sustainablesites.com"
      }

Successful Response

Company data has been updated.

  • Previous topic Pega Customer Service Chat in a reverse proxy server
  • Next topic Pega Customer Service Chat engine architecture

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

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.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us