Invalid query always returned by sharing API

I've installed an instance of owncloud 9.0, I was testing the sharing API

If I browse https://localhost/owncloud/ocs/v1.php/config

I get the correct response

<?xml version="1.0"?>
<ocs><meta><status>ok</status><statuscode>100</statuscode>
<message/></meta><data><version>1.7</version><website>ownCloud</website>
<host>localhost</host><contact/><ssl>false</ssl></data>
</ocs>

Any other request (e.g. /ocs/v1.php/apps/files_sharing/api/v1/shares) return the following failure response

>   <?xml version="1.0"?>
>   <ocs><meta><status>failure</status><statuscode>999</statuscode>
>   <message>Invalid query, please check the syntax. API specifications are here: 
> http://www.freedesktop.org/wiki/Specifications/open-collaboration-services. DEBUG OUTPUT:
>  </message></meta><data/>
> </ocs>

I wonder if there is a bug or something wrong in the configuration

Might be that you
* do not have sharing enabled
* miss a parameter, in this case the path for which you want to query for shares.

The sharing looks enabled (see attached picture) and I get that error response even if I query https://localhost/owncloud/ocs/v1.php/apps/%EF%AC%81les_sharing/api/v1/shares that should return all the shares for the user

it was my fault, some strange values have sneaked into the URL due to the copy & paste

URLs like
'https://localhost/owncloud/ocs/v1.php/apps/files_sharing/api/v1/shares' (it appears that
'https://localhost/owncloud/ocs/v2.php/apps/files_sharing/api/v1/shares' works the same way)

work as expected