Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update server-api.json to Build 1679 #237

Merged
merged 2 commits into from
Sep 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ansys-grantami-serverapi-openapi/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "ansys-grantami-serverapi-openapi"
description = "Autogenerated client library for the Granta MI Server API."
version = "4.0.0.dev291"
version = "4.0.0.dev293"
license = "MIT"
authors = ["ANSYS, Inc. <[email protected]>"]
maintainers = ["ANSYS, Inc. <[email protected]>"]
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
from .schema___profile_tables_api import SchemaProfileTablesApi
from .schema___profiles_api import SchemaProfilesApi
from .schema___record_link_groups_api import SchemaRecordLinkGroupsApi
from .schema___replacement_strings_api import SchemaReplacementStringsApi
from .schema___standard_names_api import SchemaStandardNamesApi
from .schema___subsets_api import SchemaSubsetsApi
from .schema___tables_api import SchemaTablesApi
Expand Down Expand Up @@ -102,6 +103,7 @@
"SchemaProfileTablesApi",
"SchemaProfilesApi",
"SchemaRecordLinkGroupsApi",
"SchemaReplacementStringsApi",
"SchemaStandardNamesApi",
"SchemaSubsetsApi",
"SchemaTablesApi",
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -185,3 +185,64 @@ def _ensure_user_license_available_with_http_info(self, **kwargs: Any) -> Any:
collection_formats=collection_formats,
response_type_map=response_type_map,
)

def get_server_license(self) -> "GrantaMIEnabledLicensesInfo":
"""Get info on which server licenses are enabled, and the license expiry date.

This method makes a synchronous HTTP request.

Returns
-------
GrantaMIEnabledLicensesInfo
"""
data = self._get_server_license_with_http_info(_return_http_data_only=True)
return data # type: ignore[no-any-return]

def _get_server_license_with_http_info(self, **kwargs: Any) -> Any:
all_params = ["_return_http_data_only", "_preload_content", "_request_timeout"]

params = locals()
for key, val in params["kwargs"].items():
if key not in all_params:
raise TypeError(
f"Got an unexpected keyword argument '{key}' to method get_server_license"
)
params[key] = val
del params["kwargs"]

collection_formats: Dict[str, Any] = {}

path_params: Dict[str, Any] = {}

query_params: List[Any] = []

header_params: Dict[str, Any] = {}

form_params: List[Any] = []
local_var_files: Dict[str, Any] = {}

body_params = None
# HTTP header 'Accept'
header_params["Accept"] = self.api_client.select_header_accept(
["text/plain", "application/json", "text/json"]
)

response_type_map: Dict[int, Optional[str]] = {
200: "GrantaMIEnabledLicensesInfo",
}

return self.api_client.call_api(
"/v1alpha/license/server-licenses",
"GET",
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
_return_http_data_only=params.get("_return_http_data_only"),
_preload_content=params.get("_preload_content", True),
_request_timeout=params.get("_request_timeout"),
collection_formats=collection_formats,
response_type_map=response_type_map,
)
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,7 @@ def _unsubscribe_with_http_info(self, list_identifier: "str", **kwargs: Any) ->
400: None,
403: None,
404: None,
422: None,
}

return self.api_client.call_api(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,7 @@ def update_database(
database_key: str
body: GsaUpdateDatabase
allow_reload: bool
This must be set to true if any of the following properties are patched: DatabaseKey, DataSource, UseIntegratedSecurity, SqlUserName, SqlPassword, InitialCatalog, Language, Guid. The database will reload after the changes have been applied.

Returns
-------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def create_discrete_value(
discrete_type_guid: "str",
body: "Optional[GsaDiscreteValuesCreateDiscreteValue]" = None,
) -> "Union[GsaDiscreteValuesDiscreteValue, None]":
"""Create new discrete value. If it's ordered, it will be added at the end.
"""Create new discrete value. It will be added at the end.

This method makes a synchronous HTTP request.

Expand Down Expand Up @@ -463,7 +463,7 @@ def _get_discrete_value_with_http_info(
def get_discrete_values(
self, *, database_key: "str", discrete_type_guid: "str"
) -> "Union[GsaDiscreteValuesDiscreteValuesInfo, None]":
"""Gets all discrete values for a given discreteType. If discreteType is ordered, then discreteValues will be return in order, otherwise order is not deterministic.
"""Gets all discrete values for a given discreteType, returned in order.

This method makes a synchronous HTTP request.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ def _applications_with_http_info(
}

return self.api_client.call_api(
"/v1alpha/databases/{database-key}/tables/{table-guid}/layouts/:applications",
"/v1alpha/databases/{database-key}/tables/{table-guid}/layouts:applications",
"GET",
path_params,
query_params,
Expand Down Expand Up @@ -485,6 +485,7 @@ def get_layouts(
table_guid: "str",
mode: "Optional[str]" = None,
x_ansys_vc_mode: "Optional[str]" = None,
application: "Optional[str]" = None,
) -> "Union[GsaLayoutsInfo, None]":
"""Get all layouts for table

Expand All @@ -498,13 +499,20 @@ def get_layouts(
The version control mode. If not provided, defaults to write mode if the user is allowed to see that. Can also be set in the header.
x_ansys_vc_mode: str
The version control mode. If not provided, defaults to write mode if the user is allowed to see that. Can also be set in the query string.
application: str
Optionally filter by application that the layout is applicable to.

Returns
-------
Union[GsaLayoutsInfo, None]
"""
data = self._get_layouts_with_http_info(
database_key, table_guid, mode, x_ansys_vc_mode, _return_http_data_only=True
database_key,
table_guid,
mode,
x_ansys_vc_mode,
application,
_return_http_data_only=True,
)
return data # type: ignore[no-any-return]

Expand All @@ -514,13 +522,15 @@ def _get_layouts_with_http_info(
table_guid: "str",
mode: "Optional[str]" = None,
x_ansys_vc_mode: "Optional[str]" = None,
application: "Optional[str]" = None,
**kwargs: Any,
) -> Any:
all_params = [
"database_key",
"table_guid",
"mode",
"x_ansys_vc_mode",
"application",
"_return_http_data_only",
"_preload_content",
"_request_timeout",
Expand Down Expand Up @@ -554,6 +564,8 @@ def _get_layouts_with_http_info(
query_params: List[Any] = []
if "mode" in params and mode is not None:
query_params.append(("mode", params["mode"]))
if "application" in params and application is not None:
query_params.append(("application", params["application"]))

header_params: Dict[str, Any] = {}
if "x_ansys_vc_mode" in params and x_ansys_vc_mode is not None:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ def get_record_link_groups(
mode: "Optional[str]" = None,
x_ansys_vc_mode: "Optional[str]" = None,
) -> "Union[GsaRecordLinkGroupsInfo, None]":
"""Get all record link groups
"""Get all record link groups pointing from this table.

This method makes a synchronous HTTP request.

Expand Down
Loading