SAP Knowledge Base Article - Public

3734305 - POST to Fixed Asset Retirement API returns HTTP 201 instead of 200 after CE2508 upgrade

Symptom

After upgrade to version SAP S/4HANA Cloud Public Edition 2508 (CE2508), a successful POST to the Fixed Asset - Post Asset Retirement OData V4 action returns HTTP status code 201 instead of previously 200.

Environment

SAP S/4HANA Cloud Public Edition 2508

Reproducing the Issue

  1. Send a POST request to the Fixed Asset Retirement OData V4 action (SAP__self.Post) to post an asset retirement.
  2. Observe that the successful response returns HTTP 201 instead of the previously observed HTTP 200.

Cause

A platform-level behavior change in the ABAP RESTful Application Programming Model (RAP) introduced in CE2508 returns HTTP 201 (Created) for certain action executions to enable performing further actions on the result within a single OData $batch request. This is intentional and not a defect.

Resolution

  • The HTTP status code 201 indicates success as well. It is raised now in some cases instead of previously 200. 
  • That was introduced in order to enable performing further actions on the result of an action within one OData $batch request. 

See Also

SAP Help Portal What's New Viewer - SAP S/4HANA Cloud Public Edition

Keywords

http 201, http 200, status code change, ce2508, fixed asset retirement api, odata v4, rap, abap platform, post action, sap__self.post, response handling, asset accounting, $batch, created response, s/4hana cloud public edition , KBA , BC-ESI-ESF-BSA , Business Service Adaptation , Product Enhancement

Product

SAP S/4HANA Cloud Public Edition 2508