@PLK1984-003 I don’t believe you can do this with standard Netlify redirects.
You may be able to do so by implementing your own custom edge function.
See the edge function documentation here:
https://docs.netlify.com/edge-functions/overview/
Here’s a recent example from a community member where they wanted to return a 404
for requests to any route containing .php
.
You may be able to quickly adapt it to match your requirements.