Transform field dynamically

Hi
I want to calculate total value of some fields in my grafana dashboard, I have done it with transformation - add field from calculation but name of these fields change in time and I have to set them dynamically by regex. For example anything with format of /api/test/* calculate as one filed
Is there anyway for it?