on 2020 Mar 21 8:16 PM
Hi All,
I am trying to do a bulk persistence using multipart/mix content payload using odata services in integration api.
The POST request is erroring out with 400: Bad Request. Please help me understand and resolve the issue.
POST Endpoint:
https://host:<port>/odata2webservices/InboundClassificationAttribute/$batch
Request Payload Details:
--batch
Content-Type: multipart/mixed; boundary=changeset
--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary
POST ClassificationAttributes HTTP/1.1
Accept: application/json
Content-Type: application/json
<-- NEWLINE -->
<-- NEWLINE -->
{ "@odata.context": "$metadata#ClassificationAttributes/$entity", "code": "Case_Length", "name": "Case Length", "systemVersion": { "catalog": { "id": "bekClassificationSystem" }, "version": "V1.0" } }
--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary
POST ClassificationAttributes HTTP/1.1
Accept: application/json
Content-Type: application/json
<-- NEWLINE -->
<-- NEWLINE -->
{ "@odata.context": "$metadata#ClassificationAttributes/$entity", "code": "Case_Width", "name": "Case Width", "systemVersion": { "catalog": { "id": "bekClassificationSystem" }, "version": "V1.0" } }
--changeset--
--batch
Content-Type: multipart/mixed; boundary=changeset
--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary
POST ClassificationAttributes HTTP/1.1
Accept: application/json
Content-Type: application/json
<-- NEWLINE -->
<-- NEWLINE -->
{ "@odata.context": "$metadata#ClassificationAttributes/$entity", "code": "Case_Height", "name": "Case Height", "systemVersion": { "catalog": { "id": "bekClassificationSystem" }, "version": "V1.0" } }
--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary
POST ClassificationAttributes HTTP/1.1
Accept: application/json
Content-Type: application/json
<-- NEWLINE -->
<-- NEWLINE -->
{ "@odata.context": "$metadata#ClassificationAttributes/$entity", "code": "Case_Height", "name": "Case Height", "systemVersion": { "catalog": { "id": "bekClassificationSystem" }, "version": "V1.0" } }
--changeset--
--batch--
Response Error:
<?xml version='1.0' encoding='UTF-8'?>
<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">
<code/>
<message xml:lang="en">Bad Request.</message>
</error>
Request clarification before answering.
| User | Count |
|---|---|
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.