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

fix incident response model #65

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
33 changes: 30 additions & 3 deletions opsgenie_sdk/api/incident/incident.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ class Incident(object):
'responders': 'list[Responder]',
'owner_team': 'str',
'extra_properties': 'dict(str, str)',
'request_id': 'str'
'request_id': 'str',
'impacted_services': 'list[str]'
}

attribute_map = {
Expand All @@ -64,10 +65,11 @@ class Incident(object):
'responders': 'responders',
'owner_team': 'ownerTeam',
'extra_properties': 'extraProperties',
'request_id': 'requestId'
'request_id': 'requestId',
'impacted_services': 'impactedServices'
}

def __init__(self, id=None, tiny_id=None, message=None, status=None, is_seen=None, tags=None, created_at=None, updated_at=None, source=None, owner=None, priority=None, responders=None, owner_team=None, extra_properties=None, request_id=None): # noqa: E501
def __init__(self, id=None, tiny_id=None, message=None, status=None, is_seen=None, tags=None, created_at=None, updated_at=None, source=None, owner=None, priority=None, responders=None, owner_team=None, extra_properties=None, request_id=None, impacted_services=None): # noqa: E501
"""Incident - a model defined in OpenAPI""" # noqa: E501

self._id = None
Expand All @@ -85,6 +87,7 @@ def __init__(self, id=None, tiny_id=None, message=None, status=None, is_seen=Non
self._owner_team = None
self._extra_properties = None
self._request_id = None
self._impacted_services = None
self.discriminator = None

self.id = id
Expand Down Expand Up @@ -116,6 +119,8 @@ def __init__(self, id=None, tiny_id=None, message=None, status=None, is_seen=Non
self.extra_properties = extra_properties
if request_id is not None:
self.request_id = request_id
if impacted_services is not None:
self.impacted_services = impacted_services

@property
def id(self):
Expand Down Expand Up @@ -436,6 +441,28 @@ def request_id(self, request_id):

self._request_id = request_id

#
@property
def impacted_services(self):
"""Gets the impacted services of this Incident. # noqa: E501


:return: The impacted services of this Incident. # noqa: E501
:rtype: list[str]
"""
return self._impacted_services

@impacted_services.setter
def impacted_services(self, impacted_services):
"""Sets the impacted services of this Incident.


:param impacted_services: The impacted services of this Incident. # noqa: E501
:type: list[str]
"""

self._impacted_services = impacted_services

def to_dict(self):
"""Returns the model properties as a dict"""
result = {}
Expand Down