From 58505c04a17dd7182f29eb9a775583d85804b5c2 Mon Sep 17 00:00:00 2001 From: Michael Vlach Date: Sat, 12 Oct 2024 10:55:13 +0200 Subject: [PATCH 1/5] add addmin user logout --- agdb_api/rust/src/api.rs | 12 ++++ agdb_server/src/api.rs | 1 + agdb_server/src/app.rs | 4 ++ agdb_server/src/routes/admin/user.rs | 26 ++++++++ agdb_server/src/routes/user.rs | 3 +- .../tests/routes/admin_user_logout_test.rs | 61 +++++++++++++++++++ agdb_server/tests/routes/mod.rs | 1 + .../pages/docs/references/server.en-US.md | 1 + 8 files changed, 107 insertions(+), 2 deletions(-) create mode 100644 agdb_server/tests/routes/admin_user_logout_test.rs diff --git a/agdb_api/rust/src/api.rs b/agdb_api/rust/src/api.rs index 07f85eed7..6ee3213da 100644 --- a/agdb_api/rust/src/api.rs +++ b/agdb_api/rust/src/api.rs @@ -279,6 +279,18 @@ impl AgdbApi { .await } + pub async fn admin_user_logout(&self, user: &str) -> AgdbApiResult { + Ok(self + .client + .post::<(), ()>( + &self.url(&format!("/admin/user/{user}/logout")), + &None, + &self.token, + ) + .await? + .0) + } + pub async fn admin_user_remove(&self, user: &str) -> AgdbApiResult { self.client .delete( diff --git a/agdb_server/src/api.rs b/agdb_server/src/api.rs index 76709df28..209d28a11 100644 --- a/agdb_server/src/api.rs +++ b/agdb_server/src/api.rs @@ -29,6 +29,7 @@ use utoipa::OpenApi; routes::admin::user::change_password, routes::admin::user::add, routes::admin::user::list, + routes::admin::user::logout, routes::admin::user::remove, routes::admin::shutdown, routes::admin::status, diff --git a/agdb_server/src/app.rs b/agdb_server/src/app.rs index d30687be4..8f95db561 100644 --- a/agdb_server/src/app.rs +++ b/agdb_server/src/app.rs @@ -33,6 +33,10 @@ pub(crate) fn app( .route("/admin/shutdown", routing::post(routes::admin::shutdown)) .route("/admin/status", routing::get(routes::admin::status)) .route("/admin/user/list", routing::get(routes::admin::user::list)) + .route( + "/admin/user/:user/logout", + routing::post(routes::admin::user::logout), + ) .route( "/admin/user/:user/add", routing::post(routes::admin::user::add), diff --git a/agdb_server/src/routes/admin/user.rs b/agdb_server/src/routes/admin/user.rs index 456a622e9..73a860c08 100644 --- a/agdb_server/src/routes/admin/user.rs +++ b/agdb_server/src/routes/admin/user.rs @@ -104,6 +104,32 @@ pub(crate) async fn list( Ok((StatusCode::OK, Json(users))) } +#[utoipa::path(post, + path = "/api/v1/admin/user/logout", + operation_id = "admin_user_logout", + tag = "agdb", + security(("Token" = [])), + params( + ("username" = String, Path, description = "user name"), + ), + responses( + (status = 201, description = "user logged out"), + (status = 401, description = "admin only"), + (status = 404, description = "user not found"), + ) +)] +pub(crate) async fn logout( + _admin: AdminId, + State(db_pool): State, + Path(username): Path, +) -> ServerResponse { + let mut user = db_pool.find_user(&username).await?; + user.token = String::new(); + db_pool.save_user(user).await?; + + Ok(StatusCode::CREATED) +} + #[utoipa::path(delete, path = "/api/v1/admin/user/{username}/remove", operation_id = "admin_user_remove", diff --git a/agdb_server/src/routes/user.rs b/agdb_server/src/routes/user.rs index f8a1a70b2..731b5367a 100644 --- a/agdb_server/src/routes/user.rs +++ b/agdb_server/src/routes/user.rs @@ -45,8 +45,7 @@ pub(crate) async fn login( security(("Token" = [])), responses( (status = 201, description = "user logged out"), - (status = 401, description = "invalid credentials"), - (status = 404, description = "user not found"), + (status = 401, description = "invalid credentials") ) )] pub(crate) async fn logout(user: UserId, State(db_pool): State) -> ServerResponse { diff --git a/agdb_server/tests/routes/admin_user_logout_test.rs b/agdb_server/tests/routes/admin_user_logout_test.rs new file mode 100644 index 000000000..576dbeaab --- /dev/null +++ b/agdb_server/tests/routes/admin_user_logout_test.rs @@ -0,0 +1,61 @@ +use crate::TestServer; +use crate::ADMIN; + +#[tokio::test] +async fn logout() -> anyhow::Result<()> { + let mut server = TestServer::new().await?; + let user = &server.next_user_name(); + server.api.user_login(ADMIN, ADMIN).await?; + server.api.admin_user_add(user, user).await?; + server.api.user_login(user, user).await?; + let token = server.api.token.clone(); + server.api.user_login(ADMIN, ADMIN).await?; + server.api.admin_user_logout(user).await?; + server.api.token = token; + let status = server.api.db_list().await.unwrap_err().status; + assert_eq!(status, 401); + + Ok(()) +} + +#[tokio::test] +async fn unknown_user() -> anyhow::Result<()> { + let mut server = TestServer::new().await?; + server.api.user_login(ADMIN, ADMIN).await?; + let status = server + .api + .admin_user_logout("unknown_user") + .await + .unwrap_err() + .status; + assert_eq!(status, 404); + + Ok(()) +} + +#[tokio::test] +async fn non_admin() -> anyhow::Result<()> { + let mut server = TestServer::new().await?; + let user = &server.next_user_name(); + server.api.user_login(ADMIN, ADMIN).await?; + server.api.admin_user_add(user, user).await?; + server.api.user_login(user, user).await?; + let status = server.api.admin_user_logout(user).await.unwrap_err().status; + assert_eq!(status, 401); + + Ok(()) +} + +#[tokio::test] +async fn no_token() -> anyhow::Result<()> { + let server = TestServer::new().await?; + let status = server + .api + .admin_user_logout("user") + .await + .unwrap_err() + .status; + assert_eq!(status, 401); + + Ok(()) +} diff --git a/agdb_server/tests/routes/mod.rs b/agdb_server/tests/routes/mod.rs index 4388c5e80..3d13ad43e 100644 --- a/agdb_server/tests/routes/mod.rs +++ b/agdb_server/tests/routes/mod.rs @@ -14,6 +14,7 @@ mod admin_db_user_remove_test; mod admin_user_add_test; mod admin_user_change_password_test; mod admin_user_list_test; +mod admin_user_logout_test; mod admin_user_remove_test; mod admins_status_test; mod db_add_test; diff --git a/agdb_web/pages/docs/references/server.en-US.md b/agdb_web/pages/docs/references/server.en-US.md index fa3fd18d0..f11f6e724 100644 --- a/agdb_web/pages/docs/references/server.en-US.md +++ b/agdb_web/pages/docs/references/server.en-US.md @@ -149,6 +149,7 @@ Each `agdb_server` has exactly one admin account (`admin` by default) that acts | /api/v1/admin/shutdown | gracefully shuts down the server | | /api/v1/admin/status | lists extended statiscs on the server - uptim, # dbs, # users, # logged users, server data size | | /api/v1/admin/user/list | lists the all users on the server | +| /api/v1/admin/user/{username}/logout | force logout of any user | | /api/v1/admin/user/{username}/add | adds new user to the server | | /api/v1/admin/user/{username}/change_password | changes password of a user | | /api/v1/admin/user/{username}/remove | deletes user and all their data (databases) from the server | From 3f9a02373c3ca01afc148683b75b07b94ba6edf4 Mon Sep 17 00:00:00 2001 From: Michael Vlach Date: Sat, 12 Oct 2024 11:02:09 +0200 Subject: [PATCH 2/5] update apis --- agdb_api/php/README.md | 1 + agdb_api/php/docs/Api/AgdbApi.md | 58 +++++++ agdb_api/php/docs/Model/UserStatus.md | 1 + agdb_api/php/lib/Api/AgdbApi.php | 228 ++++++++++++++++++++++++++ agdb_api/php/lib/Model/UserStatus.php | 37 +++++ agdb_api/typescript/src/openapi.d.ts | 37 ++++- agdb_ci/src/main.rs | 2 +- agdb_server/openapi.json | 44 ++++- 8 files changed, 401 insertions(+), 7 deletions(-) diff --git a/agdb_api/php/README.md b/agdb_api/php/README.md index 6b02d77dc..9e98c28ac 100644 --- a/agdb_api/php/README.md +++ b/agdb_api/php/README.md @@ -96,6 +96,7 @@ Class | Method | HTTP request | Description *AgdbApi* | [**adminUserAdd**](docs/Api/AgdbApi.md#adminuseradd) | **POST** /api/v1/admin/user/{username}/add | *AgdbApi* | [**adminUserChangePassword**](docs/Api/AgdbApi.md#adminuserchangepassword) | **PUT** /api/v1/admin/user/{username}/change_password | *AgdbApi* | [**adminUserList**](docs/Api/AgdbApi.md#adminuserlist) | **GET** /api/v1/admin/user/list | +*AgdbApi* | [**adminUserLogout**](docs/Api/AgdbApi.md#adminuserlogout) | **POST** /api/v1/admin/user/logout | *AgdbApi* | [**adminUserRemove**](docs/Api/AgdbApi.md#adminuserremove) | **DELETE** /api/v1/admin/user/{username}/remove | *AgdbApi* | [**clusterStatus**](docs/Api/AgdbApi.md#clusterstatus) | **GET** /api/v1/cluster/status | *AgdbApi* | [**dbAdd**](docs/Api/AgdbApi.md#dbadd) | **POST** /api/v1/db/{owner}/{db}/add | diff --git a/agdb_api/php/docs/Api/AgdbApi.md b/agdb_api/php/docs/Api/AgdbApi.md index b790ab9e2..da11542fd 100644 --- a/agdb_api/php/docs/Api/AgdbApi.md +++ b/agdb_api/php/docs/Api/AgdbApi.md @@ -23,6 +23,7 @@ All URIs are relative to http://localhost:3000, except if the operation defines | [**adminUserAdd()**](AgdbApi.md#adminUserAdd) | **POST** /api/v1/admin/user/{username}/add | | | [**adminUserChangePassword()**](AgdbApi.md#adminUserChangePassword) | **PUT** /api/v1/admin/user/{username}/change_password | | | [**adminUserList()**](AgdbApi.md#adminUserList) | **GET** /api/v1/admin/user/list | | +| [**adminUserLogout()**](AgdbApi.md#adminUserLogout) | **POST** /api/v1/admin/user/logout | | | [**adminUserRemove()**](AgdbApi.md#adminUserRemove) | **DELETE** /api/v1/admin/user/{username}/remove | | | [**clusterStatus()**](AgdbApi.md#clusterStatus) | **GET** /api/v1/cluster/status | | | [**dbAdd()**](AgdbApi.md#dbAdd) | **POST** /api/v1/db/{owner}/{db}/add | | @@ -1168,6 +1169,63 @@ This endpoint does not need any parameter. [[Back to Model list]](../../README.md#models) [[Back to README]](../../README.md) +## `adminUserLogout()` + +```php +adminUserLogout($username) +``` + + + +### Example + +```php +setAccessToken('YOUR_ACCESS_TOKEN'); + + +$apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( + // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`. + // This is optional, `GuzzleHttp\Client` will be used as default. + new GuzzleHttp\Client(), + $config +); +$username = 'username_example'; // string | user name + +try { + $apiInstance->adminUserLogout($username); +} catch (Exception $e) { + echo 'Exception when calling AgdbApi->adminUserLogout: ', $e->getMessage(), PHP_EOL; +} +``` + +### Parameters + +| Name | Type | Description | Notes | +| ------------- | ------------- | ------------- | ------------- | +| **username** | **string**| user name | | + +### Return type + +void (empty response body) + +### Authorization + +[Token](../../README.md#Token) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: Not defined + +[[Back to top]](#) [[Back to API list]](../../README.md#endpoints) +[[Back to Model list]](../../README.md#models) +[[Back to README]](../../README.md) + ## `adminUserRemove()` ```php diff --git a/agdb_api/php/docs/Model/UserStatus.md b/agdb_api/php/docs/Model/UserStatus.md index 077326098..9a277797f 100644 --- a/agdb_api/php/docs/Model/UserStatus.md +++ b/agdb_api/php/docs/Model/UserStatus.md @@ -4,6 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**login** | **bool** | | **name** | **string** | | [[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md) diff --git a/agdb_api/php/lib/Api/AgdbApi.php b/agdb_api/php/lib/Api/AgdbApi.php index d056ce855..dc22a5b80 100644 --- a/agdb_api/php/lib/Api/AgdbApi.php +++ b/agdb_api/php/lib/Api/AgdbApi.php @@ -128,6 +128,9 @@ class AgdbApi 'adminUserList' => [ 'application/json', ], + 'adminUserLogout' => [ + 'application/json', + ], 'adminUserRemove' => [ 'application/json', ], @@ -5421,6 +5424,231 @@ public function adminUserListRequest(string $contentType = self::contentTypes['a ); } + /** + * Operation adminUserLogout + * + * @param string $username user name (required) + * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminUserLogout'] to see the possible values for this operation + * + * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format + * @throws \InvalidArgumentException + * @return void + */ + public function adminUserLogout($username, string $contentType = self::contentTypes['adminUserLogout'][0]) + { + $this->adminUserLogoutWithHttpInfo($username, $contentType); + } + + /** + * Operation adminUserLogoutWithHttpInfo + * + * @param string $username user name (required) + * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminUserLogout'] to see the possible values for this operation + * + * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format + * @throws \InvalidArgumentException + * @return array of null, HTTP status code, HTTP response headers (array of strings) + */ + public function adminUserLogoutWithHttpInfo($username, string $contentType = self::contentTypes['adminUserLogout'][0]) + { + $request = $this->adminUserLogoutRequest($username, $contentType); + + try { + $options = $this->createHttpClientOption(); + try { + $response = $this->client->send($request, $options); + } catch (RequestException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + $e->getResponse() ? $e->getResponse()->getHeaders() : null, + $e->getResponse() ? (string) $e->getResponse()->getBody() : null + ); + } catch (ConnectException $e) { + throw new ApiException( + "[{$e->getCode()}] {$e->getMessage()}", + (int) $e->getCode(), + null, + null + ); + } + + $statusCode = $response->getStatusCode(); + + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + + return [null, $statusCode, $response->getHeaders()]; + + } catch (ApiException $e) { + switch ($e->getCode()) { + } + throw $e; + } + } + + /** + * Operation adminUserLogoutAsync + * + * @param string $username user name (required) + * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminUserLogout'] to see the possible values for this operation + * + * @throws \InvalidArgumentException + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function adminUserLogoutAsync($username, string $contentType = self::contentTypes['adminUserLogout'][0]) + { + return $this->adminUserLogoutAsyncWithHttpInfo($username, $contentType) + ->then( + function ($response) { + return $response[0]; + } + ); + } + + /** + * Operation adminUserLogoutAsyncWithHttpInfo + * + * @param string $username user name (required) + * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminUserLogout'] to see the possible values for this operation + * + * @throws \InvalidArgumentException + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function adminUserLogoutAsyncWithHttpInfo($username, string $contentType = self::contentTypes['adminUserLogout'][0]) + { + $returnType = ''; + $request = $this->adminUserLogoutRequest($username, $contentType); + + return $this->client + ->sendAsync($request, $this->createHttpClientOption()) + ->then( + function ($response) use ($returnType) { + return [null, $response->getStatusCode(), $response->getHeaders()]; + }, + function ($exception) { + $response = $exception->getResponse(); + $statusCode = $response->getStatusCode(); + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + $exception->getRequest()->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + ); + } + + /** + * Create request for operation 'adminUserLogout' + * + * @param string $username user name (required) + * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminUserLogout'] to see the possible values for this operation + * + * @throws \InvalidArgumentException + * @return \GuzzleHttp\Psr7\Request + */ + public function adminUserLogoutRequest($username, string $contentType = self::contentTypes['adminUserLogout'][0]) + { + + // verify the required parameter 'username' is set + if ($username === null || (is_array($username) && count($username) === 0)) { + throw new \InvalidArgumentException( + 'Missing the required parameter $username when calling adminUserLogout' + ); + } + + + $resourcePath = '/api/v1/admin/user/logout'; + $formParams = []; + $queryParams = []; + $headerParams = []; + $httpBody = ''; + $multipart = false; + + + + // path params + if ($username !== null) { + $resourcePath = str_replace( + '{' . 'username' . '}', + ObjectSerializer::toPathValue($username), + $resourcePath + ); + } + + + $headers = $this->headerSelector->selectHeaders( + [], + $contentType, + $multipart + ); + + // for model (json/xml) + if (count($formParams) > 0) { + if ($multipart) { + $multipartContents = []; + foreach ($formParams as $formParamName => $formParamValue) { + $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue]; + foreach ($formParamValueItems as $formParamValueItem) { + $multipartContents[] = [ + 'name' => $formParamName, + 'contents' => $formParamValueItem + ]; + } + } + // for HTTP post (form) + $httpBody = new MultipartStream($multipartContents); + + } elseif (stripos($headers['Content-Type'], 'application/json') !== false) { + # if Content-Type contains "application/json", json_encode the form parameters + $httpBody = \GuzzleHttp\Utils::jsonEncode($formParams); + } else { + // for HTTP post (form) + $httpBody = ObjectSerializer::buildQuery($formParams); + } + } + + // this endpoint requires Bearer authentication (access token) + if (!empty($this->config->getAccessToken())) { + $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken(); + } + + $defaultHeaders = []; + if ($this->config->getUserAgent()) { + $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); + } + + $headers = array_merge( + $defaultHeaders, + $headerParams, + $headers + ); + + $operationHost = $this->config->getHost(); + $query = ObjectSerializer::buildQuery($queryParams); + return new Request( + 'POST', + $operationHost . $resourcePath . ($query ? "?{$query}" : ''), + $headers, + $httpBody + ); + } + /** * Operation adminUserRemove * diff --git a/agdb_api/php/lib/Model/UserStatus.php b/agdb_api/php/lib/Model/UserStatus.php index b56b29e7d..da7f42925 100644 --- a/agdb_api/php/lib/Model/UserStatus.php +++ b/agdb_api/php/lib/Model/UserStatus.php @@ -57,6 +57,7 @@ class UserStatus implements ModelInterface, ArrayAccess, \JsonSerializable * @var string[] */ protected static $openAPITypes = [ + 'login' => 'bool', 'name' => 'string' ]; @@ -68,6 +69,7 @@ class UserStatus implements ModelInterface, ArrayAccess, \JsonSerializable * @psalm-var array */ protected static $openAPIFormats = [ + 'login' => null, 'name' => null ]; @@ -77,6 +79,7 @@ class UserStatus implements ModelInterface, ArrayAccess, \JsonSerializable * @var boolean[] */ protected static array $openAPINullables = [ + 'login' => false, 'name' => false ]; @@ -166,6 +169,7 @@ public function isNullableSetToNull(string $property): bool * @var string[] */ protected static $attributeMap = [ + 'login' => 'login', 'name' => 'name' ]; @@ -175,6 +179,7 @@ public function isNullableSetToNull(string $property): bool * @var string[] */ protected static $setters = [ + 'login' => 'setLogin', 'name' => 'setName' ]; @@ -184,6 +189,7 @@ public function isNullableSetToNull(string $property): bool * @var string[] */ protected static $getters = [ + 'login' => 'getLogin', 'name' => 'getName' ]; @@ -244,6 +250,7 @@ public function getModelName() */ public function __construct(array $data = null) { + $this->setIfExists('login', $data ?? [], null); $this->setIfExists('name', $data ?? [], null); } @@ -274,6 +281,9 @@ public function listInvalidProperties() { $invalidProperties = []; + if ($this->container['login'] === null) { + $invalidProperties[] = "'login' can't be null"; + } if ($this->container['name'] === null) { $invalidProperties[] = "'name' can't be null"; } @@ -292,6 +302,33 @@ public function valid() } + /** + * Gets login + * + * @return bool + */ + public function getLogin() + { + return $this->container['login']; + } + + /** + * Sets login + * + * @param bool $login login + * + * @return self + */ + public function setLogin($login) + { + if (is_null($login)) { + throw new \InvalidArgumentException('non-nullable login cannot be null'); + } + $this->container['login'] = $login; + + return $this; + } + /** * Gets name * diff --git a/agdb_api/typescript/src/openapi.d.ts b/agdb_api/typescript/src/openapi.d.ts index e1944229b..acfe2dafb 100644 --- a/agdb_api/typescript/src/openapi.d.ts +++ b/agdb_api/typescript/src/openapi.d.ts @@ -1190,6 +1190,7 @@ declare namespace Components { username: string; } export interface UserStatus { + login: boolean; name: string; } } @@ -1531,6 +1532,22 @@ declare namespace Paths { } } } + namespace AdminUserLogout { + namespace Parameters { + export type Username = string; + } + export interface PathParameters { + username: Parameters.Username; + } + namespace Responses { + export interface $201 { + } + export interface $401 { + } + export interface $404 { + } + } + } namespace AdminUserRemove { namespace Parameters { export type Username = string; @@ -1893,8 +1910,6 @@ declare namespace Paths { } export interface $401 { } - export interface $404 { - } } } } @@ -2028,6 +2043,14 @@ export interface OperationMethods { data?: any, config?: AxiosRequestConfig ): OperationResponse + /** + * admin_user_logout + */ + 'admin_user_logout'( + parameters?: Parameters | null, + data?: any, + config?: AxiosRequestConfig + ): OperationResponse /** * admin_user_add */ @@ -2383,6 +2406,16 @@ export interface PathsDictionary { config?: AxiosRequestConfig ): OperationResponse } + ['/api/v1/admin/user/logout']: { + /** + * admin_user_logout + */ + 'post'( + parameters?: Parameters | null, + data?: any, + config?: AxiosRequestConfig + ): OperationResponse + } ['/api/v1/admin/user/{username}/add']: { /** * admin_user_add diff --git a/agdb_ci/src/main.rs b/agdb_ci/src/main.rs index 949fef3a5..3e551a24b 100644 --- a/agdb_ci/src/main.rs +++ b/agdb_ci/src/main.rs @@ -153,7 +153,7 @@ fn main() -> Result<(), CIError> { .arg("test") .arg("-p") .arg("agdb_server") - .arg("tests::openapi") + .arg("api::tests::openapi") .arg("--") .arg("--exact"), )?; diff --git a/agdb_server/openapi.json b/agdb_server/openapi.json index 9e39f1abd..198c31146 100644 --- a/agdb_server/openapi.json +++ b/agdb_server/openapi.json @@ -769,6 +769,41 @@ ] } }, + "/api/v1/admin/user/logout": { + "post": { + "tags": [ + "agdb" + ], + "operationId": "admin_user_logout", + "parameters": [ + { + "name": "username", + "in": "path", + "description": "user name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "201": { + "description": "user logged out" + }, + "401": { + "description": "admin only" + }, + "404": { + "description": "user not found" + } + }, + "security": [ + { + "Token": [] + } + ] + } + }, "/api/v1/admin/user/{username}/add": { "post": { "tags": [ @@ -1873,9 +1908,6 @@ }, "401": { "description": "invalid credentials" - }, - "404": { - "description": "user not found" } }, "security": [ @@ -3274,9 +3306,13 @@ "UserStatus": { "type": "object", "required": [ - "name" + "name", + "login" ], "properties": { + "login": { + "type": "boolean" + }, "name": { "type": "string" } From e88116cdc6ece7653adbb90210d3592b9007d7d9 Mon Sep 17 00:00:00 2001 From: Michael Vlach Date: Sat, 12 Oct 2024 11:31:10 +0200 Subject: [PATCH 3/5] update --- agdb_server/src/db_pool.rs | 44 ++++++++++++------- agdb_server/src/routes/admin/user.rs | 2 +- .../pages/docs/references/server.en-US.md | 20 ++++----- 3 files changed, 40 insertions(+), 26 deletions(-) diff --git a/agdb_server/src/db_pool.rs b/agdb_server/src/db_pool.rs index ae0cf98b8..245ea3e7b 100644 --- a/agdb_server/src/db_pool.rs +++ b/agdb_server/src/db_pool.rs @@ -1164,12 +1164,18 @@ impl DbPool { } pub(crate) async fn status(&self, config: &Config) -> ServerResult { + let indexes = self + .db() + .await + .exec(QueryBuilder::select().indexes().query())?; + tracing::info!("{:?}", indexes); + Ok(AdminStatus { uptime: SystemTime::now().duration_since(UNIX_EPOCH)?.as_secs() - config.start_time, dbs: self .db() .await - .exec(QueryBuilder::select().edge_count().ids("dbs").query())? + .exec(QueryBuilder::select().edge_count_from().ids("dbs").query())? .elements[0] .values[0] .value @@ -1177,24 +1183,32 @@ impl DbPool { users: self .db() .await - .exec(QueryBuilder::select().edge_count().ids("users").query())? + .exec( + QueryBuilder::select() + .edge_count_from() + .ids("users") + .query(), + )? .elements[0] .values[0] .value .to_u64()?, - logged_in_users: self - .db() - .await - .exec( - QueryBuilder::search() - .from("users") - .where_() - .key("token") - .value(Comparison::NotEqual("".into())) - .query(), - )? - .ids() - .len() as u64, + logged_in_users: self.db().await.transaction(|t| -> ServerResult { + let empty_tokens = if t + .exec(QueryBuilder::search().index("token").value("").query())? + .result + == 0 + { + 0 + } else { + 1 + }; + let tokens = t.exec(QueryBuilder::select().indexes().query())?.elements[0].values + [1] + .value + .to_u64()?; + Ok(tokens - empty_tokens) + })?, size: get_size(&config.data_dir).await?, }) } diff --git a/agdb_server/src/routes/admin/user.rs b/agdb_server/src/routes/admin/user.rs index 73a860c08..c5960d7bd 100644 --- a/agdb_server/src/routes/admin/user.rs +++ b/agdb_server/src/routes/admin/user.rs @@ -105,7 +105,7 @@ pub(crate) async fn list( } #[utoipa::path(post, - path = "/api/v1/admin/user/logout", + path = "/api/v1/admin/user/{username}/logout", operation_id = "admin_user_logout", tag = "agdb", security(("Token" = [])), diff --git a/agdb_web/pages/docs/references/server.en-US.md b/agdb_web/pages/docs/references/server.en-US.md index f11f6e724..9cc907cbb 100644 --- a/agdb_web/pages/docs/references/server.en-US.md +++ b/agdb_web/pages/docs/references/server.en-US.md @@ -144,16 +144,16 @@ However the `agdb` is written in such a way that it performs excellently even un Each `agdb_server` has exactly one admin account (`admin` by default) that acts as a regular user but additonally is allowed to execute APIs under `/admin/`. These mostly copies the APIs for regular users but some of the restrictions are not enforced (i.e. ownership or db role). Additionally the admin has access to the following exclusive APIs: -| Action | Description | -| --------------------------------------------- | ----------------------------------------------------------------------------------------------- | -| /api/v1/admin/shutdown | gracefully shuts down the server | -| /api/v1/admin/status | lists extended statiscs on the server - uptim, # dbs, # users, # logged users, server data size | -| /api/v1/admin/user/list | lists the all users on the server | -| /api/v1/admin/user/{username}/logout | force logout of any user | -| /api/v1/admin/user/{username}/add | adds new user to the server | -| /api/v1/admin/user/{username}/change_password | changes password of a user | -| /api/v1/admin/user/{username}/remove | deletes user and all their data (databases) from the server | -| /api/v1/admin/db/\* | provides same endpoints as for regular users but without owner/role restrictions | +| Action | Description | +| --------------------------------------------- | ------------------------------------------------------------------------------------------------ | +| /api/v1/admin/shutdown | gracefully shuts down the server | +| /api/v1/admin/status | lists extended statiscs on the server - uptime, # dbs, # users, # logged users, server data size | +| /api/v1/admin/user/list | lists the all users on the server | +| /api/v1/admin/user/{username}/logout | force logout of any user | +| /api/v1/admin/user/{username}/add | adds new user to the server | +| /api/v1/admin/user/{username}/change_password | changes password of a user | +| /api/v1/admin/user/{username}/remove | deletes user and all their data (databases) from the server | +| /api/v1/admin/db/\* | provides same endpoints as for regular users but without owner/role restrictions | ## Shutdown From 5a3b29b70526d85d384ca245df75f3ecda93cb07 Mon Sep 17 00:00:00 2001 From: Michael Vlach Date: Sat, 12 Oct 2024 11:32:42 +0200 Subject: [PATCH 4/5] update apis --- agdb_api/php/README.md | 2 +- agdb_api/php/docs/Api/AgdbApi.md | 2 +- agdb_api/php/lib/Api/AgdbApi.php | 2 +- agdb_api/typescript/src/openapi.d.ts | 36 +++++++------- agdb_server/openapi.json | 70 ++++++++++++++-------------- 5 files changed, 56 insertions(+), 56 deletions(-) diff --git a/agdb_api/php/README.md b/agdb_api/php/README.md index 9e98c28ac..e409d9043 100644 --- a/agdb_api/php/README.md +++ b/agdb_api/php/README.md @@ -96,7 +96,7 @@ Class | Method | HTTP request | Description *AgdbApi* | [**adminUserAdd**](docs/Api/AgdbApi.md#adminuseradd) | **POST** /api/v1/admin/user/{username}/add | *AgdbApi* | [**adminUserChangePassword**](docs/Api/AgdbApi.md#adminuserchangepassword) | **PUT** /api/v1/admin/user/{username}/change_password | *AgdbApi* | [**adminUserList**](docs/Api/AgdbApi.md#adminuserlist) | **GET** /api/v1/admin/user/list | -*AgdbApi* | [**adminUserLogout**](docs/Api/AgdbApi.md#adminuserlogout) | **POST** /api/v1/admin/user/logout | +*AgdbApi* | [**adminUserLogout**](docs/Api/AgdbApi.md#adminuserlogout) | **POST** /api/v1/admin/user/{username}/logout | *AgdbApi* | [**adminUserRemove**](docs/Api/AgdbApi.md#adminuserremove) | **DELETE** /api/v1/admin/user/{username}/remove | *AgdbApi* | [**clusterStatus**](docs/Api/AgdbApi.md#clusterstatus) | **GET** /api/v1/cluster/status | *AgdbApi* | [**dbAdd**](docs/Api/AgdbApi.md#dbadd) | **POST** /api/v1/db/{owner}/{db}/add | diff --git a/agdb_api/php/docs/Api/AgdbApi.md b/agdb_api/php/docs/Api/AgdbApi.md index da11542fd..0bfae9293 100644 --- a/agdb_api/php/docs/Api/AgdbApi.md +++ b/agdb_api/php/docs/Api/AgdbApi.md @@ -23,7 +23,7 @@ All URIs are relative to http://localhost:3000, except if the operation defines | [**adminUserAdd()**](AgdbApi.md#adminUserAdd) | **POST** /api/v1/admin/user/{username}/add | | | [**adminUserChangePassword()**](AgdbApi.md#adminUserChangePassword) | **PUT** /api/v1/admin/user/{username}/change_password | | | [**adminUserList()**](AgdbApi.md#adminUserList) | **GET** /api/v1/admin/user/list | | -| [**adminUserLogout()**](AgdbApi.md#adminUserLogout) | **POST** /api/v1/admin/user/logout | | +| [**adminUserLogout()**](AgdbApi.md#adminUserLogout) | **POST** /api/v1/admin/user/{username}/logout | | | [**adminUserRemove()**](AgdbApi.md#adminUserRemove) | **DELETE** /api/v1/admin/user/{username}/remove | | | [**clusterStatus()**](AgdbApi.md#clusterStatus) | **GET** /api/v1/cluster/status | | | [**dbAdd()**](AgdbApi.md#dbAdd) | **POST** /api/v1/db/{owner}/{db}/add | | diff --git a/agdb_api/php/lib/Api/AgdbApi.php b/agdb_api/php/lib/Api/AgdbApi.php index dc22a5b80..1aa510709 100644 --- a/agdb_api/php/lib/Api/AgdbApi.php +++ b/agdb_api/php/lib/Api/AgdbApi.php @@ -5573,7 +5573,7 @@ public function adminUserLogoutRequest($username, string $contentType = self::co } - $resourcePath = '/api/v1/admin/user/logout'; + $resourcePath = '/api/v1/admin/user/{username}/logout'; $formParams = []; $queryParams = []; $headerParams = []; diff --git a/agdb_api/typescript/src/openapi.d.ts b/agdb_api/typescript/src/openapi.d.ts index acfe2dafb..3090bbac9 100644 --- a/agdb_api/typescript/src/openapi.d.ts +++ b/agdb_api/typescript/src/openapi.d.ts @@ -2043,14 +2043,6 @@ export interface OperationMethods { data?: any, config?: AxiosRequestConfig ): OperationResponse - /** - * admin_user_logout - */ - 'admin_user_logout'( - parameters?: Parameters | null, - data?: any, - config?: AxiosRequestConfig - ): OperationResponse /** * admin_user_add */ @@ -2067,6 +2059,14 @@ export interface OperationMethods { data?: Paths.AdminUserChangePassword.RequestBody, config?: AxiosRequestConfig ): OperationResponse + /** + * admin_user_logout + */ + 'admin_user_logout'( + parameters?: Parameters | null, + data?: any, + config?: AxiosRequestConfig + ): OperationResponse /** * admin_user_remove */ @@ -2406,16 +2406,6 @@ export interface PathsDictionary { config?: AxiosRequestConfig ): OperationResponse } - ['/api/v1/admin/user/logout']: { - /** - * admin_user_logout - */ - 'post'( - parameters?: Parameters | null, - data?: any, - config?: AxiosRequestConfig - ): OperationResponse - } ['/api/v1/admin/user/{username}/add']: { /** * admin_user_add @@ -2436,6 +2426,16 @@ export interface PathsDictionary { config?: AxiosRequestConfig ): OperationResponse } + ['/api/v1/admin/user/{username}/logout']: { + /** + * admin_user_logout + */ + 'post'( + parameters?: Parameters | null, + data?: any, + config?: AxiosRequestConfig + ): OperationResponse + } ['/api/v1/admin/user/{username}/remove']: { /** * admin_user_remove diff --git a/agdb_server/openapi.json b/agdb_server/openapi.json index 198c31146..85f265998 100644 --- a/agdb_server/openapi.json +++ b/agdb_server/openapi.json @@ -769,41 +769,6 @@ ] } }, - "/api/v1/admin/user/logout": { - "post": { - "tags": [ - "agdb" - ], - "operationId": "admin_user_logout", - "parameters": [ - { - "name": "username", - "in": "path", - "description": "user name", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "201": { - "description": "user logged out" - }, - "401": { - "description": "admin only" - }, - "404": { - "description": "user not found" - } - }, - "security": [ - { - "Token": [] - } - ] - } - }, "/api/v1/admin/user/{username}/add": { "post": { "tags": [ @@ -903,6 +868,41 @@ ] } }, + "/api/v1/admin/user/{username}/logout": { + "post": { + "tags": [ + "agdb" + ], + "operationId": "admin_user_logout", + "parameters": [ + { + "name": "username", + "in": "path", + "description": "user name", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "201": { + "description": "user logged out" + }, + "401": { + "description": "admin only" + }, + "404": { + "description": "user not found" + } + }, + "security": [ + { + "Token": [] + } + ] + } + }, "/api/v1/admin/user/{username}/remove": { "delete": { "tags": [ From 9fae921f940256f16d42b818945e43b8e8584b89 Mon Sep 17 00:00:00 2001 From: Michael Vlach Date: Sat, 12 Oct 2024 13:19:30 +0200 Subject: [PATCH 5/5] update php api --- agdb_api/php/README.md | 4 +- agdb_api/php/docs/Api/AgdbApi.md | 20 +- agdb_api/php/lib/Api/AgdbApi.php | 754 ++++++------------ agdb_api/php/lib/ApiException.php | 2 +- agdb_api/php/lib/Configuration.php | 2 +- agdb_api/php/lib/HeaderSelector.php | 32 +- agdb_api/php/lib/Model/AdminStatus.php | 2 +- agdb_api/php/lib/Model/ChangePassword.php | 2 +- agdb_api/php/lib/Model/ClusterStatus.php | 2 +- agdb_api/php/lib/Model/Comparison.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf1.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf2.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf3.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf4.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf5.php | 2 +- agdb_api/php/lib/Model/ComparisonOneOf6.php | 2 +- agdb_api/php/lib/Model/CountComparison.php | 2 +- .../php/lib/Model/CountComparisonOneOf.php | 2 +- .../php/lib/Model/CountComparisonOneOf1.php | 2 +- .../php/lib/Model/CountComparisonOneOf2.php | 2 +- .../php/lib/Model/CountComparisonOneOf3.php | 2 +- .../php/lib/Model/CountComparisonOneOf4.php | 2 +- .../php/lib/Model/CountComparisonOneOf5.php | 2 +- agdb_api/php/lib/Model/DbElement.php | 2 +- agdb_api/php/lib/Model/DbKeyOrder.php | 2 +- agdb_api/php/lib/Model/DbKeyOrderOneOf.php | 2 +- agdb_api/php/lib/Model/DbKeyOrderOneOf1.php | 2 +- agdb_api/php/lib/Model/DbKeyValue.php | 2 +- agdb_api/php/lib/Model/DbResource.php | 2 +- agdb_api/php/lib/Model/DbType.php | 2 +- agdb_api/php/lib/Model/DbTypeParam.php | 2 +- agdb_api/php/lib/Model/DbUser.php | 2 +- agdb_api/php/lib/Model/DbUserRole.php | 2 +- agdb_api/php/lib/Model/DbUserRoleParam.php | 2 +- agdb_api/php/lib/Model/DbValue.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf1.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf2.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf3.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf4.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf5.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf6.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf7.php | 2 +- agdb_api/php/lib/Model/DbValueOneOf8.php | 2 +- agdb_api/php/lib/Model/InsertAliasesQuery.php | 2 +- agdb_api/php/lib/Model/InsertEdgesQuery.php | 2 +- agdb_api/php/lib/Model/InsertNodesQuery.php | 2 +- agdb_api/php/lib/Model/InsertValuesQuery.php | 2 +- agdb_api/php/lib/Model/ModelInterface.php | 2 +- agdb_api/php/lib/Model/QueryAudit.php | 2 +- agdb_api/php/lib/Model/QueryCondition.php | 2 +- agdb_api/php/lib/Model/QueryConditionData.php | 2 +- .../php/lib/Model/QueryConditionDataOneOf.php | 2 +- .../lib/Model/QueryConditionDataOneOf1.php | 2 +- .../lib/Model/QueryConditionDataOneOf2.php | 2 +- .../lib/Model/QueryConditionDataOneOf3.php | 2 +- .../lib/Model/QueryConditionDataOneOf4.php | 2 +- .../lib/Model/QueryConditionDataOneOf5.php | 2 +- .../QueryConditionDataOneOf5KeyValue.php | 2 +- .../lib/Model/QueryConditionDataOneOf6.php | 2 +- .../lib/Model/QueryConditionDataOneOf7.php | 2 +- .../php/lib/Model/QueryConditionLogic.php | 2 +- .../php/lib/Model/QueryConditionModifier.php | 2 +- agdb_api/php/lib/Model/QueryId.php | 2 +- agdb_api/php/lib/Model/QueryIdOneOf.php | 2 +- agdb_api/php/lib/Model/QueryIdOneOf1.php | 2 +- agdb_api/php/lib/Model/QueryIds.php | 2 +- agdb_api/php/lib/Model/QueryIdsOneOf.php | 2 +- agdb_api/php/lib/Model/QueryIdsOneOf1.php | 2 +- agdb_api/php/lib/Model/QueryResult.php | 2 +- agdb_api/php/lib/Model/QueryType.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf1.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf10.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf11.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf12.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf13.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf14.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf15.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf16.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf2.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf3.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf4.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf5.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf6.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf7.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf8.php | 2 +- agdb_api/php/lib/Model/QueryTypeOneOf9.php | 2 +- agdb_api/php/lib/Model/QueryValues.php | 2 +- agdb_api/php/lib/Model/QueryValuesOneOf.php | 2 +- agdb_api/php/lib/Model/QueryValuesOneOf1.php | 2 +- agdb_api/php/lib/Model/SearchQuery.php | 2 +- .../php/lib/Model/SearchQueryAlgorithm.php | 2 +- .../php/lib/Model/SelectEdgeCountQuery.php | 2 +- agdb_api/php/lib/Model/SelectValuesQuery.php | 2 +- agdb_api/php/lib/Model/ServerDatabase.php | 2 +- .../php/lib/Model/ServerDatabaseRename.php | 2 +- .../php/lib/Model/ServerDatabaseResource.php | 2 +- agdb_api/php/lib/Model/UserCredentials.php | 2 +- agdb_api/php/lib/Model/UserLogin.php | 2 +- agdb_api/php/lib/Model/UserStatus.php | 2 +- agdb_api/php/lib/ObjectSerializer.php | 6 +- 103 files changed, 380 insertions(+), 632 deletions(-) diff --git a/agdb_api/php/README.md b/agdb_api/php/README.md index e409d9043..99f842b88 100644 --- a/agdb_api/php/README.md +++ b/agdb_api/php/README.md @@ -61,7 +61,7 @@ $apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( ); $owner = 'owner_example'; // string | user name $db = 'db_example'; // string | db name -$db_type = new \Agnesoft\AgdbApi\Model\DbType(); // DbType +$db_type = new \Agnesoft\AgdbApi\Model\\Agnesoft\AgdbApi\Model\DbType(); // \Agnesoft\AgdbApi\Model\DbType try { $apiInstance->adminDbAdd($owner, $db, $db_type); @@ -243,5 +243,5 @@ This PHP package is automatically generated by the [OpenAPI Generator](https://o - API version: `0.9.0` - Package version: `0.7.2` - - Generator version: `7.8.0` + - Generator version: `7.9.0` - Build package: `org.openapitools.codegen.languages.PhpClientCodegen` diff --git a/agdb_api/php/docs/Api/AgdbApi.md b/agdb_api/php/docs/Api/AgdbApi.md index 0bfae9293..9bf246c15 100644 --- a/agdb_api/php/docs/Api/AgdbApi.md +++ b/agdb_api/php/docs/Api/AgdbApi.md @@ -74,7 +74,7 @@ $apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( ); $owner = 'owner_example'; // string | user name $db = 'db_example'; // string | db name -$db_type = new \Agnesoft\AgdbApi\Model\DbType(); // DbType +$db_type = new \Agnesoft\AgdbApi\Model\\Agnesoft\AgdbApi\Model\DbType(); // \Agnesoft\AgdbApi\Model\DbType try { $apiInstance->adminDbAdd($owner, $db, $db_type); @@ -89,7 +89,7 @@ try { | ------------- | ------------- | ------------- | ------------- | | **owner** | **string**| user name | | | **db** | **string**| db name | | -| **db_type** | [**DbType**](../Model/.md)| | | +| **db_type** | [**\Agnesoft\AgdbApi\Model\DbType**](../Model/.md)| | | ### Return type @@ -731,7 +731,7 @@ $apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( $owner = 'owner_example'; // string | db owner user name $db = 'db_example'; // string | db name $username = 'username_example'; // string | user name -$db_role = new \Agnesoft\AgdbApi\Model\DbUserRole(); // DbUserRole +$db_role = new \Agnesoft\AgdbApi\Model\\Agnesoft\AgdbApi\Model\DbUserRole(); // \Agnesoft\AgdbApi\Model\DbUserRole try { $apiInstance->adminDbUserAdd($owner, $db, $username, $db_role); @@ -747,7 +747,7 @@ try { | **owner** | **string**| db owner user name | | | **db** | **string**| db name | | | **username** | **string**| user name | | -| **db_role** | [**DbUserRole**](../Model/.md)| | | +| **db_role** | [**\Agnesoft\AgdbApi\Model\DbUserRole**](../Model/.md)| | | ### Return type @@ -1362,7 +1362,7 @@ $apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( ); $owner = 'owner_example'; // string | user name $db = 'db_example'; // string | db name -$db_type = new \Agnesoft\AgdbApi\Model\DbType(); // DbType +$db_type = new \Agnesoft\AgdbApi\Model\\Agnesoft\AgdbApi\Model\DbType(); // \Agnesoft\AgdbApi\Model\DbType try { $apiInstance->dbAdd($owner, $db, $db_type); @@ -1377,7 +1377,7 @@ try { | ------------- | ------------- | ------------- | ------------- | | **owner** | **string**| user name | | | **db** | **string**| db name | | -| **db_type** | [**DbType**](../Model/.md)| | | +| **db_type** | [**\Agnesoft\AgdbApi\Model\DbType**](../Model/.md)| | | ### Return type @@ -1542,7 +1542,7 @@ $apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( ); $owner = 'owner_example'; // string | user name $db = 'db_example'; // string | db name -$resource = new \Agnesoft\AgdbApi\Model\DbResource(); // DbResource +$resource = new \Agnesoft\AgdbApi\Model\\Agnesoft\AgdbApi\Model\DbResource(); // \Agnesoft\AgdbApi\Model\DbResource try { $result = $apiInstance->dbClear($owner, $db, $resource); @@ -1558,7 +1558,7 @@ try { | ------------- | ------------- | ------------- | ------------- | | **owner** | **string**| user name | | | **db** | **string**| db name | | -| **resource** | [**DbResource**](../Model/.md)| | | +| **resource** | [**\Agnesoft\AgdbApi\Model\DbResource**](../Model/.md)| | | ### Return type @@ -2081,7 +2081,7 @@ $apiInstance = new Agnesoft\AgdbApi\Api\AgdbApi( $owner = 'owner_example'; // string | db owner user name $db = 'db_example'; // string | db name $username = 'username_example'; // string | user name -$db_role = new \Agnesoft\AgdbApi\Model\DbUserRole(); // DbUserRole +$db_role = new \Agnesoft\AgdbApi\Model\\Agnesoft\AgdbApi\Model\DbUserRole(); // \Agnesoft\AgdbApi\Model\DbUserRole try { $apiInstance->dbUserAdd($owner, $db, $username, $db_role); @@ -2097,7 +2097,7 @@ try { | **owner** | **string**| db owner user name | | | **db** | **string**| db name | | | **username** | **string**| user name | | -| **db_role** | [**DbUserRole**](../Model/.md)| | | +| **db_role** | [**\Agnesoft\AgdbApi\Model\DbUserRole**](../Model/.md)| | | ### Return type diff --git a/agdb_api/php/lib/Api/AgdbApi.php b/agdb_api/php/lib/Api/AgdbApi.php index 1aa510709..171de8de9 100644 --- a/agdb_api/php/lib/Api/AgdbApi.php +++ b/agdb_api/php/lib/Api/AgdbApi.php @@ -16,7 +16,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** @@ -209,7 +209,7 @@ public function __construct( $hostIndex = 0 ) { $this->client = $client ?: new Client(); - $this->config = $config ?: new Configuration(); + $this->config = $config ?: Configuration::getDefaultConfiguration(); $this->headerSelector = $selector ?: new HeaderSelector(); $this->hostIndex = $hostIndex; } @@ -247,7 +247,7 @@ public function getConfig() * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -264,7 +264,7 @@ public function adminDbAdd($owner, $db, $db_type, string $contentType = self::co * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -297,18 +297,6 @@ public function adminDbAddWithHttpInfo($owner, $db, $db_type, string $contentTyp $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -324,7 +312,7 @@ public function adminDbAddWithHttpInfo($owner, $db, $db_type, string $contentTyp * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -345,7 +333,7 @@ function ($response) { * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -384,7 +372,7 @@ function ($exception) { * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -562,18 +550,6 @@ public function adminDbAuditWithHttpInfo($owner, $db, string $contentType = self $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -605,6 +581,19 @@ public function adminDbAuditWithHttpInfo($owner, $db, string $contentType = self ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\QueryAudit[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -884,18 +873,6 @@ public function adminDbBackupWithHttpInfo($owner, $db, string $contentType = sel $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -1131,18 +1108,6 @@ public function adminDbCopyWithHttpInfo($owner, $db, $new_name, string $contentT $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -1395,18 +1360,6 @@ public function adminDbDeleteWithHttpInfo($owner, $db, string $contentType = sel $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -1643,18 +1596,6 @@ public function adminDbExecWithHttpInfo($owner, $db, $query_type, string $conten $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -1686,6 +1627,19 @@ public function adminDbExecWithHttpInfo($owner, $db, $query_type, string $conten ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\QueryResult[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -1979,18 +1933,6 @@ public function adminDbListWithHttpInfo(string $contentType = self::contentTypes $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -2022,6 +1964,19 @@ public function adminDbListWithHttpInfo(string $contentType = self::contentTypes ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\ServerDatabase[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -2266,18 +2221,6 @@ public function adminDbOptimizeWithHttpInfo($owner, $db, string $contentType = s $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -2309,6 +2252,19 @@ public function adminDbOptimizeWithHttpInfo($owner, $db, string $contentType = s ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\ServerDatabase'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -2588,18 +2544,6 @@ public function adminDbRemoveWithHttpInfo($owner, $db, string $contentType = sel $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -2835,18 +2779,6 @@ public function adminDbRenameWithHttpInfo($owner, $db, $new_name, string $conten $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -3099,18 +3031,6 @@ public function adminDbRestoreWithHttpInfo($owner, $db, string $contentType = se $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -3297,7 +3217,7 @@ public function adminDbRestoreRequest($owner, $db, string $contentType = self::c * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbUserAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -3315,7 +3235,7 @@ public function adminDbUserAdd($owner, $db, $username, $db_role, string $content * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbUserAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -3348,18 +3268,6 @@ public function adminDbUserAddWithHttpInfo($owner, $db, $username, $db_role, str $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -3376,7 +3284,7 @@ public function adminDbUserAddWithHttpInfo($owner, $db, $username, $db_role, str * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbUserAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -3398,7 +3306,7 @@ function ($response) { * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbUserAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -3438,7 +3346,7 @@ function ($exception) { * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['adminDbUserAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -3631,18 +3539,6 @@ public function adminDbUserListWithHttpInfo($owner, $db, string $contentType = s $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -3674,6 +3570,19 @@ public function adminDbUserListWithHttpInfo($owner, $db, string $contentType = s ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\DbUser[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -3955,18 +3864,6 @@ public function adminDbUserRemoveWithHttpInfo($owner, $db, $username, string $co $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -4214,18 +4111,6 @@ public function adminShutdownWithHttpInfo(string $contentType = self::contentTyp $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -4420,18 +4305,6 @@ public function adminStatusWithHttpInfo(string $contentType = self::contentTypes $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -4463,6 +4336,19 @@ public function adminStatusWithHttpInfo(string $contentType = self::contentTypes ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\AdminStatus'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -4706,18 +4592,6 @@ public function adminUserAddWithHttpInfo($username, $user_credentials, string $c $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -4950,18 +4824,6 @@ public function adminUserChangePasswordWithHttpInfo($username, $user_credentials $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -5191,18 +5053,6 @@ public function adminUserListWithHttpInfo(string $contentType = self::contentTyp $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -5234,6 +5084,19 @@ public function adminUserListWithHttpInfo(string $contentType = self::contentTyp ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\UserStatus[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -5475,18 +5338,6 @@ public function adminUserLogoutWithHttpInfo($username, string $contentType = sel $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -5701,18 +5552,6 @@ public function adminUserRemoveWithHttpInfo($username, string $contentType = sel $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 204: @@ -5744,6 +5583,19 @@ public function adminUserRemoveWithHttpInfo($username, string $contentType = sel ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\UserStatus[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -6002,18 +5854,6 @@ public function clusterStatusWithHttpInfo(string $contentType = self::contentTyp $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -6045,6 +5885,19 @@ public function clusterStatusWithHttpInfo(string $contentType = self::contentTyp ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\ClusterStatus[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -6236,7 +6089,7 @@ public function clusterStatusRequest(string $contentType = self::contentTypes['c * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -6253,7 +6106,7 @@ public function dbAdd($owner, $db, $db_type, string $contentType = self::content * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -6286,18 +6139,6 @@ public function dbAddWithHttpInfo($owner, $db, $db_type, string $contentType = s $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -6313,7 +6154,7 @@ public function dbAddWithHttpInfo($owner, $db, $db_type, string $contentType = s * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -6334,7 +6175,7 @@ function ($response) { * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -6373,7 +6214,7 @@ function ($exception) { * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbType $db_type (required) + * @param \Agnesoft\AgdbApi\Model\DbType $db_type (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -6551,18 +6392,6 @@ public function dbAuditWithHttpInfo($owner, $db, string $contentType = self::con $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -6594,6 +6423,19 @@ public function dbAuditWithHttpInfo($owner, $db, string $contentType = self::con ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\QueryAudit[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -6873,18 +6715,6 @@ public function dbBackupWithHttpInfo($owner, $db, string $contentType = self::co $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -7070,7 +6900,7 @@ public function dbBackupRequest($owner, $db, string $contentType = self::content * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbResource $resource resource (required) + * @param \Agnesoft\AgdbApi\Model\DbResource $resource resource (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbClear'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -7088,7 +6918,7 @@ public function dbClear($owner, $db, $resource, string $contentType = self::cont * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbResource $resource (required) + * @param \Agnesoft\AgdbApi\Model\DbResource $resource (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbClear'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -7121,18 +6951,6 @@ public function dbClearWithHttpInfo($owner, $db, $resource, string $contentType $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 201: @@ -7164,6 +6982,19 @@ public function dbClearWithHttpInfo($owner, $db, $resource, string $contentType ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\ServerDatabase'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -7212,7 +7043,7 @@ public function dbClearWithHttpInfo($owner, $db, $resource, string $contentType * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbResource $resource (required) + * @param \Agnesoft\AgdbApi\Model\DbResource $resource (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbClear'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -7233,7 +7064,7 @@ function ($response) { * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbResource $resource (required) + * @param \Agnesoft\AgdbApi\Model\DbResource $resource (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbClear'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -7285,7 +7116,7 @@ function ($exception) { * * @param string $owner user name (required) * @param string $db db name (required) - * @param DbResource $resource (required) + * @param \Agnesoft\AgdbApi\Model\DbResource $resource (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbClear'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -7464,18 +7295,6 @@ public function dbCopyWithHttpInfo($owner, $db, $new_name, string $contentType = $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -7728,18 +7547,6 @@ public function dbDeleteWithHttpInfo($owner, $db, string $contentType = self::co $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -7976,18 +7783,6 @@ public function dbExecWithHttpInfo($owner, $db, $query_type, string $contentType $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -8019,6 +7814,19 @@ public function dbExecWithHttpInfo($owner, $db, $query_type, string $contentType ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\QueryResult[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -8312,18 +8120,6 @@ public function dbListWithHttpInfo(string $contentType = self::contentTypes['dbL $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -8355,6 +8151,19 @@ public function dbListWithHttpInfo(string $contentType = self::contentTypes['dbL ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\ServerDatabase[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -8599,18 +8408,6 @@ public function dbOptimizeWithHttpInfo($owner, $db, string $contentType = self:: $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -8642,6 +8439,19 @@ public function dbOptimizeWithHttpInfo($owner, $db, string $contentType = self:: ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\ServerDatabase'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -8921,18 +8731,6 @@ public function dbRemoveWithHttpInfo($owner, $db, string $contentType = self::co $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -9168,18 +8966,6 @@ public function dbRenameWithHttpInfo($owner, $db, $new_name, string $contentType $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -9432,18 +9218,6 @@ public function dbRestoreWithHttpInfo($owner, $db, string $contentType = self::c $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -9630,7 +9404,7 @@ public function dbRestoreRequest($owner, $db, string $contentType = self::conten * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbUserAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -9648,7 +9422,7 @@ public function dbUserAdd($owner, $db, $username, $db_role, string $contentType * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbUserAdd'] to see the possible values for this operation * * @throws \Agnesoft\AgdbApi\ApiException on non-2xx response or if the response body is not in the expected format @@ -9681,18 +9455,6 @@ public function dbUserAddWithHttpInfo($owner, $db, $username, $db_role, string $ $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -9709,7 +9471,7 @@ public function dbUserAddWithHttpInfo($owner, $db, $username, $db_role, string $ * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbUserAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -9731,7 +9493,7 @@ function ($response) { * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbUserAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -9771,7 +9533,7 @@ function ($exception) { * @param string $owner db owner user name (required) * @param string $db db name (required) * @param string $username user name (required) - * @param DbUserRole $db_role (required) + * @param \Agnesoft\AgdbApi\Model\DbUserRole $db_role (required) * @param string $contentType The value for the Content-Type header. Check self::contentTypes['dbUserAdd'] to see the possible values for this operation * * @throws \InvalidArgumentException @@ -9964,18 +9726,6 @@ public function dbUserListWithHttpInfo($owner, $db, string $contentType = self:: $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -10007,6 +9757,19 @@ public function dbUserListWithHttpInfo($owner, $db, string $contentType = self:: ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = '\Agnesoft\AgdbApi\Model\DbUser[]'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -10288,18 +10051,6 @@ public function dbUserRemoveWithHttpInfo($owner, $db, $username, string $content $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -10547,18 +10298,6 @@ public function statusWithHttpInfo(string $contentType = self::contentTypes['sta $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -10750,18 +10489,6 @@ public function userChangePasswordWithHttpInfo($change_password, string $content $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; @@ -10975,18 +10702,6 @@ public function userLoginWithHttpInfo($user_login, string $contentType = self::c $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } switch($statusCode) { case 200: @@ -11018,6 +10733,19 @@ public function userLoginWithHttpInfo($user_login, string $contentType = self::c ]; } + if ($statusCode < 200 || $statusCode > 299) { + throw new ApiException( + sprintf( + '[%d] Error connecting to the API (%s)', + $statusCode, + (string) $request->getUri() + ), + $statusCode, + $response->getHeaders(), + (string) $response->getBody() + ); + } + $returnType = 'string'; if ($returnType === '\SplFileObject') { $content = $response->getBody(); //stream goes to serializer @@ -11270,18 +10998,6 @@ public function userLogoutWithHttpInfo(string $contentType = self::contentTypes[ $statusCode = $response->getStatusCode(); - if ($statusCode < 200 || $statusCode > 299) { - throw new ApiException( - sprintf( - '[%d] Error connecting to the API (%s)', - $statusCode, - (string) $request->getUri() - ), - $statusCode, - $response->getHeaders(), - (string) $response->getBody() - ); - } return [null, $statusCode, $response->getHeaders()]; diff --git a/agdb_api/php/lib/ApiException.php b/agdb_api/php/lib/ApiException.php index b50779b5e..8ffe5c569 100644 --- a/agdb_api/php/lib/ApiException.php +++ b/agdb_api/php/lib/ApiException.php @@ -16,7 +16,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Configuration.php b/agdb_api/php/lib/Configuration.php index 69a4f8f35..90159aae1 100644 --- a/agdb_api/php/lib/Configuration.php +++ b/agdb_api/php/lib/Configuration.php @@ -16,7 +16,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/HeaderSelector.php b/agdb_api/php/lib/HeaderSelector.php index 132873258..58c150bc8 100644 --- a/agdb_api/php/lib/HeaderSelector.php +++ b/agdb_api/php/lib/HeaderSelector.php @@ -16,7 +16,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** @@ -85,7 +85,7 @@ private function selectAcceptHeader(array $accept): ?string } # If none of the available Accept headers is of type "json", then just use all them - $headersWithJson = preg_grep('~(?i)^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$~', $accept); + $headersWithJson = $this->selectJsonMimeList($accept); if (count($headersWithJson) === 0) { return implode(',', $accept); } @@ -95,6 +95,34 @@ private function selectAcceptHeader(array $accept): ?string return $this->getAcceptHeaderWithAdjustedWeight($accept, $headersWithJson); } + /** + * Detects whether a string contains a valid JSON mime type + * + * @param string $searchString + * @return bool + */ + public function isJsonMime(string $searchString): bool + { + return preg_match('~^application/(json|[\w!#$&.+-^_]+\+json)\s*(;|$)~', $searchString) === 1; + } + + /** + * Select all items from a list containing a JSON mime type + * + * @param array $mimeList + * @return array + */ + private function selectJsonMimeList(array $mimeList): array { + $jsonMimeList = []; + foreach ($mimeList as $mime) { + if($this->isJsonMime($mime)) { + $jsonMimeList[] = $mime; + } + } + return $jsonMimeList; + } + + /** * Create an Accept header string from the given "Accept" headers array, recalculating all weights * diff --git a/agdb_api/php/lib/Model/AdminStatus.php b/agdb_api/php/lib/Model/AdminStatus.php index 919a461fc..7ef38ab97 100644 --- a/agdb_api/php/lib/Model/AdminStatus.php +++ b/agdb_api/php/lib/Model/AdminStatus.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ChangePassword.php b/agdb_api/php/lib/Model/ChangePassword.php index cfa1a427e..f65cefbe4 100644 --- a/agdb_api/php/lib/Model/ChangePassword.php +++ b/agdb_api/php/lib/Model/ChangePassword.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ClusterStatus.php b/agdb_api/php/lib/Model/ClusterStatus.php index fcb33c862..f1e4e2452 100644 --- a/agdb_api/php/lib/Model/ClusterStatus.php +++ b/agdb_api/php/lib/Model/ClusterStatus.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/Comparison.php b/agdb_api/php/lib/Model/Comparison.php index 95094d4fe..05724b3ea 100644 --- a/agdb_api/php/lib/Model/Comparison.php +++ b/agdb_api/php/lib/Model/Comparison.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf.php b/agdb_api/php/lib/Model/ComparisonOneOf.php index f1e1fd5c0..f69e93cf0 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf1.php b/agdb_api/php/lib/Model/ComparisonOneOf1.php index 835d16e76..a93265e05 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf1.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf2.php b/agdb_api/php/lib/Model/ComparisonOneOf2.php index b64c4ed21..d3244f997 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf2.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf2.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf3.php b/agdb_api/php/lib/Model/ComparisonOneOf3.php index 3b149e8de..bf15ebffb 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf3.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf3.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf4.php b/agdb_api/php/lib/Model/ComparisonOneOf4.php index 350d6a3cd..603bcf0d6 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf4.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf4.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf5.php b/agdb_api/php/lib/Model/ComparisonOneOf5.php index 4ee0eb8f4..3016d12c3 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf5.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf5.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ComparisonOneOf6.php b/agdb_api/php/lib/Model/ComparisonOneOf6.php index 08a4ab601..c77c1b652 100644 --- a/agdb_api/php/lib/Model/ComparisonOneOf6.php +++ b/agdb_api/php/lib/Model/ComparisonOneOf6.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparison.php b/agdb_api/php/lib/Model/CountComparison.php index fab127cc4..693e61aa9 100644 --- a/agdb_api/php/lib/Model/CountComparison.php +++ b/agdb_api/php/lib/Model/CountComparison.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparisonOneOf.php b/agdb_api/php/lib/Model/CountComparisonOneOf.php index ca1edf83b..27d85cd47 100644 --- a/agdb_api/php/lib/Model/CountComparisonOneOf.php +++ b/agdb_api/php/lib/Model/CountComparisonOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparisonOneOf1.php b/agdb_api/php/lib/Model/CountComparisonOneOf1.php index d88d53007..00c354138 100644 --- a/agdb_api/php/lib/Model/CountComparisonOneOf1.php +++ b/agdb_api/php/lib/Model/CountComparisonOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparisonOneOf2.php b/agdb_api/php/lib/Model/CountComparisonOneOf2.php index a488e61de..79bdb43b2 100644 --- a/agdb_api/php/lib/Model/CountComparisonOneOf2.php +++ b/agdb_api/php/lib/Model/CountComparisonOneOf2.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparisonOneOf3.php b/agdb_api/php/lib/Model/CountComparisonOneOf3.php index e841416f1..e22d85a35 100644 --- a/agdb_api/php/lib/Model/CountComparisonOneOf3.php +++ b/agdb_api/php/lib/Model/CountComparisonOneOf3.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparisonOneOf4.php b/agdb_api/php/lib/Model/CountComparisonOneOf4.php index 7bf1510b9..6a8f55c35 100644 --- a/agdb_api/php/lib/Model/CountComparisonOneOf4.php +++ b/agdb_api/php/lib/Model/CountComparisonOneOf4.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/CountComparisonOneOf5.php b/agdb_api/php/lib/Model/CountComparisonOneOf5.php index fc28dd075..10823d9ab 100644 --- a/agdb_api/php/lib/Model/CountComparisonOneOf5.php +++ b/agdb_api/php/lib/Model/CountComparisonOneOf5.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbElement.php b/agdb_api/php/lib/Model/DbElement.php index 802b828d2..4fd1c9398 100644 --- a/agdb_api/php/lib/Model/DbElement.php +++ b/agdb_api/php/lib/Model/DbElement.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbKeyOrder.php b/agdb_api/php/lib/Model/DbKeyOrder.php index 8de88c9b1..c5162778d 100644 --- a/agdb_api/php/lib/Model/DbKeyOrder.php +++ b/agdb_api/php/lib/Model/DbKeyOrder.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbKeyOrderOneOf.php b/agdb_api/php/lib/Model/DbKeyOrderOneOf.php index e77becbab..80cc3aba9 100644 --- a/agdb_api/php/lib/Model/DbKeyOrderOneOf.php +++ b/agdb_api/php/lib/Model/DbKeyOrderOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbKeyOrderOneOf1.php b/agdb_api/php/lib/Model/DbKeyOrderOneOf1.php index d457c61e2..f9d5968fe 100644 --- a/agdb_api/php/lib/Model/DbKeyOrderOneOf1.php +++ b/agdb_api/php/lib/Model/DbKeyOrderOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbKeyValue.php b/agdb_api/php/lib/Model/DbKeyValue.php index 84c52c21f..ec89ced65 100644 --- a/agdb_api/php/lib/Model/DbKeyValue.php +++ b/agdb_api/php/lib/Model/DbKeyValue.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbResource.php b/agdb_api/php/lib/Model/DbResource.php index 8b6cdddff..792ad6e9a 100644 --- a/agdb_api/php/lib/Model/DbResource.php +++ b/agdb_api/php/lib/Model/DbResource.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbType.php b/agdb_api/php/lib/Model/DbType.php index 9dec07e52..bb489e10f 100644 --- a/agdb_api/php/lib/Model/DbType.php +++ b/agdb_api/php/lib/Model/DbType.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbTypeParam.php b/agdb_api/php/lib/Model/DbTypeParam.php index 2e9916a94..1b89cb311 100644 --- a/agdb_api/php/lib/Model/DbTypeParam.php +++ b/agdb_api/php/lib/Model/DbTypeParam.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbUser.php b/agdb_api/php/lib/Model/DbUser.php index 20d9ba885..c68a7ff9b 100644 --- a/agdb_api/php/lib/Model/DbUser.php +++ b/agdb_api/php/lib/Model/DbUser.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbUserRole.php b/agdb_api/php/lib/Model/DbUserRole.php index 18afffc87..7a7d11cb2 100644 --- a/agdb_api/php/lib/Model/DbUserRole.php +++ b/agdb_api/php/lib/Model/DbUserRole.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbUserRoleParam.php b/agdb_api/php/lib/Model/DbUserRoleParam.php index 3988c3a20..4de73a26a 100644 --- a/agdb_api/php/lib/Model/DbUserRoleParam.php +++ b/agdb_api/php/lib/Model/DbUserRoleParam.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValue.php b/agdb_api/php/lib/Model/DbValue.php index d22f383a5..333098234 100644 --- a/agdb_api/php/lib/Model/DbValue.php +++ b/agdb_api/php/lib/Model/DbValue.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf.php b/agdb_api/php/lib/Model/DbValueOneOf.php index 190bf4890..ee1b8e071 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf.php +++ b/agdb_api/php/lib/Model/DbValueOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf1.php b/agdb_api/php/lib/Model/DbValueOneOf1.php index 2470f5bdf..558d1afa8 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf1.php +++ b/agdb_api/php/lib/Model/DbValueOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf2.php b/agdb_api/php/lib/Model/DbValueOneOf2.php index 825a1bd38..98b146ef9 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf2.php +++ b/agdb_api/php/lib/Model/DbValueOneOf2.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf3.php b/agdb_api/php/lib/Model/DbValueOneOf3.php index 2d7e3b4d8..491e3b158 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf3.php +++ b/agdb_api/php/lib/Model/DbValueOneOf3.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf4.php b/agdb_api/php/lib/Model/DbValueOneOf4.php index fb1ffef57..c751a11d9 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf4.php +++ b/agdb_api/php/lib/Model/DbValueOneOf4.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf5.php b/agdb_api/php/lib/Model/DbValueOneOf5.php index ebf17554a..b0767298a 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf5.php +++ b/agdb_api/php/lib/Model/DbValueOneOf5.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf6.php b/agdb_api/php/lib/Model/DbValueOneOf6.php index 2d2a2531b..e573b03d1 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf6.php +++ b/agdb_api/php/lib/Model/DbValueOneOf6.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf7.php b/agdb_api/php/lib/Model/DbValueOneOf7.php index 6ed3d81fb..535bfc98d 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf7.php +++ b/agdb_api/php/lib/Model/DbValueOneOf7.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/DbValueOneOf8.php b/agdb_api/php/lib/Model/DbValueOneOf8.php index b4a474685..cae6d5207 100644 --- a/agdb_api/php/lib/Model/DbValueOneOf8.php +++ b/agdb_api/php/lib/Model/DbValueOneOf8.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/InsertAliasesQuery.php b/agdb_api/php/lib/Model/InsertAliasesQuery.php index 7e71182f8..d8635d1fa 100644 --- a/agdb_api/php/lib/Model/InsertAliasesQuery.php +++ b/agdb_api/php/lib/Model/InsertAliasesQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/InsertEdgesQuery.php b/agdb_api/php/lib/Model/InsertEdgesQuery.php index 6c2fe0c74..d6af1faca 100644 --- a/agdb_api/php/lib/Model/InsertEdgesQuery.php +++ b/agdb_api/php/lib/Model/InsertEdgesQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/InsertNodesQuery.php b/agdb_api/php/lib/Model/InsertNodesQuery.php index 9e38429f3..0fdfd1945 100644 --- a/agdb_api/php/lib/Model/InsertNodesQuery.php +++ b/agdb_api/php/lib/Model/InsertNodesQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/InsertValuesQuery.php b/agdb_api/php/lib/Model/InsertValuesQuery.php index 5d9aec809..ce7a7b91c 100644 --- a/agdb_api/php/lib/Model/InsertValuesQuery.php +++ b/agdb_api/php/lib/Model/InsertValuesQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ModelInterface.php b/agdb_api/php/lib/Model/ModelInterface.php index ae8cef727..71634bb68 100644 --- a/agdb_api/php/lib/Model/ModelInterface.php +++ b/agdb_api/php/lib/Model/ModelInterface.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryAudit.php b/agdb_api/php/lib/Model/QueryAudit.php index f20a75b91..7dc7c6e66 100644 --- a/agdb_api/php/lib/Model/QueryAudit.php +++ b/agdb_api/php/lib/Model/QueryAudit.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryCondition.php b/agdb_api/php/lib/Model/QueryCondition.php index ffcdc38c8..0382a555c 100644 --- a/agdb_api/php/lib/Model/QueryCondition.php +++ b/agdb_api/php/lib/Model/QueryCondition.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionData.php b/agdb_api/php/lib/Model/QueryConditionData.php index 8239cf49c..eb4dc529a 100644 --- a/agdb_api/php/lib/Model/QueryConditionData.php +++ b/agdb_api/php/lib/Model/QueryConditionData.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf.php index e4ddcbe76..6996a107c 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf1.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf1.php index 13c8660cc..2d28cbb4e 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf1.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf2.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf2.php index 02ad47c62..7a59e9263 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf2.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf2.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf3.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf3.php index 44866b1aa..33fa4b15a 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf3.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf3.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf4.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf4.php index 637172754..fd90506b5 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf4.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf4.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf5.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf5.php index 021e63737..976aee04b 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf5.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf5.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf5KeyValue.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf5KeyValue.php index 0a2073910..b28173ad3 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf5KeyValue.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf5KeyValue.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf6.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf6.php index 5a409570a..cb7e28d3a 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf6.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf6.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionDataOneOf7.php b/agdb_api/php/lib/Model/QueryConditionDataOneOf7.php index 6b4142536..666d0c20f 100644 --- a/agdb_api/php/lib/Model/QueryConditionDataOneOf7.php +++ b/agdb_api/php/lib/Model/QueryConditionDataOneOf7.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionLogic.php b/agdb_api/php/lib/Model/QueryConditionLogic.php index 47c29a7e5..a172e4de6 100644 --- a/agdb_api/php/lib/Model/QueryConditionLogic.php +++ b/agdb_api/php/lib/Model/QueryConditionLogic.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryConditionModifier.php b/agdb_api/php/lib/Model/QueryConditionModifier.php index e4ab65212..a32f7cb2f 100644 --- a/agdb_api/php/lib/Model/QueryConditionModifier.php +++ b/agdb_api/php/lib/Model/QueryConditionModifier.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryId.php b/agdb_api/php/lib/Model/QueryId.php index 06d3e4fa2..25154f34c 100644 --- a/agdb_api/php/lib/Model/QueryId.php +++ b/agdb_api/php/lib/Model/QueryId.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryIdOneOf.php b/agdb_api/php/lib/Model/QueryIdOneOf.php index ebfb8c98e..d56455a50 100644 --- a/agdb_api/php/lib/Model/QueryIdOneOf.php +++ b/agdb_api/php/lib/Model/QueryIdOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryIdOneOf1.php b/agdb_api/php/lib/Model/QueryIdOneOf1.php index 5d2a1cc2e..e5f2e20cb 100644 --- a/agdb_api/php/lib/Model/QueryIdOneOf1.php +++ b/agdb_api/php/lib/Model/QueryIdOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryIds.php b/agdb_api/php/lib/Model/QueryIds.php index c59815245..634a733cc 100644 --- a/agdb_api/php/lib/Model/QueryIds.php +++ b/agdb_api/php/lib/Model/QueryIds.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryIdsOneOf.php b/agdb_api/php/lib/Model/QueryIdsOneOf.php index 7231d108e..19555f361 100644 --- a/agdb_api/php/lib/Model/QueryIdsOneOf.php +++ b/agdb_api/php/lib/Model/QueryIdsOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryIdsOneOf1.php b/agdb_api/php/lib/Model/QueryIdsOneOf1.php index 615a6fb7d..b99d3cb91 100644 --- a/agdb_api/php/lib/Model/QueryIdsOneOf1.php +++ b/agdb_api/php/lib/Model/QueryIdsOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryResult.php b/agdb_api/php/lib/Model/QueryResult.php index ca4670cda..c98607950 100644 --- a/agdb_api/php/lib/Model/QueryResult.php +++ b/agdb_api/php/lib/Model/QueryResult.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryType.php b/agdb_api/php/lib/Model/QueryType.php index 56ea0cb33..4cec7bf69 100644 --- a/agdb_api/php/lib/Model/QueryType.php +++ b/agdb_api/php/lib/Model/QueryType.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf.php b/agdb_api/php/lib/Model/QueryTypeOneOf.php index 289139526..4e930c3d0 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf1.php b/agdb_api/php/lib/Model/QueryTypeOneOf1.php index f331b582c..d177f9f9c 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf1.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf10.php b/agdb_api/php/lib/Model/QueryTypeOneOf10.php index 92b83b2d7..ba3f174f1 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf10.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf10.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf11.php b/agdb_api/php/lib/Model/QueryTypeOneOf11.php index 7593daef3..d88af8d10 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf11.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf11.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf12.php b/agdb_api/php/lib/Model/QueryTypeOneOf12.php index 2a145b696..4cf1abe7e 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf12.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf12.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf13.php b/agdb_api/php/lib/Model/QueryTypeOneOf13.php index 12c92c804..cc6bafa68 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf13.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf13.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf14.php b/agdb_api/php/lib/Model/QueryTypeOneOf14.php index d1e048d3b..f8c74d19e 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf14.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf14.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf15.php b/agdb_api/php/lib/Model/QueryTypeOneOf15.php index e2820b8d4..6b0eaa304 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf15.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf15.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf16.php b/agdb_api/php/lib/Model/QueryTypeOneOf16.php index 23022a01e..9b7cf1910 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf16.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf16.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf2.php b/agdb_api/php/lib/Model/QueryTypeOneOf2.php index 5e2a19e71..835a69678 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf2.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf2.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf3.php b/agdb_api/php/lib/Model/QueryTypeOneOf3.php index c563a3704..8a9fdacb0 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf3.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf3.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf4.php b/agdb_api/php/lib/Model/QueryTypeOneOf4.php index 717db6c23..2da174081 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf4.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf4.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf5.php b/agdb_api/php/lib/Model/QueryTypeOneOf5.php index 68c3d6ef8..216897a92 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf5.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf5.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf6.php b/agdb_api/php/lib/Model/QueryTypeOneOf6.php index 70190e4fd..fdff1d966 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf6.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf6.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf7.php b/agdb_api/php/lib/Model/QueryTypeOneOf7.php index 5f6b7c709..22324bebe 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf7.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf7.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf8.php b/agdb_api/php/lib/Model/QueryTypeOneOf8.php index 2211da429..f17ce4357 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf8.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf8.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryTypeOneOf9.php b/agdb_api/php/lib/Model/QueryTypeOneOf9.php index 0efa058b9..a857e7e64 100644 --- a/agdb_api/php/lib/Model/QueryTypeOneOf9.php +++ b/agdb_api/php/lib/Model/QueryTypeOneOf9.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryValues.php b/agdb_api/php/lib/Model/QueryValues.php index 7eb47cd25..1685e3b2b 100644 --- a/agdb_api/php/lib/Model/QueryValues.php +++ b/agdb_api/php/lib/Model/QueryValues.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryValuesOneOf.php b/agdb_api/php/lib/Model/QueryValuesOneOf.php index ffe957941..d00673d70 100644 --- a/agdb_api/php/lib/Model/QueryValuesOneOf.php +++ b/agdb_api/php/lib/Model/QueryValuesOneOf.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/QueryValuesOneOf1.php b/agdb_api/php/lib/Model/QueryValuesOneOf1.php index 8e102bb9b..8ef506dfd 100644 --- a/agdb_api/php/lib/Model/QueryValuesOneOf1.php +++ b/agdb_api/php/lib/Model/QueryValuesOneOf1.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/SearchQuery.php b/agdb_api/php/lib/Model/SearchQuery.php index ed99a85e6..ed1665488 100644 --- a/agdb_api/php/lib/Model/SearchQuery.php +++ b/agdb_api/php/lib/Model/SearchQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/SearchQueryAlgorithm.php b/agdb_api/php/lib/Model/SearchQueryAlgorithm.php index 9ad263029..3813eda9e 100644 --- a/agdb_api/php/lib/Model/SearchQueryAlgorithm.php +++ b/agdb_api/php/lib/Model/SearchQueryAlgorithm.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/SelectEdgeCountQuery.php b/agdb_api/php/lib/Model/SelectEdgeCountQuery.php index 8d8e27455..a6cfc01f3 100644 --- a/agdb_api/php/lib/Model/SelectEdgeCountQuery.php +++ b/agdb_api/php/lib/Model/SelectEdgeCountQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/SelectValuesQuery.php b/agdb_api/php/lib/Model/SelectValuesQuery.php index 56859b9e2..39472ac38 100644 --- a/agdb_api/php/lib/Model/SelectValuesQuery.php +++ b/agdb_api/php/lib/Model/SelectValuesQuery.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ServerDatabase.php b/agdb_api/php/lib/Model/ServerDatabase.php index 588de2e51..5403fa40e 100644 --- a/agdb_api/php/lib/Model/ServerDatabase.php +++ b/agdb_api/php/lib/Model/ServerDatabase.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ServerDatabaseRename.php b/agdb_api/php/lib/Model/ServerDatabaseRename.php index 5dc4940f9..b9ba0c6a8 100644 --- a/agdb_api/php/lib/Model/ServerDatabaseRename.php +++ b/agdb_api/php/lib/Model/ServerDatabaseRename.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/ServerDatabaseResource.php b/agdb_api/php/lib/Model/ServerDatabaseResource.php index 3caa9147d..513762298 100644 --- a/agdb_api/php/lib/Model/ServerDatabaseResource.php +++ b/agdb_api/php/lib/Model/ServerDatabaseResource.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/UserCredentials.php b/agdb_api/php/lib/Model/UserCredentials.php index ba91a2941..e901941f8 100644 --- a/agdb_api/php/lib/Model/UserCredentials.php +++ b/agdb_api/php/lib/Model/UserCredentials.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/UserLogin.php b/agdb_api/php/lib/Model/UserLogin.php index 8a16b060a..a20d47794 100644 --- a/agdb_api/php/lib/Model/UserLogin.php +++ b/agdb_api/php/lib/Model/UserLogin.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/Model/UserStatus.php b/agdb_api/php/lib/Model/UserStatus.php index da7f42925..ad67d1e19 100644 --- a/agdb_api/php/lib/Model/UserStatus.php +++ b/agdb_api/php/lib/Model/UserStatus.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** diff --git a/agdb_api/php/lib/ObjectSerializer.php b/agdb_api/php/lib/ObjectSerializer.php index 0803baf81..8c1085975 100644 --- a/agdb_api/php/lib/ObjectSerializer.php +++ b/agdb_api/php/lib/ObjectSerializer.php @@ -17,7 +17,7 @@ * * The version of the OpenAPI document: 0.9.0 * Generated by: https://openapi-generator.tech - * Generator version: 7.8.0 + * Generator version: 7.9.0 */ /** @@ -194,6 +194,10 @@ private static function isEmptyValue($value, string $openApiType): bool case 'boolean': return !in_array($value, [false, 0], true); + # For string values, '' is considered empty. + case 'string': + return $value === ''; + # For all the other types, any value at this point can be considered empty. default: return true;