diff --git a/README.md b/README.md
index 018db6c..2a2bb60 100644
--- a/README.md
+++ b/README.md
@@ -1,135 +1,138 @@
-# Org.OpenAPITools - the C# library for the Static OpenAPI document of Push API resource
+# databox
+
+Static OpenAPI document of Push API resource
+- API version: 0.3.15-sdk.5
+ - Build date: 2024-07-09T19:29:27.814676Z[Etc/UTC]
+ - Generator version: 7.6.0
Push API resources Open API documentation
-This C# SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
-- API version: 0.3.15-sdk.5
-- SDK version: 1.0.0
-- Generator version: 7.6.0
-- Build package: org.openapitools.codegen.languages.CSharpClientCodegen
+*Automatically generated by the [OpenAPI Generator](https://openapi-generator.tech)*
-
-## Frameworks supported
-
-## Dependencies
+## Requirements
-- [RestSharp](https://www.nuget.org/packages/RestSharp) - 106.13.0 or later
-- [Json.NET](https://www.nuget.org/packages/Newtonsoft.Json/) - 13.0.2 or later
-- [JsonSubTypes](https://www.nuget.org/packages/JsonSubTypes/) - 1.8.0 or later
-- [System.ComponentModel.Annotations](https://www.nuget.org/packages/System.ComponentModel.Annotations) - 5.0.0 or later
+Building the API client library requires:
+1. Java 1.8+
+2. Maven (3.8.3+)/Gradle (7.2+)
-The DLLs included in the package may not be the latest version. We recommend using [NuGet](https://docs.nuget.org/consume/installing-nuget) to obtain the latest version of the packages:
-```
-Install-Package RestSharp
-Install-Package Newtonsoft.Json
-Install-Package JsonSubTypes
-Install-Package System.ComponentModel.Annotations
+## Installation
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn clean install
```
-NOTE: RestSharp versions greater than 105.1.0 have a bug which causes file uploads to fail. See [RestSharp#742](https://github.com/restsharp/RestSharp/issues/742).
-NOTE: RestSharp for .Net Core creates a new socket for each api call, which can lead to a socket exhaustion problem. See [RestSharp#1406](https://github.com/restsharp/RestSharp/issues/1406).
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
-
-## Installation
-Run the following command to generate the DLL
-- [Mac/Linux] `/bin/sh build.sh`
-- [Windows] `build.bat`
-
-Then include the DLL (under the `bin` folder) in the C# project, and use the namespaces:
-```csharp
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
+```shell
+mvn clean deploy
```
-
-## Packaging
-A `.nuspec` is included with the project. You can follow the Nuget quickstart to [create](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#create-the-package) and [publish](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#publish-the-package) packages.
+Refer to the [OSSRH Guide](http://central.sonatype.org/pages/ossrh-guide.html) for more information.
+
+### Maven users
-This `.nuspec` uses placeholders from the `.csproj`, so build the `.csproj` directly:
+Add this dependency to your project's POM:
+```xml
+
+ org.databox
+ databox
+ 0.1.2
+ compile
+
```
-nuget pack -Build -OutputDirectory out Org.OpenAPITools.csproj
+
+### Gradle users
+
+Add this dependency to your project's build file:
+
+```groovy
+ repositories {
+ mavenCentral() // Needed if the 'databox' jar has been published to maven central.
+ mavenLocal() // Needed if the 'databox' jar has been published to the local maven repo.
+ }
+
+ dependencies {
+ implementation "org.databox:databox:0.1.2"
+ }
```
-Then, publish to a [local feed](https://docs.microsoft.com/en-us/nuget/hosting-packages/local-feeds) or [other host](https://docs.microsoft.com/en-us/nuget/hosting-packages/overview) and consume the new package via Nuget as usual.
+### Others
-
-## Usage
+At first generate the JAR by executing:
-To use the API client with a HTTP proxy, setup a `System.Net.WebProxy`
-```csharp
-Configuration c = new Configuration();
-System.Net.WebProxy webProxy = new System.Net.WebProxy("http://myProxyUrl:80/");
-webProxy.Credentials = System.Net.CredentialCache.DefaultCredentials;
-c.Proxy = webProxy;
+```shell
+mvn clean package
```
-
+Then manually install the following JARs:
+
+* `target/databox-0.1.2.jar`
+* `target/lib/*.jar`
+
## Getting Started
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class Example
- {
- public static void Main()
- {
-
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
-
- try
- {
- apiInstance.DataDelete();
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.DataDelete: " + e.Message );
- Debug.Print("Status Code: "+ e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
-
- }
+Please follow the [installation](#installation) instruction and execute the following Java code:
+
+```java
+
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ try {
+ apiInstance.dataDelete();
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#dataDelete");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
+ }
}
+
```
-
## Documentation for API Endpoints
All URIs are relative to *https://push.databox.com*
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
-*DefaultApi* | [**DataDelete**](docs/DefaultApi.md#datadelete) | **DELETE** /data |
-*DefaultApi* | [**DataMetricKeyDelete**](docs/DefaultApi.md#datametrickeydelete) | **DELETE** /data/{metricKey} |
-*DefaultApi* | [**DataPost**](docs/DefaultApi.md#datapost) | **POST** /data |
-*DefaultApi* | [**MetrickeysGet**](docs/DefaultApi.md#metrickeysget) | **GET** /metrickeys |
-*DefaultApi* | [**MetrickeysPost**](docs/DefaultApi.md#metrickeyspost) | **POST** /metrickeys |
-*DefaultApi* | [**PingGet**](docs/DefaultApi.md#pingget) | **GET** /ping |
+*DefaultApi* | [**dataDelete**](docs/DefaultApi.md#dataDelete) | **DELETE** /data |
+*DefaultApi* | [**dataMetricKeyDelete**](docs/DefaultApi.md#dataMetricKeyDelete) | **DELETE** /data/{metricKey} |
+*DefaultApi* | [**dataPost**](docs/DefaultApi.md#dataPost) | **POST** /data |
+*DefaultApi* | [**metrickeysGet**](docs/DefaultApi.md#metrickeysGet) | **GET** /metrickeys |
+*DefaultApi* | [**metrickeysPost**](docs/DefaultApi.md#metrickeysPost) | **POST** /metrickeys |
+*DefaultApi* | [**pingGet**](docs/DefaultApi.md#pingGet) | **GET** /ping |
-
## Documentation for Models
- - [Model.ApiResponse](docs/ApiResponse.md)
- - [Model.PushData](docs/PushData.md)
- - [Model.PushDataAttribute](docs/PushDataAttribute.md)
- - [Model.State](docs/State.md)
+ - [ModelApiResponse](docs/ModelApiResponse.md)
+ - [PushData](docs/PushData.md)
+ - [PushDataAttribute](docs/PushDataAttribute.md)
+ - [State](docs/State.md)
@@ -142,3 +145,12 @@ Authentication schemes defined for the API:
- **Type**: HTTP basic authentication
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issues.
+
+## Author
+
+
+
diff --git a/src/.github/workflows/maven.yml b/src/.github/workflows/maven.yml
new file mode 100644
index 0000000..2ea4610
--- /dev/null
+++ b/src/.github/workflows/maven.yml
@@ -0,0 +1,30 @@
+# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
+# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
+#
+# This file is auto-generated by OpenAPI Generator (https://openapi-generator.tech)
+
+name: Java CI with Maven
+
+on:
+ push:
+ branches: [ main, master ]
+ pull_request:
+ branches: [ main, master ]
+
+jobs:
+ build:
+ name: Build Static OpenAPI document of Push API resource
+ runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ java: [ 17, 21 ]
+ steps:
+ - uses: actions/checkout@v4
+ - name: Set up JDK
+ uses: actions/setup-java@v4
+ with:
+ java-version: ${{ matrix.java }}
+ distribution: 'temurin'
+ cache: maven
+ - name: Build with Maven
+ run: mvn -B package --no-transfer-progress --file pom.xml
diff --git a/src/.gitignore b/src/.gitignore
index 1ee5385..a530464 100644
--- a/src/.gitignore
+++ b/src/.gitignore
@@ -1,362 +1,21 @@
-## Ignore Visual Studio temporary files, build results, and
-## files generated by popular Visual Studio add-ons.
-##
-## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
+*.class
-# User-specific files
-*.rsuser
-*.suo
-*.user
-*.userosscache
-*.sln.docstates
+# Mobile Tools for Java (J2ME)
+.mtj.tmp/
-# User-specific files (MonoDevelop/Xamarin Studio)
-*.userprefs
+# Package Files #
+*.jar
+*.war
+*.ear
-# Mono auto generated files
-mono_crash.*
+# exclude jar for gradle wrapper
+!gradle/wrapper/*.jar
-# Build results
-[Dd]ebug/
-[Dd]ebugPublic/
-[Rr]elease/
-[Rr]eleases/
-x64/
-x86/
-[Ww][Ii][Nn]32/
-[Aa][Rr][Mm]/
-[Aa][Rr][Mm]64/
-bld/
-[Bb]in/
-[Oo]bj/
-[Ll]og/
-[Ll]ogs/
+# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
+hs_err_pid*
-# Visual Studio 2015/2017 cache/options directory
-.vs/
-# Uncomment if you have tasks that create the project's static files in wwwroot
-#wwwroot/
-
-# Visual Studio 2017 auto generated files
-Generated\ Files/
-
-# MSTest test Results
-[Tt]est[Rr]esult*/
-[Bb]uild[Ll]og.*
-
-# NUnit
-*.VisualState.xml
-TestResult.xml
-nunit-*.xml
-
-# Build Results of an ATL Project
-[Dd]ebugPS/
-[Rr]eleasePS/
-dlldata.c
-
-# Benchmark Results
-BenchmarkDotNet.Artifacts/
-
-# .NET Core
-project.lock.json
-project.fragment.lock.json
-artifacts/
-
-# ASP.NET Scaffolding
-ScaffoldingReadMe.txt
-
-# StyleCop
-StyleCopReport.xml
-
-# Files built by Visual Studio
-*_i.c
-*_p.c
-*_h.h
-*.ilk
-*.meta
-*.obj
-*.iobj
-*.pch
-*.pdb
-*.ipdb
-*.pgc
-*.pgd
-*.rsp
-*.sbr
-*.tlb
-*.tli
-*.tlh
-*.tmp
-*.tmp_proj
-*_wpftmp.csproj
-*.log
-*.vspscc
-*.vssscc
-.builds
-*.pidb
-*.svclog
-*.scc
-
-# Chutzpah Test files
-_Chutzpah*
-
-# Visual C++ cache files
-ipch/
-*.aps
-*.ncb
-*.opendb
-*.opensdf
-*.sdf
-*.cachefile
-*.VC.db
-*.VC.VC.opendb
-
-# Visual Studio profiler
-*.psess
-*.vsp
-*.vspx
-*.sap
-
-# Visual Studio Trace Files
-*.e2e
-
-# TFS 2012 Local Workspace
-$tf/
-
-# Guidance Automation Toolkit
-*.gpState
-
-# ReSharper is a .NET coding add-in
-_ReSharper*/
-*.[Rr]e[Ss]harper
-*.DotSettings.user
-
-# TeamCity is a build add-in
-_TeamCity*
-
-# DotCover is a Code Coverage Tool
-*.dotCover
-
-# AxoCover is a Code Coverage Tool
-.axoCover/*
-!.axoCover/settings.json
-
-# Coverlet is a free, cross platform Code Coverage Tool
-coverage*.json
-coverage*.xml
-coverage*.info
-
-# Visual Studio code coverage results
-*.coverage
-*.coveragexml
-
-# NCrunch
-_NCrunch_*
-.*crunch*.local.xml
-nCrunchTemp_*
-
-# MightyMoose
-*.mm.*
-AutoTest.Net/
-
-# Web workbench (sass)
-.sass-cache/
-
-# Installshield output folder
-[Ee]xpress/
-
-# DocProject is a documentation generator add-in
-DocProject/buildhelp/
-DocProject/Help/*.HxT
-DocProject/Help/*.HxC
-DocProject/Help/*.hhc
-DocProject/Help/*.hhk
-DocProject/Help/*.hhp
-DocProject/Help/Html2
-DocProject/Help/html
-
-# Click-Once directory
-publish/
-
-# Publish Web Output
-*.[Pp]ublish.xml
-*.azurePubxml
-# Note: Comment the next line if you want to checkin your web deploy settings,
-# but database connection strings (with potential passwords) will be unencrypted
-*.pubxml
-*.publishproj
-
-# Microsoft Azure Web App publish settings. Comment the next line if you want to
-# checkin your Azure Web App publish settings, but sensitive information contained
-# in these scripts will be unencrypted
-PublishScripts/
-
-# NuGet Packages
-*.nupkg
-# NuGet Symbol Packages
-*.snupkg
-# The packages folder can be ignored because of Package Restore
-**/[Pp]ackages/*
-# except build/, which is used as an MSBuild target.
-!**/[Pp]ackages/build/
-# Uncomment if necessary however generally it will be regenerated when needed
-#!**/[Pp]ackages/repositories.config
-# NuGet v3's project.json files produces more ignorable files
-*.nuget.props
-*.nuget.targets
-
-# Microsoft Azure Build Output
-csx/
-*.build.csdef
-
-# Microsoft Azure Emulator
-ecf/
-rcf/
-
-# Windows Store app package directories and files
-AppPackages/
-BundleArtifacts/
-Package.StoreAssociation.xml
-_pkginfo.txt
-*.appx
-*.appxbundle
-*.appxupload
-
-# Visual Studio cache files
-# files ending in .cache can be ignored
-*.[Cc]ache
-# but keep track of directories ending in .cache
-!?*.[Cc]ache/
-
-# Others
-ClientBin/
-~$*
-*~
-*.dbmdl
-*.dbproj.schemaview
-*.jfm
-*.pfx
-*.publishsettings
-orleans.codegen.cs
-
-# Including strong name files can present a security risk
-# (https://github.com/github/gitignore/pull/2483#issue-259490424)
-#*.snk
-
-# Since there are multiple workflows, uncomment next line to ignore bower_components
-# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
-#bower_components/
-
-# RIA/Silverlight projects
-Generated_Code/
-
-# Backup & report files from converting an old project file
-# to a newer Visual Studio version. Backup files are not needed,
-# because we have git ;-)
-_UpgradeReport_Files/
-Backup*/
-UpgradeLog*.XML
-UpgradeLog*.htm
-ServiceFabricBackup/
-*.rptproj.bak
-
-# SQL Server files
-*.mdf
-*.ldf
-*.ndf
-
-# Business Intelligence projects
-*.rdl.data
-*.bim.layout
-*.bim_*.settings
-*.rptproj.rsuser
-*- [Bb]ackup.rdl
-*- [Bb]ackup ([0-9]).rdl
-*- [Bb]ackup ([0-9][0-9]).rdl
-
-# Microsoft Fakes
-FakesAssemblies/
-
-# GhostDoc plugin setting file
-*.GhostDoc.xml
-
-# Node.js Tools for Visual Studio
-.ntvs_analysis.dat
-node_modules/
-
-# Visual Studio 6 build log
-*.plg
-
-# Visual Studio 6 workspace options file
-*.opt
-
-# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
-*.vbw
-
-# Visual Studio LightSwitch build output
-**/*.HTMLClient/GeneratedArtifacts
-**/*.DesktopClient/GeneratedArtifacts
-**/*.DesktopClient/ModelManifest.xml
-**/*.Server/GeneratedArtifacts
-**/*.Server/ModelManifest.xml
-_Pvt_Extensions
-
-# Paket dependency manager
-.paket/paket.exe
-paket-files/
-
-# FAKE - F# Make
-.fake/
-
-# CodeRush personal settings
-.cr/personal
-
-# Python Tools for Visual Studio (PTVS)
-__pycache__/
-*.pyc
-
-# Cake - Uncomment if you are using it
-# tools/**
-# !tools/packages.config
-
-# Tabs Studio
-*.tss
-
-# Telerik's JustMock configuration file
-*.jmconfig
-
-# BizTalk build output
-*.btp.cs
-*.btm.cs
-*.odx.cs
-*.xsd.cs
-
-# OpenCover UI analysis results
-OpenCover/
-
-# Azure Stream Analytics local run output
-ASALocalRun/
-
-# MSBuild Binary and Structured Log
-*.binlog
-
-# NVidia Nsight GPU debugger configuration file
-*.nvuser
-
-# MFractors (Xamarin productivity tool) working folder
-.mfractor/
-
-# Local History for Visual Studio
-.localhistory/
-
-# BeatPulse healthcheck temp database
-healthchecksdb
-
-# Backup folder for Package Reference Convert tool in Visual Studio 2017
-MigrationBackup/
-
-# Ionide (cross platform F# VS Code tools) working folder
-.ionide/
-
-# Fody - auto-generated XML schema
-FodyWeavers.xsd
+# build files
+**/target
+target
+.gradle
+build
diff --git a/src/.openapi-generator/FILES b/src/.openapi-generator/FILES
index 2793c31..f362689 100644
--- a/src/.openapi-generator/FILES
+++ b/src/.openapi-generator/FILES
@@ -1,40 +1,49 @@
+.github/workflows/maven.yml
.gitignore
-Org.OpenAPITools.sln
+.travis.yml
README.md
api/openapi.yaml
-appveyor.yml
-docs/ApiResponse.md
+build.gradle
+build.sbt
docs/DefaultApi.md
+docs/ModelApiResponse.md
docs/PushData.md
docs/PushDataAttribute.md
docs/State.md
git_push.sh
-src/Org.OpenAPITools.Test/Model/ApiResponseTests.cs
-src/Org.OpenAPITools.Test/Model/PushDataAttributeTests.cs
-src/Org.OpenAPITools.Test/Model/PushDataTests.cs
-src/Org.OpenAPITools.Test/Model/StateTests.cs
-src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj
-src/Org.OpenAPITools.Test/org.databox.api/DefaultApiTests.cs
-src/Org.OpenAPITools/Client/ApiClient.cs
-src/Org.OpenAPITools/Client/ApiException.cs
-src/Org.OpenAPITools/Client/ApiResponse.cs
-src/Org.OpenAPITools/Client/ClientUtils.cs
-src/Org.OpenAPITools/Client/Configuration.cs
-src/Org.OpenAPITools/Client/ExceptionFactory.cs
-src/Org.OpenAPITools/Client/GlobalConfiguration.cs
-src/Org.OpenAPITools/Client/HttpMethod.cs
-src/Org.OpenAPITools/Client/IApiAccessor.cs
-src/Org.OpenAPITools/Client/IAsynchronousClient.cs
-src/Org.OpenAPITools/Client/IReadableConfiguration.cs
-src/Org.OpenAPITools/Client/ISynchronousClient.cs
-src/Org.OpenAPITools/Client/Multimap.cs
-src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs
-src/Org.OpenAPITools/Client/RequestOptions.cs
-src/Org.OpenAPITools/Client/RetryConfiguration.cs
-src/Org.OpenAPITools/Model/AbstractOpenAPISchema.cs
-src/Org.OpenAPITools/Model/ApiResponse.cs
-src/Org.OpenAPITools/Model/PushData.cs
-src/Org.OpenAPITools/Model/PushDataAttribute.cs
-src/Org.OpenAPITools/Model/State.cs
-src/Org.OpenAPITools/Org.OpenAPITools.csproj
-src/Org.OpenAPITools/org.databox.api/DefaultApi.cs
+gradle.properties
+gradle/wrapper/gradle-wrapper.jar
+gradle/wrapper/gradle-wrapper.properties
+gradlew
+gradlew.bat
+pom.xml
+settings.gradle
+src/main/AndroidManifest.xml
+src/main/java/org/databox/ApiCallback.java
+src/main/java/org/databox/ApiClient.java
+src/main/java/org/databox/ApiException.java
+src/main/java/org/databox/ApiResponse.java
+src/main/java/org/databox/Configuration.java
+src/main/java/org/databox/GzipRequestInterceptor.java
+src/main/java/org/databox/JSON.java
+src/main/java/org/databox/Pair.java
+src/main/java/org/databox/ProgressRequestBody.java
+src/main/java/org/databox/ProgressResponseBody.java
+src/main/java/org/databox/ServerConfiguration.java
+src/main/java/org/databox/ServerVariable.java
+src/main/java/org/databox/StringUtil.java
+src/main/java/org/databox/api/DefaultApi.java
+src/main/java/org/databox/auth/ApiKeyAuth.java
+src/main/java/org/databox/auth/Authentication.java
+src/main/java/org/databox/auth/HttpBasicAuth.java
+src/main/java/org/databox/auth/HttpBearerAuth.java
+src/main/java/org/openapitools/client/model/AbstractOpenApiSchema.java
+src/main/java/org/openapitools/client/model/ModelApiResponse.java
+src/main/java/org/openapitools/client/model/PushData.java
+src/main/java/org/openapitools/client/model/PushDataAttribute.java
+src/main/java/org/openapitools/client/model/State.java
+src/test/java/org/databox/api/DefaultApiTest.java
+src/test/java/org/openapitools/client/model/ModelApiResponseTest.java
+src/test/java/org/openapitools/client/model/PushDataAttributeTest.java
+src/test/java/org/openapitools/client/model/PushDataTest.java
+src/test/java/org/openapitools/client/model/StateTest.java
diff --git a/src/.travis.yml b/src/.travis.yml
new file mode 100644
index 0000000..1b6741c
--- /dev/null
+++ b/src/.travis.yml
@@ -0,0 +1,22 @@
+#
+# Generated by OpenAPI Generator: https://openapi-generator.tech
+#
+# Ref: https://docs.travis-ci.com/user/languages/java/
+#
+language: java
+jdk:
+ - openjdk12
+ - openjdk11
+ - openjdk10
+ - openjdk9
+ - openjdk8
+before_install:
+ # ensure gradlew has proper permission
+ - chmod a+x ./gradlew
+script:
+ # test using maven
+ #- mvn test
+ # test using gradle
+ - gradle test
+ # test using sbt
+ # - sbt test
diff --git a/src/Org.OpenAPITools.sln b/src/Org.OpenAPITools.sln
deleted file mode 100644
index 09b9f30..0000000
--- a/src/Org.OpenAPITools.sln
+++ /dev/null
@@ -1,27 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 2012
-VisualStudioVersion = 12.0.0.0
-MinimumVisualStudioVersion = 10.0.0.1
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Org.OpenAPITools", "src\Org.OpenAPITools\Org.OpenAPITools.csproj", "{6F4FC320-3245-4F0A-844A-2A27CBD3DE4F}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Org.OpenAPITools.Test", "src\Org.OpenAPITools.Test\Org.OpenAPITools.Test.csproj", "{19F1DEBC-DE5E-4517-8062-F000CD499087}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|Any CPU = Debug|Any CPU
- Release|Any CPU = Release|Any CPU
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {6F4FC320-3245-4F0A-844A-2A27CBD3DE4F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {6F4FC320-3245-4F0A-844A-2A27CBD3DE4F}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {6F4FC320-3245-4F0A-844A-2A27CBD3DE4F}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {6F4FC320-3245-4F0A-844A-2A27CBD3DE4F}.Release|Any CPU.Build.0 = Release|Any CPU
- {19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {19F1DEBC-DE5E-4517-8062-F000CD499087}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {19F1DEBC-DE5E-4517-8062-F000CD499087}.Release|Any CPU.Build.0 = Release|Any CPU
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
-EndGlobal
\ No newline at end of file
diff --git a/src/README.md b/src/README.md
index 018db6c..2a2bb60 100644
--- a/src/README.md
+++ b/src/README.md
@@ -1,135 +1,138 @@
-# Org.OpenAPITools - the C# library for the Static OpenAPI document of Push API resource
+# databox
+
+Static OpenAPI document of Push API resource
+- API version: 0.3.15-sdk.5
+ - Build date: 2024-07-09T19:29:27.814676Z[Etc/UTC]
+ - Generator version: 7.6.0
Push API resources Open API documentation
-This C# SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
-- API version: 0.3.15-sdk.5
-- SDK version: 1.0.0
-- Generator version: 7.6.0
-- Build package: org.openapitools.codegen.languages.CSharpClientCodegen
+*Automatically generated by the [OpenAPI Generator](https://openapi-generator.tech)*
-
-## Frameworks supported
-
-## Dependencies
+## Requirements
-- [RestSharp](https://www.nuget.org/packages/RestSharp) - 106.13.0 or later
-- [Json.NET](https://www.nuget.org/packages/Newtonsoft.Json/) - 13.0.2 or later
-- [JsonSubTypes](https://www.nuget.org/packages/JsonSubTypes/) - 1.8.0 or later
-- [System.ComponentModel.Annotations](https://www.nuget.org/packages/System.ComponentModel.Annotations) - 5.0.0 or later
+Building the API client library requires:
+1. Java 1.8+
+2. Maven (3.8.3+)/Gradle (7.2+)
-The DLLs included in the package may not be the latest version. We recommend using [NuGet](https://docs.nuget.org/consume/installing-nuget) to obtain the latest version of the packages:
-```
-Install-Package RestSharp
-Install-Package Newtonsoft.Json
-Install-Package JsonSubTypes
-Install-Package System.ComponentModel.Annotations
+## Installation
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn clean install
```
-NOTE: RestSharp versions greater than 105.1.0 have a bug which causes file uploads to fail. See [RestSharp#742](https://github.com/restsharp/RestSharp/issues/742).
-NOTE: RestSharp for .Net Core creates a new socket for each api call, which can lead to a socket exhaustion problem. See [RestSharp#1406](https://github.com/restsharp/RestSharp/issues/1406).
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
-
-## Installation
-Run the following command to generate the DLL
-- [Mac/Linux] `/bin/sh build.sh`
-- [Windows] `build.bat`
-
-Then include the DLL (under the `bin` folder) in the C# project, and use the namespaces:
-```csharp
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
+```shell
+mvn clean deploy
```
-
-## Packaging
-A `.nuspec` is included with the project. You can follow the Nuget quickstart to [create](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#create-the-package) and [publish](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#publish-the-package) packages.
+Refer to the [OSSRH Guide](http://central.sonatype.org/pages/ossrh-guide.html) for more information.
+
+### Maven users
-This `.nuspec` uses placeholders from the `.csproj`, so build the `.csproj` directly:
+Add this dependency to your project's POM:
+```xml
+
+ org.databox
+ databox
+ 0.1.2
+ compile
+
```
-nuget pack -Build -OutputDirectory out Org.OpenAPITools.csproj
+
+### Gradle users
+
+Add this dependency to your project's build file:
+
+```groovy
+ repositories {
+ mavenCentral() // Needed if the 'databox' jar has been published to maven central.
+ mavenLocal() // Needed if the 'databox' jar has been published to the local maven repo.
+ }
+
+ dependencies {
+ implementation "org.databox:databox:0.1.2"
+ }
```
-Then, publish to a [local feed](https://docs.microsoft.com/en-us/nuget/hosting-packages/local-feeds) or [other host](https://docs.microsoft.com/en-us/nuget/hosting-packages/overview) and consume the new package via Nuget as usual.
+### Others
-
-## Usage
+At first generate the JAR by executing:
-To use the API client with a HTTP proxy, setup a `System.Net.WebProxy`
-```csharp
-Configuration c = new Configuration();
-System.Net.WebProxy webProxy = new System.Net.WebProxy("http://myProxyUrl:80/");
-webProxy.Credentials = System.Net.CredentialCache.DefaultCredentials;
-c.Proxy = webProxy;
+```shell
+mvn clean package
```
-
+Then manually install the following JARs:
+
+* `target/databox-0.1.2.jar`
+* `target/lib/*.jar`
+
## Getting Started
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class Example
- {
- public static void Main()
- {
-
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
-
- try
- {
- apiInstance.DataDelete();
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.DataDelete: " + e.Message );
- Debug.Print("Status Code: "+ e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
-
- }
+Please follow the [installation](#installation) instruction and execute the following Java code:
+
+```java
+
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ try {
+ apiInstance.dataDelete();
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#dataDelete");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
+ }
}
+
```
-
## Documentation for API Endpoints
All URIs are relative to *https://push.databox.com*
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
-*DefaultApi* | [**DataDelete**](docs/DefaultApi.md#datadelete) | **DELETE** /data |
-*DefaultApi* | [**DataMetricKeyDelete**](docs/DefaultApi.md#datametrickeydelete) | **DELETE** /data/{metricKey} |
-*DefaultApi* | [**DataPost**](docs/DefaultApi.md#datapost) | **POST** /data |
-*DefaultApi* | [**MetrickeysGet**](docs/DefaultApi.md#metrickeysget) | **GET** /metrickeys |
-*DefaultApi* | [**MetrickeysPost**](docs/DefaultApi.md#metrickeyspost) | **POST** /metrickeys |
-*DefaultApi* | [**PingGet**](docs/DefaultApi.md#pingget) | **GET** /ping |
+*DefaultApi* | [**dataDelete**](docs/DefaultApi.md#dataDelete) | **DELETE** /data |
+*DefaultApi* | [**dataMetricKeyDelete**](docs/DefaultApi.md#dataMetricKeyDelete) | **DELETE** /data/{metricKey} |
+*DefaultApi* | [**dataPost**](docs/DefaultApi.md#dataPost) | **POST** /data |
+*DefaultApi* | [**metrickeysGet**](docs/DefaultApi.md#metrickeysGet) | **GET** /metrickeys |
+*DefaultApi* | [**metrickeysPost**](docs/DefaultApi.md#metrickeysPost) | **POST** /metrickeys |
+*DefaultApi* | [**pingGet**](docs/DefaultApi.md#pingGet) | **GET** /ping |
-
## Documentation for Models
- - [Model.ApiResponse](docs/ApiResponse.md)
- - [Model.PushData](docs/PushData.md)
- - [Model.PushDataAttribute](docs/PushDataAttribute.md)
- - [Model.State](docs/State.md)
+ - [ModelApiResponse](docs/ModelApiResponse.md)
+ - [PushData](docs/PushData.md)
+ - [PushDataAttribute](docs/PushDataAttribute.md)
+ - [State](docs/State.md)
@@ -142,3 +145,12 @@ Authentication schemes defined for the API:
- **Type**: HTTP basic authentication
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issues.
+
+## Author
+
+
+
diff --git a/src/api/openapi.yaml b/src/api/openapi.yaml
index ddfe3fb..682b913 100644
--- a/src/api/openapi.yaml
+++ b/src/api/openapi.yaml
@@ -14,6 +14,8 @@ paths:
responses:
"200":
description: OK
+ x-accepts:
+ - application/json
post:
requestBody:
content:
@@ -30,6 +32,9 @@ paths:
responses:
"200":
description: OK
+ x-content-type: application/json
+ x-accepts:
+ - application/json
/data/{metricKey}:
delete:
parameters:
@@ -43,11 +48,15 @@ paths:
responses:
"200":
description: OK
+ x-accepts:
+ - application/json
/metrickeys:
get:
responses:
"200":
description: OK
+ x-accepts:
+ - application/json
post:
requestBody:
content:
@@ -60,11 +69,16 @@ paths:
responses:
"200":
description: OK
+ x-content-type: application/json
+ x-accepts:
+ - application/json
/ping:
get:
responses:
"200":
description: OK
+ x-accepts:
+ - application/json
components:
schemas:
ApiResponse:
diff --git a/src/appveyor.yml b/src/appveyor.yml
deleted file mode 100644
index f76f63c..0000000
--- a/src/appveyor.yml
+++ /dev/null
@@ -1,9 +0,0 @@
-# auto-generated by OpenAPI Generator (https://github.com/OpenAPITools/openapi-generator)
-#
-image: Visual Studio 2019
-clone_depth: 1
-build_script:
-- dotnet build -c Release
-- dotnet test -c Release
-after_build:
-- dotnet pack .\src\Org.OpenAPITools\Org.OpenAPITools.csproj -o ../../output -c Release --no-build
diff --git a/src/build.gradle b/src/build.gradle
new file mode 100644
index 0000000..8b814df
--- /dev/null
+++ b/src/build.gradle
@@ -0,0 +1,168 @@
+apply plugin: 'idea'
+apply plugin: 'eclipse'
+apply plugin: 'java'
+apply plugin: 'com.diffplug.spotless'
+
+group = 'org.databox'
+version = '0.1.2'
+
+buildscript {
+ repositories {
+ mavenCentral()
+ }
+ dependencies {
+ classpath 'com.android.tools.build:gradle:2.3.+'
+ classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
+ classpath 'com.diffplug.spotless:spotless-plugin-gradle:6.11.0'
+ }
+}
+
+repositories {
+ mavenCentral()
+}
+sourceSets {
+ main.java.srcDirs = ['src/main/java']
+}
+
+if(hasProperty('target') && target == 'android') {
+
+ apply plugin: 'com.android.library'
+ apply plugin: 'com.github.dcendents.android-maven'
+
+ android {
+ compileSdkVersion 25
+ buildToolsVersion '25.0.2'
+ defaultConfig {
+ minSdkVersion 14
+ targetSdkVersion 25
+ }
+ compileOptions {
+ sourceCompatibility JavaVersion.VERSION_1_8
+ targetCompatibility JavaVersion.VERSION_1_8
+ }
+
+ // Rename the aar correctly
+ libraryVariants.all { variant ->
+ variant.outputs.each { output ->
+ def outputFile = output.outputFile
+ if (outputFile != null && outputFile.name.endsWith('.aar')) {
+ def fileName = "${project.name}-${variant.baseName}-${version}.aar"
+ output.outputFile = new File(outputFile.parent, fileName)
+ }
+ }
+ }
+
+ dependencies {
+ provided "jakarta.annotation:jakarta.annotation-api:$jakarta_annotation_version"
+ }
+ }
+
+ afterEvaluate {
+ android.libraryVariants.all { variant ->
+ def task = project.tasks.create "jar${variant.name.capitalize()}", Jar
+ task.description = "Create jar artifact for ${variant.name}"
+ task.dependsOn variant.javaCompile
+ task.from variant.javaCompile.destinationDirectory
+ task.destinationDirectory = project.file("${project.buildDir}/outputs/jar")
+ task.archiveFileName = "${project.name}-${variant.baseName}-${version}.jar"
+ artifacts.add('archives', task)
+ }
+ }
+
+ task sourcesJar(type: Jar) {
+ from android.sourceSets.main.java.srcDirs
+ classifier = 'sources'
+ }
+
+ artifacts {
+ archives sourcesJar
+ }
+
+} else {
+
+ apply plugin: 'java'
+ apply plugin: 'maven-publish'
+
+ sourceCompatibility = JavaVersion.VERSION_1_8
+ targetCompatibility = JavaVersion.VERSION_1_8
+
+ publishing {
+ publications {
+ maven(MavenPublication) {
+ artifactId = 'databox'
+ from components.java
+ }
+ }
+ }
+
+ task execute(type:JavaExec) {
+ main = System.getProperty('mainClass')
+ classpath = sourceSets.main.runtimeClasspath
+ }
+}
+
+ext {
+ jakarta_annotation_version = "1.3.5"
+}
+
+dependencies {
+ implementation 'io.swagger:swagger-annotations:1.6.8'
+ implementation "com.google.code.findbugs:jsr305:3.0.2"
+ implementation 'com.squareup.okhttp3:okhttp:4.12.0'
+ implementation 'com.squareup.okhttp3:logging-interceptor:4.12.0'
+ implementation 'com.google.code.gson:gson:2.9.1'
+ implementation 'io.gsonfire:gson-fire:1.9.0'
+ implementation 'javax.ws.rs:jsr311-api:1.1.1'
+ implementation 'javax.ws.rs:javax.ws.rs-api:2.1.1'
+ implementation 'org.openapitools:jackson-databind-nullable:0.2.6'
+ implementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.12.0'
+ implementation "jakarta.annotation:jakarta.annotation-api:$jakarta_annotation_version"
+ testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.2'
+ testImplementation 'org.mockito:mockito-core:3.12.4'
+ testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.10.2'
+}
+
+javadoc {
+ options.tags = [ "http.response.details:a:Http Response Details" ]
+}
+
+// Use spotless plugin to automatically format code, remove unused import, etc
+// To apply changes directly to the file, run `gradlew spotlessApply`
+// Ref: https://github.com/diffplug/spotless/tree/main/plugin-gradle
+spotless {
+ // comment out below to run spotless as part of the `check` task
+ enforceCheck false
+
+ format 'misc', {
+ // define the files (e.g. '*.gradle', '*.md') to apply `misc` to
+ target '.gitignore'
+
+ // define the steps to apply to those files
+ trimTrailingWhitespace()
+ indentWithSpaces() // Takes an integer argument if you don't like 4
+ endWithNewline()
+ }
+ java {
+ // don't need to set target, it is inferred from java
+
+ // apply a specific flavor of google-java-format
+ googleJavaFormat('1.8').aosp().reflowLongStrings()
+
+ removeUnusedImports()
+ importOrder()
+ }
+}
+
+test {
+ // Enable JUnit 5 (Gradle 4.6+).
+ useJUnitPlatform()
+
+ // Always run tests, even when nothing changed.
+ dependsOn 'cleanTest'
+
+ // Show test results.
+ testLogging {
+ events "passed", "skipped", "failed"
+ }
+
+}
diff --git a/src/build.sbt b/src/build.sbt
new file mode 100644
index 0000000..fd6c76f
--- /dev/null
+++ b/src/build.sbt
@@ -0,0 +1,28 @@
+lazy val root = (project in file(".")).
+ settings(
+ organization := "org.databox",
+ name := "databox",
+ version := "0.1.2",
+ scalaVersion := "2.11.4",
+ scalacOptions ++= Seq("-feature"),
+ javacOptions in compile ++= Seq("-Xlint:deprecation"),
+ publishArtifact in (Compile, packageDoc) := false,
+ resolvers += Resolver.mavenLocal,
+ libraryDependencies ++= Seq(
+ "io.swagger" % "swagger-annotations" % "1.6.5",
+ "com.squareup.okhttp3" % "okhttp" % "4.12.0",
+ "com.squareup.okhttp3" % "logging-interceptor" % "4.12.0",
+ "com.google.code.gson" % "gson" % "2.9.1",
+ "org.apache.commons" % "commons-lang3" % "3.12.0",
+ "javax.ws.rs" % "jsr311-api" % "1.1.1",
+ "javax.ws.rs" % "javax.ws.rs-api" % "2.1.1",
+ "org.openapitools" % "jackson-databind-nullable" % "0.2.6",
+ "io.gsonfire" % "gson-fire" % "1.9.0" % "compile",
+ "jakarta.annotation" % "jakarta.annotation-api" % "1.3.5" % "compile",
+ "com.google.code.findbugs" % "jsr305" % "3.0.2" % "compile",
+ "jakarta.annotation" % "jakarta.annotation-api" % "1.3.5" % "compile",
+ "org.junit.jupiter" % "junit-jupiter-api" % "5.10.2" % "test",
+ "com.novocode" % "junit-interface" % "0.10" % "test",
+ "org.mockito" % "mockito-core" % "3.12.4" % "test"
+ )
+ )
diff --git a/src/docs/ApiResponse.md b/src/docs/ApiResponse.md
deleted file mode 100644
index 756b737..0000000
--- a/src/docs/ApiResponse.md
+++ /dev/null
@@ -1,11 +0,0 @@
-# Org.OpenAPITools.Model.ApiResponse
-
-## Properties
-
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**Status** | **string** | | [optional]
-**Message** | **string** | | [optional]
-
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
-
diff --git a/src/docs/DefaultApi.md b/src/docs/DefaultApi.md
index a5788b2..ecce651 100644
--- a/src/docs/DefaultApi.md
+++ b/src/docs/DefaultApi.md
@@ -1,80 +1,63 @@
-# Org.OpenAPITools.org.databox.api.DefaultApi
+# DefaultApi
All URIs are relative to *https://push.databox.com*
| Method | HTTP request | Description |
-|--------|--------------|-------------|
-| [**DataDelete**](DefaultApi.md#datadelete) | **DELETE** /data | |
-| [**DataMetricKeyDelete**](DefaultApi.md#datametrickeydelete) | **DELETE** /data/{metricKey} | |
-| [**DataPost**](DefaultApi.md#datapost) | **POST** /data | |
-| [**MetrickeysGet**](DefaultApi.md#metrickeysget) | **GET** /metrickeys | |
-| [**MetrickeysPost**](DefaultApi.md#metrickeyspost) | **POST** /metrickeys | |
-| [**PingGet**](DefaultApi.md#pingget) | **GET** /ping | |
+|------------- | ------------- | -------------|
+| [**dataDelete**](DefaultApi.md#dataDelete) | **DELETE** /data | |
+| [**dataMetricKeyDelete**](DefaultApi.md#dataMetricKeyDelete) | **DELETE** /data/{metricKey} | |
+| [**dataPost**](DefaultApi.md#dataPost) | **POST** /data | |
+| [**metrickeysGet**](DefaultApi.md#metrickeysGet) | **GET** /metrickeys | |
+| [**metrickeysPost**](DefaultApi.md#metrickeysPost) | **POST** /metrickeys | |
+| [**pingGet**](DefaultApi.md#pingGet) | **GET** /ping | |
-
-# **DataDelete**
-> void DataDelete ()
+
+
+# **dataDelete**
+> dataDelete()
### Example
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class DataDeleteExample
- {
- public static void Main()
- {
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
-
- try
- {
- apiInstance.DataDelete();
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.DataDelete: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
- }
+```java
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ try {
+ apiInstance.dataDelete();
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#dataDelete");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
-}
-```
-
-#### Using the DataDeleteWithHttpInfo variant
-This returns an ApiResponse object which contains the response data, status code and headers.
-
-```csharp
-try
-{
- apiInstance.DataDeleteWithHttpInfo();
-}
-catch (ApiException e)
-{
- Debug.Print("Exception when calling DefaultApi.DataDeleteWithHttpInfo: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
+ }
}
```
### Parameters
This endpoint does not need any parameter.
+
### Return type
-void (empty response body)
+null (empty response body)
### Authorization
@@ -85,83 +68,61 @@ void (empty response body)
- **Content-Type**: Not defined
- **Accept**: Not defined
-
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | OK | - |
-[[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)
-
-
-# **DataMetricKeyDelete**
-> void DataMetricKeyDelete (string metricKey)
+
+# **dataMetricKeyDelete**
+> dataMetricKeyDelete(metricKey)
### Example
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class DataMetricKeyDeleteExample
- {
- public static void Main()
- {
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
- var metricKey = "metricKey_example"; // string |
-
- try
- {
- apiInstance.DataMetricKeyDelete(metricKey);
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.DataMetricKeyDelete: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
- }
+```java
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ String metricKey = "metricKey_example"; // String |
+ try {
+ apiInstance.dataMetricKeyDelete(metricKey);
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#dataMetricKeyDelete");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
-}
-```
-
-#### Using the DataMetricKeyDeleteWithHttpInfo variant
-This returns an ApiResponse object which contains the response data, status code and headers.
-
-```csharp
-try
-{
- apiInstance.DataMetricKeyDeleteWithHttpInfo(metricKey);
-}
-catch (ApiException e)
-{
- Debug.Print("Exception when calling DefaultApi.DataMetricKeyDeleteWithHttpInfo: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
+ }
}
```
### Parameters
-| Name | Type | Description | Notes |
-|------|------|-------------|-------|
-| **metricKey** | **string** | | |
+| Name | Type | Description | Notes |
+|------------- | ------------- | ------------- | -------------|
+| **metricKey** | **String**| | |
### Return type
-void (empty response body)
+null (empty response body)
### Authorization
@@ -172,83 +133,61 @@ void (empty response body)
- **Content-Type**: Not defined
- **Accept**: Not defined
-
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | OK | - |
-[[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)
-
-
-# **DataPost**
-> void DataPost (List? pushData = null)
+
+# **dataPost**
+> dataPost(pushData)
### Example
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class DataPostExample
- {
- public static void Main()
- {
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
- var pushData = new List?(); // List? | (optional)
-
- try
- {
- apiInstance.DataPost(pushData);
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.DataPost: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
- }
+```java
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ List pushData = Arrays.asList(); // List |
+ try {
+ apiInstance.dataPost(pushData);
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#dataPost");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
-}
-```
-
-#### Using the DataPostWithHttpInfo variant
-This returns an ApiResponse object which contains the response data, status code and headers.
-
-```csharp
-try
-{
- apiInstance.DataPostWithHttpInfo(pushData);
-}
-catch (ApiException e)
-{
- Debug.Print("Exception when calling DefaultApi.DataPostWithHttpInfo: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
+ }
}
```
### Parameters
-| Name | Type | Description | Notes |
-|------|------|-------------|-------|
-| **pushData** | [**List<PushData>?**](PushData.md) | | [optional] |
+| Name | Type | Description | Notes |
+|------------- | ------------- | ------------- | -------------|
+| **pushData** | [**List<PushData>**](PushData.md)| | [optional] |
### Return type
-void (empty response body)
+null (empty response body)
### Authorization
@@ -259,78 +198,57 @@ void (empty response body)
- **Content-Type**: application/json, application/vnd.databox.v2+json
- **Accept**: Not defined
-
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | OK | - |
-[[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)
-
-
-# **MetrickeysGet**
-> void MetrickeysGet ()
+
+# **metrickeysGet**
+> metrickeysGet()
### Example
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class MetrickeysGetExample
- {
- public static void Main()
- {
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
-
- try
- {
- apiInstance.MetrickeysGet();
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.MetrickeysGet: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
- }
+```java
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ try {
+ apiInstance.metrickeysGet();
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#metrickeysGet");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
-}
-```
-
-#### Using the MetrickeysGetWithHttpInfo variant
-This returns an ApiResponse object which contains the response data, status code and headers.
-
-```csharp
-try
-{
- apiInstance.MetrickeysGetWithHttpInfo();
-}
-catch (ApiException e)
-{
- Debug.Print("Exception when calling DefaultApi.MetrickeysGetWithHttpInfo: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
+ }
}
```
### Parameters
This endpoint does not need any parameter.
+
### Return type
-void (empty response body)
+null (empty response body)
### Authorization
@@ -341,83 +259,61 @@ void (empty response body)
- **Content-Type**: Not defined
- **Accept**: Not defined
-
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | OK | - |
-[[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)
-
-
-# **MetrickeysPost**
-> void MetrickeysPost (Object? body = null)
+
+# **metrickeysPost**
+> metrickeysPost(body)
### Example
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class MetrickeysPostExample
- {
- public static void Main()
- {
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
- var body = null; // Object? | (optional)
-
- try
- {
- apiInstance.MetrickeysPost(body);
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.MetrickeysPost: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
- }
+```java
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ Object body = null; // Object |
+ try {
+ apiInstance.metrickeysPost(body);
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#metrickeysPost");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
-}
-```
-
-#### Using the MetrickeysPostWithHttpInfo variant
-This returns an ApiResponse object which contains the response data, status code and headers.
-
-```csharp
-try
-{
- apiInstance.MetrickeysPostWithHttpInfo(body);
-}
-catch (ApiException e)
-{
- Debug.Print("Exception when calling DefaultApi.MetrickeysPostWithHttpInfo: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
+ }
}
```
### Parameters
-| Name | Type | Description | Notes |
-|------|------|-------------|-------|
-| **body** | **Object?** | | [optional] |
+| Name | Type | Description | Notes |
+|------------- | ------------- | ------------- | -------------|
+| **body** | **Object**| | [optional] |
### Return type
-void (empty response body)
+null (empty response body)
### Authorization
@@ -428,78 +324,57 @@ void (empty response body)
- **Content-Type**: application/json, application/vnd.databox.v2+json
- **Accept**: Not defined
-
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | OK | - |
-[[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)
-
-
-# **PingGet**
-> void PingGet ()
+
+# **pingGet**
+> pingGet()
### Example
-```csharp
-using System.Collections.Generic;
-using System.Diagnostics;
-using Org.OpenAPITools.org.databox.api;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Example
-{
- public class PingGetExample
- {
- public static void Main()
- {
- Configuration config = new Configuration();
- config.BasePath = "https://push.databox.com";
- // Configure HTTP basic authorization: basicAuth
- config.Username = "YOUR_USERNAME";
- config.Password = "YOUR_PASSWORD";
-
- var apiInstance = new DefaultApi(config);
-
- try
- {
- apiInstance.PingGet();
- }
- catch (ApiException e)
- {
- Debug.Print("Exception when calling DefaultApi.PingGet: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
- }
- }
+```java
+// Import classes:
+import org.databox.ApiClient;
+import org.databox.ApiException;
+import org.databox.Configuration;
+import org.databox.auth.*;
+import org.databox.models.*;
+import org.databox.api.DefaultApi;
+
+public class Example {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+ defaultClient.setBasePath("https://push.databox.com");
+
+ // Configure HTTP basic authorization: basicAuth
+ HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
+ basicAuth.setUsername("YOUR USERNAME");
+ basicAuth.setPassword("YOUR PASSWORD");
+
+ DefaultApi apiInstance = new DefaultApi(defaultClient);
+ try {
+ apiInstance.pingGet();
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#pingGet");
+ System.err.println("Status code: " + e.getCode());
+ System.err.println("Reason: " + e.getResponseBody());
+ System.err.println("Response headers: " + e.getResponseHeaders());
+ e.printStackTrace();
}
-}
-```
-
-#### Using the PingGetWithHttpInfo variant
-This returns an ApiResponse object which contains the response data, status code and headers.
-
-```csharp
-try
-{
- apiInstance.PingGetWithHttpInfo();
-}
-catch (ApiException e)
-{
- Debug.Print("Exception when calling DefaultApi.PingGetWithHttpInfo: " + e.Message);
- Debug.Print("Status Code: " + e.ErrorCode);
- Debug.Print(e.StackTrace);
+ }
}
```
### Parameters
This endpoint does not need any parameter.
+
### Return type
-void (empty response body)
+null (empty response body)
### Authorization
@@ -510,11 +385,8 @@ void (empty response body)
- **Content-Type**: Not defined
- **Accept**: Not defined
-
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | OK | - |
-[[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)
-
diff --git a/src/docs/ModelApiResponse.md b/src/docs/ModelApiResponse.md
new file mode 100644
index 0000000..3f86aa8
--- /dev/null
+++ b/src/docs/ModelApiResponse.md
@@ -0,0 +1,14 @@
+
+
+# ModelApiResponse
+
+
+## Properties
+
+| Name | Type | Description | Notes |
+|------------ | ------------- | ------------- | -------------|
+|**status** | **String** | | [optional] |
+|**message** | **String** | | [optional] |
+
+
+
diff --git a/src/docs/PushData.md b/src/docs/PushData.md
index 422a67a..0e6b08e 100644
--- a/src/docs/PushData.md
+++ b/src/docs/PushData.md
@@ -1,16 +1,19 @@
-# Org.OpenAPITools.Model.PushData
+
+
+# PushData
+
## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**Attributes** | [**List<PushDataAttribute>**](PushDataAttribute.md) | | [optional]
-**Date** | **string** | | [optional]
-**Key** | **string** | | [optional]
-**PeriodFrom** | **string** | | [optional]
-**PeriodTo** | **string** | | [optional]
-**Unit** | **string** | | [optional]
-**Value** | **float** | | [optional]
-
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+| Name | Type | Description | Notes |
+|------------ | ------------- | ------------- | -------------|
+|**attributes** | [**List<PushDataAttribute>**](PushDataAttribute.md) | | [optional] |
+|**date** | **String** | | [optional] |
+|**key** | **String** | | [optional] |
+|**periodFrom** | **String** | | [optional] |
+|**periodTo** | **String** | | [optional] |
+|**unit** | **String** | | [optional] |
+|**value** | **Float** | | [optional] |
+
+
diff --git a/src/docs/PushDataAttribute.md b/src/docs/PushDataAttribute.md
index a213b1b..1bff482 100644
--- a/src/docs/PushDataAttribute.md
+++ b/src/docs/PushDataAttribute.md
@@ -1,11 +1,14 @@
-# Org.OpenAPITools.Model.PushDataAttribute
+
+
+# PushDataAttribute
+
## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**Key** | **string** | | [optional]
-**Value** | **string** | | [optional]
+| Name | Type | Description | Notes |
+|------------ | ------------- | ------------- | -------------|
+|**key** | **String** | | [optional] |
+|**value** | **String** | | [optional] |
+
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/src/docs/State.md b/src/docs/State.md
index b235ec5..a3dcbe2 100644
--- a/src/docs/State.md
+++ b/src/docs/State.md
@@ -1,9 +1,13 @@
-# Org.OpenAPITools.Model.State
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
+# State
+
+## Enum
+
+
+* `DOWN` (value: `"DOWN"`)
+
+* `UP` (value: `"UP"`)
+
-[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
diff --git a/src/gradle.properties b/src/gradle.properties
new file mode 100644
index 0000000..a340857
--- /dev/null
+++ b/src/gradle.properties
@@ -0,0 +1,6 @@
+# This file is automatically generated by OpenAPI Generator (https://github.com/openAPITools/openapi-generator).
+# To include other gradle properties as part of the code generation process, please use the `gradleProperties` option.
+#
+# Gradle properties reference: https://docs.gradle.org/current/userguide/build_environment.html#sec:gradle_configuration_properties
+# For example, uncomment below to build for Android
+#target = android
diff --git a/src/gradle/wrapper/gradle-wrapper.jar b/src/gradle/wrapper/gradle-wrapper.jar
new file mode 100644
index 0000000..e644113
Binary files /dev/null and b/src/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/src/gradle/wrapper/gradle-wrapper.properties b/src/gradle/wrapper/gradle-wrapper.properties
new file mode 100644
index 0000000..b82aa23
--- /dev/null
+++ b/src/gradle/wrapper/gradle-wrapper.properties
@@ -0,0 +1,7 @@
+distributionBase=GRADLE_USER_HOME
+distributionPath=wrapper/dists
+distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
+networkTimeout=10000
+validateDistributionUrl=true
+zipStoreBase=GRADLE_USER_HOME
+zipStorePath=wrapper/dists
diff --git a/src/gradlew b/src/gradlew
new file mode 100644
index 0000000..9d0ce63
--- /dev/null
+++ b/src/gradlew
@@ -0,0 +1,249 @@
+#!/bin/sh
+
+#
+# Copyright © 2015-2021 the original authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# https://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+##############################################################################
+#
+# Gradle start up script for POSIX generated by Gradle.
+#
+# Important for running:
+#
+# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
+# noncompliant, but you have some other compliant shell such as ksh or
+# bash, then to run this script, type that shell name before the whole
+# command line, like:
+#
+# ksh Gradle
+#
+# Busybox and similar reduced shells will NOT work, because this script
+# requires all of these POSIX shell features:
+# * functions;
+# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
+# «${var#prefix}», «${var%suffix}», and «$( cmd )»;
+# * compound commands having a testable exit status, especially «case»;
+# * various built-in commands including «command», «set», and «ulimit».
+#
+# Important for patching:
+#
+# (2) This script targets any POSIX shell, so it avoids extensions provided
+# by Bash, Ksh, etc; in particular arrays are avoided.
+#
+# The "traditional" practice of packing multiple parameters into a
+# space-separated string is a well documented source of bugs and security
+# problems, so this is (mostly) avoided, by progressively accumulating
+# options in "$@", and eventually passing that to Java.
+#
+# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
+# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
+# see the in-line comments for details.
+#
+# There are tweaks for specific operating systems such as AIX, CygWin,
+# Darwin, MinGW, and NonStop.
+#
+# (3) This script is generated from the Groovy template
+# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
+# within the Gradle project.
+#
+# You can find Gradle at https://github.com/gradle/gradle/.
+#
+##############################################################################
+
+# Attempt to set APP_HOME
+
+# Resolve links: $0 may be a link
+app_path=$0
+
+# Need this for daisy-chained symlinks.
+while
+APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
+[ -h "$app_path" ]
+do
+ls=$( ls -ld "$app_path" )
+link=${ls#*' -> '}
+case $link in #(
+/*) app_path=$link ;; #(
+*) app_path=$APP_HOME$link ;;
+esac
+done
+
+# This is normally unused
+# shellcheck disable=SC2034
+APP_BASE_NAME=${0##*/}
+# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
+APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
+
+# Use the maximum available, or set MAX_FD != -1 to use that value.
+MAX_FD=maximum
+
+warn () {
+echo "$*"
+} >&2
+
+die () {
+echo
+echo "$*"
+echo
+exit 1
+} >&2
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false
+msys=false
+darwin=false
+nonstop=false
+case "$( uname )" in #(
+CYGWIN* ) cygwin=true ;; #(
+Darwin* ) darwin=true ;; #(
+MSYS* | MINGW* ) msys=true ;; #(
+NONSTOP* ) nonstop=true ;;
+esac
+
+CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
+
+
+# Determine the Java command to use to start the JVM.
+if [ -n "$JAVA_HOME" ] ; then
+if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
+# IBM's JDK on AIX uses strange locations for the executables
+JAVACMD=$JAVA_HOME/jre/sh/java
+else
+JAVACMD=$JAVA_HOME/bin/java
+fi
+if [ ! -x "$JAVACMD" ] ; then
+die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+fi
+else
+JAVACMD=java
+if ! command -v java >/dev/null 2>&1
+then
+die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+fi
+fi
+
+# Increase the maximum file descriptors if we can.
+if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
+case $MAX_FD in #(
+max*)
+# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
+# shellcheck disable=SC2039,SC3045
+MAX_FD=$( ulimit -H -n ) ||
+warn "Could not query maximum file descriptor limit"
+esac
+case $MAX_FD in #(
+'' | soft) :;; #(
+*)
+# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
+# shellcheck disable=SC2039,SC3045
+ulimit -n "$MAX_FD" ||
+warn "Could not set maximum file descriptor limit to $MAX_FD"
+esac
+fi
+
+# Collect all arguments for the java command, stacking in reverse order:
+# * args from the command line
+# * the main class name
+# * -classpath
+# * -D...appname settings
+# * --module-path (only if needed)
+# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
+
+# For Cygwin or MSYS, switch paths to Windows format before running java
+if "$cygwin" || "$msys" ; then
+APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
+CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
+
+JAVACMD=$( cygpath --unix "$JAVACMD" )
+
+# Now convert the arguments - kludge to limit ourselves to /bin/sh
+for arg do
+if
+case $arg in #(
+-*) false ;; # don't mess with options #(
+/?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath
+[ -e "$t" ] ;; #(
+*) false ;;
+esac
+then
+arg=$( cygpath --path --ignore --mixed "$arg" )
+fi
+# Roll the args list around exactly as many times as the number of
+# args, so each arg winds up back in the position where it started, but
+# possibly modified.
+#
+# NB: a `for` loop captures its iteration list before it begins, so
+# changing the positional parameters here affects neither the number of
+# iterations, nor the values presented in `arg`.
+shift # remove old arg
+set -- "$@" "$arg" # push replacement arg
+done
+fi
+
+
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
+
+# Collect all arguments for the java command:
+# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
+# and any embedded shellness will be escaped.
+# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
+# treated as '${Hostname}' itself on the command line.
+
+set -- \
+"-Dorg.gradle.appname=$APP_BASE_NAME" \
+-classpath "$CLASSPATH" \
+org.gradle.wrapper.GradleWrapperMain \
+"$@"
+
+# Stop when "xargs" is not available.
+if ! command -v xargs >/dev/null 2>&1
+then
+die "xargs is not available"
+fi
+
+# Use "xargs" to parse quoted args.
+#
+# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
+#
+# In Bash we could simply go:
+#
+# readarray ARGS < <( xargs -n1 <<<"$var" ) &&
+# set -- "${ARGS[@]}" "$@"
+#
+# but POSIX shell has neither arrays nor command substitution, so instead we
+# post-process each arg (as a line of input to sed) to backslash-escape any
+# character that might be a shell metacharacter, then use eval to reverse
+# that process (while maintaining the separation between arguments), and wrap
+# the whole thing up as a single "set" statement.
+#
+# This will of course break if any of these variables contains a newline or
+# an unmatched quote.
+#
+
+eval "set -- $(
+printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
+xargs -n1 |
+sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
+tr '\n' ' '
+)" '"$@"'
+
+exec "$JAVACMD" "$@"
diff --git a/src/gradlew.bat b/src/gradlew.bat
new file mode 100644
index 0000000..25da30d
--- /dev/null
+++ b/src/gradlew.bat
@@ -0,0 +1,92 @@
+@rem
+@rem Copyright 2015 the original author or authors.
+@rem
+@rem Licensed under the Apache License, Version 2.0 (the "License");
+@rem you may not use this file except in compliance with the License.
+@rem You may obtain a copy of the License at
+@rem
+@rem https://www.apache.org/licenses/LICENSE-2.0
+@rem
+@rem Unless required by applicable law or agreed to in writing, software
+@rem distributed under the License is distributed on an "AS IS" BASIS,
+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+@rem See the License for the specific language governing permissions and
+@rem limitations under the License.
+@rem
+
+@if "%DEBUG%"=="" @echo off
+@rem ##########################################################################
+@rem
+@rem Gradle startup script for Windows
+@rem
+@rem ##########################################################################
+
+@rem Set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" setlocal
+
+set DIRNAME=%~dp0
+if "%DIRNAME%"=="" set DIRNAME=.
+@rem This is normally unused
+set APP_BASE_NAME=%~n0
+set APP_HOME=%DIRNAME%
+
+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
+
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
+
+@rem Find java.exe
+if defined JAVA_HOME goto findJavaFromJavaHome
+
+set JAVA_EXE=java.exe
+%JAVA_EXE% -version >NUL 2>&1
+if %ERRORLEVEL% equ 0 goto execute
+
+echo. 1>&2
+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
+echo. 1>&2
+echo Please set the JAVA_HOME variable in your environment to match the 1>&2
+echo location of your Java installation. 1>&2
+
+goto fail
+
+:findJavaFromJavaHome
+set JAVA_HOME=%JAVA_HOME:"=%
+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
+
+if exist "%JAVA_EXE%" goto execute
+
+echo. 1>&2
+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
+echo. 1>&2
+echo Please set the JAVA_HOME variable in your environment to match the 1>&2
+echo location of your Java installation. 1>&2
+
+goto fail
+
+:execute
+@rem Setup the command line
+
+set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
+
+@rem Execute Gradle
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
+
+:end
+@rem End local scope for the variables with windows NT shell
+if %ERRORLEVEL% equ 0 goto mainEnd
+
+:fail
+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
+rem the _cmd.exe /c_ return code!
+set EXIT_CODE=%ERRORLEVEL%
+if %EXIT_CODE% equ 0 set EXIT_CODE=1
+if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
+exit /b %EXIT_CODE%
+
+:mainEnd
+if "%OS%"=="Windows_NT" endlocal
+
+:omega
diff --git a/src/pom.xml b/src/pom.xml
new file mode 100644
index 0000000..70b3a3a
--- /dev/null
+++ b/src/pom.xml
@@ -0,0 +1,344 @@
+
+ 4.0.0
+ org.databox
+ databox
+ jar
+ databox
+ 0.1.2
+ https://github.com/databox/databox-java
+ SDK Client for using Databox Push API feature
+
+ scm:git:git@github.com:databox/databox-java.git
+ scm:git:git@github.com:databox/databox-java.git
+ https://github.com/databox/databox-java
+
+
+
+
+ Unlicense
+ http://unlicense.org
+ repo
+
+
+
+
+
+ Databox
+
+ Databox
+ https://databox.com/
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-compiler-plugin
+ 3.8.1
+
+ true
+ 128m
+ 512m
+
+ -Xlint:all
+ -J-Xss4m
+
+
+
+
+ org.apache.maven.plugins
+ maven-enforcer-plugin
+ 3.4.1
+
+
+ enforce-maven
+
+ enforce
+
+
+
+
+ 2.2.0
+
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-surefire-plugin
+ 2.22.2
+
+
+
+ loggerPath
+ conf/log4j.properties
+
+
+ -Xms512m -Xmx1500m
+ methods
+ 10
+
+
+
+
+ org.junit.jupiter
+ junit-jupiter-engine
+ ${junit-version}
+
+
+
+
+ maven-dependency-plugin
+ 3.6.1
+
+
+ package
+
+ copy-dependencies
+
+
+ ${project.build.directory}/lib
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-jar-plugin
+ 3.3.0
+
+
+
+ test-jar
+
+
+
+
+
+
+
+ org.codehaus.mojo
+ build-helper-maven-plugin
+ 3.5.0
+
+
+ add_sources
+ generate-sources
+
+ add-source
+
+
+
+ src/main/java
+
+
+
+
+ add_test_sources
+ generate-test-sources
+
+ add-test-source
+
+
+
+ src/test/java
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-javadoc-plugin
+ 3.6.3
+
+
+ attach-javadocs
+
+ jar
+
+
+
+
+ none
+
+
+ http.response.details
+ a
+ Http Response Details:
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-source-plugin
+ 3.3.0
+
+
+ attach-sources
+
+ jar-no-fork
+
+
+
+
+
+
+ com.diffplug.spotless
+ spotless-maven-plugin
+ ${spotless.version}
+
+
+
+
+
+
+ .gitignore
+
+
+
+
+
+ true
+ 4
+
+
+
+
+
+
+
+
+
+ 1.8
+
+ true
+
+
+
+
+
+
+
+
+
+
+
+
+
+ sign-artifacts
+
+
+
+ org.apache.maven.plugins
+ maven-gpg-plugin
+ 3.2.1
+
+
+ sign-artifacts
+ verify
+
+ sign
+
+
+
+
+
+
+
+
+
+
+
+
+ com.google.code.findbugs
+ jsr305
+ 3.0.2
+
+
+ com.squareup.okhttp3
+ okhttp
+ ${okhttp-version}
+
+
+ com.squareup.okhttp3
+ logging-interceptor
+ ${okhttp-version}
+
+
+ com.google.code.gson
+ gson
+ ${gson-version}
+
+
+ io.gsonfire
+ gson-fire
+ ${gson-fire-version}
+
+
+ org.apache.commons
+ commons-lang3
+ ${commons-lang3-version}
+
+
+ jakarta.annotation
+ jakarta.annotation-api
+ ${jakarta-annotation-version}
+ provided
+
+
+ org.openapitools
+ jackson-databind-nullable
+ ${jackson-databind-nullable-version}
+
+
+ javax.ws.rs
+ jsr311-api
+ ${jsr311-api-version}
+
+
+ javax.ws.rs
+ javax.ws.rs-api
+ ${javax.ws.rs-api-version}
+
+
+
+ org.junit.jupiter
+ junit-jupiter-engine
+ ${junit-version}
+ test
+
+
+ org.junit.platform
+ junit-platform-runner
+ ${junit-platform-runner.version}
+ test
+
+
+
+ 1.8
+ ${java.version}
+ ${java.version}
+ 1.9.0
+ 4.11.0
+ 2.10.1
+ 3.14.0
+ 0.2.6
+ 1.3.5
+ 5.10.2
+ 1.10.0
+ 2.1.1
+ 1.1.1
+ UTF-8
+ 2.43.0
+
+
diff --git a/src/settings.gradle b/src/settings.gradle
new file mode 100644
index 0000000..4e2bb90
--- /dev/null
+++ b/src/settings.gradle
@@ -0,0 +1 @@
+rootProject.name = "databox"
\ No newline at end of file
diff --git a/src/src/Org.OpenAPITools.Test/Model/ApiResponseTests.cs b/src/src/Org.OpenAPITools.Test/Model/ApiResponseTests.cs
deleted file mode 100644
index c0451b3..0000000
--- a/src/src/Org.OpenAPITools.Test/Model/ApiResponseTests.cs
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using Xunit;
-
-using System;
-using System.Linq;
-using System.IO;
-using System.Collections.Generic;
-using Org.OpenAPITools.Model;
-using Org.OpenAPITools.Client;
-using System.Reflection;
-using Newtonsoft.Json;
-
-namespace Org.OpenAPITools.Test.Model
-{
- ///
- /// Class for testing ApiResponse
- ///
- ///
- /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
- /// Please update the test case below to test the model.
- ///
- public class ApiResponseTests : IDisposable
- {
- // TODO uncomment below to declare an instance variable for ApiResponse
- //private ApiResponse instance;
-
- public ApiResponseTests()
- {
- // TODO uncomment below to create an instance of ApiResponse
- //instance = new ApiResponse();
- }
-
- public void Dispose()
- {
- // Cleanup when everything is done.
- }
-
- ///
- /// Test an instance of ApiResponse
- ///
- [Fact]
- public void ApiResponseInstanceTest()
- {
- // TODO uncomment below to test "IsType" ApiResponse
- //Assert.IsType(instance);
- }
-
- ///
- /// Test the property 'Status'
- ///
- [Fact]
- public void StatusTest()
- {
- // TODO unit test for the property 'Status'
- }
-
- ///
- /// Test the property 'Message'
- ///
- [Fact]
- public void MessageTest()
- {
- // TODO unit test for the property 'Message'
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools.Test/Model/PushDataAttributeTests.cs b/src/src/Org.OpenAPITools.Test/Model/PushDataAttributeTests.cs
deleted file mode 100644
index 2d9aa84..0000000
--- a/src/src/Org.OpenAPITools.Test/Model/PushDataAttributeTests.cs
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using Xunit;
-
-using System;
-using System.Linq;
-using System.IO;
-using System.Collections.Generic;
-using Org.OpenAPITools.Model;
-using Org.OpenAPITools.Client;
-using System.Reflection;
-using Newtonsoft.Json;
-
-namespace Org.OpenAPITools.Test.Model
-{
- ///
- /// Class for testing PushDataAttribute
- ///
- ///
- /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
- /// Please update the test case below to test the model.
- ///
- public class PushDataAttributeTests : IDisposable
- {
- // TODO uncomment below to declare an instance variable for PushDataAttribute
- //private PushDataAttribute instance;
-
- public PushDataAttributeTests()
- {
- // TODO uncomment below to create an instance of PushDataAttribute
- //instance = new PushDataAttribute();
- }
-
- public void Dispose()
- {
- // Cleanup when everything is done.
- }
-
- ///
- /// Test an instance of PushDataAttribute
- ///
- [Fact]
- public void PushDataAttributeInstanceTest()
- {
- // TODO uncomment below to test "IsType" PushDataAttribute
- //Assert.IsType(instance);
- }
-
- ///
- /// Test the property 'Key'
- ///
- [Fact]
- public void KeyTest()
- {
- // TODO unit test for the property 'Key'
- }
-
- ///
- /// Test the property 'Value'
- ///
- [Fact]
- public void ValueTest()
- {
- // TODO unit test for the property 'Value'
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools.Test/Model/PushDataTests.cs b/src/src/Org.OpenAPITools.Test/Model/PushDataTests.cs
deleted file mode 100644
index 827bb77..0000000
--- a/src/src/Org.OpenAPITools.Test/Model/PushDataTests.cs
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using Xunit;
-
-using System;
-using System.Linq;
-using System.IO;
-using System.Collections.Generic;
-using Org.OpenAPITools.Model;
-using Org.OpenAPITools.Client;
-using System.Reflection;
-using Newtonsoft.Json;
-
-namespace Org.OpenAPITools.Test.Model
-{
- ///
- /// Class for testing PushData
- ///
- ///
- /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
- /// Please update the test case below to test the model.
- ///
- public class PushDataTests : IDisposable
- {
- // TODO uncomment below to declare an instance variable for PushData
- //private PushData instance;
-
- public PushDataTests()
- {
- // TODO uncomment below to create an instance of PushData
- //instance = new PushData();
- }
-
- public void Dispose()
- {
- // Cleanup when everything is done.
- }
-
- ///
- /// Test an instance of PushData
- ///
- [Fact]
- public void PushDataInstanceTest()
- {
- // TODO uncomment below to test "IsType" PushData
- //Assert.IsType(instance);
- }
-
- ///
- /// Test the property 'Attributes'
- ///
- [Fact]
- public void AttributesTest()
- {
- // TODO unit test for the property 'Attributes'
- }
-
- ///
- /// Test the property 'Date'
- ///
- [Fact]
- public void DateTest()
- {
- // TODO unit test for the property 'Date'
- }
-
- ///
- /// Test the property 'Key'
- ///
- [Fact]
- public void KeyTest()
- {
- // TODO unit test for the property 'Key'
- }
-
- ///
- /// Test the property 'PeriodFrom'
- ///
- [Fact]
- public void PeriodFromTest()
- {
- // TODO unit test for the property 'PeriodFrom'
- }
-
- ///
- /// Test the property 'PeriodTo'
- ///
- [Fact]
- public void PeriodToTest()
- {
- // TODO unit test for the property 'PeriodTo'
- }
-
- ///
- /// Test the property 'Unit'
- ///
- [Fact]
- public void UnitTest()
- {
- // TODO unit test for the property 'Unit'
- }
-
- ///
- /// Test the property 'Value'
- ///
- [Fact]
- public void ValueTest()
- {
- // TODO unit test for the property 'Value'
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools.Test/Model/StateTests.cs b/src/src/Org.OpenAPITools.Test/Model/StateTests.cs
deleted file mode 100644
index 89ee372..0000000
--- a/src/src/Org.OpenAPITools.Test/Model/StateTests.cs
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using Xunit;
-
-using System;
-using System.Linq;
-using System.IO;
-using System.Collections.Generic;
-using Org.OpenAPITools.Model;
-using Org.OpenAPITools.Client;
-using System.Reflection;
-using Newtonsoft.Json;
-
-namespace Org.OpenAPITools.Test.Model
-{
- ///
- /// Class for testing State
- ///
- ///
- /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
- /// Please update the test case below to test the model.
- ///
- public class StateTests : IDisposable
- {
- // TODO uncomment below to declare an instance variable for State
- //private State instance;
-
- public StateTests()
- {
- // TODO uncomment below to create an instance of State
- //instance = new State();
- }
-
- public void Dispose()
- {
- // Cleanup when everything is done.
- }
-
- ///
- /// Test an instance of State
- ///
- [Fact]
- public void StateInstanceTest()
- {
- // TODO uncomment below to test "IsType" State
- //Assert.IsType(instance);
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj b/src/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj
deleted file mode 100644
index 9e82d9d..0000000
--- a/src/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
- Org.OpenAPITools.Test
- Org.OpenAPITools.Test
- net8.0
- false
- annotations
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/src/Org.OpenAPITools.Test/org.databox.api/DefaultApiTests.cs b/src/src/Org.OpenAPITools.Test/org.databox.api/DefaultApiTests.cs
deleted file mode 100644
index 1efd0a4..0000000
--- a/src/src/Org.OpenAPITools.Test/org.databox.api/DefaultApiTests.cs
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-using System;
-using System.IO;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.Reflection;
-using RestSharp;
-using Xunit;
-
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.org.databox.api;
-// uncomment below to import models
-//using Org.OpenAPITools.Model;
-
-namespace Org.OpenAPITools.Test.Api
-{
- ///
- /// Class for testing DefaultApi
- ///
- ///
- /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
- /// Please update the test case below to test the API endpoint.
- ///
- public class DefaultApiTests : IDisposable
- {
- private DefaultApi instance;
-
- public DefaultApiTests()
- {
- instance = new DefaultApi();
- }
-
- public void Dispose()
- {
- // Cleanup when everything is done.
- }
-
- ///
- /// Test an instance of DefaultApi
- ///
- [Fact]
- public void InstanceTest()
- {
- // TODO uncomment below to test 'IsType' DefaultApi
- //Assert.IsType(instance);
- }
-
- ///
- /// Test DataDelete
- ///
- [Fact]
- public void DataDeleteTest()
- {
- // TODO uncomment below to test the method and replace null with proper value
- //instance.DataDelete();
- }
-
- ///
- /// Test DataMetricKeyDelete
- ///
- [Fact]
- public void DataMetricKeyDeleteTest()
- {
- // TODO uncomment below to test the method and replace null with proper value
- //string metricKey = null;
- //instance.DataMetricKeyDelete(metricKey);
- }
-
- ///
- /// Test DataPost
- ///
- [Fact]
- public void DataPostTest()
- {
- // TODO uncomment below to test the method and replace null with proper value
- //List? pushData = null;
- //instance.DataPost(pushData);
- }
-
- ///
- /// Test MetrickeysGet
- ///
- [Fact]
- public void MetrickeysGetTest()
- {
- // TODO uncomment below to test the method and replace null with proper value
- //instance.MetrickeysGet();
- }
-
- ///
- /// Test MetrickeysPost
- ///
- [Fact]
- public void MetrickeysPostTest()
- {
- // TODO uncomment below to test the method and replace null with proper value
- //Object? body = null;
- //instance.MetrickeysPost(body);
- }
-
- ///
- /// Test PingGet
- ///
- [Fact]
- public void PingGetTest()
- {
- // TODO uncomment below to test the method and replace null with proper value
- //instance.PingGet();
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/ApiClient.cs b/src/src/Org.OpenAPITools/Client/ApiClient.cs
deleted file mode 100644
index bef2d29..0000000
--- a/src/src/Org.OpenAPITools/Client/ApiClient.cs
+++ /dev/null
@@ -1,833 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Globalization;
-using System.IO;
-using System.Linq;
-using System.Net;
-using System.Reflection;
-using System.Runtime.Serialization;
-using System.Runtime.Serialization.Formatters;
-using System.Text;
-using System.Threading;
-using System.Text.RegularExpressions;
-using System.Threading.Tasks;
-using System.Web;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Serialization;
-using RestSharp;
-using RestSharp.Serializers;
-using RestSharpMethod = RestSharp.Method;
-using Polly;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Allows RestSharp to Serialize/Deserialize JSON using our custom logic, but only when ContentType is JSON.
- ///
- internal class CustomJsonCodec : IRestSerializer, ISerializer, IDeserializer
- {
- private readonly IReadableConfiguration _configuration;
- private readonly JsonSerializerSettings _serializerSettings = new JsonSerializerSettings
- {
- // OpenAPI generated types generally hide default constructors.
- ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor,
- ContractResolver = new DefaultContractResolver
- {
- NamingStrategy = new CamelCaseNamingStrategy
- {
- OverrideSpecifiedNames = false
- }
- }
- };
-
- public CustomJsonCodec(IReadableConfiguration configuration)
- {
- _configuration = configuration;
- }
-
- public CustomJsonCodec(JsonSerializerSettings serializerSettings, IReadableConfiguration configuration)
- {
- _serializerSettings = serializerSettings;
- _configuration = configuration;
- }
-
- ///
- /// Serialize the object into a JSON string.
- ///
- /// Object to be serialized.
- /// A JSON string.
- public string Serialize(object obj)
- {
- if (obj != null && obj is Org.OpenAPITools.Model.AbstractOpenAPISchema)
- {
- // the object to be serialized is an oneOf/anyOf schema
- return ((Org.OpenAPITools.Model.AbstractOpenAPISchema)obj).ToJson();
- }
- else
- {
- return JsonConvert.SerializeObject(obj, _serializerSettings);
- }
- }
-
- public string Serialize(Parameter bodyParameter) => Serialize(bodyParameter.Value);
-
- public T Deserialize(RestResponse response)
- {
- var result = (T)Deserialize(response, typeof(T));
- return result;
- }
-
- ///
- /// Deserialize the JSON string into a proper object.
- ///
- /// The HTTP response.
- /// Object type.
- /// Object representation of the JSON string.
- internal object Deserialize(RestResponse response, Type type)
- {
- if (type == typeof(byte[])) // return byte array
- {
- return response.RawBytes;
- }
-
- // TODO: ? if (type.IsAssignableFrom(typeof(Stream)))
- if (type == typeof(Stream))
- {
- var bytes = response.RawBytes;
- if (response.Headers != null)
- {
- var filePath = string.IsNullOrEmpty(_configuration.TempFolderPath)
- ? Path.GetTempPath()
- : _configuration.TempFolderPath;
- var regex = new Regex(@"Content-Disposition=.*filename=['""]?([^'""\s]+)['""]?$");
- foreach (var header in response.Headers)
- {
- var match = regex.Match(header.ToString());
- if (match.Success)
- {
- string fileName = filePath + ClientUtils.SanitizeFilename(match.Groups[1].Value.Replace("\"", "").Replace("'", ""));
- File.WriteAllBytes(fileName, bytes);
- return new FileStream(fileName, FileMode.Open);
- }
- }
- }
- var stream = new MemoryStream(bytes);
- return stream;
- }
-
- if (type.Name.StartsWith("System.Nullable`1[[System.DateTime")) // return a datetime object
- {
- return DateTime.Parse(response.Content, null, System.Globalization.DateTimeStyles.RoundtripKind);
- }
-
- if (type == typeof(string) || type.Name.StartsWith("System.Nullable")) // return primitive type
- {
- return Convert.ChangeType(response.Content, type);
- }
-
- // at this point, it must be a model (json)
- try
- {
- return JsonConvert.DeserializeObject(response.Content, type, _serializerSettings);
- }
- catch (Exception e)
- {
- throw new ApiException(500, e.Message);
- }
- }
-
- public ISerializer Serializer => this;
- public IDeserializer Deserializer => this;
-
- public string[] AcceptedContentTypes => RestSharp.ContentType.JsonAccept;
-
- public SupportsContentType SupportsContentType => contentType =>
- contentType.Value.EndsWith("json", StringComparison.InvariantCultureIgnoreCase) ||
- contentType.Value.EndsWith("javascript", StringComparison.InvariantCultureIgnoreCase);
-
- public ContentType ContentType { get; set; } = RestSharp.ContentType.Json;
-
- public DataFormat DataFormat => DataFormat.Json;
- }
- ///
- /// Provides a default implementation of an Api client (both synchronous and asynchronous implementations),
- /// encapsulating general REST accessor use cases.
- ///
- public partial class ApiClient : ISynchronousClient, IAsynchronousClient
- {
- private readonly string _baseUrl;
-
- ///
- /// Specifies the settings on a object.
- /// These settings can be adjusted to accommodate custom serialization rules.
- ///
- public JsonSerializerSettings SerializerSettings { get; set; } = new JsonSerializerSettings
- {
- // OpenAPI generated types generally hide default constructors.
- ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor,
- ContractResolver = new DefaultContractResolver
- {
- NamingStrategy = new CamelCaseNamingStrategy
- {
- OverrideSpecifiedNames = false
- }
- }
- };
-
- ///
- /// Allows for extending request processing for generated code.
- ///
- /// The RestSharp request object
- partial void InterceptRequest(RestRequest request);
-
- ///
- /// Allows for extending response processing for generated code.
- ///
- /// The RestSharp request object
- /// The RestSharp response object
- partial void InterceptResponse(RestRequest request, RestResponse response);
-
- ///
- /// Initializes a new instance of the , defaulting to the global configurations' base url.
- ///
- public ApiClient()
- {
- _baseUrl = Org.OpenAPITools.Client.GlobalConfiguration.Instance.BasePath;
- }
-
- ///
- /// Initializes a new instance of the
- ///
- /// The target service's base path in URL format.
- ///
- public ApiClient(string basePath)
- {
- if (string.IsNullOrEmpty(basePath))
- throw new ArgumentException("basePath cannot be empty");
-
- _baseUrl = basePath;
- }
-
- ///
- /// Constructs the RestSharp version of an http method
- ///
- /// Swagger Client Custom HttpMethod
- /// RestSharp's HttpMethod instance.
- ///
- private RestSharpMethod Method(HttpMethod method)
- {
- RestSharpMethod other;
- switch (method)
- {
- case HttpMethod.Get:
- other = RestSharpMethod.Get;
- break;
- case HttpMethod.Post:
- other = RestSharpMethod.Post;
- break;
- case HttpMethod.Put:
- other = RestSharpMethod.Put;
- break;
- case HttpMethod.Delete:
- other = RestSharpMethod.Delete;
- break;
- case HttpMethod.Head:
- other = RestSharpMethod.Head;
- break;
- case HttpMethod.Options:
- other = RestSharpMethod.Options;
- break;
- case HttpMethod.Patch:
- other = RestSharpMethod.Patch;
- break;
- default:
- throw new ArgumentOutOfRangeException("method", method, null);
- }
-
- return other;
- }
-
- ///
- /// Provides all logic for constructing a new RestSharp .
- /// At this point, all information for querying the service is known. Here, it is simply
- /// mapped into the RestSharp request.
- ///
- /// The http verb.
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// [private] A new RestRequest instance.
- ///
- private RestRequest NewRequest(
- HttpMethod method,
- string path,
- RequestOptions options,
- IReadableConfiguration configuration)
- {
- if (path == null) throw new ArgumentNullException("path");
- if (options == null) throw new ArgumentNullException("options");
- if (configuration == null) throw new ArgumentNullException("configuration");
-
- RestRequest request = new RestRequest(path, Method(method));
-
- if (options.PathParameters != null)
- {
- foreach (var pathParam in options.PathParameters)
- {
- request.AddParameter(pathParam.Key, pathParam.Value, ParameterType.UrlSegment);
- }
- }
-
- if (options.QueryParameters != null)
- {
- foreach (var queryParam in options.QueryParameters)
- {
- foreach (var value in queryParam.Value)
- {
- request.AddQueryParameter(queryParam.Key, value);
- }
- }
- }
-
- if (configuration.DefaultHeaders != null)
- {
- foreach (var headerParam in configuration.DefaultHeaders)
- {
- request.AddHeader(headerParam.Key, headerParam.Value);
- }
- }
-
- if (options.HeaderParameters != null)
- {
- foreach (var headerParam in options.HeaderParameters)
- {
- foreach (var value in headerParam.Value)
- {
- request.AddHeader(headerParam.Key, value);
- }
- }
- }
-
- if (options.FormParameters != null)
- {
- foreach (var formParam in options.FormParameters)
- {
- request.AddParameter(formParam.Key, formParam.Value);
- }
- }
-
- if (options.Data != null)
- {
- if (options.Data is Stream stream)
- {
- var contentType = "application/octet-stream";
- if (options.HeaderParameters != null)
- {
- var contentTypes = options.HeaderParameters["Content-Type"];
- contentType = contentTypes[0];
- }
-
- var bytes = ClientUtils.ReadAsBytes(stream);
- request.AddParameter(contentType, bytes, ParameterType.RequestBody);
- }
- else
- {
- if (options.HeaderParameters != null)
- {
- var contentTypes = options.HeaderParameters["Content-Type"];
- if (contentTypes == null || contentTypes.Any(header => header.Contains("application/json")))
- {
- request.RequestFormat = DataFormat.Json;
- }
- else
- {
- // TODO: Generated client user should add additional handlers. RestSharp only supports XML and JSON, with XML as default.
- }
- }
- else
- {
- // Here, we'll assume JSON APIs are more common. XML can be forced by adding produces/consumes to openapi spec explicitly.
- request.RequestFormat = DataFormat.Json;
- }
-
- request.AddJsonBody(options.Data);
- }
- }
-
- if (options.FileParameters != null)
- {
- foreach (var fileParam in options.FileParameters)
- {
- foreach (var file in fileParam.Value)
- {
- var bytes = ClientUtils.ReadAsBytes(file);
- var fileStream = file as FileStream;
- if (fileStream != null)
- request.AddFile(fileParam.Key, bytes, System.IO.Path.GetFileName(fileStream.Name));
- else
- request.AddFile(fileParam.Key, bytes, "no_file_name_provided");
- }
- }
- }
-
- return request;
- }
-
- private ApiResponse ToApiResponse(RestResponse response)
- {
- T result = response.Data;
- string rawContent = response.Content;
-
- var transformed = new ApiResponse(response.StatusCode, new Multimap(), result, rawContent)
- {
- ErrorText = response.ErrorMessage,
- Cookies = new List()
- };
-
- if (response.Headers != null)
- {
- foreach (var responseHeader in response.Headers)
- {
- transformed.Headers.Add(responseHeader.Name, ClientUtils.ParameterToString(responseHeader.Value));
- }
- }
-
- if (response.ContentHeaders != null)
- {
- foreach (var responseHeader in response.ContentHeaders)
- {
- transformed.Headers.Add(responseHeader.Name, ClientUtils.ParameterToString(responseHeader.Value));
- }
- }
-
- if (response.Cookies != null)
- {
- foreach (var responseCookies in response.Cookies.Cast())
- {
- transformed.Cookies.Add(
- new Cookie(
- responseCookies.Name,
- responseCookies.Value,
- responseCookies.Path,
- responseCookies.Domain)
- );
- }
- }
-
- return transformed;
- }
-
- private ApiResponse Exec(RestRequest request, RequestOptions options, IReadableConfiguration configuration)
- {
- var baseUrl = configuration.GetOperationServerUrl(options.Operation, options.OperationIndex) ?? _baseUrl;
-
- var cookies = new CookieContainer();
-
- if (options.Cookies != null && options.Cookies.Count > 0)
- {
- foreach (var cookie in options.Cookies)
- {
- cookies.Add(new Cookie(cookie.Name, cookie.Value));
- }
- }
-
- var clientOptions = new RestClientOptions(baseUrl)
- {
- ClientCertificates = configuration.ClientCertificates,
- CookieContainer = cookies,
- MaxTimeout = configuration.Timeout,
- Proxy = configuration.Proxy,
- UserAgent = configuration.UserAgent,
- UseDefaultCredentials = configuration.UseDefaultCredentials,
- RemoteCertificateValidationCallback = configuration.RemoteCertificateValidationCallback
- };
-
- using (RestClient client = new RestClient(clientOptions,
- configureSerialization: serializerConfig => serializerConfig.UseSerializer(() => new CustomJsonCodec(SerializerSettings, configuration))))
- {
- InterceptRequest(request);
-
- RestResponse response;
- if (RetryConfiguration.RetryPolicy != null)
- {
- var policy = RetryConfiguration.RetryPolicy;
- var policyResult = policy.ExecuteAndCapture(() => client.Execute(request));
- response = (policyResult.Outcome == OutcomeType.Successful) ? client.Deserialize(policyResult.Result) : new RestResponse(request)
- {
- ErrorException = policyResult.FinalException
- };
- }
- else
- {
- response = client.Execute(request);
- }
-
- // if the response type is oneOf/anyOf, call FromJSON to deserialize the data
- if (typeof(Org.OpenAPITools.Model.AbstractOpenAPISchema).IsAssignableFrom(typeof(T)))
- {
- try
- {
- response.Data = (T) typeof(T).GetMethod("FromJson").Invoke(null, new object[] { response.Content });
- }
- catch (Exception ex)
- {
- throw ex.InnerException != null ? ex.InnerException : ex;
- }
- }
- else if (typeof(T).Name == "Stream") // for binary response
- {
- response.Data = (T)(object)new MemoryStream(response.RawBytes);
- }
- else if (typeof(T).Name == "Byte[]") // for byte response
- {
- response.Data = (T)(object)response.RawBytes;
- }
- else if (typeof(T).Name == "String") // for string response
- {
- response.Data = (T)(object)response.Content;
- }
-
- InterceptResponse(request, response);
-
- var result = ToApiResponse(response);
- if (response.ErrorMessage != null)
- {
- result.ErrorText = response.ErrorMessage;
- }
-
- if (response.Cookies != null && response.Cookies.Count > 0)
- {
- if (result.Cookies == null) result.Cookies = new List();
- foreach (var restResponseCookie in response.Cookies.Cast())
- {
- var cookie = new Cookie(
- restResponseCookie.Name,
- restResponseCookie.Value,
- restResponseCookie.Path,
- restResponseCookie.Domain
- )
- {
- Comment = restResponseCookie.Comment,
- CommentUri = restResponseCookie.CommentUri,
- Discard = restResponseCookie.Discard,
- Expired = restResponseCookie.Expired,
- Expires = restResponseCookie.Expires,
- HttpOnly = restResponseCookie.HttpOnly,
- Port = restResponseCookie.Port,
- Secure = restResponseCookie.Secure,
- Version = restResponseCookie.Version
- };
-
- result.Cookies.Add(cookie);
- }
- }
- return result;
- }
- }
-
- private async Task> ExecAsync(RestRequest request, RequestOptions options, IReadableConfiguration configuration, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var baseUrl = configuration.GetOperationServerUrl(options.Operation, options.OperationIndex) ?? _baseUrl;
-
- var clientOptions = new RestClientOptions(baseUrl)
- {
- ClientCertificates = configuration.ClientCertificates,
- MaxTimeout = configuration.Timeout,
- Proxy = configuration.Proxy,
- UserAgent = configuration.UserAgent,
- UseDefaultCredentials = configuration.UseDefaultCredentials,
- RemoteCertificateValidationCallback = configuration.RemoteCertificateValidationCallback
- };
-
- using (RestClient client = new RestClient(clientOptions,
- configureSerialization: serializerConfig => serializerConfig.UseSerializer(() => new CustomJsonCodec(SerializerSettings, configuration))))
- {
- InterceptRequest(request);
-
- RestResponse response;
- if (RetryConfiguration.AsyncRetryPolicy != null)
- {
- var policy = RetryConfiguration.AsyncRetryPolicy;
- var policyResult = await policy.ExecuteAndCaptureAsync((ct) => client.ExecuteAsync(request, ct), cancellationToken).ConfigureAwait(false);
- response = (policyResult.Outcome == OutcomeType.Successful) ? client.Deserialize(policyResult.Result) : new RestResponse(request)
- {
- ErrorException = policyResult.FinalException
- };
- }
- else
- {
- response = await client.ExecuteAsync(request, cancellationToken).ConfigureAwait(false);
- }
-
- // if the response type is oneOf/anyOf, call FromJSON to deserialize the data
- if (typeof(Org.OpenAPITools.Model.AbstractOpenAPISchema).IsAssignableFrom(typeof(T)))
- {
- response.Data = (T) typeof(T).GetMethod("FromJson").Invoke(null, new object[] { response.Content });
- }
- else if (typeof(T).Name == "Stream") // for binary response
- {
- response.Data = (T)(object)new MemoryStream(response.RawBytes);
- }
- else if (typeof(T).Name == "Byte[]") // for byte response
- {
- response.Data = (T)(object)response.RawBytes;
- }
-
- InterceptResponse(request, response);
-
- var result = ToApiResponse(response);
- if (response.ErrorMessage != null)
- {
- result.ErrorText = response.ErrorMessage;
- }
-
- if (response.Cookies != null && response.Cookies.Count > 0)
- {
- if (result.Cookies == null) result.Cookies = new List();
- foreach (var restResponseCookie in response.Cookies.Cast())
- {
- var cookie = new Cookie(
- restResponseCookie.Name,
- restResponseCookie.Value,
- restResponseCookie.Path,
- restResponseCookie.Domain
- )
- {
- Comment = restResponseCookie.Comment,
- CommentUri = restResponseCookie.CommentUri,
- Discard = restResponseCookie.Discard,
- Expired = restResponseCookie.Expired,
- Expires = restResponseCookie.Expires,
- HttpOnly = restResponseCookie.HttpOnly,
- Port = restResponseCookie.Port,
- Secure = restResponseCookie.Secure,
- Version = restResponseCookie.Version
- };
-
- result.Cookies.Add(cookie);
- }
- }
- return result;
- }
- }
-
- #region IAsynchronousClient
- ///
- /// Make a HTTP GET request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> GetAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Get, path, options, config), options, config, cancellationToken);
- }
-
- ///
- /// Make a HTTP POST request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> PostAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Post, path, options, config), options, config, cancellationToken);
- }
-
- ///
- /// Make a HTTP PUT request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> PutAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Put, path, options, config), options, config, cancellationToken);
- }
-
- ///
- /// Make a HTTP DELETE request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> DeleteAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Delete, path, options, config), options, config, cancellationToken);
- }
-
- ///
- /// Make a HTTP HEAD request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> HeadAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Head, path, options, config), options, config, cancellationToken);
- }
-
- ///
- /// Make a HTTP OPTION request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> OptionsAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Options, path, options, config), options, config, cancellationToken);
- }
-
- ///
- /// Make a HTTP PATCH request (async).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// Token that enables callers to cancel the request.
- /// A Task containing ApiResponse
- public Task> PatchAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return ExecAsync(NewRequest(HttpMethod.Patch, path, options, config), options, config, cancellationToken);
- }
- #endregion IAsynchronousClient
-
- #region ISynchronousClient
- ///
- /// Make a HTTP GET request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Get(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Get, path, options, config), options, config);
- }
-
- ///
- /// Make a HTTP POST request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Post(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Post, path, options, config), options, config);
- }
-
- ///
- /// Make a HTTP PUT request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Put(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Put, path, options, config), options, config);
- }
-
- ///
- /// Make a HTTP DELETE request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Delete(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Delete, path, options, config), options, config);
- }
-
- ///
- /// Make a HTTP HEAD request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Head(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Head, path, options, config), options, config);
- }
-
- ///
- /// Make a HTTP OPTION request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Options(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Options, path, options, config), options, config);
- }
-
- ///
- /// Make a HTTP PATCH request (synchronous).
- ///
- /// The target path (or resource).
- /// The additional request options.
- /// A per-request configuration object. It is assumed that any merge with
- /// GlobalConfiguration has been done before calling this method.
- /// A Task containing ApiResponse
- public ApiResponse Patch(string path, RequestOptions options, IReadableConfiguration configuration = null)
- {
- var config = configuration ?? GlobalConfiguration.Instance;
- return Exec(NewRequest(HttpMethod.Patch, path, options, config), options, config);
- }
- #endregion ISynchronousClient
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/ApiException.cs b/src/src/Org.OpenAPITools/Client/ApiException.cs
deleted file mode 100644
index 2e03490..0000000
--- a/src/src/Org.OpenAPITools/Client/ApiException.cs
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// API Exception
- ///
- public class ApiException : Exception
- {
- ///
- /// Gets or sets the error code (HTTP status code)
- ///
- /// The error code (HTTP status code).
- public int ErrorCode { get; set; }
-
- ///
- /// Gets or sets the error content (body json object)
- ///
- /// The error content (Http response body).
- public object ErrorContent { get; private set; }
-
- ///
- /// Gets or sets the HTTP headers
- ///
- /// HTTP headers
- public Multimap Headers { get; private set; }
-
- ///
- /// Initializes a new instance of the class.
- ///
- public ApiException() { }
-
- ///
- /// Initializes a new instance of the class.
- ///
- /// HTTP status code.
- /// Error message.
- public ApiException(int errorCode, string message) : base(message)
- {
- this.ErrorCode = errorCode;
- }
-
- ///
- /// Initializes a new instance of the class.
- ///
- /// HTTP status code.
- /// Error message.
- /// Error content.
- /// HTTP Headers.
- public ApiException(int errorCode, string message, object errorContent = null, Multimap headers = null) : base(message)
- {
- this.ErrorCode = errorCode;
- this.ErrorContent = errorContent;
- this.Headers = headers;
- }
- }
-
-}
diff --git a/src/src/Org.OpenAPITools/Client/ApiResponse.cs b/src/src/Org.OpenAPITools/Client/ApiResponse.cs
deleted file mode 100644
index b90c770..0000000
--- a/src/src/Org.OpenAPITools/Client/ApiResponse.cs
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections.Generic;
-using System.Net;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Provides a non-generic contract for the ApiResponse wrapper.
- ///
- public interface IApiResponse
- {
- ///
- /// The data type of
- ///
- Type ResponseType { get; }
-
- ///
- /// The content of this response
- ///
- Object Content { get; }
-
- ///
- /// Gets or sets the status code (HTTP status code)
- ///
- /// The status code.
- HttpStatusCode StatusCode { get; }
-
- ///
- /// Gets or sets the HTTP headers
- ///
- /// HTTP headers
- Multimap Headers { get; }
-
- ///
- /// Gets or sets any error text defined by the calling client.
- ///
- string ErrorText { get; set; }
-
- ///
- /// Gets or sets any cookies passed along on the response.
- ///
- List Cookies { get; set; }
-
- ///
- /// The raw content of this response
- ///
- string RawContent { get; }
- }
-
- ///
- /// API Response
- ///
- public class ApiResponse : IApiResponse
- {
- #region Properties
-
- ///
- /// Gets or sets the status code (HTTP status code)
- ///
- /// The status code.
- public HttpStatusCode StatusCode { get; }
-
- ///
- /// Gets or sets the HTTP headers
- ///
- /// HTTP headers
- public Multimap Headers { get; }
-
- ///
- /// Gets or sets the data (parsed HTTP body)
- ///
- /// The data.
- public T Data { get; }
-
- ///
- /// Gets or sets any error text defined by the calling client.
- ///
- public string ErrorText { get; set; }
-
- ///
- /// Gets or sets any cookies passed along on the response.
- ///
- public List Cookies { get; set; }
-
- ///
- /// The content of this response
- ///
- public Type ResponseType
- {
- get { return typeof(T); }
- }
-
- ///
- /// The data type of
- ///
- public object Content
- {
- get { return Data; }
- }
-
- ///
- /// The raw content
- ///
- public string RawContent { get; }
-
- #endregion Properties
-
- #region Constructors
-
- ///
- /// Initializes a new instance of the class.
- ///
- /// HTTP status code.
- /// HTTP headers.
- /// Data (parsed HTTP body)
- /// Raw content.
- public ApiResponse(HttpStatusCode statusCode, Multimap headers, T data, string rawContent)
- {
- StatusCode = statusCode;
- Headers = headers;
- Data = data;
- RawContent = rawContent;
- }
-
- ///
- /// Initializes a new instance of the class.
- ///
- /// HTTP status code.
- /// HTTP headers.
- /// Data (parsed HTTP body)
- public ApiResponse(HttpStatusCode statusCode, Multimap headers, T data) : this(statusCode, headers, data, null)
- {
- }
-
- ///
- /// Initializes a new instance of the class.
- ///
- /// HTTP status code.
- /// Data (parsed HTTP body)
- /// Raw content.
- public ApiResponse(HttpStatusCode statusCode, T data, string rawContent) : this(statusCode, null, data, rawContent)
- {
- }
-
- ///
- /// Initializes a new instance of the class.
- ///
- /// HTTP status code.
- /// Data (parsed HTTP body)
- public ApiResponse(HttpStatusCode statusCode, T data) : this(statusCode, data, null)
- {
- }
-
- #endregion Constructors
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/ClientUtils.cs b/src/src/Org.OpenAPITools/Client/ClientUtils.cs
deleted file mode 100644
index 2675455..0000000
--- a/src/src/Org.OpenAPITools/Client/ClientUtils.cs
+++ /dev/null
@@ -1,247 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Globalization;
-using System.IO;
-using System.Linq;
-using System.Runtime.Serialization;
-using System.Text;
-using System.Text.RegularExpressions;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Utility functions providing some benefit to API client consumers.
- ///
- public static class ClientUtils
- {
- ///
- /// Sanitize filename by removing the path
- ///
- /// Filename
- /// Filename
- public static string SanitizeFilename(string filename)
- {
- Match match = Regex.Match(filename, @".*[/\\](.*)$");
- return match.Success ? match.Groups[1].Value : filename;
- }
-
- ///
- /// Convert params to key/value pairs.
- /// Use collectionFormat to properly format lists and collections.
- ///
- /// The swagger-supported collection format, one of: csv, tsv, ssv, pipes, multi
- /// Key name.
- /// Value object.
- /// A multimap of keys with 1..n associated values.
- public static Multimap ParameterToMultiMap(string collectionFormat, string name, object value)
- {
- var parameters = new Multimap();
-
- if (value is ICollection collection && collectionFormat == "multi")
- {
- foreach (var item in collection)
- {
- parameters.Add(name, ParameterToString(item));
- }
- }
- else if (value is IDictionary dictionary)
- {
- if(collectionFormat == "deepObject") {
- foreach (DictionaryEntry entry in dictionary)
- {
- parameters.Add(name + "[" + entry.Key + "]", ParameterToString(entry.Value));
- }
- }
- else {
- foreach (DictionaryEntry entry in dictionary)
- {
- parameters.Add(entry.Key.ToString(), ParameterToString(entry.Value));
- }
- }
- }
- else
- {
- parameters.Add(name, ParameterToString(value));
- }
-
- return parameters;
- }
-
- ///
- /// If parameter is DateTime, output in a formatted string (default ISO 8601), customizable with Configuration.DateTime.
- /// If parameter is a list, join the list with ",".
- /// Otherwise just return the string.
- ///
- /// The parameter (header, path, query, form).
- /// An optional configuration instance, providing formatting options used in processing.
- /// Formatted string.
- public static string ParameterToString(object obj, IReadableConfiguration configuration = null)
- {
- if (obj is DateTime dateTime)
- // Return a formatted date string - Can be customized with Configuration.DateTimeFormat
- // Defaults to an ISO 8601, using the known as a Round-trip date/time pattern ("o")
- // https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx#Anchor_8
- // For example: 2009-06-15T13:45:30.0000000
- return dateTime.ToString((configuration ?? GlobalConfiguration.Instance).DateTimeFormat);
- if (obj is DateTimeOffset dateTimeOffset)
- // Return a formatted date string - Can be customized with Configuration.DateTimeFormat
- // Defaults to an ISO 8601, using the known as a Round-trip date/time pattern ("o")
- // https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx#Anchor_8
- // For example: 2009-06-15T13:45:30.0000000
- return dateTimeOffset.ToString((configuration ?? GlobalConfiguration.Instance).DateTimeFormat);
- if (obj is bool boolean)
- return boolean ? "true" : "false";
- if (obj is ICollection collection) {
- List entries = new List();
- foreach (var entry in collection)
- entries.Add(ParameterToString(entry, configuration));
- return string.Join(",", entries);
- }
- if (obj is Enum && HasEnumMemberAttrValue(obj))
- return GetEnumMemberAttrValue(obj);
-
- return Convert.ToString(obj, CultureInfo.InvariantCulture);
- }
-
- ///
- /// Serializes the given object when not null. Otherwise return null.
- ///
- /// The object to serialize.
- /// Serialized string.
- public static string Serialize(object obj)
- {
- return obj != null ? Newtonsoft.Json.JsonConvert.SerializeObject(obj) : null;
- }
-
- ///
- /// Encode string in base64 format.
- ///
- /// string to be encoded.
- /// Encoded string.
- public static string Base64Encode(string text)
- {
- return Convert.ToBase64String(System.Text.Encoding.UTF8.GetBytes(text));
- }
-
- ///
- /// Convert stream to byte array
- ///
- /// Input stream to be converted
- /// Byte array
- public static byte[] ReadAsBytes(Stream inputStream)
- {
- using (var ms = new MemoryStream())
- {
- inputStream.CopyTo(ms);
- return ms.ToArray();
- }
- }
-
- ///
- /// Select the Content-Type header's value from the given content-type array:
- /// if JSON type exists in the given array, use it;
- /// otherwise use the first one defined in 'consumes'
- ///
- /// The Content-Type array to select from.
- /// The Content-Type header to use.
- public static string SelectHeaderContentType(string[] contentTypes)
- {
- if (contentTypes.Length == 0)
- return null;
-
- foreach (var contentType in contentTypes)
- {
- if (IsJsonMime(contentType))
- return contentType;
- }
-
- return contentTypes[0]; // use the first content type specified in 'consumes'
- }
-
- ///
- /// Select the Accept header's value from the given accepts array:
- /// if JSON exists in the given array, use it;
- /// otherwise use all of them (joining into a string)
- ///
- /// The accepts array to select from.
- /// The Accept header to use.
- public static string SelectHeaderAccept(string[] accepts)
- {
- if (accepts.Length == 0)
- return null;
-
- if (accepts.Contains("application/json", StringComparer.OrdinalIgnoreCase))
- return "application/json";
-
- return string.Join(",", accepts);
- }
-
- ///
- /// Provides a case-insensitive check that a provided content type is a known JSON-like content type.
- ///
- public static readonly Regex JsonRegex = new Regex("(?i)^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$");
-
- ///
- /// Check if the given MIME is a JSON MIME.
- /// JSON MIME examples:
- /// application/json
- /// application/json; charset=UTF8
- /// APPLICATION/JSON
- /// application/vnd.company+json
- ///
- /// MIME
- /// Returns True if MIME type is json.
- public static bool IsJsonMime(string mime)
- {
- if (string.IsNullOrWhiteSpace(mime)) return false;
-
- return JsonRegex.IsMatch(mime) || mime.Equals("application/json-patch+json");
- }
-
- ///
- /// Is the Enum decorated with EnumMember Attribute
- ///
- ///
- /// true if found
- private static bool HasEnumMemberAttrValue(object enumVal)
- {
- if (enumVal == null)
- throw new ArgumentNullException(nameof(enumVal));
- var enumType = enumVal.GetType();
- var memInfo = enumType.GetMember(enumVal.ToString() ?? throw new InvalidOperationException());
- var attr = memInfo.FirstOrDefault()?.GetCustomAttributes(false).OfType().FirstOrDefault();
- if (attr != null) return true;
- return false;
- }
-
- ///
- /// Get the EnumMember value
- ///
- ///
- /// EnumMember value as string otherwise null
- private static string GetEnumMemberAttrValue(object enumVal)
- {
- if (enumVal == null)
- throw new ArgumentNullException(nameof(enumVal));
- var enumType = enumVal.GetType();
- var memInfo = enumType.GetMember(enumVal.ToString() ?? throw new InvalidOperationException());
- var attr = memInfo.FirstOrDefault()?.GetCustomAttributes(false).OfType().FirstOrDefault();
- if (attr != null)
- {
- return attr.Value;
- }
- return null;
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/Configuration.cs b/src/src/Org.OpenAPITools/Client/Configuration.cs
deleted file mode 100644
index 6ba0a70..0000000
--- a/src/src/Org.OpenAPITools/Client/Configuration.cs
+++ /dev/null
@@ -1,612 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections.Concurrent;
-using System.Collections.Generic;
-using System.IO;
-using System.Linq;
-using System.Net;
-using System.Reflection;
-using System.Security.Cryptography.X509Certificates;
-using System.Text;
-using System.Net.Http;
-using System.Net.Security;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Represents a set of configuration settings
- ///
- public class Configuration : IReadableConfiguration
- {
- #region Constants
-
- ///
- /// Version of the package.
- ///
- /// Version of the package.
- public const string Version = "1.0.0";
-
- ///
- /// Identifier for ISO 8601 DateTime Format
- ///
- /// See https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx#Anchor_8 for more information.
- // ReSharper disable once InconsistentNaming
- public const string ISO8601_DATETIME_FORMAT = "o";
-
- #endregion Constants
-
- #region Static Members
-
- ///
- /// Default creation of exceptions for a given method name and response object
- ///
- public static readonly ExceptionFactory DefaultExceptionFactory = (methodName, response) =>
- {
- var status = (int)response.StatusCode;
- if (status >= 400)
- {
- return new ApiException(status,
- string.Format("Error calling {0}: {1}", methodName, response.RawContent),
- response.RawContent, response.Headers);
- }
- if (status == 0)
- {
- return new ApiException(status,
- string.Format("Error calling {0}: {1}", methodName, response.ErrorText), response.ErrorText);
- }
- return null;
- };
-
- #endregion Static Members
-
- #region Private Members
-
- ///
- /// Defines the base path of the target API server.
- /// Example: http://localhost:3000/v1/
- ///
- private string _basePath;
-
- private bool _useDefaultCredentials = false;
-
- ///
- /// Gets or sets the API key based on the authentication name.
- /// This is the key and value comprising the "secret" for accessing an API.
- ///
- /// The API key.
- private IDictionary _apiKey;
-
- ///
- /// Gets or sets the prefix (e.g. Token) of the API key based on the authentication name.
- ///
- /// The prefix of the API key.
- private IDictionary _apiKeyPrefix;
-
- private string _dateTimeFormat = ISO8601_DATETIME_FORMAT;
- private string _tempFolderPath = Path.GetTempPath();
-
- ///
- /// Gets or sets the servers defined in the OpenAPI spec.
- ///
- /// The servers
- private IList> _servers;
-
- ///
- /// Gets or sets the operation servers defined in the OpenAPI spec.
- ///
- /// The operation servers
- private IReadOnlyDictionary>> _operationServers;
-
- #endregion Private Members
-
- #region Constructors
-
- ///
- /// Initializes a new instance of the class
- ///
- [System.Diagnostics.CodeAnalysis.SuppressMessage("ReSharper", "VirtualMemberCallInConstructor")]
- public Configuration()
- {
- Proxy = null;
- UserAgent = WebUtility.UrlEncode("OpenAPI-Generator/1.0.0/csharp");
- BasePath = "https://push.databox.com";
- DefaultHeaders = new ConcurrentDictionary();
- ApiKey = new ConcurrentDictionary();
- ApiKeyPrefix = new ConcurrentDictionary();
- Servers = new List>()
- {
- {
- new Dictionary {
- {"url", "https://push.databox.com"},
- {"description", "Dev mode server description"},
- }
- }
- };
- OperationServers = new Dictionary>>()
- {
- };
-
- // Setting Timeout has side effects (forces ApiClient creation).
- Timeout = 100000;
- }
-
- ///
- /// Initializes a new instance of the class
- ///
- [System.Diagnostics.CodeAnalysis.SuppressMessage("ReSharper", "VirtualMemberCallInConstructor")]
- public Configuration(
- IDictionary defaultHeaders,
- IDictionary apiKey,
- IDictionary apiKeyPrefix,
- string basePath = "https://push.databox.com") : this()
- {
- if (string.IsNullOrWhiteSpace(basePath))
- throw new ArgumentException("The provided basePath is invalid.", "basePath");
- if (defaultHeaders == null)
- throw new ArgumentNullException("defaultHeaders");
- if (apiKey == null)
- throw new ArgumentNullException("apiKey");
- if (apiKeyPrefix == null)
- throw new ArgumentNullException("apiKeyPrefix");
-
- BasePath = basePath;
-
- foreach (var keyValuePair in defaultHeaders)
- {
- DefaultHeaders.Add(keyValuePair);
- }
-
- foreach (var keyValuePair in apiKey)
- {
- ApiKey.Add(keyValuePair);
- }
-
- foreach (var keyValuePair in apiKeyPrefix)
- {
- ApiKeyPrefix.Add(keyValuePair);
- }
- }
-
- #endregion Constructors
-
- #region Properties
-
- ///
- /// Gets or sets the base path for API access.
- ///
- public virtual string BasePath
- {
- get { return _basePath; }
- set { _basePath = value; }
- }
-
- ///
- /// Determine whether or not the "default credentials" (e.g. the user account under which the current process is running) will be sent along to the server. The default is false.
- ///
- public virtual bool UseDefaultCredentials
- {
- get { return _useDefaultCredentials; }
- set { _useDefaultCredentials = value; }
- }
-
- ///
- /// Gets or sets the default header.
- ///
- [Obsolete("Use DefaultHeaders instead.")]
- public virtual IDictionary DefaultHeader
- {
- get
- {
- return DefaultHeaders;
- }
- set
- {
- DefaultHeaders = value;
- }
- }
-
- ///
- /// Gets or sets the default headers.
- ///
- public virtual IDictionary DefaultHeaders { get; set; }
-
- ///
- /// Gets or sets the HTTP timeout (milliseconds) of ApiClient. Default to 100000 milliseconds.
- ///
- public virtual int Timeout { get; set; }
-
- ///
- /// Gets or sets the proxy
- ///
- /// Proxy.
- public virtual WebProxy Proxy { get; set; }
-
- ///
- /// Gets or sets the HTTP user agent.
- ///
- /// Http user agent.
- public virtual string UserAgent { get; set; }
-
- ///
- /// Gets or sets the username (HTTP basic authentication).
- ///
- /// The username.
- public virtual string Username { get; set; }
-
- ///
- /// Gets or sets the password (HTTP basic authentication).
- ///
- /// The password.
- public virtual string Password { get; set; }
-
- ///
- /// Gets the API key with prefix.
- ///
- /// API key identifier (authentication scheme).
- /// API key with prefix.
- public string GetApiKeyWithPrefix(string apiKeyIdentifier)
- {
- string apiKeyValue;
- ApiKey.TryGetValue(apiKeyIdentifier, out apiKeyValue);
- string apiKeyPrefix;
- if (ApiKeyPrefix.TryGetValue(apiKeyIdentifier, out apiKeyPrefix))
- {
- return apiKeyPrefix + " " + apiKeyValue;
- }
-
- return apiKeyValue;
- }
-
- ///
- /// Gets or sets certificate collection to be sent with requests.
- ///
- /// X509 Certificate collection.
- public X509CertificateCollection ClientCertificates { get; set; }
-
- ///
- /// Gets or sets the access token for OAuth2 authentication.
- ///
- /// This helper property simplifies code generation.
- ///
- /// The access token.
- public virtual string AccessToken { get; set; }
-
- ///
- /// Gets or sets the temporary folder path to store the files downloaded from the server.
- ///
- /// Folder path.
- public virtual string TempFolderPath
- {
- get { return _tempFolderPath; }
-
- set
- {
- if (string.IsNullOrEmpty(value))
- {
- _tempFolderPath = Path.GetTempPath();
- return;
- }
-
- // create the directory if it does not exist
- if (!Directory.Exists(value))
- {
- Directory.CreateDirectory(value);
- }
-
- // check if the path contains directory separator at the end
- if (value[value.Length - 1] == Path.DirectorySeparatorChar)
- {
- _tempFolderPath = value;
- }
- else
- {
- _tempFolderPath = value + Path.DirectorySeparatorChar;
- }
- }
- }
-
- ///
- /// Gets or sets the date time format used when serializing in the ApiClient
- /// By default, it's set to ISO 8601 - "o", for others see:
- /// https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx
- /// and https://msdn.microsoft.com/en-us/library/8kb3ddd4(v=vs.110).aspx
- /// No validation is done to ensure that the string you're providing is valid
- ///
- /// The DateTimeFormat string
- public virtual string DateTimeFormat
- {
- get { return _dateTimeFormat; }
- set
- {
- if (string.IsNullOrEmpty(value))
- {
- // Never allow a blank or null string, go back to the default
- _dateTimeFormat = ISO8601_DATETIME_FORMAT;
- return;
- }
-
- // Caution, no validation when you choose date time format other than ISO 8601
- // Take a look at the above links
- _dateTimeFormat = value;
- }
- }
-
- ///
- /// Gets or sets the prefix (e.g. Token) of the API key based on the authentication name.
- ///
- /// Whatever you set here will be prepended to the value defined in AddApiKey.
- ///
- /// An example invocation here might be:
- ///
- /// ApiKeyPrefix["Authorization"] = "Bearer";
- ///
- /// … where ApiKey["Authorization"] would then be used to set the value of your bearer token.
- ///
- ///
- /// OAuth2 workflows should set tokens via AccessToken.
- ///
- ///
- /// The prefix of the API key.
- public virtual IDictionary ApiKeyPrefix
- {
- get { return _apiKeyPrefix; }
- set
- {
- if (value == null)
- {
- throw new InvalidOperationException("ApiKeyPrefix collection may not be null.");
- }
- _apiKeyPrefix = value;
- }
- }
-
- ///
- /// Gets or sets the API key based on the authentication name.
- ///
- /// The API key.
- public virtual IDictionary ApiKey
- {
- get { return _apiKey; }
- set
- {
- if (value == null)
- {
- throw new InvalidOperationException("ApiKey collection may not be null.");
- }
- _apiKey = value;
- }
- }
-
- ///
- /// Gets or sets the servers.
- ///
- /// The servers.
- public virtual IList> Servers
- {
- get { return _servers; }
- set
- {
- if (value == null)
- {
- throw new InvalidOperationException("Servers may not be null.");
- }
- _servers = value;
- }
- }
-
- ///
- /// Gets or sets the operation servers.
- ///
- /// The operation servers.
- public virtual IReadOnlyDictionary>> OperationServers
- {
- get { return _operationServers; }
- set
- {
- if (value == null)
- {
- throw new InvalidOperationException("Operation servers may not be null.");
- }
- _operationServers = value;
- }
- }
-
- ///
- /// Returns URL based on server settings without providing values
- /// for the variables
- ///
- /// Array index of the server settings.
- /// The server URL.
- public string GetServerUrl(int index)
- {
- return GetServerUrl(Servers, index, null);
- }
-
- ///
- /// Returns URL based on server settings.
- ///
- /// Array index of the server settings.
- /// Dictionary of the variables and the corresponding values.
- /// The server URL.
- public string GetServerUrl(int index, Dictionary inputVariables)
- {
- return GetServerUrl(Servers, index, inputVariables);
- }
-
- ///
- /// Returns URL based on operation server settings.
- ///
- /// Operation associated with the request path.
- /// Array index of the server settings.
- /// The operation server URL.
- public string GetOperationServerUrl(string operation, int index)
- {
- return GetOperationServerUrl(operation, index, null);
- }
-
- ///
- /// Returns URL based on operation server settings.
- ///
- /// Operation associated with the request path.
- /// Array index of the server settings.
- /// Dictionary of the variables and the corresponding values.
- /// The operation server URL.
- public string GetOperationServerUrl(string operation, int index, Dictionary inputVariables)
- {
- if (operation != null && OperationServers.TryGetValue(operation, out var operationServer))
- {
- return GetServerUrl(operationServer, index, inputVariables);
- }
-
- return null;
- }
-
- ///
- /// Returns URL based on server settings.
- ///
- /// Dictionary of server settings.
- /// Array index of the server settings.
- /// Dictionary of the variables and the corresponding values.
- /// The server URL.
- private string GetServerUrl(IList> servers, int index, Dictionary inputVariables)
- {
- if (index < 0 || index >= servers.Count)
- {
- throw new InvalidOperationException($"Invalid index {index} when selecting the server. Must be less than {servers.Count}.");
- }
-
- if (inputVariables == null)
- {
- inputVariables = new Dictionary();
- }
-
- IReadOnlyDictionary server = servers[index];
- string url = (string)server["url"];
-
- if (server.ContainsKey("variables"))
- {
- // go through each variable and assign a value
- foreach (KeyValuePair variable in (IReadOnlyDictionary)server["variables"])
- {
-
- IReadOnlyDictionary serverVariables = (IReadOnlyDictionary)(variable.Value);
-
- if (inputVariables.ContainsKey(variable.Key))
- {
- if (((List)serverVariables["enum_values"]).Contains(inputVariables[variable.Key]))
- {
- url = url.Replace("{" + variable.Key + "}", inputVariables[variable.Key]);
- }
- else
- {
- throw new InvalidOperationException($"The variable `{variable.Key}` in the server URL has invalid value #{inputVariables[variable.Key]}. Must be {(List)serverVariables["enum_values"]}");
- }
- }
- else
- {
- // use default value
- url = url.Replace("{" + variable.Key + "}", (string)serverVariables["default_value"]);
- }
- }
- }
-
- return url;
- }
-
- ///
- /// Gets and Sets the RemoteCertificateValidationCallback
- ///
- public RemoteCertificateValidationCallback RemoteCertificateValidationCallback { get; set; }
-
- #endregion Properties
-
- #region Methods
-
- ///
- /// Returns a string with essential information for debugging.
- ///
- public static string ToDebugReport()
- {
- string report = "C# SDK (Org.OpenAPITools) Debug Report:\n";
- report += " OS: " + System.Environment.OSVersion + "\n";
- report += " .NET Framework Version: " + System.Environment.Version + "\n";
- report += " Version of the API: 0.3.15-sdk.5\n";
- report += " SDK Package Version: 1.0.0\n";
-
- return report;
- }
-
- ///
- /// Add Api Key Header.
- ///
- /// Api Key name.
- /// Api Key value.
- ///
- public void AddApiKey(string key, string value)
- {
- ApiKey[key] = value;
- }
-
- ///
- /// Sets the API key prefix.
- ///
- /// Api Key name.
- /// Api Key value.
- public void AddApiKeyPrefix(string key, string value)
- {
- ApiKeyPrefix[key] = value;
- }
-
- #endregion Methods
-
- #region Static Members
- ///
- /// Merge configurations.
- ///
- /// First configuration.
- /// Second configuration.
- /// Merged configuration.
- public static IReadableConfiguration MergeConfigurations(IReadableConfiguration first, IReadableConfiguration second)
- {
- if (second == null) return first ?? GlobalConfiguration.Instance;
-
- Dictionary apiKey = first.ApiKey.ToDictionary(kvp => kvp.Key, kvp => kvp.Value);
- Dictionary apiKeyPrefix = first.ApiKeyPrefix.ToDictionary(kvp => kvp.Key, kvp => kvp.Value);
- Dictionary defaultHeaders = first.DefaultHeaders.ToDictionary(kvp => kvp.Key, kvp => kvp.Value);
-
- foreach (var kvp in second.ApiKey) apiKey[kvp.Key] = kvp.Value;
- foreach (var kvp in second.ApiKeyPrefix) apiKeyPrefix[kvp.Key] = kvp.Value;
- foreach (var kvp in second.DefaultHeaders) defaultHeaders[kvp.Key] = kvp.Value;
-
- var config = new Configuration
- {
- ApiKey = apiKey,
- ApiKeyPrefix = apiKeyPrefix,
- DefaultHeaders = defaultHeaders,
- BasePath = second.BasePath ?? first.BasePath,
- Timeout = second.Timeout,
- Proxy = second.Proxy ?? first.Proxy,
- UserAgent = second.UserAgent ?? first.UserAgent,
- Username = second.Username ?? first.Username,
- Password = second.Password ?? first.Password,
- AccessToken = second.AccessToken ?? first.AccessToken,
- TempFolderPath = second.TempFolderPath ?? first.TempFolderPath,
- DateTimeFormat = second.DateTimeFormat ?? first.DateTimeFormat,
- ClientCertificates = second.ClientCertificates ?? first.ClientCertificates,
- UseDefaultCredentials = second.UseDefaultCredentials,
- RemoteCertificateValidationCallback = second.RemoteCertificateValidationCallback ?? first.RemoteCertificateValidationCallback,
- };
- return config;
- }
- #endregion Static Members
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/ExceptionFactory.cs b/src/src/Org.OpenAPITools/Client/ExceptionFactory.cs
deleted file mode 100644
index 7d66a61..0000000
--- a/src/src/Org.OpenAPITools/Client/ExceptionFactory.cs
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// A delegate to ExceptionFactory method
- ///
- /// Method name
- /// Response
- /// Exceptions
- public delegate Exception ExceptionFactory(string methodName, IApiResponse response);
-}
diff --git a/src/src/Org.OpenAPITools/Client/GlobalConfiguration.cs b/src/src/Org.OpenAPITools/Client/GlobalConfiguration.cs
deleted file mode 100644
index 46ffa20..0000000
--- a/src/src/Org.OpenAPITools/Client/GlobalConfiguration.cs
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System.Collections.Generic;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// provides a compile-time extension point for globally configuring
- /// API Clients.
- ///
- ///
- /// A customized implementation via partial class may reside in another file and may
- /// be excluded from automatic generation via a .openapi-generator-ignore file.
- ///
- public partial class GlobalConfiguration : Configuration
- {
- #region Private Members
-
- private static readonly object GlobalConfigSync = new { };
- private static IReadableConfiguration _globalConfiguration;
-
- #endregion Private Members
-
- #region Constructors
-
- ///
- private GlobalConfiguration()
- {
- }
-
- ///
- public GlobalConfiguration(IDictionary defaultHeader, IDictionary apiKey, IDictionary apiKeyPrefix, string basePath = "http://localhost:3000/api") : base(defaultHeader, apiKey, apiKeyPrefix, basePath)
- {
- }
-
- static GlobalConfiguration()
- {
- Instance = new GlobalConfiguration();
- }
-
- #endregion Constructors
-
- ///
- /// Gets or sets the default Configuration.
- ///
- /// Configuration.
- public static IReadableConfiguration Instance
- {
- get { return _globalConfiguration; }
- set
- {
- lock (GlobalConfigSync)
- {
- _globalConfiguration = value;
- }
- }
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/HttpMethod.cs b/src/src/Org.OpenAPITools/Client/HttpMethod.cs
deleted file mode 100644
index 8aa315a..0000000
--- a/src/src/Org.OpenAPITools/Client/HttpMethod.cs
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Http methods supported by swagger
- ///
- public enum HttpMethod
- {
- /// HTTP GET request.
- Get,
- /// HTTP POST request.
- Post,
- /// HTTP PUT request.
- Put,
- /// HTTP DELETE request.
- Delete,
- /// HTTP HEAD request.
- Head,
- /// HTTP OPTIONS request.
- Options,
- /// HTTP PATCH request.
- Patch
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/IApiAccessor.cs b/src/src/Org.OpenAPITools/Client/IApiAccessor.cs
deleted file mode 100644
index d4e3a5c..0000000
--- a/src/src/Org.OpenAPITools/Client/IApiAccessor.cs
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Represents configuration aspects required to interact with the API endpoints.
- ///
- public interface IApiAccessor
- {
- ///
- /// Gets or sets the configuration object
- ///
- /// An instance of the Configuration
- IReadableConfiguration Configuration { get; set; }
-
- ///
- /// Gets the base path of the API client.
- ///
- /// The base path
- string GetBasePath();
-
- ///
- /// Provides a factory method hook for the creation of exceptions.
- ///
- ExceptionFactory ExceptionFactory { get; set; }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/IAsynchronousClient.cs b/src/src/Org.OpenAPITools/Client/IAsynchronousClient.cs
deleted file mode 100644
index bd4ab35..0000000
--- a/src/src/Org.OpenAPITools/Client/IAsynchronousClient.cs
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Threading.Tasks;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Contract for Asynchronous RESTful API interactions.
- ///
- /// This interface allows consumers to provide a custom API accessor client.
- ///
- public interface IAsynchronousClient
- {
- ///
- /// Executes a non-blocking call to some using the GET http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> GetAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
-
- ///
- /// Executes a non-blocking call to some using the POST http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> PostAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
-
- ///
- /// Executes a non-blocking call to some using the PUT http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> PutAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
-
- ///
- /// Executes a non-blocking call to some using the DELETE http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> DeleteAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
-
- ///
- /// Executes a non-blocking call to some using the HEAD http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> HeadAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
-
- ///
- /// Executes a non-blocking call to some using the OPTIONS http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> OptionsAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
-
- ///
- /// Executes a non-blocking call to some using the PATCH http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// Cancellation Token to cancel the request.
- /// The return type.
- /// A task eventually representing the response data, decorated with
- Task> PatchAsync(string path, RequestOptions options, IReadableConfiguration configuration = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/IReadableConfiguration.cs b/src/src/Org.OpenAPITools/Client/IReadableConfiguration.cs
deleted file mode 100644
index e53abfa..0000000
--- a/src/src/Org.OpenAPITools/Client/IReadableConfiguration.cs
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections.Generic;
-using System.Net;
-using System.Net.Security;
-using System.Security.Cryptography.X509Certificates;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Represents a readable-only configuration contract.
- ///
- public interface IReadableConfiguration
- {
- ///
- /// Gets the access token.
- ///
- /// Access token.
- string AccessToken { get; }
-
- ///
- /// Gets the API key.
- ///
- /// API key.
- IDictionary ApiKey { get; }
-
- ///
- /// Gets the API key prefix.
- ///
- /// API key prefix.
- IDictionary ApiKeyPrefix { get; }
-
- ///
- /// Gets the base path.
- ///
- /// Base path.
- string BasePath { get; }
-
- ///
- /// Gets the date time format.
- ///
- /// Date time format.
- string DateTimeFormat { get; }
-
- ///
- /// Gets the default header.
- ///
- /// Default header.
- [Obsolete("Use DefaultHeaders instead.")]
- IDictionary DefaultHeader { get; }
-
- ///
- /// Gets the default headers.
- ///
- /// Default headers.
- IDictionary DefaultHeaders { get; }
-
- ///
- /// Gets the temp folder path.
- ///
- /// Temp folder path.
- string TempFolderPath { get; }
-
- ///
- /// Gets the HTTP connection timeout (in milliseconds)
- ///
- /// HTTP connection timeout.
- int Timeout { get; }
-
- ///
- /// Gets the proxy.
- ///
- /// Proxy.
- WebProxy Proxy { get; }
-
- ///
- /// Gets the user agent.
- ///
- /// User agent.
- string UserAgent { get; }
-
- ///
- /// Gets the username.
- ///
- /// Username.
- string Username { get; }
-
- ///
- /// Gets the password.
- ///
- /// Password.
- string Password { get; }
-
- ///
- /// Determine whether or not the "default credentials" (e.g. the user account under which the current process is running) will be sent along to the server. The default is false.
- ///
- bool UseDefaultCredentials { get; }
-
- ///
- /// Get the servers associated with the operation.
- ///
- /// Operation servers.
- IReadOnlyDictionary>> OperationServers { get; }
-
- ///
- /// Gets the API key with prefix.
- ///
- /// API key identifier (authentication scheme).
- /// API key with prefix.
- string GetApiKeyWithPrefix(string apiKeyIdentifier);
-
- ///
- /// Gets the Operation server url at the provided index.
- ///
- /// Operation server name.
- /// Index of the operation server settings.
- ///
- string GetOperationServerUrl(string operation, int index);
-
- ///
- /// Gets certificate collection to be sent with requests.
- ///
- /// X509 Certificate collection.
- X509CertificateCollection ClientCertificates { get; }
-
- ///
- /// Callback function for handling the validation of remote certificates. Useful for certificate pinning and
- /// overriding certificate errors in the scope of a request.
- ///
- RemoteCertificateValidationCallback RemoteCertificateValidationCallback { get; }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/ISynchronousClient.cs b/src/src/Org.OpenAPITools/Client/ISynchronousClient.cs
deleted file mode 100644
index ff86786..0000000
--- a/src/src/Org.OpenAPITools/Client/ISynchronousClient.cs
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.IO;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Contract for Synchronous RESTful API interactions.
- ///
- /// This interface allows consumers to provide a custom API accessor client.
- ///
- public interface ISynchronousClient
- {
- ///
- /// Executes a blocking call to some using the GET http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Get(string path, RequestOptions options, IReadableConfiguration configuration = null);
-
- ///
- /// Executes a blocking call to some using the POST http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Post(string path, RequestOptions options, IReadableConfiguration configuration = null);
-
- ///
- /// Executes a blocking call to some using the PUT http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Put(string path, RequestOptions options, IReadableConfiguration configuration = null);
-
- ///
- /// Executes a blocking call to some using the DELETE http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Delete(string path, RequestOptions options, IReadableConfiguration configuration = null);
-
- ///
- /// Executes a blocking call to some using the HEAD http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Head(string path, RequestOptions options, IReadableConfiguration configuration = null);
-
- ///
- /// Executes a blocking call to some using the OPTIONS http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Options(string path, RequestOptions options, IReadableConfiguration configuration = null);
-
- ///
- /// Executes a blocking call to some using the PATCH http verb.
- ///
- /// The relative path to invoke.
- /// The request parameters to pass along to the client.
- /// Per-request configurable settings.
- /// The return type.
- /// The response data, decorated with
- ApiResponse Patch(string path, RequestOptions options, IReadableConfiguration configuration = null);
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/Multimap.cs b/src/src/Org.OpenAPITools/Client/Multimap.cs
deleted file mode 100644
index 71f4c5a..0000000
--- a/src/src/Org.OpenAPITools/Client/Multimap.cs
+++ /dev/null
@@ -1,295 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// A dictionary in which one key has many associated values.
- ///
- /// The type of the key
- /// The type of the value associated with the key.
- public class Multimap : IDictionary>
- {
- #region Private Fields
-
- private readonly Dictionary> _dictionary;
-
- #endregion Private Fields
-
- #region Constructors
-
- ///
- /// Empty Constructor.
- ///
- public Multimap()
- {
- _dictionary = new Dictionary>();
- }
-
- ///
- /// Constructor with comparer.
- ///
- ///
- public Multimap(IEqualityComparer comparer)
- {
- _dictionary = new Dictionary>(comparer);
- }
-
- #endregion Constructors
-
- #region Enumerators
-
- ///
- /// To get the enumerator.
- ///
- /// Enumerator
- public IEnumerator>> GetEnumerator()
- {
- return _dictionary.GetEnumerator();
- }
-
- ///
- /// To get the enumerator.
- ///
- /// Enumerator
- IEnumerator IEnumerable.GetEnumerator()
- {
- return _dictionary.GetEnumerator();
- }
-
- #endregion Enumerators
-
- #region Public Members
- ///
- /// Add values to Multimap
- ///
- /// Key value pair
- public void Add(KeyValuePair> item)
- {
- if (!TryAdd(item.Key, item.Value))
- throw new InvalidOperationException("Could not add values to Multimap.");
- }
-
- ///
- /// Add Multimap to Multimap
- ///
- /// Multimap
- public void Add(Multimap multimap)
- {
- foreach (var item in multimap)
- {
- if (!TryAdd(item.Key, item.Value))
- throw new InvalidOperationException("Could not add values to Multimap.");
- }
- }
-
- ///
- /// Clear Multimap
- ///
- public void Clear()
- {
- _dictionary.Clear();
- }
-
- ///
- /// Determines whether Multimap contains the specified item.
- ///
- /// Key value pair
- /// Method needs to be implemented
- /// true if the Multimap contains the item; otherwise, false.
- public bool Contains(KeyValuePair> item)
- {
- throw new NotImplementedException();
- }
-
- ///
- /// Copy items of the Multimap to an array,
- /// starting at a particular array index.
- ///
- /// The array that is the destination of the items copied
- /// from Multimap. The array must have zero-based indexing.
- /// The zero-based index in array at which copying begins.
- /// Method needs to be implemented
- public void CopyTo(KeyValuePair>[] array, int arrayIndex)
- {
- throw new NotImplementedException();
- }
-
- ///
- /// Removes the specified item from the Multimap.
- ///
- /// Key value pair
- /// true if the item is successfully removed; otherwise, false.
- /// Method needs to be implemented
- public bool Remove(KeyValuePair> item)
- {
- throw new NotImplementedException();
- }
-
- ///
- /// Gets the number of items contained in the Multimap.
- ///
- public int Count => _dictionary.Count;
-
- ///
- /// Gets a value indicating whether the Multimap is read-only.
- ///
- public bool IsReadOnly => false;
-
- ///
- /// Adds an item with the provided key and value to the Multimap.
- ///
- /// The object to use as the key of the item to add.
- /// The object to use as the value of the item to add.
- /// Thrown when couldn't add the value to Multimap.
- public void Add(TKey key, IList value)
- {
- if (value != null && value.Count > 0)
- {
- if (_dictionary.TryGetValue(key, out var list))
- {
- foreach (var k in value) list.Add(k);
- }
- else
- {
- list = new List(value);
- if (!TryAdd(key, list))
- throw new InvalidOperationException("Could not add values to Multimap.");
- }
- }
- }
-
- ///
- /// Determines whether the Multimap contains an item with the specified key.
- ///
- /// The key to locate in the Multimap.
- /// true if the Multimap contains an item with
- /// the key; otherwise, false.
- public bool ContainsKey(TKey key)
- {
- return _dictionary.ContainsKey(key);
- }
-
- ///
- /// Removes item with the specified key from the Multimap.
- ///
- /// The key to locate in the Multimap.
- /// true if the item is successfully removed; otherwise, false.
- public bool Remove(TKey key)
- {
- return TryRemove(key, out var _);
- }
-
- ///
- /// Gets the value associated with the specified key.
- ///
- /// The key whose value to get.
- /// When this method returns, the value associated with the specified key, if the
- /// key is found; otherwise, the default value for the type of the value parameter.
- /// This parameter is passed uninitialized.
- /// true if the object that implements Multimap contains
- /// an item with the specified key; otherwise, false.
- public bool TryGetValue(TKey key, out IList value)
- {
- return _dictionary.TryGetValue(key, out value);
- }
-
- ///
- /// Gets or sets the item with the specified key.
- ///
- /// The key of the item to get or set.
- /// The value of the specified key.
- public IList this[TKey key]
- {
- get => _dictionary[key];
- set => _dictionary[key] = value;
- }
-
- ///
- /// Gets a System.Collections.Generic.ICollection containing the keys of the Multimap.
- ///
- public ICollection Keys => _dictionary.Keys;
-
- ///
- /// Gets a System.Collections.Generic.ICollection containing the values of the Multimap.
- ///
- public ICollection> Values => _dictionary.Values;
-
- ///
- /// Copy the items of the Multimap to an System.Array,
- /// starting at a particular System.Array index.
- ///
- /// The one-dimensional System.Array that is the destination of the items copied
- /// from Multimap. The System.Array must have zero-based indexing.
- /// The zero-based index in array at which copying begins.
- public void CopyTo(Array array, int index)
- {
- ((ICollection)_dictionary).CopyTo(array, index);
- }
-
- ///
- /// Adds an item with the provided key and value to the Multimap.
- ///
- /// The object to use as the key of the item to add.
- /// The object to use as the value of the item to add.
- /// Thrown when couldn't add value to Multimap.
- public void Add(TKey key, TValue value)
- {
- if (value != null)
- {
- if (_dictionary.TryGetValue(key, out var list))
- {
- list.Add(value);
- }
- else
- {
- list = new List { value };
- if (!TryAdd(key, list))
- throw new InvalidOperationException("Could not add value to Multimap.");
- }
- }
- }
-
- #endregion Public Members
-
- #region Private Members
-
- /**
- * Helper method to encapsulate generator differences between dictionary types.
- */
- private bool TryRemove(TKey key, out IList value)
- {
- _dictionary.TryGetValue(key, out value);
- return _dictionary.Remove(key);
- }
-
- /**
- * Helper method to encapsulate generator differences between dictionary types.
- */
- private bool TryAdd(TKey key, IList value)
- {
- try
- {
- _dictionary.Add(key, value);
- }
- catch (ArgumentException)
- {
- return false;
- }
-
- return true;
- }
- #endregion Private Members
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs b/src/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs
deleted file mode 100644
index 869139e..0000000
--- a/src/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-using Newtonsoft.Json.Converters;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Formatter for 'date' openapi formats ss defined by full-date - RFC3339
- /// see https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.0.md#data-types
- ///
- public class OpenAPIDateConverter : IsoDateTimeConverter
- {
- ///
- /// Initializes a new instance of the class.
- ///
- public OpenAPIDateConverter()
- {
- // full-date = date-fullyear "-" date-month "-" date-mday
- DateTimeFormat = "yyyy-MM-dd";
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/RequestOptions.cs b/src/src/Org.OpenAPITools/Client/RequestOptions.cs
deleted file mode 100644
index 1b6e158..0000000
--- a/src/src/Org.OpenAPITools/Client/RequestOptions.cs
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Net;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// A container for generalized request inputs. This type allows consumers to extend the request functionality
- /// by abstracting away from the default (built-in) request framework (e.g. RestSharp).
- ///
- public class RequestOptions
- {
- ///
- /// Parameters to be bound to path parts of the Request's URL
- ///
- public Dictionary PathParameters { get; set; }
-
- ///
- /// Query parameters to be applied to the request.
- /// Keys may have 1 or more values associated.
- ///
- public Multimap QueryParameters { get; set; }
-
- ///
- /// Header parameters to be applied to the request.
- /// Keys may have 1 or more values associated.
- ///
- public Multimap HeaderParameters { get; set; }
-
- ///
- /// Form parameters to be sent along with the request.
- ///
- public Dictionary FormParameters { get; set; }
-
- ///
- /// File parameters to be sent along with the request.
- ///
- public Multimap FileParameters { get; set; }
-
- ///
- /// Cookies to be sent along with the request.
- ///
- public List Cookies { get; set; }
-
- ///
- /// Operation associated with the request path.
- ///
- public string Operation { get; set; }
-
- ///
- /// Index associated with the operation.
- ///
- public int OperationIndex { get; set; }
-
- ///
- /// Any data associated with a request body.
- ///
- public Object Data { get; set; }
-
- ///
- /// Constructs a new instance of
- ///
- public RequestOptions()
- {
- PathParameters = new Dictionary();
- QueryParameters = new Multimap();
- HeaderParameters = new Multimap();
- FormParameters = new Dictionary();
- FileParameters = new Multimap();
- Cookies = new List();
- }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Client/RetryConfiguration.cs b/src/src/Org.OpenAPITools/Client/RetryConfiguration.cs
deleted file mode 100644
index 16ffdc3..0000000
--- a/src/src/Org.OpenAPITools/Client/RetryConfiguration.cs
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using Polly;
-using RestSharp;
-
-namespace Org.OpenAPITools.Client
-{
- ///
- /// Configuration class to set the polly retry policies to be applied to the requests.
- ///
- public static class RetryConfiguration
- {
- ///
- /// Retry policy
- ///
- public static Policy RetryPolicy { get; set; }
-
- ///
- /// Async retry policy
- ///
- public static AsyncPolicy AsyncRetryPolicy { get; set; }
- }
-}
diff --git a/src/src/Org.OpenAPITools/Model/AbstractOpenAPISchema.cs b/src/src/Org.OpenAPITools/Model/AbstractOpenAPISchema.cs
deleted file mode 100644
index b0e715c..0000000
--- a/src/src/Org.OpenAPITools/Model/AbstractOpenAPISchema.cs
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Serialization;
-
-namespace Org.OpenAPITools.Model
-{
- ///
- /// Abstract base class for oneOf, anyOf schemas in the OpenAPI specification
- ///
- public abstract partial class AbstractOpenAPISchema
- {
- ///
- /// Custom JSON serializer
- ///
- static public readonly JsonSerializerSettings SerializerSettings = new JsonSerializerSettings
- {
- // OpenAPI generated types generally hide default constructors.
- ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor,
- MissingMemberHandling = MissingMemberHandling.Error,
- ContractResolver = new DefaultContractResolver
- {
- NamingStrategy = new CamelCaseNamingStrategy
- {
- OverrideSpecifiedNames = false
- }
- }
- };
-
- ///
- /// Custom JSON serializer for objects with additional properties
- ///
- static public readonly JsonSerializerSettings AdditionalPropertiesSerializerSettings = new JsonSerializerSettings
- {
- // OpenAPI generated types generally hide default constructors.
- ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor,
- MissingMemberHandling = MissingMemberHandling.Ignore,
- ContractResolver = new DefaultContractResolver
- {
- NamingStrategy = new CamelCaseNamingStrategy
- {
- OverrideSpecifiedNames = false
- }
- }
- };
-
- ///
- /// Gets or Sets the actual instance
- ///
- public abstract Object ActualInstance { get; set; }
-
- ///
- /// Gets or Sets IsNullable to indicate whether the instance is nullable
- ///
- public bool IsNullable { get; protected set; }
-
- ///
- /// Gets or Sets the schema type, which can be either `oneOf` or `anyOf`
- ///
- public string SchemaType { get; protected set; }
-
- ///
- /// Converts the instance into JSON string.
- ///
- public abstract string ToJson();
- }
-}
diff --git a/src/src/Org.OpenAPITools/Model/ApiResponse.cs b/src/src/Org.OpenAPITools/Model/ApiResponse.cs
deleted file mode 100644
index 162a461..0000000
--- a/src/src/Org.OpenAPITools/Model/ApiResponse.cs
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.IO;
-using System.Runtime.Serialization;
-using System.Text;
-using System.Text.RegularExpressions;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Converters;
-using Newtonsoft.Json.Linq;
-using System.ComponentModel.DataAnnotations;
-using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
-
-namespace Org.OpenAPITools.Model
-{
- ///
- /// ApiResponse
- ///
- [DataContract(Name = "ApiResponse")]
- public partial class ApiResponse : IValidatableObject
- {
- ///
- /// Initializes a new instance of the class.
- ///
- /// status.
- /// message.
- public ApiResponse(string status = default(string), string message = default(string))
- {
- this.Status = status;
- this.Message = message;
- }
-
- ///
- /// Gets or Sets Status
- ///
- [DataMember(Name = "status", EmitDefaultValue = false)]
- public string Status { get; set; }
-
- ///
- /// Gets or Sets Message
- ///
- [DataMember(Name = "message", EmitDefaultValue = false)]
- public string Message { get; set; }
-
- ///
- /// Returns the string presentation of the object
- ///
- /// String presentation of the object
- public override string ToString()
- {
- StringBuilder sb = new StringBuilder();
- sb.Append("class ApiResponse {\n");
- sb.Append(" Status: ").Append(Status).Append("\n");
- sb.Append(" Message: ").Append(Message).Append("\n");
- sb.Append("}\n");
- return sb.ToString();
- }
-
- ///
- /// Returns the JSON string presentation of the object
- ///
- /// JSON string presentation of the object
- public virtual string ToJson()
- {
- return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
- }
-
- ///
- /// To validate all properties of the instance
- ///
- /// Validation context
- /// Validation Result
- IEnumerable IValidatableObject.Validate(ValidationContext validationContext)
- {
- yield break;
- }
- }
-
-}
diff --git a/src/src/Org.OpenAPITools/Model/PushData.cs b/src/src/Org.OpenAPITools/Model/PushData.cs
deleted file mode 100644
index 99811b9..0000000
--- a/src/src/Org.OpenAPITools/Model/PushData.cs
+++ /dev/null
@@ -1,136 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.IO;
-using System.Runtime.Serialization;
-using System.Text;
-using System.Text.RegularExpressions;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Converters;
-using Newtonsoft.Json.Linq;
-using System.ComponentModel.DataAnnotations;
-using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
-
-namespace Org.OpenAPITools.Model
-{
- ///
- /// PushData
- ///
- [DataContract(Name = "PushData")]
- public partial class PushData : IValidatableObject
- {
- ///
- /// Initializes a new instance of the class.
- ///
- /// attributes.
- /// date.
- /// key.
- /// periodFrom.
- /// periodTo.
- /// unit.
- /// value.
- public PushData(List attributes = default(List), string date = default(string), string key = default(string), string periodFrom = default(string), string periodTo = default(string), string unit = default(string), float value = default(float))
- {
- this.Attributes = attributes;
- this.Date = date;
- this.Key = key;
- this.PeriodFrom = periodFrom;
- this.PeriodTo = periodTo;
- this.Unit = unit;
- this.Value = value;
- }
-
- ///
- /// Gets or Sets Attributes
- ///
- [DataMember(Name = "attributes", EmitDefaultValue = false)]
- public List Attributes { get; set; }
-
- ///
- /// Gets or Sets Date
- ///
- [DataMember(Name = "date", EmitDefaultValue = false)]
- public string Date { get; set; }
-
- ///
- /// Gets or Sets Key
- ///
- [DataMember(Name = "key", EmitDefaultValue = false)]
- public string Key { get; set; }
-
- ///
- /// Gets or Sets PeriodFrom
- ///
- [DataMember(Name = "periodFrom", EmitDefaultValue = false)]
- public string PeriodFrom { get; set; }
-
- ///
- /// Gets or Sets PeriodTo
- ///
- [DataMember(Name = "periodTo", EmitDefaultValue = false)]
- public string PeriodTo { get; set; }
-
- ///
- /// Gets or Sets Unit
- ///
- [DataMember(Name = "unit", EmitDefaultValue = false)]
- public string Unit { get; set; }
-
- ///
- /// Gets or Sets Value
- ///
- [DataMember(Name = "value", EmitDefaultValue = false)]
- public float Value { get; set; }
-
- ///
- /// Returns the string presentation of the object
- ///
- /// String presentation of the object
- public override string ToString()
- {
- StringBuilder sb = new StringBuilder();
- sb.Append("class PushData {\n");
- sb.Append(" Attributes: ").Append(Attributes).Append("\n");
- sb.Append(" Date: ").Append(Date).Append("\n");
- sb.Append(" Key: ").Append(Key).Append("\n");
- sb.Append(" PeriodFrom: ").Append(PeriodFrom).Append("\n");
- sb.Append(" PeriodTo: ").Append(PeriodTo).Append("\n");
- sb.Append(" Unit: ").Append(Unit).Append("\n");
- sb.Append(" Value: ").Append(Value).Append("\n");
- sb.Append("}\n");
- return sb.ToString();
- }
-
- ///
- /// Returns the JSON string presentation of the object
- ///
- /// JSON string presentation of the object
- public virtual string ToJson()
- {
- return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
- }
-
- ///
- /// To validate all properties of the instance
- ///
- /// Validation context
- /// Validation Result
- IEnumerable IValidatableObject.Validate(ValidationContext validationContext)
- {
- yield break;
- }
- }
-
-}
diff --git a/src/src/Org.OpenAPITools/Model/PushDataAttribute.cs b/src/src/Org.OpenAPITools/Model/PushDataAttribute.cs
deleted file mode 100644
index 43e00f9..0000000
--- a/src/src/Org.OpenAPITools/Model/PushDataAttribute.cs
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.IO;
-using System.Runtime.Serialization;
-using System.Text;
-using System.Text.RegularExpressions;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Converters;
-using Newtonsoft.Json.Linq;
-using System.ComponentModel.DataAnnotations;
-using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
-
-namespace Org.OpenAPITools.Model
-{
- ///
- /// PushDataAttribute
- ///
- [DataContract(Name = "PushDataAttribute")]
- public partial class PushDataAttribute : IValidatableObject
- {
- ///
- /// Initializes a new instance of the class.
- ///
- /// key.
- /// value.
- public PushDataAttribute(string key = default(string), string value = default(string))
- {
- this.Key = key;
- this.Value = value;
- }
-
- ///
- /// Gets or Sets Key
- ///
- [DataMember(Name = "key", EmitDefaultValue = false)]
- public string Key { get; set; }
-
- ///
- /// Gets or Sets Value
- ///
- [DataMember(Name = "value", EmitDefaultValue = false)]
- public string Value { get; set; }
-
- ///
- /// Returns the string presentation of the object
- ///
- /// String presentation of the object
- public override string ToString()
- {
- StringBuilder sb = new StringBuilder();
- sb.Append("class PushDataAttribute {\n");
- sb.Append(" Key: ").Append(Key).Append("\n");
- sb.Append(" Value: ").Append(Value).Append("\n");
- sb.Append("}\n");
- return sb.ToString();
- }
-
- ///
- /// Returns the JSON string presentation of the object
- ///
- /// JSON string presentation of the object
- public virtual string ToJson()
- {
- return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
- }
-
- ///
- /// To validate all properties of the instance
- ///
- /// Validation context
- /// Validation Result
- IEnumerable IValidatableObject.Validate(ValidationContext validationContext)
- {
- yield break;
- }
- }
-
-}
diff --git a/src/src/Org.OpenAPITools/Model/State.cs b/src/src/Org.OpenAPITools/Model/State.cs
deleted file mode 100644
index 12920c4..0000000
--- a/src/src/Org.OpenAPITools/Model/State.cs
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.IO;
-using System.Runtime.Serialization;
-using System.Text;
-using System.Text.RegularExpressions;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Converters;
-using Newtonsoft.Json.Linq;
-using System.ComponentModel.DataAnnotations;
-using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
-
-namespace Org.OpenAPITools.Model
-{
- ///
- /// Defines State
- ///
- [JsonConverter(typeof(StringEnumConverter))]
- public enum State
- {
- ///
- /// Enum DOWN for value: DOWN
- ///
- [EnumMember(Value = "DOWN")]
- DOWN = 1,
-
- ///
- /// Enum UP for value: UP
- ///
- [EnumMember(Value = "UP")]
- UP = 2
- }
-
-}
diff --git a/src/src/Org.OpenAPITools/Org.OpenAPITools.csproj b/src/src/Org.OpenAPITools/Org.OpenAPITools.csproj
deleted file mode 100644
index 76b5f48..0000000
--- a/src/src/Org.OpenAPITools/Org.OpenAPITools.csproj
+++ /dev/null
@@ -1,36 +0,0 @@
-
-
-
- false
- net8.0
- Org.OpenAPITools
- Org.OpenAPITools
- Library
- OpenAPI
- OpenAPI
- OpenAPI Library
- A library generated from a OpenAPI doc
- No Copyright
- Org.OpenAPITools
- 1.0.0
- bin\$(Configuration)\$(TargetFramework)\Org.OpenAPITools.xml
- https://github.com/GIT_USER_ID/GIT_REPO_ID.git
- git
- Minor update
- annotations
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/src/Org.OpenAPITools/org.databox.api/DefaultApi.cs b/src/src/Org.OpenAPITools/org.databox.api/DefaultApi.cs
deleted file mode 100644
index e55b2b5..0000000
--- a/src/src/Org.OpenAPITools/org.databox.api/DefaultApi.cs
+++ /dev/null
@@ -1,1259 +0,0 @@
-/*
- * Static OpenAPI document of Push API resource
- *
- * Push API resources Open API documentation
- *
- * The version of the OpenAPI document: 0.3.15-sdk.5
- * Generated by: https://github.com/openapitools/openapi-generator.git
- */
-
-
-using System;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.Net;
-using System.Net.Mime;
-using Org.OpenAPITools.Client;
-using Org.OpenAPITools.Model;
-
-namespace Org.OpenAPITools.org.databox.api
-{
-
- ///
- /// Represents a collection of functions to interact with the API endpoints
- ///
- public interface IDefaultApiSync : IApiAccessor
- {
- #region Synchronous Operations
- ///
- ///
- ///
- /// Thrown when fails to make API call
- /// Index associated with the operation.
- ///
- void DataDelete(int operationIndex = 0);
-
- ///
- ///
- ///
- ///
- ///
- ///
- /// Thrown when fails to make API call
- /// Index associated with the operation.
- /// ApiResponse of Object(void)
- ApiResponse