Is it possible to specify the search term in the request to Kibana for a saved search?

Hello,

I would like to be able to give users a URL to Kibana that links to a saved search and passes the value for a parameterised object in the query. For example, the following URL:

http://kibana/#/discover/MySearch?provisionid=1234

In this case the 'MySearch' search would be used and the token 'provisionid' in the ES query would be replaced with the value specified, e.g. 1234.

Is this possible? I know it was in Kibana 3.

Thanks, Russell

Templates and scripts work differently in Kibana 4, compared to Kibana 3, and as a result are easier to create and manipulate with external tools.

The URL itself can contain the entire dashboard and visualization schema:

http://localhost:5601/#/visualize/create?type=histogram&indexPattern=logstash-*&_g=(time:(from:now-2d,mode:relative,to:now))&_a=(vis:(aggs:!((params:(),schema:metric,type:count),(params:(extended_bounds:(),field:'@timestamp',interval:auto,min_doc_count:1),schema:segment,type:date_histogram)),type:histogram))

https://localhost:5601/#/dashboard/Logstash-Dashboard?_g=(refreshInterval:(display:Off,pause:!f,section:0,value:0),time:(from:'2014-09-12T19:46:10.400Z',mode:absolute,to:'2014-10-21T22:07:13.825Z'))&_a=(filters:!(),panels:!((col:2,id:'Logstash:-Docs-over-Time',row:9,size_x:6,size_y:4,type:visualization),(col:9,id:Logstash-User-Agents,row:1,size_x:3,size_y:5,type:visualization),(col:1,id:Logstash-Map,row:1,size_x:8,size_y:8,type:visualization)),query:(query_string:(analyze_wildcard:!t,query:'*')),title:'Logstash%20Dashboard')

See similar discussions on Github: https://github.com/elastic/kibana/issues/1482