-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Christian GrĂ¼n wrote:
It works on my machine. Did you specify an Accept header in your request? I would expect it to be mandatory in eXist db as well..
curl -H"Accept:application/json" "http://localhost:8984/all-documents.json"
Gotcha, existdb does not seem to care about the Accept header since it responds through such a request through the browser.
As an alternative, you can also remove the %rest:produces("application/json") annotation.
curl -H"Accept:application/json" "http://localhost:8984/all-documents.json" This now returns the XML version of func() - however now JSON serialized response although %output:method("json") is specified!? Andreas -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQGUBAEBAgAGBQJU5Io0AAoJEADcfz7u4AZj5FkLwMvw1psFIBb/JQV4q09Szasz GGa4C8TBqAc4aeYje9Bqv55rgmJL7zjDaqjKUgrgnT3mvoVwKwz6URm6pgrg2S82 fF3fw2taGnwnA2Np7eEJgaW5Lu7hByBGa+l4yGEW39s1SVgvkVnmSXrw+Cn84fpi F3XwtRdoD9nH3T9aTY3vTUs2ZqHD7oTrg8kgi57IDAxuG10WQpsZ6jsxwFgsS0Db sjgnFfg1/eLQyP9aIi12519bhoKzLnyl7GqyYoi0dgSy7ncu/2SyUQ1u8pVdEt7t gFOxC9cS/tuqYH4oQwcqXqoCNU961f/I/jdaMSeuaNzZaSn6bHLzuhkReddAJtwE RQ67XkTqXIayTFtjZP6u73Hrw/HI0NBThuug0ZwwEAiXEw9PsFDq8RWX8tFJR85m QDyAvOGXgzI/Z/9u4Zjfn2otetiCG1qSybaPD0p9P9ZA9jamSdXSeGw7GhZPLUjb MK8jRejjEQxeKr1miwCLYQGRjSxXaJQ= =iDiq -----END PGP SIGNATURE-----