Skip to content

Commit 7682d69

Browse files
feat: Automated regeneration of AdSensePlatform client (#12815)
Auto-created at 2025-01-14 13:15:16 +0000 using the toys pull request generator.
1 parent 814a8b1 commit 7682d69

File tree

4 files changed

+185
-1
lines changed

4 files changed

+185
-1
lines changed

clients/ad_sense_platform/lib/google_api/ad_sense_platform/v1alpha/api/accounts.ex

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,4 +165,80 @@ defmodule GoogleApi.AdSensePlatform.V1alpha.Api.Accounts do
165165
opts ++ [struct: %GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformsResponse{}]
166166
)
167167
end
168+
169+
@doc """
170+
Lists Platform Child Sites for a specified Platform Child Account.
171+
172+
## Parameters
173+
174+
* `connection` (*type:* `GoogleApi.AdSensePlatform.V1alpha.Connection.t`) - Connection to server
175+
* `parent` (*type:* `String.t`) - Required. The name of the platform to retrieve. Format: accounts/{account}/platforms/{platform}/childAccounts/{child_publisher_code}
176+
* `optional_params` (*type:* `keyword()`) - Optional parameters
177+
* `:"$.xgafv"` (*type:* `String.t`) - V1 error format.
178+
* `:access_token` (*type:* `String.t`) - OAuth access token.
179+
* `:alt` (*type:* `String.t`) - Data format for response.
180+
* `:callback` (*type:* `String.t`) - JSONP
181+
* `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response.
182+
* `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
183+
* `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user.
184+
* `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks.
185+
* `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
186+
* `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart").
187+
* `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart").
188+
* `:pageSize` (*type:* `integer()`) - Optional. The maximum number of children to include in the response, used for paging. If unspecified, at most 10000 platforms will be returned. The maximum value is 10000; values above 10000 will be coerced to 10000.
189+
* `:pageToken` (*type:* `String.t`) - Optional. A page token, received from a previous `ListPlatformChildren` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListPlatformChildren` must match the call that provided the page token.
190+
* `opts` (*type:* `keyword()`) - Call options
191+
192+
## Returns
193+
194+
* `{:ok, %GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse{}}` on success
195+
* `{:error, info}` on failure
196+
"""
197+
@spec adsenseplatform_accounts_platforms_child_accounts_sites_list(
198+
Tesla.Env.client(),
199+
String.t(),
200+
keyword(),
201+
keyword()
202+
) ::
203+
{:ok, GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse.t()}
204+
| {:ok, Tesla.Env.t()}
205+
| {:ok, list()}
206+
| {:error, any()}
207+
def adsenseplatform_accounts_platforms_child_accounts_sites_list(
208+
connection,
209+
parent,
210+
optional_params \\ [],
211+
opts \\ []
212+
) do
213+
optional_params_config = %{
214+
:"$.xgafv" => :query,
215+
:access_token => :query,
216+
:alt => :query,
217+
:callback => :query,
218+
:fields => :query,
219+
:key => :query,
220+
:oauth_token => :query,
221+
:prettyPrint => :query,
222+
:quotaUser => :query,
223+
:uploadType => :query,
224+
:upload_protocol => :query,
225+
:pageSize => :query,
226+
:pageToken => :query
227+
}
228+
229+
request =
230+
Request.new()
231+
|> Request.method(:get)
232+
|> Request.url("/v1alpha/{+parent}/sites", %{
233+
"parent" => URI.encode(parent, &URI.char_unreserved?/1)
234+
})
235+
|> Request.add_optional_params(optional_params_config, optional_params)
236+
|> Request.library_version(@library_version)
237+
238+
connection
239+
|> Connection.execute(request)
240+
|> Response.decode(
241+
opts ++ [struct: %GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse{}]
242+
)
243+
end
168244
end

clients/ad_sense_platform/lib/google_api/ad_sense_platform/v1alpha/metadata.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ defmodule GoogleApi.AdSensePlatform.V1alpha do
2020
API client metadata for GoogleApi.AdSensePlatform.V1alpha.
2121
"""
2222

23-
@discovery_revision "20250108"
23+
@discovery_revision "20250114"
2424

2525
def discovery_revision(), do: @discovery_revision
2626
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse do
19+
@moduledoc """
20+
Response definition for the list platform child sites rpc.
21+
22+
## Attributes
23+
24+
* `nextPageToken` (*type:* `String.t`, *default:* `nil`) - Continuation token used to page through platforms. To retrieve the next page of the results, set the next request's "page_token" value to this.
25+
* `platformChildSites` (*type:* `list(GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite.t)`, *default:* `nil`) - The platform child sites returned in this list response.
26+
"""
27+
28+
use GoogleApi.Gax.ModelBase
29+
30+
@type t :: %__MODULE__{
31+
:nextPageToken => String.t() | nil,
32+
:platformChildSites =>
33+
list(GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite.t()) | nil
34+
}
35+
36+
field(:nextPageToken)
37+
38+
field(:platformChildSites,
39+
as: GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite,
40+
type: :list
41+
)
42+
end
43+
44+
defimpl Poison.Decoder,
45+
for: GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse do
46+
def decode(value, options) do
47+
GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse.decode(value, options)
48+
end
49+
end
50+
51+
defimpl Poison.Encoder,
52+
for: GoogleApi.AdSensePlatform.V1alpha.Model.ListPlatformChildSitesResponse do
53+
def encode(value, options) do
54+
GoogleApi.Gax.ModelBase.encode(value, options)
55+
end
56+
end
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite do
19+
@moduledoc """
20+
Representation of a Transparent Platform Child Site.
21+
22+
## Attributes
23+
24+
* `domain` (*type:* `String.t`, *default:* `nil`) - Output only. Domain URL of the Platform Child Site. Part of the PlatformChildSite name.
25+
* `name` (*type:* `String.t`, *default:* `nil`) - Identifier. Format: accounts/{account}/platforms/{platform}/childAccounts/{child}/sites/{platformChildSite}
26+
* `platformGroup` (*type:* `String.t`, *default:* `nil`) - Resource name of the Platform Group of the Platform Child Site.
27+
"""
28+
29+
use GoogleApi.Gax.ModelBase
30+
31+
@type t :: %__MODULE__{
32+
:domain => String.t() | nil,
33+
:name => String.t() | nil,
34+
:platformGroup => String.t() | nil
35+
}
36+
37+
field(:domain)
38+
field(:name)
39+
field(:platformGroup)
40+
end
41+
42+
defimpl Poison.Decoder, for: GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite do
43+
def decode(value, options) do
44+
GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite.decode(value, options)
45+
end
46+
end
47+
48+
defimpl Poison.Encoder, for: GoogleApi.AdSensePlatform.V1alpha.Model.PlatformChildSite do
49+
def encode(value, options) do
50+
GoogleApi.Gax.ModelBase.encode(value, options)
51+
end
52+
end

0 commit comments

Comments
 (0)