You indeed need to pass the Content-Type.
- benoit
> The other thing, is there a way to 'force' a
>
> application/json Content-Type
>
> In the cURL command?
You can use the -H option to pass extra headers. This can be found in the output of 'curl --help' and also in the curl man page.
> While I realise I don't need to do this to 'get into' couchDB -- I
> would like a simple way to learn, try prototypes, and simple tests
> using something LIKE cURL, so any helpful answers or things to try are
> most welcome.
For OS X I sometimes use HTTP Client to interact with HTTP servers: http://ditchnet.org/httpclient/
Google for REST client or HTTP client and you might find some interesting tools.
If you're into a particular scripting or programming language you could also dig into a good library for that platform. IMO couchdbkit is a great toolkit for Python for instance.
Nils.
De informatie vervat in deze e-mail en meegezonden bijlagen is uitsluitend bedoeld voor gebruik door de geadresseerde en kan vertrouwelijke informatie bevatten. Openbaarmaking, vermenigvuldiging, verspreiding en/of verstrekking van deze informatie aan derden is voorbehouden aan geadresseerde. De VPRO staat niet in voor de juiste en volledige overbrenging van de inhoud van een verzonden e-mail, noch voor tijdige ontvangst daarvan.
Hello all,
This is really basic I think, though for myself I want to work through
the fundamentals so I get a good feel for how CouchDB works -- At
least to the crawling/toddler stage.
I want to use the simple PUT example from the "CouchDB Book", "Core
API" section, viz.
http://books.couchdb.org/relax/intro/core-api
curl -X PUT http://127.0.0.1:5984/albums/6e1295ed6c29495e54cc05947f18c8af
-d '{"title":"There is Nothing Left to Lose","artist":"Foo
Fighters"}'