diff --git a/README.md b/README.md
index fb4be412..7c868470 100644
--- a/README.md
+++ b/README.md
@@ -62,11 +62,7 @@ $ ./gradlew build
## Update client
-* Run `./gradlew generateSwaggerCode`
-* Delete `client/settings.gradle` (client is a gradle sub project and must not have a settings.gradle)
-* Delete `repositories` block from `client/build.gradle`
-* Delete `implementation "com.sun.xml.ws:jaxws-rt:x.x.x“` from `client/build.gradle`
-* Insert missing bracket in `retryingIntercept` method of class `src/main/java/com/github/gotify/client/auth/OAuth`
+* Run `./gradlew openApiGenerate`
* Commit changes
## Versioning
diff --git a/app/build.gradle.kts b/app/build.gradle.kts
index 68fae13e..52558d15 100644
--- a/app/build.gradle.kts
+++ b/app/build.gradle.kts
@@ -13,7 +13,7 @@ android {
compileSdk = 36
defaultConfig {
applicationId = "com.github.gotify"
- minSdk = 23
+ minSdk = 26
targetSdk = 36
versionCode = 34
versionName = "2.9.0"
@@ -101,7 +101,7 @@ dependencies {
implementation("com.google.code.gson:gson:2.13.1")
implementation("com.squareup.retrofit2:retrofit:3.0.0")
- implementation("org.threeten:threetenbp:1.7.1")
+
}
configurations {
diff --git a/app/src/main/kotlin/com/github/gotify/Utils.kt b/app/src/main/kotlin/com/github/gotify/Utils.kt
index babb389c..c8770e40 100644
--- a/app/src/main/kotlin/com/github/gotify/Utils.kt
+++ b/app/src/main/kotlin/com/github/gotify/Utils.kt
@@ -16,12 +16,12 @@ import java.net.MalformedURLException
import java.net.URI
import java.net.URISyntaxException
import java.net.URL
+import java.time.OffsetDateTime
import kotlinx.coroutines.CoroutineDispatcher
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch
import okhttp3.HttpUrl.Companion.toHttpUrlOrNull
-import org.threeten.bp.OffsetDateTime
import org.tinylog.kotlin.Logger
internal object Utils {
diff --git a/app/src/main/kotlin/com/github/gotify/init/InitializationActivity.kt b/app/src/main/kotlin/com/github/gotify/init/InitializationActivity.kt
index 534d4778..c3162221 100644
--- a/app/src/main/kotlin/com/github/gotify/init/InitializationActivity.kt
+++ b/app/src/main/kotlin/com/github/gotify/init/InitializationActivity.kt
@@ -138,7 +138,7 @@ internal class InitializationActivity : AppCompatActivity() {
private fun authenticated(user: User) {
Logger.info("Authenticated as ${user.name}")
- settings.setUser(user.name, user.isAdmin)
+ settings.setUser(user.name, user.admin)
requestVersion {
splashScreenActive = false
startActivity(Intent(this, MessagesActivity::class.java))
diff --git a/app/src/main/kotlin/com/github/gotify/messages/ListMessageAdapter.kt b/app/src/main/kotlin/com/github/gotify/messages/ListMessageAdapter.kt
index d87ef7a7..1b4dc623 100644
--- a/app/src/main/kotlin/com/github/gotify/messages/ListMessageAdapter.kt
+++ b/app/src/main/kotlin/com/github/gotify/messages/ListMessageAdapter.kt
@@ -30,8 +30,8 @@ import com.github.gotify.databinding.MessageItemCompactBinding
import com.github.gotify.messages.provider.MessageWithImage
import io.noties.markwon.Markwon
import java.text.DateFormat
+import java.time.OffsetDateTime
import java.util.Date
-import org.threeten.bp.OffsetDateTime
internal class ListMessageAdapter(
private val context: Context,
diff --git a/app/src/main/kotlin/com/github/gotify/service/WebSocketService.kt b/app/src/main/kotlin/com/github/gotify/service/WebSocketService.kt
index f5e72e26..0e5d6dd0 100644
--- a/app/src/main/kotlin/com/github/gotify/service/WebSocketService.kt
+++ b/app/src/main/kotlin/com/github/gotify/service/WebSocketService.kt
@@ -235,7 +235,7 @@ internal class WebSocketService : Service() {
messages.forEach { message ->
if (lastReceivedMessage.get() < message.id) {
lastReceivedMessage.set(message.id)
- highestPriority = highestPriority.coerceAtLeast(message.priority)
+ highestPriority = highestPriority.coerceAtLeast(message.priority ?: 0L)
}
broadcast(message)
}
@@ -256,9 +256,9 @@ internal class WebSocketService : Service() {
broadcast(message)
showNotification(
message.id,
- message.title,
+ message.title ?: "",
message.message,
- message.priority,
+ message.priority ?: 0L,
message.extras,
message.appid
)
diff --git a/build.gradle.kts b/build.gradle.kts
index bb26ca77..bd2761b7 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -1,11 +1,10 @@
-import com.android.build.gradle.internal.tasks.factory.dependsOn
import java.io.File
import java.net.URI
plugins {
id("com.android.application") version "8.11.0" apply false
id("org.jetbrains.kotlin.android") version "2.2.0" apply false
- id("org.hidetake.swagger.generator") version "2.19.2"
+ id("org.openapi.generator") version "7.19.0"
}
fun download(url: String, filename: String) {
@@ -29,19 +28,23 @@ tasks.register("downloadSpec") {
}
}
-swaggerSources {
- create("swagger") {
- setInputFile(file("$projectDir/build/gotify.spec.json"))
- code.apply {
- language = "java"
- configFile = file("$projectDir/swagger.config.json")
- outputDir = file("$projectDir/client")
- }
- }
+openApiGenerate {
+ generatorName.set("java")
+ inputSpec.set("$projectDir/build/gotify.spec.json")
+ outputDir.set("$projectDir/client")
+ apiPackage.set("com.github.gotify.client.api")
+ modelPackage.set("com.github.gotify.client.model")
+ configOptions.set(mapOf(
+ "library" to "retrofit2",
+ "hideGenerationTimestamp" to "true",
+ "dateLibrary" to "java8"
+ ))
+ generateApiTests.set(false)
+ generateModelTests.set(false)
+ generateApiDocumentation.set(false)
+ generateModelDocumentation.set(false)
}
-dependencies {
- "swaggerCodegen"("io.swagger.codegen.v3:swagger-codegen-cli:3.0.63")
+tasks.named("openApiGenerate").configure {
+ dependsOn("downloadSpec")
}
-
-tasks.named("generateSwaggerCode").dependsOn("downloadSpec")
diff --git a/client/.swagger-codegen-ignore b/client/.openapi-generator-ignore
similarity index 70%
rename from client/.swagger-codegen-ignore
rename to client/.openapi-generator-ignore
index c5fa491b..80e77a1e 100644
--- a/client/.swagger-codegen-ignore
+++ b/client/.openapi-generator-ignore
@@ -1,12 +1,22 @@
-# Swagger Codegen Ignore
-# Generated by swagger-codegen https://github.com/swagger-api/swagger-codegen
+# OpenAPI Generator Ignore
+# Generated by openapi-generator https://github.com/openapitools/openapi-generator
# Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore.
# As an example, the C# client generator defines ApiClient.cs.
-# You can make changes and tell Swagger Codgen to ignore just this file by uncommenting the following line:
+# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
#ApiClient.cs
+build.gradle
+build.sbt
+gradle/**
+gradlew
+gradlew.bat
+pom.xml
+settings.gradle
+.github/**
+.travis.yml
+api/openapi.yaml
# You can match any string of characters against a directory, file or extension with a single asterisk (*):
#foo/*/qux
diff --git a/client/.openapi-generator/FILES b/client/.openapi-generator/FILES
new file mode 100644
index 00000000..a38b3174
--- /dev/null
+++ b/client/.openapi-generator/FILES
@@ -0,0 +1,37 @@
+.gitignore
+README.md
+git_push.sh
+gradle.properties
+src/main/AndroidManifest.xml
+src/main/java/com/github/gotify/client/ApiClient.java
+src/main/java/com/github/gotify/client/CollectionFormats.java
+src/main/java/com/github/gotify/client/JSON.java
+src/main/java/com/github/gotify/client/ServerConfiguration.java
+src/main/java/com/github/gotify/client/ServerVariable.java
+src/main/java/com/github/gotify/client/StringUtil.java
+src/main/java/com/github/gotify/client/api/ApplicationApi.java
+src/main/java/com/github/gotify/client/api/ClientApi.java
+src/main/java/com/github/gotify/client/api/HealthApi.java
+src/main/java/com/github/gotify/client/api/MessageApi.java
+src/main/java/com/github/gotify/client/api/PluginApi.java
+src/main/java/com/github/gotify/client/api/UserApi.java
+src/main/java/com/github/gotify/client/api/VersionApi.java
+src/main/java/com/github/gotify/client/auth/ApiKeyAuth.java
+src/main/java/com/github/gotify/client/auth/HttpBasicAuth.java
+src/main/java/com/github/gotify/client/auth/HttpBearerAuth.java
+src/main/java/com/github/gotify/client/auth/OAuthOkHttpClient.java
+src/main/java/com/github/gotify/client/model/Application.java
+src/main/java/com/github/gotify/client/model/ApplicationParams.java
+src/main/java/com/github/gotify/client/model/Client.java
+src/main/java/com/github/gotify/client/model/ClientParams.java
+src/main/java/com/github/gotify/client/model/CreateUserExternal.java
+src/main/java/com/github/gotify/client/model/Error.java
+src/main/java/com/github/gotify/client/model/Health.java
+src/main/java/com/github/gotify/client/model/Message.java
+src/main/java/com/github/gotify/client/model/PagedMessages.java
+src/main/java/com/github/gotify/client/model/Paging.java
+src/main/java/com/github/gotify/client/model/PluginConf.java
+src/main/java/com/github/gotify/client/model/UpdateUserExternal.java
+src/main/java/com/github/gotify/client/model/User.java
+src/main/java/com/github/gotify/client/model/UserPass.java
+src/main/java/com/github/gotify/client/model/VersionInfo.java
diff --git a/client/.openapi-generator/VERSION b/client/.openapi-generator/VERSION
new file mode 100644
index 00000000..3821090f
--- /dev/null
+++ b/client/.openapi-generator/VERSION
@@ -0,0 +1 @@
+7.19.0
diff --git a/client/.swagger-codegen/VERSION b/client/.swagger-codegen/VERSION
deleted file mode 100644
index eefcac2b..00000000
--- a/client/.swagger-codegen/VERSION
+++ /dev/null
@@ -1 +0,0 @@
-3.0.63
\ No newline at end of file
diff --git a/client/.travis.yml b/client/.travis.yml
deleted file mode 100644
index 70cb81a6..00000000
--- a/client/.travis.yml
+++ /dev/null
@@ -1,17 +0,0 @@
-#
-# Generated by: https://github.com/swagger-api/swagger-codegen.git
-#
-language: java
-jdk:
- - oraclejdk8
- - oraclejdk7
-before_install:
- # ensure gradlew has proper permission
- - chmod a+x ./gradlew
-script:
- # test using maven
- - mvn test
- # uncomment below to test using gradle
- # - gradle test
- # uncomment below to test using sbt
- # - sbt test
diff --git a/client/README.md b/client/README.md
index f280fa71..cc57858e 100644
--- a/client/README.md
+++ b/client/README.md
@@ -1,4 +1,4 @@
-# swagger-java-client
+# openapi-java-client
## Requirements
@@ -24,9 +24,9 @@ After the client library is installed/deployed, you can use it in your Maven pro
```xml
- io.swagger
- swagger-java-client
- 1.0.0
+ org.openapitools
+ openapi-java-client
+ 2.0.2compile
diff --git a/client/build.gradle b/client/build.gradle
index 78265313..e50a101b 100644
--- a/client/build.gradle
+++ b/client/build.gradle
@@ -4,12 +4,12 @@ plugins {
}
ext {
- oltu_version = "1.0.2"
- retrofit_version = "2.7.1"
- swagger_annotations_version = "2.0.0"
- junit_version = "4.12"
- threetenbp_version = "1.4.1"
- json_fire_version = "1.8.3"
+ oltu_version = "1.0.1"
+ retrofit_version = "2.11.0"
+ jakarta_annotation_version = "1.3.5"
+ swagger_annotations_version = "2.2.28"
+ junit_version = "5.10.3"
+ json_fire_version = "1.9.0"
}
dependencies {
@@ -17,39 +17,26 @@ dependencies {
implementation "com.squareup.retrofit2:converter-scalars:$retrofit_version"
implementation "com.squareup.retrofit2:converter-gson:$retrofit_version"
implementation "io.swagger.core.v3:swagger-annotations:$swagger_annotations_version"
+ implementation "com.google.code.findbugs:jsr305:3.0.2"
implementation ("org.apache.oltu.oauth2:org.apache.oltu.oauth2.client:$oltu_version"){
exclude group:'org.apache.oltu.oauth2' , module: 'org.apache.oltu.oauth2.common'
- exclude group: 'org.json', module: 'json'
}
- implementation "org.json:json:20180130"
implementation "io.gsonfire:gson-fire:$json_fire_version"
- implementation "org.threeten:threetenbp:$threetenbp_version"
-
- testImplementation "junit:junit:$junit_version"
+ implementation "jakarta.annotation:jakarta.annotation-api:$jakarta_annotation_version"
+ testImplementation "org.junit.jupiter:junit-jupiter-api:$junit_version"
}
-group = 'io.swagger'
-version = '1.0.0'
-description = 'Swagger Java'
-
-java.sourceCompatibility = 11
-java.targetCompatibility = 11
+group = 'org.openapitools'
+version = '2.0.2'
-tasks.register('testsJar', Jar) {
- archiveClassifier = 'tests'
- from(sourceSets.test.output)
-}
-
-java {
- withSourcesJar()
- withJavadocJar()
-}
+java.sourceCompatibility = JavaVersion.VERSION_11
+java.targetCompatibility = JavaVersion.VERSION_11
publishing {
publications {
maven(MavenPublication) {
- from(components.java)
- artifact(testsJar)
+ artifactId = 'openapi-java-client'
+ from components.java
}
}
}
diff --git a/client/build.sbt b/client/build.sbt
deleted file mode 100644
index 29ea0f49..00000000
--- a/client/build.sbt
+++ /dev/null
@@ -1,22 +0,0 @@
-lazy val root = (project in file(".")).
- settings(
- organization := "io.swagger",
- name := "swagger-java-client",
- version := "1.0.0",
- scalaVersion := "2.11.4",
- scalacOptions ++= Seq("-feature"),
- javacOptions in compile ++= Seq("-Xlint:deprecation"),
- publishArtifact in (Compile, packageDoc) := false,
- resolvers += Resolver.mavenLocal,
- libraryDependencies ++= Seq(
- "com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
- "com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
- "com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
- "io.swagger.core.v3" % "swagger-annotations" % "2.0.0" % "compile",
- "org.apache.oltu.oauth2" % "org.apache.oltu.oauth2.client" % "1.0.2" % "compile",
- "org.threeten" % "threetenbp" % "1.3.5" % "compile",
- "io.gsonfire" % "gson-fire" % "1.8.0" % "compile",
- "junit" % "junit" % "4.12" % "test",
- "com.novocode" % "junit-interface" % "0.11" % "test"
- )
- )
diff --git a/client/docs/Application.md b/client/docs/Application.md
deleted file mode 100644
index 9a05079d..00000000
--- a/client/docs/Application.md
+++ /dev/null
@@ -1,13 +0,0 @@
-# Application
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**defaultPriority** | **Long** | The default priority of messages sent by this application. Defaults to 0. | [optional]
-**description** | **String** | The description of the application. |
-**id** | **Long** | The application id. |
-**image** | **String** | The image of the application. |
-**internal** | **Boolean** | Whether the application is an internal application. Internal applications should not be deleted. |
-**lastUsed** | [**OffsetDateTime**](OffsetDateTime.md) | The last time the application token was used. | [optional]
-**name** | **String** | The application name. This is how the application should be displayed to the user. |
-**token** | **String** | The application token. Can be used as `appToken`. See Authentication. |
diff --git a/client/docs/ApplicationApi.md b/client/docs/ApplicationApi.md
deleted file mode 100644
index ab81e2f8..00000000
--- a/client/docs/ApplicationApi.md
+++ /dev/null
@@ -1,427 +0,0 @@
-# ApplicationApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**createApp**](ApplicationApi.md#createApp) | **POST** application | Create an application.
-[**deleteApp**](ApplicationApi.md#deleteApp) | **DELETE** application/{id} | Delete an application.
-[**getApps**](ApplicationApi.md#getApps) | **GET** application | Return all applications.
-[**removeAppImage**](ApplicationApi.md#removeAppImage) | **DELETE** application/{id}/image | Deletes an image of an application.
-[**updateApplication**](ApplicationApi.md#updateApplication) | **PUT** application/{id} | Update an application.
-[**uploadAppImage**](ApplicationApi.md#uploadAppImage) | **POST** application/{id}/image | Upload an image for an application.
-
-
-# **createApp**
-> Application createApp(body)
-
-Create an application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ApplicationApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ApplicationApi apiInstance = new ApplicationApi();
-ApplicationParams body = new ApplicationParams(); // ApplicationParams | the application to add
-try {
- Application result = apiInstance.createApp(body);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ApplicationApi#createApp");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**ApplicationParams**](ApplicationParams.md)| the application to add |
-
-### Return type
-
-[**Application**](Application.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
-
-# **deleteApp**
-> Void deleteApp(id)
-
-Delete an application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ApplicationApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ApplicationApi apiInstance = new ApplicationApi();
-Long id = 789L; // Long | the application id
-try {
- Void result = apiInstance.deleteApp(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ApplicationApi#deleteApp");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the application id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getApps**
-> List<Application> getApps()
-
-Return all applications.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ApplicationApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ApplicationApi apiInstance = new ApplicationApi();
-try {
- List result = apiInstance.getApps();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ApplicationApi#getApps");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**List<Application>**](Application.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **removeAppImage**
-> Void removeAppImage(id)
-
-Deletes an image of an application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ApplicationApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ApplicationApi apiInstance = new ApplicationApi();
-Long id = 789L; // Long | the application id
-try {
- Void result = apiInstance.removeAppImage(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ApplicationApi#removeAppImage");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the application id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **updateApplication**
-> Application updateApplication(body, id)
-
-Update an application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ApplicationApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ApplicationApi apiInstance = new ApplicationApi();
-ApplicationParams body = new ApplicationParams(); // ApplicationParams | the application to update
-Long id = 789L; // Long | the application id
-try {
- Application result = apiInstance.updateApplication(body, id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ApplicationApi#updateApplication");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**ApplicationParams**](ApplicationParams.md)| the application to update |
- **id** | **Long**| the application id |
-
-### Return type
-
-[**Application**](Application.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
-
-# **uploadAppImage**
-> Application uploadAppImage(file, id)
-
-Upload an image for an application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ApplicationApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ApplicationApi apiInstance = new ApplicationApi();
-File file = new File("file_example"); // File |
-Long id = 789L; // Long | the application id
-try {
- Application result = apiInstance.uploadAppImage(file, id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ApplicationApi#uploadAppImage");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **file** | **File**| |
- **id** | **Long**| the application id |
-
-### Return type
-
-[**Application**](Application.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: multipart/form-data
- - **Accept**: application/json
-
diff --git a/client/docs/ApplicationParams.md b/client/docs/ApplicationParams.md
deleted file mode 100644
index 683a9036..00000000
--- a/client/docs/ApplicationParams.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# ApplicationParams
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**defaultPriority** | **Long** | The default priority of messages sent by this application. Defaults to 0. | [optional]
-**description** | **String** | The description of the application. | [optional]
-**name** | **String** | The application name. This is how the application should be displayed to the user. |
diff --git a/client/docs/Client.md b/client/docs/Client.md
deleted file mode 100644
index b6b4f9cd..00000000
--- a/client/docs/Client.md
+++ /dev/null
@@ -1,9 +0,0 @@
-# Client
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**id** | **Long** | The client id. |
-**lastUsed** | [**OffsetDateTime**](OffsetDateTime.md) | The last time the client token was used. | [optional]
-**name** | **String** | The client name. This is how the client should be displayed to the user. |
-**token** | **String** | The client token. Can be used as `clientToken`. See Authentication. |
diff --git a/client/docs/ClientApi.md b/client/docs/ClientApi.md
deleted file mode 100644
index e1628a1e..00000000
--- a/client/docs/ClientApi.md
+++ /dev/null
@@ -1,285 +0,0 @@
-# ClientApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**createClient**](ClientApi.md#createClient) | **POST** client | Create a client.
-[**deleteClient**](ClientApi.md#deleteClient) | **DELETE** client/{id} | Delete a client.
-[**getClients**](ClientApi.md#getClients) | **GET** client | Return all clients.
-[**updateClient**](ClientApi.md#updateClient) | **PUT** client/{id} | Update a client.
-
-
-# **createClient**
-> Client createClient(body)
-
-Create a client.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ClientApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ClientApi apiInstance = new ClientApi();
-ClientParams body = new ClientParams(); // ClientParams | the client to add
-try {
- Client result = apiInstance.createClient(body);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ClientApi#createClient");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**ClientParams**](ClientParams.md)| the client to add |
-
-### Return type
-
-[**Client**](Client.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
-
-# **deleteClient**
-> Void deleteClient(id)
-
-Delete a client.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ClientApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ClientApi apiInstance = new ClientApi();
-Long id = 789L; // Long | the client id
-try {
- Void result = apiInstance.deleteClient(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ClientApi#deleteClient");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the client id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getClients**
-> List<Client> getClients()
-
-Return all clients.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ClientApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ClientApi apiInstance = new ClientApi();
-try {
- List result = apiInstance.getClients();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ClientApi#getClients");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**List<Client>**](Client.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **updateClient**
-> Client updateClient(body, id)
-
-Update a client.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.ClientApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-ClientApi apiInstance = new ClientApi();
-ClientParams body = new ClientParams(); // ClientParams | the client to update
-Long id = 789L; // Long | the client id
-try {
- Client result = apiInstance.updateClient(body, id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling ClientApi#updateClient");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**ClientParams**](ClientParams.md)| the client to update |
- **id** | **Long**| the client id |
-
-### Return type
-
-[**Client**](Client.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
diff --git a/client/docs/ClientParams.md b/client/docs/ClientParams.md
deleted file mode 100644
index cb1370fe..00000000
--- a/client/docs/ClientParams.md
+++ /dev/null
@@ -1,6 +0,0 @@
-# ClientParams
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**name** | **String** | The client name |
diff --git a/client/docs/CreateUserExternal.md b/client/docs/CreateUserExternal.md
deleted file mode 100644
index 22fa5fee..00000000
--- a/client/docs/CreateUserExternal.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# CreateUserExternal
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**admin** | **Boolean** | If the user is an administrator. |
-**name** | **String** | The user name. For login. |
-**pass** | **String** | The user password. For login. |
diff --git a/client/docs/Error.md b/client/docs/Error.md
deleted file mode 100644
index 8dc3bb2d..00000000
--- a/client/docs/Error.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# Error
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**error** | **String** | The general error message |
-**errorCode** | **Long** | The http error code. |
-**errorDescription** | **String** | The http error code. |
diff --git a/client/docs/Health.md b/client/docs/Health.md
deleted file mode 100644
index a6b7c8af..00000000
--- a/client/docs/Health.md
+++ /dev/null
@@ -1,7 +0,0 @@
-# Health
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**database** | **String** | The health of the database connection. |
-**health** | **String** | The health of the overall application. |
diff --git a/client/docs/HealthApi.md b/client/docs/HealthApi.md
deleted file mode 100644
index 4e28101d..00000000
--- a/client/docs/HealthApi.md
+++ /dev/null
@@ -1,47 +0,0 @@
-# HealthApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**getHealth**](HealthApi.md#getHealth) | **GET** health | Get health information.
-
-
-# **getHealth**
-> Health getHealth()
-
-Get health information.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.api.HealthApi;
-
-
-HealthApi apiInstance = new HealthApi();
-try {
- Health result = apiInstance.getHealth();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling HealthApi#getHealth");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**Health**](Health.md)
-
-### Authorization
-
-No authorization required
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
diff --git a/client/docs/IdImageBody.md b/client/docs/IdImageBody.md
deleted file mode 100644
index 813a4b4e..00000000
--- a/client/docs/IdImageBody.md
+++ /dev/null
@@ -1,6 +0,0 @@
-# IdImageBody
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**file** | [**File**](File.md) | the application image |
diff --git a/client/docs/Message.md b/client/docs/Message.md
deleted file mode 100644
index 0822a334..00000000
--- a/client/docs/Message.md
+++ /dev/null
@@ -1,12 +0,0 @@
-# Message
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**appid** | **Long** | The application id that send this message. |
-**date** | [**OffsetDateTime**](OffsetDateTime.md) | The date the message was created. |
-**extras** | **Map<String, Object>** | The extra data sent along the message. The extra fields are stored in a key-value scheme. Only accepted in CreateMessage requests with application/json content-type. The keys should be in the following format: <top-namespace>::[<sub-namespace>::]<action> These namespaces are reserved and might be used in the official clients: gotify android ios web server client. Do not use them for other purposes. | [optional]
-**id** | **Long** | The message id. |
-**message** | **String** | The message. Markdown (excluding html) is allowed. |
-**priority** | **Long** | The priority of the message. If unset, then the default priority of the application will be used. | [optional]
-**title** | **String** | The title of the message. | [optional]
diff --git a/client/docs/MessageApi.md b/client/docs/MessageApi.md
deleted file mode 100644
index 9b42a212..00000000
--- a/client/docs/MessageApi.md
+++ /dev/null
@@ -1,493 +0,0 @@
-# MessageApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**createMessage**](MessageApi.md#createMessage) | **POST** message | Create a message.
-[**deleteAppMessages**](MessageApi.md#deleteAppMessages) | **DELETE** application/{id}/message | Delete all messages from a specific application.
-[**deleteMessage**](MessageApi.md#deleteMessage) | **DELETE** message/{id} | Deletes a message with an id.
-[**deleteMessages**](MessageApi.md#deleteMessages) | **DELETE** message | Delete all messages.
-[**getAppMessages**](MessageApi.md#getAppMessages) | **GET** application/{id}/message | Return all messages from a specific application.
-[**getMessages**](MessageApi.md#getMessages) | **GET** message | Return all messages.
-[**streamMessages**](MessageApi.md#streamMessages) | **GET** stream | Websocket, return newly created messages.
-
-
-# **createMessage**
-> Message createMessage(body)
-
-Create a message.
-
-__NOTE__: This API ONLY accepts an application token as authentication.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-
-// Configure API key authorization: appTokenAuthorizationHeader
-ApiKeyAuth appTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("appTokenAuthorizationHeader");
-appTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//appTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: appTokenHeader
-ApiKeyAuth appTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("appTokenHeader");
-appTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//appTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: appTokenQuery
-ApiKeyAuth appTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("appTokenQuery");
-appTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//appTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-Message body = new Message(); // Message | the message to add
-try {
- Message result = apiInstance.createMessage(body);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#createMessage");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**Message**](Message.md)| the message to add |
-
-### Return type
-
-[**Message**](Message.md)
-
-### Authorization
-
-[appTokenAuthorizationHeader](../README.md#appTokenAuthorizationHeader)[appTokenHeader](../README.md#appTokenHeader)[appTokenQuery](../README.md#appTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
-
-# **deleteAppMessages**
-> Void deleteAppMessages(id)
-
-Delete all messages from a specific application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-Long id = 789L; // Long | the application id
-try {
- Void result = apiInstance.deleteAppMessages(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#deleteAppMessages");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the application id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **deleteMessage**
-> Void deleteMessage(id)
-
-Deletes a message with an id.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-Long id = 789L; // Long | the message id
-try {
- Void result = apiInstance.deleteMessage(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#deleteMessage");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the message id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **deleteMessages**
-> Void deleteMessages()
-
-Delete all messages.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-try {
- Void result = apiInstance.deleteMessages();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#deleteMessages");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getAppMessages**
-> PagedMessages getAppMessages(id, limit, since)
-
-Return all messages from a specific application.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-Long id = 789L; // Long | the application id
-Integer limit = 100; // Integer | the maximal amount of messages to return
-Long since = 789L; // Long | return all messages with an ID less than this value
-try {
- PagedMessages result = apiInstance.getAppMessages(id, limit, since);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#getAppMessages");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the application id |
- **limit** | **Integer**| the maximal amount of messages to return | [optional] [default to 100] [enum: 1, 200]
- **since** | **Long**| return all messages with an ID less than this value | [optional] [enum: 0]
-
-### Return type
-
-[**PagedMessages**](PagedMessages.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getMessages**
-> PagedMessages getMessages(limit, since)
-
-Return all messages.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-Integer limit = 100; // Integer | the maximal amount of messages to return
-Long since = 789L; // Long | return all messages with an ID less than this value
-try {
- PagedMessages result = apiInstance.getMessages(limit, since);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#getMessages");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **limit** | **Integer**| the maximal amount of messages to return | [optional] [default to 100] [enum: 1, 200]
- **since** | **Long**| return all messages with an ID less than this value | [optional] [enum: 0]
-
-### Return type
-
-[**PagedMessages**](PagedMessages.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **streamMessages**
-> Message streamMessages()
-
-Websocket, return newly created messages.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.MessageApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-MessageApi apiInstance = new MessageApi();
-try {
- Message result = apiInstance.streamMessages();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling MessageApi#streamMessages");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**Message**](Message.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
diff --git a/client/docs/PagedMessages.md b/client/docs/PagedMessages.md
deleted file mode 100644
index f3ddffcb..00000000
--- a/client/docs/PagedMessages.md
+++ /dev/null
@@ -1,7 +0,0 @@
-# PagedMessages
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**messages** | [**List<Message>**](Message.md) | The messages. |
-**paging** | [**Paging**](Paging.md) | |
diff --git a/client/docs/Paging.md b/client/docs/Paging.md
deleted file mode 100644
index 12fbfd31..00000000
--- a/client/docs/Paging.md
+++ /dev/null
@@ -1,9 +0,0 @@
-# Paging
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**limit** | **Long** | The limit of the messages for the current request. |
-**next** | **String** | The request url for the next page. Empty/Null when no next page is available. | [optional]
-**since** | **Long** | The ID of the last message returned in the current request. Use this as alternative to the next link. |
-**size** | **Long** | The amount of messages that got returned in the current request. |
diff --git a/client/docs/PluginApi.md b/client/docs/PluginApi.md
deleted file mode 100644
index 7b7d870f..00000000
--- a/client/docs/PluginApi.md
+++ /dev/null
@@ -1,423 +0,0 @@
-# PluginApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**disablePlugin**](PluginApi.md#disablePlugin) | **POST** plugin/{id}/disable | Disable a plugin.
-[**enablePlugin**](PluginApi.md#enablePlugin) | **POST** plugin/{id}/enable | Enable a plugin.
-[**getPluginConfig**](PluginApi.md#getPluginConfig) | **GET** plugin/{id}/config | Get YAML configuration for Configurer plugin.
-[**getPluginDisplay**](PluginApi.md#getPluginDisplay) | **GET** plugin/{id}/display | Get display info for a Displayer plugin.
-[**getPlugins**](PluginApi.md#getPlugins) | **GET** plugin | Return all plugins.
-[**updatePluginConfig**](PluginApi.md#updatePluginConfig) | **POST** plugin/{id}/config | Update YAML configuration for Configurer plugin.
-
-
-# **disablePlugin**
-> Void disablePlugin(id)
-
-Disable a plugin.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.PluginApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-PluginApi apiInstance = new PluginApi();
-Long id = 789L; // Long | the plugin id
-try {
- Void result = apiInstance.disablePlugin(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling PluginApi#disablePlugin");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the plugin id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **enablePlugin**
-> Void enablePlugin(id)
-
-Enable a plugin.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.PluginApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-PluginApi apiInstance = new PluginApi();
-Long id = 789L; // Long | the plugin id
-try {
- Void result = apiInstance.enablePlugin(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling PluginApi#enablePlugin");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the plugin id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getPluginConfig**
-> Object getPluginConfig(id)
-
-Get YAML configuration for Configurer plugin.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.PluginApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-PluginApi apiInstance = new PluginApi();
-Long id = 789L; // Long | the plugin id
-try {
- Object result = apiInstance.getPluginConfig(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling PluginApi#getPluginConfig");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the plugin id |
-
-### Return type
-
-**Object**
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/x-yaml
-
-
-# **getPluginDisplay**
-> String getPluginDisplay(id)
-
-Get display info for a Displayer plugin.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.PluginApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-PluginApi apiInstance = new PluginApi();
-Long id = 789L; // Long | the plugin id
-try {
- String result = apiInstance.getPluginDisplay(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling PluginApi#getPluginDisplay");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the plugin id |
-
-### Return type
-
-**String**
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getPlugins**
-> List<PluginConf> getPlugins()
-
-Return all plugins.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.PluginApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-PluginApi apiInstance = new PluginApi();
-try {
- List result = apiInstance.getPlugins();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling PluginApi#getPlugins");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**List<PluginConf>**](PluginConf.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **updatePluginConfig**
-> Void updatePluginConfig(id)
-
-Update YAML configuration for Configurer plugin.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.PluginApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-PluginApi apiInstance = new PluginApi();
-Long id = 789L; // Long | the plugin id
-try {
- Void result = apiInstance.updatePluginConfig(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling PluginApi#updatePluginConfig");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the plugin id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
diff --git a/client/docs/PluginConf.md b/client/docs/PluginConf.md
deleted file mode 100644
index 64a8c1e2..00000000
--- a/client/docs/PluginConf.md
+++ /dev/null
@@ -1,14 +0,0 @@
-# PluginConf
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**author** | **String** | The author of the plugin. | [optional]
-**capabilities** | **List<String>** | Capabilities the plugin provides |
-**enabled** | **Boolean** | Whether the plugin instance is enabled. |
-**id** | **Long** | The plugin id. |
-**license** | **String** | The license of the plugin. | [optional]
-**modulePath** | **String** | The module path of the plugin. |
-**name** | **String** | The plugin name. |
-**token** | **String** | The user name. For login. |
-**website** | **String** | The website of the plugin. | [optional]
diff --git a/client/docs/UpdateUserExternal.md b/client/docs/UpdateUserExternal.md
deleted file mode 100644
index a88d819f..00000000
--- a/client/docs/UpdateUserExternal.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# UpdateUserExternal
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**admin** | **Boolean** | If the user is an administrator. |
-**name** | **String** | The user name. For login. |
-**pass** | **String** | The user password. For login. Empty for using old password | [optional]
diff --git a/client/docs/User.md b/client/docs/User.md
deleted file mode 100644
index 3a299613..00000000
--- a/client/docs/User.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# User
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**admin** | **Boolean** | If the user is an administrator. |
-**id** | **Long** | The user id. |
-**name** | **String** | The user name. For login. |
diff --git a/client/docs/UserApi.md b/client/docs/UserApi.md
deleted file mode 100644
index 9c7ec0a7..00000000
--- a/client/docs/UserApi.md
+++ /dev/null
@@ -1,493 +0,0 @@
-# UserApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**createUser**](UserApi.md#createUser) | **POST** user | Create a user.
-[**currentUser**](UserApi.md#currentUser) | **GET** current/user | Return the current user.
-[**deleteUser**](UserApi.md#deleteUser) | **DELETE** user/{id} | Deletes a user.
-[**getUser**](UserApi.md#getUser) | **GET** user/{id} | Get a user.
-[**getUsers**](UserApi.md#getUsers) | **GET** user | Return all users.
-[**updateCurrentUser**](UserApi.md#updateCurrentUser) | **POST** current/user/password | Update the password of the current user.
-[**updateUser**](UserApi.md#updateUser) | **POST** user/{id} | Update a user.
-
-
-# **createUser**
-> User createUser(body)
-
-Create a user.
-
-With enabled registration: non admin users can be created without authentication. With disabled registrations: users can only be created by admin users.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-CreateUserExternal body = new CreateUserExternal(); // CreateUserExternal | the user to add
-try {
- User result = apiInstance.createUser(body);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#createUser");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**CreateUserExternal**](CreateUserExternal.md)| the user to add |
-
-### Return type
-
-[**User**](User.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
-
-# **currentUser**
-> User currentUser()
-
-Return the current user.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-try {
- User result = apiInstance.currentUser();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#currentUser");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**User**](User.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **deleteUser**
-> Void deleteUser(id)
-
-Deletes a user.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-Long id = 789L; // Long | the user id
-try {
- Void result = apiInstance.deleteUser(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#deleteUser");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the user id |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getUser**
-> User getUser(id)
-
-Get a user.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-Long id = 789L; // Long | the user id
-try {
- User result = apiInstance.getUser(id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#getUser");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **id** | **Long**| the user id |
-
-### Return type
-
-[**User**](User.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **getUsers**
-> List<User> getUsers()
-
-Return all users.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-try {
- List result = apiInstance.getUsers();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#getUsers");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**List<User>**](User.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
-
-# **updateCurrentUser**
-> Void updateCurrentUser(body)
-
-Update the password of the current user.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-UserPass body = new UserPass(); // UserPass | the user
-try {
- Void result = apiInstance.updateCurrentUser(body);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#updateCurrentUser");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**UserPass**](UserPass.md)| the user |
-
-### Return type
-
-[**Void**](.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
-
-# **updateUser**
-> User updateUser(body, id)
-
-Update a user.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiClient;
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.Configuration;
-//import com.github.gotify.client.auth.*;
-//import com.github.gotify.client.api.UserApi;
-
-ApiClient defaultClient = Configuration.getDefaultApiClient();
-// Configure HTTP basic authorization: basicAuth
-HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
-basicAuth.setUsername("YOUR USERNAME");
-basicAuth.setPassword("YOUR PASSWORD");
-
-// Configure API key authorization: clientTokenAuthorizationHeader
-ApiKeyAuth clientTokenAuthorizationHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenAuthorizationHeader");
-clientTokenAuthorizationHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenAuthorizationHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenHeader
-ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
-clientTokenHeader.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenHeader.setApiKeyPrefix("Token");
-
-// Configure API key authorization: clientTokenQuery
-ApiKeyAuth clientTokenQuery = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenQuery");
-clientTokenQuery.setApiKey("YOUR API KEY");
-// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
-//clientTokenQuery.setApiKeyPrefix("Token");
-
-UserApi apiInstance = new UserApi();
-UpdateUserExternal body = new UpdateUserExternal(); // UpdateUserExternal | the updated user
-Long id = 789L; // Long | the user id
-try {
- User result = apiInstance.updateUser(body, id);
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling UserApi#updateUser");
- e.printStackTrace();
-}
-```
-
-### Parameters
-
-Name | Type | Description | Notes
-------------- | ------------- | ------------- | -------------
- **body** | [**UpdateUserExternal**](UpdateUserExternal.md)| the updated user |
- **id** | **Long**| the user id |
-
-### Return type
-
-[**User**](User.md)
-
-### Authorization
-
-[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
-
-### HTTP request headers
-
- - **Content-Type**: application/json
- - **Accept**: application/json
-
diff --git a/client/docs/UserPass.md b/client/docs/UserPass.md
deleted file mode 100644
index 1c396acc..00000000
--- a/client/docs/UserPass.md
+++ /dev/null
@@ -1,6 +0,0 @@
-# UserPass
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**pass** | **String** | The user password. For login. |
diff --git a/client/docs/VersionApi.md b/client/docs/VersionApi.md
deleted file mode 100644
index 9fd3b8d7..00000000
--- a/client/docs/VersionApi.md
+++ /dev/null
@@ -1,47 +0,0 @@
-# VersionApi
-
-All URIs are relative to *http://localhost/*
-
-Method | HTTP request | Description
-------------- | ------------- | -------------
-[**getVersion**](VersionApi.md#getVersion) | **GET** version | Get version information.
-
-
-# **getVersion**
-> VersionInfo getVersion()
-
-Get version information.
-
-### Example
-```java
-// Import classes:
-//import com.github.gotify.client.ApiException;
-//import com.github.gotify.client.api.VersionApi;
-
-
-VersionApi apiInstance = new VersionApi();
-try {
- VersionInfo result = apiInstance.getVersion();
- System.out.println(result);
-} catch (ApiException e) {
- System.err.println("Exception when calling VersionApi#getVersion");
- e.printStackTrace();
-}
-```
-
-### Parameters
-This endpoint does not need any parameter.
-
-### Return type
-
-[**VersionInfo**](VersionInfo.md)
-
-### Authorization
-
-No authorization required
-
-### HTTP request headers
-
- - **Content-Type**: Not defined
- - **Accept**: application/json
-
diff --git a/client/docs/VersionInfo.md b/client/docs/VersionInfo.md
deleted file mode 100644
index 19e205ac..00000000
--- a/client/docs/VersionInfo.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# VersionInfo
-
-## Properties
-Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
-**buildDate** | **String** | The date on which this binary was built. |
-**commit** | **String** | The git commit hash on which this binary was built. |
-**version** | **String** | The current version. |
diff --git a/client/git_push.sh b/client/git_push.sh
index ed374619..f53a75d4 100644
--- a/client/git_push.sh
+++ b/client/git_push.sh
@@ -1,11 +1,17 @@
#!/bin/sh
# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
#
-# Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update"
+# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com"
git_user_id=$1
git_repo_id=$2
release_note=$3
+git_host=$4
+
+if [ "$git_host" = "" ]; then
+ git_host="github.com"
+ echo "[INFO] No command line input provided. Set \$git_host to $git_host"
+fi
if [ "$git_user_id" = "" ]; then
git_user_id="GIT_USER_ID"
@@ -28,18 +34,18 @@ git init
# Adds the files in the local repository and stages them for commit.
git add .
-# Commits the tracked changes and prepares them to be pushed to a remote repository.
+# Commits the tracked changes and prepares them to be pushed to a remote repository.
git commit -m "$release_note"
# Sets the new remote
-git_remote=`git remote`
+git_remote=$(git remote)
if [ "$git_remote" = "" ]; then # git remote not defined
if [ "$GIT_TOKEN" = "" ]; then
- echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git crediential in your environment."
- git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git
+ echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
+ git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
else
- git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git
+ git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git
fi
fi
@@ -47,6 +53,5 @@ fi
git pull origin master
# Pushes (Forces) the changes in the local repository up to the remote repository
-echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git"
+echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
git push origin master 2>&1 | grep -v 'To https'
-
diff --git a/client/gradle.properties b/client/gradle.properties
index 05644f07..a3408578 100644
--- a/client/gradle.properties
+++ b/client/gradle.properties
@@ -1,2 +1,6 @@
-# Uncomment to build for Android
-#target = android
\ No newline at end of file
+# 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/client/gradle/wrapper/gradle-wrapper.jar b/client/gradle/wrapper/gradle-wrapper.jar
deleted file mode 100644
index d64cd491..00000000
Binary files a/client/gradle/wrapper/gradle-wrapper.jar and /dev/null differ
diff --git a/client/gradle/wrapper/gradle-wrapper.properties b/client/gradle/wrapper/gradle-wrapper.properties
deleted file mode 100644
index 1af9e093..00000000
--- a/client/gradle/wrapper/gradle-wrapper.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-distributionBase=GRADLE_USER_HOME
-distributionPath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
-networkTimeout=10000
-validateDistributionUrl=true
-zipStoreBase=GRADLE_USER_HOME
-zipStorePath=wrapper/dists
diff --git a/client/gradlew b/client/gradlew
deleted file mode 100644
index 9d82f789..00000000
--- a/client/gradlew
+++ /dev/null
@@ -1,160 +0,0 @@
-#!/usr/bin/env bash
-
-##############################################################################
-##
-## Gradle start up script for UN*X
-##
-##############################################################################
-
-# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-DEFAULT_JVM_OPTS=""
-
-APP_NAME="Gradle"
-APP_BASE_NAME=`basename "$0"`
-
-# Use the maximum available, or set MAX_FD != -1 to use that value.
-MAX_FD="maximum"
-
-warn ( ) {
- echo "$*"
-}
-
-die ( ) {
- echo
- echo "$*"
- echo
- exit 1
-}
-
-# OS specific support (must be 'true' or 'false').
-cygwin=false
-msys=false
-darwin=false
-case "`uname`" in
- CYGWIN* )
- cygwin=true
- ;;
- Darwin* )
- darwin=true
- ;;
- MINGW* )
- msys=true
- ;;
-esac
-
-# Attempt to set APP_HOME
-# Resolve links: $0 may be a link
-PRG="$0"
-# Need this for relative symlinks.
-while [ -h "$PRG" ] ; do
- ls=`ls -ld "$PRG"`
- link=`expr "$ls" : '.*-> \(.*\)$'`
- if expr "$link" : '/.*' > /dev/null; then
- PRG="$link"
- else
- PRG=`dirname "$PRG"`"/$link"
- fi
-done
-SAVED="`pwd`"
-cd "`dirname \"$PRG\"`/" >/dev/null
-APP_HOME="`pwd -P`"
-cd "$SAVED" >/dev/null
-
-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"
- which java >/dev/null 2>&1 || 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
-
-# Increase the maximum file descriptors if we can.
-if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
- MAX_FD_LIMIT=`ulimit -H -n`
- if [ $? -eq 0 ] ; then
- if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
- MAX_FD="$MAX_FD_LIMIT"
- fi
- ulimit -n $MAX_FD
- if [ $? -ne 0 ] ; then
- warn "Could not set maximum file descriptor limit: $MAX_FD"
- fi
- else
- warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
- fi
-fi
-
-# For Darwin, add options to specify how the application appears in the dock
-if $darwin; then
- GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
-fi
-
-# For Cygwin, switch paths to Windows format before running java
-if $cygwin ; then
- APP_HOME=`cygpath --path --mixed "$APP_HOME"`
- CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
- JAVACMD=`cygpath --unix "$JAVACMD"`
-
- # We build the pattern for arguments to be converted via cygpath
- ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
- SEP=""
- for dir in $ROOTDIRSRAW ; do
- ROOTDIRS="$ROOTDIRS$SEP$dir"
- SEP="|"
- done
- OURCYGPATTERN="(^($ROOTDIRS))"
- # Add a user-defined pattern to the cygpath arguments
- if [ "$GRADLE_CYGPATTERN" != "" ] ; then
- OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
- fi
- # Now convert the arguments - kludge to limit ourselves to /bin/sh
- i=0
- for arg in "$@" ; do
- CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
- CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
-
- if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
- eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
- else
- eval `echo args$i`="\"$arg\""
- fi
- i=$((i+1))
- done
- case $i in
- (0) set -- ;;
- (1) set -- "$args0" ;;
- (2) set -- "$args0" "$args1" ;;
- (3) set -- "$args0" "$args1" "$args2" ;;
- (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
- (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
- (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
- (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
- (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
- (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
- esac
-fi
-
-# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
-function splitJvmOpts() {
- JVM_OPTS=("$@")
-}
-eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
-JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
-
-exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
diff --git a/client/gradlew.bat b/client/gradlew.bat
deleted file mode 100644
index 5f192121..00000000
--- a/client/gradlew.bat
+++ /dev/null
@@ -1,90 +0,0 @@
-@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
-
-@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=
-
-set DIRNAME=%~dp0
-if "%DIRNAME%" == "" set DIRNAME=.
-set APP_BASE_NAME=%~n0
-set APP_HOME=%DIRNAME%
-
-@rem Find java.exe
-if defined JAVA_HOME goto findJavaFromJavaHome
-
-set JAVA_EXE=java.exe
-%JAVA_EXE% -version >NUL 2>&1
-if "%ERRORLEVEL%" == "0" goto init
-
-echo.
-echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
-echo.
-echo Please set the JAVA_HOME variable in your environment to match the
-echo location of your Java installation.
-
-goto fail
-
-:findJavaFromJavaHome
-set JAVA_HOME=%JAVA_HOME:"=%
-set JAVA_EXE=%JAVA_HOME%/bin/java.exe
-
-if exist "%JAVA_EXE%" goto init
-
-echo.
-echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
-echo.
-echo Please set the JAVA_HOME variable in your environment to match the
-echo location of your Java installation.
-
-goto fail
-
-:init
-@rem Get command-line arguments, handling Windows variants
-
-if not "%OS%" == "Windows_NT" goto win9xME_args
-if "%@eval[2+2]" == "4" goto 4NT_args
-
-:win9xME_args
-@rem Slurp the command line arguments.
-set CMD_LINE_ARGS=
-set _SKIP=2
-
-:win9xME_args_slurp
-if "x%~1" == "x" goto execute
-
-set CMD_LINE_ARGS=%*
-goto execute
-
-:4NT_args
-@rem Get arguments from the 4NT Shell from JP Software
-set CMD_LINE_ARGS=%$
-
-: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 %CMD_LINE_ARGS%
-
-:end
-@rem End local scope for the variables with windows NT shell
-if "%ERRORLEVEL%"=="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!
-if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
-exit /b 1
-
-:mainEnd
-if "%OS%"=="Windows_NT" endlocal
-
-:omega
diff --git a/client/pom.xml b/client/pom.xml
deleted file mode 100644
index ca79f7bc..00000000
--- a/client/pom.xml
+++ /dev/null
@@ -1,244 +0,0 @@
-
- 4.0.0
- io.swagger
- swagger-java-client
- jar
- swagger-java-client
- 1.0.0
- https://github.com/swagger-api/swagger-codegen
- Swagger Java
-
- scm:git:git@github.com:swagger-api/swagger-codegen.git
- scm:git:git@github.com:swagger-api/swagger-codegen.git
- https://github.com/swagger-api/swagger-codegen
-
-
- 2.2.0
-
-
-
-
- Unlicense
- https://github.com/gotify/server/blob/master/LICENSE
- repo
-
-
-
-
-
- Swagger
- apiteam@swagger.io
- Swagger
- http://swagger.io
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-surefire-plugin
- 2.12
-
-
-
- loggerPath
- conf/log4j.properties
-
-
- -Xms512m -Xmx1500m
- methods
- pertest
-
-
-
- maven-dependency-plugin
-
-
- package
-
- copy-dependencies
-
-
- ${project.build.directory}/lib
-
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-jar-plugin
- 2.2
-
-
-
- jar
- test-jar
-
-
-
-
-
-
-
-
- org.codehaus.mojo
- build-helper-maven-plugin
- 1.10
-
-
- 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.2.0
-
-
- attach-javadocs
-
- jar
-
-
-
-
-
- org.apache.maven.plugins
- maven-source-plugin
- 2.2.1
-
-
- attach-sources
-
- jar-no-fork
-
-
-
-
-
-
-
-
-
- sign-artifacts
-
-
-
- org.apache.maven.plugins
- maven-gpg-plugin
- 1.5
-
-
- sign-artifacts
- verify
-
- sign
-
-
-
-
-
-
-
-
- jdk11
-
- [11,)
-
-
-
- com.sun.xml.ws
- jaxws-rt
- 2.3.3
- pom
-
-
-
-
-
-
-
- io.swagger.core.v3
- swagger-annotations
- ${swagger-core-version}
-
-
- com.squareup.retrofit2
- converter-gson
- ${retrofit-version}
-
-
- com.squareup.retrofit2
- retrofit
- ${retrofit-version}
-
-
- com.squareup.retrofit2
- converter-scalars
- ${retrofit-version}
-
-
- org.apache.oltu.oauth2
- org.apache.oltu.oauth2.client
- ${oltu-version}
-
-
- io.gsonfire
- gson-fire
- ${gson-fire-version}
-
-
- org.threeten
- threetenbp
- ${threetenbp-version}
-
-
-
-
-
-
- junit
- junit
- ${junit-version}
- test
-
-
-
- UTF-8
- 11
- ${java.version}
- ${java.version}
- 1.8.0
- 2.0.0
- 2.3.0
- 1.3.5
- 1.0.2
- 4.13.1
-
-
diff --git a/client/src/main/java/com/github/gotify/client/ApiClient.java b/client/src/main/java/com/github/gotify/client/ApiClient.java
index 8f7e13cf..6c5ba520 100644
--- a/client/src/main/java/com/github/gotify/client/ApiClient.java
+++ b/client/src/main/java/com/github/gotify/client/ApiClient.java
@@ -1,3 +1,16 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
package com.github.gotify.client;
import com.google.gson.Gson;
@@ -7,37 +20,41 @@
import okhttp3.OkHttpClient;
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
-import org.apache.oltu.oauth2.client.request.OAuthClientRequest.AuthenticationRequestBuilder;
-import org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder;
-import org.threeten.bp.format.DateTimeFormatter;
import retrofit2.Converter;
import retrofit2.Retrofit;
import retrofit2.converter.gson.GsonConverterFactory;
import retrofit2.converter.scalars.ScalarsConverterFactory;
import com.github.gotify.client.auth.HttpBasicAuth;
+import com.github.gotify.client.auth.HttpBearerAuth;
import com.github.gotify.client.auth.ApiKeyAuth;
-import com.github.gotify.client.auth.OAuth;
-import com.github.gotify.client.auth.OAuth.AccessTokenListener;
-import com.github.gotify.client.auth.OAuthFlow;
import java.io.IOException;
import java.lang.annotation.Annotation;
import java.lang.reflect.Type;
import java.text.DateFormat;
+import java.time.format.DateTimeFormatter;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.HashMap;
public class ApiClient {
- private Map apiAuthorizations;
- private OkHttpClient.Builder okBuilder;
- private Retrofit.Builder adapterBuilder;
- private JSON json;
+ protected Map apiAuthorizations;
+ protected OkHttpClient.Builder okBuilder;
+ protected Retrofit.Builder adapterBuilder;
+ protected JSON json;
+ protected OkHttpClient okHttpClient;
public ApiClient() {
apiAuthorizations = new LinkedHashMap();
createDefaultAdapter();
+ okBuilder = new OkHttpClient.Builder();
+ }
+
+ public ApiClient(OkHttpClient client){
+ apiAuthorizations = new LinkedHashMap();
+ createDefaultAdapter();
+ okHttpClient = client;
}
public ApiClient(String[] authNames) {
@@ -52,7 +69,7 @@ public ApiClient(String[] authNames) {
auth = new ApiKeyAuth("query", "token");
} else if ("basicAuth".equals(authName)) {
auth = new HttpBasicAuth();
- } else if ("clientTokenAuthorizationHeader".equals(authName)) {
+ } else if ("clientTokenAuthorizationHeader".equals(authName)) {
auth = new ApiKeyAuth("header", "Authorization");
} else if ("clientTokenHeader".equals(authName)) {
auth = new ApiKeyAuth("header", "X-Gotify-Key");
@@ -61,8 +78,9 @@ public ApiClient(String[] authNames) {
} else {
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
}
-
- addAuthorization(authName, auth);
+ if (auth != null) {
+ addAuthorization(authName, auth);
+ }
}
}
@@ -95,28 +113,10 @@ public ApiClient(String authName, String username, String password) {
this.setCredentials(username, password);
}
- /**
- * Helper constructor for single password oauth2
- * @param authName Authentication name
- * @param clientId Client ID
- * @param secret Client Secret
- * @param username Username
- * @param password Password
- */
- public ApiClient(String authName, String clientId, String secret, String username, String password) {
- this(authName);
- this.getTokenEndPoint()
- .setClientId(clientId)
- .setClientSecret(secret)
- .setUsername(username)
- .setPassword(password);
- }
-
public void createDefaultAdapter() {
json = new JSON();
- okBuilder = new OkHttpClient.Builder();
- String baseUrl = "http://localhost/";
+ String baseUrl = "http://localhost";
if (!baseUrl.endsWith("/"))
baseUrl = baseUrl + "/";
@@ -128,10 +128,11 @@ public void createDefaultAdapter() {
}
public S createService(Class serviceClass) {
- return adapterBuilder
- .client(okBuilder.build())
- .build()
- .create(serviceClass);
+ if (okHttpClient != null) {
+ return adapterBuilder.client(okHttpClient).build().create(serviceClass);
+ } else {
+ return adapterBuilder.client(okBuilder.build()).build().create(serviceClass);
+ }
}
public ApiClient setDateFormat(DateFormat dateFormat) {
@@ -172,65 +173,14 @@ public ApiClient setApiKey(String apiKey) {
}
/**
- * Helper method to configure the username/password for basic auth or password oauth
- * @param username Username
- * @param password Password
- * @return ApiClient
- */
- public ApiClient setCredentials(String username, String password) {
- for(Interceptor apiAuthorization : apiAuthorizations.values()) {
- if (apiAuthorization instanceof HttpBasicAuth) {
- HttpBasicAuth basicAuth = (HttpBasicAuth) apiAuthorization;
- basicAuth.setCredentials(username, password);
- return this;
- }
- if (apiAuthorization instanceof OAuth) {
- OAuth oauth = (OAuth) apiAuthorization;
- oauth.getTokenRequestBuilder().setUsername(username).setPassword(password);
- return this;
- }
- }
- return this;
- }
-
- /**
- * Helper method to configure the token endpoint of the first oauth found in the apiAuthorizations (there should be only one)
- * @return Token request builder
- */
- public TokenRequestBuilder getTokenEndPoint() {
- for(Interceptor apiAuthorization : apiAuthorizations.values()) {
- if (apiAuthorization instanceof OAuth) {
- OAuth oauth = (OAuth) apiAuthorization;
- return oauth.getTokenRequestBuilder();
- }
- }
- return null;
- }
-
- /**
- * Helper method to configure authorization endpoint of the first oauth found in the apiAuthorizations (there should be only one)
- * @return Authentication request builder
- */
- public AuthenticationRequestBuilder getAuthorizationEndPoint() {
- for(Interceptor apiAuthorization : apiAuthorizations.values()) {
- if (apiAuthorization instanceof OAuth) {
- OAuth oauth = (OAuth) apiAuthorization;
- return oauth.getAuthenticationRequestBuilder();
- }
- }
- return null;
- }
-
- /**
- * Helper method to pre-set the oauth access token of the first oauth found in the apiAuthorizations (there should be only one)
- * @param accessToken Access token
+ * Helper method to set token for the first Http Bearer authentication found.
+ * @param bearerToken Bearer token
* @return ApiClient
*/
- public ApiClient setAccessToken(String accessToken) {
- for(Interceptor apiAuthorization : apiAuthorizations.values()) {
- if (apiAuthorization instanceof OAuth) {
- OAuth oauth = (OAuth) apiAuthorization;
- oauth.setAccessToken(accessToken);
+ public ApiClient setBearerToken(String bearerToken) {
+ for (Interceptor apiAuthorization : apiAuthorizations.values()) {
+ if (apiAuthorization instanceof HttpBearerAuth) {
+ ((HttpBearerAuth) apiAuthorization).setBearerToken(bearerToken);
return this;
}
}
@@ -238,44 +188,22 @@ public ApiClient setAccessToken(String accessToken) {
}
/**
- * Helper method to configure the oauth accessCode/implicit flow parameters
- * @param clientId Client ID
- * @param clientSecret Client secret
- * @param redirectURI Redirect URI
+ * Helper method to configure the username/password for basic auth or password oauth
+ * @param username Username
+ * @param password Password
* @return ApiClient
*/
- public ApiClient configureAuthorizationFlow(String clientId, String clientSecret, String redirectURI) {
+ public ApiClient setCredentials(String username, String password) {
for(Interceptor apiAuthorization : apiAuthorizations.values()) {
- if (apiAuthorization instanceof OAuth) {
- OAuth oauth = (OAuth) apiAuthorization;
- oauth.getTokenRequestBuilder()
- .setClientId(clientId)
- .setClientSecret(clientSecret)
- .setRedirectURI(redirectURI);
- oauth.getAuthenticationRequestBuilder()
- .setClientId(clientId)
- .setRedirectURI(redirectURI);
+ if (apiAuthorization instanceof HttpBasicAuth) {
+ HttpBasicAuth basicAuth = (HttpBasicAuth) apiAuthorization;
+ basicAuth.setCredentials(username, password);
return this;
}
}
return this;
}
- /**
- * Configures a listener which is notified when a new access token is received.
- * @param accessTokenListener Access token listener
- * @return ApiClient
- */
- public ApiClient registerAccessTokenListener(AccessTokenListener accessTokenListener) {
- for(Interceptor apiAuthorization : apiAuthorizations.values()) {
- if (apiAuthorization instanceof OAuth) {
- OAuth oauth = (OAuth) apiAuthorization;
- oauth.registerAccessTokenListener(accessTokenListener);
- return this;
- }
- }
- return this;
- }
/**
* Adds an authorization to be used by the client
@@ -288,7 +216,11 @@ public ApiClient addAuthorization(String authName, Interceptor authorization) {
throw new RuntimeException("auth name \"" + authName + "\" already in api authorizations");
}
apiAuthorizations.put(authName, authorization);
+ if(okBuilder == null){
+ throw new RuntimeException("The ApiClient was created with a built OkHttpClient so it's not possible to add an authorization interceptor to it");
+ }
okBuilder.addInterceptor(authorization);
+
return this;
}
@@ -336,8 +268,8 @@ public void configureFromOkclient(OkHttpClient okClient) {
* expected type is String, then just return the body string.
*/
class GsonResponseBodyConverterToString implements Converter {
- private final Gson gson;
- private final Type type;
+ protected final Gson gson;
+ protected final Type type;
GsonResponseBodyConverterToString(Gson gson, Type type) {
this.gson = gson;
@@ -357,14 +289,14 @@ class GsonResponseBodyConverterToString implements Converter
class GsonCustomConverterFactory extends Converter.Factory
{
- private final Gson gson;
- private final GsonConverterFactory gsonConverterFactory;
+ protected final Gson gson;
+ protected final GsonConverterFactory gsonConverterFactory;
public static GsonCustomConverterFactory create(Gson gson) {
return new GsonCustomConverterFactory(gson);
}
- private GsonCustomConverterFactory(Gson gson) {
+ protected GsonCustomConverterFactory(Gson gson) {
if (gson == null)
throw new NullPointerException("gson == null");
this.gson = gson;
diff --git a/client/src/main/java/com/github/gotify/client/CollectionFormats.java b/client/src/main/java/com/github/gotify/client/CollectionFormats.java
index 59425173..3177dd0a 100644
--- a/client/src/main/java/com/github/gotify/client/CollectionFormats.java
+++ b/client/src/main/java/com/github/gotify/client/CollectionFormats.java
@@ -1,3 +1,16 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
package com.github.gotify.client;
import java.util.Arrays;
@@ -35,6 +48,10 @@ public String toString() {
}
+ public static class SPACEParams extends SSVParams {
+
+ }
+
public static class SSVParams extends CSVParams {
public SSVParams() {
diff --git a/client/src/main/java/com/github/gotify/client/JSON.java b/client/src/main/java/com/github/gotify/client/JSON.java
index 40dc7d07..deb5e16a 100644
--- a/client/src/main/java/com/github/gotify/client/JSON.java
+++ b/client/src/main/java/com/github/gotify/client/JSON.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client;
import com.google.gson.Gson;
@@ -22,9 +23,6 @@
import com.google.gson.JsonElement;
import io.gsonfire.GsonFireBuilder;
import io.gsonfire.TypeSelector;
-import org.threeten.bp.LocalDate;
-import org.threeten.bp.OffsetDateTime;
-import org.threeten.bp.format.DateTimeFormatter;
import com.github.gotify.client.model.*;
@@ -34,7 +32,11 @@
import java.text.DateFormat;
import java.text.ParseException;
import java.text.ParsePosition;
+import java.time.LocalDate;
+import java.time.OffsetDateTime;
+import java.time.format.DateTimeFormatter;
import java.util.Date;
+import java.util.Locale;
import java.util.Map;
import java.util.HashMap;
@@ -47,6 +49,7 @@ public class JSON {
public static GsonBuilder createGson() {
GsonFireBuilder fireBuilder = new GsonFireBuilder()
+
;
return fireBuilder.createGsonBuilder();
}
@@ -60,7 +63,7 @@ private static String getDiscriminatorValue(JsonElement readElement, String disc
}
private static Class getClassByDiscriminator(Map classByDiscriminatorValue, String discriminatorValue) {
- Class clazz = (Class) classByDiscriminatorValue.get(discriminatorValue.toUpperCase());
+ Class clazz = (Class) classByDiscriminatorValue.get(discriminatorValue.toUpperCase(Locale.ROOT));
if(null == clazz) {
throw new IllegalArgumentException("cannot determine model class of name: <" + discriminatorValue + ">");
}
diff --git a/client/src/main/java/com/github/gotify/client/ServerConfiguration.java b/client/src/main/java/com/github/gotify/client/ServerConfiguration.java
new file mode 100644
index 00000000..f2ea4980
--- /dev/null
+++ b/client/src/main/java/com/github/gotify/client/ServerConfiguration.java
@@ -0,0 +1,72 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
+package com.github.gotify.client;
+
+import java.util.Map;
+
+/**
+ * Representing a Server configuration.
+ */
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
+public class ServerConfiguration {
+ public String URL;
+ public String description;
+ public Map variables;
+
+ /**
+ * @param URL A URL to the target host.
+ * @param description A description of the host designated by the URL.
+ * @param variables A map between a variable name and its value. The value is used for substitution in the server's URL template.
+ */
+ public ServerConfiguration(String URL, String description, Map variables) {
+ this.URL = URL;
+ this.description = description;
+ this.variables = variables;
+ }
+
+ /**
+ * Format URL template using given variables.
+ *
+ * @param variables A map between a variable name and its value.
+ * @return Formatted URL.
+ */
+ public String URL(Map variables) {
+ String url = this.URL;
+
+ // go through variables and replace placeholders
+ for (Map.Entry variable: this.variables.entrySet()) {
+ String name = variable.getKey();
+ ServerVariable serverVariable = variable.getValue();
+ String value = serverVariable.defaultValue;
+
+ if (variables != null && variables.containsKey(name)) {
+ value = variables.get(name);
+ if (serverVariable.enumValues.size() > 0 && !serverVariable.enumValues.contains(value)) {
+ throw new IllegalArgumentException("The variable " + name + " in the server URL has invalid value " + value + ".");
+ }
+ }
+ url = url.replace("{" + name + "}", value);
+ }
+ return url;
+ }
+
+ /**
+ * Format URL template using default server variables.
+ *
+ * @return Formatted URL.
+ */
+ public String URL() {
+ return URL(null);
+ }
+}
diff --git a/client/src/main/java/com/github/gotify/client/ServerVariable.java b/client/src/main/java/com/github/gotify/client/ServerVariable.java
new file mode 100644
index 00000000..59b50c07
--- /dev/null
+++ b/client/src/main/java/com/github/gotify/client/ServerVariable.java
@@ -0,0 +1,37 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
+package com.github.gotify.client;
+
+import java.util.HashSet;
+
+/**
+ * Representing a Server Variable for server URL template substitution.
+ */
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
+public class ServerVariable {
+ public String description;
+ public String defaultValue;
+ public HashSet enumValues = null;
+
+ /**
+ * @param description A description for the server variable.
+ * @param defaultValue The default value to use for substitution.
+ * @param enumValues An enumeration of string values to be used if the substitution options are from a limited set.
+ */
+ public ServerVariable(String description, String defaultValue, HashSet enumValues) {
+ this.description = description;
+ this.defaultValue = defaultValue;
+ this.enumValues = enumValues;
+ }
+}
diff --git a/client/src/main/java/com/github/gotify/client/StringUtil.java b/client/src/main/java/com/github/gotify/client/StringUtil.java
index 4e134639..b3ba95b4 100644
--- a/client/src/main/java/com/github/gotify/client/StringUtil.java
+++ b/client/src/main/java/com/github/gotify/client/StringUtil.java
@@ -2,17 +2,21 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client;
+import java.util.Collection;
+import java.util.Iterator;
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class StringUtil {
/**
* Check if the given array contains the given value (with case-insensitive comparison).
@@ -23,8 +27,12 @@ public class StringUtil {
*/
public static boolean containsIgnoreCase(String[] array, String value) {
for (String str : array) {
- if (value == null && str == null) return true;
- if (value != null && value.equalsIgnoreCase(str)) return true;
+ if (value == null && str == null) {
+ return true;
+ }
+ if (value != null && value.equalsIgnoreCase(str)) {
+ return true;
+ }
}
return false;
}
@@ -42,7 +50,9 @@ public static boolean containsIgnoreCase(String[] array, String value) {
*/
public static String join(String[] array, String separator) {
int len = array.length;
- if (len == 0) return "";
+ if (len == 0) {
+ return "";
+ }
StringBuilder out = new StringBuilder();
out.append(array[0]);
@@ -51,4 +61,23 @@ public static String join(String[] array, String separator) {
}
return out.toString();
}
+
+ /**
+ * Join a list of strings with the given separator.
+ *
+ * @param list The list of strings
+ * @param separator The separator
+ * @return the resulting string
+ */
+ public static String join(Collection list, String separator) {
+ Iterator iterator = list.iterator();
+ StringBuilder out = new StringBuilder();
+ if (iterator.hasNext()) {
+ out.append(iterator.next());
+ }
+ while (iterator.hasNext()) {
+ out.append(separator).append(iterator.next());
+ }
+ return out.toString();
+ }
}
diff --git a/client/src/main/java/com/github/gotify/client/api/ApplicationApi.java b/client/src/main/java/com/github/gotify/client/api/ApplicationApi.java
index 1e983e04..1ca29567 100644
--- a/client/src/main/java/com/github/gotify/client/api/ApplicationApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/ApplicationApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.Application;
import com.github.gotify.client.model.ApplicationParams;
@@ -17,6 +18,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface ApplicationApi {
/**
@@ -67,8 +69,8 @@ Call removeAppImage(
/**
* Update an application.
*
- * @param body the application to update (required)
* @param id the application id (required)
+ * @param body the application to update (required)
* @return Call<Application>
*/
@Headers({
@@ -76,20 +78,20 @@ Call removeAppImage(
})
@PUT("application/{id}")
Call updateApplication(
- @retrofit2.http.Body ApplicationParams body, @retrofit2.http.Path("id") Long id
+ @retrofit2.http.Path("id") Long id, @retrofit2.http.Body ApplicationParams body
);
/**
* Upload an image for an application.
*
- * @param file (required)
* @param id the application id (required)
+ * @param _file the application image (required)
* @return Call<Application>
*/
@retrofit2.http.Multipart
@POST("application/{id}/image")
Call uploadAppImage(
- @retrofit2.http.Part("file\"; filename=\"file") RequestBody file, @retrofit2.http.Path("id") Long id
+ @retrofit2.http.Path("id") Long id, @retrofit2.http.Part MultipartBody.Part _file
);
}
diff --git a/client/src/main/java/com/github/gotify/client/api/ClientApi.java b/client/src/main/java/com/github/gotify/client/api/ClientApi.java
index 66b12cb4..d4bb4acf 100644
--- a/client/src/main/java/com/github/gotify/client/api/ClientApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/ClientApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.Client;
import com.github.gotify.client.model.ClientParams;
@@ -16,6 +17,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface ClientApi {
/**
@@ -55,8 +57,8 @@ Call deleteClient(
/**
* Update a client.
*
- * @param body the client to update (required)
* @param id the client id (required)
+ * @param body the client to update (required)
* @return Call<Client>
*/
@Headers({
@@ -64,7 +66,7 @@ Call deleteClient(
})
@PUT("client/{id}")
Call updateClient(
- @retrofit2.http.Body ClientParams body, @retrofit2.http.Path("id") Long id
+ @retrofit2.http.Path("id") Long id, @retrofit2.http.Body ClientParams body
);
}
diff --git a/client/src/main/java/com/github/gotify/client/api/HealthApi.java b/client/src/main/java/com/github/gotify/client/api/HealthApi.java
index 8757825f..2e1510c3 100644
--- a/client/src/main/java/com/github/gotify/client/api/HealthApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/HealthApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.Health;
@@ -14,6 +15,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface HealthApi {
/**
diff --git a/client/src/main/java/com/github/gotify/client/api/MessageApi.java b/client/src/main/java/com/github/gotify/client/api/MessageApi.java
index ba567347..1c2bd33c 100644
--- a/client/src/main/java/com/github/gotify/client/api/MessageApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/MessageApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.Error;
import com.github.gotify.client.model.Message;
@@ -16,6 +17,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface MessageApi {
/**
diff --git a/client/src/main/java/com/github/gotify/client/api/PluginApi.java b/client/src/main/java/com/github/gotify/client/api/PluginApi.java
index 94717de5..3b4b2e93 100644
--- a/client/src/main/java/com/github/gotify/client/api/PluginApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/PluginApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.Error;
import com.github.gotify.client.model.PluginConf;
@@ -15,6 +16,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface PluginApi {
/**
diff --git a/client/src/main/java/com/github/gotify/client/api/UserApi.java b/client/src/main/java/com/github/gotify/client/api/UserApi.java
index 5f38b284..22581861 100644
--- a/client/src/main/java/com/github/gotify/client/api/UserApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/UserApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.CreateUserExternal;
import com.github.gotify.client.model.Error;
@@ -18,6 +19,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface UserApi {
/**
@@ -91,8 +93,8 @@ Call updateCurrentUser(
/**
* Update a user.
*
- * @param body the updated user (required)
* @param id the user id (required)
+ * @param body the updated user (required)
* @return Call<User>
*/
@Headers({
@@ -100,7 +102,7 @@ Call updateCurrentUser(
})
@POST("user/{id}")
Call updateUser(
- @retrofit2.http.Body UpdateUserExternal body, @retrofit2.http.Path("id") Long id
+ @retrofit2.http.Path("id") Long id, @retrofit2.http.Body UpdateUserExternal body
);
}
diff --git a/client/src/main/java/com/github/gotify/client/api/VersionApi.java b/client/src/main/java/com/github/gotify/client/api/VersionApi.java
index 7fd66aa4..8e26cf1b 100644
--- a/client/src/main/java/com/github/gotify/client/api/VersionApi.java
+++ b/client/src/main/java/com/github/gotify/client/api/VersionApi.java
@@ -7,6 +7,7 @@
import okhttp3.RequestBody;
import okhttp3.ResponseBody;
+import okhttp3.MultipartBody;
import com.github.gotify.client.model.VersionInfo;
@@ -14,6 +15,7 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import java.util.Set;
public interface VersionApi {
/**
diff --git a/client/src/main/java/com/github/gotify/client/auth/ApiKeyAuth.java b/client/src/main/java/com/github/gotify/client/auth/ApiKeyAuth.java
index 82cbd774..15b6c61c 100644
--- a/client/src/main/java/com/github/gotify/client/auth/ApiKeyAuth.java
+++ b/client/src/main/java/com/github/gotify/client/auth/ApiKeyAuth.java
@@ -1,3 +1,16 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
package com.github.gotify.client.auth;
import java.io.IOException;
@@ -62,6 +75,10 @@ public Response intercept(Chain chain) throws IOException {
request = request.newBuilder()
.addHeader(paramName, apiKey)
.build();
+ } else if ("cookie".equals(location)) {
+ request = request.newBuilder()
+ .addHeader("Cookie", String.format(java.util.Locale.ROOT, "%s=%s", paramName, apiKey))
+ .build();
}
return chain.proceed(request);
}
diff --git a/client/src/main/java/com/github/gotify/client/auth/HttpBasicAuth.java b/client/src/main/java/com/github/gotify/client/auth/HttpBasicAuth.java
index 8b78eddd..e1a54cdc 100644
--- a/client/src/main/java/com/github/gotify/client/auth/HttpBasicAuth.java
+++ b/client/src/main/java/com/github/gotify/client/auth/HttpBasicAuth.java
@@ -1,3 +1,16 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
package com.github.gotify.client.auth;
import java.io.IOException;
@@ -12,7 +25,7 @@ public class HttpBasicAuth implements Interceptor {
private String username;
private String password;
-
+
public String getUsername() {
return username;
}
diff --git a/client/src/main/java/com/github/gotify/client/auth/HttpBearerAuth.java b/client/src/main/java/com/github/gotify/client/auth/HttpBearerAuth.java
new file mode 100644
index 00000000..77ad8f54
--- /dev/null
+++ b/client/src/main/java/com/github/gotify/client/auth/HttpBearerAuth.java
@@ -0,0 +1,55 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
+package com.github.gotify.client.auth;
+
+import java.io.IOException;
+
+import okhttp3.Interceptor;
+import okhttp3.Request;
+import okhttp3.Response;
+
+public class HttpBearerAuth implements Interceptor {
+ private final String scheme;
+ private String bearerToken;
+
+ public HttpBearerAuth(String scheme) {
+ this.scheme = scheme;
+ }
+
+ public String getBearerToken() {
+ return bearerToken;
+ }
+
+ public void setBearerToken(String bearerToken) {
+ this.bearerToken = bearerToken;
+ }
+
+ @Override
+ public Response intercept(Chain chain) throws IOException {
+ Request request = chain.request();
+
+ // If the request already have an authorization (eg. Basic auth), do nothing
+ if (request.header("Authorization") == null && bearerToken != null) {
+ request = request.newBuilder()
+ .addHeader("Authorization", (scheme != null ? upperCaseBearer(scheme) + " " : "") + bearerToken)
+ .build();
+ }
+ return chain.proceed(request);
+ }
+
+ private static String upperCaseBearer(String scheme) {
+ return ("bearer".equalsIgnoreCase(scheme)) ? "Bearer" : scheme;
+ }
+
+}
diff --git a/client/src/main/java/com/github/gotify/client/auth/OAuthOkHttpClient.java b/client/src/main/java/com/github/gotify/client/auth/OAuthOkHttpClient.java
index c4a77819..326132a9 100644
--- a/client/src/main/java/com/github/gotify/client/auth/OAuthOkHttpClient.java
+++ b/client/src/main/java/com/github/gotify/client/auth/OAuthOkHttpClient.java
@@ -1,3 +1,16 @@
+/*
+ * Gotify REST-API.
+ * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
+ *
+ * The version of the OpenAPI document: 2.0.2
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
package com.github.gotify.client.auth;
import java.io.IOException;
@@ -56,10 +69,9 @@ public T execute(OAuthClientRequest request, Map
try {
Response response = client.newCall(requestBuilder.build()).execute();
return OAuthClientResponseFactory.createCustomResponse(
- response.body().string(),
+ response.body().string(),
response.body().contentType().toString(),
response.code(),
- response.headers().toMultimap(),
responseClass);
} catch (IOException e) {
throw new OAuthSystemException(e);
diff --git a/client/src/main/java/com/github/gotify/client/model/Application.java b/client/src/main/java/com/github/gotify/client/model/Application.java
index 13729eb4..6575b9f8 100644
--- a/client/src/main/java/com/github/gotify/client/model/Application.java
+++ b/client/src/main/java/com/github/gotify/client/model/Application.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,142 +20,226 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
-import org.threeten.bp.OffsetDateTime;
+import java.time.OffsetDateTime;
+
/**
* The Application holds information about an app which can send notifications.
*/
-@Schema(description = "The Application holds information about an app which can send notifications.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class Application {
- @SerializedName("defaultPriority")
- private Long defaultPriority = null;
-
- @SerializedName("description")
- private String description = null;
-
- @SerializedName("id")
- private Long id = null;
-
- @SerializedName("image")
- private String image = null;
-
- @SerializedName("internal")
- private Boolean internal = null;
-
- @SerializedName("lastUsed")
- private OffsetDateTime lastUsed = null;
-
- @SerializedName("name")
- private String name = null;
-
- @SerializedName("token")
- private String token = null;
+ public static final String SERIALIZED_NAME_DEFAULT_PRIORITY = "defaultPriority";
+ @SerializedName(SERIALIZED_NAME_DEFAULT_PRIORITY)
+ @javax.annotation.Nullable
+ private Long defaultPriority;
+
+ public static final String SERIALIZED_NAME_DESCRIPTION = "description";
+ @SerializedName(SERIALIZED_NAME_DESCRIPTION)
+ @javax.annotation.Nonnull
+ private String description;
+
+ public static final String SERIALIZED_NAME_ID = "id";
+ @SerializedName(SERIALIZED_NAME_ID)
+ @javax.annotation.Nonnull
+ private Long id;
+
+ public static final String SERIALIZED_NAME_IMAGE = "image";
+ @SerializedName(SERIALIZED_NAME_IMAGE)
+ @javax.annotation.Nonnull
+ private String image;
+
+ public static final String SERIALIZED_NAME_INTERNAL = "internal";
+ @SerializedName(SERIALIZED_NAME_INTERNAL)
+ @javax.annotation.Nonnull
+ private Boolean internal;
+
+ public static final String SERIALIZED_NAME_LAST_USED = "lastUsed";
+ @SerializedName(SERIALIZED_NAME_LAST_USED)
+ @javax.annotation.Nullable
+ private OffsetDateTime lastUsed;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public static final String SERIALIZED_NAME_SORT_KEY = "sortKey";
+ @SerializedName(SERIALIZED_NAME_SORT_KEY)
+ @javax.annotation.Nonnull
+ private String sortKey;
+
+ public static final String SERIALIZED_NAME_TOKEN = "token";
+ @SerializedName(SERIALIZED_NAME_TOKEN)
+ @javax.annotation.Nonnull
+ private String token;
+
+ public Application() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public Application(
+ Long id,
+ String image,
+ Boolean internal,
+ OffsetDateTime lastUsed,
+ String token
+ ) {
+ this();
+ this.id = id;
+ this.image = image;
+ this.internal = internal;
+ this.lastUsed = lastUsed;
+ this.token = token;
+ }
- public Application defaultPriority(Long defaultPriority) {
+ public Application defaultPriority(@javax.annotation.Nullable Long defaultPriority) {
+
this.defaultPriority = defaultPriority;
return this;
}
- /**
+ /**
* The default priority of messages sent by this application. Defaults to 0.
* @return defaultPriority
- **/
- @Schema(example = "4", description = "The default priority of messages sent by this application. Defaults to 0.")
+ */
+ @javax.annotation.Nullable
+
public Long getDefaultPriority() {
return defaultPriority;
}
- public void setDefaultPriority(Long defaultPriority) {
+
+ public void setDefaultPriority(@javax.annotation.Nullable Long defaultPriority) {
this.defaultPriority = defaultPriority;
}
- public Application description(String description) {
+ public Application description(@javax.annotation.Nonnull String description) {
+
this.description = description;
return this;
}
- /**
+ /**
* The description of the application.
* @return description
- **/
- @Schema(example = "Backup server for the interwebs", required = true, description = "The description of the application.")
+ */
+ @javax.annotation.Nonnull
+
public String getDescription() {
return description;
}
- public void setDescription(String description) {
+
+ public void setDescription(@javax.annotation.Nonnull String description) {
this.description = description;
}
- /**
+ /**
* The application id.
* @return id
- **/
- @Schema(example = "5", required = true, description = "The application id.")
+ */
+ @javax.annotation.Nonnull
+
public Long getId() {
return id;
}
- /**
+
+
+ /**
* The image of the application.
* @return image
- **/
- @Schema(example = "image/image.jpeg", required = true, description = "The image of the application.")
+ */
+ @javax.annotation.Nonnull
+
public String getImage() {
return image;
}
- /**
+
+
+ /**
* Whether the application is an internal application. Internal applications should not be deleted.
* @return internal
- **/
- @Schema(example = "false", required = true, description = "Whether the application is an internal application. Internal applications should not be deleted.")
- public Boolean isInternal() {
+ */
+ @javax.annotation.Nonnull
+
+ public Boolean getInternal() {
return internal;
}
- /**
+
+
+ /**
* The last time the application token was used.
* @return lastUsed
- **/
- @Schema(example = "2019-01-01T00:00Z", description = "The last time the application token was used.")
+ */
+ @javax.annotation.Nullable
+
public OffsetDateTime getLastUsed() {
return lastUsed;
}
- public Application name(String name) {
+
+
+ public Application name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The application name. This is how the application should be displayed to the user.
* @return name
- **/
- @Schema(example = "Backup Server", required = true, description = "The application name. This is how the application should be displayed to the user.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
- /**
+ public Application sortKey(@javax.annotation.Nonnull String sortKey) {
+
+ this.sortKey = sortKey;
+ return this;
+ }
+
+ /**
+ * The sort key of this application. Uses fractional indexing.
+ * @return sortKey
+ */
+ @javax.annotation.Nonnull
+
+ public String getSortKey() {
+ return sortKey;
+ }
+
+
+ public void setSortKey(@javax.annotation.Nonnull String sortKey) {
+ this.sortKey = sortKey;
+ }
+
+ /**
* The application token. Can be used as `appToken`. See Authentication.
* @return token
- **/
- @Schema(example = "AWH0wZ5r0Mbac.r", required = true, description = "The application token. Can be used as `appToken`. See Authentication.")
+ */
+ @javax.annotation.Nonnull
+
public String getToken() {
return token;
}
+
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -169,20 +254,19 @@ public boolean equals(java.lang.Object o) {
Objects.equals(this.internal, application.internal) &&
Objects.equals(this.lastUsed, application.lastUsed) &&
Objects.equals(this.name, application.name) &&
+ Objects.equals(this.sortKey, application.sortKey) &&
Objects.equals(this.token, application.token);
}
@Override
public int hashCode() {
- return Objects.hash(defaultPriority, description, id, image, internal, lastUsed, name, token);
+ return Objects.hash(defaultPriority, description, id, image, internal, lastUsed, name, sortKey, token);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Application {\n");
-
sb.append(" defaultPriority: ").append(toIndentedString(defaultPriority)).append("\n");
sb.append(" description: ").append(toIndentedString(description)).append("\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
@@ -190,6 +274,7 @@ public String toString() {
sb.append(" internal: ").append(toIndentedString(internal)).append("\n");
sb.append(" lastUsed: ").append(toIndentedString(lastUsed)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
+ sb.append(" sortKey: ").append(toIndentedString(sortKey)).append("\n");
sb.append(" token: ").append(toIndentedString(token)).append("\n");
sb.append("}");
return sb.toString();
@@ -199,7 +284,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -207,3 +292,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/ApplicationParams.java b/client/src/main/java/com/github/gotify/client/model/ApplicationParams.java
index da84f84c..11889231 100644
--- a/client/src/main/java/com/github/gotify/client/model/ApplicationParams.java
+++ b/client/src/main/java/com/github/gotify/client/model/ApplicationParams.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,81 +20,122 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* Params allowed to create or update Applications.
*/
-@Schema(description = "Params allowed to create or update Applications.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class ApplicationParams {
- @SerializedName("defaultPriority")
- private Long defaultPriority = null;
-
- @SerializedName("description")
- private String description = null;
-
- @SerializedName("name")
- private String name = null;
+ public static final String SERIALIZED_NAME_DEFAULT_PRIORITY = "defaultPriority";
+ @SerializedName(SERIALIZED_NAME_DEFAULT_PRIORITY)
+ @javax.annotation.Nullable
+ private Long defaultPriority;
+
+ public static final String SERIALIZED_NAME_DESCRIPTION = "description";
+ @SerializedName(SERIALIZED_NAME_DESCRIPTION)
+ @javax.annotation.Nullable
+ private String description;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public static final String SERIALIZED_NAME_SORT_KEY = "sortKey";
+ @SerializedName(SERIALIZED_NAME_SORT_KEY)
+ @javax.annotation.Nullable
+ private String sortKey;
+
+ public ApplicationParams() {
+ }
- public ApplicationParams defaultPriority(Long defaultPriority) {
+ public ApplicationParams defaultPriority(@javax.annotation.Nullable Long defaultPriority) {
+
this.defaultPriority = defaultPriority;
return this;
}
- /**
+ /**
* The default priority of messages sent by this application. Defaults to 0.
* @return defaultPriority
- **/
- @Schema(example = "5", description = "The default priority of messages sent by this application. Defaults to 0.")
+ */
+ @javax.annotation.Nullable
+
public Long getDefaultPriority() {
return defaultPriority;
}
- public void setDefaultPriority(Long defaultPriority) {
+
+ public void setDefaultPriority(@javax.annotation.Nullable Long defaultPriority) {
this.defaultPriority = defaultPriority;
}
- public ApplicationParams description(String description) {
+ public ApplicationParams description(@javax.annotation.Nullable String description) {
+
this.description = description;
return this;
}
- /**
+ /**
* The description of the application.
* @return description
- **/
- @Schema(example = "Backup server for the interwebs", description = "The description of the application.")
+ */
+ @javax.annotation.Nullable
+
public String getDescription() {
return description;
}
- public void setDescription(String description) {
+
+ public void setDescription(@javax.annotation.Nullable String description) {
this.description = description;
}
- public ApplicationParams name(String name) {
+ public ApplicationParams name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The application name. This is how the application should be displayed to the user.
* @return name
- **/
- @Schema(example = "Backup Server", required = true, description = "The application name. This is how the application should be displayed to the user.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
+ public ApplicationParams sortKey(@javax.annotation.Nullable String sortKey) {
+
+ this.sortKey = sortKey;
+ return this;
+ }
+
+ /**
+ * The sortKey for the application. Uses fractional indexing.
+ * @return sortKey
+ */
+ @javax.annotation.Nullable
+
+ public String getSortKey() {
+ return sortKey;
+ }
+
+
+ public void setSortKey(@javax.annotation.Nullable String sortKey) {
+ this.sortKey = sortKey;
+ }
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -103,23 +145,23 @@ public boolean equals(java.lang.Object o) {
ApplicationParams applicationParams = (ApplicationParams) o;
return Objects.equals(this.defaultPriority, applicationParams.defaultPriority) &&
Objects.equals(this.description, applicationParams.description) &&
- Objects.equals(this.name, applicationParams.name);
+ Objects.equals(this.name, applicationParams.name) &&
+ Objects.equals(this.sortKey, applicationParams.sortKey);
}
@Override
public int hashCode() {
- return Objects.hash(defaultPriority, description, name);
+ return Objects.hash(defaultPriority, description, name, sortKey);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class ApplicationParams {\n");
-
sb.append(" defaultPriority: ").append(toIndentedString(defaultPriority)).append("\n");
sb.append(" description: ").append(toIndentedString(description)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
+ sb.append(" sortKey: ").append(toIndentedString(sortKey)).append("\n");
sb.append("}");
return sb.toString();
}
@@ -128,7 +170,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -136,3 +178,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/Client.java b/client/src/main/java/com/github/gotify/client/model/Client.java
index 89d718ef..c9292ceb 100644
--- a/client/src/main/java/com/github/gotify/client/model/Client.java
+++ b/client/src/main/java/com/github/gotify/client/model/Client.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,76 +20,110 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
-import org.threeten.bp.OffsetDateTime;
+import java.time.OffsetDateTime;
+
/**
* The Client holds information about a device which can receive notifications (and other stuff).
*/
-@Schema(description = "The Client holds information about a device which can receive notifications (and other stuff).")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class Client {
- @SerializedName("id")
- private Long id = null;
-
- @SerializedName("lastUsed")
- private OffsetDateTime lastUsed = null;
-
- @SerializedName("name")
- private String name = null;
-
- @SerializedName("token")
- private String token = null;
+ public static final String SERIALIZED_NAME_ID = "id";
+ @SerializedName(SERIALIZED_NAME_ID)
+ @javax.annotation.Nonnull
+ private Long id;
+
+ public static final String SERIALIZED_NAME_LAST_USED = "lastUsed";
+ @SerializedName(SERIALIZED_NAME_LAST_USED)
+ @javax.annotation.Nullable
+ private OffsetDateTime lastUsed;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public static final String SERIALIZED_NAME_TOKEN = "token";
+ @SerializedName(SERIALIZED_NAME_TOKEN)
+ @javax.annotation.Nonnull
+ private String token;
+
+ public Client() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public Client(
+ Long id,
+ OffsetDateTime lastUsed,
+ String token
+ ) {
+ this();
+ this.id = id;
+ this.lastUsed = lastUsed;
+ this.token = token;
+ }
- /**
+ /**
* The client id.
* @return id
- **/
- @Schema(example = "5", required = true, description = "The client id.")
+ */
+ @javax.annotation.Nonnull
+
public Long getId() {
return id;
}
- /**
+
+
+ /**
* The last time the client token was used.
* @return lastUsed
- **/
- @Schema(example = "2019-01-01T00:00Z", description = "The last time the client token was used.")
+ */
+ @javax.annotation.Nullable
+
public OffsetDateTime getLastUsed() {
return lastUsed;
}
- public Client name(String name) {
+
+
+ public Client name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The client name. This is how the client should be displayed to the user.
* @return name
- **/
- @Schema(example = "Android Phone", required = true, description = "The client name. This is how the client should be displayed to the user.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
- /**
+ /**
* The client token. Can be used as `clientToken`. See Authentication.
* @return token
- **/
- @Schema(example = "CWH0wZ5r0Mbac.r", required = true, description = "The client token. Can be used as `clientToken`. See Authentication.")
+ */
+ @javax.annotation.Nonnull
+
public String getToken() {
return token;
}
+
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -107,12 +142,10 @@ public int hashCode() {
return Objects.hash(id, lastUsed, name, token);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Client {\n");
-
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" lastUsed: ").append(toIndentedString(lastUsed)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
@@ -125,7 +158,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -133,3 +166,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/ClientParams.java b/client/src/main/java/com/github/gotify/client/model/ClientParams.java
index f41a6705..8976d533 100644
--- a/client/src/main/java/com/github/gotify/client/model/ClientParams.java
+++ b/client/src/main/java/com/github/gotify/client/model/ClientParams.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,39 +20,44 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* Params allowed to create or update Clients.
*/
-@Schema(description = "Params allowed to create or update Clients.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class ClientParams {
- @SerializedName("name")
- private String name = null;
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
- public ClientParams name(String name) {
+ public ClientParams() {
+ }
+
+ public ClientParams name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The client name
* @return name
- **/
- @Schema(example = "My Client", required = true, description = "The client name")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -67,12 +73,10 @@ public int hashCode() {
return Objects.hash(name);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class ClientParams {\n");
-
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append("}");
return sb.toString();
@@ -82,7 +86,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -90,3 +94,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/CreateUserExternal.java b/client/src/main/java/com/github/gotify/client/model/CreateUserExternal.java
index 961e5041..aa5ac4fa 100644
--- a/client/src/main/java/com/github/gotify/client/model/CreateUserExternal.java
+++ b/client/src/main/java/com/github/gotify/client/model/CreateUserExternal.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,81 +20,96 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* Used for user creation.
*/
-@Schema(description = "Used for user creation.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class CreateUserExternal {
- @SerializedName("admin")
- private Boolean admin = null;
-
- @SerializedName("name")
- private String name = null;
-
- @SerializedName("pass")
- private String pass = null;
+ public static final String SERIALIZED_NAME_ADMIN = "admin";
+ @SerializedName(SERIALIZED_NAME_ADMIN)
+ @javax.annotation.Nonnull
+ private Boolean admin;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public static final String SERIALIZED_NAME_PASS = "pass";
+ @SerializedName(SERIALIZED_NAME_PASS)
+ @javax.annotation.Nonnull
+ private String pass;
+
+ public CreateUserExternal() {
+ }
- public CreateUserExternal admin(Boolean admin) {
+ public CreateUserExternal admin(@javax.annotation.Nonnull Boolean admin) {
+
this.admin = admin;
return this;
}
- /**
+ /**
* If the user is an administrator.
* @return admin
- **/
- @Schema(example = "true", required = true, description = "If the user is an administrator.")
- public Boolean isAdmin() {
+ */
+ @javax.annotation.Nonnull
+
+ public Boolean getAdmin() {
return admin;
}
- public void setAdmin(Boolean admin) {
+
+ public void setAdmin(@javax.annotation.Nonnull Boolean admin) {
this.admin = admin;
}
- public CreateUserExternal name(String name) {
+ public CreateUserExternal name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The user name. For login.
* @return name
- **/
- @Schema(example = "unicorn", required = true, description = "The user name. For login.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
- public CreateUserExternal pass(String pass) {
+ public CreateUserExternal pass(@javax.annotation.Nonnull String pass) {
+
this.pass = pass;
return this;
}
- /**
+ /**
* The user password. For login.
* @return pass
- **/
- @Schema(example = "nrocinu", required = true, description = "The user password. For login.")
+ */
+ @javax.annotation.Nonnull
+
public String getPass() {
return pass;
}
- public void setPass(String pass) {
+
+ public void setPass(@javax.annotation.Nonnull String pass) {
this.pass = pass;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -111,12 +127,10 @@ public int hashCode() {
return Objects.hash(admin, name, pass);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class CreateUserExternal {\n");
-
sb.append(" admin: ").append(toIndentedString(admin)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append(" pass: ").append(toIndentedString(pass)).append("\n");
@@ -128,7 +142,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -136,3 +150,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/Error.java b/client/src/main/java/com/github/gotify/client/model/Error.java
index a45e991b..d23e6526 100644
--- a/client/src/main/java/com/github/gotify/client/model/Error.java
+++ b/client/src/main/java/com/github/gotify/client/model/Error.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,81 +20,96 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* The Error contains error relevant information.
*/
-@Schema(description = "The Error contains error relevant information.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class Error {
- @SerializedName("error")
- private String error = null;
-
- @SerializedName("errorCode")
- private Long errorCode = null;
-
- @SerializedName("errorDescription")
- private String errorDescription = null;
+ public static final String SERIALIZED_NAME_ERROR = "error";
+ @SerializedName(SERIALIZED_NAME_ERROR)
+ @javax.annotation.Nonnull
+ private String error;
+
+ public static final String SERIALIZED_NAME_ERROR_CODE = "errorCode";
+ @SerializedName(SERIALIZED_NAME_ERROR_CODE)
+ @javax.annotation.Nonnull
+ private Long errorCode;
+
+ public static final String SERIALIZED_NAME_ERROR_DESCRIPTION = "errorDescription";
+ @SerializedName(SERIALIZED_NAME_ERROR_DESCRIPTION)
+ @javax.annotation.Nonnull
+ private String errorDescription;
+
+ public Error() {
+ }
- public Error error(String error) {
+ public Error error(@javax.annotation.Nonnull String error) {
+
this.error = error;
return this;
}
- /**
+ /**
* The general error message
* @return error
- **/
- @Schema(example = "Unauthorized", required = true, description = "The general error message")
+ */
+ @javax.annotation.Nonnull
+
public String getError() {
return error;
}
- public void setError(String error) {
+
+ public void setError(@javax.annotation.Nonnull String error) {
this.error = error;
}
- public Error errorCode(Long errorCode) {
+ public Error errorCode(@javax.annotation.Nonnull Long errorCode) {
+
this.errorCode = errorCode;
return this;
}
- /**
+ /**
* The http error code.
* @return errorCode
- **/
- @Schema(example = "401", required = true, description = "The http error code.")
+ */
+ @javax.annotation.Nonnull
+
public Long getErrorCode() {
return errorCode;
}
- public void setErrorCode(Long errorCode) {
+
+ public void setErrorCode(@javax.annotation.Nonnull Long errorCode) {
this.errorCode = errorCode;
}
- public Error errorDescription(String errorDescription) {
+ public Error errorDescription(@javax.annotation.Nonnull String errorDescription) {
+
this.errorDescription = errorDescription;
return this;
}
- /**
+ /**
* The http error code.
* @return errorDescription
- **/
- @Schema(example = "you need to provide a valid access token or user credentials to access this api", required = true, description = "The http error code.")
+ */
+ @javax.annotation.Nonnull
+
public String getErrorDescription() {
return errorDescription;
}
- public void setErrorDescription(String errorDescription) {
+
+ public void setErrorDescription(@javax.annotation.Nonnull String errorDescription) {
this.errorDescription = errorDescription;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -111,12 +127,10 @@ public int hashCode() {
return Objects.hash(error, errorCode, errorDescription);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Error {\n");
-
sb.append(" error: ").append(toIndentedString(error)).append("\n");
sb.append(" errorCode: ").append(toIndentedString(errorCode)).append("\n");
sb.append(" errorDescription: ").append(toIndentedString(errorDescription)).append("\n");
@@ -128,7 +142,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -136,3 +150,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/Health.java b/client/src/main/java/com/github/gotify/client/model/Health.java
index e0ad0800..97195ded 100644
--- a/client/src/main/java/com/github/gotify/client/model/Health.java
+++ b/client/src/main/java/com/github/gotify/client/model/Health.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,60 +20,70 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* Health represents how healthy the application is.
*/
-@Schema(description = "Health represents how healthy the application is.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class Health {
- @SerializedName("database")
- private String database = null;
+ public static final String SERIALIZED_NAME_DATABASE = "database";
+ @SerializedName(SERIALIZED_NAME_DATABASE)
+ @javax.annotation.Nonnull
+ private String database;
+
+ public static final String SERIALIZED_NAME_HEALTH = "health";
+ @SerializedName(SERIALIZED_NAME_HEALTH)
+ @javax.annotation.Nonnull
+ private String health;
- @SerializedName("health")
- private String health = null;
+ public Health() {
+ }
- public Health database(String database) {
+ public Health database(@javax.annotation.Nonnull String database) {
+
this.database = database;
return this;
}
- /**
+ /**
* The health of the database connection.
* @return database
- **/
- @Schema(example = "green", required = true, description = "The health of the database connection.")
+ */
+ @javax.annotation.Nonnull
+
public String getDatabase() {
return database;
}
- public void setDatabase(String database) {
+
+ public void setDatabase(@javax.annotation.Nonnull String database) {
this.database = database;
}
- public Health health(String health) {
+ public Health health(@javax.annotation.Nonnull String health) {
+
this.health = health;
return this;
}
- /**
+ /**
* The health of the overall application.
* @return health
- **/
- @Schema(example = "green", required = true, description = "The health of the overall application.")
+ */
+ @javax.annotation.Nonnull
+
public String getHealth() {
return health;
}
- public void setHealth(String health) {
+
+ public void setHealth(@javax.annotation.Nonnull String health) {
this.health = health;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -89,12 +100,10 @@ public int hashCode() {
return Objects.hash(database, health);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Health {\n");
-
sb.append(" database: ").append(toIndentedString(database)).append("\n");
sb.append(" health: ").append(toIndentedString(health)).append("\n");
sb.append("}");
@@ -105,7 +114,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -113,3 +122,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/IdImageBody.java b/client/src/main/java/com/github/gotify/client/model/IdImageBody.java
deleted file mode 100644
index 3a5672fd..00000000
--- a/client/src/main/java/com/github/gotify/client/model/IdImageBody.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Gotify REST-API.
- * This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
- *
- * OpenAPI spec version: 2.0.2
- *
- *
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
- * Do not edit the class manually.
- */
-
-package com.github.gotify.client.model;
-
-import java.util.Objects;
-import java.util.Arrays;
-import com.google.gson.TypeAdapter;
-import com.google.gson.annotations.JsonAdapter;
-import com.google.gson.annotations.SerializedName;
-import com.google.gson.stream.JsonReader;
-import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
-import java.io.File;
-import java.io.IOException;
-/**
- * IdImageBody
- */
-
-
-
-public class IdImageBody {
- @SerializedName("file")
- private File file = null;
-
- public IdImageBody file(File file) {
- this.file = file;
- return this;
- }
-
- /**
- * the application image
- * @return file
- **/
- @Schema(required = true, description = "the application image")
- public File getFile() {
- return file;
- }
-
- public void setFile(File file) {
- this.file = file;
- }
-
-
- @Override
- public boolean equals(java.lang.Object o) {
- if (this == o) {
- return true;
- }
- if (o == null || getClass() != o.getClass()) {
- return false;
- }
- IdImageBody idImageBody = (IdImageBody) o;
- return Objects.equals(this.file, idImageBody.file);
- }
-
- @Override
- public int hashCode() {
- return Objects.hash(Objects.hashCode(file));
- }
-
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder();
- sb.append("class IdImageBody {\n");
-
- sb.append(" file: ").append(toIndentedString(file)).append("\n");
- sb.append("}");
- return sb.toString();
- }
-
- /**
- * Convert the given object to string with each line indented by 4 spaces
- * (except the first line).
- */
- private String toIndentedString(java.lang.Object o) {
- if (o == null) {
- return "null";
- }
- return o.toString().replace("\n", "\n ");
- }
-
-}
diff --git a/client/src/main/java/com/github/gotify/client/model/Message.java b/client/src/main/java/com/github/gotify/client/model/Message.java
index ccf8ca3c..9ef2ce24 100644
--- a/client/src/main/java/com/github/gotify/client/model/Message.java
+++ b/client/src/main/java/com/github/gotify/client/model/Message.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,150 +20,198 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+import java.time.OffsetDateTime;
import java.util.HashMap;
-import java.util.List;
import java.util.Map;
-import org.threeten.bp.OffsetDateTime;
+
/**
* The MessageExternal holds information about a message which was sent by an Application.
*/
-@Schema(description = "The MessageExternal holds information about a message which was sent by an Application.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class Message {
- @SerializedName("appid")
- private Long appid = null;
-
- @SerializedName("date")
- private OffsetDateTime date = null;
-
- @SerializedName("extras")
- private Map extras = null;
-
- @SerializedName("id")
- private Long id = null;
-
- @SerializedName("message")
- private String message = null;
-
- @SerializedName("priority")
- private Long priority = null;
-
- @SerializedName("title")
- private String title = null;
+ public static final String SERIALIZED_NAME_APPID = "appid";
+ @SerializedName(SERIALIZED_NAME_APPID)
+ @javax.annotation.Nonnull
+ private Long appid;
+
+ public static final String SERIALIZED_NAME_DATE = "date";
+ @SerializedName(SERIALIZED_NAME_DATE)
+ @javax.annotation.Nonnull
+ private OffsetDateTime date;
+
+ public static final String SERIALIZED_NAME_EXTRAS = "extras";
+ @SerializedName(SERIALIZED_NAME_EXTRAS)
+ @javax.annotation.Nullable
+ private Map extras = new HashMap<>();
+
+ public static final String SERIALIZED_NAME_ID = "id";
+ @SerializedName(SERIALIZED_NAME_ID)
+ @javax.annotation.Nonnull
+ private Long id;
+
+ public static final String SERIALIZED_NAME_MESSAGE = "message";
+ @SerializedName(SERIALIZED_NAME_MESSAGE)
+ @javax.annotation.Nonnull
+ private String message;
+
+ public static final String SERIALIZED_NAME_PRIORITY = "priority";
+ @SerializedName(SERIALIZED_NAME_PRIORITY)
+ @javax.annotation.Nullable
+ private Long priority;
+
+ public static final String SERIALIZED_NAME_TITLE = "title";
+ @SerializedName(SERIALIZED_NAME_TITLE)
+ @javax.annotation.Nullable
+ private String title;
+
+ public Message() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public Message(
+ Long appid,
+ OffsetDateTime date,
+ Long id
+ ) {
+ this();
+ this.appid = appid;
+ this.date = date;
+ this.id = id;
+ }
- /**
+ /**
* The application id that send this message.
* @return appid
- **/
- @Schema(example = "5", required = true, description = "The application id that send this message.")
+ */
+ @javax.annotation.Nonnull
+
public Long getAppid() {
return appid;
}
- /**
+
+
+ /**
* The date the message was created.
* @return date
- **/
- @Schema(example = "2018-02-27T19:36:10.504504400+01:00", required = true, description = "The date the message was created.")
+ */
+ @javax.annotation.Nonnull
+
public OffsetDateTime getDate() {
return date;
}
- public Message extras(Map extras) {
+
+
+ public Message extras(@javax.annotation.Nullable Map extras) {
+
this.extras = extras;
return this;
}
public Message putExtrasItem(String key, Object extrasItem) {
if (this.extras == null) {
- this.extras = new HashMap();
+ this.extras = new HashMap<>();
}
this.extras.put(key, extrasItem);
return this;
}
- /**
+ /**
* The extra data sent along the message. The extra fields are stored in a key-value scheme. Only accepted in CreateMessage requests with application/json content-type. The keys should be in the following format: <top-namespace>::[<sub-namespace>::]<action> These namespaces are reserved and might be used in the official clients: gotify android ios web server client. Do not use them for other purposes.
* @return extras
- **/
- @Schema(example = "{\"home::appliances::lighting::on\":{\"brightness\":15},\"home::appliances::thermostat::change_temperature\":{\"temperature\":23}}", description = "The extra data sent along the message. The extra fields are stored in a key-value scheme. Only accepted in CreateMessage requests with application/json content-type. The keys should be in the following format: <top-namespace>::[<sub-namespace>::]<action> These namespaces are reserved and might be used in the official clients: gotify android ios web server client. Do not use them for other purposes.")
+ */
+ @javax.annotation.Nullable
+
public Map getExtras() {
return extras;
}
- public void setExtras(Map extras) {
+
+ public void setExtras(@javax.annotation.Nullable Map extras) {
this.extras = extras;
}
- /**
+ /**
* The message id.
* @return id
- **/
- @Schema(example = "25", required = true, description = "The message id.")
+ */
+ @javax.annotation.Nonnull
+
public Long getId() {
return id;
}
- public Message message(String message) {
+
+
+ public Message message(@javax.annotation.Nonnull String message) {
+
this.message = message;
return this;
}
- /**
+ /**
* The message. Markdown (excluding html) is allowed.
* @return message
- **/
- @Schema(example = "**Backup** was successfully finished.", required = true, description = "The message. Markdown (excluding html) is allowed.")
+ */
+ @javax.annotation.Nonnull
+
public String getMessage() {
return message;
}
- public void setMessage(String message) {
+
+ public void setMessage(@javax.annotation.Nonnull String message) {
this.message = message;
}
- public Message priority(Long priority) {
+ public Message priority(@javax.annotation.Nullable Long priority) {
+
this.priority = priority;
return this;
}
- /**
+ /**
* The priority of the message. If unset, then the default priority of the application will be used.
* @return priority
- **/
- @Schema(example = "2", description = "The priority of the message. If unset, then the default priority of the application will be used.")
+ */
+ @javax.annotation.Nullable
+
public Long getPriority() {
return priority;
}
- public void setPriority(Long priority) {
+
+ public void setPriority(@javax.annotation.Nullable Long priority) {
this.priority = priority;
}
- public Message title(String title) {
+ public Message title(@javax.annotation.Nullable String title) {
+
this.title = title;
return this;
}
- /**
+ /**
* The title of the message.
* @return title
- **/
- @Schema(example = "Backup", description = "The title of the message.")
+ */
+ @javax.annotation.Nullable
+
public String getTitle() {
return title;
}
- public void setTitle(String title) {
+
+ public void setTitle(@javax.annotation.Nullable String title) {
this.title = title;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -184,12 +233,10 @@ public int hashCode() {
return Objects.hash(appid, date, extras, id, message, priority, title);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Message {\n");
-
sb.append(" appid: ").append(toIndentedString(appid)).append("\n");
sb.append(" date: ").append(toIndentedString(date)).append("\n");
sb.append(" extras: ").append(toIndentedString(extras)).append("\n");
@@ -205,7 +252,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -213,3 +260,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/PagedMessages.java b/client/src/main/java/com/github/gotify/client/model/PagedMessages.java
index 9d0fd34a..606d06fd 100644
--- a/client/src/main/java/com/github/gotify/client/model/PagedMessages.java
+++ b/client/src/main/java/com/github/gotify/client/model/PagedMessages.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -21,53 +22,74 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.List;
+
/**
* Wrapper for the paging and the messages.
*/
-@Schema(description = "Wrapper for the paging and the messages.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class PagedMessages {
- @SerializedName("messages")
- private List messages = new ArrayList();
+ public static final String SERIALIZED_NAME_MESSAGES = "messages";
+ @SerializedName(SERIALIZED_NAME_MESSAGES)
+ @javax.annotation.Nonnull
+ private List messages = new ArrayList<>();
+
+ public static final String SERIALIZED_NAME_PAGING = "paging";
+ @SerializedName(SERIALIZED_NAME_PAGING)
+ @javax.annotation.Nonnull
+ private Paging paging;
- @SerializedName("paging")
- private Paging paging = null;
+ public PagedMessages() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public PagedMessages(
+ List messages
+ ) {
+ this();
+ this.messages = messages;
+ }
- /**
+ /**
* The messages.
* @return messages
- **/
- @Schema(required = true, description = "The messages.")
+ */
+ @javax.annotation.Nonnull
+
public List getMessages() {
return messages;
}
- public PagedMessages paging(Paging paging) {
+
+
+ public PagedMessages paging(@javax.annotation.Nonnull Paging paging) {
+
this.paging = paging;
return this;
}
- /**
+ /**
* Get paging
* @return paging
- **/
- @Schema(required = true, description = "")
+ */
+ @javax.annotation.Nonnull
+
public Paging getPaging() {
return paging;
}
- public void setPaging(Paging paging) {
+
+ public void setPaging(@javax.annotation.Nonnull Paging paging) {
this.paging = paging;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -84,12 +106,10 @@ public int hashCode() {
return Objects.hash(messages, paging);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class PagedMessages {\n");
-
sb.append(" messages: ").append(toIndentedString(messages)).append("\n");
sb.append(" paging: ").append(toIndentedString(paging)).append("\n");
sb.append("}");
@@ -100,7 +120,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -108,3 +128,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/Paging.java b/client/src/main/java/com/github/gotify/client/model/Paging.java
index c7df0268..b908ca54 100644
--- a/client/src/main/java/com/github/gotify/client/model/Paging.java
+++ b/client/src/main/java/com/github/gotify/client/model/Paging.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,69 +20,105 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* The Paging holds information about the limit and making requests to the next page.
*/
-@Schema(description = "The Paging holds information about the limit and making requests to the next page.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class Paging {
- @SerializedName("limit")
- private Long limit = null;
-
- @SerializedName("next")
- private String next = null;
-
- @SerializedName("since")
- private Long since = null;
-
- @SerializedName("size")
- private Long size = null;
+ public static final String SERIALIZED_NAME_LIMIT = "limit";
+ @SerializedName(SERIALIZED_NAME_LIMIT)
+ @javax.annotation.Nonnull
+ private Long limit;
+
+ public static final String SERIALIZED_NAME_NEXT = "next";
+ @SerializedName(SERIALIZED_NAME_NEXT)
+ @javax.annotation.Nullable
+ private String next;
+
+ public static final String SERIALIZED_NAME_SINCE = "since";
+ @SerializedName(SERIALIZED_NAME_SINCE)
+ @javax.annotation.Nonnull
+ private Long since;
+
+ public static final String SERIALIZED_NAME_SIZE = "size";
+ @SerializedName(SERIALIZED_NAME_SIZE)
+ @javax.annotation.Nonnull
+ private Long size;
+
+ public Paging() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public Paging(
+ Long limit,
+ String next,
+ Long since,
+ Long size
+ ) {
+ this();
+ this.limit = limit;
+ this.next = next;
+ this.since = since;
+ this.size = size;
+ }
- /**
+ /**
* The limit of the messages for the current request.
* minimum: 1
* maximum: 200
* @return limit
- **/
- @Schema(example = "123", required = true, description = "The limit of the messages for the current request.")
+ */
+ @javax.annotation.Nonnull
+
public Long getLimit() {
return limit;
}
- /**
+
+
+ /**
* The request url for the next page. Empty/Null when no next page is available.
* @return next
- **/
- @Schema(example = "http://example.com/message?limit=50&since=123456", description = "The request url for the next page. Empty/Null when no next page is available.")
+ */
+ @javax.annotation.Nullable
+
public String getNext() {
return next;
}
- /**
+
+
+ /**
* The ID of the last message returned in the current request. Use this as alternative to the next link.
* minimum: 0
* @return since
- **/
- @Schema(example = "5", required = true, description = "The ID of the last message returned in the current request. Use this as alternative to the next link.")
+ */
+ @javax.annotation.Nonnull
+
public Long getSince() {
return since;
}
- /**
+
+
+ /**
* The amount of messages that got returned in the current request.
* @return size
- **/
- @Schema(example = "5", required = true, description = "The amount of messages that got returned in the current request.")
+ */
+ @javax.annotation.Nonnull
+
public Long getSize() {
return size;
}
+
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -100,12 +137,10 @@ public int hashCode() {
return Objects.hash(limit, next, since, size);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Paging {\n");
-
sb.append(" limit: ").append(toIndentedString(limit)).append("\n");
sb.append(" next: ").append(toIndentedString(next)).append("\n");
sb.append(" since: ").append(toIndentedString(since)).append("\n");
@@ -118,7 +153,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -126,3 +161,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/PluginConf.java b/client/src/main/java/com/github/gotify/client/model/PluginConf.java
index ac162dd5..968ba4a8 100644
--- a/client/src/main/java/com/github/gotify/client/model/PluginConf.java
+++ b/client/src/main/java/com/github/gotify/client/model/PluginConf.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,160 +20,229 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.List;
+
/**
* Holds information about a plugin instance for one user.
*/
-@Schema(description = "Holds information about a plugin instance for one user.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class PluginConf {
- @SerializedName("author")
- private String author = null;
-
- @SerializedName("capabilities")
- private List capabilities = new ArrayList();
-
- @SerializedName("enabled")
- private Boolean enabled = null;
-
- @SerializedName("id")
- private Long id = null;
-
- @SerializedName("license")
- private String license = null;
-
- @SerializedName("modulePath")
- private String modulePath = null;
-
- @SerializedName("name")
- private String name = null;
-
- @SerializedName("token")
- private String token = null;
-
- @SerializedName("website")
- private String website = null;
+ public static final String SERIALIZED_NAME_AUTHOR = "author";
+ @SerializedName(SERIALIZED_NAME_AUTHOR)
+ @javax.annotation.Nullable
+ private String author;
+
+ public static final String SERIALIZED_NAME_CAPABILITIES = "capabilities";
+ @SerializedName(SERIALIZED_NAME_CAPABILITIES)
+ @javax.annotation.Nonnull
+ private List capabilities = new ArrayList<>();
+
+ public static final String SERIALIZED_NAME_ENABLED = "enabled";
+ @SerializedName(SERIALIZED_NAME_ENABLED)
+ @javax.annotation.Nonnull
+ private Boolean enabled;
+
+ public static final String SERIALIZED_NAME_ID = "id";
+ @SerializedName(SERIALIZED_NAME_ID)
+ @javax.annotation.Nonnull
+ private Long id;
+
+ public static final String SERIALIZED_NAME_LICENSE = "license";
+ @SerializedName(SERIALIZED_NAME_LICENSE)
+ @javax.annotation.Nullable
+ private String license;
+
+ public static final String SERIALIZED_NAME_MODULE_PATH = "modulePath";
+ @SerializedName(SERIALIZED_NAME_MODULE_PATH)
+ @javax.annotation.Nonnull
+ private String modulePath;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public static final String SERIALIZED_NAME_TOKEN = "token";
+ @SerializedName(SERIALIZED_NAME_TOKEN)
+ @javax.annotation.Nonnull
+ private String token;
+
+ public static final String SERIALIZED_NAME_WEBSITE = "website";
+ @SerializedName(SERIALIZED_NAME_WEBSITE)
+ @javax.annotation.Nullable
+ private String website;
+
+ public PluginConf() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public PluginConf(
+ String author,
+ Long id,
+ String license,
+ String modulePath,
+ String name,
+ String website
+ ) {
+ this();
+ this.author = author;
+ this.id = id;
+ this.license = license;
+ this.modulePath = modulePath;
+ this.name = name;
+ this.website = website;
+ }
- /**
+ /**
* The author of the plugin.
* @return author
- **/
- @Schema(example = "jmattheis", description = "The author of the plugin.")
+ */
+ @javax.annotation.Nullable
+
public String getAuthor() {
return author;
}
- public PluginConf capabilities(List capabilities) {
+
+
+ public PluginConf capabilities(@javax.annotation.Nonnull List capabilities) {
+
this.capabilities = capabilities;
return this;
}
public PluginConf addCapabilitiesItem(String capabilitiesItem) {
+ if (this.capabilities == null) {
+ this.capabilities = new ArrayList<>();
+ }
this.capabilities.add(capabilitiesItem);
return this;
}
- /**
+ /**
* Capabilities the plugin provides
* @return capabilities
- **/
- @Schema(example = "[\"webhook\",\"display\"]", required = true, description = "Capabilities the plugin provides")
+ */
+ @javax.annotation.Nonnull
+
public List getCapabilities() {
return capabilities;
}
- public void setCapabilities(List capabilities) {
+
+ public void setCapabilities(@javax.annotation.Nonnull List capabilities) {
this.capabilities = capabilities;
}
- public PluginConf enabled(Boolean enabled) {
+ public PluginConf enabled(@javax.annotation.Nonnull Boolean enabled) {
+
this.enabled = enabled;
return this;
}
- /**
+ /**
* Whether the plugin instance is enabled.
* @return enabled
- **/
- @Schema(example = "true", required = true, description = "Whether the plugin instance is enabled.")
- public Boolean isEnabled() {
+ */
+ @javax.annotation.Nonnull
+
+ public Boolean getEnabled() {
return enabled;
}
- public void setEnabled(Boolean enabled) {
+
+ public void setEnabled(@javax.annotation.Nonnull Boolean enabled) {
this.enabled = enabled;
}
- /**
+ /**
* The plugin id.
* @return id
- **/
- @Schema(example = "25", required = true, description = "The plugin id.")
+ */
+ @javax.annotation.Nonnull
+
public Long getId() {
return id;
}
- /**
+
+
+ /**
* The license of the plugin.
* @return license
- **/
- @Schema(example = "MIT", description = "The license of the plugin.")
+ */
+ @javax.annotation.Nullable
+
public String getLicense() {
return license;
}
- /**
+
+
+ /**
* The module path of the plugin.
* @return modulePath
- **/
- @Schema(example = "github.com/gotify/server/plugin/example/echo", required = true, description = "The module path of the plugin.")
+ */
+ @javax.annotation.Nonnull
+
public String getModulePath() {
return modulePath;
}
- /**
+
+
+ /**
* The plugin name.
* @return name
- **/
- @Schema(example = "RSS poller", required = true, description = "The plugin name.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public PluginConf token(String token) {
+
+
+ public PluginConf token(@javax.annotation.Nonnull String token) {
+
this.token = token;
return this;
}
- /**
+ /**
* The user name. For login.
* @return token
- **/
- @Schema(example = "P1234", required = true, description = "The user name. For login.")
+ */
+ @javax.annotation.Nonnull
+
public String getToken() {
return token;
}
- public void setToken(String token) {
+
+ public void setToken(@javax.annotation.Nonnull String token) {
this.token = token;
}
- /**
+ /**
* The website of the plugin.
* @return website
- **/
- @Schema(example = "gotify.net", description = "The website of the plugin.")
+ */
+ @javax.annotation.Nullable
+
public String getWebsite() {
return website;
}
+
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -196,12 +266,10 @@ public int hashCode() {
return Objects.hash(author, capabilities, enabled, id, license, modulePath, name, token, website);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class PluginConf {\n");
-
sb.append(" author: ").append(toIndentedString(author)).append("\n");
sb.append(" capabilities: ").append(toIndentedString(capabilities)).append("\n");
sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n");
@@ -219,7 +287,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -227,3 +295,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/UpdateUserExternal.java b/client/src/main/java/com/github/gotify/client/model/UpdateUserExternal.java
index a0b2d376..d4d2a369 100644
--- a/client/src/main/java/com/github/gotify/client/model/UpdateUserExternal.java
+++ b/client/src/main/java/com/github/gotify/client/model/UpdateUserExternal.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,81 +20,96 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* Used for updating a user.
*/
-@Schema(description = "Used for updating a user.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class UpdateUserExternal {
- @SerializedName("admin")
- private Boolean admin = null;
-
- @SerializedName("name")
- private String name = null;
-
- @SerializedName("pass")
- private String pass = null;
+ public static final String SERIALIZED_NAME_ADMIN = "admin";
+ @SerializedName(SERIALIZED_NAME_ADMIN)
+ @javax.annotation.Nonnull
+ private Boolean admin;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public static final String SERIALIZED_NAME_PASS = "pass";
+ @SerializedName(SERIALIZED_NAME_PASS)
+ @javax.annotation.Nullable
+ private String pass;
+
+ public UpdateUserExternal() {
+ }
- public UpdateUserExternal admin(Boolean admin) {
+ public UpdateUserExternal admin(@javax.annotation.Nonnull Boolean admin) {
+
this.admin = admin;
return this;
}
- /**
+ /**
* If the user is an administrator.
* @return admin
- **/
- @Schema(example = "true", required = true, description = "If the user is an administrator.")
- public Boolean isAdmin() {
+ */
+ @javax.annotation.Nonnull
+
+ public Boolean getAdmin() {
return admin;
}
- public void setAdmin(Boolean admin) {
+
+ public void setAdmin(@javax.annotation.Nonnull Boolean admin) {
this.admin = admin;
}
- public UpdateUserExternal name(String name) {
+ public UpdateUserExternal name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The user name. For login.
* @return name
- **/
- @Schema(example = "unicorn", required = true, description = "The user name. For login.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
- public UpdateUserExternal pass(String pass) {
+ public UpdateUserExternal pass(@javax.annotation.Nullable String pass) {
+
this.pass = pass;
return this;
}
- /**
+ /**
* The user password. For login. Empty for using old password
* @return pass
- **/
- @Schema(example = "nrocinu", description = "The user password. For login. Empty for using old password")
+ */
+ @javax.annotation.Nullable
+
public String getPass() {
return pass;
}
- public void setPass(String pass) {
+
+ public void setPass(@javax.annotation.Nullable String pass) {
this.pass = pass;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -111,12 +127,10 @@ public int hashCode() {
return Objects.hash(admin, name, pass);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class UpdateUserExternal {\n");
-
sb.append(" admin: ").append(toIndentedString(admin)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append(" pass: ").append(toIndentedString(pass)).append("\n");
@@ -128,7 +142,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -136,3 +150,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/User.java b/client/src/main/java/com/github/gotify/client/model/User.java
index 7e87f5e7..24ebb3c0 100644
--- a/client/src/main/java/com/github/gotify/client/model/User.java
+++ b/client/src/main/java/com/github/gotify/client/model/User.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,72 +20,97 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* The User holds information about permission and other stuff.
*/
-@Schema(description = "The User holds information about permission and other stuff.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class User {
- @SerializedName("admin")
- private Boolean admin = null;
-
- @SerializedName("id")
- private Long id = null;
-
- @SerializedName("name")
- private String name = null;
+ public static final String SERIALIZED_NAME_ADMIN = "admin";
+ @SerializedName(SERIALIZED_NAME_ADMIN)
+ @javax.annotation.Nonnull
+ private Boolean admin;
+
+ public static final String SERIALIZED_NAME_ID = "id";
+ @SerializedName(SERIALIZED_NAME_ID)
+ @javax.annotation.Nonnull
+ private Long id;
+
+ public static final String SERIALIZED_NAME_NAME = "name";
+ @SerializedName(SERIALIZED_NAME_NAME)
+ @javax.annotation.Nonnull
+ private String name;
+
+ public User() {
+ }
+ /**
+ * Constructor with only readonly parameters
+ */
+
+ public User(
+ Long id
+ ) {
+ this();
+ this.id = id;
+ }
- public User admin(Boolean admin) {
+ public User admin(@javax.annotation.Nonnull Boolean admin) {
+
this.admin = admin;
return this;
}
- /**
+ /**
* If the user is an administrator.
* @return admin
- **/
- @Schema(example = "true", required = true, description = "If the user is an administrator.")
- public Boolean isAdmin() {
+ */
+ @javax.annotation.Nonnull
+
+ public Boolean getAdmin() {
return admin;
}
- public void setAdmin(Boolean admin) {
+
+ public void setAdmin(@javax.annotation.Nonnull Boolean admin) {
this.admin = admin;
}
- /**
+ /**
* The user id.
* @return id
- **/
- @Schema(example = "25", required = true, description = "The user id.")
+ */
+ @javax.annotation.Nonnull
+
public Long getId() {
return id;
}
- public User name(String name) {
+
+
+ public User name(@javax.annotation.Nonnull String name) {
+
this.name = name;
return this;
}
- /**
+ /**
* The user name. For login.
* @return name
- **/
- @Schema(example = "unicorn", required = true, description = "The user name. For login.")
+ */
+ @javax.annotation.Nonnull
+
public String getName() {
return name;
}
- public void setName(String name) {
+
+ public void setName(@javax.annotation.Nonnull String name) {
this.name = name;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -102,12 +128,10 @@ public int hashCode() {
return Objects.hash(admin, id, name);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class User {\n");
-
sb.append(" admin: ").append(toIndentedString(admin)).append("\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
@@ -119,7 +143,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -127,3 +151,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/UserPass.java b/client/src/main/java/com/github/gotify/client/model/UserPass.java
index 50c121a9..9ed2839d 100644
--- a/client/src/main/java/com/github/gotify/client/model/UserPass.java
+++ b/client/src/main/java/com/github/gotify/client/model/UserPass.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,39 +20,44 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* The Password for updating the user.
*/
-@Schema(description = "The Password for updating the user.")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class UserPass {
- @SerializedName("pass")
- private String pass = null;
+ public static final String SERIALIZED_NAME_PASS = "pass";
+ @SerializedName(SERIALIZED_NAME_PASS)
+ @javax.annotation.Nonnull
+ private String pass;
- public UserPass pass(String pass) {
+ public UserPass() {
+ }
+
+ public UserPass pass(@javax.annotation.Nonnull String pass) {
+
this.pass = pass;
return this;
}
- /**
+ /**
* The user password. For login.
* @return pass
- **/
- @Schema(example = "nrocinu", required = true, description = "The user password. For login.")
+ */
+ @javax.annotation.Nonnull
+
public String getPass() {
return pass;
}
- public void setPass(String pass) {
+
+ public void setPass(@javax.annotation.Nonnull String pass) {
this.pass = pass;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -67,12 +73,10 @@ public int hashCode() {
return Objects.hash(pass);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class UserPass {\n");
-
sb.append(" pass: ").append(toIndentedString(pass)).append("\n");
sb.append("}");
return sb.toString();
@@ -82,7 +86,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -90,3 +94,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/main/java/com/github/gotify/client/model/VersionInfo.java b/client/src/main/java/com/github/gotify/client/model/VersionInfo.java
index 263326e8..751e6deb 100644
--- a/client/src/main/java/com/github/gotify/client/model/VersionInfo.java
+++ b/client/src/main/java/com/github/gotify/client/model/VersionInfo.java
@@ -2,14 +2,15 @@
* Gotify REST-API.
* This is the documentation of the Gotify REST-API. # Authentication In Gotify there are two token types: __clientToken__: a client is something that receives message and manages stuff like creating new tokens or delete messages. (f.ex this token should be used for an android app) __appToken__: an application is something that sends messages (f.ex. this token should be used for a shell script) The token can be transmitted in a header named `X-Gotify-Key`, in a query parameter named `token` or through a header named `Authorization` with the value prefixed with `Bearer` (Ex. `Bearer randomtoken`). There is also the possibility to authenticate through basic auth, this should only be used for creating a clientToken. \\--- Found a bug or have some questions? [Create an issue on GitHub](https://github.com/gotify/server/issues)
*
- * OpenAPI spec version: 2.0.2
+ * The version of the OpenAPI document: 2.0.2
*
*
- * NOTE: This class is auto generated by the swagger code generator program.
- * https://github.com/swagger-api/swagger-codegen.git
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
* Do not edit the class manually.
*/
+
package com.github.gotify.client.model;
import java.util.Objects;
@@ -19,81 +20,96 @@
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
-import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
+
/**
* VersionInfo Model
*/
-@Schema(description = "VersionInfo Model")
-
-
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.19.0")
public class VersionInfo {
- @SerializedName("buildDate")
- private String buildDate = null;
-
- @SerializedName("commit")
- private String commit = null;
-
- @SerializedName("version")
- private String version = null;
+ public static final String SERIALIZED_NAME_BUILD_DATE = "buildDate";
+ @SerializedName(SERIALIZED_NAME_BUILD_DATE)
+ @javax.annotation.Nonnull
+ private String buildDate;
+
+ public static final String SERIALIZED_NAME_COMMIT = "commit";
+ @SerializedName(SERIALIZED_NAME_COMMIT)
+ @javax.annotation.Nonnull
+ private String commit;
+
+ public static final String SERIALIZED_NAME_VERSION = "version";
+ @SerializedName(SERIALIZED_NAME_VERSION)
+ @javax.annotation.Nonnull
+ private String version;
+
+ public VersionInfo() {
+ }
- public VersionInfo buildDate(String buildDate) {
+ public VersionInfo buildDate(@javax.annotation.Nonnull String buildDate) {
+
this.buildDate = buildDate;
return this;
}
- /**
+ /**
* The date on which this binary was built.
* @return buildDate
- **/
- @Schema(example = "2018-02-27T19:36:10.5045044+01:00", required = true, description = "The date on which this binary was built.")
+ */
+ @javax.annotation.Nonnull
+
public String getBuildDate() {
return buildDate;
}
- public void setBuildDate(String buildDate) {
+
+ public void setBuildDate(@javax.annotation.Nonnull String buildDate) {
this.buildDate = buildDate;
}
- public VersionInfo commit(String commit) {
+ public VersionInfo commit(@javax.annotation.Nonnull String commit) {
+
this.commit = commit;
return this;
}
- /**
+ /**
* The git commit hash on which this binary was built.
* @return commit
- **/
- @Schema(example = "ae9512b6b6feea56a110d59a3353ea3b9c293864", required = true, description = "The git commit hash on which this binary was built.")
+ */
+ @javax.annotation.Nonnull
+
public String getCommit() {
return commit;
}
- public void setCommit(String commit) {
+
+ public void setCommit(@javax.annotation.Nonnull String commit) {
this.commit = commit;
}
- public VersionInfo version(String version) {
+ public VersionInfo version(@javax.annotation.Nonnull String version) {
+
this.version = version;
return this;
}
- /**
+ /**
* The current version.
* @return version
- **/
- @Schema(example = "5.2.6", required = true, description = "The current version.")
+ */
+ @javax.annotation.Nonnull
+
public String getVersion() {
return version;
}
- public void setVersion(String version) {
+
+ public void setVersion(@javax.annotation.Nonnull String version) {
this.version = version;
}
-
@Override
- public boolean equals(java.lang.Object o) {
+ public boolean equals(Object o) {
if (this == o) {
return true;
}
@@ -111,12 +127,10 @@ public int hashCode() {
return Objects.hash(buildDate, commit, version);
}
-
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class VersionInfo {\n");
-
sb.append(" buildDate: ").append(toIndentedString(buildDate)).append("\n");
sb.append(" commit: ").append(toIndentedString(commit)).append("\n");
sb.append(" version: ").append(toIndentedString(version)).append("\n");
@@ -128,7 +142,7 @@ public String toString() {
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
- private String toIndentedString(java.lang.Object o) {
+ private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
@@ -136,3 +150,4 @@ private String toIndentedString(java.lang.Object o) {
}
}
+
diff --git a/client/src/test/java/com/github/gotify/client/api/ApplicationApiTest.java b/client/src/test/java/com/github/gotify/client/api/ApplicationApiTest.java
deleted file mode 100644
index 2db46e89..00000000
--- a/client/src/test/java/com/github/gotify/client/api/ApplicationApiTest.java
+++ /dev/null
@@ -1,109 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.Application;
-import com.github.gotify.client.model.ApplicationParams;
-import com.github.gotify.client.model.Error;
-import java.io.File;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for ApplicationApi
- */
-public class ApplicationApiTest {
-
- private ApplicationApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(ApplicationApi.class);
- }
-
-
- /**
- * Create an application.
- *
- *
- */
- @Test
- public void createAppTest() {
- ApplicationParams body = null;
- // Application response = api.createApp(body);
-
- // TODO: test validations
- }
-
- /**
- * Delete an application.
- *
- *
- */
- @Test
- public void deleteAppTest() {
- Long id = null;
- // Void response = api.deleteApp(id);
-
- // TODO: test validations
- }
-
- /**
- * Return all applications.
- *
- *
- */
- @Test
- public void getAppsTest() {
- // List response = api.getApps();
-
- // TODO: test validations
- }
-
- /**
- * Deletes an image of an application.
- *
- *
- */
- @Test
- public void removeAppImageTest() {
- Long id = null;
- // Void response = api.removeAppImage(id);
-
- // TODO: test validations
- }
-
- /**
- * Update an application.
- *
- *
- */
- @Test
- public void updateApplicationTest() {
- ApplicationParams body = null;
- Long id = null;
- // Application response = api.updateApplication(body, id);
-
- // TODO: test validations
- }
-
- /**
- * Upload an image for an application.
- *
- *
- */
- @Test
- public void uploadAppImageTest() {
- File file = null;
- Long id = null;
- // Application response = api.uploadAppImage(file, id);
-
- // TODO: test validations
- }
-}
diff --git a/client/src/test/java/com/github/gotify/client/api/ClientApiTest.java b/client/src/test/java/com/github/gotify/client/api/ClientApiTest.java
deleted file mode 100644
index 20b9845b..00000000
--- a/client/src/test/java/com/github/gotify/client/api/ClientApiTest.java
+++ /dev/null
@@ -1,81 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.Client;
-import com.github.gotify.client.model.ClientParams;
-import com.github.gotify.client.model.Error;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for ClientApi
- */
-public class ClientApiTest {
-
- private ClientApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(ClientApi.class);
- }
-
-
- /**
- * Create a client.
- *
- *
- */
- @Test
- public void createClientTest() {
- ClientParams body = null;
- // Client response = api.createClient(body);
-
- // TODO: test validations
- }
-
- /**
- * Delete a client.
- *
- *
- */
- @Test
- public void deleteClientTest() {
- Long id = null;
- // Void response = api.deleteClient(id);
-
- // TODO: test validations
- }
-
- /**
- * Return all clients.
- *
- *
- */
- @Test
- public void getClientsTest() {
- // List response = api.getClients();
-
- // TODO: test validations
- }
-
- /**
- * Update a client.
- *
- *
- */
- @Test
- public void updateClientTest() {
- ClientParams body = null;
- Long id = null;
- // Client response = api.updateClient(body, id);
-
- // TODO: test validations
- }
-}
diff --git a/client/src/test/java/com/github/gotify/client/api/HealthApiTest.java b/client/src/test/java/com/github/gotify/client/api/HealthApiTest.java
deleted file mode 100644
index 4275f85a..00000000
--- a/client/src/test/java/com/github/gotify/client/api/HealthApiTest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.Health;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for HealthApi
- */
-public class HealthApiTest {
-
- private HealthApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(HealthApi.class);
- }
-
-
- /**
- * Get health information.
- *
- *
- */
- @Test
- public void getHealthTest() {
- // Health response = api.getHealth();
-
- // TODO: test validations
- }
-}
diff --git a/client/src/test/java/com/github/gotify/client/api/MessageApiTest.java b/client/src/test/java/com/github/gotify/client/api/MessageApiTest.java
deleted file mode 100644
index 0788b9d0..00000000
--- a/client/src/test/java/com/github/gotify/client/api/MessageApiTest.java
+++ /dev/null
@@ -1,121 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.Error;
-import com.github.gotify.client.model.Message;
-import com.github.gotify.client.model.PagedMessages;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for MessageApi
- */
-public class MessageApiTest {
-
- private MessageApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(MessageApi.class);
- }
-
-
- /**
- * Create a message.
- *
- * __NOTE__: This API ONLY accepts an application token as authentication.
- */
- @Test
- public void createMessageTest() {
- Message body = null;
- // Message response = api.createMessage(body);
-
- // TODO: test validations
- }
-
- /**
- * Delete all messages from a specific application.
- *
- *
- */
- @Test
- public void deleteAppMessagesTest() {
- Long id = null;
- // Void response = api.deleteAppMessages(id);
-
- // TODO: test validations
- }
-
- /**
- * Deletes a message with an id.
- *
- *
- */
- @Test
- public void deleteMessageTest() {
- Long id = null;
- // Void response = api.deleteMessage(id);
-
- // TODO: test validations
- }
-
- /**
- * Delete all messages.
- *
- *
- */
- @Test
- public void deleteMessagesTest() {
- // Void response = api.deleteMessages();
-
- // TODO: test validations
- }
-
- /**
- * Return all messages from a specific application.
- *
- *
- */
- @Test
- public void getAppMessagesTest() {
- Long id = null;
- Integer limit = null;
- Long since = null;
- // PagedMessages response = api.getAppMessages(id, limit, since);
-
- // TODO: test validations
- }
-
- /**
- * Return all messages.
- *
- *
- */
- @Test
- public void getMessagesTest() {
- Integer limit = null;
- Long since = null;
- // PagedMessages response = api.getMessages(limit, since);
-
- // TODO: test validations
- }
-
- /**
- * Websocket, return newly created messages.
- *
- *
- */
- @Test
- public void streamMessagesTest() {
- // Message response = api.streamMessages();
-
- // TODO: test validations
- }
-}
diff --git a/client/src/test/java/com/github/gotify/client/api/PluginApiTest.java b/client/src/test/java/com/github/gotify/client/api/PluginApiTest.java
deleted file mode 100644
index 48bbf472..00000000
--- a/client/src/test/java/com/github/gotify/client/api/PluginApiTest.java
+++ /dev/null
@@ -1,105 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.Error;
-import com.github.gotify.client.model.PluginConf;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for PluginApi
- */
-public class PluginApiTest {
-
- private PluginApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(PluginApi.class);
- }
-
-
- /**
- * Disable a plugin.
- *
- *
- */
- @Test
- public void disablePluginTest() {
- Long id = null;
- // Void response = api.disablePlugin(id);
-
- // TODO: test validations
- }
-
- /**
- * Enable a plugin.
- *
- *
- */
- @Test
- public void enablePluginTest() {
- Long id = null;
- // Void response = api.enablePlugin(id);
-
- // TODO: test validations
- }
-
- /**
- * Get YAML configuration for Configurer plugin.
- *
- *
- */
- @Test
- public void getPluginConfigTest() {
- Long id = null;
- // Object response = api.getPluginConfig(id);
-
- // TODO: test validations
- }
-
- /**
- * Get display info for a Displayer plugin.
- *
- *
- */
- @Test
- public void getPluginDisplayTest() {
- Long id = null;
- // String response = api.getPluginDisplay(id);
-
- // TODO: test validations
- }
-
- /**
- * Return all plugins.
- *
- *
- */
- @Test
- public void getPluginsTest() {
- // List response = api.getPlugins();
-
- // TODO: test validations
- }
-
- /**
- * Update YAML configuration for Configurer plugin.
- *
- *
- */
- @Test
- public void updatePluginConfigTest() {
- Long id = null;
- // Void response = api.updatePluginConfig(id);
-
- // TODO: test validations
- }
-}
diff --git a/client/src/test/java/com/github/gotify/client/api/UserApiTest.java b/client/src/test/java/com/github/gotify/client/api/UserApiTest.java
deleted file mode 100644
index 48a1f0cf..00000000
--- a/client/src/test/java/com/github/gotify/client/api/UserApiTest.java
+++ /dev/null
@@ -1,121 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.CreateUserExternal;
-import com.github.gotify.client.model.Error;
-import com.github.gotify.client.model.UpdateUserExternal;
-import com.github.gotify.client.model.User;
-import com.github.gotify.client.model.UserPass;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for UserApi
- */
-public class UserApiTest {
-
- private UserApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(UserApi.class);
- }
-
-
- /**
- * Create a user.
- *
- * With enabled registration: non admin users can be created without authentication. With disabled registrations: users can only be created by admin users.
- */
- @Test
- public void createUserTest() {
- CreateUserExternal body = null;
- // User response = api.createUser(body);
-
- // TODO: test validations
- }
-
- /**
- * Return the current user.
- *
- *
- */
- @Test
- public void currentUserTest() {
- // User response = api.currentUser();
-
- // TODO: test validations
- }
-
- /**
- * Deletes a user.
- *
- *
- */
- @Test
- public void deleteUserTest() {
- Long id = null;
- // Void response = api.deleteUser(id);
-
- // TODO: test validations
- }
-
- /**
- * Get a user.
- *
- *
- */
- @Test
- public void getUserTest() {
- Long id = null;
- // User response = api.getUser(id);
-
- // TODO: test validations
- }
-
- /**
- * Return all users.
- *
- *
- */
- @Test
- public void getUsersTest() {
- // List response = api.getUsers();
-
- // TODO: test validations
- }
-
- /**
- * Update the password of the current user.
- *
- *
- */
- @Test
- public void updateCurrentUserTest() {
- UserPass body = null;
- // Void response = api.updateCurrentUser(body);
-
- // TODO: test validations
- }
-
- /**
- * Update a user.
- *
- *
- */
- @Test
- public void updateUserTest() {
- UpdateUserExternal body = null;
- Long id = null;
- // User response = api.updateUser(body, id);
-
- // TODO: test validations
- }
-}
diff --git a/client/src/test/java/com/github/gotify/client/api/VersionApiTest.java b/client/src/test/java/com/github/gotify/client/api/VersionApiTest.java
deleted file mode 100644
index 0890b525..00000000
--- a/client/src/test/java/com/github/gotify/client/api/VersionApiTest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package com.github.gotify.client.api;
-
-import com.github.gotify.client.ApiClient;
-import com.github.gotify.client.model.VersionInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * API tests for VersionApi
- */
-public class VersionApiTest {
-
- private VersionApi api;
-
- @Before
- public void setup() {
- api = new ApiClient().createService(VersionApi.class);
- }
-
-
- /**
- * Get version information.
- *
- *
- */
- @Test
- public void getVersionTest() {
- // VersionInfo response = api.getVersion();
-
- // TODO: test validations
- }
-}
diff --git a/swagger.config.json b/swagger.config.json
deleted file mode 100644
index 4d0673bd..00000000
--- a/swagger.config.json
+++ /dev/null
@@ -1,7 +0,0 @@
-{
- "apiPackage": "com.github.gotify.client.api",
- "modelPackage": "com.github.gotify.client.model",
- "library": "retrofit2",
- "java11": true,
- "hideGenerationTimestamp": true
-}
\ No newline at end of file