How to add a version number to the URL of the API interface?

problem description

Nginx configuration failed


Nginx
PHP7
Thinkphp5

I hope the final request is as follows:

  1. api.JhouShuai.com/3.0.0/ucenter/profile-> api.JhouShuai.com/V300/ucenter/profile

2.api.JhouShuai.com/3.0.1/ucenter/profile-> api.JhouShuai.com/V301/ucenter/profile

Jun.16,2022

Menu