Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possibility to access search templates via Rest-API #6493

Closed
Greevee opened this issue Jun 13, 2014 · 5 comments
Closed

Possibility to access search templates via Rest-API #6493

Greevee opened this issue Jun 13, 2014 · 5 comments

Comments

@Greevee
Copy link

Greevee commented Jun 13, 2014

There should be a possibility to access the search templates and get the parameters.Because there is no way you know which search templates are possibile, if you dont have access to the file system and parse the mustache files.

@dadoonet
Copy link
Member

I think you are looking for this: #5637, right?

@Greevee
Copy link
Author

Greevee commented Jun 13, 2014

ya right, sorry, didnt notice. Important part is to get access to the available templates, without knowing their name!

@dadoonet
Copy link
Member

So a

GET _search/template

that is?

I updated the issue. May be we can close this one?

@Greevee
Copy link
Author

Greevee commented Jun 13, 2014

sorry, ill have to ask again, maybe im just confused : )

My Problem: i have some .mustache files in the "config\scripts" directory. I know how to access them via rest, thats no a problem! but i dont know the name of the templates, thats my problem, is there a way to access the available templates? in my case there are template1.mustache and template2.mustache and i want to get the 2 avaiable templates via rest, without knowing they are names template1 and template2.

if this is possible, sure, this ticket is obsolet and can be closed! :)

@clintongormley
Copy link

Hi @Greevee

We don't support returning node-level config file info via the REST API. I suggest you use indexed search templates instead, which can then be entirely managed by the REST API.
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-template.html#pre-registered-templates

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants