Skip to content
Open
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
6 changes: 3 additions & 3 deletions .generation/config.ini
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
[input]
backendTag = pro-nightly-2024-11-09
backendTag = pro-nightly-2024-11-21

[general]
githubUrl = https://github.com/geo-engine/openapi-client

[python]
name = geoengine_openapi_client
version = 0.0.17
version = 0.0.18

[typescript]
name = @geoengine/openapi-client
version = 0.0.17
version = 0.0.18

25 changes: 24 additions & 1 deletion .generation/input/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
"servers": [
{
"url": "http://localhost:3030/api"
"url": "http://0.0.0.0:3030/api"
}
],
"paths": {
Expand Down Expand Up @@ -6755,6 +6755,25 @@
"MlModelName": {
"type": "string"
},
"MlModelResource": {
"type": "object",
"title": "MlModelResource",
"required": [
"type",
"id"
],
"properties": {
"id": {
"$ref": "#/components/schemas/MlModelId"
},
"type": {
"type": "string",
"enum": [
"mlModel"
]
}
}
},
"MockDatasetDataSourceLoadingInfo": {
"type": "object",
"required": [
Expand Down Expand Up @@ -8184,6 +8203,9 @@
},
{
"$ref": "#/components/schemas/DatasetResource"
},
{
"$ref": "#/components/schemas/MlModelResource"
}
],
"discriminator": {
Expand All @@ -8192,6 +8214,7 @@
"dataset": "#/components/schemas/DatasetResource",
"layer": "#/components/schemas/LayerResource",
"layerCollection": "#/components/schemas/LayerCollectionResource",
"mlModel": "#/components/schemas/MlModelResource",
"project": "#/components/schemas/ProjectResource"
}
}
Expand Down
3 changes: 3 additions & 0 deletions python/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ docs/MetaDataDefinition.md
docs/MetaDataSuggestion.md
docs/MlModel.md
docs/MlModelMetadata.md
docs/MlModelResource.md
docs/MockDatasetDataSourceLoadingInfo.md
docs/MockMetaData.md
docs/MultiBandRasterColorizer.md
Expand Down Expand Up @@ -337,6 +338,7 @@ geoengine_openapi_client/models/meta_data_definition.py
geoengine_openapi_client/models/meta_data_suggestion.py
geoengine_openapi_client/models/ml_model.py
geoengine_openapi_client/models/ml_model_metadata.py
geoengine_openapi_client/models/ml_model_resource.py
geoengine_openapi_client/models/mock_dataset_data_source_loading_info.py
geoengine_openapi_client/models/mock_meta_data.py
geoengine_openapi_client/models/multi_band_raster_colorizer.py
Expand Down Expand Up @@ -567,6 +569,7 @@ test/test_meta_data_suggestion.py
test/test_ml_api.py
test/test_ml_model.py
test/test_ml_model_metadata.py
test/test_ml_model_resource.py
test/test_mock_dataset_data_source_loading_info.py
test/test_mock_meta_data.py
test/test_multi_band_raster_colorizer.py
Expand Down
7 changes: 4 additions & 3 deletions python/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ import geoengine_openapi_client
from geoengine_openapi_client.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:3030/api
# Defining the host is optional and defaults to http://0.0.0.0:3030/api
# See configuration.py for a list of all supported configuration parameters.
configuration = geoengine_openapi_client.Configuration(
host = "http://localhost:3030/api"
host = "http://0.0.0.0:3030/api"
)

# The client must configure the authentication and authorization parameters
Expand Down Expand Up @@ -90,7 +90,7 @@ with geoengine_openapi_client.ApiClient(configuration) as api_client:

## Documentation for API Endpoints

All URIs are relative to *http://localhost:3030/api*
All URIs are relative to *http://0.0.0.0:3030/api*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
Expand Down Expand Up @@ -261,6 +261,7 @@ Class | Method | HTTP request | Description
- [MetaDataSuggestion](docs/MetaDataSuggestion.md)
- [MlModel](docs/MlModel.md)
- [MlModelMetadata](docs/MlModelMetadata.md)
- [MlModelResource](docs/MlModelResource.md)
- [MockDatasetDataSourceLoadingInfo](docs/MockDatasetDataSourceLoadingInfo.md)
- [MockMetaData](docs/MockMetaData.md)
- [MultiBandRasterColorizer](docs/MultiBandRasterColorizer.md)
Expand Down
1 change: 1 addition & 0 deletions python/geoengine_openapi_client/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@
from geoengine_openapi_client.models.meta_data_suggestion import MetaDataSuggestion
from geoengine_openapi_client.models.ml_model import MlModel
from geoengine_openapi_client.models.ml_model_metadata import MlModelMetadata
from geoengine_openapi_client.models.ml_model_resource import MlModelResource
from geoengine_openapi_client.models.mock_dataset_data_source_loading_info import MockDatasetDataSourceLoadingInfo
from geoengine_openapi_client.models.mock_meta_data import MockMetaData
from geoengine_openapi_client.models.multi_band_raster_colorizer import MultiBandRasterColorizer
Expand Down
4 changes: 2 additions & 2 deletions python/geoengine_openapi_client/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def __init__(self, host=None,
) -> None:
"""Constructor
"""
self._base_path = "http://localhost:3030/api" if host is None else host
self._base_path = "http://0.0.0.0:3030/api" if host is None else host
"""Default Base url
"""
self.server_index = 0 if server_index is None and host is None else server_index
Expand Down Expand Up @@ -388,7 +388,7 @@ def get_host_settings(self):
"""
return [
{
'url': "http://localhost:3030/api",
'url': "http://0.0.0.0:3030/api",
'description': "No description provided",
}
]
Expand Down
1 change: 1 addition & 0 deletions python/geoengine_openapi_client/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@
from geoengine_openapi_client.models.meta_data_suggestion import MetaDataSuggestion
from geoengine_openapi_client.models.ml_model import MlModel
from geoengine_openapi_client.models.ml_model_metadata import MlModelMetadata
from geoengine_openapi_client.models.ml_model_resource import MlModelResource
from geoengine_openapi_client.models.mock_dataset_data_source_loading_info import MockDatasetDataSourceLoadingInfo
from geoengine_openapi_client.models.mock_meta_data import MockMetaData
from geoengine_openapi_client.models.multi_band_raster_colorizer import MultiBandRasterColorizer
Expand Down
4 changes: 2 additions & 2 deletions python/geoengine_openapi_client/models/layer_resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ class LayerResource(BaseModel):
@validator('type')
def type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('layer', 'layerCollection', 'project', 'dataset'):
raise ValueError("must be one of enum values ('layer', 'layerCollection', 'project', 'dataset')")
if value not in ('layer', 'layerCollection', 'project', 'dataset', 'mlModel'):
raise ValueError("must be one of enum values ('layer', 'layerCollection', 'project', 'dataset', 'mlModel')")
return value

class Config:
Expand Down
81 changes: 81 additions & 0 deletions python/geoengine_openapi_client/models/ml_model_resource.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# coding: utf-8

"""
Geo Engine Pro API

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

The version of the OpenAPI document: 0.8.0
Contact: [email protected]
Generated by OpenAPI Generator (https://openapi-generator.tech)

Do not edit the class manually.
""" # noqa: E501


from __future__ import annotations
import pprint
import re # noqa: F401
import json



from pydantic import BaseModel, Field, StrictStr, validator

class MlModelResource(BaseModel):
"""
MlModelResource
"""
id: StrictStr = Field(...)
type: StrictStr = Field(...)
__properties = ["id", "type"]

@validator('type')
def type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('mlModel'):
raise ValueError("must be one of enum values ('mlModel')")
return value

class Config:
"""Pydantic configuration"""
allow_population_by_field_name = True
validate_assignment = True

def to_str(self) -> str:
"""Returns the string representation of the model using alias"""
return pprint.pformat(self.dict(by_alias=True))

def to_json(self) -> str:
"""Returns the JSON representation of the model using alias"""
return json.dumps(self.to_dict())

@classmethod
def from_json(cls, json_str: str) -> MlModelResource:
"""Create an instance of MlModelResource from a JSON string"""
return cls.from_dict(json.loads(json_str))

def to_dict(self):
"""Returns the dictionary representation of the model using alias"""
_dict = self.dict(by_alias=True,
exclude={
},
exclude_none=True)
return _dict

@classmethod
def from_dict(cls, obj: dict) -> MlModelResource:
"""Create an instance of MlModelResource from a dict"""
if obj is None:
return None

if not isinstance(obj, dict):
return MlModelResource.parse_obj(obj)

_obj = MlModelResource.parse_obj({
"id": obj.get("id"),
"type": obj.get("type")
})
return _obj


81 changes: 81 additions & 0 deletions python/geoengine_openapi_client/models/ml_model_ressource.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# coding: utf-8

"""
Geo Engine Pro API

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

The version of the OpenAPI document: 0.8.0
Contact: [email protected]
Generated by OpenAPI Generator (https://openapi-generator.tech)

Do not edit the class manually.
""" # noqa: E501


from __future__ import annotations
import pprint
import re # noqa: F401
import json



from pydantic import BaseModel, Field, StrictStr, validator

class MlModelRessource(BaseModel):
"""
MlModelRessource
"""
id: StrictStr = Field(...)
type: StrictStr = Field(...)
__properties = ["id", "type"]

@validator('type')
def type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('mlModel'):
raise ValueError("must be one of enum values ('mlModel')")
return value

class Config:
"""Pydantic configuration"""
allow_population_by_field_name = True
validate_assignment = True

def to_str(self) -> str:
"""Returns the string representation of the model using alias"""
return pprint.pformat(self.dict(by_alias=True))

def to_json(self) -> str:
"""Returns the JSON representation of the model using alias"""
return json.dumps(self.to_dict())

@classmethod
def from_json(cls, json_str: str) -> MlModelRessource:
"""Create an instance of MlModelRessource from a JSON string"""
return cls.from_dict(json.loads(json_str))

def to_dict(self):
"""Returns the dictionary representation of the model using alias"""
_dict = self.dict(by_alias=True,
exclude={
},
exclude_none=True)
return _dict

@classmethod
def from_dict(cls, obj: dict) -> MlModelRessource:
"""Create an instance of MlModelRessource from a dict"""
if obj is None:
return None

if not isinstance(obj, dict):
return MlModelRessource.parse_obj(obj)

_obj = MlModelRessource.parse_obj({
"id": obj.get("id"),
"type": obj.get("type")
})
return _obj


Loading
Loading