0

I have a problem when sending a POST request to my couchdb database using curl.

curl -X POST http://admin:password@localhost:3005/fisconet/_find -d '{"selector":{"fields":{"keywords":{"$regex":".*évasion fiscale.*"}}}}' -H "Content-Type: application/json"

This is the error I get:

{"error":"bad_request","reason":"invalid UTF-8 JSON"}

If I remove the accent of the regular expression {"$regex":".*evasion fiscale.*"}, I don't get the error but I don't find what I'm looking for.

Couldn't find anything on the internet that worked.

Thanks

2
  • *.évasion I don't believe that is a valid regular expression Commented May 8, 2021 at 17:02
  • Also, what is the encoding used with your shell, e.g. for *nix check this. If on windows, you must use a text file as cmd.exe doesn't fly with utf-8; not sure about PowerShell. Commented May 8, 2021 at 17:40

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.