Skip to main content

Hello,

With an ETL and REST components, I create orders in IFS. After creation I would like to change the status of the order from planned to released.

I use this :

"https://blabla/main/ifsapplications/projection/v1/CustomerOrderHandling.svc"

"CustomerOrderSet(OrderNo='blabla')/IfsApp.CustomerOrderHandling.CustomerOrder_ReleaseOrder"

I have this response :

500      |{"error":{"code":"ODP_DESERIALIZATION_ERROR","message":"Error while de-serializing contents."}}

I also try with parameters CustomerNo and Company, i have same message…

Can someone help me ?

 

Thanks,

Hi,

 

To release a customer order you must know the ETag value of the order.

 

You can get the ETag value with the Get request below.

https://url:port/main/ifsapplications/projection/v1/CustomerOrderHandling.svc/CustomerOrderSet(OrderNo='Y1025')

 

After that, send a Post request like below. It will return 204 when the ETag value is correct.

https://url:port/main/ifsapplications/projection/v1/CustomerOrderHandling.svc/CustomerOrderSet(OrderNo='Y1025')/IfsApp.CustomerOrderHandling.CustomerOrder.SetReleased

 

Note: Don’t forget to remove the “\” characters from the ETag value.

Example:  

W/\"Vy8iQUFBU2c0QUFHQUFBQ25iQUFIOjIwMjAwOTE1MTMyMTUxIg==\"

W/"Vy8iQUFBU2c0QUFHQUFBQ25iQUFIOjIwMjAwOTE1MTMyMTUxIg=="

 


This error can appear if you do not specify your headers, for reasons unknown you should add following headers


Accept: application/json;odata.metadata=full;IEEE754Compatible=true
Content-Type: application/json;IEEE754Compatible=true

Otherwise you have something wrong in you request

Could you provide the full REST request you execute?

 

Thanks for your answer.

Yes i could take the : 
<root odata.context="https://blabla/main/ifsapplications/projection/v1/CustomerOrderHandling.svc/$metadata#CustomerOrderSet/$entity" odata.etag="W/&quot;Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==&quot;">

My ETL is Talend, it’s in java, so i have the \”.

Then i add this in my header :

webClient_tRESTClient_3.header("Content-type", "*/*");

 webClient_tRESTClient_3.header("Accept", "*/*");

webClient_tRESTClient_3.header("If-Match", "W/\"Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==\"");

i tried with 

"W/&quot;Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==&quot;"

 

And same result :

500      |{"error":{"code":"ODP_DESERIALIZATION_ERROR","message":"Error while de-serializing contents."}}

 

Thanks,

 

>Edit] : I tried with this and same result

Accept: application/json;odata.metadata=full;IEEE754Compatible=true
Content-Type: application/json;IEEE754Compatible=true


This is how I configure my java component, I don't know if this will mean anything to you.

 


Your ETag value is not correct. 

 

Wrong:     W/\"Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==\"

Wrong:    W/&quot;Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==&quot;

True:       W/”Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==”


Your ETag value is not correct. Just try like below.

 

W/"Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig=="


@jourdann Your URL is not correct. Change the URL like

CustomerOrderSet(OrderNo='order_no')/IfsApp.CustomerOrderHandling.CustomerOrder.SetReleased

 

And ETag value should be 

 

W/"Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig=="

 

W/&quot;Vy8iQUFBUmgyQUI1GNEQUFCOjIwMjMwOTEzMTQwODI5Ig==&quot; is wrong


 


I think there was problem about comments. When I send a comment. It didn't shown. Now all of them shown. :)


Forum was off for some hours…

 

I have same things in postman

 


Do you use Team Viewer or Anydesk? I can check your request with one of them. 


Awesome ! Thanks to your help I solved my problem!!

You have to pay attention to the "if-match" and you need {} in the body...

Thanks again


Reply