Hey,

I’m sending a POST request to the /documents with the inputs below and getting 
an error message that I’m not entirely sure how to solve (I Googled and looked 
in the docs and there was no information). The response in full is:


<error-response xmlns="http://marklogic.com/xdmp/error";>

  <status-code>400</status-code>

  <status>Bad Request</status>

  <message-code>XDMP-HTTP-MULTIPART</message-code>

  <message>XDMP-HTTP-MULTIPART: xdmp:get-request-part-headers() -- Only valid 
for a HTTP request with the multipart/mixed or multipart/related content 
type</message>

</error-response>

Which to me sounds like the Content-Type isn’t multipart/mixed, but it can 
clearly be seen below that it is… Anyone have any ideas?

Thanks,

Ashley

Headers:


POST /LATEST/documents HTTP/1.1

Authorization: Digest username="username", realm="public", 
nonce="76d9131f5e0b6938c30a009046ed6e1f", uri="/LATEST/documents", 
cnonce="MTU3OTcw", nc=00000001, qop="auth", 
response="b285a17cafd471172e21a04964e063f2", opaque="56275b576982d2b1"

Host: localhost:8003

Content-Type:multipart/mixed

boundary: ML_BOUNDARY_887901ea1c4e8d2fa219b5d0a7bb9199d3a9df62

Accept:application/xml

Content-Length: 112723

Expect: 100-continue

Then the request body is:


--ML_BOUNDARY_887901ea1c4e8d2fa219b5d0a7bb9199d3a9df62
Content-Disposition: attachment; filename="/2015/11/18/20848763"; 
category=content; format=xml
Content-Type: application/xml
Content-Length: 11115

<?xml version="1.0" encoding="UTF-8"?>
[MY XML]


--ML_BOUNDARY_887901ea1c4e8d2fa219b5d0a7bb9199d3a9df62
Content-Disposition: attachment; filename="/2015/11/18/20848766"; 
category=content; format=xml
Content-Type: application/xml
Content-Length: 11152

<?xml version="1.0" encoding="UTF-8"?>
[MY XML]




[cid:[email protected]]


[cid:[email protected]]


Ashley Peacock


Developer II
Elevate Credit International Limited
P: 01284 717800 | Ext: 877 |  Elevate.co.uk<http://elevate.co.uk>
Amadeus House, Floral Street, Covent Garden, London WC2E 9DP




Privileged and Confidential. This e-mail, and any attachments thereto, is 
intended only for use by the addressee(s) named herein and may contain 
privileged and/or confidential information. If you have received this e-mail in 
error, please notify me immediately by a return e-mail and delete this e-mail. 
You are hereby notified that any dissemination, distribution or copying of this 
e-mail and/or any attachments thereto, is strictly prohibited.

Elevate Credit International Limited is registered in England & Wales with 
Company Number 05041905. Registered Office: 27-28 Eastcastle Street, London, 
W1W 8DH


_______________________________________________
General mailing list
[email protected]
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to