Elastic search Kotlin Function score query

Hey I'm using kotlin and I want to write a code that run this query:

{
  "query": {
    "function_score": {
      "query": {
        "match_all": {}
      },
      "functions": [
        {
          "random_score": {
            "seed": 314159265359
          }
        },
        {
          "gauss": {
            "created_at_dt": {
              "origin": "2013-09-17",#default is current time
              "scale": "1d", 
              "decay": 0.5
            }
          }
        }
      ],
      "score_mode": "multiply"
    }
  }
}

I couldn't find any good examples on how to build this kind of query.
Thank you!

Hi @Meir_Levi

You can use the version by community contribuitor.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.