Generate new client version
This commit is contained in:
@@ -1 +1 @@
|
|||||||
2.3.1
|
3.0.63
|
||||||
@@ -36,4 +36,3 @@ After the client library is installed/deployed, you can use it in your Maven pro
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,32 +1,59 @@
|
|||||||
apply plugin: 'idea'
|
plugins {
|
||||||
apply plugin: 'eclipse'
|
id 'java'
|
||||||
|
id 'maven-publish'
|
||||||
group = 'io.swagger'
|
}
|
||||||
version = '1.0.0'
|
|
||||||
|
|
||||||
apply plugin: 'java-library'
|
|
||||||
|
|
||||||
sourceCompatibility = JavaVersion.VERSION_1_7
|
|
||||||
targetCompatibility = JavaVersion.VERSION_1_7
|
|
||||||
|
|
||||||
ext {
|
ext {
|
||||||
oltu_version = "1.0.2"
|
oltu_version = "1.0.2"
|
||||||
retrofit_version = "2.5.0"
|
retrofit_version = "2.7.1"
|
||||||
swagger_annotations_version = "1.5.15"
|
swagger_annotations_version = "2.0.0"
|
||||||
junit_version = "4.13"
|
junit_version = "4.12"
|
||||||
threetenbp_version = "1.4.4"
|
threetenbp_version = "1.4.1"
|
||||||
json_fire_version = "1.8.4"
|
json_fire_version = "1.8.3"
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api "com.squareup.retrofit2:retrofit:$retrofit_version"
|
implementation "com.squareup.retrofit2:retrofit:$retrofit_version"
|
||||||
api "com.squareup.retrofit2:converter-scalars:$retrofit_version"
|
implementation "com.squareup.retrofit2:converter-scalars:$retrofit_version"
|
||||||
api "com.squareup.retrofit2:converter-gson:$retrofit_version"
|
implementation "com.squareup.retrofit2:converter-gson:$retrofit_version"
|
||||||
api "io.swagger:swagger-annotations:$swagger_annotations_version"
|
implementation "io.swagger.core.v3:swagger-annotations:$swagger_annotations_version"
|
||||||
implementation ("org.apache.oltu.oauth2:org.apache.oltu.oauth2.client:$oltu_version") {
|
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.apache.oltu.oauth2' , module: 'org.apache.oltu.oauth2.common'
|
||||||
|
exclude group: 'org.json', module: 'json'
|
||||||
}
|
}
|
||||||
api "io.gsonfire:gson-fire:$json_fire_version"
|
implementation "org.json:json:20180130"
|
||||||
api "org.threeten:threetenbp:$threetenbp_version"
|
implementation "io.gsonfire:gson-fire:$json_fire_version"
|
||||||
|
implementation "org.threeten:threetenbp:$threetenbp_version"
|
||||||
|
|
||||||
testImplementation "junit:junit:$junit_version"
|
testImplementation "junit:junit:$junit_version"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
group = 'io.swagger'
|
||||||
|
version = '1.0.0'
|
||||||
|
description = 'Swagger Java'
|
||||||
|
|
||||||
|
java.sourceCompatibility = 11
|
||||||
|
java.targetCompatibility = 11
|
||||||
|
|
||||||
|
tasks.register('testsJar', Jar) {
|
||||||
|
archiveClassifier = 'tests'
|
||||||
|
from(sourceSets.test.output)
|
||||||
|
}
|
||||||
|
|
||||||
|
java {
|
||||||
|
withSourcesJar()
|
||||||
|
withJavadocJar()
|
||||||
|
}
|
||||||
|
|
||||||
|
publishing {
|
||||||
|
publications {
|
||||||
|
maven(MavenPublication) {
|
||||||
|
from(components.java)
|
||||||
|
artifact(testsJar)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
tasks.withType(JavaCompile) {
|
||||||
|
options.encoding = 'UTF-8'
|
||||||
|
}
|
||||||
|
|||||||
@@ -12,8 +12,8 @@ lazy val root = (project in file(".")).
|
|||||||
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
|
"com.squareup.retrofit2" % "retrofit" % "2.3.0" % "compile",
|
||||||
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
|
"com.squareup.retrofit2" % "converter-scalars" % "2.3.0" % "compile",
|
||||||
"com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
|
"com.squareup.retrofit2" % "converter-gson" % "2.3.0" % "compile",
|
||||||
"io.swagger" % "swagger-annotations" % "1.5.15" % "compile",
|
"io.swagger.core.v3" % "swagger-annotations" % "2.0.0" % "compile",
|
||||||
"org.apache.oltu.oauth2" % "org.apache.oltu.oauth2.client" % "1.0.1" % "compile",
|
"org.apache.oltu.oauth2" % "org.apache.oltu.oauth2.client" % "1.0.2" % "compile",
|
||||||
"org.threeten" % "threetenbp" % "1.3.5" % "compile",
|
"org.threeten" % "threetenbp" % "1.3.5" % "compile",
|
||||||
"io.gsonfire" % "gson-fire" % "1.8.0" % "compile",
|
"io.gsonfire" % "gson-fire" % "1.8.0" % "compile",
|
||||||
"junit" % "junit" % "4.12" % "test",
|
"junit" % "junit" % "4.12" % "test",
|
||||||
|
|||||||
@@ -1,15 +1,13 @@
|
|||||||
|
|
||||||
# Application
|
# Application
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
Name | Type | Description | Notes
|
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. |
|
**description** | **String** | The description of the application. |
|
||||||
**id** | **Long** | The application id. |
|
**id** | **Long** | The application id. |
|
||||||
**image** | **String** | The image of the application. |
|
**image** | **String** | The image of the application. |
|
||||||
**internal** | **Boolean** | Whether the application is an internal application. Internal applications should not be deleted. |
|
**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. |
|
**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. |
|
**token** | **String** | The application token. Can be used as `appToken`. See Authentication. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
# ApplicationApi
|
# ApplicationApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
[**createApp**](ApplicationApi.md#createApp) | **POST** application | Create an application.
|
[**createApp**](ApplicationApi.md#createApp) | **POST** application | Create an application.
|
||||||
[**deleteApp**](ApplicationApi.md#deleteApp) | **DELETE** application/{id} | Delete an application.
|
[**deleteApp**](ApplicationApi.md#deleteApp) | **DELETE** application/{id} | Delete an application.
|
||||||
[**getApps**](ApplicationApi.md#getApps) | **GET** application | Return all applications.
|
[**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.
|
[**updateApplication**](ApplicationApi.md#updateApplication) | **PUT** application/{id} | Update an application.
|
||||||
[**uploadAppImage**](ApplicationApi.md#uploadAppImage) | **POST** application/{id}/image | Upload an image for an application.
|
[**uploadAppImage**](ApplicationApi.md#uploadAppImage) | **POST** application/{id}/image | Upload an image for an application.
|
||||||
|
|
||||||
|
|
||||||
<a name="createApp"></a>
|
<a name="createApp"></a>
|
||||||
# **createApp**
|
# **createApp**
|
||||||
> Application createApp(body)
|
> Application createApp(body)
|
||||||
@@ -27,12 +27,17 @@ Create an application.
|
|||||||
//import com.github.gotify.client.api.ApplicationApi;
|
//import com.github.gotify.client.api.ApplicationApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -46,7 +51,7 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
ApplicationApi apiInstance = new ApplicationApi();
|
ApplicationApi apiInstance = new ApplicationApi();
|
||||||
Application body = new Application(); // Application | the application to add
|
ApplicationParams body = new ApplicationParams(); // ApplicationParams | the application to add
|
||||||
try {
|
try {
|
||||||
Application result = apiInstance.createApp(body);
|
Application result = apiInstance.createApp(body);
|
||||||
System.out.println(result);
|
System.out.println(result);
|
||||||
@@ -60,7 +65,7 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**Application**](Application.md)| the application to add |
|
**body** | [**ApplicationParams**](ApplicationParams.md)| the application to add |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@@ -68,7 +73,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@@ -91,12 +96,17 @@ Delete an application.
|
|||||||
//import com.github.gotify.client.api.ApplicationApi;
|
//import com.github.gotify.client.api.ApplicationApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -132,11 +142,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getApps"></a>
|
<a name="getApps"></a>
|
||||||
@@ -155,12 +165,17 @@ Return all applications.
|
|||||||
//import com.github.gotify.client.api.ApplicationApi;
|
//import com.github.gotify.client.api.ApplicationApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -192,11 +207,80 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
|
- **Accept**: application/json
|
||||||
|
|
||||||
|
<a name="removeAppImage"></a>
|
||||||
|
# **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
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="updateApplication"></a>
|
<a name="updateApplication"></a>
|
||||||
@@ -215,12 +299,17 @@ Update an application.
|
|||||||
//import com.github.gotify.client.api.ApplicationApi;
|
//import com.github.gotify.client.api.ApplicationApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -234,7 +323,7 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
ApplicationApi apiInstance = new ApplicationApi();
|
ApplicationApi apiInstance = new ApplicationApi();
|
||||||
Application body = new Application(); // Application | the application to update
|
ApplicationParams body = new ApplicationParams(); // ApplicationParams | the application to update
|
||||||
Long id = 789L; // Long | the application id
|
Long id = 789L; // Long | the application id
|
||||||
try {
|
try {
|
||||||
Application result = apiInstance.updateApplication(body, id);
|
Application result = apiInstance.updateApplication(body, id);
|
||||||
@@ -249,7 +338,7 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**Application**](Application.md)| the application to update |
|
**body** | [**ApplicationParams**](ApplicationParams.md)| the application to update |
|
||||||
**id** | **Long**| the application id |
|
**id** | **Long**| the application id |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
@@ -258,7 +347,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@@ -281,12 +370,17 @@ Upload an image for an application.
|
|||||||
//import com.github.gotify.client.api.ApplicationApi;
|
//import com.github.gotify.client.api.ApplicationApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -300,7 +394,7 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
ApplicationApi apiInstance = new ApplicationApi();
|
ApplicationApi apiInstance = new ApplicationApi();
|
||||||
File file = new File("/path/to/file.txt"); // File | the application image
|
File file = new File("file_example"); // File |
|
||||||
Long id = 789L; // Long | the application id
|
Long id = 789L; // Long | the application id
|
||||||
try {
|
try {
|
||||||
Application result = apiInstance.uploadAppImage(file, id);
|
Application result = apiInstance.uploadAppImage(file, id);
|
||||||
@@ -315,7 +409,7 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**file** | **File**| the application image |
|
**file** | **File**| |
|
||||||
**id** | **Long**| the application id |
|
**id** | **Long**| the application id |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
@@ -324,7 +418,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
|||||||
8
client/docs/ApplicationParams.md
Normal file
8
client/docs/ApplicationParams.md
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# 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. |
|
||||||
@@ -1,12 +1,9 @@
|
|||||||
|
|
||||||
# Client
|
# Client
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**id** | **Long** | The client id. |
|
**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. |
|
**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. |
|
**token** | **String** | The client token. Can be used as `clientToken`. See Authentication. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# ClientApi
|
# ClientApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
@@ -9,7 +9,6 @@ Method | HTTP request | Description
|
|||||||
[**getClients**](ClientApi.md#getClients) | **GET** client | Return all clients.
|
[**getClients**](ClientApi.md#getClients) | **GET** client | Return all clients.
|
||||||
[**updateClient**](ClientApi.md#updateClient) | **PUT** client/{id} | Update a client.
|
[**updateClient**](ClientApi.md#updateClient) | **PUT** client/{id} | Update a client.
|
||||||
|
|
||||||
|
|
||||||
<a name="createClient"></a>
|
<a name="createClient"></a>
|
||||||
# **createClient**
|
# **createClient**
|
||||||
> Client createClient(body)
|
> Client createClient(body)
|
||||||
@@ -26,12 +25,17 @@ Create a client.
|
|||||||
//import com.github.gotify.client.api.ClientApi;
|
//import com.github.gotify.client.api.ClientApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -45,7 +49,7 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
ClientApi apiInstance = new ClientApi();
|
ClientApi apiInstance = new ClientApi();
|
||||||
Client body = new Client(); // Client | the client to add
|
ClientParams body = new ClientParams(); // ClientParams | the client to add
|
||||||
try {
|
try {
|
||||||
Client result = apiInstance.createClient(body);
|
Client result = apiInstance.createClient(body);
|
||||||
System.out.println(result);
|
System.out.println(result);
|
||||||
@@ -59,7 +63,7 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**Client**](Client.md)| the client to add |
|
**body** | [**ClientParams**](ClientParams.md)| the client to add |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@@ -67,7 +71,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@@ -90,12 +94,17 @@ Delete a client.
|
|||||||
//import com.github.gotify.client.api.ClientApi;
|
//import com.github.gotify.client.api.ClientApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -131,11 +140,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getClients"></a>
|
<a name="getClients"></a>
|
||||||
@@ -154,12 +163,17 @@ Return all clients.
|
|||||||
//import com.github.gotify.client.api.ClientApi;
|
//import com.github.gotify.client.api.ClientApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -191,11 +205,11 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="updateClient"></a>
|
<a name="updateClient"></a>
|
||||||
@@ -214,12 +228,17 @@ Update a client.
|
|||||||
//import com.github.gotify.client.api.ClientApi;
|
//import com.github.gotify.client.api.ClientApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -233,7 +252,7 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
ClientApi apiInstance = new ClientApi();
|
ClientApi apiInstance = new ClientApi();
|
||||||
Client body = new Client(); // Client | the client to update
|
ClientParams body = new ClientParams(); // ClientParams | the client to update
|
||||||
Long id = 789L; // Long | the client id
|
Long id = 789L; // Long | the client id
|
||||||
try {
|
try {
|
||||||
Client result = apiInstance.updateClient(body, id);
|
Client result = apiInstance.updateClient(body, id);
|
||||||
@@ -248,7 +267,7 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**Client**](Client.md)| the client to update |
|
**body** | [**ClientParams**](ClientParams.md)| the client to update |
|
||||||
**id** | **Long**| the client id |
|
**id** | **Long**| the client id |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
@@ -257,7 +276,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
|||||||
6
client/docs/ClientParams.md
Normal file
6
client/docs/ClientParams.md
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# ClientParams
|
||||||
|
|
||||||
|
## Properties
|
||||||
|
Name | Type | Description | Notes
|
||||||
|
------------ | ------------- | ------------- | -------------
|
||||||
|
**name** | **String** | The client name |
|
||||||
@@ -1,13 +1,8 @@
|
|||||||
|
# CreateUserExternal
|
||||||
# UserWithPass
|
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**admin** | **Boolean** | If the user is an administrator. | [optional]
|
**admin** | **Boolean** | If the user is an administrator. |
|
||||||
**id** | **Long** | The user id. |
|
|
||||||
**name** | **String** | The user name. For login. |
|
**name** | **String** | The user name. For login. |
|
||||||
**pass** | **String** | The user password. For login. |
|
**pass** | **String** | The user password. For login. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# Error
|
# Error
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -7,6 +6,3 @@ Name | Type | Description | Notes
|
|||||||
**error** | **String** | The general error message |
|
**error** | **String** | The general error message |
|
||||||
**errorCode** | **Long** | The http error code. |
|
**errorCode** | **Long** | The http error code. |
|
||||||
**errorDescription** | **String** | The http error code. |
|
**errorDescription** | **String** | The http error code. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# Health
|
# Health
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -6,6 +5,3 @@ Name | Type | Description | Notes
|
|||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**database** | **String** | The health of the database connection. |
|
**database** | **String** | The health of the database connection. |
|
||||||
**health** | **String** | The health of the overall application. |
|
**health** | **String** | The health of the overall application. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
# HealthApi
|
# HealthApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
[**getHealth**](HealthApi.md#getHealth) | **GET** health | Get health information.
|
[**getHealth**](HealthApi.md#getHealth) | **GET** health | Get health information.
|
||||||
|
|
||||||
|
|
||||||
<a name="getHealth"></a>
|
<a name="getHealth"></a>
|
||||||
# **getHealth**
|
# **getHealth**
|
||||||
> Health getHealth()
|
> Health getHealth()
|
||||||
@@ -43,6 +42,6 @@ No authorization required
|
|||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
|
|||||||
6
client/docs/IdImageBody.md
Normal file
6
client/docs/IdImageBody.md
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# IdImageBody
|
||||||
|
|
||||||
|
## Properties
|
||||||
|
Name | Type | Description | Notes
|
||||||
|
------------ | ------------- | ------------- | -------------
|
||||||
|
**file** | [**File**](File.md) | the application image |
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# Message
|
# Message
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -9,8 +8,5 @@ Name | Type | Description | Notes
|
|||||||
**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: &lt;top-namespace&gt;::[&lt;sub-namespace&gt;::]&lt;action&gt; 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]
|
**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: &lt;top-namespace&gt;::[&lt;sub-namespace&gt;::]&lt;action&gt; 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. |
|
**id** | **Long** | The message id. |
|
||||||
**message** | **String** | The message. Markdown (excluding html) is allowed. |
|
**message** | **String** | The message. Markdown (excluding html) is allowed. |
|
||||||
**priority** | **Long** | The priority of the message. | [optional]
|
**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]
|
**title** | **String** | The title of the message. | [optional]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# MessageApi
|
# MessageApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
@@ -12,7 +12,6 @@ Method | HTTP request | Description
|
|||||||
[**getMessages**](MessageApi.md#getMessages) | **GET** message | Return all messages.
|
[**getMessages**](MessageApi.md#getMessages) | **GET** message | Return all messages.
|
||||||
[**streamMessages**](MessageApi.md#streamMessages) | **GET** stream | Websocket, return newly created messages.
|
[**streamMessages**](MessageApi.md#streamMessages) | **GET** stream | Websocket, return newly created messages.
|
||||||
|
|
||||||
|
|
||||||
<a name="createMessage"></a>
|
<a name="createMessage"></a>
|
||||||
# **createMessage**
|
# **createMessage**
|
||||||
> Message createMessage(body)
|
> Message createMessage(body)
|
||||||
@@ -32,6 +31,12 @@ __NOTE__: This API ONLY accepts an application token as authentication.
|
|||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
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
|
// Configure API key authorization: appTokenHeader
|
||||||
ApiKeyAuth appTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("appTokenHeader");
|
ApiKeyAuth appTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("appTokenHeader");
|
||||||
appTokenHeader.setApiKey("YOUR API KEY");
|
appTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -67,7 +72,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[appTokenHeader](../README.md#appTokenHeader), [appTokenQuery](../README.md#appTokenQuery)
|
[appTokenAuthorizationHeader](../README.md#appTokenAuthorizationHeader)[appTokenHeader](../README.md#appTokenHeader)[appTokenQuery](../README.md#appTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@@ -90,12 +95,17 @@ Delete all messages from a specific application.
|
|||||||
//import com.github.gotify.client.api.MessageApi;
|
//import com.github.gotify.client.api.MessageApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -131,11 +141,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="deleteMessage"></a>
|
<a name="deleteMessage"></a>
|
||||||
@@ -154,12 +164,17 @@ Deletes a message with an id.
|
|||||||
//import com.github.gotify.client.api.MessageApi;
|
//import com.github.gotify.client.api.MessageApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -195,11 +210,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="deleteMessages"></a>
|
<a name="deleteMessages"></a>
|
||||||
@@ -218,12 +233,17 @@ Delete all messages.
|
|||||||
//import com.github.gotify.client.api.MessageApi;
|
//import com.github.gotify.client.api.MessageApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -255,11 +275,11 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getAppMessages"></a>
|
<a name="getAppMessages"></a>
|
||||||
@@ -278,12 +298,17 @@ Return all messages from a specific application.
|
|||||||
//import com.github.gotify.client.api.MessageApi;
|
//import com.github.gotify.client.api.MessageApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -314,8 +339,8 @@ try {
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**id** | **Long**| the application id |
|
**id** | **Long**| the application id |
|
||||||
**limit** | **Integer**| the maximal amount of messages to return | [optional] [default to 100]
|
**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]
|
**since** | **Long**| return all messages with an ID less than this value | [optional] [enum: 0]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@@ -323,11 +348,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getMessages"></a>
|
<a name="getMessages"></a>
|
||||||
@@ -346,12 +371,17 @@ Return all messages.
|
|||||||
//import com.github.gotify.client.api.MessageApi;
|
//import com.github.gotify.client.api.MessageApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -380,8 +410,8 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**limit** | **Integer**| the maximal amount of messages to return | [optional] [default to 100]
|
**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]
|
**since** | **Long**| return all messages with an ID less than this value | [optional] [enum: 0]
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@@ -389,11 +419,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="streamMessages"></a>
|
<a name="streamMessages"></a>
|
||||||
@@ -412,12 +442,17 @@ Websocket, return newly created messages.
|
|||||||
//import com.github.gotify.client.api.MessageApi;
|
//import com.github.gotify.client.api.MessageApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -449,10 +484,10 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# PagedMessages
|
# PagedMessages
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -6,6 +5,3 @@ Name | Type | Description | Notes
|
|||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**messages** | [**List<Message>**](Message.md) | The messages. |
|
**messages** | [**List<Message>**](Message.md) | The messages. |
|
||||||
**paging** | [**Paging**](Paging.md) | |
|
**paging** | [**Paging**](Paging.md) | |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# Paging
|
# Paging
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -8,6 +7,3 @@ Name | Type | Description | Notes
|
|||||||
**next** | **String** | The request url for the next page. Empty/Null when no next page is available. | [optional]
|
**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. |
|
**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. |
|
**size** | **Long** | The amount of messages that got returned in the current request. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# PluginApi
|
# PluginApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
@@ -11,7 +11,6 @@ Method | HTTP request | Description
|
|||||||
[**getPlugins**](PluginApi.md#getPlugins) | **GET** plugin | Return all plugins.
|
[**getPlugins**](PluginApi.md#getPlugins) | **GET** plugin | Return all plugins.
|
||||||
[**updatePluginConfig**](PluginApi.md#updatePluginConfig) | **POST** plugin/{id}/config | Update YAML configuration for Configurer plugin.
|
[**updatePluginConfig**](PluginApi.md#updatePluginConfig) | **POST** plugin/{id}/config | Update YAML configuration for Configurer plugin.
|
||||||
|
|
||||||
|
|
||||||
<a name="disablePlugin"></a>
|
<a name="disablePlugin"></a>
|
||||||
# **disablePlugin**
|
# **disablePlugin**
|
||||||
> Void disablePlugin(id)
|
> Void disablePlugin(id)
|
||||||
@@ -28,12 +27,17 @@ Disable a plugin.
|
|||||||
//import com.github.gotify.client.api.PluginApi;
|
//import com.github.gotify.client.api.PluginApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -69,11 +73,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="enablePlugin"></a>
|
<a name="enablePlugin"></a>
|
||||||
@@ -92,12 +96,17 @@ Enable a plugin.
|
|||||||
//import com.github.gotify.client.api.PluginApi;
|
//import com.github.gotify.client.api.PluginApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -133,11 +142,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getPluginConfig"></a>
|
<a name="getPluginConfig"></a>
|
||||||
@@ -156,12 +165,17 @@ Get YAML configuration for Configurer plugin.
|
|||||||
//import com.github.gotify.client.api.PluginApi;
|
//import com.github.gotify.client.api.PluginApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -197,11 +211,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/x-yaml
|
- **Accept**: application/x-yaml
|
||||||
|
|
||||||
<a name="getPluginDisplay"></a>
|
<a name="getPluginDisplay"></a>
|
||||||
@@ -220,12 +234,17 @@ Get display info for a Displayer plugin.
|
|||||||
//import com.github.gotify.client.api.PluginApi;
|
//import com.github.gotify.client.api.PluginApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -261,11 +280,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getPlugins"></a>
|
<a name="getPlugins"></a>
|
||||||
@@ -284,12 +303,17 @@ Return all plugins.
|
|||||||
//import com.github.gotify.client.api.PluginApi;
|
//import com.github.gotify.client.api.PluginApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -321,11 +345,11 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="updatePluginConfig"></a>
|
<a name="updatePluginConfig"></a>
|
||||||
@@ -344,12 +368,17 @@ Update YAML configuration for Configurer plugin.
|
|||||||
//import com.github.gotify.client.api.PluginApi;
|
//import com.github.gotify.client.api.PluginApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -385,10 +414,10 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/x-yaml
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# PluginConf
|
# PluginConf
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -13,6 +12,3 @@ Name | Type | Description | Notes
|
|||||||
**name** | **String** | The plugin name. |
|
**name** | **String** | The plugin name. |
|
||||||
**token** | **String** | The user name. For login. |
|
**token** | **String** | The user name. For login. |
|
||||||
**website** | **String** | The website of the plugin. | [optional]
|
**website** | **String** | The website of the plugin. | [optional]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
8
client/docs/UpdateUserExternal.md
Normal file
8
client/docs/UpdateUserExternal.md
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# 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]
|
||||||
@@ -1,12 +1,8 @@
|
|||||||
|
|
||||||
# User
|
# User
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**admin** | **Boolean** | If the user is an administrator. | [optional]
|
**admin** | **Boolean** | If the user is an administrator. |
|
||||||
**id** | **Long** | The user id. |
|
**id** | **Long** | The user id. |
|
||||||
**name** | **String** | The user name. For login. |
|
**name** | **String** | The user name. For login. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# UserApi
|
# UserApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
@@ -12,13 +12,14 @@ Method | HTTP request | Description
|
|||||||
[**updateCurrentUser**](UserApi.md#updateCurrentUser) | **POST** current/user/password | Update the password of the current user.
|
[**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.
|
[**updateUser**](UserApi.md#updateUser) | **POST** user/{id} | Update a user.
|
||||||
|
|
||||||
|
|
||||||
<a name="createUser"></a>
|
<a name="createUser"></a>
|
||||||
# **createUser**
|
# **createUser**
|
||||||
> User createUser(body)
|
> User createUser(body)
|
||||||
|
|
||||||
Create a user.
|
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
|
### Example
|
||||||
```java
|
```java
|
||||||
// Import classes:
|
// Import classes:
|
||||||
@@ -29,12 +30,17 @@ Create a user.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -48,7 +54,7 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
UserApi apiInstance = new UserApi();
|
UserApi apiInstance = new UserApi();
|
||||||
UserWithPass body = new UserWithPass(); // UserWithPass | the user to add
|
CreateUserExternal body = new CreateUserExternal(); // CreateUserExternal | the user to add
|
||||||
try {
|
try {
|
||||||
User result = apiInstance.createUser(body);
|
User result = apiInstance.createUser(body);
|
||||||
System.out.println(result);
|
System.out.println(result);
|
||||||
@@ -62,7 +68,7 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | [**UserWithPass**](UserWithPass.md)| the user to add |
|
**body** | [**CreateUserExternal**](CreateUserExternal.md)| the user to add |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@@ -70,7 +76,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@@ -93,12 +99,17 @@ Return the current user.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -130,11 +141,11 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="deleteUser"></a>
|
<a name="deleteUser"></a>
|
||||||
@@ -153,12 +164,17 @@ Deletes a user.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -194,11 +210,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getUser"></a>
|
<a name="getUser"></a>
|
||||||
@@ -217,12 +233,17 @@ Get a user.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -258,11 +279,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="getUsers"></a>
|
<a name="getUsers"></a>
|
||||||
@@ -281,12 +302,17 @@ Return all users.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -318,11 +344,11 @@ This endpoint does not need any parameter.
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
<a name="updateCurrentUser"></a>
|
<a name="updateCurrentUser"></a>
|
||||||
@@ -341,12 +367,17 @@ Update the password of the current user.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -382,7 +413,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
@@ -391,7 +422,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
<a name="updateUser"></a>
|
<a name="updateUser"></a>
|
||||||
# **updateUser**
|
# **updateUser**
|
||||||
> User updateUser(id, body)
|
> User updateUser(body, id)
|
||||||
|
|
||||||
Update a user.
|
Update a user.
|
||||||
|
|
||||||
@@ -405,12 +436,17 @@ Update a user.
|
|||||||
//import com.github.gotify.client.api.UserApi;
|
//import com.github.gotify.client.api.UserApi;
|
||||||
|
|
||||||
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
ApiClient defaultClient = Configuration.getDefaultApiClient();
|
||||||
|
|
||||||
// Configure HTTP basic authorization: basicAuth
|
// Configure HTTP basic authorization: basicAuth
|
||||||
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
|
||||||
basicAuth.setUsername("YOUR USERNAME");
|
basicAuth.setUsername("YOUR USERNAME");
|
||||||
basicAuth.setPassword("YOUR PASSWORD");
|
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
|
// Configure API key authorization: clientTokenHeader
|
||||||
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
ApiKeyAuth clientTokenHeader = (ApiKeyAuth) defaultClient.getAuthentication("clientTokenHeader");
|
||||||
clientTokenHeader.setApiKey("YOUR API KEY");
|
clientTokenHeader.setApiKey("YOUR API KEY");
|
||||||
@@ -424,10 +460,10 @@ clientTokenQuery.setApiKey("YOUR API KEY");
|
|||||||
//clientTokenQuery.setApiKeyPrefix("Token");
|
//clientTokenQuery.setApiKeyPrefix("Token");
|
||||||
|
|
||||||
UserApi apiInstance = new UserApi();
|
UserApi apiInstance = new UserApi();
|
||||||
|
UpdateUserExternal body = new UpdateUserExternal(); // UpdateUserExternal | the updated user
|
||||||
Long id = 789L; // Long | the user id
|
Long id = 789L; // Long | the user id
|
||||||
UserWithPass body = new UserWithPass(); // UserWithPass | the updated user
|
|
||||||
try {
|
try {
|
||||||
User result = apiInstance.updateUser(id, body);
|
User result = apiInstance.updateUser(body, id);
|
||||||
System.out.println(result);
|
System.out.println(result);
|
||||||
} catch (ApiException e) {
|
} catch (ApiException e) {
|
||||||
System.err.println("Exception when calling UserApi#updateUser");
|
System.err.println("Exception when calling UserApi#updateUser");
|
||||||
@@ -439,8 +475,8 @@ try {
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
|
**body** | [**UpdateUserExternal**](UpdateUserExternal.md)| the updated user |
|
||||||
**id** | **Long**| the user id |
|
**id** | **Long**| the user id |
|
||||||
**body** | [**UserWithPass**](UserWithPass.md)| the updated user |
|
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@@ -448,7 +484,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### Authorization
|
### Authorization
|
||||||
|
|
||||||
[basicAuth](../README.md#basicAuth), [clientTokenHeader](../README.md#clientTokenHeader), [clientTokenQuery](../README.md#clientTokenQuery)
|
[basicAuth](../README.md#basicAuth)[clientTokenAuthorizationHeader](../README.md#clientTokenAuthorizationHeader)[clientTokenHeader](../README.md#clientTokenHeader)[clientTokenQuery](../README.md#clientTokenQuery)
|
||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
|
|||||||
@@ -1,10 +1,6 @@
|
|||||||
|
|
||||||
# UserPass
|
# UserPass
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**pass** | **String** | The user password. For login. |
|
**pass** | **String** | The user password. For login. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
# VersionApi
|
# VersionApi
|
||||||
|
|
||||||
All URIs are relative to *http://localhost*
|
All URIs are relative to *http://localhost/*
|
||||||
|
|
||||||
Method | HTTP request | Description
|
Method | HTTP request | Description
|
||||||
------------- | ------------- | -------------
|
------------- | ------------- | -------------
|
||||||
[**getVersion**](VersionApi.md#getVersion) | **GET** version | Get version information.
|
[**getVersion**](VersionApi.md#getVersion) | **GET** version | Get version information.
|
||||||
|
|
||||||
|
|
||||||
<a name="getVersion"></a>
|
<a name="getVersion"></a>
|
||||||
# **getVersion**
|
# **getVersion**
|
||||||
> VersionInfo getVersion()
|
> VersionInfo getVersion()
|
||||||
@@ -43,6 +42,6 @@ No authorization required
|
|||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: application/json
|
- **Accept**: application/json
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# VersionInfo
|
# VersionInfo
|
||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
@@ -7,6 +6,3 @@ Name | Type | Description | Notes
|
|||||||
**buildDate** | **String** | The date on which this binary was built. |
|
**buildDate** | **String** | The date on which this binary was built. |
|
||||||
**commit** | **String** | The git commit hash on which this binary was built. |
|
**commit** | **String** | The git commit hash on which this binary was built. |
|
||||||
**version** | **String** | The current version. |
|
**version** | **String** | The current version. |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ git_remote=`git remote`
|
|||||||
if [ "$git_remote" = "" ]; then # git remote not defined
|
if [ "$git_remote" = "" ]; then # git remote not defined
|
||||||
|
|
||||||
if [ "$GIT_TOKEN" = "" ]; then
|
if [ "$GIT_TOKEN" = "" ]; then
|
||||||
echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
|
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
|
git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git
|
||||||
else
|
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}@github.com/${git_user_id}/${git_repo_id}.git
|
||||||
|
|||||||
BIN
client/gradle/wrapper/gradle-wrapper.jar
vendored
BIN
client/gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
@@ -1,6 +1,7 @@
|
|||||||
#Tue May 17 23:08:05 CST 2016
|
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
|
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
|
||||||
|
networkTimeout=10000
|
||||||
|
validateDistributionUrl=true
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.6-bin.zip
|
|
||||||
|
|||||||
467
client/pom.xml
467
client/pom.xml
@@ -1,249 +1,244 @@
|
|||||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>io.swagger</groupId>
|
<groupId>io.swagger</groupId>
|
||||||
<artifactId>swagger-java-client</artifactId>
|
<artifactId>swagger-java-client</artifactId>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<name>swagger-java-client</name>
|
<name>swagger-java-client</name>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
|
<url>https://github.com/swagger-api/swagger-codegen</url>
|
||||||
|
<description>Swagger Java</description>
|
||||||
|
<scm>
|
||||||
|
<connection>scm:git:git@github.com:swagger-api/swagger-codegen.git</connection>
|
||||||
|
<developerConnection>scm:git:git@github.com:swagger-api/swagger-codegen.git</developerConnection>
|
||||||
<url>https://github.com/swagger-api/swagger-codegen</url>
|
<url>https://github.com/swagger-api/swagger-codegen</url>
|
||||||
<description>Swagger Java</description>
|
</scm>
|
||||||
<scm>
|
<prerequisites>
|
||||||
<connection>scm:git:git@github.com:swagger-api/swagger-codegen.git</connection>
|
<maven>2.2.0</maven>
|
||||||
<developerConnection>scm:git:git@github.com:swagger-api/swagger-codegen.git</developerConnection>
|
</prerequisites>
|
||||||
<url>https://github.com/swagger-api/swagger-codegen</url>
|
|
||||||
</scm>
|
|
||||||
|
|
||||||
<licenses>
|
<licenses>
|
||||||
<license>
|
<license>
|
||||||
<name>Unlicense</name>
|
<name>Unlicense</name>
|
||||||
<url>https://github.com/gotify/server/blob/master/LICENSE</url>
|
<url>https://github.com/gotify/server/blob/master/LICENSE</url>
|
||||||
<distribution>repo</distribution>
|
<distribution>repo</distribution>
|
||||||
</license>
|
</license>
|
||||||
</licenses>
|
</licenses>
|
||||||
|
|
||||||
<developers>
|
<developers>
|
||||||
<developer>
|
<developer>
|
||||||
<name>Swagger</name>
|
<name>Swagger</name>
|
||||||
<email>apiteam@swagger.io</email>
|
<email>apiteam@swagger.io</email>
|
||||||
<organization>Swagger</organization>
|
<organization>Swagger</organization>
|
||||||
<organizationUrl>http://swagger.io</organizationUrl>
|
<organizationUrl>http://swagger.io</organizationUrl>
|
||||||
</developer>
|
</developer>
|
||||||
</developers>
|
</developers>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-surefire-plugin</artifactId>
|
||||||
|
<version>2.12</version>
|
||||||
|
<configuration>
|
||||||
|
<systemProperties>
|
||||||
|
<property>
|
||||||
|
<name>loggerPath</name>
|
||||||
|
<value>conf/log4j.properties</value>
|
||||||
|
</property>
|
||||||
|
</systemProperties>
|
||||||
|
<argLine>-Xms512m -Xmx1500m</argLine>
|
||||||
|
<parallel>methods</parallel>
|
||||||
|
<forkMode>pertest</forkMode>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<artifactId>maven-dependency-plugin</artifactId>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>copy-dependencies</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<outputDirectory>${project.build.directory}/lib</outputDirectory>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<!-- attach test jar -->
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-jar-plugin</artifactId>
|
||||||
|
<version>2.2</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
<goal>test-jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
<configuration>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.codehaus.mojo</groupId>
|
||||||
|
<artifactId>build-helper-maven-plugin</artifactId>
|
||||||
|
<version>1.10</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>add_sources</id>
|
||||||
|
<phase>generate-sources</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>add-source</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<sources>
|
||||||
|
<source>src/main/java</source>
|
||||||
|
</sources>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
<execution>
|
||||||
|
<id>add_test_sources</id>
|
||||||
|
<phase>generate-test-sources</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>add-test-source</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<sources>
|
||||||
|
<source>src/test/java</source>
|
||||||
|
</sources>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>3.2.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-javadocs</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-source-plugin</artifactId>
|
||||||
|
<version>2.2.1</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-sources</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar-no-fork</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
<profiles>
|
||||||
|
<profile>
|
||||||
|
<id>sign-artifacts</id>
|
||||||
|
<build>
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-enforcer-plugin</artifactId>
|
<artifactId>maven-gpg-plugin</artifactId>
|
||||||
<version>3.0.0-M1</version>
|
<version>1.5</version>
|
||||||
<executions>
|
<executions>
|
||||||
<execution>
|
<execution>
|
||||||
<id>enforce-maven</id>
|
<id>sign-artifacts</id>
|
||||||
<goals>
|
<phase>verify</phase>
|
||||||
<goal>enforce</goal>
|
<goals>
|
||||||
</goals>
|
<goal>sign</goal>
|
||||||
<configuration>
|
</goals>
|
||||||
<rules>
|
</execution>
|
||||||
<requireMavenVersion>
|
</executions>
|
||||||
<version>2.2.0</version>
|
</plugin>
|
||||||
</requireMavenVersion>
|
|
||||||
</rules>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-surefire-plugin</artifactId>
|
|
||||||
<version>2.12</version>
|
|
||||||
<configuration>
|
|
||||||
<systemProperties>
|
|
||||||
<property>
|
|
||||||
<name>loggerPath</name>
|
|
||||||
<value>conf/log4j.properties</value>
|
|
||||||
</property>
|
|
||||||
</systemProperties>
|
|
||||||
<argLine>-Xms512m -Xmx1500m</argLine>
|
|
||||||
<parallel>methods</parallel>
|
|
||||||
<forkMode>pertest</forkMode>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<artifactId>maven-dependency-plugin</artifactId>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<phase>package</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>copy-dependencies</goal>
|
|
||||||
</goals>
|
|
||||||
<configuration>
|
|
||||||
<outputDirectory>${project.build.directory}/lib</outputDirectory>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
|
|
||||||
<!-- attach test jar -->
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-jar-plugin</artifactId>
|
|
||||||
<version>2.2</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<goals>
|
|
||||||
<goal>jar</goal>
|
|
||||||
<goal>test-jar</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
<configuration>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.codehaus.mojo</groupId>
|
|
||||||
<artifactId>build-helper-maven-plugin</artifactId>
|
|
||||||
<version>1.10</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<id>add_sources</id>
|
|
||||||
<phase>generate-sources</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>add-source</goal>
|
|
||||||
</goals>
|
|
||||||
<configuration>
|
|
||||||
<sources>
|
|
||||||
<source>
|
|
||||||
src/main/java</source>
|
|
||||||
</sources>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
<execution>
|
|
||||||
<id>add_test_sources</id>
|
|
||||||
<phase>generate-test-sources</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>add-test-source</goal>
|
|
||||||
</goals>
|
|
||||||
<configuration>
|
|
||||||
<sources>
|
|
||||||
<source>
|
|
||||||
src/test/java</source>
|
|
||||||
</sources>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-javadoc-plugin</artifactId>
|
|
||||||
<version>2.10.4</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<id>attach-javadocs</id>
|
|
||||||
<goals>
|
|
||||||
<goal>jar</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-source-plugin</artifactId>
|
|
||||||
<version>2.2.1</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<id>attach-sources</id>
|
|
||||||
<goals>
|
|
||||||
<goal>jar-no-fork</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
</profile>
|
||||||
<profiles>
|
<profile>
|
||||||
<profile>
|
<id>jdk11</id>
|
||||||
<id>sign-artifacts</id>
|
<activation>
|
||||||
<build>
|
<jdk>[11,)</jdk>
|
||||||
<plugins>
|
</activation>
|
||||||
<plugin>
|
<dependencies>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-gpg-plugin</artifactId>
|
|
||||||
<version>1.5</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<id>sign-artifacts</id>
|
|
||||||
<phase>verify</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>sign</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
</profile>
|
|
||||||
</profiles>
|
|
||||||
|
|
||||||
<dependencies>
|
|
||||||
<dependency>
|
|
||||||
<groupId>io.swagger</groupId>
|
|
||||||
<artifactId>swagger-annotations</artifactId>
|
|
||||||
<version>${swagger-core-version}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.squareup.retrofit2</groupId>
|
|
||||||
<artifactId>converter-gson</artifactId>
|
|
||||||
<version>${retrofit-version}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.squareup.retrofit2</groupId>
|
|
||||||
<artifactId>retrofit</artifactId>
|
|
||||||
<version>${retrofit-version}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.squareup.retrofit2</groupId>
|
|
||||||
<artifactId>converter-scalars</artifactId>
|
|
||||||
<version>${retrofit-version}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.apache.oltu.oauth2</groupId>
|
|
||||||
<artifactId>org.apache.oltu.oauth2.client</artifactId>
|
|
||||||
<version>${oltu-version}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>io.gsonfire</groupId>
|
|
||||||
<artifactId>gson-fire</artifactId>
|
|
||||||
<version>${gson-fire-version}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.threeten</groupId>
|
<groupId>com.sun.xml.ws</groupId>
|
||||||
<artifactId>threetenbp</artifactId>
|
<artifactId>jaxws-rt</artifactId>
|
||||||
<version>${threetenbp-version}</version>
|
<version>2.3.3</version>
|
||||||
|
<type>pom</type>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
</profile>
|
||||||
|
</profiles>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>io.swagger.core.v3</groupId>
|
||||||
|
<artifactId>swagger-annotations</artifactId>
|
||||||
|
<version>${swagger-core-version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.squareup.retrofit2</groupId>
|
||||||
|
<artifactId>converter-gson</artifactId>
|
||||||
|
<version>${retrofit-version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.squareup.retrofit2</groupId>
|
||||||
|
<artifactId>retrofit</artifactId>
|
||||||
|
<version>${retrofit-version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.squareup.retrofit2</groupId>
|
||||||
|
<artifactId>converter-scalars</artifactId>
|
||||||
|
<version>${retrofit-version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.apache.oltu.oauth2</groupId>
|
||||||
|
<artifactId>org.apache.oltu.oauth2.client</artifactId>
|
||||||
|
<version>${oltu-version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>io.gsonfire</groupId>
|
||||||
|
<artifactId>gson-fire</artifactId>
|
||||||
|
<version>${gson-fire-version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.threeten</groupId>
|
||||||
|
<artifactId>threetenbp</artifactId>
|
||||||
|
<version>${threetenbp-version}</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- test dependencies -->
|
<!-- test dependencies -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>junit</groupId>
|
<groupId>junit</groupId>
|
||||||
<artifactId>junit</artifactId>
|
<artifactId>junit</artifactId>
|
||||||
<version>${junit-version}</version>
|
<version>${junit-version}</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<properties>
|
<properties>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<java.version>1.7</java.version>
|
<java.version>11</java.version>
|
||||||
<maven.compiler.source>${java.version}</maven.compiler.source>
|
<maven.compiler.source>${java.version}</maven.compiler.source>
|
||||||
<maven.compiler.target>${java.version}</maven.compiler.target>
|
<maven.compiler.target>${java.version}</maven.compiler.target>
|
||||||
<gson-fire-version>1.8.0</gson-fire-version>
|
<gson-fire-version>1.8.0</gson-fire-version>
|
||||||
<swagger-core-version>1.5.15</swagger-core-version>
|
<swagger-core-version>2.0.0</swagger-core-version>
|
||||||
<retrofit-version>2.3.0</retrofit-version>
|
<retrofit-version>2.3.0</retrofit-version>
|
||||||
<threetenbp-version>1.3.5</threetenbp-version>
|
<threetenbp-version>1.3.5</threetenbp-version>
|
||||||
<oltu-version>1.0.1</oltu-version>
|
<oltu-version>1.0.2</oltu-version>
|
||||||
<junit-version>4.12</junit-version>
|
<junit-version>4.13.1</junit-version>
|
||||||
</properties>
|
</properties>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -43,13 +43,17 @@ public class ApiClient {
|
|||||||
public ApiClient(String[] authNames) {
|
public ApiClient(String[] authNames) {
|
||||||
this();
|
this();
|
||||||
for(String authName : authNames) {
|
for(String authName : authNames) {
|
||||||
Interceptor auth;
|
Interceptor auth = null;
|
||||||
if ("appTokenHeader".equals(authName)) {
|
if ("appTokenAuthorizationHeader".equals(authName)) {
|
||||||
|
auth = new ApiKeyAuth("header", "Authorization");
|
||||||
|
} else if ("appTokenHeader".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("header", "X-Gotify-Key");
|
auth = new ApiKeyAuth("header", "X-Gotify-Key");
|
||||||
} else if ("appTokenQuery".equals(authName)) {
|
} else if ("appTokenQuery".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("query", "token");
|
auth = new ApiKeyAuth("query", "token");
|
||||||
} else if ("basicAuth".equals(authName)) {
|
} else if ("basicAuth".equals(authName)) {
|
||||||
auth = new HttpBasicAuth();
|
auth = new HttpBasicAuth();
|
||||||
|
} else if ("clientTokenAuthorizationHeader".equals(authName)) {
|
||||||
|
auth = new ApiKeyAuth("header", "Authorization");
|
||||||
} else if ("clientTokenHeader".equals(authName)) {
|
} else if ("clientTokenHeader".equals(authName)) {
|
||||||
auth = new ApiKeyAuth("header", "X-Gotify-Key");
|
auth = new ApiKeyAuth("header", "X-Gotify-Key");
|
||||||
} else if ("clientTokenQuery".equals(authName)) {
|
} else if ("clientTokenQuery".equals(authName)) {
|
||||||
@@ -112,7 +116,7 @@ public class ApiClient {
|
|||||||
json = new JSON();
|
json = new JSON();
|
||||||
okBuilder = new OkHttpClient.Builder();
|
okBuilder = new OkHttpClient.Builder();
|
||||||
|
|
||||||
String baseUrl = "http://localhost";
|
String baseUrl = "http://localhost/";
|
||||||
if (!baseUrl.endsWith("/"))
|
if (!baseUrl.endsWith("/"))
|
||||||
baseUrl = baseUrl + "/";
|
baseUrl = baseUrl + "/";
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,7 +10,6 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client;
|
package com.github.gotify.client;
|
||||||
|
|
||||||
import com.google.gson.Gson;
|
import com.google.gson.Gson;
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,9 +10,9 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client;
|
package com.github.gotify.client;
|
||||||
|
|
||||||
|
|
||||||
public class StringUtil {
|
public class StringUtil {
|
||||||
/**
|
/**
|
||||||
* Check if the given array contains the given value (with case-insensitive comparison).
|
* Check if the given array contains the given value (with case-insensitive comparison).
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import okhttp3.RequestBody;
|
|||||||
import okhttp3.ResponseBody;
|
import okhttp3.ResponseBody;
|
||||||
|
|
||||||
import com.github.gotify.client.model.Application;
|
import com.github.gotify.client.model.Application;
|
||||||
|
import com.github.gotify.client.model.ApplicationParams;
|
||||||
import com.github.gotify.client.model.Error;
|
import com.github.gotify.client.model.Error;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
|
||||||
@@ -29,7 +30,7 @@ public interface ApplicationApi {
|
|||||||
})
|
})
|
||||||
@POST("application")
|
@POST("application")
|
||||||
Call<Application> createApp(
|
Call<Application> createApp(
|
||||||
@retrofit2.http.Body Application body
|
@retrofit2.http.Body ApplicationParams body
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -38,9 +39,6 @@ public interface ApplicationApi {
|
|||||||
* @param id the application id (required)
|
* @param id the application id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@DELETE("application/{id}")
|
@DELETE("application/{id}")
|
||||||
Call<Void> deleteApp(
|
Call<Void> deleteApp(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -51,13 +49,21 @@ public interface ApplicationApi {
|
|||||||
*
|
*
|
||||||
* @return Call<List<Application>>
|
* @return Call<List<Application>>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("application")
|
@GET("application")
|
||||||
Call<List<Application>> getApps();
|
Call<List<Application>> getApps();
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Deletes an image of an application.
|
||||||
|
*
|
||||||
|
* @param id the application id (required)
|
||||||
|
* @return Call<Void>
|
||||||
|
*/
|
||||||
|
@DELETE("application/{id}/image")
|
||||||
|
Call<Void> removeAppImage(
|
||||||
|
@retrofit2.http.Path("id") Long id
|
||||||
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Update an application.
|
* Update an application.
|
||||||
*
|
*
|
||||||
@@ -70,13 +76,13 @@ public interface ApplicationApi {
|
|||||||
})
|
})
|
||||||
@PUT("application/{id}")
|
@PUT("application/{id}")
|
||||||
Call<Application> updateApplication(
|
Call<Application> updateApplication(
|
||||||
@retrofit2.http.Body Application body, @retrofit2.http.Path("id") Long id
|
@retrofit2.http.Body ApplicationParams body, @retrofit2.http.Path("id") Long id
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Upload an image for an application.
|
* Upload an image for an application.
|
||||||
*
|
*
|
||||||
* @param file the application image (required)
|
* @param file (required)
|
||||||
* @param id the application id (required)
|
* @param id the application id (required)
|
||||||
* @return Call<Application>
|
* @return Call<Application>
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import okhttp3.RequestBody;
|
|||||||
import okhttp3.ResponseBody;
|
import okhttp3.ResponseBody;
|
||||||
|
|
||||||
import com.github.gotify.client.model.Client;
|
import com.github.gotify.client.model.Client;
|
||||||
|
import com.github.gotify.client.model.ClientParams;
|
||||||
import com.github.gotify.client.model.Error;
|
import com.github.gotify.client.model.Error;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
@@ -28,7 +29,7 @@ public interface ClientApi {
|
|||||||
})
|
})
|
||||||
@POST("client")
|
@POST("client")
|
||||||
Call<Client> createClient(
|
Call<Client> createClient(
|
||||||
@retrofit2.http.Body Client body
|
@retrofit2.http.Body ClientParams body
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -37,9 +38,6 @@ public interface ClientApi {
|
|||||||
* @param id the client id (required)
|
* @param id the client id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@DELETE("client/{id}")
|
@DELETE("client/{id}")
|
||||||
Call<Void> deleteClient(
|
Call<Void> deleteClient(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -50,9 +48,6 @@ public interface ClientApi {
|
|||||||
*
|
*
|
||||||
* @return Call<List<Client>>
|
* @return Call<List<Client>>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("client")
|
@GET("client")
|
||||||
Call<List<Client>> getClients();
|
Call<List<Client>> getClients();
|
||||||
|
|
||||||
@@ -69,7 +64,7 @@ public interface ClientApi {
|
|||||||
})
|
})
|
||||||
@PUT("client/{id}")
|
@PUT("client/{id}")
|
||||||
Call<Client> updateClient(
|
Call<Client> updateClient(
|
||||||
@retrofit2.http.Body Client body, @retrofit2.http.Path("id") Long id
|
@retrofit2.http.Body ClientParams body, @retrofit2.http.Path("id") Long id
|
||||||
);
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,9 +21,6 @@ public interface HealthApi {
|
|||||||
*
|
*
|
||||||
* @return Call<Health>
|
* @return Call<Health>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("health")
|
@GET("health")
|
||||||
Call<Health> getHealth();
|
Call<Health> getHealth();
|
||||||
|
|
||||||
|
|||||||
@@ -38,9 +38,6 @@ public interface MessageApi {
|
|||||||
* @param id the application id (required)
|
* @param id the application id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@DELETE("application/{id}/message")
|
@DELETE("application/{id}/message")
|
||||||
Call<Void> deleteAppMessages(
|
Call<Void> deleteAppMessages(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -52,9 +49,6 @@ public interface MessageApi {
|
|||||||
* @param id the message id (required)
|
* @param id the message id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@DELETE("message/{id}")
|
@DELETE("message/{id}")
|
||||||
Call<Void> deleteMessage(
|
Call<Void> deleteMessage(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -65,9 +59,6 @@ public interface MessageApi {
|
|||||||
*
|
*
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@DELETE("message")
|
@DELETE("message")
|
||||||
Call<Void> deleteMessages();
|
Call<Void> deleteMessages();
|
||||||
|
|
||||||
@@ -80,9 +71,6 @@ public interface MessageApi {
|
|||||||
* @param since return all messages with an ID less than this value (optional)
|
* @param since return all messages with an ID less than this value (optional)
|
||||||
* @return Call<PagedMessages>
|
* @return Call<PagedMessages>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("application/{id}/message")
|
@GET("application/{id}/message")
|
||||||
Call<PagedMessages> getAppMessages(
|
Call<PagedMessages> getAppMessages(
|
||||||
@retrofit2.http.Path("id") Long id, @retrofit2.http.Query("limit") Integer limit, @retrofit2.http.Query("since") Long since
|
@retrofit2.http.Path("id") Long id, @retrofit2.http.Query("limit") Integer limit, @retrofit2.http.Query("since") Long since
|
||||||
@@ -95,9 +83,6 @@ public interface MessageApi {
|
|||||||
* @param since return all messages with an ID less than this value (optional)
|
* @param since return all messages with an ID less than this value (optional)
|
||||||
* @return Call<PagedMessages>
|
* @return Call<PagedMessages>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("message")
|
@GET("message")
|
||||||
Call<PagedMessages> getMessages(
|
Call<PagedMessages> getMessages(
|
||||||
@retrofit2.http.Query("limit") Integer limit, @retrofit2.http.Query("since") Long since
|
@retrofit2.http.Query("limit") Integer limit, @retrofit2.http.Query("since") Long since
|
||||||
@@ -108,9 +93,6 @@ public interface MessageApi {
|
|||||||
*
|
*
|
||||||
* @return Call<Message>
|
* @return Call<Message>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("stream")
|
@GET("stream")
|
||||||
Call<Message> streamMessages();
|
Call<Message> streamMessages();
|
||||||
|
|
||||||
|
|||||||
@@ -23,9 +23,6 @@ public interface PluginApi {
|
|||||||
* @param id the plugin id (required)
|
* @param id the plugin id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@POST("plugin/{id}/disable")
|
@POST("plugin/{id}/disable")
|
||||||
Call<Void> disablePlugin(
|
Call<Void> disablePlugin(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -37,9 +34,6 @@ public interface PluginApi {
|
|||||||
* @param id the plugin id (required)
|
* @param id the plugin id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@POST("plugin/{id}/enable")
|
@POST("plugin/{id}/enable")
|
||||||
Call<Void> enablePlugin(
|
Call<Void> enablePlugin(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -51,9 +45,6 @@ public interface PluginApi {
|
|||||||
* @param id the plugin id (required)
|
* @param id the plugin id (required)
|
||||||
* @return Call<Object>
|
* @return Call<Object>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("plugin/{id}/config")
|
@GET("plugin/{id}/config")
|
||||||
Call<Object> getPluginConfig(
|
Call<Object> getPluginConfig(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -65,9 +56,6 @@ public interface PluginApi {
|
|||||||
* @param id the plugin id (required)
|
* @param id the plugin id (required)
|
||||||
* @return Call<String>
|
* @return Call<String>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("plugin/{id}/display")
|
@GET("plugin/{id}/display")
|
||||||
Call<String> getPluginDisplay(
|
Call<String> getPluginDisplay(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -78,9 +66,6 @@ public interface PluginApi {
|
|||||||
*
|
*
|
||||||
* @return Call<List<PluginConf>>
|
* @return Call<List<PluginConf>>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("plugin")
|
@GET("plugin")
|
||||||
Call<List<PluginConf>> getPlugins();
|
Call<List<PluginConf>> getPlugins();
|
||||||
|
|
||||||
@@ -91,9 +76,6 @@ public interface PluginApi {
|
|||||||
* @param id the plugin id (required)
|
* @param id the plugin id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/x-yaml"
|
|
||||||
})
|
|
||||||
@POST("plugin/{id}/config")
|
@POST("plugin/{id}/config")
|
||||||
Call<Void> updatePluginConfig(
|
Call<Void> updatePluginConfig(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
|
|||||||
@@ -8,10 +8,11 @@ import retrofit2.http.*;
|
|||||||
import okhttp3.RequestBody;
|
import okhttp3.RequestBody;
|
||||||
import okhttp3.ResponseBody;
|
import okhttp3.ResponseBody;
|
||||||
|
|
||||||
|
import com.github.gotify.client.model.CreateUserExternal;
|
||||||
import com.github.gotify.client.model.Error;
|
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.User;
|
||||||
import com.github.gotify.client.model.UserPass;
|
import com.github.gotify.client.model.UserPass;
|
||||||
import com.github.gotify.client.model.UserWithPass;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
@@ -21,7 +22,7 @@ import java.util.Map;
|
|||||||
public interface UserApi {
|
public interface UserApi {
|
||||||
/**
|
/**
|
||||||
* Create a user.
|
* 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.
|
||||||
* @param body the user to add (required)
|
* @param body the user to add (required)
|
||||||
* @return Call<User>
|
* @return Call<User>
|
||||||
*/
|
*/
|
||||||
@@ -30,7 +31,7 @@ public interface UserApi {
|
|||||||
})
|
})
|
||||||
@POST("user")
|
@POST("user")
|
||||||
Call<User> createUser(
|
Call<User> createUser(
|
||||||
@retrofit2.http.Body UserWithPass body
|
@retrofit2.http.Body CreateUserExternal body
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -38,9 +39,6 @@ public interface UserApi {
|
|||||||
*
|
*
|
||||||
* @return Call<User>
|
* @return Call<User>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("current/user")
|
@GET("current/user")
|
||||||
Call<User> currentUser();
|
Call<User> currentUser();
|
||||||
|
|
||||||
@@ -51,9 +49,6 @@ public interface UserApi {
|
|||||||
* @param id the user id (required)
|
* @param id the user id (required)
|
||||||
* @return Call<Void>
|
* @return Call<Void>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@DELETE("user/{id}")
|
@DELETE("user/{id}")
|
||||||
Call<Void> deleteUser(
|
Call<Void> deleteUser(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -65,9 +60,6 @@ public interface UserApi {
|
|||||||
* @param id the user id (required)
|
* @param id the user id (required)
|
||||||
* @return Call<User>
|
* @return Call<User>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("user/{id}")
|
@GET("user/{id}")
|
||||||
Call<User> getUser(
|
Call<User> getUser(
|
||||||
@retrofit2.http.Path("id") Long id
|
@retrofit2.http.Path("id") Long id
|
||||||
@@ -78,9 +70,6 @@ public interface UserApi {
|
|||||||
*
|
*
|
||||||
* @return Call<List<User>>
|
* @return Call<List<User>>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("user")
|
@GET("user")
|
||||||
Call<List<User>> getUsers();
|
Call<List<User>> getUsers();
|
||||||
|
|
||||||
@@ -102,8 +91,8 @@ public interface UserApi {
|
|||||||
/**
|
/**
|
||||||
* Update a user.
|
* Update a user.
|
||||||
*
|
*
|
||||||
* @param id the user id (required)
|
|
||||||
* @param body the updated user (required)
|
* @param body the updated user (required)
|
||||||
|
* @param id the user id (required)
|
||||||
* @return Call<User>
|
* @return Call<User>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
@Headers({
|
||||||
@@ -111,7 +100,7 @@ public interface UserApi {
|
|||||||
})
|
})
|
||||||
@POST("user/{id}")
|
@POST("user/{id}")
|
||||||
Call<User> updateUser(
|
Call<User> updateUser(
|
||||||
@retrofit2.http.Path("id") Long id, @retrofit2.http.Body UserWithPass body
|
@retrofit2.http.Body UpdateUserExternal body, @retrofit2.http.Path("id") Long id
|
||||||
);
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,9 +21,6 @@ public interface VersionApi {
|
|||||||
*
|
*
|
||||||
* @return Call<VersionInfo>
|
* @return Call<VersionInfo>
|
||||||
*/
|
*/
|
||||||
@Headers({
|
|
||||||
"Content-Type:application/json"
|
|
||||||
})
|
|
||||||
@GET("version")
|
@GET("version")
|
||||||
Call<VersionInfo> getVersion();
|
Call<VersionInfo> getVersion();
|
||||||
|
|
||||||
|
|||||||
@@ -113,8 +113,16 @@ public class OAuth implements Interceptor {
|
|||||||
|
|
||||||
// 401/403 most likely indicates that access token has expired. Unless it happens two times in a row.
|
// 401/403 most likely indicates that access token has expired. Unless it happens two times in a row.
|
||||||
if ( response != null && (response.code() == HTTP_UNAUTHORIZED || response.code() == HTTP_FORBIDDEN) && updateTokenAndRetryOnAuthorizationFailure ) {
|
if ( response != null && (response.code() == HTTP_UNAUTHORIZED || response.code() == HTTP_FORBIDDEN) && updateTokenAndRetryOnAuthorizationFailure ) {
|
||||||
if (updateAccessToken(requestAccessToken)) {
|
if (response != null && (response.code() == HTTP_UNAUTHORIZED || response.code() == HTTP_FORBIDDEN) && updateTokenAndRetryOnAuthorizationFailure) {
|
||||||
return retryingIntercept( chain, false );
|
try {
|
||||||
|
if (updateAccessToken(requestAccessToken)) {
|
||||||
|
response.body().close();
|
||||||
|
return retryingIntercept(chain, false);
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
response.body().close();
|
||||||
|
throw e;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return response;
|
return response;
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,7 +10,6 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.auth;
|
package com.github.gotify.client.auth;
|
||||||
|
|
||||||
public enum OAuthFlow {
|
public enum OAuthFlow {
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,24 +10,28 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import org.threeten.bp.OffsetDateTime;
|
||||||
/**
|
/**
|
||||||
* The Application holds information about an app which can send notifications.
|
* The Application holds information about an app which can send notifications.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "The Application holds information about an app which can send notifications.")
|
@Schema(description = "The Application holds information about an app which can send notifications.")
|
||||||
|
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
|
@SerializedName("defaultPriority")
|
||||||
|
private Long defaultPriority = null;
|
||||||
|
|
||||||
@SerializedName("description")
|
@SerializedName("description")
|
||||||
private String description = null;
|
private String description = null;
|
||||||
|
|
||||||
@@ -40,12 +44,33 @@ public class Application {
|
|||||||
@SerializedName("internal")
|
@SerializedName("internal")
|
||||||
private Boolean internal = null;
|
private Boolean internal = null;
|
||||||
|
|
||||||
|
@SerializedName("lastUsed")
|
||||||
|
private OffsetDateTime lastUsed = null;
|
||||||
|
|
||||||
@SerializedName("name")
|
@SerializedName("name")
|
||||||
private String name = null;
|
private String name = null;
|
||||||
|
|
||||||
@SerializedName("token")
|
@SerializedName("token")
|
||||||
private String token = null;
|
private String token = null;
|
||||||
|
|
||||||
|
public Application defaultPriority(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.")
|
||||||
|
public Long getDefaultPriority() {
|
||||||
|
return defaultPriority;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDefaultPriority(Long defaultPriority) {
|
||||||
|
this.defaultPriority = defaultPriority;
|
||||||
|
}
|
||||||
|
|
||||||
public Application description(String description) {
|
public Application description(String description) {
|
||||||
this.description = description;
|
this.description = description;
|
||||||
return this;
|
return this;
|
||||||
@@ -55,7 +80,7 @@ public class Application {
|
|||||||
* The description of the application.
|
* The description of the application.
|
||||||
* @return description
|
* @return description
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "Backup server for the interwebs", required = true, value = "The description of the application.")
|
@Schema(example = "Backup server for the interwebs", required = true, description = "The description of the application.")
|
||||||
public String getDescription() {
|
public String getDescription() {
|
||||||
return description;
|
return description;
|
||||||
}
|
}
|
||||||
@@ -68,7 +93,7 @@ public class Application {
|
|||||||
* The application id.
|
* The application id.
|
||||||
* @return id
|
* @return id
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "5", required = true, value = "The application id.")
|
@Schema(example = "5", required = true, description = "The application id.")
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
@@ -77,7 +102,7 @@ public class Application {
|
|||||||
* The image of the application.
|
* The image of the application.
|
||||||
* @return image
|
* @return image
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "image/image.jpeg", required = true, value = "The image of the application.")
|
@Schema(example = "image/image.jpeg", required = true, description = "The image of the application.")
|
||||||
public String getImage() {
|
public String getImage() {
|
||||||
return image;
|
return image;
|
||||||
}
|
}
|
||||||
@@ -86,11 +111,20 @@ public class Application {
|
|||||||
* Whether the application is an internal application. Internal applications should not be deleted.
|
* Whether the application is an internal application. Internal applications should not be deleted.
|
||||||
* @return internal
|
* @return internal
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "false", required = true, value = "Whether the application is an internal application. Internal applications should not be deleted.")
|
@Schema(example = "false", required = true, description = "Whether the application is an internal application. Internal applications should not be deleted.")
|
||||||
public Boolean isInternal() {
|
public Boolean isInternal() {
|
||||||
return internal;
|
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.")
|
||||||
|
public OffsetDateTime getLastUsed() {
|
||||||
|
return lastUsed;
|
||||||
|
}
|
||||||
|
|
||||||
public Application name(String name) {
|
public Application name(String name) {
|
||||||
this.name = name;
|
this.name = name;
|
||||||
return this;
|
return this;
|
||||||
@@ -100,7 +134,7 @@ public class Application {
|
|||||||
* The application name. This is how the application should be displayed to the user.
|
* The application name. This is how the application should be displayed to the user.
|
||||||
* @return name
|
* @return name
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "Backup Server", required = true, value = "The application name. This is how the application should be displayed to the user.")
|
@Schema(example = "Backup Server", required = true, description = "The application name. This is how the application should be displayed to the user.")
|
||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
@@ -113,7 +147,7 @@ public class Application {
|
|||||||
* The application token. Can be used as `appToken`. See Authentication.
|
* The application token. Can be used as `appToken`. See Authentication.
|
||||||
* @return token
|
* @return token
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "AWH0wZ5r0Mbac.r", required = true, value = "The application token. Can be used as `appToken`. See Authentication.")
|
@Schema(example = "AWH0wZ5r0Mbac.r", required = true, description = "The application token. Can be used as `appToken`. See Authentication.")
|
||||||
public String getToken() {
|
public String getToken() {
|
||||||
return token;
|
return token;
|
||||||
}
|
}
|
||||||
@@ -128,17 +162,19 @@ public class Application {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
Application application = (Application) o;
|
Application application = (Application) o;
|
||||||
return Objects.equals(this.description, application.description) &&
|
return Objects.equals(this.defaultPriority, application.defaultPriority) &&
|
||||||
|
Objects.equals(this.description, application.description) &&
|
||||||
Objects.equals(this.id, application.id) &&
|
Objects.equals(this.id, application.id) &&
|
||||||
Objects.equals(this.image, application.image) &&
|
Objects.equals(this.image, application.image) &&
|
||||||
Objects.equals(this.internal, application.internal) &&
|
Objects.equals(this.internal, application.internal) &&
|
||||||
|
Objects.equals(this.lastUsed, application.lastUsed) &&
|
||||||
Objects.equals(this.name, application.name) &&
|
Objects.equals(this.name, application.name) &&
|
||||||
Objects.equals(this.token, application.token);
|
Objects.equals(this.token, application.token);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
return Objects.hash(description, id, image, internal, name, token);
|
return Objects.hash(defaultPriority, description, id, image, internal, lastUsed, name, token);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -147,10 +183,12 @@ public class Application {
|
|||||||
StringBuilder sb = new StringBuilder();
|
StringBuilder sb = new StringBuilder();
|
||||||
sb.append("class Application {\n");
|
sb.append("class Application {\n");
|
||||||
|
|
||||||
|
sb.append(" defaultPriority: ").append(toIndentedString(defaultPriority)).append("\n");
|
||||||
sb.append(" description: ").append(toIndentedString(description)).append("\n");
|
sb.append(" description: ").append(toIndentedString(description)).append("\n");
|
||||||
sb.append(" id: ").append(toIndentedString(id)).append("\n");
|
sb.append(" id: ").append(toIndentedString(id)).append("\n");
|
||||||
sb.append(" image: ").append(toIndentedString(image)).append("\n");
|
sb.append(" image: ").append(toIndentedString(image)).append("\n");
|
||||||
sb.append(" internal: ").append(toIndentedString(internal)).append("\n");
|
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(" name: ").append(toIndentedString(name)).append("\n");
|
||||||
sb.append(" token: ").append(toIndentedString(token)).append("\n");
|
sb.append(" token: ").append(toIndentedString(token)).append("\n");
|
||||||
sb.append("}");
|
sb.append("}");
|
||||||
@@ -169,4 +207,3 @@ public class Application {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
/*
|
||||||
|
* 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.IOException;
|
||||||
|
/**
|
||||||
|
* Params allowed to create or update Applications.
|
||||||
|
*/
|
||||||
|
@Schema(description = "Params allowed to create or update Applications.")
|
||||||
|
|
||||||
|
|
||||||
|
public class ApplicationParams {
|
||||||
|
@SerializedName("defaultPriority")
|
||||||
|
private Long defaultPriority = null;
|
||||||
|
|
||||||
|
@SerializedName("description")
|
||||||
|
private String description = null;
|
||||||
|
|
||||||
|
@SerializedName("name")
|
||||||
|
private String name = null;
|
||||||
|
|
||||||
|
public ApplicationParams defaultPriority(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.")
|
||||||
|
public Long getDefaultPriority() {
|
||||||
|
return defaultPriority;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDefaultPriority(Long defaultPriority) {
|
||||||
|
this.defaultPriority = defaultPriority;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ApplicationParams description(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.")
|
||||||
|
public String getDescription() {
|
||||||
|
return description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDescription(String description) {
|
||||||
|
this.description = description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ApplicationParams name(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.")
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean equals(java.lang.Object o) {
|
||||||
|
if (this == o) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (o == null || getClass() != o.getClass()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
ApplicationParams applicationParams = (ApplicationParams) o;
|
||||||
|
return Objects.equals(this.defaultPriority, applicationParams.defaultPriority) &&
|
||||||
|
Objects.equals(this.description, applicationParams.description) &&
|
||||||
|
Objects.equals(this.name, applicationParams.name);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int hashCode() {
|
||||||
|
return Objects.hash(defaultPriority, description, name);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@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("}");
|
||||||
|
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 ");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,27 +10,31 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import org.threeten.bp.OffsetDateTime;
|
||||||
/**
|
/**
|
||||||
* The Client holds information about a device which can receive notifications (and other stuff).
|
* The Client holds information about a device which can receive notifications (and other stuff).
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "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).")
|
||||||
|
|
||||||
|
|
||||||
public class Client {
|
public class Client {
|
||||||
@SerializedName("id")
|
@SerializedName("id")
|
||||||
private Long id = null;
|
private Long id = null;
|
||||||
|
|
||||||
|
@SerializedName("lastUsed")
|
||||||
|
private OffsetDateTime lastUsed = null;
|
||||||
|
|
||||||
@SerializedName("name")
|
@SerializedName("name")
|
||||||
private String name = null;
|
private String name = null;
|
||||||
|
|
||||||
@@ -41,11 +45,20 @@ public class Client {
|
|||||||
* The client id.
|
* The client id.
|
||||||
* @return id
|
* @return id
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "5", required = true, value = "The client id.")
|
@Schema(example = "5", required = true, description = "The client id.")
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
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.")
|
||||||
|
public OffsetDateTime getLastUsed() {
|
||||||
|
return lastUsed;
|
||||||
|
}
|
||||||
|
|
||||||
public Client name(String name) {
|
public Client name(String name) {
|
||||||
this.name = name;
|
this.name = name;
|
||||||
return this;
|
return this;
|
||||||
@@ -55,7 +68,7 @@ public class Client {
|
|||||||
* The client name. This is how the client should be displayed to the user.
|
* The client name. This is how the client should be displayed to the user.
|
||||||
* @return name
|
* @return name
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "Android Phone", required = true, value = "The client name. This is how the client should be displayed to the user.")
|
@Schema(example = "Android Phone", required = true, description = "The client name. This is how the client should be displayed to the user.")
|
||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
@@ -68,7 +81,7 @@ public class Client {
|
|||||||
* The client token. Can be used as `clientToken`. See Authentication.
|
* The client token. Can be used as `clientToken`. See Authentication.
|
||||||
* @return token
|
* @return token
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "CWH0wZ5r0Mbac.r", required = true, value = "The client token. Can be used as `clientToken`. See Authentication.")
|
@Schema(example = "CWH0wZ5r0Mbac.r", required = true, description = "The client token. Can be used as `clientToken`. See Authentication.")
|
||||||
public String getToken() {
|
public String getToken() {
|
||||||
return token;
|
return token;
|
||||||
}
|
}
|
||||||
@@ -84,13 +97,14 @@ public class Client {
|
|||||||
}
|
}
|
||||||
Client client = (Client) o;
|
Client client = (Client) o;
|
||||||
return Objects.equals(this.id, client.id) &&
|
return Objects.equals(this.id, client.id) &&
|
||||||
|
Objects.equals(this.lastUsed, client.lastUsed) &&
|
||||||
Objects.equals(this.name, client.name) &&
|
Objects.equals(this.name, client.name) &&
|
||||||
Objects.equals(this.token, client.token);
|
Objects.equals(this.token, client.token);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
return Objects.hash(id, name, token);
|
return Objects.hash(id, lastUsed, name, token);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -100,6 +114,7 @@ public class Client {
|
|||||||
sb.append("class Client {\n");
|
sb.append("class Client {\n");
|
||||||
|
|
||||||
sb.append(" id: ").append(toIndentedString(id)).append("\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");
|
sb.append(" name: ").append(toIndentedString(name)).append("\n");
|
||||||
sb.append(" token: ").append(toIndentedString(token)).append("\n");
|
sb.append(" token: ").append(toIndentedString(token)).append("\n");
|
||||||
sb.append("}");
|
sb.append("}");
|
||||||
@@ -118,4 +133,3 @@ public class Client {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,92 @@
|
|||||||
|
/*
|
||||||
|
* 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.IOException;
|
||||||
|
/**
|
||||||
|
* Params allowed to create or update Clients.
|
||||||
|
*/
|
||||||
|
@Schema(description = "Params allowed to create or update Clients.")
|
||||||
|
|
||||||
|
|
||||||
|
public class ClientParams {
|
||||||
|
@SerializedName("name")
|
||||||
|
private String name = null;
|
||||||
|
|
||||||
|
public ClientParams name(String name) {
|
||||||
|
this.name = name;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The client name
|
||||||
|
* @return name
|
||||||
|
**/
|
||||||
|
@Schema(example = "My Client", required = true, description = "The client name")
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean equals(java.lang.Object o) {
|
||||||
|
if (this == o) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (o == null || getClass() != o.getClass()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
ClientParams clientParams = (ClientParams) o;
|
||||||
|
return Objects.equals(this.name, clientParams.name);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
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();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 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 ");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,37 +10,34 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The UserWithPass holds information about the credentials and other stuff.
|
* Used for user creation.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "The UserWithPass holds information about the credentials and other stuff.")
|
@Schema(description = "Used for user creation.")
|
||||||
public class UserWithPass {
|
|
||||||
|
|
||||||
|
public class CreateUserExternal {
|
||||||
@SerializedName("admin")
|
@SerializedName("admin")
|
||||||
private Boolean admin = null;
|
private Boolean admin = null;
|
||||||
|
|
||||||
@SerializedName("id")
|
|
||||||
private Long id = null;
|
|
||||||
|
|
||||||
@SerializedName("name")
|
@SerializedName("name")
|
||||||
private String name = null;
|
private String name = null;
|
||||||
|
|
||||||
@SerializedName("pass")
|
@SerializedName("pass")
|
||||||
private String pass = null;
|
private String pass = null;
|
||||||
|
|
||||||
public UserWithPass admin(Boolean admin) {
|
public CreateUserExternal admin(Boolean admin) {
|
||||||
this.admin = admin;
|
this.admin = admin;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
@@ -49,7 +46,7 @@ public class UserWithPass {
|
|||||||
* If the user is an administrator.
|
* If the user is an administrator.
|
||||||
* @return admin
|
* @return admin
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "true", value = "If the user is an administrator.")
|
@Schema(example = "true", required = true, description = "If the user is an administrator.")
|
||||||
public Boolean isAdmin() {
|
public Boolean isAdmin() {
|
||||||
return admin;
|
return admin;
|
||||||
}
|
}
|
||||||
@@ -58,16 +55,7 @@ public class UserWithPass {
|
|||||||
this.admin = admin;
|
this.admin = admin;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
public CreateUserExternal name(String name) {
|
||||||
* The user id.
|
|
||||||
* @return id
|
|
||||||
**/
|
|
||||||
@ApiModelProperty(example = "25", required = true, value = "The user id.")
|
|
||||||
public Long getId() {
|
|
||||||
return id;
|
|
||||||
}
|
|
||||||
|
|
||||||
public UserWithPass name(String name) {
|
|
||||||
this.name = name;
|
this.name = name;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
@@ -76,7 +64,7 @@ public class UserWithPass {
|
|||||||
* The user name. For login.
|
* The user name. For login.
|
||||||
* @return name
|
* @return name
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "unicorn", required = true, value = "The user name. For login.")
|
@Schema(example = "unicorn", required = true, description = "The user name. For login.")
|
||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
@@ -85,7 +73,7 @@ public class UserWithPass {
|
|||||||
this.name = name;
|
this.name = name;
|
||||||
}
|
}
|
||||||
|
|
||||||
public UserWithPass pass(String pass) {
|
public CreateUserExternal pass(String pass) {
|
||||||
this.pass = pass;
|
this.pass = pass;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
@@ -94,7 +82,7 @@ public class UserWithPass {
|
|||||||
* The user password. For login.
|
* The user password. For login.
|
||||||
* @return pass
|
* @return pass
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "nrocinu", required = true, value = "The user password. For login.")
|
@Schema(example = "nrocinu", required = true, description = "The user password. For login.")
|
||||||
public String getPass() {
|
public String getPass() {
|
||||||
return pass;
|
return pass;
|
||||||
}
|
}
|
||||||
@@ -112,26 +100,24 @@ public class UserWithPass {
|
|||||||
if (o == null || getClass() != o.getClass()) {
|
if (o == null || getClass() != o.getClass()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
UserWithPass userWithPass = (UserWithPass) o;
|
CreateUserExternal createUserExternal = (CreateUserExternal) o;
|
||||||
return Objects.equals(this.admin, userWithPass.admin) &&
|
return Objects.equals(this.admin, createUserExternal.admin) &&
|
||||||
Objects.equals(this.id, userWithPass.id) &&
|
Objects.equals(this.name, createUserExternal.name) &&
|
||||||
Objects.equals(this.name, userWithPass.name) &&
|
Objects.equals(this.pass, createUserExternal.pass);
|
||||||
Objects.equals(this.pass, userWithPass.pass);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
return Objects.hash(admin, id, name, pass);
|
return Objects.hash(admin, name, pass);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
StringBuilder sb = new StringBuilder();
|
StringBuilder sb = new StringBuilder();
|
||||||
sb.append("class UserWithPass {\n");
|
sb.append("class CreateUserExternal {\n");
|
||||||
|
|
||||||
sb.append(" admin: ").append(toIndentedString(admin)).append("\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");
|
sb.append(" name: ").append(toIndentedString(name)).append("\n");
|
||||||
sb.append(" pass: ").append(toIndentedString(pass)).append("\n");
|
sb.append(" pass: ").append(toIndentedString(pass)).append("\n");
|
||||||
sb.append("}");
|
sb.append("}");
|
||||||
@@ -150,4 +136,3 @@ public class UserWithPass {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,23 +10,23 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Error contains error relevant information.
|
* The Error contains error relevant information.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "The Error contains error relevant information.")
|
@Schema(description = "The Error contains error relevant information.")
|
||||||
|
|
||||||
|
|
||||||
public class Error {
|
public class Error {
|
||||||
@SerializedName("error")
|
@SerializedName("error")
|
||||||
private String error = null;
|
private String error = null;
|
||||||
@@ -46,7 +46,7 @@ public class Error {
|
|||||||
* The general error message
|
* The general error message
|
||||||
* @return error
|
* @return error
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "Unauthorized", required = true, value = "The general error message")
|
@Schema(example = "Unauthorized", required = true, description = "The general error message")
|
||||||
public String getError() {
|
public String getError() {
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
@@ -64,7 +64,7 @@ public class Error {
|
|||||||
* The http error code.
|
* The http error code.
|
||||||
* @return errorCode
|
* @return errorCode
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "401", required = true, value = "The http error code.")
|
@Schema(example = "401", required = true, description = "The http error code.")
|
||||||
public Long getErrorCode() {
|
public Long getErrorCode() {
|
||||||
return errorCode;
|
return errorCode;
|
||||||
}
|
}
|
||||||
@@ -82,7 +82,7 @@ public class Error {
|
|||||||
* The http error code.
|
* The http error code.
|
||||||
* @return errorDescription
|
* @return errorDescription
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "you need to provide a valid access token or user credentials to access this api", required = true, value = "The http error code.")
|
@Schema(example = "you need to provide a valid access token or user credentials to access this api", required = true, description = "The http error code.")
|
||||||
public String getErrorDescription() {
|
public String getErrorDescription() {
|
||||||
return errorDescription;
|
return errorDescription;
|
||||||
}
|
}
|
||||||
@@ -136,4 +136,3 @@ public class Error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,23 +10,23 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Health represents how healthy the application is.
|
* Health represents how healthy the application is.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "Health represents how healthy the application is.")
|
@Schema(description = "Health represents how healthy the application is.")
|
||||||
|
|
||||||
|
|
||||||
public class Health {
|
public class Health {
|
||||||
@SerializedName("database")
|
@SerializedName("database")
|
||||||
private String database = null;
|
private String database = null;
|
||||||
@@ -43,7 +43,7 @@ public class Health {
|
|||||||
* The health of the database connection.
|
* The health of the database connection.
|
||||||
* @return database
|
* @return database
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "green", required = true, value = "The health of the database connection.")
|
@Schema(example = "green", required = true, description = "The health of the database connection.")
|
||||||
public String getDatabase() {
|
public String getDatabase() {
|
||||||
return database;
|
return database;
|
||||||
}
|
}
|
||||||
@@ -61,7 +61,7 @@ public class Health {
|
|||||||
* The health of the overall application.
|
* The health of the overall application.
|
||||||
* @return health
|
* @return health
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "green", required = true, value = "The health of the overall application.")
|
@Schema(example = "green", required = true, description = "The health of the overall application.")
|
||||||
public String getHealth() {
|
public String getHealth() {
|
||||||
return health;
|
return health;
|
||||||
}
|
}
|
||||||
@@ -113,4 +113,3 @@ public class Health {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,93 @@
|
|||||||
|
/*
|
||||||
|
* 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 ");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,27 +10,27 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import org.threeten.bp.OffsetDateTime;
|
import org.threeten.bp.OffsetDateTime;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The MessageExternal holds information about a message which was sent by an Application.
|
* The MessageExternal holds information about a message which was sent by an Application.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "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.")
|
||||||
|
|
||||||
|
|
||||||
public class Message {
|
public class Message {
|
||||||
@SerializedName("appid")
|
@SerializedName("appid")
|
||||||
private Long appid = null;
|
private Long appid = null;
|
||||||
@@ -57,7 +57,7 @@ public class Message {
|
|||||||
* The application id that send this message.
|
* The application id that send this message.
|
||||||
* @return appid
|
* @return appid
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "5", required = true, value = "The application id that send this message.")
|
@Schema(example = "5", required = true, description = "The application id that send this message.")
|
||||||
public Long getAppid() {
|
public Long getAppid() {
|
||||||
return appid;
|
return appid;
|
||||||
}
|
}
|
||||||
@@ -66,7 +66,7 @@ public class Message {
|
|||||||
* The date the message was created.
|
* The date the message was created.
|
||||||
* @return date
|
* @return date
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "2018-02-27T19:36:10.5045044+01:00", required = true, value = "The date the message was created.")
|
@Schema(example = "2018-02-27T19:36:10.504504400+01:00", required = true, description = "The date the message was created.")
|
||||||
public OffsetDateTime getDate() {
|
public OffsetDateTime getDate() {
|
||||||
return date;
|
return date;
|
||||||
}
|
}
|
||||||
@@ -88,7 +88,7 @@ public class Message {
|
|||||||
* 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: &lt;top-namespace&gt;::[&lt;sub-namespace&gt;::]&lt;action&gt; 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.
|
* 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: &lt;top-namespace&gt;::[&lt;sub-namespace&gt;::]&lt;action&gt; 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
|
* @return extras
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "{\"home::appliances::lighting::on\":{\"brightness\":15},\"home::appliances::thermostat::change_temperature\":{\"temperature\":23}}", value = "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.")
|
@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.")
|
||||||
public Map<String, Object> getExtras() {
|
public Map<String, Object> getExtras() {
|
||||||
return extras;
|
return extras;
|
||||||
}
|
}
|
||||||
@@ -101,7 +101,7 @@ public class Message {
|
|||||||
* The message id.
|
* The message id.
|
||||||
* @return id
|
* @return id
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "25", required = true, value = "The message id.")
|
@Schema(example = "25", required = true, description = "The message id.")
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
@@ -115,7 +115,7 @@ public class Message {
|
|||||||
* The message. Markdown (excluding html) is allowed.
|
* The message. Markdown (excluding html) is allowed.
|
||||||
* @return message
|
* @return message
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "**Backup** was successfully finished.", required = true, value = "The message. Markdown (excluding html) is allowed.")
|
@Schema(example = "**Backup** was successfully finished.", required = true, description = "The message. Markdown (excluding html) is allowed.")
|
||||||
public String getMessage() {
|
public String getMessage() {
|
||||||
return message;
|
return message;
|
||||||
}
|
}
|
||||||
@@ -130,10 +130,10 @@ public class Message {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The priority of the message.
|
* The priority of the message. If unset, then the default priority of the application will be used.
|
||||||
* @return priority
|
* @return priority
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "2", value = "The priority of the message.")
|
@Schema(example = "2", description = "The priority of the message. If unset, then the default priority of the application will be used.")
|
||||||
public Long getPriority() {
|
public Long getPriority() {
|
||||||
return priority;
|
return priority;
|
||||||
}
|
}
|
||||||
@@ -151,7 +151,7 @@ public class Message {
|
|||||||
* The title of the message.
|
* The title of the message.
|
||||||
* @return title
|
* @return title
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "Backup", value = "The title of the message.")
|
@Schema(example = "Backup", description = "The title of the message.")
|
||||||
public String getTitle() {
|
public String getTitle() {
|
||||||
return title;
|
return title;
|
||||||
}
|
}
|
||||||
@@ -213,4 +213,3 @@ public class Message {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,10 +10,10 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.github.gotify.client.model.Message;
|
import com.github.gotify.client.model.Message;
|
||||||
import com.github.gotify.client.model.Paging;
|
import com.github.gotify.client.model.Paging;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
@@ -21,16 +21,16 @@ import com.google.gson.annotations.JsonAdapter;
|
|||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wrapper for the paging and the messages
|
* Wrapper for the paging and the messages.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "Wrapper for the paging and the messages")
|
@Schema(description = "Wrapper for the paging and the messages.")
|
||||||
|
|
||||||
|
|
||||||
public class PagedMessages {
|
public class PagedMessages {
|
||||||
@SerializedName("messages")
|
@SerializedName("messages")
|
||||||
private List<Message> messages = new ArrayList<Message>();
|
private List<Message> messages = new ArrayList<Message>();
|
||||||
@@ -38,29 +38,15 @@ public class PagedMessages {
|
|||||||
@SerializedName("paging")
|
@SerializedName("paging")
|
||||||
private Paging paging = null;
|
private Paging paging = null;
|
||||||
|
|
||||||
public PagedMessages messages(List<Message> messages) {
|
|
||||||
this.messages = messages;
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
public PagedMessages addMessagesItem(Message messagesItem) {
|
|
||||||
this.messages.add(messagesItem);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The messages.
|
* The messages.
|
||||||
* @return messages
|
* @return messages
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(required = true, value = "The messages.")
|
@Schema(required = true, description = "The messages.")
|
||||||
public List<Message> getMessages() {
|
public List<Message> getMessages() {
|
||||||
return messages;
|
return messages;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setMessages(List<Message> messages) {
|
|
||||||
this.messages = messages;
|
|
||||||
}
|
|
||||||
|
|
||||||
public PagedMessages paging(Paging paging) {
|
public PagedMessages paging(Paging paging) {
|
||||||
this.paging = paging;
|
this.paging = paging;
|
||||||
return this;
|
return this;
|
||||||
@@ -70,7 +56,7 @@ public class PagedMessages {
|
|||||||
* Get paging
|
* Get paging
|
||||||
* @return paging
|
* @return paging
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(required = true, value = "")
|
@Schema(required = true, description = "")
|
||||||
public Paging getPaging() {
|
public Paging getPaging() {
|
||||||
return paging;
|
return paging;
|
||||||
}
|
}
|
||||||
@@ -122,4 +108,3 @@ public class PagedMessages {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,23 +10,23 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Paging holds information about the limit and making requests to the next page.
|
* The Paging holds information about the limit and making requests to the next page.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "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.")
|
||||||
|
|
||||||
|
|
||||||
public class Paging {
|
public class Paging {
|
||||||
@SerializedName("limit")
|
@SerializedName("limit")
|
||||||
private Long limit = null;
|
private Long limit = null;
|
||||||
@@ -46,7 +46,7 @@ public class Paging {
|
|||||||
* maximum: 200
|
* maximum: 200
|
||||||
* @return limit
|
* @return limit
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "123", required = true, value = "The limit of the messages for the current request.")
|
@Schema(example = "123", required = true, description = "The limit of the messages for the current request.")
|
||||||
public Long getLimit() {
|
public Long getLimit() {
|
||||||
return limit;
|
return limit;
|
||||||
}
|
}
|
||||||
@@ -55,7 +55,7 @@ public class Paging {
|
|||||||
* The request url for the next page. Empty/Null when no next page is available.
|
* The request url for the next page. Empty/Null when no next page is available.
|
||||||
* @return next
|
* @return next
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "http://example.com/message?limit=50&since=123456", value = "The request url for the next page. Empty/Null when no next page is available.")
|
@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.")
|
||||||
public String getNext() {
|
public String getNext() {
|
||||||
return next;
|
return next;
|
||||||
}
|
}
|
||||||
@@ -65,7 +65,7 @@ public class Paging {
|
|||||||
* minimum: 0
|
* minimum: 0
|
||||||
* @return since
|
* @return since
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "5", required = true, value = "The ID of the last message returned in the current request. Use this as alternative to the next link.")
|
@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.")
|
||||||
public Long getSince() {
|
public Long getSince() {
|
||||||
return since;
|
return since;
|
||||||
}
|
}
|
||||||
@@ -74,7 +74,7 @@ public class Paging {
|
|||||||
* The amount of messages that got returned in the current request.
|
* The amount of messages that got returned in the current request.
|
||||||
* @return size
|
* @return size
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "5", required = true, value = "The amount of messages that got returned in the current request.")
|
@Schema(example = "5", required = true, description = "The amount of messages that got returned in the current request.")
|
||||||
public Long getSize() {
|
public Long getSize() {
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
@@ -126,4 +126,3 @@ public class Paging {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,25 +10,25 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds information about a plugin instance for one user.
|
* Holds information about a plugin instance for one user.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "Holds information about a plugin instance for one user.")
|
@Schema(description = "Holds information about a plugin instance for one user.")
|
||||||
|
|
||||||
|
|
||||||
public class PluginConf {
|
public class PluginConf {
|
||||||
@SerializedName("author")
|
@SerializedName("author")
|
||||||
private String author = null;
|
private String author = null;
|
||||||
@@ -61,7 +61,7 @@ public class PluginConf {
|
|||||||
* The author of the plugin.
|
* The author of the plugin.
|
||||||
* @return author
|
* @return author
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "jmattheis", value = "The author of the plugin.")
|
@Schema(example = "jmattheis", description = "The author of the plugin.")
|
||||||
public String getAuthor() {
|
public String getAuthor() {
|
||||||
return author;
|
return author;
|
||||||
}
|
}
|
||||||
@@ -80,7 +80,7 @@ public class PluginConf {
|
|||||||
* Capabilities the plugin provides
|
* Capabilities the plugin provides
|
||||||
* @return capabilities
|
* @return capabilities
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "[\"webhook\",\"display\"]", required = true, value = "Capabilities the plugin provides")
|
@Schema(example = "[\"webhook\",\"display\"]", required = true, description = "Capabilities the plugin provides")
|
||||||
public List<String> getCapabilities() {
|
public List<String> getCapabilities() {
|
||||||
return capabilities;
|
return capabilities;
|
||||||
}
|
}
|
||||||
@@ -98,7 +98,7 @@ public class PluginConf {
|
|||||||
* Whether the plugin instance is enabled.
|
* Whether the plugin instance is enabled.
|
||||||
* @return enabled
|
* @return enabled
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "true", required = true, value = "Whether the plugin instance is enabled.")
|
@Schema(example = "true", required = true, description = "Whether the plugin instance is enabled.")
|
||||||
public Boolean isEnabled() {
|
public Boolean isEnabled() {
|
||||||
return enabled;
|
return enabled;
|
||||||
}
|
}
|
||||||
@@ -111,7 +111,7 @@ public class PluginConf {
|
|||||||
* The plugin id.
|
* The plugin id.
|
||||||
* @return id
|
* @return id
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "25", required = true, value = "The plugin id.")
|
@Schema(example = "25", required = true, description = "The plugin id.")
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
@@ -120,7 +120,7 @@ public class PluginConf {
|
|||||||
* The license of the plugin.
|
* The license of the plugin.
|
||||||
* @return license
|
* @return license
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "MIT", value = "The license of the plugin.")
|
@Schema(example = "MIT", description = "The license of the plugin.")
|
||||||
public String getLicense() {
|
public String getLicense() {
|
||||||
return license;
|
return license;
|
||||||
}
|
}
|
||||||
@@ -129,7 +129,7 @@ public class PluginConf {
|
|||||||
* The module path of the plugin.
|
* The module path of the plugin.
|
||||||
* @return modulePath
|
* @return modulePath
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "github.com/gotify/server/plugin/example/echo", required = true, value = "The module path of the plugin.")
|
@Schema(example = "github.com/gotify/server/plugin/example/echo", required = true, description = "The module path of the plugin.")
|
||||||
public String getModulePath() {
|
public String getModulePath() {
|
||||||
return modulePath;
|
return modulePath;
|
||||||
}
|
}
|
||||||
@@ -138,7 +138,7 @@ public class PluginConf {
|
|||||||
* The plugin name.
|
* The plugin name.
|
||||||
* @return name
|
* @return name
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "RSS poller", required = true, value = "The plugin name.")
|
@Schema(example = "RSS poller", required = true, description = "The plugin name.")
|
||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
@@ -152,7 +152,7 @@ public class PluginConf {
|
|||||||
* The user name. For login.
|
* The user name. For login.
|
||||||
* @return token
|
* @return token
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "P1234", required = true, value = "The user name. For login.")
|
@Schema(example = "P1234", required = true, description = "The user name. For login.")
|
||||||
public String getToken() {
|
public String getToken() {
|
||||||
return token;
|
return token;
|
||||||
}
|
}
|
||||||
@@ -165,7 +165,7 @@ public class PluginConf {
|
|||||||
* The website of the plugin.
|
* The website of the plugin.
|
||||||
* @return website
|
* @return website
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "gotify.net", value = "The website of the plugin.")
|
@Schema(example = "gotify.net", description = "The website of the plugin.")
|
||||||
public String getWebsite() {
|
public String getWebsite() {
|
||||||
return website;
|
return website;
|
||||||
}
|
}
|
||||||
@@ -227,4 +227,3 @@ public class PluginConf {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
/*
|
||||||
|
* 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.IOException;
|
||||||
|
/**
|
||||||
|
* Used for updating a user.
|
||||||
|
*/
|
||||||
|
@Schema(description = "Used for updating a user.")
|
||||||
|
|
||||||
|
|
||||||
|
public class UpdateUserExternal {
|
||||||
|
@SerializedName("admin")
|
||||||
|
private Boolean admin = null;
|
||||||
|
|
||||||
|
@SerializedName("name")
|
||||||
|
private String name = null;
|
||||||
|
|
||||||
|
@SerializedName("pass")
|
||||||
|
private String pass = null;
|
||||||
|
|
||||||
|
public UpdateUserExternal admin(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() {
|
||||||
|
return admin;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setAdmin(Boolean admin) {
|
||||||
|
this.admin = admin;
|
||||||
|
}
|
||||||
|
|
||||||
|
public UpdateUserExternal name(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.")
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public UpdateUserExternal pass(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")
|
||||||
|
public String getPass() {
|
||||||
|
return pass;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPass(String pass) {
|
||||||
|
this.pass = pass;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean equals(java.lang.Object o) {
|
||||||
|
if (this == o) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (o == null || getClass() != o.getClass()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
UpdateUserExternal updateUserExternal = (UpdateUserExternal) o;
|
||||||
|
return Objects.equals(this.admin, updateUserExternal.admin) &&
|
||||||
|
Objects.equals(this.name, updateUserExternal.name) &&
|
||||||
|
Objects.equals(this.pass, updateUserExternal.pass);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
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");
|
||||||
|
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 ");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,23 +10,23 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The User holds information about permission and other stuff.
|
* The User holds information about permission and other stuff.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "The User holds information about permission and other stuff.")
|
@Schema(description = "The User holds information about permission and other stuff.")
|
||||||
|
|
||||||
|
|
||||||
public class User {
|
public class User {
|
||||||
@SerializedName("admin")
|
@SerializedName("admin")
|
||||||
private Boolean admin = null;
|
private Boolean admin = null;
|
||||||
@@ -46,7 +46,7 @@ public class User {
|
|||||||
* If the user is an administrator.
|
* If the user is an administrator.
|
||||||
* @return admin
|
* @return admin
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "true", value = "If the user is an administrator.")
|
@Schema(example = "true", required = true, description = "If the user is an administrator.")
|
||||||
public Boolean isAdmin() {
|
public Boolean isAdmin() {
|
||||||
return admin;
|
return admin;
|
||||||
}
|
}
|
||||||
@@ -59,7 +59,7 @@ public class User {
|
|||||||
* The user id.
|
* The user id.
|
||||||
* @return id
|
* @return id
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "25", required = true, value = "The user id.")
|
@Schema(example = "25", required = true, description = "The user id.")
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
@@ -73,7 +73,7 @@ public class User {
|
|||||||
* The user name. For login.
|
* The user name. For login.
|
||||||
* @return name
|
* @return name
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "unicorn", required = true, value = "The user name. For login.")
|
@Schema(example = "unicorn", required = true, description = "The user name. For login.")
|
||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
@@ -127,4 +127,3 @@ public class User {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,23 +10,23 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Password for updating the user.
|
* The Password for updating the user.
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "The Password for updating the user.")
|
@Schema(description = "The Password for updating the user.")
|
||||||
|
|
||||||
|
|
||||||
public class UserPass {
|
public class UserPass {
|
||||||
@SerializedName("pass")
|
@SerializedName("pass")
|
||||||
private String pass = null;
|
private String pass = null;
|
||||||
@@ -40,7 +40,7 @@ public class UserPass {
|
|||||||
* The user password. For login.
|
* The user password. For login.
|
||||||
* @return pass
|
* @return pass
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "nrocinu", required = true, value = "The user password. For login.")
|
@Schema(example = "nrocinu", required = true, description = "The user password. For login.")
|
||||||
public String getPass() {
|
public String getPass() {
|
||||||
return pass;
|
return pass;
|
||||||
}
|
}
|
||||||
@@ -90,4 +90,3 @@ public class UserPass {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
* Gotify REST-API.
|
* 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 either transmitted through a header named `X-Gotify-Key` or a query parameter named `token`. 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)
|
* 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.1
|
* OpenAPI spec version: 2.0.2
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* NOTE: This class is auto generated by the swagger code generator program.
|
* NOTE: This class is auto generated by the swagger code generator program.
|
||||||
@@ -10,23 +10,23 @@
|
|||||||
* Do not edit the class manually.
|
* Do not edit the class manually.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
package com.github.gotify.client.model;
|
package com.github.gotify.client.model;
|
||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Arrays;
|
||||||
import com.google.gson.TypeAdapter;
|
import com.google.gson.TypeAdapter;
|
||||||
import com.google.gson.annotations.JsonAdapter;
|
import com.google.gson.annotations.JsonAdapter;
|
||||||
import com.google.gson.annotations.SerializedName;
|
import com.google.gson.annotations.SerializedName;
|
||||||
import com.google.gson.stream.JsonReader;
|
import com.google.gson.stream.JsonReader;
|
||||||
import com.google.gson.stream.JsonWriter;
|
import com.google.gson.stream.JsonWriter;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* VersionInfo Model
|
* VersionInfo Model
|
||||||
*/
|
*/
|
||||||
@ApiModel(description = "VersionInfo Model")
|
@Schema(description = "VersionInfo Model")
|
||||||
|
|
||||||
|
|
||||||
public class VersionInfo {
|
public class VersionInfo {
|
||||||
@SerializedName("buildDate")
|
@SerializedName("buildDate")
|
||||||
private String buildDate = null;
|
private String buildDate = null;
|
||||||
@@ -46,7 +46,7 @@ public class VersionInfo {
|
|||||||
* The date on which this binary was built.
|
* The date on which this binary was built.
|
||||||
* @return buildDate
|
* @return buildDate
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "2018-02-27T19:36:10.5045044+01:00", required = true, value = "The date on which this binary was built.")
|
@Schema(example = "2018-02-27T19:36:10.5045044+01:00", required = true, description = "The date on which this binary was built.")
|
||||||
public String getBuildDate() {
|
public String getBuildDate() {
|
||||||
return buildDate;
|
return buildDate;
|
||||||
}
|
}
|
||||||
@@ -64,7 +64,7 @@ public class VersionInfo {
|
|||||||
* The git commit hash on which this binary was built.
|
* The git commit hash on which this binary was built.
|
||||||
* @return commit
|
* @return commit
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "ae9512b6b6feea56a110d59a3353ea3b9c293864", required = true, value = "The git commit hash on which this binary was built.")
|
@Schema(example = "ae9512b6b6feea56a110d59a3353ea3b9c293864", required = true, description = "The git commit hash on which this binary was built.")
|
||||||
public String getCommit() {
|
public String getCommit() {
|
||||||
return commit;
|
return commit;
|
||||||
}
|
}
|
||||||
@@ -82,7 +82,7 @@ public class VersionInfo {
|
|||||||
* The current version.
|
* The current version.
|
||||||
* @return version
|
* @return version
|
||||||
**/
|
**/
|
||||||
@ApiModelProperty(example = "5.2.6", required = true, value = "The current version.")
|
@Schema(example = "5.2.6", required = true, description = "The current version.")
|
||||||
public String getVersion() {
|
public String getVersion() {
|
||||||
return version;
|
return version;
|
||||||
}
|
}
|
||||||
@@ -136,4 +136,3 @@ public class VersionInfo {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,16 +2,19 @@ package com.github.gotify.client.api;
|
|||||||
|
|
||||||
import com.github.gotify.client.ApiClient;
|
import com.github.gotify.client.ApiClient;
|
||||||
import com.github.gotify.client.model.Application;
|
import com.github.gotify.client.model.Application;
|
||||||
|
import com.github.gotify.client.model.ApplicationParams;
|
||||||
import com.github.gotify.client.model.Error;
|
import com.github.gotify.client.model.Error;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for ApplicationApi
|
* API tests for ApplicationApi
|
||||||
*/
|
*/
|
||||||
@@ -24,6 +27,7 @@ public class ApplicationApiTest {
|
|||||||
api = new ApiClient().createService(ApplicationApi.class);
|
api = new ApiClient().createService(ApplicationApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create an application.
|
* Create an application.
|
||||||
*
|
*
|
||||||
@@ -31,11 +35,12 @@ public class ApplicationApiTest {
|
|||||||
*/
|
*/
|
||||||
@Test
|
@Test
|
||||||
public void createAppTest() {
|
public void createAppTest() {
|
||||||
Application body = null;
|
ApplicationParams body = null;
|
||||||
// Application response = api.createApp(body);
|
// Application response = api.createApp(body);
|
||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Delete an application.
|
* Delete an application.
|
||||||
*
|
*
|
||||||
@@ -48,6 +53,7 @@ public class ApplicationApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all applications.
|
* Return all applications.
|
||||||
*
|
*
|
||||||
@@ -59,6 +65,20 @@ public class ApplicationApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// 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.
|
* Update an application.
|
||||||
*
|
*
|
||||||
@@ -66,12 +86,13 @@ public class ApplicationApiTest {
|
|||||||
*/
|
*/
|
||||||
@Test
|
@Test
|
||||||
public void updateApplicationTest() {
|
public void updateApplicationTest() {
|
||||||
Application body = null;
|
ApplicationParams body = null;
|
||||||
Long id = null;
|
Long id = null;
|
||||||
// Application response = api.updateApplication(body, id);
|
// Application response = api.updateApplication(body, id);
|
||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Upload an image for an application.
|
* Upload an image for an application.
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -2,15 +2,18 @@ package com.github.gotify.client.api;
|
|||||||
|
|
||||||
import com.github.gotify.client.ApiClient;
|
import com.github.gotify.client.ApiClient;
|
||||||
import com.github.gotify.client.model.Client;
|
import com.github.gotify.client.model.Client;
|
||||||
|
import com.github.gotify.client.model.ClientParams;
|
||||||
import com.github.gotify.client.model.Error;
|
import com.github.gotify.client.model.Error;
|
||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for ClientApi
|
* API tests for ClientApi
|
||||||
*/
|
*/
|
||||||
@@ -23,6 +26,7 @@ public class ClientApiTest {
|
|||||||
api = new ApiClient().createService(ClientApi.class);
|
api = new ApiClient().createService(ClientApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a client.
|
* Create a client.
|
||||||
*
|
*
|
||||||
@@ -30,11 +34,12 @@ public class ClientApiTest {
|
|||||||
*/
|
*/
|
||||||
@Test
|
@Test
|
||||||
public void createClientTest() {
|
public void createClientTest() {
|
||||||
Client body = null;
|
ClientParams body = null;
|
||||||
// Client response = api.createClient(body);
|
// Client response = api.createClient(body);
|
||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Delete a client.
|
* Delete a client.
|
||||||
*
|
*
|
||||||
@@ -47,6 +52,7 @@ public class ClientApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all clients.
|
* Return all clients.
|
||||||
*
|
*
|
||||||
@@ -58,6 +64,7 @@ public class ClientApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Update a client.
|
* Update a client.
|
||||||
*
|
*
|
||||||
@@ -65,7 +72,7 @@ public class ClientApiTest {
|
|||||||
*/
|
*/
|
||||||
@Test
|
@Test
|
||||||
public void updateClientTest() {
|
public void updateClientTest() {
|
||||||
Client body = null;
|
ClientParams body = null;
|
||||||
Long id = null;
|
Long id = null;
|
||||||
// Client response = api.updateClient(body, id);
|
// Client response = api.updateClient(body, id);
|
||||||
|
|
||||||
|
|||||||
@@ -5,11 +5,13 @@ import com.github.gotify.client.model.Health;
|
|||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for HealthApi
|
* API tests for HealthApi
|
||||||
*/
|
*/
|
||||||
@@ -22,6 +24,7 @@ public class HealthApiTest {
|
|||||||
api = new ApiClient().createService(HealthApi.class);
|
api = new ApiClient().createService(HealthApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get health information.
|
* Get health information.
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -7,11 +7,13 @@ import com.github.gotify.client.model.PagedMessages;
|
|||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for MessageApi
|
* API tests for MessageApi
|
||||||
*/
|
*/
|
||||||
@@ -24,6 +26,7 @@ public class MessageApiTest {
|
|||||||
api = new ApiClient().createService(MessageApi.class);
|
api = new ApiClient().createService(MessageApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a message.
|
* Create a message.
|
||||||
*
|
*
|
||||||
@@ -36,6 +39,7 @@ public class MessageApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Delete all messages from a specific application.
|
* Delete all messages from a specific application.
|
||||||
*
|
*
|
||||||
@@ -48,6 +52,7 @@ public class MessageApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Deletes a message with an id.
|
* Deletes a message with an id.
|
||||||
*
|
*
|
||||||
@@ -60,6 +65,7 @@ public class MessageApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Delete all messages.
|
* Delete all messages.
|
||||||
*
|
*
|
||||||
@@ -71,6 +77,7 @@ public class MessageApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all messages from a specific application.
|
* Return all messages from a specific application.
|
||||||
*
|
*
|
||||||
@@ -85,6 +92,7 @@ public class MessageApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all messages.
|
* Return all messages.
|
||||||
*
|
*
|
||||||
@@ -98,6 +106,7 @@ public class MessageApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Websocket, return newly created messages.
|
* Websocket, return newly created messages.
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -6,11 +6,13 @@ import com.github.gotify.client.model.PluginConf;
|
|||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for PluginApi
|
* API tests for PluginApi
|
||||||
*/
|
*/
|
||||||
@@ -23,6 +25,7 @@ public class PluginApiTest {
|
|||||||
api = new ApiClient().createService(PluginApi.class);
|
api = new ApiClient().createService(PluginApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Disable a plugin.
|
* Disable a plugin.
|
||||||
*
|
*
|
||||||
@@ -35,6 +38,7 @@ public class PluginApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Enable a plugin.
|
* Enable a plugin.
|
||||||
*
|
*
|
||||||
@@ -47,6 +51,7 @@ public class PluginApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get YAML configuration for Configurer plugin.
|
* Get YAML configuration for Configurer plugin.
|
||||||
*
|
*
|
||||||
@@ -59,6 +64,7 @@ public class PluginApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get display info for a Displayer plugin.
|
* Get display info for a Displayer plugin.
|
||||||
*
|
*
|
||||||
@@ -71,6 +77,7 @@ public class PluginApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all plugins.
|
* Return all plugins.
|
||||||
*
|
*
|
||||||
@@ -82,6 +89,7 @@ public class PluginApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Update YAML configuration for Configurer plugin.
|
* Update YAML configuration for Configurer plugin.
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -1,18 +1,21 @@
|
|||||||
package com.github.gotify.client.api;
|
package com.github.gotify.client.api;
|
||||||
|
|
||||||
import com.github.gotify.client.ApiClient;
|
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.Error;
|
||||||
|
import com.github.gotify.client.model.UpdateUserExternal;
|
||||||
import com.github.gotify.client.model.User;
|
import com.github.gotify.client.model.User;
|
||||||
import com.github.gotify.client.model.UserPass;
|
import com.github.gotify.client.model.UserPass;
|
||||||
import com.github.gotify.client.model.UserWithPass;
|
|
||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for UserApi
|
* API tests for UserApi
|
||||||
*/
|
*/
|
||||||
@@ -25,18 +28,20 @@ public class UserApiTest {
|
|||||||
api = new ApiClient().createService(UserApi.class);
|
api = new ApiClient().createService(UserApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a user.
|
* 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
|
@Test
|
||||||
public void createUserTest() {
|
public void createUserTest() {
|
||||||
UserWithPass body = null;
|
CreateUserExternal body = null;
|
||||||
// User response = api.createUser(body);
|
// User response = api.createUser(body);
|
||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return the current user.
|
* Return the current user.
|
||||||
*
|
*
|
||||||
@@ -48,6 +53,7 @@ public class UserApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Deletes a user.
|
* Deletes a user.
|
||||||
*
|
*
|
||||||
@@ -60,6 +66,7 @@ public class UserApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get a user.
|
* Get a user.
|
||||||
*
|
*
|
||||||
@@ -72,6 +79,7 @@ public class UserApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all users.
|
* Return all users.
|
||||||
*
|
*
|
||||||
@@ -83,6 +91,7 @@ public class UserApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Update the password of the current user.
|
* Update the password of the current user.
|
||||||
*
|
*
|
||||||
@@ -95,6 +104,7 @@ public class UserApiTest {
|
|||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Update a user.
|
* Update a user.
|
||||||
*
|
*
|
||||||
@@ -102,9 +112,9 @@ public class UserApiTest {
|
|||||||
*/
|
*/
|
||||||
@Test
|
@Test
|
||||||
public void updateUserTest() {
|
public void updateUserTest() {
|
||||||
|
UpdateUserExternal body = null;
|
||||||
Long id = null;
|
Long id = null;
|
||||||
UserWithPass body = null;
|
// User response = api.updateUser(body, id);
|
||||||
// User response = api.updateUser(id, body);
|
|
||||||
|
|
||||||
// TODO: test validations
|
// TODO: test validations
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,11 +5,13 @@ import com.github.gotify.client.model.VersionInfo;
|
|||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* API tests for VersionApi
|
* API tests for VersionApi
|
||||||
*/
|
*/
|
||||||
@@ -22,6 +24,7 @@ public class VersionApiTest {
|
|||||||
api = new ApiClient().createService(VersionApi.class);
|
api = new ApiClient().createService(VersionApi.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get version information.
|
* Get version information.
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user