Pega Knowlegde Buddy - Integration with Pega Constellation Apps

  • An internal error occurred while fetching the results using data view. Please contact administrator.
  • Access token endpoint invocation failed : {ErrorMessage=Response status : 401 Unauthorized, statuscode=401}

Getting the above error in Constellation application when accessing Pega Knowledge Buddy (KB).
Double checked KB configuration and is as per requirement.
Pega Cloud lab instance recently provisioned so assuming its Pega Cloud 3.
When I test the KB in Pega Knowledge Buddy application it runs fine.

@aniki @MattBroch

Hi @Atanu Sen, the 401 Unauthorized means that there is something wrong with credentials.

Anytime when I see a 401 on API call I would recommend to try the following:

  1. Double check the credentials you are using - sometimes with APIs you might accidentally use credentials from another environment.
  2. Test if API is working with these credentials if you call it manually from Postman.
  3. Try to reset credentials and use the new ones.
  4. Trace the invocation step by step to eyeball if there is something wrong.

@aniki- off course. I am interested to know if there is a license issue, similar to this support ticket.

@aniki - I rechecked all the configuration and looks like its a product issue. Meanwhile I switched to basic auth to get it working.

@Atanu Senif basic auth is working that points to the OAuth config not being correct as that is what KB is configured to ship with as the default. There are two main auth profiles used by KB, KnowledgeBuddy_OAuth_DataUser (Pegasystems Documentation) for ingestion and deletion, as well as KnowledgeBuddy_OAuth_EndUser (Pegasystems Documentation) for asking of questions. Please double check their configuration is correct and be sure to revert the KnowledgeBuddy service package back to use OAuth.