Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

Connect-REST fails to test successfully



An error occurred when testing a Connect-REST rule.

Error Messages

"The response was not recognized as JSON or XML and cannot be saved."

Steps to Reproduce

  1. Create a Connect-REST rule.
  2. Define basic parameters.
  3. Select Method name as POST.
  4. Provide the request content in XML format.
  5. Click Test.

Root Cause

A defect in custom application code or rules:

The error occurs because the response is formatted as HTML. The REST connector is expects JSON or XML, and does not handle HTML.


Perform the following local-change:
Update foreign service to return JSON or XML.
Suggest Edit

Published December 8, 2016 - Updated October 8, 2020

Did you find this content helpful? Yes No

0% found this useful

Have a question? Get answers now.

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

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

Pega Community 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
Contact us