Is there any regex can create index alias based on weekly/monthly/yearly?

I want to create different date index alias.
Is there any regex can create index alias based on weekly/monthly/yearly?
but the below restful API doesn't work. could anyone help on this?

POST /_aliases
{
"actions": [
{ "add": { "index": "metricbeat-linux-system-{now/w}", "alias": "system" }}
]
}

Those APIs don't do date math for you, you need to do it client side and then make the request.

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