By default, salt-api uses glob method to match target minion. Is it possible to use other way(maybe grains, pcre and so on) to find minions.
I tried to pass tgt_type to salt-api, but it didn't work.
curl -s -H "Accept: application/json" -d username='user' -d password='pwd' -d eauth='pam' -d fun='test.ping' -d tgt='127.0.0.1' -d client='local' -d tgt_type='ipcidr' localhost:8000/run
expr_form
is the option you're looking for.
expr_form='ipcidr'
This is found quite often in various parts of Salt.
Here's a legend with the different types of matching in Salt: http://docs.saltstack.com/en/latest/topics/targeting/compound.html