mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-06-24 01:30:51 +00:00
Preserve order of securitySchemes (#14536)
* Remove alphabetical sort * Update integration testing expectations * Regenerate files
This commit is contained in:
parent
1b60ee1799
commit
68b944e6e6
@ -5303,14 +5303,6 @@ public class DefaultCodegen implements CodegenConfig {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// sort auth methods to maintain the same order
|
|
||||||
Collections.sort(codegenSecurities, new Comparator<CodegenSecurity>() {
|
|
||||||
@Override
|
|
||||||
public int compare(CodegenSecurity one, CodegenSecurity another) {
|
|
||||||
return ObjectUtils.compare(one.name, another.name);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
return codegenSecurities;
|
return codegenSecurities;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2543,6 +2543,20 @@ public class DefaultCodegenTest {
|
|||||||
assertTrue(flows.containsAll(Arrays.asList("password", "application")));
|
assertTrue(flows.containsAll(Arrays.asList("password", "application")));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testMultipleSecuritySchemes() {
|
||||||
|
final OpenAPI openAPI = TestUtils.parseFlattenSpec("src/test/resources/3_0/petstore.yaml");
|
||||||
|
final DefaultCodegen codegen = new DefaultCodegen();
|
||||||
|
codegen.setOpenAPI(openAPI);
|
||||||
|
|
||||||
|
final Map<String, SecurityScheme> securitySchemes = openAPI.getComponents().getSecuritySchemes();
|
||||||
|
final List<CodegenSecurity> securities = codegen.fromSecurity(securitySchemes);
|
||||||
|
|
||||||
|
assertEquals(securities.size(), 2);
|
||||||
|
assertEquals(securities.get(0).name, "petstore_auth");
|
||||||
|
assertEquals(securities.get(1).name, "api_key");
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testItemsPresent() {
|
public void testItemsPresent() {
|
||||||
final OpenAPI openAPI = TestUtils.parseFlattenSpec("src/test/resources/3_0/issue_7613.yaml");
|
final OpenAPI openAPI = TestUtils.parseFlattenSpec("src/test/resources/3_0/issue_7613.yaml");
|
||||||
|
@ -87,6 +87,15 @@ export class Configuration {
|
|||||||
this.credentials = {};
|
this.credentials = {};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// init default petstore_auth credential
|
||||||
|
if (!this.credentials['petstore_auth']) {
|
||||||
|
this.credentials['petstore_auth'] = () => {
|
||||||
|
return typeof this.accessToken === 'function'
|
||||||
|
? this.accessToken()
|
||||||
|
: this.accessToken;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
// init default api_key credential
|
// init default api_key credential
|
||||||
if (!this.credentials['api_key']) {
|
if (!this.credentials['api_key']) {
|
||||||
this.credentials['api_key'] = () => {
|
this.credentials['api_key'] = () => {
|
||||||
@ -97,15 +106,6 @@ export class Configuration {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
// init default petstore_auth credential
|
|
||||||
if (!this.credentials['petstore_auth']) {
|
|
||||||
this.credentials['petstore_auth'] = () => {
|
|
||||||
return typeof this.accessToken === 'function'
|
|
||||||
? this.accessToken()
|
|
||||||
: this.accessToken;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -134,20 +134,14 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
|
||||||
### BearerToken
|
|
||||||
|
|
||||||
- **Type**: Bearer authentication
|
|
||||||
|
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### http_auth
|
### http_auth
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
### BearerToken
|
||||||
|
|
||||||
|
- **Type**: Bearer authentication
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -157,4 +151,10 @@ Class | Method | HTTP request | Description
|
|||||||
- `write:pets`: modify pets in your account
|
- `write:pets`: modify pets in your account
|
||||||
- `read:pets`: read your pets
|
- `read:pets`: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
|
@ -134,20 +134,14 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
|
||||||
### BearerToken
|
|
||||||
|
|
||||||
- **Type**: Bearer authentication
|
|
||||||
|
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### http_auth
|
### http_auth
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
### BearerToken
|
||||||
|
|
||||||
|
- **Type**: Bearer authentication
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -157,4 +151,10 @@ Class | Method | HTTP request | Description
|
|||||||
- `write:pets`: modify pets in your account
|
- `write:pets`: modify pets in your account
|
||||||
- `read:pets`: read your pets
|
- `read:pets`: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
|
@ -134,20 +134,14 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
|
||||||
### BearerToken
|
|
||||||
|
|
||||||
- **Type**: Bearer authentication
|
|
||||||
|
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### http_auth
|
### http_auth
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
### BearerToken
|
||||||
|
|
||||||
|
- **Type**: Bearer authentication
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -157,4 +151,10 @@ Class | Method | HTTP request | Description
|
|||||||
- `write:pets`: modify pets in your account
|
- `write:pets`: modify pets in your account
|
||||||
- `read:pets`: read your pets
|
- `read:pets`: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
|
@ -100,13 +100,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -116,6 +109,13 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Author
|
## Author
|
||||||
|
|
||||||
|
@ -200,6 +200,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation For Authorization
|
## Documentation For Authorization
|
||||||
|
|
||||||
|
|
||||||
|
## petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- **write:pets**: modify pets in your account
|
||||||
|
- **read:pets**: read your pets
|
||||||
|
|
||||||
## api_key
|
## api_key
|
||||||
|
|
||||||
|
|
||||||
@ -218,13 +228,3 @@ Class | Method | HTTP request | Description
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
## petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- **write:pets**: modify pets in your account
|
|
||||||
- **read:pets**: read your pets
|
|
||||||
|
|
||||||
|
@ -742,18 +742,18 @@ ${BOLD}${WHITE}Usage${OFF}
|
|||||||
EOF
|
EOF
|
||||||
echo -e "${BOLD}${WHITE}Authentication methods${OFF}"
|
echo -e "${BOLD}${WHITE}Authentication methods${OFF}"
|
||||||
echo -e ""
|
echo -e ""
|
||||||
echo -e " - ${BLUE}Api-key${OFF} - add '${RED}api_key:<api-key>${OFF}' after ${YELLOW}<operation>${OFF}"
|
|
||||||
echo -e " or export ${RED}PETSTORE_API_KEY='<api-key>'${OFF}"
|
|
||||||
echo -e " - ${BLUE}Api-key${OFF} - add '${RED}api_key_query=<api-key>${OFF}' after ${YELLOW}<operation>${OFF}"
|
|
||||||
echo -e " or export ${RED}PETSTORE_API_KEY='<api-key>'${OFF}"
|
|
||||||
echo -e " - ${BLUE}Basic AUTH${OFF} - add '-u <username>:<password>' before ${YELLOW}<operation>${OFF}"
|
|
||||||
echo -e " or export ${RED}PETSTORE_BASIC_AUTH='<username>:<password>'${OFF}"
|
|
||||||
echo -e " - ${MAGENTA}OAuth2 (flow: implicit)${OFF}"
|
echo -e " - ${MAGENTA}OAuth2 (flow: implicit)${OFF}"
|
||||||
echo -e " Authorization URL: "
|
echo -e " Authorization URL: "
|
||||||
echo -e " * http://petstore.swagger.io/api/oauth/dialog"
|
echo -e " * http://petstore.swagger.io/api/oauth/dialog"
|
||||||
echo -e " Scopes:"
|
echo -e " Scopes:"
|
||||||
echo -e " * write:pets - modify pets in your account"
|
echo -e " * write:pets - modify pets in your account"
|
||||||
echo -e " * read:pets - read your pets"
|
echo -e " * read:pets - read your pets"
|
||||||
|
echo -e " - ${BLUE}Api-key${OFF} - add '${RED}api_key:<api-key>${OFF}' after ${YELLOW}<operation>${OFF}"
|
||||||
|
echo -e " or export ${RED}PETSTORE_API_KEY='<api-key>'${OFF}"
|
||||||
|
echo -e " - ${BLUE}Api-key${OFF} - add '${RED}api_key_query=<api-key>${OFF}' after ${YELLOW}<operation>${OFF}"
|
||||||
|
echo -e " or export ${RED}PETSTORE_API_KEY='<api-key>'${OFF}"
|
||||||
|
echo -e " - ${BLUE}Basic AUTH${OFF} - add '-u <username>:<password>' before ${YELLOW}<operation>${OFF}"
|
||||||
|
echo -e " or export ${RED}PETSTORE_BASIC_AUTH='<username>:<password>'${OFF}"
|
||||||
echo ""
|
echo ""
|
||||||
echo -e "${BOLD}${WHITE}Operations (grouped by tags)${OFF}"
|
echo -e "${BOLD}${WHITE}Operations (grouped by tags)${OFF}"
|
||||||
echo ""
|
echo ""
|
||||||
|
@ -100,14 +100,6 @@ Category | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
@ -119,6 +111,14 @@ Category | Method | HTTP request | Description
|
|||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Author
|
## Author
|
||||||
|
|
||||||
|
|
||||||
|
@ -28,8 +28,8 @@ typedef struct apiClient_t {
|
|||||||
int (*progress_func)(void *, curl_off_t, curl_off_t, curl_off_t, curl_off_t);
|
int (*progress_func)(void *, curl_off_t, curl_off_t, curl_off_t, curl_off_t);
|
||||||
void *progress_data;
|
void *progress_data;
|
||||||
long response_code;
|
long response_code;
|
||||||
list_t *apiKeys_api_key;
|
|
||||||
char *accessToken;
|
char *accessToken;
|
||||||
|
list_t *apiKeys_api_key;
|
||||||
} apiClient_t;
|
} apiClient_t;
|
||||||
|
|
||||||
apiClient_t* apiClient_create();
|
apiClient_t* apiClient_create();
|
||||||
|
@ -16,8 +16,8 @@ apiClient_t *apiClient_create() {
|
|||||||
apiClient->progress_func = NULL;
|
apiClient->progress_func = NULL;
|
||||||
apiClient->progress_data = NULL;
|
apiClient->progress_data = NULL;
|
||||||
apiClient->response_code = 0;
|
apiClient->response_code = 0;
|
||||||
apiClient->apiKeys_api_key = NULL;
|
|
||||||
apiClient->accessToken = NULL;
|
apiClient->accessToken = NULL;
|
||||||
|
apiClient->apiKeys_api_key = NULL;
|
||||||
|
|
||||||
return apiClient;
|
return apiClient;
|
||||||
}
|
}
|
||||||
@ -45,6 +45,7 @@ apiClient_t *apiClient_create_with_base_path(const char *basePath
|
|||||||
apiClient->progress_func = NULL;
|
apiClient->progress_func = NULL;
|
||||||
apiClient->progress_data = NULL;
|
apiClient->progress_data = NULL;
|
||||||
apiClient->response_code = 0;
|
apiClient->response_code = 0;
|
||||||
|
apiClient->accessToken = NULL;
|
||||||
if(apiKeys_api_key!= NULL) {
|
if(apiKeys_api_key!= NULL) {
|
||||||
apiClient->apiKeys_api_key = list_createList();
|
apiClient->apiKeys_api_key = list_createList();
|
||||||
listEntry_t *listEntry = NULL;
|
listEntry_t *listEntry = NULL;
|
||||||
@ -56,7 +57,6 @@ apiClient_t *apiClient_create_with_base_path(const char *basePath
|
|||||||
}else{
|
}else{
|
||||||
apiClient->apiKeys_api_key = NULL;
|
apiClient->apiKeys_api_key = NULL;
|
||||||
}
|
}
|
||||||
apiClient->accessToken = NULL;
|
|
||||||
|
|
||||||
return apiClient;
|
return apiClient;
|
||||||
}
|
}
|
||||||
@ -68,6 +68,9 @@ void apiClient_free(apiClient_t *apiClient) {
|
|||||||
apiClient->data_callback_func = NULL;
|
apiClient->data_callback_func = NULL;
|
||||||
apiClient->progress_func = NULL;
|
apiClient->progress_func = NULL;
|
||||||
apiClient->progress_data = NULL;
|
apiClient->progress_data = NULL;
|
||||||
|
if(apiClient->accessToken) {
|
||||||
|
free(apiClient->accessToken);
|
||||||
|
}
|
||||||
if(apiClient->apiKeys_api_key) {
|
if(apiClient->apiKeys_api_key) {
|
||||||
listEntry_t *listEntry = NULL;
|
listEntry_t *listEntry = NULL;
|
||||||
list_ForEach(listEntry, apiClient->apiKeys_api_key) {
|
list_ForEach(listEntry, apiClient->apiKeys_api_key) {
|
||||||
@ -82,9 +85,6 @@ void apiClient_free(apiClient_t *apiClient) {
|
|||||||
}
|
}
|
||||||
list_freeList(apiClient->apiKeys_api_key);
|
list_freeList(apiClient->apiKeys_api_key);
|
||||||
}
|
}
|
||||||
if(apiClient->accessToken) {
|
|
||||||
free(apiClient->accessToken);
|
|
||||||
}
|
|
||||||
free(apiClient);
|
free(apiClient);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -128,13 +128,6 @@ servers:
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
@ -145,6 +138,13 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Author
|
## Author
|
||||||
|
|
||||||
|
@ -218,18 +218,18 @@ module Petstore
|
|||||||
# Returns Auth Settings hash for api client.
|
# Returns Auth Settings hash for api client.
|
||||||
def auth_settings
|
def auth_settings
|
||||||
Hash{
|
Hash{
|
||||||
"api_key" => {
|
|
||||||
type: "api_key",
|
|
||||||
in: "header",
|
|
||||||
key: "api_key",
|
|
||||||
value: api_key_with_prefix(:api_key)
|
|
||||||
},
|
|
||||||
"petstore_auth" => {
|
"petstore_auth" => {
|
||||||
type: "oauth2",
|
type: "oauth2",
|
||||||
in: "header",
|
in: "header",
|
||||||
key: "Authorization",
|
key: "Authorization",
|
||||||
value: "Bearer #{access_token}"
|
value: "Bearer #{access_token}"
|
||||||
},
|
},
|
||||||
|
"api_key" => {
|
||||||
|
type: "api_key",
|
||||||
|
in: "header",
|
||||||
|
key: "api_key",
|
||||||
|
value: api_key_with_prefix(:api_key)
|
||||||
|
},
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -234,6 +234,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -248,27 +258,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -657,22 +657,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -689,6 +673,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -762,22 +762,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -794,6 +778,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1038,22 +1038,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1070,6 +1054,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1144,22 +1144,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1176,6 +1160,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1250,22 +1250,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1282,6 +1266,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1358,22 +1358,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1390,6 +1374,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1605,22 +1605,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1637,6 +1621,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1710,22 +1710,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1742,6 +1726,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -553,6 +553,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -561,12 +567,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] contentTypes = new string[] {
|
string[] contentTypes = new string[] {
|
||||||
"application/json",
|
"application/json",
|
||||||
"application/xml"
|
"application/xml"
|
||||||
@ -883,6 +883,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -891,12 +897,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] accepts = new string[] {
|
string[] accepts = new string[] {
|
||||||
"application/xml",
|
"application/xml",
|
||||||
"application/json"
|
"application/json"
|
||||||
@ -1056,6 +1056,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -1064,12 +1070,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] accepts = new string[] {
|
string[] accepts = new string[] {
|
||||||
"application/xml",
|
"application/xml",
|
||||||
"application/json"
|
"application/json"
|
||||||
@ -1381,6 +1381,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -1389,12 +1395,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] contentTypes = new string[] {
|
string[] contentTypes = new string[] {
|
||||||
"application/json",
|
"application/json",
|
||||||
"application/xml"
|
"application/xml"
|
||||||
|
@ -155,6 +155,17 @@ namespace YourProject
|
|||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -169,34 +180,23 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
## Build
|
## Build
|
||||||
- SDK version: 1.0.0
|
- SDK version: 1.0.0
|
||||||
- Build package: org.openapitools.codegen.languages.CSharpNetCoreClientCodegen
|
- Build package: org.openapitools.codegen.languages.CSharpNetCoreClientCodegen
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -445,6 +445,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -453,12 +459,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] contentTypes = new string[] {
|
string[] contentTypes = new string[] {
|
||||||
"application/json",
|
"application/json",
|
||||||
"application/xml"
|
"application/xml"
|
||||||
@ -775,6 +775,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -783,12 +789,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] accepts = new string[] {
|
string[] accepts = new string[] {
|
||||||
"application/xml",
|
"application/xml",
|
||||||
"application/json"
|
"application/json"
|
||||||
@ -948,6 +948,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -956,12 +962,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] accepts = new string[] {
|
string[] accepts = new string[] {
|
||||||
"application/xml",
|
"application/xml",
|
||||||
"application/json"
|
"application/json"
|
||||||
@ -1273,6 +1273,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -1281,12 +1287,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] contentTypes = new string[] {
|
string[] contentTypes = new string[] {
|
||||||
"application/json",
|
"application/json",
|
||||||
"application/xml"
|
"application/xml"
|
||||||
|
@ -155,6 +155,17 @@ namespace YourProject
|
|||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -169,34 +180,23 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
## Build
|
## Build
|
||||||
- SDK version: 1.0.0
|
- SDK version: 1.0.0
|
||||||
- Build package: org.openapitools.codegen.languages.CSharpNetCoreClientCodegen
|
- Build package: org.openapitools.codegen.languages.CSharpNetCoreClientCodegen
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -445,6 +445,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -453,12 +459,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] contentTypes = new string[] {
|
string[] contentTypes = new string[] {
|
||||||
"application/json",
|
"application/json",
|
||||||
"application/xml"
|
"application/xml"
|
||||||
@ -775,6 +775,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -783,12 +789,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] accepts = new string[] {
|
string[] accepts = new string[] {
|
||||||
"application/xml",
|
"application/xml",
|
||||||
"application/json"
|
"application/json"
|
||||||
@ -948,6 +948,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -956,12 +962,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] accepts = new string[] {
|
string[] accepts = new string[] {
|
||||||
"application/xml",
|
"application/xml",
|
||||||
"application/json"
|
"application/json"
|
||||||
@ -1273,6 +1273,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
request.RequestUri = uriBuilder.Uri;
|
request.RequestUri = uriBuilder.Uri;
|
||||||
|
|
||||||
|
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
|
tokens.Add(oauthToken);
|
||||||
|
|
||||||
|
oauthToken.UseInHeader(request, "");
|
||||||
|
|
||||||
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
HttpSignatureToken signatureToken = (HttpSignatureToken) await HttpSignatureTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
||||||
|
|
||||||
tokens.Add(signatureToken);
|
tokens.Add(signatureToken);
|
||||||
@ -1281,12 +1287,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
signatureToken.UseInHeader(request, requestBody, cancellationToken);
|
||||||
|
|
||||||
OAuthToken oauthToken = (OAuthToken) await OauthTokenProvider.GetAsync(cancellationToken).ConfigureAwait(false);
|
|
||||||
|
|
||||||
tokens.Add(oauthToken);
|
|
||||||
|
|
||||||
oauthToken.UseInHeader(request, "");
|
|
||||||
|
|
||||||
string[] contentTypes = new string[] {
|
string[] contentTypes = new string[] {
|
||||||
"application/json",
|
"application/json",
|
||||||
"application/xml"
|
"application/xml"
|
||||||
|
@ -155,6 +155,17 @@ namespace YourProject
|
|||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -169,34 +180,23 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
## Build
|
## Build
|
||||||
- SDK version: 1.0.0
|
- SDK version: 1.0.0
|
||||||
- Build package: org.openapitools.codegen.languages.CSharpNetCoreClientCodegen
|
- Build package: org.openapitools.codegen.languages.CSharpNetCoreClientCodegen
|
||||||
|
@ -259,6 +259,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -273,27 +283,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -91,7 +91,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -283,7 +283,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -382,7 +382,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -577,7 +577,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -701,6 +701,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.Data = pet;
|
localVarRequestOptions.Data = pet;
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -717,12 +723,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -782,6 +782,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.Data = pet;
|
localVarRequestOptions.Data = pet;
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -798,12 +804,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
|
|
||||||
@ -988,6 +988,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "status", status));
|
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "status", status));
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -1004,12 +1010,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1070,6 +1070,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "status", status));
|
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "status", status));
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -1086,12 +1092,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
|
|
||||||
@ -1151,6 +1151,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "tags", tags));
|
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "tags", tags));
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -1167,12 +1173,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1235,6 +1235,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "tags", tags));
|
localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("csv", "tags", tags));
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -1251,12 +1257,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
|
|
||||||
@ -1432,6 +1432,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.Data = pet;
|
localVarRequestOptions.Data = pet;
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -1448,12 +1454,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1513,6 +1513,12 @@ namespace Org.OpenAPITools.Api
|
|||||||
|
|
||||||
localVarRequestOptions.Data = pet;
|
localVarRequestOptions.Data = pet;
|
||||||
|
|
||||||
|
// authentication (petstore_auth) required
|
||||||
|
// oauth required
|
||||||
|
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
||||||
|
}
|
||||||
// authentication (http_signature_test) required
|
// authentication (http_signature_test) required
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
{
|
{
|
||||||
@ -1529,12 +1535,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// authentication (petstore_auth) required
|
|
||||||
// oauth required
|
|
||||||
if (!string.IsNullOrEmpty(this.Configuration.AccessToken) && !localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken);
|
|
||||||
}
|
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
|
|
||||||
|
@ -246,6 +246,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -260,27 +270,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -657,22 +657,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -689,6 +673,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -762,22 +762,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -794,6 +778,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1038,22 +1038,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1070,6 +1054,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1144,22 +1144,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1176,6 +1160,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1250,22 +1250,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1282,6 +1266,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1358,22 +1358,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1390,6 +1374,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1605,22 +1605,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1637,6 +1621,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1710,22 +1710,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1742,6 +1726,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
|
@ -246,6 +246,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -260,27 +270,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -657,22 +657,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -689,6 +673,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -762,22 +762,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -794,6 +778,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1038,22 +1038,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1070,6 +1054,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1144,22 +1144,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1176,6 +1160,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1250,22 +1250,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1282,6 +1266,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1358,22 +1358,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1390,6 +1374,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1605,22 +1605,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1637,6 +1621,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1710,22 +1710,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1742,6 +1726,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
|
@ -246,6 +246,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -260,27 +270,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -657,22 +657,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -689,6 +673,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -762,22 +762,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -794,6 +778,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1038,22 +1038,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1070,6 +1054,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1144,22 +1144,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1176,6 +1160,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1250,22 +1250,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1282,6 +1266,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1358,22 +1358,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1390,6 +1374,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1605,22 +1605,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1637,6 +1621,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1710,22 +1710,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1742,6 +1726,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
|
@ -234,6 +234,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -248,27 +258,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -657,22 +657,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -689,6 +673,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -762,22 +762,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -794,6 +778,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1038,22 +1038,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1070,6 +1054,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1144,22 +1144,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1176,6 +1160,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1250,22 +1250,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1282,6 +1266,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1358,22 +1358,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1390,6 +1374,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1605,22 +1605,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1637,6 +1621,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1710,22 +1710,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1742,6 +1726,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
|
@ -246,6 +246,16 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
<a name="petstore_auth"></a>
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
<a name="api_key"></a>
|
<a name="api_key"></a>
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
@ -260,27 +270,17 @@ Class | Method | HTTP request | Description
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
<a name="bearer_test"></a>
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
- **Type**: Bearer Authentication
|
|
||||||
|
|
||||||
<a name="http_basic_test"></a>
|
<a name="http_basic_test"></a>
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
<a name="bearer_test"></a>
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
- **Type**: Bearer Authentication
|
||||||
|
|
||||||
<a name="http_signature_test"></a>
|
<a name="http_signature_test"></a>
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -366,7 +366,7 @@ catch (ApiException e)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -657,22 +657,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -689,6 +673,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Post<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -762,22 +762,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.AddPet";
|
localVarRequestOptions.Operation = "PetApi.AddPet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -794,6 +778,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "POST", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PostAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1038,22 +1038,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1070,6 +1054,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration);
|
||||||
@ -1144,22 +1144,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByStatus";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1176,6 +1160,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByStatus", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByStatus", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1250,22 +1250,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1282,6 +1266,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Get<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration);
|
||||||
@ -1358,22 +1358,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
localVarRequestOptions.Operation = "PetApi.FindPetsByTags";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1390,6 +1374,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "GET", "/pet/findByTags", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Pet>>("/pet/findByTags", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
@ -1605,22 +1605,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1637,6 +1621,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
var localVarResponse = this.Client.Put<Object>("/pet", localVarRequestOptions, this.Configuration);
|
||||||
@ -1710,22 +1710,6 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
localVarRequestOptions.Operation = "PetApi.UpdatePet";
|
||||||
localVarRequestOptions.OperationIndex = operationIndex;
|
localVarRequestOptions.OperationIndex = operationIndex;
|
||||||
|
|
||||||
// authentication (http_signature_test) required
|
|
||||||
if (this.Configuration.HttpSigningConfiguration != null)
|
|
||||||
{
|
|
||||||
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
|
||||||
foreach (var headerItem in HttpSigningHeaders)
|
|
||||||
{
|
|
||||||
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// authentication (petstore_auth) required
|
// authentication (petstore_auth) required
|
||||||
// oauth required
|
// oauth required
|
||||||
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
if (!localVarRequestOptions.HeaderParameters.ContainsKey("Authorization"))
|
||||||
@ -1742,6 +1726,22 @@ namespace Org.OpenAPITools.Api
|
|||||||
localVarRequestOptions.OAuth = true;
|
localVarRequestOptions.OAuth = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// authentication (http_signature_test) required
|
||||||
|
if (this.Configuration.HttpSigningConfiguration != null)
|
||||||
|
{
|
||||||
|
var HttpSigningHeaders = this.Configuration.HttpSigningConfiguration.GetHttpSignedHeader(this.Configuration.BasePath, "PUT", "/pet", localVarRequestOptions);
|
||||||
|
foreach (var headerItem in HttpSigningHeaders)
|
||||||
|
{
|
||||||
|
if (localVarRequestOptions.HeaderParameters.ContainsKey(headerItem.Key))
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters[headerItem.Key] = new List<string>() { headerItem.Value };
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
localVarRequestOptions.HeaderParameters.Add(headerItem.Key, headerItem.Value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// make the HTTP request
|
// make the HTTP request
|
||||||
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
var localVarResponse = await this.AsynchronousClient.PutAsync<Object>("/pet", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
|
||||||
|
@ -142,13 +142,6 @@ Class | Method | HTTP request | Description
|
|||||||
<a name="documentation-for-authorization"></a>
|
<a name="documentation-for-authorization"></a>
|
||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
<a name="api_key"></a>
|
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
<a name="petstore_auth"></a>
|
<a name="petstore_auth"></a>
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
@ -159,3 +152,10 @@ Class | Method | HTTP request | Description
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
<a name="api_key"></a>
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
@ -203,6 +203,17 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
|
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
- **Type**: API key
|
- **Type**: API key
|
||||||
@ -219,29 +230,18 @@ Class | Method | HTTP request | Description
|
|||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
|
|
||||||
### bearer_test
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP bearer authentication
|
|
||||||
|
|
||||||
|
|
||||||
### http_basic_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
|
|
||||||
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: HTTP bearer authentication
|
||||||
|
|
||||||
|
|
||||||
### http_signature_test
|
### http_signature_test
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
@ -173,6 +173,36 @@ Class | Method | HTTP request | Description
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- **write:pets**: modify pets in your account
|
||||||
|
- **read:pets**: read your pets
|
||||||
|
|
||||||
|
Example
|
||||||
|
|
||||||
|
```golang
|
||||||
|
auth := context.WithValue(context.Background(), sw.ContextAccessToken, "ACCESSTOKENSTRING")
|
||||||
|
r, err := client.Service.Operation(auth, args)
|
||||||
|
```
|
||||||
|
|
||||||
|
Or via OAuth2 module to automatically refresh tokens and perform user authentication.
|
||||||
|
|
||||||
|
```golang
|
||||||
|
import "golang.org/x/oauth2"
|
||||||
|
|
||||||
|
/* Perform OAuth2 round trip request and obtain a token */
|
||||||
|
|
||||||
|
tokenSource := oauth2cfg.TokenSource(createContext(httpClient), &token)
|
||||||
|
auth := context.WithValue(oauth2.NoContext, sw.ContextOAuth2, tokenSource)
|
||||||
|
r, err := client.Service.Operation(auth, args)
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
- **Type**: API key
|
- **Type**: API key
|
||||||
@ -206,36 +236,6 @@ r, err := client.Service.Operation(auth, args)
|
|||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- **write:pets**: modify pets in your account
|
|
||||||
- **read:pets**: read your pets
|
|
||||||
|
|
||||||
Example
|
|
||||||
|
|
||||||
```golang
|
|
||||||
auth := context.WithValue(context.Background(), sw.ContextAccessToken, "ACCESSTOKENSTRING")
|
|
||||||
r, err := client.Service.Operation(auth, args)
|
|
||||||
```
|
|
||||||
|
|
||||||
Or via OAuth2 module to automatically refresh tokens and perform user authentication.
|
|
||||||
|
|
||||||
```golang
|
|
||||||
import "golang.org/x/oauth2"
|
|
||||||
|
|
||||||
/* Perform OAuth2 round trip request and obtain a token */
|
|
||||||
|
|
||||||
tokenSource := oauth2cfg.TokenSource(createContext(httpClient), &token)
|
|
||||||
auth := context.WithValue(oauth2.NoContext, sw.ContextOAuth2, tokenSource)
|
|
||||||
r, err := client.Service.Operation(auth, args)
|
|
||||||
```
|
|
||||||
|
|
||||||
|
|
||||||
## Documentation for Utility Methods
|
## Documentation for Utility Methods
|
||||||
|
|
||||||
Due to the fact that model structure members are all pointers, this package contains
|
Due to the fact that model structure members are all pointers, this package contains
|
||||||
|
@ -2430,6 +2430,19 @@ toOuterEnum = \case
|
|||||||
|
|
||||||
-- * Auth Methods
|
-- * Auth Methods
|
||||||
|
|
||||||
|
-- ** AuthOAuthPetstoreAuth
|
||||||
|
data AuthOAuthPetstoreAuth =
|
||||||
|
AuthOAuthPetstoreAuth Text -- ^ secret
|
||||||
|
deriving (P.Eq, P.Show, P.Typeable)
|
||||||
|
|
||||||
|
instance AuthMethod AuthOAuthPetstoreAuth where
|
||||||
|
applyAuthMethod _ a@(AuthOAuthPetstoreAuth secret) req =
|
||||||
|
P.pure $
|
||||||
|
if (P.typeOf a `P.elem` rAuthTypes req)
|
||||||
|
then req `setHeader` toHeader ("Authorization", "Bearer " <> secret)
|
||||||
|
& L.over rAuthTypesL (P.filter (/= P.typeOf a))
|
||||||
|
else req
|
||||||
|
|
||||||
-- ** AuthApiKeyApiKey
|
-- ** AuthApiKeyApiKey
|
||||||
data AuthApiKeyApiKey =
|
data AuthApiKeyApiKey =
|
||||||
AuthApiKeyApiKey Text -- ^ secret
|
AuthApiKeyApiKey Text -- ^ secret
|
||||||
@ -2470,17 +2483,4 @@ instance AuthMethod AuthBasicHttpBasicTest where
|
|||||||
else req
|
else req
|
||||||
where cred = BC.append "Basic " (B64.encode $ BC.concat [ user, ":", pw ])
|
where cred = BC.append "Basic " (B64.encode $ BC.concat [ user, ":", pw ])
|
||||||
|
|
||||||
-- ** AuthOAuthPetstoreAuth
|
|
||||||
data AuthOAuthPetstoreAuth =
|
|
||||||
AuthOAuthPetstoreAuth Text -- ^ secret
|
|
||||||
deriving (P.Eq, P.Show, P.Typeable)
|
|
||||||
|
|
||||||
instance AuthMethod AuthOAuthPetstoreAuth where
|
|
||||||
applyAuthMethod _ a@(AuthOAuthPetstoreAuth secret) req =
|
|
||||||
P.pure $
|
|
||||||
if (P.typeOf a `P.elem` rAuthTypes req)
|
|
||||||
then req `setHeader` toHeader ("Authorization", "Bearer " <> secret)
|
|
||||||
& L.over rAuthTypesL (P.filter (/= P.typeOf a))
|
|
||||||
else req
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,5 +1,15 @@
|
|||||||
# Authorization methods
|
# Authorization methods
|
||||||
<a name="name"></a>
|
<a name="name"></a>
|
||||||
|
# petstore_auth
|
||||||
|
Authorization method is **OAuth2** with `implicit` flow.
|
||||||
|
The scopes are:
|
||||||
|
* `write:pets`
|
||||||
|
* `read:pets`
|
||||||
|
|
||||||
|
It can be configured in the [application.yml](src/main/resources/application.yml) using Micronaut security features.
|
||||||
|
|
||||||
|
More information on configuring can be found in [Micronaut Security Guide](https://micronaut-projects.github.io/micronaut-security/latest/guide/#oauth).
|
||||||
|
<a name="name"></a>
|
||||||
# api_key
|
# api_key
|
||||||
Authorization method is of **api key type**. The parameter `api_key` is located in `header`.
|
Authorization method is of **api key type**. The parameter `api_key` is located in `header`.
|
||||||
|
|
||||||
@ -14,13 +24,3 @@ It can be configured in the [application.yml](src/main/resources/application.yml
|
|||||||
Authorization method is of **basic auth**.
|
Authorization method is of **basic auth**.
|
||||||
|
|
||||||
It can be configured in the [application.yml](src/main/resources/application.yml) using Micronaut security features.
|
It can be configured in the [application.yml](src/main/resources/application.yml) using Micronaut security features.
|
||||||
<a name="name"></a>
|
|
||||||
# petstore_auth
|
|
||||||
Authorization method is **OAuth2** with `implicit` flow.
|
|
||||||
The scopes are:
|
|
||||||
* `write:pets`
|
|
||||||
* `read:pets`
|
|
||||||
|
|
||||||
It can be configured in the [application.yml](src/main/resources/application.yml) using Micronaut security features.
|
|
||||||
|
|
||||||
More information on configuring can be found in [Micronaut Security Guide](https://micronaut-projects.github.io/micronaut-security/latest/guide/#oauth).
|
|
||||||
|
@ -204,6 +204,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -218,12 +228,12 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
### bearer_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### http_basic_test
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
@ -233,16 +243,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -172,12 +172,12 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
|
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
||||||
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
|
||||||
|
@ -58,14 +58,14 @@ public class ApiClient {
|
|||||||
for(String authName : authNames) {
|
for(String authName : authNames) {
|
||||||
log.log(Level.FINE, "Creating authentication {0}", authName);
|
log.log(Level.FINE, "Creating authentication {0}", authName);
|
||||||
RequestInterceptor auth;
|
RequestInterceptor auth;
|
||||||
if ("api_key".equals(authName)) {
|
if ("petstore_auth".equals(authName)) {
|
||||||
|
auth = buildOauthRequestInterceptor(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
||||||
|
} else if ("api_key".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("header", "api_key");
|
auth = new ApiKeyAuth("header", "api_key");
|
||||||
} else if ("api_key_query".equals(authName)) {
|
} else if ("api_key_query".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("query", "api_key_query");
|
auth = new ApiKeyAuth("query", "api_key_query");
|
||||||
} else if ("http_basic_test".equals(authName)) {
|
} else if ("http_basic_test".equals(authName)) {
|
||||||
auth = new HttpBasicAuth();
|
auth = new HttpBasicAuth();
|
||||||
} else if ("petstore_auth".equals(authName)) {
|
|
||||||
auth = buildOauthRequestInterceptor(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
||||||
}
|
}
|
||||||
|
@ -59,18 +59,18 @@ public class ApiClient {
|
|||||||
for(String authName : authNames) {
|
for(String authName : authNames) {
|
||||||
log.log(Level.FINE, "Creating authentication {0}", authName);
|
log.log(Level.FINE, "Creating authentication {0}", authName);
|
||||||
RequestInterceptor auth;
|
RequestInterceptor auth;
|
||||||
if ("api_key".equals(authName)) {
|
if ("petstore_auth".equals(authName)) {
|
||||||
|
auth = buildOauthRequestInterceptor(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
||||||
|
} else if ("api_key".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("header", "api_key");
|
auth = new ApiKeyAuth("header", "api_key");
|
||||||
} else if ("api_key_query".equals(authName)) {
|
} else if ("api_key_query".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("query", "api_key_query");
|
auth = new ApiKeyAuth("query", "api_key_query");
|
||||||
} else if ("bearer_test".equals(authName)) {
|
|
||||||
auth = new HttpBearerAuth("bearer");
|
|
||||||
} else if ("http_basic_test".equals(authName)) {
|
} else if ("http_basic_test".equals(authName)) {
|
||||||
auth = new HttpBasicAuth();
|
auth = new HttpBasicAuth();
|
||||||
|
} else if ("bearer_test".equals(authName)) {
|
||||||
|
auth = new HttpBearerAuth("bearer");
|
||||||
} else if ("http_signature_test".equals(authName)) {
|
} else if ("http_signature_test".equals(authName)) {
|
||||||
auth = new HttpBearerAuth("signature");
|
auth = new HttpBearerAuth("signature");
|
||||||
} else if ("petstore_auth".equals(authName)) {
|
|
||||||
auth = buildOauthRequestInterceptor(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
||||||
}
|
}
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -102,10 +102,10 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
|
||||||
|
@ -232,6 +232,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -251,16 +261,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -127,6 +127,14 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
Authentication auth = null;
|
Authentication auth = null;
|
||||||
|
if (authMap != null) {
|
||||||
|
auth = authMap.get("petstore_auth");
|
||||||
|
}
|
||||||
|
if (auth instanceof OAuth) {
|
||||||
|
authentications.put("petstore_auth", auth);
|
||||||
|
} else {
|
||||||
|
authentications.put("petstore_auth", new OAuth(basePath, ""));
|
||||||
|
}
|
||||||
if (authMap != null) {
|
if (authMap != null) {
|
||||||
auth = authMap.get("api_key");
|
auth = authMap.get("api_key");
|
||||||
}
|
}
|
||||||
@ -151,14 +159,6 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
} else {
|
} else {
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
}
|
}
|
||||||
if (authMap != null) {
|
|
||||||
auth = authMap.get("petstore_auth");
|
|
||||||
}
|
|
||||||
if (auth instanceof OAuth) {
|
|
||||||
authentications.put("petstore_auth", auth);
|
|
||||||
} else {
|
|
||||||
authentications.put("petstore_auth", new OAuth(basePath, ""));
|
|
||||||
}
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
|
||||||
|
@ -232,6 +232,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -251,16 +261,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -127,6 +127,14 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
Authentication auth = null;
|
Authentication auth = null;
|
||||||
|
if (authMap != null) {
|
||||||
|
auth = authMap.get("petstore_auth");
|
||||||
|
}
|
||||||
|
if (auth instanceof OAuth) {
|
||||||
|
authentications.put("petstore_auth", auth);
|
||||||
|
} else {
|
||||||
|
authentications.put("petstore_auth", new OAuth(basePath, ""));
|
||||||
|
}
|
||||||
if (authMap != null) {
|
if (authMap != null) {
|
||||||
auth = authMap.get("api_key");
|
auth = authMap.get("api_key");
|
||||||
}
|
}
|
||||||
@ -151,14 +159,6 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
} else {
|
} else {
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
}
|
}
|
||||||
if (authMap != null) {
|
|
||||||
auth = authMap.get("petstore_auth");
|
|
||||||
}
|
|
||||||
if (auth instanceof OAuth) {
|
|
||||||
authentications.put("petstore_auth", auth);
|
|
||||||
} else {
|
|
||||||
authentications.put("petstore_auth", new OAuth(basePath, ""));
|
|
||||||
}
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
|
||||||
|
@ -237,6 +237,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -251,12 +261,12 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
### bearer_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### http_basic_test
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
@ -266,16 +276,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -40,11 +40,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -73,7 +73,7 @@ null (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -181,11 +181,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
||||||
try {
|
try {
|
||||||
@ -215,7 +215,7 @@ public class Example {
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -253,11 +253,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
||||||
try {
|
try {
|
||||||
@ -287,7 +287,7 @@ public class Example {
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -399,11 +399,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -432,7 +432,7 @@ null (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -197,6 +197,14 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
Authentication auth = null;
|
Authentication auth = null;
|
||||||
|
if (authMap != null) {
|
||||||
|
auth = authMap.get("petstore_auth");
|
||||||
|
}
|
||||||
|
if (auth instanceof OAuth) {
|
||||||
|
authentications.put("petstore_auth", auth);
|
||||||
|
} else {
|
||||||
|
authentications.put("petstore_auth", new OAuth(basePath, ""));
|
||||||
|
}
|
||||||
if (authMap != null) {
|
if (authMap != null) {
|
||||||
auth = authMap.get("api_key");
|
auth = authMap.get("api_key");
|
||||||
}
|
}
|
||||||
@ -213,14 +221,6 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
} else {
|
} else {
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
}
|
}
|
||||||
if (authMap != null) {
|
|
||||||
auth = authMap.get("bearer_test");
|
|
||||||
}
|
|
||||||
if (auth instanceof HttpBearerAuth) {
|
|
||||||
authentications.put("bearer_test", auth);
|
|
||||||
} else {
|
|
||||||
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
|
||||||
}
|
|
||||||
if (authMap != null) {
|
if (authMap != null) {
|
||||||
auth = authMap.get("http_basic_test");
|
auth = authMap.get("http_basic_test");
|
||||||
}
|
}
|
||||||
@ -229,20 +229,20 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
} else {
|
} else {
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
}
|
}
|
||||||
|
if (authMap != null) {
|
||||||
|
auth = authMap.get("bearer_test");
|
||||||
|
}
|
||||||
|
if (auth instanceof HttpBearerAuth) {
|
||||||
|
authentications.put("bearer_test", auth);
|
||||||
|
} else {
|
||||||
|
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
||||||
|
}
|
||||||
if (authMap != null) {
|
if (authMap != null) {
|
||||||
auth = authMap.get("http_signature_test");
|
auth = authMap.get("http_signature_test");
|
||||||
}
|
}
|
||||||
if (auth instanceof HttpSignatureAuth) {
|
if (auth instanceof HttpSignatureAuth) {
|
||||||
authentications.put("http_signature_test", auth);
|
authentications.put("http_signature_test", auth);
|
||||||
}
|
}
|
||||||
if (authMap != null) {
|
|
||||||
auth = authMap.get("petstore_auth");
|
|
||||||
}
|
|
||||||
if (auth instanceof OAuth) {
|
|
||||||
authentications.put("petstore_auth", auth);
|
|
||||||
} else {
|
|
||||||
authentications.put("petstore_auth", new OAuth(basePath, ""));
|
|
||||||
}
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
|
||||||
|
@ -105,7 +105,7 @@ public class PetApi {
|
|||||||
};
|
};
|
||||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
|
|
||||||
return apiClient.invokeAPI("PetApi.addPet", localVarPath, "POST", localVarQueryParams, localVarPostBody,
|
return apiClient.invokeAPI("PetApi.addPet", localVarPath, "POST", localVarQueryParams, localVarPostBody,
|
||||||
localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType,
|
localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType,
|
||||||
@ -242,7 +242,7 @@ public class PetApi {
|
|||||||
};
|
};
|
||||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
|
|
||||||
GenericType<List<Pet>> localVarReturnType = new GenericType<List<Pet>>() {};
|
GenericType<List<Pet>> localVarReturnType = new GenericType<List<Pet>>() {};
|
||||||
|
|
||||||
@ -316,7 +316,7 @@ public class PetApi {
|
|||||||
};
|
};
|
||||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
|
|
||||||
GenericType<List<Pet>> localVarReturnType = new GenericType<List<Pet>>() {};
|
GenericType<List<Pet>> localVarReturnType = new GenericType<List<Pet>>() {};
|
||||||
|
|
||||||
@ -458,7 +458,7 @@ public class PetApi {
|
|||||||
};
|
};
|
||||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
|
|
||||||
return apiClient.invokeAPI("PetApi.updatePet", localVarPath, "PUT", localVarQueryParams, localVarPostBody,
|
return apiClient.invokeAPI("PetApi.updatePet", localVarPath, "PUT", localVarQueryParams, localVarPostBody,
|
||||||
localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType,
|
localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType,
|
||||||
|
@ -269,6 +269,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -283,12 +293,12 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
### bearer_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### http_basic_test
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
@ -298,16 +308,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -50,11 +50,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -84,7 +84,7 @@ CompletableFuture<void> (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -122,11 +122,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -165,7 +165,7 @@ CompletableFuture<ApiResponse<Void>>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -358,11 +358,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
||||||
try {
|
try {
|
||||||
@ -393,7 +393,7 @@ CompletableFuture<[**List<Pet>**](Pet.md)>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -432,11 +432,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
||||||
try {
|
try {
|
||||||
@ -476,7 +476,7 @@ CompletableFuture<ApiResponse<[**List<Pet>**](Pet.md)>>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -515,11 +515,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
||||||
try {
|
try {
|
||||||
@ -550,7 +550,7 @@ CompletableFuture<[**List<Pet>**](Pet.md)>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -589,11 +589,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
||||||
try {
|
try {
|
||||||
@ -633,7 +633,7 @@ CompletableFuture<ApiResponse<[**List<Pet>**](Pet.md)>>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -833,11 +833,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -867,7 +867,7 @@ CompletableFuture<void> (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -907,11 +907,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -950,7 +950,7 @@ CompletableFuture<ApiResponse<Void>>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -160,13 +160,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
@ -177,6 +170,13 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -268,6 +268,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -282,12 +292,12 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
### bearer_test
|
### http_basic_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### http_basic_test
|
### bearer_test
|
||||||
|
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
@ -297,16 +307,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -49,11 +49,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -83,7 +83,7 @@ null (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -120,11 +120,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -156,7 +156,7 @@ ApiResponse<Void>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -339,11 +339,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
||||||
try {
|
try {
|
||||||
@ -374,7 +374,7 @@ public class Example {
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -412,11 +412,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
||||||
try {
|
try {
|
||||||
@ -449,7 +449,7 @@ ApiResponse<[**List<Pet>**](Pet.md)>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -487,11 +487,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
||||||
try {
|
try {
|
||||||
@ -522,7 +522,7 @@ public class Example {
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -560,11 +560,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
||||||
try {
|
try {
|
||||||
@ -597,7 +597,7 @@ ApiResponse<[**List<Pet>**](Pet.md)>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -787,11 +787,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -821,7 +821,7 @@ null (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -860,11 +860,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -896,7 +896,7 @@ ApiResponse<Void>
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -155,12 +155,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -170,6 +164,12 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -105,8 +105,8 @@ public class ApiClient {
|
|||||||
initHttpClient();
|
initHttpClient();
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("AWS4Auth", new AWS4Auth());
|
authentications.put("AWS4Auth", new AWS4Auth());
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
@ -123,8 +123,8 @@ public class ApiClient {
|
|||||||
httpClient = client;
|
httpClient = client;
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("AWS4Auth", new AWS4Auth());
|
authentications.put("AWS4Auth", new AWS4Auth());
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
@ -207,6 +207,15 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
- **Type**: API key
|
- **Type**: API key
|
||||||
@ -223,15 +232,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -112,10 +112,10 @@ public class ApiClient {
|
|||||||
initHttpClient();
|
initHttpClient();
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
@ -131,10 +131,10 @@ public class ApiClient {
|
|||||||
httpClient = client;
|
httpClient = client;
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -142,12 +142,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -157,6 +151,12 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -104,8 +104,8 @@ public class ApiClient {
|
|||||||
initHttpClient();
|
initHttpClient();
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
@ -121,8 +121,8 @@ public class ApiClient {
|
|||||||
httpClient = client;
|
httpClient = client;
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -207,6 +207,15 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
- **Type**: API key
|
- **Type**: API key
|
||||||
@ -223,15 +232,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -104,10 +104,10 @@ public class ApiClient {
|
|||||||
initHttpClient();
|
initHttpClient();
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
@ -123,10 +123,10 @@ public class ApiClient {
|
|||||||
httpClient = client;
|
httpClient = client;
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -153,12 +153,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
- **Type**: OAuth
|
- **Type**: OAuth
|
||||||
@ -168,6 +162,12 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -104,8 +104,8 @@ public class ApiClient {
|
|||||||
initHttpClient();
|
initHttpClient();
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
@ -121,8 +121,8 @@ public class ApiClient {
|
|||||||
httpClient = client;
|
httpClient = client;
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -241,6 +241,15 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
- **Type**: API key
|
- **Type**: API key
|
||||||
@ -253,11 +262,11 @@ Authentication schemes defined for the API:
|
|||||||
- **API key parameter name**: api_key_query
|
- **API key parameter name**: api_key_query
|
||||||
- **Location**: URL query string
|
- **Location**: URL query string
|
||||||
|
|
||||||
### bearer_test
|
### http_basic_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### http_basic_test
|
### bearer_test
|
||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
@ -265,15 +274,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -38,11 +38,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -70,7 +70,7 @@ null (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -173,11 +173,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
|
||||||
try {
|
try {
|
||||||
@ -206,7 +206,7 @@ public class Example {
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -242,11 +242,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
|
||||||
try {
|
try {
|
||||||
@ -275,7 +275,7 @@ public class Example {
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@ -382,11 +382,11 @@ public class Example {
|
|||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
defaultClient.setBasePath("http://petstore.swagger.io:80/v2");
|
||||||
|
|
||||||
|
|
||||||
// Configure OAuth2 access token for authorization: petstore_auth
|
// Configure OAuth2 access token for authorization: petstore_auth
|
||||||
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
|
||||||
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
|
||||||
|
|
||||||
|
|
||||||
PetApi apiInstance = new PetApi(defaultClient);
|
PetApi apiInstance = new PetApi(defaultClient);
|
||||||
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store
|
||||||
try {
|
try {
|
||||||
@ -414,7 +414,7 @@ null (empty response body)
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[http_signature_test](../README.md#http_signature_test), [petstore_auth](../README.md#petstore_auth)
|
[petstore_auth](../README.md#petstore_auth), [http_signature_test](../README.md#http_signature_test)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
@ -147,12 +147,12 @@ public class ApiClient {
|
|||||||
initHttpClient();
|
initHttpClient();
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
|
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
||||||
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
@ -168,12 +168,12 @@ public class ApiClient {
|
|||||||
httpClient = client;
|
httpClient = client;
|
||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
|
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
||||||
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
@ -241,8 +241,8 @@ public class ApiClient {
|
|||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
|
authentications.put("bearer_test", new HttpBearerAuth("bearer"));
|
||||||
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
authentications.put("http_signature_test", new HttpBearerAuth("signature"));
|
||||||
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
|
@ -128,7 +128,7 @@ public class PetApi {
|
|||||||
localVarHeaderParams.put("Content-Type", localVarContentType);
|
localVarHeaderParams.put("Content-Type", localVarContentType);
|
||||||
}
|
}
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -378,7 +378,7 @@ public class PetApi {
|
|||||||
localVarHeaderParams.put("Content-Type", localVarContentType);
|
localVarHeaderParams.put("Content-Type", localVarContentType);
|
||||||
}
|
}
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -511,7 +511,7 @@ public class PetApi {
|
|||||||
localVarHeaderParams.put("Content-Type", localVarContentType);
|
localVarHeaderParams.put("Content-Type", localVarContentType);
|
||||||
}
|
}
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -778,7 +778,7 @@ public class PetApi {
|
|||||||
localVarHeaderParams.put("Content-Type", localVarContentType);
|
localVarHeaderParams.put("Content-Type", localVarContentType);
|
||||||
}
|
}
|
||||||
|
|
||||||
String[] localVarAuthNames = new String[] { "http_signature_test", "petstore_auth" };
|
String[] localVarAuthNames = new String[] { "petstore_auth", "http_signature_test" };
|
||||||
return localVarApiClient.buildCall(basePath, localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
return localVarApiClient.buildCall(basePath, localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -81,10 +81,10 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -152,13 +152,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
@ -169,6 +162,13 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -111,8 +111,8 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -152,13 +152,6 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
### api_key
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: API key
|
|
||||||
- **API key parameter name**: api_key
|
|
||||||
- **Location**: HTTP header
|
|
||||||
|
|
||||||
### petstore_auth
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
@ -169,6 +162,13 @@ Authentication schemes defined for the API:
|
|||||||
- write:pets: modify pets in your account
|
- write:pets: modify pets in your account
|
||||||
- read:pets: read your pets
|
- read:pets: read your pets
|
||||||
|
|
||||||
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: API key
|
||||||
|
- **API key parameter name**: api_key
|
||||||
|
- **Location**: HTTP header
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -111,8 +111,8 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
|
||||||
authentications.put("petstore_auth", new OAuth());
|
authentications.put("petstore_auth", new OAuth());
|
||||||
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -117,10 +117,10 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -112,10 +112,10 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<String, Authentication>();
|
authentications = new HashMap<String, Authentication>();
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -58,10 +58,10 @@ public class ApiClient {
|
|||||||
public ApiClient() {
|
public ApiClient() {
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
authentications = new HashMap<>();
|
authentications = new HashMap<>();
|
||||||
|
// authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
// authentications.put("http_basic_test", new HttpBasicAuth());
|
// authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
// authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
authentications = Collections.unmodifiableMap(authentications);
|
authentications = Collections.unmodifiableMap(authentications);
|
||||||
}
|
}
|
||||||
|
@ -53,7 +53,10 @@ public class ApiClient {
|
|||||||
this();
|
this();
|
||||||
for(String authName : authNames) {
|
for(String authName : authNames) {
|
||||||
Interceptor auth;
|
Interceptor auth;
|
||||||
if ("api_key".equals(authName)) {
|
if ("petstore_auth".equals(authName)) {
|
||||||
|
|
||||||
|
auth = new OAuth(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
||||||
|
} else if ("api_key".equals(authName)) {
|
||||||
|
|
||||||
auth = new ApiKeyAuth("header", "api_key");
|
auth = new ApiKeyAuth("header", "api_key");
|
||||||
} else if ("api_key_query".equals(authName)) {
|
} else if ("api_key_query".equals(authName)) {
|
||||||
@ -63,9 +66,6 @@ public class ApiClient {
|
|||||||
|
|
||||||
auth = new HttpBasicAuth();
|
auth = new HttpBasicAuth();
|
||||||
|
|
||||||
} else if ("petstore_auth".equals(authName)) {
|
|
||||||
|
|
||||||
auth = new OAuth(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
||||||
}
|
}
|
||||||
|
@ -54,7 +54,10 @@ public class ApiClient {
|
|||||||
this();
|
this();
|
||||||
for(String authName : authNames) {
|
for(String authName : authNames) {
|
||||||
Interceptor auth;
|
Interceptor auth;
|
||||||
if ("api_key".equals(authName)) {
|
if ("petstore_auth".equals(authName)) {
|
||||||
|
|
||||||
|
auth = new OAuth(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
||||||
|
} else if ("api_key".equals(authName)) {
|
||||||
|
|
||||||
auth = new ApiKeyAuth("header", "api_key");
|
auth = new ApiKeyAuth("header", "api_key");
|
||||||
} else if ("api_key_query".equals(authName)) {
|
} else if ("api_key_query".equals(authName)) {
|
||||||
@ -64,9 +67,6 @@ public class ApiClient {
|
|||||||
|
|
||||||
auth = new HttpBasicAuth();
|
auth = new HttpBasicAuth();
|
||||||
|
|
||||||
} else if ("petstore_auth".equals(authName)) {
|
|
||||||
|
|
||||||
auth = new OAuth(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
||||||
}
|
}
|
||||||
|
@ -54,7 +54,10 @@ public class ApiClient {
|
|||||||
this();
|
this();
|
||||||
for(String authName : authNames) {
|
for(String authName : authNames) {
|
||||||
Interceptor auth;
|
Interceptor auth;
|
||||||
if ("api_key".equals(authName)) {
|
if ("petstore_auth".equals(authName)) {
|
||||||
|
|
||||||
|
auth = new OAuth(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
||||||
|
} else if ("api_key".equals(authName)) {
|
||||||
|
|
||||||
auth = new ApiKeyAuth("header", "api_key");
|
auth = new ApiKeyAuth("header", "api_key");
|
||||||
} else if ("api_key_query".equals(authName)) {
|
} else if ("api_key_query".equals(authName)) {
|
||||||
@ -64,9 +67,6 @@ public class ApiClient {
|
|||||||
|
|
||||||
auth = new HttpBasicAuth();
|
auth = new HttpBasicAuth();
|
||||||
|
|
||||||
} else if ("petstore_auth".equals(authName)) {
|
|
||||||
|
|
||||||
auth = new OAuth(OAuthFlow.IMPLICIT, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
|
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
|
||||||
}
|
}
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
@ -82,10 +82,10 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
// Setup authentications (key: authentication name, value: authentication).
|
// Setup authentications (key: authentication name, value: authentication).
|
||||||
this.authentications = new HashMap<>();
|
this.authentications = new HashMap<>();
|
||||||
|
authentications.put("petstore_auth", new OAuth());
|
||||||
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
authentications.put("api_key", new ApiKeyAuth("header", "api_key"));
|
||||||
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
authentications.put("api_key_query", new ApiKeyAuth("query", "api_key_query"));
|
||||||
authentications.put("http_basic_test", new HttpBasicAuth());
|
authentications.put("http_basic_test", new HttpBasicAuth());
|
||||||
authentications.put("petstore_auth", new OAuth());
|
|
||||||
// Prevent the authentications from being modified.
|
// Prevent the authentications from being modified.
|
||||||
this.authentications = Collections.unmodifiableMap(authentications);
|
this.authentications = Collections.unmodifiableMap(authentications);
|
||||||
|
|
||||||
@ -667,6 +667,12 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
|
|
||||||
private final Map<String, Authentication> authentications = new LinkedHashMap<>();
|
private final Map<String, Authentication> authentications = new LinkedHashMap<>();
|
||||||
|
|
||||||
|
public void addPetstore_authAuthentication(String accessToken) {
|
||||||
|
OAuth auth = new OAuth();
|
||||||
|
auth.setAccessToken(accessToken);
|
||||||
|
authentications.put("petstore_auth", auth);
|
||||||
|
}
|
||||||
|
|
||||||
public void addApi_keyAuthentication(String apikey, String apiKeyPrefix) {
|
public void addApi_keyAuthentication(String apikey, String apiKeyPrefix) {
|
||||||
ApiKeyAuth auth = new ApiKeyAuth("header","api_key");
|
ApiKeyAuth auth = new ApiKeyAuth("header","api_key");
|
||||||
auth.setApiKey(apikey);
|
auth.setApiKey(apikey);
|
||||||
@ -688,10 +694,10 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
authentications.put("http_basic_test", auth);
|
authentications.put("http_basic_test", auth);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void addPetstore_authAuthentication(String accessToken) {
|
public static AuthInfo forPetstore_authAuthentication(String accessToken) {
|
||||||
OAuth auth = new OAuth();
|
AuthInfo authInfo = new AuthInfo();
|
||||||
auth.setAccessToken(accessToken);
|
authInfo.addPetstore_authAuthentication(accessToken);
|
||||||
authentications.put("petstore_auth", auth);
|
return authInfo;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static AuthInfo forApi_keyAuthentication(String apikey, String apiKeyPrefix) {
|
public static AuthInfo forApi_keyAuthentication(String apikey, String apiKeyPrefix) {
|
||||||
@ -711,11 +717,5 @@ public class ApiClient extends JavaTimeFormatter {
|
|||||||
authInfo.addHttp_basic_testAuthentication(username, password);
|
authInfo.addHttp_basic_testAuthentication(username, password);
|
||||||
return authInfo;
|
return authInfo;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static AuthInfo forPetstore_authAuthentication(String accessToken) {
|
|
||||||
AuthInfo authInfo = new AuthInfo();
|
|
||||||
authInfo.addPetstore_authAuthentication(accessToken);
|
|
||||||
return authInfo;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -207,6 +207,16 @@ Class | Method | HTTP request | Description
|
|||||||
## Documentation for Authorization
|
## Documentation for Authorization
|
||||||
|
|
||||||
Authentication schemes defined for the API:
|
Authentication schemes defined for the API:
|
||||||
|
### petstore_auth
|
||||||
|
|
||||||
|
|
||||||
|
- **Type**: OAuth
|
||||||
|
- **Flow**: implicit
|
||||||
|
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
||||||
|
- **Scopes**:
|
||||||
|
- write:pets: modify pets in your account
|
||||||
|
- read:pets: read your pets
|
||||||
|
|
||||||
### api_key
|
### api_key
|
||||||
|
|
||||||
|
|
||||||
@ -226,16 +236,6 @@ Authentication schemes defined for the API:
|
|||||||
|
|
||||||
- **Type**: HTTP basic authentication
|
- **Type**: HTTP basic authentication
|
||||||
|
|
||||||
### petstore_auth
|
|
||||||
|
|
||||||
|
|
||||||
- **Type**: OAuth
|
|
||||||
- **Flow**: implicit
|
|
||||||
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
|
|
||||||
- **Scopes**:
|
|
||||||
- write:pets: modify pets in your account
|
|
||||||
- read:pets: read your pets
|
|
||||||
|
|
||||||
|
|
||||||
## Recommendation
|
## Recommendation
|
||||||
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user