I'm trying to get the number of buckets in my aggregation.
I tried {{ ctx.payload.aggregations.myAgg.buckets.size() }}, but nothing was displayed. I've seen other posts using that method in conditions, but I need it in actions.
I would also like to get the sum of each bucket's doc_count (different than {{ ctx.payload.hits.total }} when using min_doc_count).