All of Discover, Visualize and Dashboard use the same query mechanism underneath which makes them hard to distinguish. I would not consider what you ask to be an easy task, but you might be able to loop such a parameter through from the SearchSource through the Request to callClient.
I just tried to point out where the SearchSource is created so you can find a suitable place to make your changes. The SavedObject class is used to load the visualization or dashboard definition.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.