<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Code based Odata CLient Proxy Response handler returns Exception when the response contains null in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14464396#M4947576</link>
    <description>Hi JyothirAditya, Since the proxy model is already marked as nullable and the same mapping works when those fields contain actual values, I would look more closely at how the generated client proxy handles `null` for those properties. The error `/IWBEP/CM_CP-168` suggests the issue is happening during deserialization of the complex type rather than simply a JSON structure mismatch. It might be worth checking the generated proxy definition and the exact ABAP types used for `id` and `externalId`, especially how their nullable properties are represented. If you can share the generated response structure/model definition for these fields, it would be easier to narrow down where the `null` handling is failing.</description>
    <pubDate>Sat, 15 Aug 2026 16:26:58 GMT</pubDate>
    <dc:creator>aravindhan2529</dc:creator>
    <dc:date>2026-08-15T16:26:58Z</dc:date>
    <item>
      <title>Code based Odata CLient Proxy Response handler returns Exception when the response contains null</title>
      <link>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaq-p/14461773</link>
      <description>&lt;P&gt;hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;we are using code based odata client proxy -( rest service ) to send or receive data . i have defined the model class and set the response body structure for the HTTP operation. In the response handler class -&amp;nbsp;/IWBEP/IF_CP_RESPONSE_HANDLER~HANDLE_REST_RESPONSE, it is unable to parse the response to the desired format and getting error&amp;nbsp;/IWBEP/CM_CP-168:&amp;nbsp;Instance of a complex type could not be deserialized. I have defined the response structure fields to be of type string and as nullable.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Response payload structure:&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="json"&gt;[
  {
    "status": 500,
     "id" : null,
    "externalId": null,
"message": "Some string"
  }
]&lt;/LI-CODE&gt;&lt;P&gt;Some of the fields in the response structure are optional and they are ignored or sent as null by other REST API. Can you please guide what is wrong/missing and how to resolve the error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Aug 2026 05:02:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaq-p/14461773</guid>
      <dc:creator>JyothirAditya_Kundhurthi</dc:creator>
      <dc:date>2026-08-12T05:02:00Z</dc:date>
    </item>
    <item>
      <title>Re: Code based Odata CLient Proxy Response handler return...</title>
      <link>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14462136#M4947451</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.sap.com/t5/user/viewprofilepage/user-id/1528753"&gt;@JyothirAditya_Kundhurthi&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The JSON response does not match the proxy model&lt;/P&gt;&lt;P&gt;For nullable fields, ensure the proxy property is marked nullable. If null handling still fails, ask the REST API to omit null fields or send empty strings.&lt;/P&gt;&lt;P&gt;Then regenerate the OData client proxy/model and retest.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Sravan&lt;/P&gt;</description>
      <pubDate>Wed, 12 Aug 2026 12:11:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14462136#M4947451</guid>
      <dc:creator>sravan_aleshwaram</dc:creator>
      <dc:date>2026-08-12T12:11:57Z</dc:date>
    </item>
    <item>
      <title>Re: Code based Odata CLient Proxy Response handler return...</title>
      <link>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14462153#M4947453</link>
      <description>its not possible to omit or send empty strings from other system. i have defined the property as nullable, The json response matched the proxy model.This issue arises only when the response is different, for other case able to map the data.</description>
      <pubDate>Wed, 12 Aug 2026 12:27:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14462153#M4947453</guid>
      <dc:creator>JyothirAditya_Kundhurthi</dc:creator>
      <dc:date>2026-08-12T12:27:30Z</dc:date>
    </item>
    <item>
      <title>Re: Code based Odata CLient Proxy Response handler returns Exception when the response contains null</title>
      <link>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14464396#M4947576</link>
      <description>Hi JyothirAditya, Since the proxy model is already marked as nullable and the same mapping works when those fields contain actual values, I would look more closely at how the generated client proxy handles `null` for those properties. The error `/IWBEP/CM_CP-168` suggests the issue is happening during deserialization of the complex type rather than simply a JSON structure mismatch. It might be worth checking the generated proxy definition and the exact ABAP types used for `id` and `externalId`, especially how their nullable properties are represented. If you can share the generated response structure/model definition for these fields, it would be easier to narrow down where the `null` handling is failing.</description>
      <pubDate>Sat, 15 Aug 2026 16:26:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/code-based-odata-client-proxy-response-handler-returns-exception-when-the/qaa-p/14464396#M4947576</guid>
      <dc:creator>aravindhan2529</dc:creator>
      <dc:date>2026-08-15T16:26:58Z</dc:date>
    </item>
  </channel>
</rss>

