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
5 changes: 5 additions & 0 deletions agent/src/superplaneapi/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@
from superplaneapi.models.organizations_describe_organization_response import OrganizationsDescribeOrganizationResponse
from superplaneapi.models.organizations_get_agent_settings_response import OrganizationsGetAgentSettingsResponse
from superplaneapi.models.organizations_get_invite_link_response import OrganizationsGetInviteLinkResponse
from superplaneapi.models.organizations_get_okta_idp_settings_response import OrganizationsGetOktaIdpSettingsResponse
from superplaneapi.models.organizations_integration import OrganizationsIntegration
from superplaneapi.models.organizations_integration_metadata import OrganizationsIntegrationMetadata
from superplaneapi.models.organizations_integration_resource_ref import OrganizationsIntegrationResourceRef
Expand All @@ -192,9 +193,11 @@
from superplaneapi.models.organizations_invite_link import OrganizationsInviteLink
from superplaneapi.models.organizations_list_integration_resources_response import OrganizationsListIntegrationResourcesResponse
from superplaneapi.models.organizations_list_invitations_response import OrganizationsListInvitationsResponse
from superplaneapi.models.organizations_okta_idp_settings import OrganizationsOktaIdpSettings
from superplaneapi.models.organizations_organization import OrganizationsOrganization
from superplaneapi.models.organizations_organization_metadata import OrganizationsOrganizationMetadata
from superplaneapi.models.organizations_reset_invite_link_response import OrganizationsResetInviteLinkResponse
from superplaneapi.models.organizations_rotate_okta_scim_bearer_token_response import OrganizationsRotateOktaScimBearerTokenResponse
from superplaneapi.models.organizations_set_agent_open_ai_key_body import OrganizationsSetAgentOpenAIKeyBody
from superplaneapi.models.organizations_set_agent_open_ai_key_response import OrganizationsSetAgentOpenAIKeyResponse
from superplaneapi.models.organizations_update_agent_settings_body import OrganizationsUpdateAgentSettingsBody
Expand All @@ -203,6 +206,8 @@
from superplaneapi.models.organizations_update_integration_response import OrganizationsUpdateIntegrationResponse
from superplaneapi.models.organizations_update_invite_link_body import OrganizationsUpdateInviteLinkBody
from superplaneapi.models.organizations_update_invite_link_response import OrganizationsUpdateInviteLinkResponse
from superplaneapi.models.organizations_update_okta_idp_settings_body import OrganizationsUpdateOktaIdpSettingsBody
from superplaneapi.models.organizations_update_okta_idp_settings_response import OrganizationsUpdateOktaIdpSettingsResponse
from superplaneapi.models.organizations_update_organization_body import OrganizationsUpdateOrganizationBody
from superplaneapi.models.organizations_update_organization_response import OrganizationsUpdateOrganizationResponse
from superplaneapi.models.protobuf_any import ProtobufAny
Expand Down
842 changes: 827 additions & 15 deletions agent/src/superplaneapi/api/organization_api.py

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions agent/src/superplaneapi/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@
from superplaneapi.models.organizations_describe_organization_response import OrganizationsDescribeOrganizationResponse
from superplaneapi.models.organizations_get_agent_settings_response import OrganizationsGetAgentSettingsResponse
from superplaneapi.models.organizations_get_invite_link_response import OrganizationsGetInviteLinkResponse
from superplaneapi.models.organizations_get_okta_idp_settings_response import OrganizationsGetOktaIdpSettingsResponse
from superplaneapi.models.organizations_integration import OrganizationsIntegration
from superplaneapi.models.organizations_integration_metadata import OrganizationsIntegrationMetadata
from superplaneapi.models.organizations_integration_resource_ref import OrganizationsIntegrationResourceRef
Expand All @@ -158,9 +159,11 @@
from superplaneapi.models.organizations_invite_link import OrganizationsInviteLink
from superplaneapi.models.organizations_list_integration_resources_response import OrganizationsListIntegrationResourcesResponse
from superplaneapi.models.organizations_list_invitations_response import OrganizationsListInvitationsResponse
from superplaneapi.models.organizations_okta_idp_settings import OrganizationsOktaIdpSettings
from superplaneapi.models.organizations_organization import OrganizationsOrganization
from superplaneapi.models.organizations_organization_metadata import OrganizationsOrganizationMetadata
from superplaneapi.models.organizations_reset_invite_link_response import OrganizationsResetInviteLinkResponse
from superplaneapi.models.organizations_rotate_okta_scim_bearer_token_response import OrganizationsRotateOktaScimBearerTokenResponse
from superplaneapi.models.organizations_set_agent_open_ai_key_body import OrganizationsSetAgentOpenAIKeyBody
from superplaneapi.models.organizations_set_agent_open_ai_key_response import OrganizationsSetAgentOpenAIKeyResponse
from superplaneapi.models.organizations_update_agent_settings_body import OrganizationsUpdateAgentSettingsBody
Expand All @@ -169,6 +172,8 @@
from superplaneapi.models.organizations_update_integration_response import OrganizationsUpdateIntegrationResponse
from superplaneapi.models.organizations_update_invite_link_body import OrganizationsUpdateInviteLinkBody
from superplaneapi.models.organizations_update_invite_link_response import OrganizationsUpdateInviteLinkResponse
from superplaneapi.models.organizations_update_okta_idp_settings_body import OrganizationsUpdateOktaIdpSettingsBody
from superplaneapi.models.organizations_update_okta_idp_settings_response import OrganizationsUpdateOktaIdpSettingsResponse
from superplaneapi.models.organizations_update_organization_body import OrganizationsUpdateOrganizationBody
from superplaneapi.models.organizations_update_organization_response import OrganizationsUpdateOrganizationResponse
from superplaneapi.models.protobuf_any import ProtobufAny
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
# coding: utf-8

"""
Superplane Organizations API

API for managing organizations in the Superplane service

The version of the OpenAPI document: 1.0
Contact: support@superplane.com
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, ConfigDict
from typing import Any, ClassVar, Dict, List, Optional
from superplaneapi.models.organizations_okta_idp_settings import OrganizationsOktaIdpSettings
from typing import Optional, Set
from typing_extensions import Self

class OrganizationsGetOktaIdpSettingsResponse(BaseModel):
"""
OrganizationsGetOktaIdpSettingsResponse
""" # noqa: E501
settings: Optional[OrganizationsOktaIdpSettings] = None
__properties: ClassVar[List[str]] = ["settings"]

model_config = ConfigDict(
populate_by_name=True,
validate_assignment=True,
protected_namespaces=(),
)


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

def to_json(self) -> str:
"""Returns the JSON representation of the model using alias"""
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
return json.dumps(self.to_dict())

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

def to_dict(self) -> Dict[str, Any]:
"""Return the dictionary representation of the model using alias.

This has the following differences from calling pydantic's
`self.model_dump(by_alias=True)`:

* `None` is only added to the output dict for nullable fields that
were set at model initialization. Other fields with value `None`
are ignored.
"""
excluded_fields: Set[str] = set([
])

_dict = self.model_dump(
by_alias=True,
exclude=excluded_fields,
exclude_none=True,
)
# override the default output from pydantic by calling `to_dict()` of settings
if self.settings:
_dict['settings'] = self.settings.to_dict()
return _dict

@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OrganizationsGetOktaIdpSettingsResponse from a dict"""
if obj is None:
return None

if not isinstance(obj, dict):
return cls.model_validate(obj)

_obj = cls.model_validate({
"settings": OrganizationsOktaIdpSettings.from_dict(obj["settings"]) if obj.get("settings") is not None else None
})
return _obj


107 changes: 107 additions & 0 deletions agent/src/superplaneapi/models/organizations_okta_idp_settings.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
# coding: utf-8

"""
Superplane Organizations API

API for managing organizations in the Superplane service

The version of the OpenAPI document: 1.0
Contact: support@superplane.com
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 datetime import datetime
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
from typing import Optional, Set
from typing_extensions import Self

class OrganizationsOktaIdpSettings(BaseModel):
"""
OrganizationsOktaIdpSettings
""" # noqa: E501
organization_id: Optional[StrictStr] = Field(default=None, alias="organizationId")
configured: Optional[StrictBool] = None
issuer_base_url: Optional[StrictStr] = Field(default=None, alias="issuerBaseUrl")
oauth_client_id: Optional[StrictStr] = Field(default=None, alias="oauthClientId")
oauth_client_secret_configured: Optional[StrictBool] = Field(default=None, alias="oauthClientSecretConfigured")
oidc_enabled: Optional[StrictBool] = Field(default=None, alias="oidcEnabled")
scim_enabled: Optional[StrictBool] = Field(default=None, alias="scimEnabled")
scim_bearer_token_configured: Optional[StrictBool] = Field(default=None, alias="scimBearerTokenConfigured")
created_at: Optional[datetime] = Field(default=None, alias="createdAt")
updated_at: Optional[datetime] = Field(default=None, alias="updatedAt")
__properties: ClassVar[List[str]] = ["organizationId", "configured", "issuerBaseUrl", "oauthClientId", "oauthClientSecretConfigured", "oidcEnabled", "scimEnabled", "scimBearerTokenConfigured", "createdAt", "updatedAt"]

model_config = ConfigDict(
populate_by_name=True,
validate_assignment=True,
protected_namespaces=(),
)


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

def to_json(self) -> str:
"""Returns the JSON representation of the model using alias"""
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
return json.dumps(self.to_dict())

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

def to_dict(self) -> Dict[str, Any]:
"""Return the dictionary representation of the model using alias.

This has the following differences from calling pydantic's
`self.model_dump(by_alias=True)`:

* `None` is only added to the output dict for nullable fields that
were set at model initialization. Other fields with value `None`
are ignored.
"""
excluded_fields: Set[str] = set([
])

_dict = self.model_dump(
by_alias=True,
exclude=excluded_fields,
exclude_none=True,
)
return _dict

@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OrganizationsOktaIdpSettings from a dict"""
if obj is None:
return None

if not isinstance(obj, dict):
return cls.model_validate(obj)

_obj = cls.model_validate({
"organizationId": obj.get("organizationId"),
"configured": obj.get("configured"),
"issuerBaseUrl": obj.get("issuerBaseUrl"),
"oauthClientId": obj.get("oauthClientId"),
"oauthClientSecretConfigured": obj.get("oauthClientSecretConfigured"),
"oidcEnabled": obj.get("oidcEnabled"),
"scimEnabled": obj.get("scimEnabled"),
"scimBearerTokenConfigured": obj.get("scimBearerTokenConfigured"),
"createdAt": obj.get("createdAt"),
"updatedAt": obj.get("updatedAt")
})
return _obj


Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
# coding: utf-8

"""
Superplane Organizations API

API for managing organizations in the Superplane service

The version of the OpenAPI document: 1.0
Contact: support@superplane.com
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, ConfigDict, Field, StrictStr
from typing import Any, ClassVar, Dict, List, Optional
from superplaneapi.models.organizations_okta_idp_settings import OrganizationsOktaIdpSettings
from typing import Optional, Set
from typing_extensions import Self

class OrganizationsRotateOktaScimBearerTokenResponse(BaseModel):
"""
OrganizationsRotateOktaScimBearerTokenResponse
""" # noqa: E501
scim_bearer_token: Optional[StrictStr] = Field(default=None, alias="scimBearerToken")
settings: Optional[OrganizationsOktaIdpSettings] = None
__properties: ClassVar[List[str]] = ["scimBearerToken", "settings"]

model_config = ConfigDict(
populate_by_name=True,
validate_assignment=True,
protected_namespaces=(),
)


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

def to_json(self) -> str:
"""Returns the JSON representation of the model using alias"""
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
return json.dumps(self.to_dict())

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

def to_dict(self) -> Dict[str, Any]:
"""Return the dictionary representation of the model using alias.

This has the following differences from calling pydantic's
`self.model_dump(by_alias=True)`:

* `None` is only added to the output dict for nullable fields that
were set at model initialization. Other fields with value `None`
are ignored.
"""
excluded_fields: Set[str] = set([
])

_dict = self.model_dump(
by_alias=True,
exclude=excluded_fields,
exclude_none=True,
)
# override the default output from pydantic by calling `to_dict()` of settings
if self.settings:
_dict['settings'] = self.settings.to_dict()
return _dict

@classmethod
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
"""Create an instance of OrganizationsRotateOktaScimBearerTokenResponse from a dict"""
if obj is None:
return None

if not isinstance(obj, dict):
return cls.model_validate(obj)

_obj = cls.model_validate({
"scimBearerToken": obj.get("scimBearerToken"),
"settings": OrganizationsOktaIdpSettings.from_dict(obj["settings"]) if obj.get("settings") is not None else None
})
return _obj


Loading