Support Forums

How to use :splat in _redirects?

I’m trying to a site that uses only the redirects feature of Netlify. You can call it a link shortener. I am having the following URL: https://api.whatsapp.com/send/?phone=85263615814&text=I+am+Gavin&app_absent=0
I’m trying to create the redirect such that example.com/Gavin will redirect to the above link.
However, example.com/Pereira should redirect to https://api.whatsapp.com/send/?phone=85263615814&text=I+am+Pereira&app_absent=0
Basically, I want it to inject the slug into the WhatsApp API link.
Is this possible with _redirects alone or do I have to use Serverless functions?

Got it working by using the following rule in _redirects

/* https://api.whatsapp.com/send/?phone=85263615814&text=I+am+:splat&app_absent=0