AMLBaseX Rest client
I have spent quite a bit of time trying to figure out how to send an XQuery expression via http post request to the rest service of the BaseX database without errors. I had the problem that the XQuery expression could be processed without errors in the BaseX GUI application, but the same expression when submitted via HTTP request from the C# program was always incorrect. For the implementation I followed the RESTPost.Java example which presents the HTTP POST method as java code. In this example the content type for the post request is defined as “application/query+xml”. This corresponds to the following statement when using the .NET HttpClient in c#: