fixed nrt bug (#14973)

This commit is contained in:
devhl-labs
2023-03-15 20:59:12 -04:00
committed by GitHub
parent 5c4529259f
commit b6ccf078ef
32 changed files with 2721 additions and 1 deletions

View File

@@ -167,7 +167,7 @@ namespace {{packageName}}.{{apiPackage}}
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'{{/returnTypeIsPrimitive}}{{/nrt}}
throw new ApiException(apiResponseLocalVar.ReasonPhrase, apiResponseLocalVar.StatusCode, apiResponseLocalVar.RawContent);
return apiResponseLocalVar.Content{{#nrt}}{{#returnProperty}}{{#isPrimitiveType}}{{^isMap}}{{^isString}}.Value{{/isString}}{{/isMap}}{{/isPrimitiveType}}{{/returnProperty}}{{/nrt}};
return apiResponseLocalVar.Content{{#nrt}}{{#returnProperty}}{{#isPrimitiveType}}{{^isMap}}{{^isString}}{{^isContainer}}.Value{{/isContainer}}{{/isString}}{{/isMap}}{{/isPrimitiveType}}{{/returnProperty}}{{/nrt}};
}
{{#nrt}}

View File

@@ -17,6 +17,21 @@ tags:
- name: user
description: Operations about user
paths:
/hello:
get:
summary: Hello
description: Hello
operationId: Hello
responses:
'200':
description: UUIDs
content:
application/json:
schema:
type: array
items:
type: string
format: uuid
/foo:
get:
responses:

View File

@@ -106,6 +106,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -65,6 +65,27 @@ namespace Org.OpenAPITools.Api
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country, int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello(int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0);
#endregion Synchronous Operations
}
@@ -122,6 +143,29 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -510,5 +554,131 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello(int operationIndex = 0)
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0)
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
}
}

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)

View File

@@ -95,6 +95,38 @@ namespace Org.OpenAPITools.IApi
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;object?&gt;</returns>
Task<object?> GetCountryOrDefaultAsync(string country, System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task&lt;ApiResponse&lt;List&lt;Guid&gt;?&gt;&gt;</returns>
Task<ApiResponse<List<Guid>?>> HelloWithHttpInfoAsync(System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;List&lt;Guid&gt;&gt;</returns>
Task<List<Guid>> HelloAsync(System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;List&lt;Guid&gt;?&gt;</returns>
Task<List<Guid>?> HelloOrDefaultAsync(System.Threading.CancellationToken? cancellationToken = null);
}
}
@@ -454,5 +486,134 @@ namespace Org.OpenAPITools.Api
throw;
}
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="List&lt;Guid&gt;"/>&gt;</returns>
public async Task<List<Guid>> HelloAsync(System.Threading.CancellationToken? cancellationToken = null)
{
ApiResponse<List<Guid>?> apiResponseLocalVar = await HelloWithHttpInfoAsync(cancellationToken).ConfigureAwait(false);
if (apiResponseLocalVar.Content == null)
throw new ApiException(apiResponseLocalVar.ReasonPhrase, apiResponseLocalVar.StatusCode, apiResponseLocalVar.RawContent);
return apiResponseLocalVar.Content;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="List&lt;Guid&gt;"/>&gt;</returns>
public async Task<List<Guid>?> HelloOrDefaultAsync(System.Threading.CancellationToken? cancellationToken = null)
{
ApiResponse<List<Guid>?>? apiResponseLocalVar = null;
try
{
apiResponseLocalVar = await HelloWithHttpInfoAsync(cancellationToken).ConfigureAwait(false);
}
catch (Exception)
{
}
return apiResponseLocalVar != null && apiResponseLocalVar.IsSuccessStatusCode
? apiResponseLocalVar.Content
: null;
}
/// <summary>
/// Validates the request parameters
/// </summary>
/// <returns></returns>
protected virtual void OnHello()
{
return;
}
/// <summary>
/// Processes the server response
/// </summary>
/// <param name="apiResponseLocalVar"></param>
protected virtual void AfterHello(ApiResponse<List<Guid>?> apiResponseLocalVar)
{
}
/// <summary>
/// Processes the server response
/// </summary>
/// <param name="exception"></param>
/// <param name="pathFormat"></param>
/// <param name="path"></param>
protected virtual void OnErrorHello(Exception exception, string pathFormat, string path)
{
Logger.LogError(exception, "An error occurred while sending the request to the server.");
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="ApiResponse{T}"/>&gt; where T : <see cref="List&lt;Guid&gt;"/></returns>
public async Task<ApiResponse<List<Guid>?>> HelloWithHttpInfoAsync(System.Threading.CancellationToken? cancellationToken = null)
{
UriBuilder uriBuilderLocalVar = new UriBuilder();
try
{
OnHello();
using (HttpRequestMessage httpRequestMessageLocalVar = new HttpRequestMessage())
{
uriBuilderLocalVar.Host = HttpClient.BaseAddress!.Host;
uriBuilderLocalVar.Port = HttpClient.BaseAddress.Port;
uriBuilderLocalVar.Scheme = HttpClient.BaseAddress.Scheme;
uriBuilderLocalVar.Path = ClientUtils.CONTEXT_PATH + "/hello";
httpRequestMessageLocalVar.RequestUri = uriBuilderLocalVar.Uri;
string[] acceptLocalVars = new string[] {
"application/json"
};
string? acceptLocalVar = ClientUtils.SelectHeaderAccept(acceptLocalVars);
if (acceptLocalVar != null)
httpRequestMessageLocalVar.Headers.Accept.Add(new MediaTypeWithQualityHeaderValue(acceptLocalVar));
httpRequestMessageLocalVar.Method = HttpMethod.Get;
DateTime requestedAtLocalVar = DateTime.UtcNow;
using (HttpResponseMessage httpResponseMessageLocalVar = await HttpClient.SendAsync(httpRequestMessageLocalVar, cancellationToken.GetValueOrDefault()).ConfigureAwait(false))
{
OnApiResponded(new ApiResponseEventArgs(requestedAtLocalVar, DateTime.UtcNow, httpResponseMessageLocalVar.StatusCode, "/hello", uriBuilderLocalVar.Path));
string responseContentLocalVar = await httpResponseMessageLocalVar.Content.ReadAsStringAsync(cancellationToken.GetValueOrDefault()).ConfigureAwait(false);
ApiResponse<List<Guid>?> apiResponseLocalVar = new ApiResponse<List<Guid>?>(httpResponseMessageLocalVar, responseContentLocalVar);
if (apiResponseLocalVar.IsSuccessStatusCode)
{
apiResponseLocalVar.Content = JsonSerializer.Deserialize<List<Guid>>(apiResponseLocalVar.RawContent, _jsonSerializerOptions);
AfterHello(apiResponseLocalVar);
}
return apiResponseLocalVar;
}
}
}
catch(Exception e)
{
OnErrorHello(e, "/hello", uriBuilderLocalVar.Path);
throw;
}
}
}
}

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)

View File

@@ -72,6 +72,28 @@ namespace Org.OpenAPITools.IApi
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;object&gt;</returns>
Task<object> GetCountryAsync(string country, System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task&lt;ApiResponse&lt;List&lt;Guid&gt;&gt;&gt;</returns>
Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;List&lt;Guid&gt;&gt;</returns>
Task<List<Guid>> HelloAsync(System.Threading.CancellationToken? cancellationToken = null);
}
}
@@ -431,5 +453,114 @@ namespace Org.OpenAPITools.Api
throw;
}
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="List&lt;Guid&gt;"/>&gt;</returns>
public async Task<List<Guid>> HelloAsync(System.Threading.CancellationToken? cancellationToken = null)
{
ApiResponse<List<Guid>> apiResponseLocalVar = await HelloWithHttpInfoAsync(cancellationToken).ConfigureAwait(false);
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
if (apiResponseLocalVar.Content == null)
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
throw new ApiException(apiResponseLocalVar.ReasonPhrase, apiResponseLocalVar.StatusCode, apiResponseLocalVar.RawContent);
return apiResponseLocalVar.Content;
}
/// <summary>
/// Validates the request parameters
/// </summary>
/// <returns></returns>
protected virtual void OnHello()
{
return;
}
/// <summary>
/// Processes the server response
/// </summary>
/// <param name="apiResponseLocalVar"></param>
protected virtual void AfterHello(ApiResponse<List<Guid>> apiResponseLocalVar)
{
}
/// <summary>
/// Processes the server response
/// </summary>
/// <param name="exception"></param>
/// <param name="pathFormat"></param>
/// <param name="path"></param>
protected virtual void OnErrorHello(Exception exception, string pathFormat, string path)
{
Logger.LogError(exception, "An error occurred while sending the request to the server.");
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="ApiResponse{T}"/>&gt; where T : <see cref="List&lt;Guid&gt;"/></returns>
public async Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken? cancellationToken = null)
{
UriBuilder uriBuilderLocalVar = new UriBuilder();
try
{
OnHello();
using (HttpRequestMessage httpRequestMessageLocalVar = new HttpRequestMessage())
{
uriBuilderLocalVar.Host = HttpClient.BaseAddress.Host;
uriBuilderLocalVar.Port = HttpClient.BaseAddress.Port;
uriBuilderLocalVar.Scheme = HttpClient.BaseAddress.Scheme;
uriBuilderLocalVar.Path = ClientUtils.CONTEXT_PATH + "/hello";
httpRequestMessageLocalVar.RequestUri = uriBuilderLocalVar.Uri;
string[] acceptLocalVars = new string[] {
"application/json"
};
string acceptLocalVar = ClientUtils.SelectHeaderAccept(acceptLocalVars);
if (acceptLocalVar != null)
httpRequestMessageLocalVar.Headers.Accept.Add(new MediaTypeWithQualityHeaderValue(acceptLocalVar));
httpRequestMessageLocalVar.Method = HttpMethod.Get;
DateTime requestedAtLocalVar = DateTime.UtcNow;
using (HttpResponseMessage httpResponseMessageLocalVar = await HttpClient.SendAsync(httpRequestMessageLocalVar, cancellationToken.GetValueOrDefault()).ConfigureAwait(false))
{
OnApiResponded(new ApiResponseEventArgs(requestedAtLocalVar, DateTime.UtcNow, httpResponseMessageLocalVar.StatusCode, "/hello", uriBuilderLocalVar.Path));
string responseContentLocalVar = await httpResponseMessageLocalVar.Content.ReadAsStringAsync(cancellationToken.GetValueOrDefault()).ConfigureAwait(false);
ApiResponse<List<Guid>> apiResponseLocalVar = new ApiResponse<List<Guid>>(httpResponseMessageLocalVar, responseContentLocalVar);
if (apiResponseLocalVar.IsSuccessStatusCode)
{
apiResponseLocalVar.Content = JsonSerializer.Deserialize<List<Guid>>(apiResponseLocalVar.RawContent, _jsonSerializerOptions);
AfterHello(apiResponseLocalVar);
}
return apiResponseLocalVar;
}
}
}
catch(Exception e)
{
OnErrorHello(e, "/hello", uriBuilderLocalVar.Path);
throw;
}
}
}
}

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)

View File

@@ -72,6 +72,28 @@ namespace Org.OpenAPITools.IApi
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;object&gt;</returns>
Task<object> GetCountryAsync(string country, System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task&lt;ApiResponse&lt;List&lt;Guid&gt;&gt;&gt;</returns>
Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken? cancellationToken = null);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse&lt;List&lt;Guid&gt;&gt;</returns>
Task<List<Guid>> HelloAsync(System.Threading.CancellationToken? cancellationToken = null);
}
}
@@ -431,5 +453,114 @@ namespace Org.OpenAPITools.Api
throw;
}
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="List&lt;Guid&gt;"/>&gt;</returns>
public async Task<List<Guid>> HelloAsync(System.Threading.CancellationToken? cancellationToken = null)
{
ApiResponse<List<Guid>> apiResponseLocalVar = await HelloWithHttpInfoAsync(cancellationToken).ConfigureAwait(false);
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
if (apiResponseLocalVar.Content == null)
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
throw new ApiException(apiResponseLocalVar.ReasonPhrase, apiResponseLocalVar.StatusCode, apiResponseLocalVar.RawContent);
return apiResponseLocalVar.Content;
}
/// <summary>
/// Validates the request parameters
/// </summary>
/// <returns></returns>
protected virtual void OnHello()
{
return;
}
/// <summary>
/// Processes the server response
/// </summary>
/// <param name="apiResponseLocalVar"></param>
protected virtual void AfterHello(ApiResponse<List<Guid>> apiResponseLocalVar)
{
}
/// <summary>
/// Processes the server response
/// </summary>
/// <param name="exception"></param>
/// <param name="pathFormat"></param>
/// <param name="path"></param>
protected virtual void OnErrorHello(Exception exception, string pathFormat, string path)
{
Logger.LogError(exception, "An error occurred while sending the request to the server.");
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns><see cref="Task"/>&lt;<see cref="ApiResponse{T}"/>&gt; where T : <see cref="List&lt;Guid&gt;"/></returns>
public async Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken? cancellationToken = null)
{
UriBuilder uriBuilderLocalVar = new UriBuilder();
try
{
OnHello();
using (HttpRequestMessage httpRequestMessageLocalVar = new HttpRequestMessage())
{
uriBuilderLocalVar.Host = HttpClient.BaseAddress.Host;
uriBuilderLocalVar.Port = HttpClient.BaseAddress.Port;
uriBuilderLocalVar.Scheme = HttpClient.BaseAddress.Scheme;
uriBuilderLocalVar.Path = ClientUtils.CONTEXT_PATH + "/hello";
httpRequestMessageLocalVar.RequestUri = uriBuilderLocalVar.Uri;
string[] acceptLocalVars = new string[] {
"application/json"
};
string acceptLocalVar = ClientUtils.SelectHeaderAccept(acceptLocalVars);
if (acceptLocalVar != null)
httpRequestMessageLocalVar.Headers.Accept.Add(new MediaTypeWithQualityHeaderValue(acceptLocalVar));
httpRequestMessageLocalVar.Method = new HttpMethod("GET");
DateTime requestedAtLocalVar = DateTime.UtcNow;
using (HttpResponseMessage httpResponseMessageLocalVar = await HttpClient.SendAsync(httpRequestMessageLocalVar, cancellationToken.GetValueOrDefault()).ConfigureAwait(false))
{
OnApiResponded(new ApiResponseEventArgs(requestedAtLocalVar, DateTime.UtcNow, httpResponseMessageLocalVar.StatusCode, "/hello", uriBuilderLocalVar.Path));
string responseContentLocalVar = await httpResponseMessageLocalVar.Content.ReadAsStringAsync().ConfigureAwait(false);
ApiResponse<List<Guid>> apiResponseLocalVar = new ApiResponse<List<Guid>>(httpResponseMessageLocalVar, responseContentLocalVar);
if (apiResponseLocalVar.IsSuccessStatusCode)
{
apiResponseLocalVar.Content = JsonSerializer.Deserialize<List<Guid>>(apiResponseLocalVar.RawContent, _jsonSerializerOptions);
AfterHello(apiResponseLocalVar);
}
return apiResponseLocalVar;
}
}
}
catch(Exception e)
{
OnErrorHello(e, "/hello", uriBuilderLocalVar.Path);
throw;
}
}
}
}

View File

@@ -131,6 +131,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -180,3 +181,93 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using System.Net.Http;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
// create instances of HttpClient, HttpClientHandler to be reused later with different Api classes
HttpClient httpClient = new HttpClient();
HttpClientHandler httpClientHandler = new HttpClientHandler();
var apiInstance = new DefaultApi(httpClient, config, httpClientHandler);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -61,6 +61,25 @@ namespace Org.OpenAPITools.Api
/// <param name="country"></param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello();
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo();
#endregion Synchronous Operations
}
@@ -114,6 +133,27 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -541,5 +581,106 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello()
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo()
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null) localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null) localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null) throw _exception;
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null) localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null) localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null) throw _exception;
}
return localVarResponse;
}
}
}

View File

@@ -118,6 +118,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -65,6 +65,27 @@ namespace Org.OpenAPITools.Api
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country, int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello(int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0);
#endregion Synchronous Operations
}
@@ -122,6 +143,29 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -510,5 +554,131 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello(int operationIndex = 0)
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0)
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
}
}

View File

@@ -118,6 +118,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -65,6 +65,27 @@ namespace Org.OpenAPITools.Api
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country, int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello(int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0);
#endregion Synchronous Operations
}
@@ -122,6 +143,29 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -510,5 +554,131 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello(int operationIndex = 0)
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0)
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
}
}

View File

@@ -118,6 +118,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -65,6 +65,27 @@ namespace Org.OpenAPITools.Api
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country, int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello(int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0);
#endregion Synchronous Operations
}
@@ -122,6 +143,29 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -510,5 +554,131 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello(int operationIndex = 0)
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0)
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
}
}

View File

@@ -92,6 +92,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -60,6 +60,25 @@ namespace Org.OpenAPITools.Api
/// <param name="country"></param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello();
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo();
#endregion Synchronous Operations
}
@@ -113,6 +132,27 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -493,5 +533,117 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello()
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo()
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null) localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null) localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null) throw _exception;
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
var task = HelloWithHttpInfoAsync(cancellationToken);
#if UNITY_EDITOR || !UNITY_WEBGL
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await task.ConfigureAwait(false);
#else
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await task;
#endif
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null) localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null) localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
// make the HTTP request
var task = this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken);
#if UNITY_EDITOR || !UNITY_WEBGL
var localVarResponse = await task.ConfigureAwait(false);
#else
var localVarResponse = await task;
#endif
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null) throw _exception;
}
return localVarResponse;
}
}
}

View File

@@ -106,6 +106,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -65,6 +65,27 @@ namespace Org.OpenAPITools.Api
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country, int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello(int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0);
#endregion Synchronous Operations
}
@@ -122,6 +143,29 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -510,5 +554,131 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello(int operationIndex = 0)
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0)
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
}
}

View File

@@ -118,6 +118,7 @@ Class | Method | HTTP request | Description
*AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags
*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo |
*DefaultApi* | [**GetCountry**](docs/DefaultApi.md#getcountry) | **POST** /country |
*DefaultApi* | [**Hello**](docs/DefaultApi.md#hello) | **GET** /hello | Hello
*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint
*FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean |
*FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite |

View File

@@ -6,6 +6,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2*
|--------|--------------|-------------|
| [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | |
| [**GetCountry**](DefaultApi.md#getcountry) | **POST** /country | |
| [**Hello**](DefaultApi.md#hello) | **GET** /hello | Hello |
<a name="fooget"></a>
# **FooGet**
@@ -172,3 +173,89 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="hello"></a>
# **Hello**
> List&lt;Guid&gt; Hello ()
Hello
Hello
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class HelloExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io:80/v2";
var apiInstance = new DefaultApi(config);
try
{
// Hello
List<Guid> result = apiInstance.Hello();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.Hello: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
#### Using the HelloWithHttpInfo variant
This returns an ApiResponse object which contains the response data, status code and headers.
```csharp
try
{
// Hello
ApiResponse<List<Guid>> response = apiInstance.HelloWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling DefaultApi.HelloWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**List<Guid>**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | UUIDs | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@@ -65,6 +65,27 @@ namespace Org.OpenAPITools.Api
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> GetCountryWithHttpInfo(string country, int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
List<Guid> Hello(int operationIndex = 0);
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0);
#endregion Synchronous Operations
}
@@ -122,6 +143,29 @@ namespace Org.OpenAPITools.Api
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> GetCountryWithHttpInfoAsync(string country, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary>
/// Hello
/// </summary>
/// <remarks>
/// Hello
/// </remarks>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
#endregion Asynchronous Operations
}
@@ -510,5 +554,131 @@ namespace Org.OpenAPITools.Api
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;Guid&gt;</returns>
public List<Guid> Hello(int operationIndex = 0)
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = HelloWithHttpInfo();
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;Guid&gt;</returns>
public Org.OpenAPITools.Client.ApiResponse<List<Guid>> HelloWithHttpInfo(int operationIndex = 0)
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = this.Client.Get<List<Guid>>("/hello", localVarRequestOptions, this.Configuration);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;Guid&gt;</returns>
public async System.Threading.Tasks.Task<List<Guid>> HelloAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.ApiResponse<List<Guid>> localVarResponse = await HelloWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
/// <summary>
/// Hello Hello
/// </summary>
/// <exception cref="Org.OpenAPITools.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;Guid&gt;)</returns>
public async System.Threading.Tasks.Task<Org.OpenAPITools.Client.ApiResponse<List<Guid>>> HelloWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{
Org.OpenAPITools.Client.RequestOptions localVarRequestOptions = new Org.OpenAPITools.Client.RequestOptions();
string[] _contentTypes = new string[] {
};
// to determine the Accept header
string[] _accepts = new string[] {
"application/json"
};
var localVarContentType = Org.OpenAPITools.Client.ClientUtils.SelectHeaderContentType(_contentTypes);
if (localVarContentType != null)
{
localVarRequestOptions.HeaderParameters.Add("Content-Type", localVarContentType);
}
var localVarAccept = Org.OpenAPITools.Client.ClientUtils.SelectHeaderAccept(_accepts);
if (localVarAccept != null)
{
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
}
localVarRequestOptions.Operation = "DefaultApi.Hello";
localVarRequestOptions.OperationIndex = operationIndex;
// make the HTTP request
var localVarResponse = await this.AsynchronousClient.GetAsync<List<Guid>>("/hello", localVarRequestOptions, this.Configuration, cancellationToken).ConfigureAwait(false);
if (this.ExceptionFactory != null)
{
Exception _exception = this.ExceptionFactory("Hello", localVarResponse);
if (_exception != null)
{
throw _exception;
}
}
return localVarResponse;
}
}
}