Setup Pega to check the mandatory fields in a json - REST call
What I would like to know is how to setup Pega to check the mandatory fields in a json that is sent as part of the incomming REST call and send appropriate return code. I tried to do that as part of "Validation" under "Advanced" tab for the property under the mapped json class, see below details.
I have a REST service which I am testing various input scenarios and see how Pega sends the response back. When I wans testing the "mandatory field" in the incomming json, I added some validation data for the property in the class that are mapped to the json. I did the below changes and when I call the REST endpoint without the required field as part of the json, I dont get any error instead I get a valid response back.
Under Advanced tab, I have the following Validation on the property accessionId
1. Max length = 5
2. Min length = 3
3. Column inclusion = Required
Pls let me know if this the right way of doing it or if there is a different way of doing it.
***Moderator Edit-Vidyaranjan: Updated SR details***
Keep up to date on this post and subscribe to comments
- REST JSON- Does Pega support complex request and response?
- Deletion of row in PEGA UI Data table with mandatory field checks
- 6.2SP2 Using REST with JSOn- issue
- Disable Client Side Valiation(mandatory field checking) on "Save as draft"- Is this the best practice
- Mandatory sign (asterisk symbol '*') is not displayed for read-only fields in pega 8.2 whereas it was there in 7.1