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

[AutoPR security/resource-manager] Add playbook configurations resource REST specification #6934

Closed
Closed
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
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
from ._models_py3 import ConnectedWorkspace
from ._models_py3 import DataExportSetting
from ._models_py3 import DiscoveredSecuritySolution
from ._models_py3 import ETag
from ._models_py3 import ExternalSecuritySolution
from ._models_py3 import ExternalSecuritySolutionKind1
from ._models_py3 import ExternalSecuritySolutionProperties
Expand Down Expand Up @@ -85,11 +86,13 @@
from ._models_py3 import ServerVulnerabilityAssessmentsList
from ._models_py3 import Setting
from ._models_py3 import SettingResource
from ._models_py3 import Tags
from ._models_py3 import TagsResource
from ._models_py3 import TopologyResource
from ._models_py3 import TopologySingleResource
from ._models_py3 import TopologySingleResourceChild
from ._models_py3 import TopologySingleResourceParent
from ._models_py3 import TrackedResource
from ._models_py3 import UpdateIotSecuritySolutionData
from ._models_py3 import UserDefinedResourcesProperties
from ._models_py3 import UserRecommendation
Expand Down Expand Up @@ -122,6 +125,7 @@
from ._models import ConnectedWorkspace
from ._models import DataExportSetting
from ._models import DiscoveredSecuritySolution
from ._models import ETag
from ._models import ExternalSecuritySolution
from ._models import ExternalSecuritySolutionKind1
from ._models import ExternalSecuritySolutionProperties
Expand Down Expand Up @@ -171,11 +175,13 @@
from ._models import ServerVulnerabilityAssessmentsList
from ._models import Setting
from ._models import SettingResource
from ._models import Tags
from ._models import TagsResource
from ._models import TopologyResource
from ._models import TopologySingleResource
from ._models import TopologySingleResourceChild
from ._models import TopologySingleResourceParent
from ._models import TrackedResource
from ._models import UpdateIotSecuritySolutionData
from ._models import UserDefinedResourcesProperties
from ._models import UserRecommendation
Expand Down Expand Up @@ -253,6 +259,7 @@
'ConnectedWorkspace',
'DataExportSetting',
'DiscoveredSecuritySolution',
'ETag',
'ExternalSecuritySolution',
'ExternalSecuritySolutionKind1',
'ExternalSecuritySolutionProperties',
Expand Down Expand Up @@ -302,11 +309,13 @@
'ServerVulnerabilityAssessmentsList',
'Setting',
'SettingResource',
'Tags',
'TagsResource',
'TopologyResource',
'TopologySingleResource',
'TopologySingleResourceChild',
'TopologySingleResourceParent',
'TrackedResource',
'UpdateIotSecuritySolutionData',
'UserDefinedResourcesProperties',
'UserRecommendation',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1315,6 +1315,27 @@ def __init__(self, **kwargs):
self.sku = kwargs.get('sku', None)


class ETag(Model):
"""Entity tag is used for comparing two or more entities from the same
requested resource. ETags may be returned for individual resources, and
then sent via If-Match / If-None-Match headers for concurrency control. .

:param etag: Entity tag is used for comparing two or more entities from
the same requested resource. ETags may be returned for individual
resources, and then sent via If-Match / If-None-Match headers for
concurrency control.
:type etag: str
"""

_attribute_map = {
'etag': {'key': 'etag', 'type': 'str'},
}

def __init__(self, **kwargs):
super(ETag, self).__init__(**kwargs)
self.etag = kwargs.get('etag', None)


class ExternalSecuritySolutionKind1(Model):
"""Describes an Azure resource with kind.

Expand Down Expand Up @@ -2549,7 +2570,10 @@ def __init__(self, **kwargs):


class Pricing(Resource):
"""Pricing tier will be applied for the scope based on the resource ID.
"""Azure Security Center is provided in two pricing tiers: free and standard,
with the standard tier available with a trial period. The standard tier
offers advanced security capabilities, while the free tier offers basic
security features.

Variables are only populated by the server, and will be ignored when
sending a request.
Expand Down Expand Up @@ -3111,6 +3135,22 @@ def __init__(self, **kwargs):
self.value = kwargs.get('value', None)


class Tags(Model):
"""A list of key value pairs that describe the resource.

:param tags: A list of key value pairs that describe the resource.
:type tags: dict[str, str]
"""

_attribute_map = {
'tags': {'key': 'tags', 'type': '{str}'},
}

def __init__(self, **kwargs):
super(Tags, self).__init__(**kwargs)
self.tags = kwargs.get('tags', None)


class TagsResource(Model):
"""A container holding only the Tags for a resource, allowing the user to
update the tags.
Expand Down Expand Up @@ -3291,6 +3331,59 @@ def __init__(self, **kwargs):
self.resource_id = None


class TrackedResource(Model):
"""Describes an Azure tracked resource.

Variables are only populated by the server, and will be ignored when
sending a request.

:ivar id: Resource Id
:vartype id: str
:ivar name: Resource name
:vartype name: str
:ivar type: Resource type
:vartype type: str
:ivar location: Location where the resource is stored
:vartype location: str
:param kind: Kind of the resource
:type kind: str
:param etag: Entity tag is used for comparing two or more entities from
the same requested resource. ETags may be returned for individual
resources, and then sent via If-Match / If-None-Match headers for
concurrency control.
:type etag: str
:param tags: A list of key value pairs that describe the resource.
:type tags: dict[str, str]
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'readonly': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'location': {'key': 'location', 'type': 'str'},
'kind': {'key': 'kind', 'type': 'str'},
'etag': {'key': 'etag', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
}

def __init__(self, **kwargs):
super(TrackedResource, self).__init__(**kwargs)
self.id = None
self.name = None
self.type = None
self.location = None
self.kind = kwargs.get('kind', None)
self.etag = kwargs.get('etag', None)
self.tags = kwargs.get('tags', None)


class UpdateIotSecuritySolutionData(TagsResource):
"""UpdateIotSecuritySolutionData.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1315,6 +1315,27 @@ def __init__(self, *, security_family, offer: str, publisher: str, sku: str, **k
self.sku = sku


class ETag(Model):
"""Entity tag is used for comparing two or more entities from the same
requested resource. ETags may be returned for individual resources, and
then sent via If-Match / If-None-Match headers for concurrency control. .

:param etag: Entity tag is used for comparing two or more entities from
the same requested resource. ETags may be returned for individual
resources, and then sent via If-Match / If-None-Match headers for
concurrency control.
:type etag: str
"""

_attribute_map = {
'etag': {'key': 'etag', 'type': 'str'},
}

def __init__(self, *, etag: str=None, **kwargs) -> None:
super(ETag, self).__init__(**kwargs)
self.etag = etag


class ExternalSecuritySolutionKind1(Model):
"""Describes an Azure resource with kind.

Expand Down Expand Up @@ -2549,7 +2570,10 @@ def __init__(self, *, path: str=None, action=None, type=None, publisher_info=Non


class Pricing(Resource):
"""Pricing tier will be applied for the scope based on the resource ID.
"""Azure Security Center is provided in two pricing tiers: free and standard,
with the standard tier available with a trial period. The standard tier
offers advanced security capabilities, while the free tier offers basic
security features.

Variables are only populated by the server, and will be ignored when
sending a request.
Expand Down Expand Up @@ -3111,6 +3135,22 @@ def __init__(self, *, value=None, **kwargs) -> None:
self.value = value


class Tags(Model):
"""A list of key value pairs that describe the resource.

:param tags: A list of key value pairs that describe the resource.
:type tags: dict[str, str]
"""

_attribute_map = {
'tags': {'key': 'tags', 'type': '{str}'},
}

def __init__(self, *, tags=None, **kwargs) -> None:
super(Tags, self).__init__(**kwargs)
self.tags = tags


class TagsResource(Model):
"""A container holding only the Tags for a resource, allowing the user to
update the tags.
Expand Down Expand Up @@ -3291,6 +3331,59 @@ def __init__(self, **kwargs) -> None:
self.resource_id = None


class TrackedResource(Model):
"""Describes an Azure tracked resource.

Variables are only populated by the server, and will be ignored when
sending a request.

:ivar id: Resource Id
:vartype id: str
:ivar name: Resource name
:vartype name: str
:ivar type: Resource type
:vartype type: str
:ivar location: Location where the resource is stored
:vartype location: str
:param kind: Kind of the resource
:type kind: str
:param etag: Entity tag is used for comparing two or more entities from
the same requested resource. ETags may be returned for individual
resources, and then sent via If-Match / If-None-Match headers for
concurrency control.
:type etag: str
:param tags: A list of key value pairs that describe the resource.
:type tags: dict[str, str]
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'readonly': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'location': {'key': 'location', 'type': 'str'},
'kind': {'key': 'kind', 'type': 'str'},
'etag': {'key': 'etag', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
}

def __init__(self, *, kind: str=None, etag: str=None, tags=None, **kwargs) -> None:
super(TrackedResource, self).__init__(**kwargs)
self.id = None
self.name = None
self.type = None
self.location = None
self.kind = kind
self.etag = etag
self.tags = tags


class UpdateIotSecuritySolutionData(TagsResource):
"""UpdateIotSecuritySolutionData.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,7 @@ def __init__(self, client, config, serializer, deserializer):

def list(
self, custom_headers=None, raw=False, **operation_config):
"""A given security pricing configuration in the subscription. Azure
Security Center is available in two pricing tiers: Free and Standard,
on multiple resource types, including Virtual machines, SQL Servers,
App service plans and Storage accounts.
"""Lists Security Center pricing configurations in the subscription.

:param dict custom_headers: headers that will be added to the request
:param bool raw: returns the direct response alongside the
Expand Down Expand Up @@ -99,10 +96,8 @@ def list(

def get(
self, pricing_name, custom_headers=None, raw=False, **operation_config):
"""A given security pricing configuration in the subscription. Azure
Security Center is available in two pricing tiers: Free and Standard,
on multiple resource types, including Virtual machines, SQL Servers,
App service plans and Storage accounts.
"""Gets a provided Security Center pricing configuration in the
subscription.

:param pricing_name: name of the pricing configuration
:type pricing_name: str
Expand Down Expand Up @@ -160,10 +155,8 @@ def get(

def update(
self, pricing_name, pricing_tier, custom_headers=None, raw=False, **operation_config):
"""A given security pricing configuration in the subscription. Azure
Security Center is available in two pricing tiers: Free and Standard,
on multiple resource types, including Virtual machines, SQL Servers,
App service plans and Storage accounts.
"""Updates a provided Security Center pricing configuration in the
subscription.

:param pricing_name: name of the pricing configuration
:type pricing_name: str
Expand Down