Skip to content

Commit a75cb36

Browse files
Simon Zeltserandrewsg
Simon Zeltser
authored andcommitted
Removing basePath = "\" from openApi spec file (GoogleCloudPlatform#1382)
From the OpenAPI 2 spec: * basePath: "If it is not included, the API is served directly under the host. The value MUST start with a leading slash (/). " * Paths for methods: "A relative path to an individual endpoint. The field name MUST begin with a slash. The path is appended to the basePath in order to construct the full URL." This OpenAPI getting-started sample have basePath="/", which (per strict spec interpretation) means all the paths start with double-slashes. (e.g "//v1/shelves" rather than "/v1/shelves"). Removing basepath="/" fixes that.
1 parent e64b04f commit a75cb36

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

endpoints/getting-started/openapi.yaml

-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ info:
66
version: "1.0.0"
77
host: "echo-api.endpoints.YOUR-PROJECT-ID.cloud.goog"
88
# [END swagger]
9-
basePath: "/"
109
consumes:
1110
- "application/json"
1211
produces:

0 commit comments

Comments
 (0)