Skip to content

Add events response fields message and status #1576

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

Merged
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
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.5",
"regenerated": "2023-07-13 19:35:43.377556",
"spec_repo_commit": "b37fc521"
"regenerated": "2023-07-13 20:37:02.004842",
"spec_repo_commit": "efde263a"
},
"v2": {
"apigentools_version": "1.6.5",
"regenerated": "2023-07-13 19:35:43.395282",
"spec_repo_commit": "b37fc521"
"regenerated": "2023-07-13 20:37:02.018065",
"spec_repo_commit": "efde263a"
}
}
}
7 changes: 7 additions & 0 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4443,6 +4443,9 @@ components:
properties:
attributes:
$ref: '#/components/schemas/EventAttributes'
message:
description: The message of the event.
type: string
tags:
description: An array of tags associated with the event.
example:
Expand Down Expand Up @@ -4693,6 +4696,10 @@ components:
description: The identifier of the request.
example: MWlFUjVaWGZTTTZPYzM0VXp1OXU2d3xLSVpEMjZKQ0VKUTI0dEYtM3RSOFVR
type: string
status:
description: The request status.
example: done
type: string
warnings:
description: 'A list of warnings (non-fatal errors) encountered. Partial
results might be returned if
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,22 @@ def openapi_types(_):

return {
"attributes": (EventAttributes,),
"message": (str,),
"tags": ([str],),
"timestamp": (datetime,),
}

attribute_map = {
"attributes": "attributes",
"message": "message",
"tags": "tags",
"timestamp": "timestamp",
}

def __init__(
self_,
attributes: Union[EventAttributes, UnsetType] = unset,
message: Union[str, UnsetType] = unset,
tags: Union[List[str], UnsetType] = unset,
timestamp: Union[datetime, UnsetType] = unset,
**kwargs,
Expand All @@ -48,6 +51,9 @@ def __init__(
:param attributes: Object description of attributes from your event.
:type attributes: EventAttributes, optional

:param message: The message of the event.
:type message: str, optional

:param tags: An array of tags associated with the event.
:type tags: [str], optional

Expand All @@ -56,6 +62,8 @@ def __init__(
"""
if attributes is not unset:
kwargs["attributes"] = attributes
if message is not unset:
kwargs["message"] = message
if tags is not unset:
kwargs["tags"] = tags
if timestamp is not unset:
Expand Down
8 changes: 8 additions & 0 deletions src/datadog_api_client/v2/model/events_response_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,15 @@ def openapi_types(_):
"elapsed": (int,),
"page": (EventsResponseMetadataPage,),
"request_id": (str,),
"status": (str,),
"warnings": ([EventsWarning],),
}

attribute_map = {
"elapsed": "elapsed",
"page": "page",
"request_id": "request_id",
"status": "status",
"warnings": "warnings",
}

Expand All @@ -43,6 +45,7 @@ def __init__(
elapsed: Union[int, UnsetType] = unset,
page: Union[EventsResponseMetadataPage, UnsetType] = unset,
request_id: Union[str, UnsetType] = unset,
status: Union[str, UnsetType] = unset,
warnings: Union[List[EventsWarning], UnsetType] = unset,
**kwargs,
):
Expand All @@ -58,6 +61,9 @@ def __init__(
:param request_id: The identifier of the request.
:type request_id: str, optional

:param status: The request status.
:type status: str, optional

:param warnings: A list of warnings (non-fatal errors) encountered. Partial results might be returned if
warnings are present in the response.
:type warnings: [EventsWarning], optional
Expand All @@ -68,6 +74,8 @@ def __init__(
kwargs["page"] = page
if request_id is not unset:
kwargs["request_id"] = request_id
if status is not unset:
kwargs["status"] = status
if warnings is not unset:
kwargs["warnings"] = warnings
super().__init__(kwargs)