Skip to content

Commit

Permalink
feat: [google-cloud-advisorynotifications] add GetSettings and Update…
Browse files Browse the repository at this point in the history
…Settings methods at the Project-level to advisorynotifications.googleapis.com (#12547)

BEGIN_COMMIT_OVERRIDE

feat: add GetSettings and UpdateSettings methods at the Project-level to
advisorynotifications.googleapis.com

docs: adding docs for new project level settings methods

END_COMMIT_OVERRIDE

- [ ] Regenerate this pull request now.

docs: adding docs for new project level settings methods
PiperOrigin-RevId: 621647197

Source-Link:
googleapis/googleapis@39692d0

Source-Link:
googleapis/googleapis-gen@5d0ab2f
Copy-Tag:
eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWFkdmlzb3J5bm90aWZpY2F0aW9ucy8uT3dsQm90LnlhbWwiLCJoIjoiNWQwYWIyZmU4YjM3OWRmYWU2NTFiMzUwZjM4OTE1ZjJkNDRhZjQyYSJ9

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: ohmayr <omairnaveed@ymail.com>
  • Loading branch information
3 people authored Apr 4, 2024
1 parent 22201e2 commit b8a4835
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ async def sample_list_notifications():
the form
"organizations/{organization}/locations/{location}"
or
"projects/{project}/locations/{location}"
"projects/{project}/locations/{location}".
This corresponds to the ``parent`` field
on the ``request`` instance; if ``request`` is provided, this
Expand Down Expand Up @@ -566,7 +566,9 @@ async def sample_get_settings():
Required. The resource name of the
settings to retrieve. Format:
organizations/{organization}/locations/{location}/settings.
organizations/{organization}/locations/{location}/settings
or
projects/{projects}/locations/{location}/settings.
This corresponds to the ``name`` field
on the ``request`` instance; if ``request`` is provided, this
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -747,7 +747,7 @@ def sample_list_notifications():
the form
"organizations/{organization}/locations/{location}"
or
"projects/{project}/locations/{location}"
"projects/{project}/locations/{location}".
This corresponds to the ``parent`` field
on the ``request`` instance; if ``request`` is provided, this
Expand Down Expand Up @@ -974,7 +974,9 @@ def sample_get_settings():
Required. The resource name of the
settings to retrieve. Format:
organizations/{organization}/locations/{location}/settings.
organizations/{organization}/locations/{location}/settings
or
projects/{projects}/locations/{location}/settings.
This corresponds to the ``name`` field
on the ``request`` instance; if ``request`` is provided, this
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -421,6 +421,10 @@ def __call__(
"method": "get",
"uri": "/v1/{name=organizations/*/locations/*/settings}",
},
{
"method": "get",
"uri": "/v1/{name=projects/*/locations/*/settings}",
},
]
request, metadata = self._interceptor.pre_get_settings(request, metadata)
pb_request = service.GetSettingsRequest.pb(request)
Expand Down Expand Up @@ -601,6 +605,11 @@ def __call__(
"uri": "/v1/{settings.name=organizations/*/locations/*/settings}",
"body": "settings",
},
{
"method": "patch",
"uri": "/v1/{settings.name=projects/*/locations/*/settings}",
"body": "settings",
},
]
request, metadata = self._interceptor.pre_update_settings(request, metadata)
pb_request = service.UpdateSettingsRequest.pb(request)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -449,10 +449,12 @@ class Settings(proto.Message):
Attributes:
name (str):
Output only. The resource name of the
settings to retrieve. Format:
Identifier. The resource name of the settings
to retrieve. Format:
organizations/{organization}/locations/{location}/settings.
organizations/{organization}/locations/{location}/settings
or
projects/{projects}/locations/{location}/settings.
notification_settings (MutableMapping[str, google.cloud.advisorynotifications_v1.types.NotificationSettings]):
Required. Map of each notification type and
its settings to get/set all settings at once.
Expand Down Expand Up @@ -506,7 +508,9 @@ class GetSettingsRequest(proto.Message):
Required. The resource name of the settings
to retrieve. Format:
organizations/{organization}/locations/{location}/settings.
organizations/{organization}/locations/{location}/settings
or
projects/{projects}/locations/{location}/settings.
"""

name: str = proto.Field(
Expand Down

0 comments on commit b8a4835

Please sign in to comment.