Skip to content

Commit

Permalink
[cpp C++] fix use of isBasic condition (#15535)
Browse files Browse the repository at this point in the history
  • Loading branch information
tiffmaelite committed May 20, 2023
1 parent 89e4b24 commit e7039f4
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ void Example::exampleFunction1(){
apiInstance.setUsername("YOUR USERNAME");
apiInstance.setPassword("YOUR PASSWORD");{{/isBasicBasic}}{{#isBasicBearer}}
// Configure HTTP bearer authorization: {{{name}}}
apiInstance.setBearerToken("BEARER TOKEN");{{/isBasicBearer}}{{/isBasic}}{{#isApiKey}}
apiInstance.setBearerToken("BEARER TOKEN");{{/isBasicBearer}}{{#isHttpSignature}}
//No Http Signature Authentication supported right now{{/isHttpSignature}}{{/isBasic}}{{#isApiKey}}
// Configure API key authorization: {{{name}}}
apiInstance.setApiKey("YOUR API KEY NAME","YOUR API KEY");{{/isApiKey}}{{#isOAuth}}
//OAuth Authentication supported right now{{/isOAuth}}{{#isHttpSignature}}
//No Http Signature Authentication supported right now{{/isHttpSignature}}
//OAuth Authentication supported right now{{/isOAuth}}
{{/authMethods}}
{{/hasAuthMethods}}
{{#allParams}}
Expand Down Expand Up @@ -165,8 +165,13 @@ servers:
- **Type**: HTTP basic authentication
{{/isBasicBasic}}
{{#isBasicBearer}}
- **Type**: HTTP Bearer Token authentication

- **Type**: HTTP Bearer Token authentication{{#bearerFormat}} ({{{.}}}){{/bearerFormat}}
{{/isBasicBearer}}
{{#isHttpSignature}}

- **Type**: HTTP signature authentication
{{/isHttpSignature}}
{{#isOAuth}}

- **Type**: OAuth
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -256,9 +256,9 @@ pplx::task<{{{returnType}}}{{^returnType}}void{{/returnType}}> {{classname}}::{{
}
{{/isKeyInQuery}}
{{/isApiKey}}
{{#isBasic}}
{{#isBasicBasic}}
// Basic authentication is added automatically as part of the http_client_config
{{/isBasic}}
{{/isBasicBasic}}
{{#isOAuth}}
// oauth2 authentication is added automatically as part of the http_client_config
{{/isOAuth}}
Expand Down

0 comments on commit e7039f4

Please sign in to comment.