diff --git a/endpoints/getting-started/openapi.yaml b/endpoints/getting-started/openapi.yaml index 634ef8b38d..840f2bd290 100644 --- a/endpoints/getting-started/openapi.yaml +++ b/endpoints/getting-started/openapi.yaml @@ -43,12 +43,8 @@ paths: description: "Authenication info." schema: $ref: "#/definitions/authInfoResponse" - x-security: - - google_jwt: - audiences: - # This must match the "aud" field in the JWT. You can add multiple - # audiences to accept JWTs from multiple clients. - - "echo.endpoints.sample.google.com" + security: + - google_jwt: [] "/auth/info/googleidtoken": get: description: "Returns the requests' authentication information." @@ -60,12 +56,8 @@ paths: description: "Authenication info." schema: $ref: "#/definitions/authInfoResponse" - x-security: - - google_id_token: - audiences: - # Your OAuth2 client's Client ID must be added here. You can add - # multiple client IDs to accept tokens from multiple clients. - - "YOUR-CLIENT-ID" + security: + - google_id_token: [] definitions: echoMessage: properties: @@ -97,6 +89,9 @@ securityDefinitions: x-google-issuer: "jwt-client.endpoints.sample.google.com" # Update this with your service account's email address. x-google-jwks_uri: "https://www.googleapis.com/service_accounts/v1/jwk/YOUR-SERVICE-ACCOUNT-EMAIL" + # This must match the "aud" field in the JWT. You can add multiple + # audiences to accept JWTs from multiple clients. + x-google-audiences: "echo.endpoints.sample.google.com" # This section configures authentication using Google OAuth2 ID Tokens. # ID Tokens can be obtained using OAuth2 clients, and can be used to access # your API on behalf of a particular user. @@ -104,5 +99,9 @@ securityDefinitions: authorizationUrl: "" flow: "implicit" type: "oauth2" - x-google-issuer: "accounts.google.com" - x-google-jwks_uri: "https://www.googleapis.com/oauth2/v1/certs" + x-google-issuer: "https://accounts.google.com" + x-google-jwks_uri: "https://www.googleapis.com/oauth2/v3/certs" + # Your OAuth2 client's Client ID must be added here. You can add + # multiple client IDs to accept tokens from multiple clients. + x-google-audiences: "YOUR-CLIENT-ID" +