cancel
Showing results for 
Search instead for 
Did you mean: 

Data Validation in RAP web service with messages in response

BhargavJack
Discoverer
0 Kudos
192

Hi All,

I Have one scenario whare i have to validate some data using rap in odata web service. 

The data are coming in specific payload. I have to validate this data and if any error message is coming i have to send as response. This one is web Odata so i can not send messages as an error message. The all functionality i have to do in GET method only.

Any way to do this one?

sample payload

{
  "company_code" "3N6R",
  "profit_center" "",
  "trading_partner" "",
  "gl_account" "",
  "cost_center" "",
  "internal_order" "",
  "wbs_elements" "",
  "Customer" "",
  "Vendor" "",
  "posting_date" "\/Date(1721088000000)\/"
}

junwu
Active Contributor
0 Kudos
don't know what you are talking....

Accepted Solutions (0)

Answers (2)

Answers (2)

MioYasutake
Active Contributor
0 Kudos

@BhargavJack 

How about not setting the 'failed' object and setting a severity other than 'error' for the 'reported' object?

BhargavJack
Discoverer
0 Kudos

 

I am Getting error message like this one when service is triggered. Here Return code is 400. due to this system consider message as an error message.

BhargavJack_0-1721839187607.png

But I want Message like this one. here Return code is 200. so on BTP i can read this message properly without any error.

BhargavJack_1-1721839310306.png