Open
Description
In CouchDB The Definitive Guide,
In the Core API section, under Documents, when you run the command:
curl -X PUT http://127.0.0.1:5984/albums/6e1295ed6c29495e54cc05947f18c8af -d '{"title":"There is Nothing Left to Lose","artist":"Foo Fighters"}'
I always got: {"error":"bad_request","reason":"invalid_json"}
It took a LONG time to debug. Under Windows 7 command shell, the Quotes in JSON need to be escaped differently using curl. Here's what worked for me:
c:>curl -X PUT http://127.0.0.1:5984/albums/6e1295ed6c29495e54cc05947f18c8af -d "{"""title""":"""There is Nothing Left to Lose""","""artist""":"""Foo Fighters"""}"
Metadata
Metadata
Assignees
Labels
No labels