incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jens Alfke <j...@couchbase.com>
Subject Re: How to post multipart data to CouchDB?
Date Tue, 18 Oct 2011 23:36:34 GMT

On Oct 18, 2011, at 11:45 AM, Pulkit Singhal wrote:

2) If yes, then how is someone supposed to post a multipart document
to be indexed? Can someone please point me to an example of this being
done using curl?

I’m not sure what you mean by “a multipart document”. Do you mean one with attachments?
If so, you can add the attachment bodies in the JSON you post. See the “Inline Attachments”
section on that same page. There’s also a way to send a multipart/related HTTP body, but
I can’t see any documentation of it on the wiki.

(As far as I know, the multipart/form-data support is just there as a minor convenience for
code that doesn’t want to pack the document up into JSON on its own. This seems like a small
detail that shouldn’t prevent you from using any features.)

—Jens

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message