Hi,

We have refactored ES tags api as follows to be consistent with the rest of
the ES apis.

*option 1* : returns names of all the tags and their count for the given
asset type
*api request template*
<context>/apis/tags?type=<asset_type>

ex: https://localhost:9443/publisher/apis/tags?type=gadget

*sample response*
[{"name" : "charts", "count" : 13.0}, {"name" : "hbar", "count" : 1.0},
{"name" : "visualization", "count" : 13.0}, {"name" : "mix", "count" : 1.0}]


*option 2* : return tags which has the given tag name and belongs to the
given asset type
*api request template*
<context>/apis/tags?type=<asset_type>&q="name":"<tag_name>"

ex: https://localhost:9443/publisher/apis/tags?type=gadget&q="name":"wso2";

*sample response*
[{"name" : "wso2", "count" : 5}]

*options 3 *: returns all the tags
*api request template*
<context>/apis/tags

Option 3 is not yet implemented and will be a future enhancement.

We have exposed the api in both the publisher and store.
Currently changes are pushed to store_771 branch in carbon-store repo and
will be merging to the master once the 2.2.0 release is done. So the
aforementioned changes will be available in the 2.3.0 release of the
carbon-store.

Thanks,
Tanya


-- 
Tanya Madurapperuma

Senior Software Engineer,
WSO2 Inc. : wso2.com
Mobile : +94718184439
Blog : http://tanyamadurapperuma.blogspot.com
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to