32
32
required : true
33
33
schema :
34
34
$ref : " #/definitions/echoMessage"
35
+ security :
36
+ - api_key : []
35
37
" /auth/info/googlejwt " :
36
38
get :
37
39
description : " Returns the requests' authentication information."
@@ -43,12 +45,9 @@ paths:
43
45
description : " Authenication info."
44
46
schema :
45
47
$ref : " #/definitions/authInfoResponse"
46
- x-security :
47
- - google_jwt :
48
- audiences :
49
- # This must match the "aud" field in the JWT. You can add multiple
50
- # audiences to accept JWTs from multiple clients.
51
- - " echo.endpoints.sample.google.com"
48
+ security :
49
+ - api_key : []
50
+ - google_jwt : []
52
51
" /auth/info/googleidtoken " :
53
52
get :
54
53
description : " Returns the requests' authentication information."
@@ -60,12 +59,9 @@ paths:
60
59
description : " Authenication info."
61
60
schema :
62
61
$ref : " #/definitions/authInfoResponse"
63
- x-security :
64
- - google_id_token :
65
- audiences :
66
- # Your OAuth2 client's Client ID must be added here. You can add
67
- # multiple client IDs to accept tokens from multiple clients.
68
- - " YOUR-CLIENT-ID"
62
+ security :
63
+ - api_key : []
64
+ - google_id_token : []
69
65
definitions :
70
66
echoMessage :
71
67
properties :
@@ -77,9 +73,6 @@ definitions:
77
73
type : " string"
78
74
email :
79
75
type : " string"
80
- # This section requires all requests to any path to require an API key.
81
- security :
82
- - api_key : []
83
76
securityDefinitions :
84
77
# This section configures basic authentication with an API key.
85
78
api_key :
@@ -97,12 +90,18 @@ securityDefinitions:
97
90
x-google-issuer : " jwt-client.endpoints.sample.google.com"
98
91
# Update this with your service account's email address.
99
92
x-google-jwks_uri : " https://www.googleapis.com/service_accounts/v1/jwk/YOUR-SERVICE-ACCOUNT-EMAIL"
93
+ # This must match the "aud" field in the JWT. You can add multiple
94
+ # audiences to accept JWTs from multiple clients.
95
+ x-google-audiences : " echo.endpoints.sample.google.com"
100
96
# This section configures authentication using Google OAuth2 ID Tokens.
101
97
# ID Tokens can be obtained using OAuth2 clients, and can be used to access
102
98
# your API on behalf of a particular user.
103
99
google_id_token :
104
100
authorizationUrl : " "
105
101
flow : " implicit"
106
102
type : " oauth2"
107
- x-google-issuer : " accounts.google.com"
108
- x-google-jwks_uri : " https://www.googleapis.com/oauth2/v1/certs"
103
+ x-google-issuer : " https://accounts.google.com"
104
+ x-google-jwks_uri : " https://www.googleapis.com/oauth2/v3/certs"
105
+ # Your OAuth2 client's Client ID must be added here. You can add
106
+ # multiple client IDs to accept tokens from multiple clients.
107
+ x-google-audiences : " YOUR-CLIENT-ID"
0 commit comments