You can add routes only for user-defined services. |
On the top navigation bar, click System.
From the left navigation pane, select System Settings > Gateway Settings > Service.
Click the name of a service.
Click the Routes tab, and then click Create.
Configure the route parameters.
Table-1 Configuring route parameters
Parameter |
Description |
Method |
Select one or multiple API methods. To select all available methods, leave this parameter empty. |
Protocols |
Select HTTP or HTTPS as the protocol used for connecting to the API gateway. You can select both HTTP and HTTPS. |
Path |
Enter a path for the specified methods. The path is used with the HTTP proxy address of the API gateway. For example, a route of a service uses the GET method, HTTP, and path /cloudquery. If the API gateway provides HTTP proxying for this service at 172.22.25.140:703, the API for the GET method is http://172.22.25.140:703/cloudquery/v3. v3 is the service interface. |
Remove Matching Path |
Select whether to remove the matching prefix from upstream requested URL paths that match this route. For example, if you set the path to /v1/v2 and the interface prefix for other services to access this service is /v2/v3, v2 is removed during matching. |