Check the required fields and show message with Postman

Hi Team, I need to check if the gender and full name fields are mandatory, and if they are left blank I want to display a message like: “Mandatory fields thank you

“naturalPerson”: {
“fullName”: “Teste com o Luis”,
“nickName”: “Pacheco”,
“gender”: 2,
“pronoun”: 2,
“maritalStatus”: {
“maritalStatusSituation”: 2,
“partnerDocumentType”: 1,
“partnerDocumentNumber”: “83132967556”

What have you tried so far? What’s not working for you?

There are several resources available to help with writing tests, for example:

Excuse me I’m asking for help on a specific point? If you have the solution and want to send it thank you, I’m new to this!!

Which is why Danny advised you to try some of the training materials first, so you can learn how to do this yourself.

Creating tests\assertions on responses is basic functionality.

Just telling you the answer without you understanding the core basics, doesn’t help you in the long run.

If you are having issues with a particular response or assertion after you’ve gone through the Learning Centre, then post what you’ve tried and we can then help.

This is the same as most forums out there. There is an expectation that you have tried to find the answer in the first instance.

1 Like

let it be!!! thank you very much…

Ron Burgundy Escalated Quickly GIF - Ron Burgundy Escalated Quickly GIFs

1 Like

For what it’s worth it sounds to me like you’re trying to do client-side validation, for which Postman won’t really be helpful.
Have you checked this? Form data validation - Aprendendo desenvolvimento web | MDN

1 Like