06-01-2022 08:56 AM
Hi Everybody,
I try to play with the REST API, now I'm able to do a lot of thing but there is still something that fail.
I cannot find anything with the /queries/nodes interface.
To be true, actually, I can have a lot of result for this request while this word is never used ... (banana)
http://server:8081/alfresco/api/-default-/public/alfresco/versions/1/queries/nodes?term='name:banana':&maxItems=500000&rootNodeId=-root-
If a replace by an existing name, I have no result .. Personnaly, I can understand it better ..
http://server:8081/alfresco/api/-default-/public/alfresco/versions/1/queries/nodes?term='name:memorandum':&maxItems=500000&rootNodeId=-root-
What am I doing wrong ? Could you understand why it find such weird result ?
The real request I would like to achieve is to have all nodes which have a properties named "ifm:ref" whith a value beginning by I .. I tries with term:ifm:ref:I* (as is is suggested here https://docs.alfresco.com/search-enterprise/latest/using/) . but .. nothing
Could someone help me create the correct "term" ?
Thank you !
06-02-2022 04:12 AM
You may try with the "search" API.
$ curl -X POST \ "http://localhost:8080/alfresco/api/-default-/public/search/versions/1/search" \ -H "accept: application/json" -H "authorization: Basic YWRtaW46YWRtaW4=" \ -H "Content-Type: application/json" \ -d "{ \"query\": { \"query\": \"cm:name:z*\" }}"
06-02-2022 04:12 AM
You may try with the "search" API.
$ curl -X POST \ "http://localhost:8080/alfresco/api/-default-/public/search/versions/1/search" \ -H "accept: application/json" -H "authorization: Basic YWRtaW46YWRtaW4=" \ -H "Content-Type: application/json" \ -d "{ \"query\": { \"query\": \"cm:name:z*\" }}"
06-02-2022 05:12 AM
thanks a lot
It works great !
Explore our Alfresco products with the links below. Use labels to filter content by product module.