nginx convert untyped file to html

In my nginx conf file, I’m trying to translate something like /api/1/frontend/taskpane/ -> /api/1/frontend/taskpane.html /api/1/frontend/taskpane/?param=x -> /api/1/frontend/taskpane.html?param=x I’ve gotten the first case to work with a rewrite rule as follows: rewrite ^/api/1/frontend/taskpane/$ /api/1/frontend/taskpane.html last; …but it fails when the GET parameters are passed Furthermore, I have other filetypes that I want to remain untouched. For…