admob
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Overview¶
Package admob provides access to the AdMob API.
For product documentation, see:https://developers.google.com/admob/api/
Library status¶
These client libraries are officially supported by Google. However, thislibrary is considered complete and is in maintenance mode. This meansthat we will address critical bugs and security issues but will not addany new features.
When possible, we recommend using our newer[Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)that are still actively being worked and iterated on.
Creating a client¶
Usage example:
import "google.golang.org/api/admob/v1beta"...ctx := context.Background()admobService, err := admob.NewService(ctx)
In this example, Google Application Default Credentials are used forauthentication. For information on how to create and obtain ApplicationDefault Credentials, seehttps://developers.google.com/identity/protocols/application-default-credentials.
Other authentication options¶
By default, all available scopes (see "Constants") are used to authenticate.To restrict scopes, usegoogle.golang.org/api/option.WithScopes:
admobService, err := admob.NewService(ctx, option.WithScopes(admob.AdmobReportScope))
To use an API key for authentication (note: some APIs do not support APIkeys), usegoogle.golang.org/api/option.WithAPIKey:
admobService, err := admob.NewService(ctx, option.WithAPIKey("AIza..."))To use an OAuth token (e.g., a user token obtained via a three-legged OAuthflow, usegoogle.golang.org/api/option.WithTokenSource:
config := &oauth2.Config{...}// ...token, err := config.Exchange(ctx, ...)admobService, err := admob.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))Seegoogle.golang.org/api/option.ClientOption for details on options.
Index¶
- Constants
- type AccountsAdSourcesAdaptersListCall
- func (c *AccountsAdSourcesAdaptersListCall) Context(ctx context.Context) *AccountsAdSourcesAdaptersListCall
- func (c *AccountsAdSourcesAdaptersListCall) Do(opts ...googleapi.CallOption) (*ListAdaptersResponse, error)
- func (c *AccountsAdSourcesAdaptersListCall) Fields(s ...googleapi.Field) *AccountsAdSourcesAdaptersListCall
- func (c *AccountsAdSourcesAdaptersListCall) Header() http.Header
- func (c *AccountsAdSourcesAdaptersListCall) IfNoneMatch(entityTag string) *AccountsAdSourcesAdaptersListCall
- func (c *AccountsAdSourcesAdaptersListCall) PageSize(pageSize int64) *AccountsAdSourcesAdaptersListCall
- func (c *AccountsAdSourcesAdaptersListCall) PageToken(pageToken string) *AccountsAdSourcesAdaptersListCall
- func (c *AccountsAdSourcesAdaptersListCall) Pages(ctx context.Context, f func(*ListAdaptersResponse) error) error
- type AccountsAdSourcesAdaptersService
- type AccountsAdSourcesListCall
- func (c *AccountsAdSourcesListCall) Context(ctx context.Context) *AccountsAdSourcesListCall
- func (c *AccountsAdSourcesListCall) Do(opts ...googleapi.CallOption) (*ListAdSourcesResponse, error)
- func (c *AccountsAdSourcesListCall) Fields(s ...googleapi.Field) *AccountsAdSourcesListCall
- func (c *AccountsAdSourcesListCall) Header() http.Header
- func (c *AccountsAdSourcesListCall) IfNoneMatch(entityTag string) *AccountsAdSourcesListCall
- func (c *AccountsAdSourcesListCall) PageSize(pageSize int64) *AccountsAdSourcesListCall
- func (c *AccountsAdSourcesListCall) PageToken(pageToken string) *AccountsAdSourcesListCall
- func (c *AccountsAdSourcesListCall) Pages(ctx context.Context, f func(*ListAdSourcesResponse) error) error
- type AccountsAdSourcesService
- type AccountsAdUnitMappingsBatchCreateCall
- func (c *AccountsAdUnitMappingsBatchCreateCall) Context(ctx context.Context) *AccountsAdUnitMappingsBatchCreateCall
- func (c *AccountsAdUnitMappingsBatchCreateCall) Do(opts ...googleapi.CallOption) (*BatchCreateAdUnitMappingsResponse, error)
- func (c *AccountsAdUnitMappingsBatchCreateCall) Fields(s ...googleapi.Field) *AccountsAdUnitMappingsBatchCreateCall
- func (c *AccountsAdUnitMappingsBatchCreateCall) Header() http.Header
- type AccountsAdUnitMappingsService
- type AccountsAdUnitsAdUnitMappingsCreateCall
- func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Context(ctx context.Context) *AccountsAdUnitsAdUnitMappingsCreateCall
- func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Do(opts ...googleapi.CallOption) (*AdUnitMapping, error)
- func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Fields(s ...googleapi.Field) *AccountsAdUnitsAdUnitMappingsCreateCall
- func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Header() http.Header
- type AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) Context(ctx context.Context) *AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) Do(opts ...googleapi.CallOption) (*ListAdUnitMappingsResponse, error)
- func (c *AccountsAdUnitsAdUnitMappingsListCall) Fields(s ...googleapi.Field) *AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) Filter(filter string) *AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) Header() http.Header
- func (c *AccountsAdUnitsAdUnitMappingsListCall) IfNoneMatch(entityTag string) *AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) PageSize(pageSize int64) *AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) PageToken(pageToken string) *AccountsAdUnitsAdUnitMappingsListCall
- func (c *AccountsAdUnitsAdUnitMappingsListCall) Pages(ctx context.Context, f func(*ListAdUnitMappingsResponse) error) error
- type AccountsAdUnitsAdUnitMappingsService
- type AccountsAdUnitsCreateCall
- func (c *AccountsAdUnitsCreateCall) Context(ctx context.Context) *AccountsAdUnitsCreateCall
- func (c *AccountsAdUnitsCreateCall) Do(opts ...googleapi.CallOption) (*AdUnit, error)
- func (c *AccountsAdUnitsCreateCall) Fields(s ...googleapi.Field) *AccountsAdUnitsCreateCall
- func (c *AccountsAdUnitsCreateCall) Header() http.Header
- type AccountsAdUnitsListCall
- func (c *AccountsAdUnitsListCall) Context(ctx context.Context) *AccountsAdUnitsListCall
- func (c *AccountsAdUnitsListCall) Do(opts ...googleapi.CallOption) (*ListAdUnitsResponse, error)
- func (c *AccountsAdUnitsListCall) Fields(s ...googleapi.Field) *AccountsAdUnitsListCall
- func (c *AccountsAdUnitsListCall) Header() http.Header
- func (c *AccountsAdUnitsListCall) IfNoneMatch(entityTag string) *AccountsAdUnitsListCall
- func (c *AccountsAdUnitsListCall) PageSize(pageSize int64) *AccountsAdUnitsListCall
- func (c *AccountsAdUnitsListCall) PageToken(pageToken string) *AccountsAdUnitsListCall
- func (c *AccountsAdUnitsListCall) Pages(ctx context.Context, f func(*ListAdUnitsResponse) error) error
- type AccountsAdUnitsService
- type AccountsAppsCreateCall
- func (c *AccountsAppsCreateCall) Context(ctx context.Context) *AccountsAppsCreateCall
- func (c *AccountsAppsCreateCall) Do(opts ...googleapi.CallOption) (*App, error)
- func (c *AccountsAppsCreateCall) Fields(s ...googleapi.Field) *AccountsAppsCreateCall
- func (c *AccountsAppsCreateCall) Header() http.Header
- type AccountsAppsListCall
- func (c *AccountsAppsListCall) Context(ctx context.Context) *AccountsAppsListCall
- func (c *AccountsAppsListCall) Do(opts ...googleapi.CallOption) (*ListAppsResponse, error)
- func (c *AccountsAppsListCall) Fields(s ...googleapi.Field) *AccountsAppsListCall
- func (c *AccountsAppsListCall) Header() http.Header
- func (c *AccountsAppsListCall) IfNoneMatch(entityTag string) *AccountsAppsListCall
- func (c *AccountsAppsListCall) PageSize(pageSize int64) *AccountsAppsListCall
- func (c *AccountsAppsListCall) PageToken(pageToken string) *AccountsAppsListCall
- func (c *AccountsAppsListCall) Pages(ctx context.Context, f func(*ListAppsResponse) error) error
- type AccountsAppsService
- type AccountsCampaignReportGenerateCall
- func (c *AccountsCampaignReportGenerateCall) Context(ctx context.Context) *AccountsCampaignReportGenerateCall
- func (c *AccountsCampaignReportGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateCampaignReportResponse, error)
- func (c *AccountsCampaignReportGenerateCall) Fields(s ...googleapi.Field) *AccountsCampaignReportGenerateCall
- func (c *AccountsCampaignReportGenerateCall) Header() http.Header
- type AccountsCampaignReportService
- type AccountsGetCall
- func (c *AccountsGetCall) Context(ctx context.Context) *AccountsGetCall
- func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*PublisherAccount, error)
- func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall
- func (c *AccountsGetCall) Header() http.Header
- func (c *AccountsGetCall) IfNoneMatch(entityTag string) *AccountsGetCall
- type AccountsListCall
- func (c *AccountsListCall) Context(ctx context.Context) *AccountsListCall
- func (c *AccountsListCall) Do(opts ...googleapi.CallOption) (*ListPublisherAccountsResponse, error)
- func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall
- func (c *AccountsListCall) Header() http.Header
- func (c *AccountsListCall) IfNoneMatch(entityTag string) *AccountsListCall
- func (c *AccountsListCall) PageSize(pageSize int64) *AccountsListCall
- func (c *AccountsListCall) PageToken(pageToken string) *AccountsListCall
- func (c *AccountsListCall) Pages(ctx context.Context, f func(*ListPublisherAccountsResponse) error) error
- type AccountsMediationGroupsCreateCall
- func (c *AccountsMediationGroupsCreateCall) Context(ctx context.Context) *AccountsMediationGroupsCreateCall
- func (c *AccountsMediationGroupsCreateCall) Do(opts ...googleapi.CallOption) (*MediationGroup, error)
- func (c *AccountsMediationGroupsCreateCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsCreateCall
- func (c *AccountsMediationGroupsCreateCall) Header() http.Header
- type AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) Context(ctx context.Context) *AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) Do(opts ...googleapi.CallOption) (*ListMediationGroupsResponse, error)
- func (c *AccountsMediationGroupsListCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) Filter(filter string) *AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) Header() http.Header
- func (c *AccountsMediationGroupsListCall) IfNoneMatch(entityTag string) *AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) PageSize(pageSize int64) *AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) PageToken(pageToken string) *AccountsMediationGroupsListCall
- func (c *AccountsMediationGroupsListCall) Pages(ctx context.Context, f func(*ListMediationGroupsResponse) error) error
- type AccountsMediationGroupsMediationAbExperimentsCreateCall
- func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Context(ctx context.Context) *AccountsMediationGroupsMediationAbExperimentsCreateCall
- func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Do(opts ...googleapi.CallOption) (*MediationAbExperiment, error)
- func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsMediationAbExperimentsCreateCall
- func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Header() http.Header
- type AccountsMediationGroupsMediationAbExperimentsService
- func (r *AccountsMediationGroupsMediationAbExperimentsService) Create(parent string, mediationabexperiment *MediationAbExperiment) *AccountsMediationGroupsMediationAbExperimentsCreateCall
- func (r *AccountsMediationGroupsMediationAbExperimentsService) Stop(name string, ...) *AccountsMediationGroupsMediationAbExperimentsStopCall
- type AccountsMediationGroupsMediationAbExperimentsStopCall
- func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Context(ctx context.Context) *AccountsMediationGroupsMediationAbExperimentsStopCall
- func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Do(opts ...googleapi.CallOption) (*MediationAbExperiment, error)
- func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsMediationAbExperimentsStopCall
- func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Header() http.Header
- type AccountsMediationGroupsPatchCall
- func (c *AccountsMediationGroupsPatchCall) Context(ctx context.Context) *AccountsMediationGroupsPatchCall
- func (c *AccountsMediationGroupsPatchCall) Do(opts ...googleapi.CallOption) (*MediationGroup, error)
- func (c *AccountsMediationGroupsPatchCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsPatchCall
- func (c *AccountsMediationGroupsPatchCall) Header() http.Header
- func (c *AccountsMediationGroupsPatchCall) UpdateMask(updateMask string) *AccountsMediationGroupsPatchCall
- type AccountsMediationGroupsService
- func (r *AccountsMediationGroupsService) Create(parent string, mediationgroup *MediationGroup) *AccountsMediationGroupsCreateCall
- func (r *AccountsMediationGroupsService) List(parent string) *AccountsMediationGroupsListCall
- func (r *AccountsMediationGroupsService) Patch(name string, mediationgroup *MediationGroup) *AccountsMediationGroupsPatchCall
- type AccountsMediationReportGenerateCall
- func (c *AccountsMediationReportGenerateCall) Context(ctx context.Context) *AccountsMediationReportGenerateCall
- func (c *AccountsMediationReportGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateMediationReportResponse, error)
- func (c *AccountsMediationReportGenerateCall) Fields(s ...googleapi.Field) *AccountsMediationReportGenerateCall
- func (c *AccountsMediationReportGenerateCall) Header() http.Header
- type AccountsMediationReportService
- type AccountsNetworkReportGenerateCall
- func (c *AccountsNetworkReportGenerateCall) Context(ctx context.Context) *AccountsNetworkReportGenerateCall
- func (c *AccountsNetworkReportGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateNetworkReportResponse, error)
- func (c *AccountsNetworkReportGenerateCall) Fields(s ...googleapi.Field) *AccountsNetworkReportGenerateCall
- func (c *AccountsNetworkReportGenerateCall) Header() http.Header
- type AccountsNetworkReportService
- type AccountsService
- type AdSource
- type AdUnit
- type AdUnitMapping
- type AdUnitRewardSettings
- type Adapter
- type AdapterAdapterConfigMetadata
- type App
- type AppLinkedAppInfo
- type AppManualAppInfo
- type BatchCreateAdUnitMappingsRequest
- type BatchCreateAdUnitMappingsResponse
- type CampaignReportSpec
- type CreateAdUnitMappingRequest
- type Date
- type DateRange
- type GenerateCampaignReportRequest
- type GenerateCampaignReportResponse
- type GenerateMediationReportRequest
- type GenerateMediationReportResponse
- type GenerateNetworkReportRequest
- type GenerateNetworkReportResponse
- type ListAdSourcesResponse
- type ListAdUnitMappingsResponse
- type ListAdUnitsResponse
- type ListAdaptersResponse
- type ListAppsResponse
- type ListMediationGroupsResponse
- type ListPublisherAccountsResponse
- type LocalizationSettings
- type MediationAbExperiment
- type MediationAbExperimentExperimentMediationLine
- type MediationGroup
- type MediationGroupMediationGroupLine
- type MediationGroupTargeting
- type MediationReportSpec
- type MediationReportSpecDimensionFilter
- type MediationReportSpecSortCondition
- type NetworkReportSpec
- type NetworkReportSpecDimensionFilter
- type NetworkReportSpecSortCondition
- type PublisherAccount
- type ReportFooter
- type ReportHeader
- type ReportRow
- type ReportRowDimensionValue
- type ReportRowMetricValue
- type ReportWarning
- type Service
- type StopMediationAbExperimentRequest
- type StringList
Constants¶
const (// See your AdMob dataAdmobReadonlyScope = "https://www.googleapis.com/auth/admob.readonly"// See your AdMob dataAdmobReportScope = "https://www.googleapis.com/auth/admob.report")
OAuth2 scopes used by this API.
Variables¶
This section is empty.
Functions¶
This section is empty.
Types¶
typeAccountsAdSourcesAdaptersListCall¶added inv0.139.0
type AccountsAdSourcesAdaptersListCall struct {// contains filtered or unexported fields}func (*AccountsAdSourcesAdaptersListCall)Context¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) Context(ctxcontext.Context) *AccountsAdSourcesAdaptersListCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdSourcesAdaptersListCall)Do¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) Do(opts ...googleapi.CallOption) (*ListAdaptersResponse,error)
Do executes the "admob.accounts.adSources.adapters.list" call.Any non-2xx status code is an error. Response headers are in either*ListAdaptersResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsAdSourcesAdaptersListCall)Fields¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) Fields(s ...googleapi.Field) *AccountsAdSourcesAdaptersListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdSourcesAdaptersListCall)Header¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsAdSourcesAdaptersListCall)IfNoneMatch¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) IfNoneMatch(entityTagstring) *AccountsAdSourcesAdaptersListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsAdSourcesAdaptersListCall)PageSize¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) PageSize(pageSizeint64) *AccountsAdSourcesAdaptersListCall
PageSize sets the optional parameter "pageSize": The maximum number ofadapters to return. If unspecified or 0, at most 10,000 adapters will bereturned. The maximum value is 20,000; values above 20,000 will be coercedto 20,000.
func (*AccountsAdSourcesAdaptersListCall)PageToken¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) PageToken(pageTokenstring) *AccountsAdSourcesAdaptersListCall
PageToken sets the optional parameter "pageToken": A page token, receivedfrom a previous `ListAdapters` call. Provide this to retrieve the subsequentpage.
func (*AccountsAdSourcesAdaptersListCall)Pages¶added inv0.139.0
func (c *AccountsAdSourcesAdaptersListCall) Pages(ctxcontext.Context, f func(*ListAdaptersResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsAdSourcesAdaptersService¶added inv0.139.0
type AccountsAdSourcesAdaptersService struct {// contains filtered or unexported fields}funcNewAccountsAdSourcesAdaptersService¶added inv0.139.0
func NewAccountsAdSourcesAdaptersService(s *Service) *AccountsAdSourcesAdaptersService
func (*AccountsAdSourcesAdaptersService)List¶added inv0.139.0
func (r *AccountsAdSourcesAdaptersService) List(parentstring) *AccountsAdSourcesAdaptersListCall
List: List the adapters of the ad source.
- parent: The parent which owns this collection of adapters. Format:accounts/{publisher_id}/adSources/{ad_source_id}.
typeAccountsAdSourcesListCall¶added inv0.78.0
type AccountsAdSourcesListCall struct {// contains filtered or unexported fields}func (*AccountsAdSourcesListCall)Context¶added inv0.78.0
func (c *AccountsAdSourcesListCall) Context(ctxcontext.Context) *AccountsAdSourcesListCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdSourcesListCall)Do¶added inv0.78.0
func (c *AccountsAdSourcesListCall) Do(opts ...googleapi.CallOption) (*ListAdSourcesResponse,error)
Do executes the "admob.accounts.adSources.list" call.Any non-2xx status code is an error. Response headers are in either*ListAdSourcesResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsAdSourcesListCall)Fields¶added inv0.78.0
func (c *AccountsAdSourcesListCall) Fields(s ...googleapi.Field) *AccountsAdSourcesListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdSourcesListCall)Header¶added inv0.78.0
func (c *AccountsAdSourcesListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsAdSourcesListCall)IfNoneMatch¶added inv0.78.0
func (c *AccountsAdSourcesListCall) IfNoneMatch(entityTagstring) *AccountsAdSourcesListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsAdSourcesListCall)PageSize¶added inv0.78.0
func (c *AccountsAdSourcesListCall) PageSize(pageSizeint64) *AccountsAdSourcesListCall
PageSize sets the optional parameter "pageSize": The maximum number of adsources to return. If unspecified or 0, at most 10,000 ad sources will bereturned. The maximum value is 20,000; values above 10,000 will be coercedto 20,000.
func (*AccountsAdSourcesListCall)PageToken¶added inv0.78.0
func (c *AccountsAdSourcesListCall) PageToken(pageTokenstring) *AccountsAdSourcesListCall
PageToken sets the optional parameter "pageToken": A page token, receivedfrom a previous `ListAdSources` call. Provide this to retrieve thesubsequent page.
func (*AccountsAdSourcesListCall)Pages¶added inv0.78.0
func (c *AccountsAdSourcesListCall) Pages(ctxcontext.Context, f func(*ListAdSourcesResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsAdSourcesService¶added inv0.78.0
type AccountsAdSourcesService struct {Adapters *AccountsAdSourcesAdaptersService// contains filtered or unexported fields}funcNewAccountsAdSourcesService¶added inv0.78.0
func NewAccountsAdSourcesService(s *Service) *AccountsAdSourcesService
func (*AccountsAdSourcesService)List¶added inv0.78.0
func (r *AccountsAdSourcesService) List(parentstring) *AccountsAdSourcesListCall
List: List the ad sources.
- parent: The parent which owns this collection of ad sources. Format:accounts/{publisher_id}.
typeAccountsAdUnitMappingsBatchCreateCall¶added inv0.139.0
type AccountsAdUnitMappingsBatchCreateCall struct {// contains filtered or unexported fields}func (*AccountsAdUnitMappingsBatchCreateCall)Context¶added inv0.139.0
func (c *AccountsAdUnitMappingsBatchCreateCall) Context(ctxcontext.Context) *AccountsAdUnitMappingsBatchCreateCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdUnitMappingsBatchCreateCall)Do¶added inv0.139.0
func (c *AccountsAdUnitMappingsBatchCreateCall) Do(opts ...googleapi.CallOption) (*BatchCreateAdUnitMappingsResponse,error)
Do executes the "admob.accounts.adUnitMappings.batchCreate" call.Any non-2xx status code is an error. Response headers are in either*BatchCreateAdUnitMappingsResponse.ServerResponse.Header or (if a responsewas returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsAdUnitMappingsBatchCreateCall)Fields¶added inv0.139.0
func (c *AccountsAdUnitMappingsBatchCreateCall) Fields(s ...googleapi.Field) *AccountsAdUnitMappingsBatchCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdUnitMappingsBatchCreateCall)Header¶added inv0.139.0
func (c *AccountsAdUnitMappingsBatchCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsAdUnitMappingsService¶added inv0.139.0
type AccountsAdUnitMappingsService struct {// contains filtered or unexported fields}funcNewAccountsAdUnitMappingsService¶added inv0.139.0
func NewAccountsAdUnitMappingsService(s *Service) *AccountsAdUnitMappingsService
func (*AccountsAdUnitMappingsService)BatchCreate¶added inv0.139.0
func (r *AccountsAdUnitMappingsService) BatchCreate(parentstring, batchcreateadunitmappingsrequest *BatchCreateAdUnitMappingsRequest) *AccountsAdUnitMappingsBatchCreateCall
BatchCreate: Batch create the ad unit mappings under the specific AdMobaccount. The maximum allowed batch size is 100. This method has limitedaccess. If you see a 403 permission denied error, please reach out to youraccount manager for access.
- parent: The AdMob account which owns this collection of ad unit mappings.Format: accounts/{publisher_id} Seehttps://support.google.com/admob/answer/2784578 for instructions on how tofind your AdMob publisher ID.
typeAccountsAdUnitsAdUnitMappingsCreateCall¶added inv0.139.0
type AccountsAdUnitsAdUnitMappingsCreateCall struct {// contains filtered or unexported fields}func (*AccountsAdUnitsAdUnitMappingsCreateCall)Context¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Context(ctxcontext.Context) *AccountsAdUnitsAdUnitMappingsCreateCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdUnitsAdUnitMappingsCreateCall)Do¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Do(opts ...googleapi.CallOption) (*AdUnitMapping,error)
Do executes the "admob.accounts.adUnits.adUnitMappings.create" call.Any non-2xx status code is an error. Response headers are in either*AdUnitMapping.ServerResponse.Header or (if a response was returned at all)in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*AccountsAdUnitsAdUnitMappingsCreateCall)Fields¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Fields(s ...googleapi.Field) *AccountsAdUnitsAdUnitMappingsCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdUnitsAdUnitMappingsCreateCall)Header¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsAdUnitsAdUnitMappingsListCall¶added inv0.139.0
type AccountsAdUnitsAdUnitMappingsListCall struct {// contains filtered or unexported fields}func (*AccountsAdUnitsAdUnitMappingsListCall)Context¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) Context(ctxcontext.Context) *AccountsAdUnitsAdUnitMappingsListCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdUnitsAdUnitMappingsListCall)Do¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) Do(opts ...googleapi.CallOption) (*ListAdUnitMappingsResponse,error)
Do executes the "admob.accounts.adUnits.adUnitMappings.list" call.Any non-2xx status code is an error. Response headers are in either*ListAdUnitMappingsResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsAdUnitsAdUnitMappingsListCall)Fields¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) Fields(s ...googleapi.Field) *AccountsAdUnitsAdUnitMappingsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdUnitsAdUnitMappingsListCall)Filter¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) Filter(filterstring) *AccountsAdUnitsAdUnitMappingsListCall
Filter sets the optional parameter "filter": The filter string that usesEBNF grammar syntax (https://google.aip.dev/assets/misc/ebnf-filtering.txt).Possible field to filter by is: - "DISPLAY_NAME" Possible filter functionis: - `IN`: Used to filter fields that represent a singleton including"DISPLAY_NAME". The filter functions can be added together using `AND`. `OR`functionality is not supported. Example: filter: IN(DISPLAY_NAME, "Test AdUnit Mapping 1", "Test Ad Unit Mapping 2")
func (*AccountsAdUnitsAdUnitMappingsListCall)Header¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsAdUnitsAdUnitMappingsListCall)IfNoneMatch¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) IfNoneMatch(entityTagstring) *AccountsAdUnitsAdUnitMappingsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsAdUnitsAdUnitMappingsListCall)PageSize¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) PageSize(pageSizeint64) *AccountsAdUnitsAdUnitMappingsListCall
PageSize sets the optional parameter "pageSize": The maximum number of adunit mappings to return. If unspecified or 0, at most 10,000 ad unitmappings will be returned. The maximum value is 20,000; values above 20,000will be coerced to 20,000.
func (*AccountsAdUnitsAdUnitMappingsListCall)PageToken¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) PageToken(pageTokenstring) *AccountsAdUnitsAdUnitMappingsListCall
PageToken sets the optional parameter "pageToken": A page token, receivedfrom a previous `ListAdUnitMappings` call. Provide this to retrieve thesubsequent page.
func (*AccountsAdUnitsAdUnitMappingsListCall)Pages¶added inv0.139.0
func (c *AccountsAdUnitsAdUnitMappingsListCall) Pages(ctxcontext.Context, f func(*ListAdUnitMappingsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsAdUnitsAdUnitMappingsService¶added inv0.139.0
type AccountsAdUnitsAdUnitMappingsService struct {// contains filtered or unexported fields}funcNewAccountsAdUnitsAdUnitMappingsService¶added inv0.139.0
func NewAccountsAdUnitsAdUnitMappingsService(s *Service) *AccountsAdUnitsAdUnitMappingsService
func (*AccountsAdUnitsAdUnitMappingsService)Create¶added inv0.139.0
func (r *AccountsAdUnitsAdUnitMappingsService) Create(parentstring, adunitmapping *AdUnitMapping) *AccountsAdUnitsAdUnitMappingsCreateCall
Create: Create an ad unit mapping under the specific AdMob account and adunit. This method has limited access. If you see a 403 permission deniederror, please reach out to your account manager for access.
- parent: The parent which owns the ad unit mapping. Format:accounts/{publisher_id}/adUnits/{ad_unit_id}.
func (*AccountsAdUnitsAdUnitMappingsService)List¶added inv0.139.0
func (r *AccountsAdUnitsAdUnitMappingsService) List(parentstring) *AccountsAdUnitsAdUnitMappingsListCall
List: List ad unit mappings under the specified AdMob account and ad unit.This method has limited access. If you see a 403 permission denied error,please reach out to your account manager for access.
- parent: The parent which owns this collection of ad unit mappings. Format:accounts/{publisher_id}/adUnits/{ad_unit_id}.
typeAccountsAdUnitsCreateCall¶added inv0.139.0
type AccountsAdUnitsCreateCall struct {// contains filtered or unexported fields}func (*AccountsAdUnitsCreateCall)Context¶added inv0.139.0
func (c *AccountsAdUnitsCreateCall) Context(ctxcontext.Context) *AccountsAdUnitsCreateCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdUnitsCreateCall)Do¶added inv0.139.0
func (c *AccountsAdUnitsCreateCall) Do(opts ...googleapi.CallOption) (*AdUnit,error)
Do executes the "admob.accounts.adUnits.create" call.Any non-2xx status code is an error. Response headers are in either*AdUnit.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*AccountsAdUnitsCreateCall)Fields¶added inv0.139.0
func (c *AccountsAdUnitsCreateCall) Fields(s ...googleapi.Field) *AccountsAdUnitsCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdUnitsCreateCall)Header¶added inv0.139.0
func (c *AccountsAdUnitsCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsAdUnitsListCall¶
type AccountsAdUnitsListCall struct {// contains filtered or unexported fields}func (*AccountsAdUnitsListCall)Context¶
func (c *AccountsAdUnitsListCall) Context(ctxcontext.Context) *AccountsAdUnitsListCall
Context sets the context to be used in this call's Do method.
func (*AccountsAdUnitsListCall)Do¶
func (c *AccountsAdUnitsListCall) Do(opts ...googleapi.CallOption) (*ListAdUnitsResponse,error)
Do executes the "admob.accounts.adUnits.list" call.Any non-2xx status code is an error. Response headers are in either*ListAdUnitsResponse.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsAdUnitsListCall)Fields¶
func (c *AccountsAdUnitsListCall) Fields(s ...googleapi.Field) *AccountsAdUnitsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAdUnitsListCall)Header¶
func (c *AccountsAdUnitsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsAdUnitsListCall)IfNoneMatch¶
func (c *AccountsAdUnitsListCall) IfNoneMatch(entityTagstring) *AccountsAdUnitsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsAdUnitsListCall)PageSize¶
func (c *AccountsAdUnitsListCall) PageSize(pageSizeint64) *AccountsAdUnitsListCall
PageSize sets the optional parameter "pageSize": The maximum number of adunits to return. If unspecified or 0, at most 10,000 ad units will bereturned. The maximum value is 20,000; values above 20,000 will be coercedto 20,000.
func (*AccountsAdUnitsListCall)PageToken¶
func (c *AccountsAdUnitsListCall) PageToken(pageTokenstring) *AccountsAdUnitsListCall
PageToken sets the optional parameter "pageToken": The value returned by thelast `ListAdUnitsResponse`; indicates that this is a continuation of a prior`ListAdUnits` call, and that the system should return the next page of data.
func (*AccountsAdUnitsListCall)Pages¶
func (c *AccountsAdUnitsListCall) Pages(ctxcontext.Context, f func(*ListAdUnitsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsAdUnitsService¶
type AccountsAdUnitsService struct {AdUnitMappings *AccountsAdUnitsAdUnitMappingsService// contains filtered or unexported fields}funcNewAccountsAdUnitsService¶
func NewAccountsAdUnitsService(s *Service) *AccountsAdUnitsService
func (*AccountsAdUnitsService)Create¶added inv0.139.0
func (r *AccountsAdUnitsService) Create(parentstring, adunit *AdUnit) *AccountsAdUnitsCreateCall
Create: Creates an ad unit under the specified AdMob account. This methodhas limited access. If you see a 403 permission denied error, please reachout to your account manager for access.
- parent: Resource name of the account to create the specified ad unit for.Example: accounts/pub-9876543210987654.
func (*AccountsAdUnitsService)List¶
func (r *AccountsAdUnitsService) List(parentstring) *AccountsAdUnitsListCall
List: List the ad units under the specified AdMob account.
- parent: Resource name of the account to list ad units for. Example:accounts/pub-9876543210987654.
typeAccountsAppsCreateCall¶added inv0.139.0
type AccountsAppsCreateCall struct {// contains filtered or unexported fields}func (*AccountsAppsCreateCall)Context¶added inv0.139.0
func (c *AccountsAppsCreateCall) Context(ctxcontext.Context) *AccountsAppsCreateCall
Context sets the context to be used in this call's Do method.
func (*AccountsAppsCreateCall)Do¶added inv0.139.0
func (c *AccountsAppsCreateCall) Do(opts ...googleapi.CallOption) (*App,error)
Do executes the "admob.accounts.apps.create" call.Any non-2xx status code is an error. Response headers are in either*App.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*AccountsAppsCreateCall)Fields¶added inv0.139.0
func (c *AccountsAppsCreateCall) Fields(s ...googleapi.Field) *AccountsAppsCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAppsCreateCall)Header¶added inv0.139.0
func (c *AccountsAppsCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsAppsListCall¶
type AccountsAppsListCall struct {// contains filtered or unexported fields}func (*AccountsAppsListCall)Context¶
func (c *AccountsAppsListCall) Context(ctxcontext.Context) *AccountsAppsListCall
Context sets the context to be used in this call's Do method.
func (*AccountsAppsListCall)Do¶
func (c *AccountsAppsListCall) Do(opts ...googleapi.CallOption) (*ListAppsResponse,error)
Do executes the "admob.accounts.apps.list" call.Any non-2xx status code is an error. Response headers are in either*ListAppsResponse.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsAppsListCall)Fields¶
func (c *AccountsAppsListCall) Fields(s ...googleapi.Field) *AccountsAppsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsAppsListCall)Header¶
func (c *AccountsAppsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsAppsListCall)IfNoneMatch¶
func (c *AccountsAppsListCall) IfNoneMatch(entityTagstring) *AccountsAppsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsAppsListCall)PageSize¶
func (c *AccountsAppsListCall) PageSize(pageSizeint64) *AccountsAppsListCall
PageSize sets the optional parameter "pageSize": The maximum number of appsto return. If unspecified or 0, at most 10,000 apps will be returned. Themaximum value is 20,000; values above 20,000 will be coerced to 20,000.
func (*AccountsAppsListCall)PageToken¶
func (c *AccountsAppsListCall) PageToken(pageTokenstring) *AccountsAppsListCall
PageToken sets the optional parameter "pageToken": The value returned by thelast `ListAppsResponse`; indicates that this is a continuation of a prior`ListApps` call, and that the system should return the next page of data.
func (*AccountsAppsListCall)Pages¶
func (c *AccountsAppsListCall) Pages(ctxcontext.Context, f func(*ListAppsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsAppsService¶
type AccountsAppsService struct {// contains filtered or unexported fields}funcNewAccountsAppsService¶
func NewAccountsAppsService(s *Service) *AccountsAppsService
func (*AccountsAppsService)Create¶added inv0.139.0
func (r *AccountsAppsService) Create(parentstring, app *App) *AccountsAppsCreateCall
Create: Creates an app under the specified AdMob account. This method haslimited access. If you see a 403 permission denied error, please reach outto your account manager for access.
- parent: Resource name of the account for which the app is being created.Example: accounts/pub-9876543210987654.
func (*AccountsAppsService)List¶
func (r *AccountsAppsService) List(parentstring) *AccountsAppsListCall
List: List the apps under the specified AdMob account.
- parent: Resource name of the account to list apps for. Example:accounts/pub-9876543210987654.
typeAccountsCampaignReportGenerateCall¶added inv0.139.0
type AccountsCampaignReportGenerateCall struct {// contains filtered or unexported fields}func (*AccountsCampaignReportGenerateCall)Context¶added inv0.139.0
func (c *AccountsCampaignReportGenerateCall) Context(ctxcontext.Context) *AccountsCampaignReportGenerateCall
Context sets the context to be used in this call's Do method.
func (*AccountsCampaignReportGenerateCall)Do¶added inv0.139.0
func (c *AccountsCampaignReportGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateCampaignReportResponse,error)
Do executes the "admob.accounts.campaignReport.generate" call.Any non-2xx status code is an error. Response headers are in either*GenerateCampaignReportResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsCampaignReportGenerateCall)Fields¶added inv0.139.0
func (c *AccountsCampaignReportGenerateCall) Fields(s ...googleapi.Field) *AccountsCampaignReportGenerateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsCampaignReportGenerateCall)Header¶added inv0.139.0
func (c *AccountsCampaignReportGenerateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsCampaignReportService¶added inv0.139.0
type AccountsCampaignReportService struct {// contains filtered or unexported fields}funcNewAccountsCampaignReportService¶added inv0.139.0
func NewAccountsCampaignReportService(s *Service) *AccountsCampaignReportService
func (*AccountsCampaignReportService)Generate¶added inv0.139.0
func (r *AccountsCampaignReportService) Generate(parentstring, generatecampaignreportrequest *GenerateCampaignReportRequest) *AccountsCampaignReportGenerateCall
Generate: Generates Campaign Report based on provided specifications.
- parent: Resource name of the account to generate the report for. Example:accounts/pub-9876543210987654.
typeAccountsGetCall¶
type AccountsGetCall struct {// contains filtered or unexported fields}func (*AccountsGetCall)Context¶
func (c *AccountsGetCall) Context(ctxcontext.Context) *AccountsGetCall
Context sets the context to be used in this call's Do method.
func (*AccountsGetCall)Do¶
func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*PublisherAccount,error)
Do executes the "admob.accounts.get" call.Any non-2xx status code is an error. Response headers are in either*PublisherAccount.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsGetCall)Fields¶
func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsGetCall)Header¶
func (c *AccountsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsGetCall)IfNoneMatch¶
func (c *AccountsGetCall) IfNoneMatch(entityTagstring) *AccountsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeAccountsListCall¶
type AccountsListCall struct {// contains filtered or unexported fields}func (*AccountsListCall)Context¶
func (c *AccountsListCall) Context(ctxcontext.Context) *AccountsListCall
Context sets the context to be used in this call's Do method.
func (*AccountsListCall)Do¶
func (c *AccountsListCall) Do(opts ...googleapi.CallOption) (*ListPublisherAccountsResponse,error)
Do executes the "admob.accounts.list" call.Any non-2xx status code is an error. Response headers are in either*ListPublisherAccountsResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsListCall)Fields¶
func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsListCall)Header¶
func (c *AccountsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsListCall)IfNoneMatch¶
func (c *AccountsListCall) IfNoneMatch(entityTagstring) *AccountsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsListCall)PageSize¶
func (c *AccountsListCall) PageSize(pageSizeint64) *AccountsListCall
PageSize sets the optional parameter "pageSize": Maximum number of accountsto return.
func (*AccountsListCall)PageToken¶
func (c *AccountsListCall) PageToken(pageTokenstring) *AccountsListCall
PageToken sets the optional parameter "pageToken": The value returned by thelast `ListPublisherAccountsResponse`; indicates that this is a continuationof a prior `ListPublisherAccounts` call, and that the system should returnthe next page of data.
func (*AccountsListCall)Pages¶
func (c *AccountsListCall) Pages(ctxcontext.Context, f func(*ListPublisherAccountsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsMediationGroupsCreateCall¶added inv0.139.0
type AccountsMediationGroupsCreateCall struct {// contains filtered or unexported fields}func (*AccountsMediationGroupsCreateCall)Context¶added inv0.139.0
func (c *AccountsMediationGroupsCreateCall) Context(ctxcontext.Context) *AccountsMediationGroupsCreateCall
Context sets the context to be used in this call's Do method.
func (*AccountsMediationGroupsCreateCall)Do¶added inv0.139.0
func (c *AccountsMediationGroupsCreateCall) Do(opts ...googleapi.CallOption) (*MediationGroup,error)
Do executes the "admob.accounts.mediationGroups.create" call.Any non-2xx status code is an error. Response headers are in either*MediationGroup.ServerResponse.Header or (if a response was returned at all)in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*AccountsMediationGroupsCreateCall)Fields¶added inv0.139.0
func (c *AccountsMediationGroupsCreateCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsMediationGroupsCreateCall)Header¶added inv0.139.0
func (c *AccountsMediationGroupsCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsMediationGroupsListCall¶added inv0.139.0
type AccountsMediationGroupsListCall struct {// contains filtered or unexported fields}func (*AccountsMediationGroupsListCall)Context¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) Context(ctxcontext.Context) *AccountsMediationGroupsListCall
Context sets the context to be used in this call's Do method.
func (*AccountsMediationGroupsListCall)Do¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) Do(opts ...googleapi.CallOption) (*ListMediationGroupsResponse,error)
Do executes the "admob.accounts.mediationGroups.list" call.Any non-2xx status code is an error. Response headers are in either*ListMediationGroupsResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsMediationGroupsListCall)Fields¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsMediationGroupsListCall)Filter¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) Filter(filterstring) *AccountsMediationGroupsListCall
Filter sets the optional parameter "filter": The filter string that usesEBNF grammar syntax (https://google.aip.dev/assets/misc/ebnf-filtering.txt).Possible fields to filter by are: - "AD_SOURCE_IDS" - "AD_UNIT_IDS" -"APP_IDS" - "DISPLAY_NAME" - "FORMAT" - "MEDIATION_GROUP_ID" - "PLATFORM" -"STATE" - "TARGETED_REGION_CODES" Possible filter functions are: - `IN`:Used to filter fields that represent a singleton including"MEDIATION_GROUP_ID", "DISPLAY_NAME", "STATE", "PLATFORM", and "FORMAT". -`CONTAINS_ANY`: Used to filter fields that represent a collection including"AD_SOURCE_IDS", "AD_UNIT_IDS", "APP_IDS", and "TARGETED_REGION_CODES". Thefilter functions can be added together using `AND`. `OR` functionality isnot supported. Example: filter: IN(DISPLAY_NAME, "Test Group 1", "Test Group2") AND IN(PLATFORM, "ANDROID") AND CONTAINS_ANY(AD_SOURCE_IDS,"5450213213286189855")
func (*AccountsMediationGroupsListCall)Header¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsMediationGroupsListCall)IfNoneMatch¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) IfNoneMatch(entityTagstring) *AccountsMediationGroupsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*AccountsMediationGroupsListCall)PageSize¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) PageSize(pageSizeint64) *AccountsMediationGroupsListCall
PageSize sets the optional parameter "pageSize": The maximum number ofmediation groups to return. If unspecified or 0, at most 10,000 mediationgroups will be returned. The maximum value is 20,000; values above 20,000will be coerced to 20,000.
func (*AccountsMediationGroupsListCall)PageToken¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) PageToken(pageTokenstring) *AccountsMediationGroupsListCall
PageToken sets the optional parameter "pageToken": The value returned by thelast `ListMediationGroupsResponse`; indicates that this is a continuation ofa prior `ListMediationGroups` call, and that the system should return thenext page of data.
func (*AccountsMediationGroupsListCall)Pages¶added inv0.139.0
func (c *AccountsMediationGroupsListCall) Pages(ctxcontext.Context, f func(*ListMediationGroupsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeAccountsMediationGroupsMediationAbExperimentsCreateCall¶added inv0.139.0
type AccountsMediationGroupsMediationAbExperimentsCreateCall struct {// contains filtered or unexported fields}func (*AccountsMediationGroupsMediationAbExperimentsCreateCall)Context¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Context(ctxcontext.Context) *AccountsMediationGroupsMediationAbExperimentsCreateCall
Context sets the context to be used in this call's Do method.
func (*AccountsMediationGroupsMediationAbExperimentsCreateCall)Do¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Do(opts ...googleapi.CallOption) (*MediationAbExperiment,error)
Do executes the "admob.accounts.mediationGroups.mediationAbExperiments.create" call.Any non-2xx status code is an error. Response headers are in either*MediationAbExperiment.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsMediationGroupsMediationAbExperimentsCreateCall)Fields¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsMediationAbExperimentsCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsMediationGroupsMediationAbExperimentsCreateCall)Header¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsMediationGroupsMediationAbExperimentsService¶added inv0.139.0
type AccountsMediationGroupsMediationAbExperimentsService struct {// contains filtered or unexported fields}funcNewAccountsMediationGroupsMediationAbExperimentsService¶added inv0.139.0
func NewAccountsMediationGroupsMediationAbExperimentsService(s *Service) *AccountsMediationGroupsMediationAbExperimentsService
func (*AccountsMediationGroupsMediationAbExperimentsService)Create¶added inv0.139.0
func (r *AccountsMediationGroupsMediationAbExperimentsService) Create(parentstring, mediationabexperiment *MediationAbExperiment) *AccountsMediationGroupsMediationAbExperimentsCreateCall
Create: Create an A/B testing experiment for a specified AdMob account and amediation group. This method has limited access. If you see a 403 permissiondenied error, please reach out to your account manager for access.
- parent: The parent which owns the mediation group. Format:accounts/{publisher_id}/mediationGroups/{mediation_group_id}.
func (*AccountsMediationGroupsMediationAbExperimentsService)Stop¶added inv0.139.0
func (r *AccountsMediationGroupsMediationAbExperimentsService) Stop(namestring, stopmediationabexperimentrequest *StopMediationAbExperimentRequest) *AccountsMediationGroupsMediationAbExperimentsStopCall
Stop: Stop the mediation A/B experiment and choose a variant. This methodhas limited access. If you see a 403 permission denied error, please reachout to your account manager for access.
- name: Name of the mediation group, the experiment for which to choose avariant for. Example:accounts/pub-9876543210987654/mediationGroups/0123456789/mediationAbExperiments.
typeAccountsMediationGroupsMediationAbExperimentsStopCall¶added inv0.139.0
type AccountsMediationGroupsMediationAbExperimentsStopCall struct {// contains filtered or unexported fields}func (*AccountsMediationGroupsMediationAbExperimentsStopCall)Context¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Context(ctxcontext.Context) *AccountsMediationGroupsMediationAbExperimentsStopCall
Context sets the context to be used in this call's Do method.
func (*AccountsMediationGroupsMediationAbExperimentsStopCall)Do¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Do(opts ...googleapi.CallOption) (*MediationAbExperiment,error)
Do executes the "admob.accounts.mediationGroups.mediationAbExperiments.stop" call.Any non-2xx status code is an error. Response headers are in either*MediationAbExperiment.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*AccountsMediationGroupsMediationAbExperimentsStopCall)Fields¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsMediationAbExperimentsStopCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsMediationGroupsMediationAbExperimentsStopCall)Header¶added inv0.139.0
func (c *AccountsMediationGroupsMediationAbExperimentsStopCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsMediationGroupsPatchCall¶added inv0.139.0
type AccountsMediationGroupsPatchCall struct {// contains filtered or unexported fields}func (*AccountsMediationGroupsPatchCall)Context¶added inv0.139.0
func (c *AccountsMediationGroupsPatchCall) Context(ctxcontext.Context) *AccountsMediationGroupsPatchCall
Context sets the context to be used in this call's Do method.
func (*AccountsMediationGroupsPatchCall)Do¶added inv0.139.0
func (c *AccountsMediationGroupsPatchCall) Do(opts ...googleapi.CallOption) (*MediationGroup,error)
Do executes the "admob.accounts.mediationGroups.patch" call.Any non-2xx status code is an error. Response headers are in either*MediationGroup.ServerResponse.Header or (if a response was returned at all)in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*AccountsMediationGroupsPatchCall)Fields¶added inv0.139.0
func (c *AccountsMediationGroupsPatchCall) Fields(s ...googleapi.Field) *AccountsMediationGroupsPatchCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsMediationGroupsPatchCall)Header¶added inv0.139.0
func (c *AccountsMediationGroupsPatchCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*AccountsMediationGroupsPatchCall)UpdateMask¶added inv0.139.0
func (c *AccountsMediationGroupsPatchCall) UpdateMask(updateMaskstring) *AccountsMediationGroupsPatchCall
UpdateMask sets the optional parameter "updateMask": List of mediation groupfields to be updated. Updates to repeated fields such as items in a listwill fully replace the existing value(s) with the new value(s). Updates toindividual values in a map can be done by indexing by the key. The followingfield masks are supported for mediation group updates: -"mediation_group_lines[\"{mediation_group_line_id}\"]" clang-format off -"mediation_group_lines[\"{mediation_group_line_id}\"].ad_unit_mappings[\"{ad_unit_id}\"]" clang-format on -"mediation_group_lines[\"{mediation_group_line_id}\"].cpm_micros" -"mediation_group_lines[\"{mediation_group_line_id}\"].cpm_mode" -"mediation_group_lines[\"{mediation_group_line_id}\"].state" -"mediation_group_lines[\"{mediation_group_line_id}\"].display_name" -"targeting.ad_unit_ids" To update a mediation group with a new mediationgroup line, use a distinct negative number for the"mediation_group_line_id". For Example: update_mask { paths:"mediation_group_lines[\"123456789012345\"].cpm_micros" }
typeAccountsMediationGroupsService¶added inv0.139.0
type AccountsMediationGroupsService struct {MediationAbExperiments *AccountsMediationGroupsMediationAbExperimentsService// contains filtered or unexported fields}funcNewAccountsMediationGroupsService¶added inv0.139.0
func NewAccountsMediationGroupsService(s *Service) *AccountsMediationGroupsService
func (*AccountsMediationGroupsService)Create¶added inv0.139.0
func (r *AccountsMediationGroupsService) Create(parentstring, mediationgroup *MediationGroup) *AccountsMediationGroupsCreateCall
Create: Create a mediation group under the specific AdMob account. Thismethod has limited access. If you see a 403 permission denied error, pleasereach out to your account manager for access.
- parent: The parent which owns the mediation group. Format:accounts/{publisher_id}.
func (*AccountsMediationGroupsService)List¶added inv0.139.0
func (r *AccountsMediationGroupsService) List(parentstring) *AccountsMediationGroupsListCall
List: List mediation groups under the specified AdMob account. This methodhas limited access. If you see a 403 permission denied error, please reachout to your account manager for access.
- parent: Resource name of the account to list mediation groups for.Example: accounts/pub-9876543210987654.
func (*AccountsMediationGroupsService)Patch¶added inv0.139.0
func (r *AccountsMediationGroupsService) Patch(namestring, mediationgroup *MediationGroup) *AccountsMediationGroupsPatchCall
Patch: Update the specified mediation group under the specified AdMobaccount. This method has limited access. If you see a 403 permission deniederror, please reach out to your account manager for access.
- name: Resource name for this mediation group. Format is:accounts/{publisher_id}/mediationGroups/{mediation_group_id} Example:accounts/pub-9876543210987654/mediationGroups/0123456789.
typeAccountsMediationReportGenerateCall¶
type AccountsMediationReportGenerateCall struct {// contains filtered or unexported fields}func (*AccountsMediationReportGenerateCall)Context¶
func (c *AccountsMediationReportGenerateCall) Context(ctxcontext.Context) *AccountsMediationReportGenerateCall
Context sets the context to be used in this call's Do method.
func (*AccountsMediationReportGenerateCall)Do¶
func (c *AccountsMediationReportGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateMediationReportResponse,error)
Do executes the "admob.accounts.mediationReport.generate" call.Any non-2xx status code is an error. Response headers are in either*GenerateMediationReportResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsMediationReportGenerateCall)Fields¶
func (c *AccountsMediationReportGenerateCall) Fields(s ...googleapi.Field) *AccountsMediationReportGenerateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsMediationReportGenerateCall)Header¶
func (c *AccountsMediationReportGenerateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsMediationReportService¶
type AccountsMediationReportService struct {// contains filtered or unexported fields}funcNewAccountsMediationReportService¶
func NewAccountsMediationReportService(s *Service) *AccountsMediationReportService
func (*AccountsMediationReportService)Generate¶
func (r *AccountsMediationReportService) Generate(parentstring, generatemediationreportrequest *GenerateMediationReportRequest) *AccountsMediationReportGenerateCall
Generate: Generates an AdMob Mediation report based on the provided reportspecification. Returns result of a server-side streaming RPC. The result isreturned in a sequence of responses.
- parent: Resource name of the account to generate the report for. Example:accounts/pub-9876543210987654.
typeAccountsNetworkReportGenerateCall¶
type AccountsNetworkReportGenerateCall struct {// contains filtered or unexported fields}func (*AccountsNetworkReportGenerateCall)Context¶
func (c *AccountsNetworkReportGenerateCall) Context(ctxcontext.Context) *AccountsNetworkReportGenerateCall
Context sets the context to be used in this call's Do method.
func (*AccountsNetworkReportGenerateCall)Do¶
func (c *AccountsNetworkReportGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateNetworkReportResponse,error)
Do executes the "admob.accounts.networkReport.generate" call.Any non-2xx status code is an error. Response headers are in either*GenerateNetworkReportResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*AccountsNetworkReportGenerateCall)Fields¶
func (c *AccountsNetworkReportGenerateCall) Fields(s ...googleapi.Field) *AccountsNetworkReportGenerateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*AccountsNetworkReportGenerateCall)Header¶
func (c *AccountsNetworkReportGenerateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeAccountsNetworkReportService¶
type AccountsNetworkReportService struct {// contains filtered or unexported fields}funcNewAccountsNetworkReportService¶
func NewAccountsNetworkReportService(s *Service) *AccountsNetworkReportService
func (*AccountsNetworkReportService)Generate¶
func (r *AccountsNetworkReportService) Generate(parentstring, generatenetworkreportrequest *GenerateNetworkReportRequest) *AccountsNetworkReportGenerateCall
Generate: Generates an AdMob Network report based on the provided reportspecification. Returns result of a server-side streaming RPC. The result isreturned in a sequence of responses.
- parent: Resource name of the account to generate the report for. Example:accounts/pub-9876543210987654.
typeAccountsService¶
type AccountsService struct {AdSources *AccountsAdSourcesServiceAdUnitMappings *AccountsAdUnitMappingsServiceAdUnits *AccountsAdUnitsServiceApps *AccountsAppsServiceCampaignReport *AccountsCampaignReportServiceMediationGroups *AccountsMediationGroupsServiceMediationReport *AccountsMediationReportServiceNetworkReport *AccountsNetworkReportService// contains filtered or unexported fields}funcNewAccountsService¶
func NewAccountsService(s *Service) *AccountsService
func (*AccountsService)Get¶
func (r *AccountsService) Get(namestring) *AccountsGetCall
Get: Gets information about the specified AdMob publisher account.
- name: Resource name of the publisher account to retrieve. Example:accounts/pub-9876543210987654.
func (*AccountsService)List¶
func (r *AccountsService) List() *AccountsListCall
List: Lists the AdMob publisher account that was most recently signed in tofrom the AdMob UI. For more information, seehttps://support.google.com/admob/answer/10243672.
typeAdSource¶added inv0.78.0
type AdSource struct {// AdSourceId: ID of this ad source.AdSourceIdstring `json:"adSourceId,omitempty"`// Name: Resource name of this ad source. Format is:// accounts/{publisher_id}/adSources/{ad_source_id}Namestring `json:"name,omitempty"`// Title: Display name of this ad source.Titlestring `json:"title,omitempty"`// ForceSendFields is a list of field names (e.g. "AdSourceId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdSourceId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AdSource: Definition of a mediation ad source.
func (AdSource)MarshalJSON¶added inv0.78.0
typeAdUnit¶
type AdUnit struct {// AdFormat: AdFormat of the ad unit. Possible values are as follows:// "APP_OPEN" - App Open ad format. "BANNER" - Banner ad format.// "BANNER_INTERSTITIAL" - Legacy format that can be used as either banner or// interstitial. This format can no longer be created but can be targeted by// mediation groups. "INTERSTITIAL" - A full screen ad. Supported ad types are// "RICH_MEDIA" and "VIDEO". "NATIVE" - Native ad format. "REWARDED" - An ad// that, once viewed, gets a callback verifying the view so that a reward can// be given to the user. Supported ad types are "RICH_MEDIA" (interactive) and// video where video can not be excluded. "REWARDED_INTERSTITIAL" - Rewarded// Interstitial ad format. Only supports video ad type. See//https://support.google.com/admob/answer/9884467.AdFormatstring `json:"adFormat,omitempty"`// AdTypes: Ad media type supported by this ad unit. Possible values as// follows: "RICH_MEDIA" - Text, image, and other non-video media. "VIDEO" -// Video media.AdTypes []string `json:"adTypes,omitempty"`// AdUnitId: The externally visible ID of the ad unit which can be used to// integrate with the AdMob SDK. This is a read only property. Example:// ca-app-pub-9876543210987654/0123456789AdUnitIdstring `json:"adUnitId,omitempty"`// AppId: The externally visible ID of the app this ad unit is associated with.// Example: ca-app-pub-9876543210987654~0123456789AppIdstring `json:"appId,omitempty"`// DisplayName: The display name of the ad unit as shown in the AdMob UI, which// is provided by the user. The maximum length allowed is 80 characters.DisplayNamestring `json:"displayName,omitempty"`// Name: Resource name for this ad unit. Format is// accounts/{publisher_id}/adUnits/{ad_unit_id_fragment} Example:// accounts/pub-9876543210987654/adUnits/0123456789Namestring `json:"name,omitempty"`// RewardSettings: Optional. Settings for a rewarded ad unit. This can be set// or unset only when the ad_format is "REWARDED".RewardSettings *AdUnitRewardSettings `json:"rewardSettings,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AdFormat") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdFormat") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AdUnit: Describes an AdMob ad unit.
func (AdUnit)MarshalJSON¶
typeAdUnitMapping¶added inv0.139.0
type AdUnitMapping struct {// AdUnitConfigurations: Settings for the specified ad unit to make an ad// request to 3rd party ad network. Key-value pairs with values set by the user// for the keys requested by the ad network. Please see//https://support.google.com/admob/answer/3245073 for details on how to// configure the network settings.AdUnitConfigurations map[string]string `json:"adUnitConfigurations,omitempty"`// AdapterId: The ID of mediation ad source adapter used by this ad unit// mapping. The adapter determines the information needed in the// ad_network_settings.AdapterIdint64 `json:"adapterId,omitempty,string"`// DisplayName: Optional. The display name of this ad unit mapping instance.DisplayNamestring `json:"displayName,omitempty"`// Name: Resource name of this ad unit mapping. Format is:// accounts/{publisher_id}/adUnits/{ad_unit_id_fragment}/adUnitMappings/{ad_unit// _mapping_id} Example:// accounts/pub-1234567890123456/adUnits/0123456789/adUnitMappings/987654321Namestring `json:"name,omitempty"`// State: Output only. The status of this ad unit mapping.//// Possible values:// "STATE_UNSPECIFIED" - The default value.// "ENABLED" - The ad unit mapping is active and used to serve ads or// collecting stats.Statestring `json:"state,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AdUnitConfigurations") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdUnitConfigurations") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AdUnitMapping: Settings to map an AdMob ad unit to a 3rd party ad unit.
func (AdUnitMapping)MarshalJSON¶added inv0.139.0
func (sAdUnitMapping) MarshalJSON() ([]byte,error)
typeAdUnitRewardSettings¶added inv0.139.0
type AdUnitRewardSettings struct {// UnitAmount: Reward amount for this ad unit.UnitAmountint64 `json:"unitAmount,omitempty,string"`// UnitType: Reward item for this ad unit.UnitTypestring `json:"unitType,omitempty"`// ForceSendFields is a list of field names (e.g. "UnitAmount") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "UnitAmount") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AdUnitRewardSettings: Settings for a rewarded ad unit.
func (AdUnitRewardSettings)MarshalJSON¶added inv0.139.0
func (sAdUnitRewardSettings) MarshalJSON() ([]byte,error)
typeAdapter¶added inv0.139.0
type Adapter struct {// AdapterConfigMetadata: Output only. Configuration metadata associated with// this adapter.AdapterConfigMetadata []*AdapterAdapterConfigMetadata `json:"adapterConfigMetadata,omitempty"`// AdapterId: Output only. ID of this adapter. It is used to set adapter_id// (#AdUnitMapping.adapter_id).AdapterIdstring `json:"adapterId,omitempty"`// Formats: Output only. Indicates the formats of the ad units supported by// this adapter.Formats []string `json:"formats,omitempty"`// Name: Output only. Resource name of the adapter. Format is:// accounts/{publisher_id}/adSources/{ad_source_id}/adapters/{adapter_id}.Namestring `json:"name,omitempty"`// Platform: Output only. Mobile application platform supported by this// adapter. Supported values are: IOS, ANDROID, WINDOWS_PHONEPlatformstring `json:"platform,omitempty"`// Title: Output only. The display name of this adapter.Titlestring `json:"title,omitempty"`// ForceSendFields is a list of field names (e.g. "AdapterConfigMetadata") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdapterConfigMetadata") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Adapter: Describes adapters supported by each mediation ad source. Adapterscorrespond to a specific SDK implementation of the ad source, and are eachassociated with a single platform and a list of supported ad unit formats.Adapters may also require setting some configurations to perform adrequests. Configurations can be specified in the AdUnitMapping by settingthe ad_unit_configurations (#AdUnitMapping.ad_unit_configurations) key/valuepairs. For example, the ad_unit_configurations can be used to pass variousIDs to the adapter's third-party SDK.
func (Adapter)MarshalJSON¶added inv0.139.0
typeAdapterAdapterConfigMetadata¶added inv0.139.0
type AdapterAdapterConfigMetadata struct {// AdapterConfigMetadataId: This is used to fill the key of the// ad_unit_configurations (#AdUnitMapping.ad_unit_configurations).AdapterConfigMetadataIdstring `json:"adapterConfigMetadataId,omitempty"`// AdapterConfigMetadataLabel: Name of the adapter configuration metadata.AdapterConfigMetadataLabelstring `json:"adapterConfigMetadataLabel,omitempty"`// IsRequired: Whether this metadata is required for configuring the// AdUnitMappings.IsRequiredbool `json:"isRequired,omitempty"`// ForceSendFields is a list of field names (e.g. "AdapterConfigMetadataId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdapterConfigMetadataId") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AdapterAdapterConfigMetadata: Configuration metadata associated with thisadapter. They are used to define the ad_unit_configurations associated withAdUnitMappings for the this adapter.
func (AdapterAdapterConfigMetadata)MarshalJSON¶added inv0.139.0
func (sAdapterAdapterConfigMetadata) MarshalJSON() ([]byte,error)
typeApp¶
type App struct {// AppApprovalState: Output only. The approval state for the app. The field is// read-only.//// Possible values:// "APP_APPROVAL_STATE_UNSPECIFIED" - Default value for an unset field. Do// not use.// "ACTION_REQUIRED" - The app requires additional user action to be// approved. Please refer tohttps://support.google.com/admob/answer/10564477// for details and next steps.// "IN_REVIEW" - The app is pending review.// "APPROVED" - The app is approved and can serve ads.AppApprovalStatestring `json:"appApprovalState,omitempty"`// AppId: The externally visible ID of the app which can be used to integrate// with the AdMob SDK. This is a read only property. Example:// ca-app-pub-9876543210987654~0123456789AppIdstring `json:"appId,omitempty"`// LinkedAppInfo: Immutable. The information for an app that is linked to an// app store. This field is present if and only if the app is linked to an app// store.LinkedAppInfo *AppLinkedAppInfo `json:"linkedAppInfo,omitempty"`// ManualAppInfo: The information for an app that is not linked to any app// store. After an app is linked, this information is still retrivable. If no// name is provided for the app upon creation, a placeholder name will be used.ManualAppInfo *AppManualAppInfo `json:"manualAppInfo,omitempty"`// Name: Resource name for this app. Format is// accounts/{publisher_id}/apps/{app_id_fragment} Example:// accounts/pub-9876543210987654/apps/0123456789Namestring `json:"name,omitempty"`// Platform: Describes the platform of the app. Limited to "IOS" and "ANDROID".Platformstring `json:"platform,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AppApprovalState") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AppApprovalState") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}App: Describes an AdMob app for a specific platform (For example: Android oriOS).
func (App)MarshalJSON¶
typeAppLinkedAppInfo¶
type AppLinkedAppInfo struct {// AndroidAppStores: Optional. The app store information for published Android// apps. This field is only used for apps on the Android platform and will be// ignored if the PLATFORM is set to iOS. The default value is the Google Play// App store. This field can be updated after app is created. If the app is not// published, this field will not be included in the response.//// Possible values:// "ANDROID_APP_STORE_UNSPECIFIED" - Default value for an unset field. Do not// use.// "GOOGLE_PLAY_APP_STORE" - Google Play Store.// "AMAZON_APP_STORE" - Amazon Appstore.// "OPPO_APP_STORE" - Oppo App Market.// "SAMSUNG_APP_STORE" - Samsung Galaxy Store.// "VIVO_APP_STORE" - VIVO App Store.// "XIAOMI_APP_STORE" - Xiaomi GetApps.AndroidAppStores []string `json:"androidAppStores,omitempty"`// AppStoreId: The app store ID of the app; present if and only if the app is// linked to an app store. If the app is added to the Google Play store, it// will be the application ID of the app. For example: "com.example.myapp". See//https://developer.android.com/studio/build/application-id. If the app is// added to the Apple App Store, it will be app store ID. For example// "105169111". Note that setting the app store id is considered an// irreversible action. Once an app is linked, it cannot be unlinked.AppStoreIdstring `json:"appStoreId,omitempty"`// DisplayName: Output only. Display name of the app as it appears in the app// store. This is an output-only field, and may be empty if the app cannot be// found in the store.DisplayNamestring `json:"displayName,omitempty"`// ForceSendFields is a list of field names (e.g. "AndroidAppStores") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AndroidAppStores") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AppLinkedAppInfo: Information from the app store if the app is linked to anapp store.
func (AppLinkedAppInfo)MarshalJSON¶
func (sAppLinkedAppInfo) MarshalJSON() ([]byte,error)
typeAppManualAppInfo¶
type AppManualAppInfo struct {// DisplayName: The display name of the app as shown in the AdMob UI, which is// provided by the user. The maximum length allowed is 80 characters.DisplayNamestring `json:"displayName,omitempty"`// ForceSendFields is a list of field names (e.g. "DisplayName") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DisplayName") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AppManualAppInfo: Information provided for manual apps which are not linkedto an application store (Example: Google Play, App Store).
func (AppManualAppInfo)MarshalJSON¶
func (sAppManualAppInfo) MarshalJSON() ([]byte,error)
typeBatchCreateAdUnitMappingsRequest¶added inv0.139.0
type BatchCreateAdUnitMappingsRequest struct {// Requests: Required. The request message specifying the ad unit mappings to// create. A maximum of 100 ad unit mappings can be created in a batch. If the// number of ad unit mappings in the batch request exceed 100, the entire// request will be rejected and no ad unit mappings will be created.Requests []*CreateAdUnitMappingRequest `json:"requests,omitempty"`// ForceSendFields is a list of field names (e.g. "Requests") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Requests") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BatchCreateAdUnitMappingsRequest: Request to create a batch of ad unitmappings under the specific AdMob account.
func (BatchCreateAdUnitMappingsRequest)MarshalJSON¶added inv0.139.0
func (sBatchCreateAdUnitMappingsRequest) MarshalJSON() ([]byte,error)
typeBatchCreateAdUnitMappingsResponse¶added inv0.139.0
type BatchCreateAdUnitMappingsResponse struct {// AdUnitMappings: The Ad units mappings created under the requested account.AdUnitMappings []*AdUnitMapping `json:"adUnitMappings,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AdUnitMappings") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdUnitMappings") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BatchCreateAdUnitMappingsResponse: Response containing a batch of created adunit mappings.
func (BatchCreateAdUnitMappingsResponse)MarshalJSON¶added inv0.139.0
func (sBatchCreateAdUnitMappingsResponse) MarshalJSON() ([]byte,error)
typeCampaignReportSpec¶added inv0.139.0
type CampaignReportSpec struct {// DateRange: The date range for which the report is generated. The max range// is 30 days.DateRange *DateRange `json:"dateRange,omitempty"`// Dimensions: List of dimensions of the report. The value combination of these// dimensions determines the row of the report. If no dimensions are specified,// the report returns a single row of requested metrics for the entire account.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value of an unspecified dimension. Do// not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701").// "CAMPAIGN_ID" - The unique ID of the campaign, for example "123456789",// which is consistent with the campaign id from campaign list api.// "CAMPAIGN_NAME" - The name of the campaign.// "AD_ID" - The unique ID of the ad, for example "123456789".// "AD_NAME" - The name of the ad, which may not be unique.// "PLACEMENT_ID" - The vendor-specific unique ID of the app where the ad is// placed. For example, com.goog.bar for Android and 123456789 for iOS apps.// "PLACEMENT_NAME" - The name of the app where the ad is placed.// "PLACEMENT_PLATFORM" - The platform of the app where the ad is placed.// "COUNTRY" - The name of the targeted country.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.Dimensions []string `json:"dimensions,omitempty"`// LanguageCode: Language used for any localized text, such as certain// applicable dimension values. The language tag is defined in the IETF BCP47.// Defaults to 'en-US' if unspecified or invalid.LanguageCodestring `json:"languageCode,omitempty"`// Metrics: List of metrics of the report. A report must specify at least one// metric.//// Possible values:// "METRIC_UNSPECIFIED" - Default value for an unset field. Do not use.// "IMPRESSIONS" - The number of times an ad is shown to the user.// "CLICKS" - The number of times a user clicks an ad.// "CLICK_THROUGH_RATE" - The number of clicks an ad receives divided by the// number of times the ad is shown.// "INSTALLS" - The number of times apps were downloaded to devices.// "ESTIMATED_COST" - The estimated cost of serving a campaign ad instead of// an ad that earns revenue. The currency is the reporting currency for// campaigns.// "AVERAGE_CPI" - The average cost per install. This means the average// amount that was spent to acquire a new user. The currency is the reporting// currency for campaigns.// "INTERACTIONS" - The number of times a user interacts with an ad. This// consists of clicks and engagements.Metrics []string `json:"metrics,omitempty"`// ForceSendFields is a list of field names (e.g. "DateRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DateRange") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}CampaignReportSpec: The specification for generating a Campaign report. Forexample, the specification to get IMPRESSIONS and CLICKS sliced byCAMPAIGN_ID can look like the following example: { "date_range": {"start_date": {"year": 2021, "month": 12, "day": 1}, "end_date": {"year":2021, "month": 12, "day": 30} }, "dimensions": ["CAMPAIGN_ID"], "metrics":["IMPRESSIONS", "CLICKS"], }
func (CampaignReportSpec)MarshalJSON¶added inv0.139.0
func (sCampaignReportSpec) MarshalJSON() ([]byte,error)
typeCreateAdUnitMappingRequest¶added inv0.139.0
type CreateAdUnitMappingRequest struct {// AdUnitMapping: Required. The ad unit mapping to create.AdUnitMapping *AdUnitMapping `json:"adUnitMapping,omitempty"`// Parent: Required. The parent which owns the ad unit mapping. Format:// accounts/{publisher_id}/adUnits/{ad_unit_id}Parentstring `json:"parent,omitempty"`// ForceSendFields is a list of field names (e.g. "AdUnitMapping") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdUnitMapping") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}CreateAdUnitMappingRequest: Request to create an ad unit mapping under thespecific AdMob account and ad unit.
func (CreateAdUnitMappingRequest)MarshalJSON¶added inv0.139.0
func (sCreateAdUnitMappingRequest) MarshalJSON() ([]byte,error)
typeDate¶
type Date struct {// Day: Day of a month. Must be from 1 to 31 and valid for the year and month,// or 0 to specify a year by itself or a year and month where the day isn't// significant.Dayint64 `json:"day,omitempty"`// Month: Month of a year. Must be from 1 to 12, or 0 to specify a year without// a month and day.Monthint64 `json:"month,omitempty"`// Year: Year of the date. Must be from 1 to 9999, or 0 to specify a date// without a year.Yearint64 `json:"year,omitempty"`// ForceSendFields is a list of field names (e.g. "Day") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Day") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Date: Represents a whole or partial calendar date, such as a birthday. Thetime of day and time zone are either specified elsewhere or areinsignificant. The date is relative to the Gregorian Calendar. This canrepresent one of the following: * A full date, with non-zero year, month,and day values. * A month and day, with a zero year (for example, ananniversary). * A year on its own, with a zero month and a zero day. * Ayear and month, with a zero day (for example, a credit card expirationdate). Related types: * google.type.TimeOfDay * google.type.DateTime *google.protobuf.Timestamp
func (Date)MarshalJSON¶
typeDateRange¶
type DateRange struct {// EndDate: End date of the date range, inclusive. Must be greater than or// equal to the start date.EndDate *Date `json:"endDate,omitempty"`// StartDate: Start date of the date range, inclusive. Must be less than or// equal to the end date.StartDate *Date `json:"startDate,omitempty"`// ForceSendFields is a list of field names (e.g. "EndDate") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EndDate") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DateRange: Specification of a single date range. Both dates are inclusive.
func (DateRange)MarshalJSON¶
typeGenerateCampaignReportRequest¶added inv0.139.0
type GenerateCampaignReportRequest struct {// ReportSpec: Campaign report specification.ReportSpec *CampaignReportSpec `json:"reportSpec,omitempty"`// ForceSendFields is a list of field names (e.g. "ReportSpec") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ReportSpec") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateCampaignReportRequest: Request to generate campaign report.
func (GenerateCampaignReportRequest)MarshalJSON¶added inv0.139.0
func (sGenerateCampaignReportRequest) MarshalJSON() ([]byte,error)
typeGenerateCampaignReportResponse¶added inv0.139.0
type GenerateCampaignReportResponse struct {// Rows: The campaign report data from the specified publisher. At most 100000// rows will be returned from the API.Rows []*ReportRow `json:"rows,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Rows") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Rows") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateCampaignReportResponse: Campaign Report API response.
func (GenerateCampaignReportResponse)MarshalJSON¶added inv0.139.0
func (sGenerateCampaignReportResponse) MarshalJSON() ([]byte,error)
typeGenerateMediationReportRequest¶
type GenerateMediationReportRequest struct {// ReportSpec: Network report specification.ReportSpec *MediationReportSpec `json:"reportSpec,omitempty"`// ForceSendFields is a list of field names (e.g. "ReportSpec") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ReportSpec") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateMediationReportRequest: Request to generate an AdMob Mediationreport.
func (GenerateMediationReportRequest)MarshalJSON¶
func (sGenerateMediationReportRequest) MarshalJSON() ([]byte,error)
typeGenerateMediationReportResponse¶
type GenerateMediationReportResponse struct {// Footer: Additional information about the generated report, such as warnings// about the data.Footer *ReportFooter `json:"footer,omitempty"`// Header: Report generation settings that describes the report contents, such// as the report date range and localization settings.Header *ReportHeader `json:"header,omitempty"`// Row: Actual report data.Row *ReportRow `json:"row,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Footer") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Footer") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateMediationReportResponse: The streaming response for the AdMobMediation report where the first response contains the report header, then astream of row responses, and finally a footer as the last response message.For example: [{ "header": { "date_range": { "start_date": {"year": 2018,"month": 9, "day": 1}, "end_date": {"year": 2018, "month": 9, "day": 1} },"localization_settings": { "currency_code": "USD", "language_code": "en-US"} } }, { "row": { "dimension_values": { "DATE": {"value": "20180918"},"APP": { "value": "ca-app-pub-8123415297019784~1001342552", "display_label":"My app name!" } }, "metric_values": { "ESTIMATED_EARNINGS":{"decimal_value": "1324746"} } } }, { "footer": {"matching_row_count": 1} }]
func (GenerateMediationReportResponse)MarshalJSON¶
func (sGenerateMediationReportResponse) MarshalJSON() ([]byte,error)
typeGenerateNetworkReportRequest¶
type GenerateNetworkReportRequest struct {// ReportSpec: Network report specification.ReportSpec *NetworkReportSpec `json:"reportSpec,omitempty"`// ForceSendFields is a list of field names (e.g. "ReportSpec") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ReportSpec") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateNetworkReportRequest: Request to generate an AdMob Network report.
func (GenerateNetworkReportRequest)MarshalJSON¶
func (sGenerateNetworkReportRequest) MarshalJSON() ([]byte,error)
typeGenerateNetworkReportResponse¶
type GenerateNetworkReportResponse struct {// Footer: Additional information about the generated report, such as warnings// about the data.Footer *ReportFooter `json:"footer,omitempty"`// Header: Report generation settings that describes the report contents, such// as the report date range and localization settings.Header *ReportHeader `json:"header,omitempty"`// Row: Actual report data.Row *ReportRow `json:"row,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Footer") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Footer") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateNetworkReportResponse: The streaming response for the AdMob Networkreport where the first response contains the report header, then a stream ofrow responses, and finally a footer as the last response message. Forexample: [{ "header": { "dateRange": { "startDate": {"year": 2018, "month":9, "day": 1}, "endDate": {"year": 2018, "month": 9, "day": 1} },"localizationSettings": { "currencyCode": "USD", "languageCode": "en-US" } }}, { "row": { "dimensionValues": { "DATE": {"value": "20180918"}, "APP": {"value": "ca-app-pub-8123415297019784~1001342552", displayLabel: "My appname!" } }, "metricValues": { "ESTIMATED_EARNINGS": {"microsValue": 6500000}} } }, { "footer": {"matchingRowCount": 1} }]
func (GenerateNetworkReportResponse)MarshalJSON¶
func (sGenerateNetworkReportResponse) MarshalJSON() ([]byte,error)
typeListAdSourcesResponse¶added inv0.78.0
type ListAdSourcesResponse struct {// AdSources: The ad sources.AdSources []*AdSource `json:"adSources,omitempty"`// NextPageToken: Used to set the `page_token` in the `ListAdSourcesRequest` to// retrieve the next page. If this field is omitted, there are no subsequent// pages.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AdSources") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdSources") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListAdSourcesResponse: Response for the ListAdSourcesRequest.
func (ListAdSourcesResponse)MarshalJSON¶added inv0.78.0
func (sListAdSourcesResponse) MarshalJSON() ([]byte,error)
typeListAdUnitMappingsResponse¶added inv0.139.0
type ListAdUnitMappingsResponse struct {// AdUnitMappings: The ad unit mappings from the specified account and ad unit.AdUnitMappings []*AdUnitMapping `json:"adUnitMappings,omitempty"`// NextPageToken: Used to set the `page_token` in the// `ListAdUnitMappingsRequest` to retrieve the next page. If this field is// omitted, there are no subsequent pages.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AdUnitMappings") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdUnitMappings") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListAdUnitMappingsResponse: Response for the ListAdUnitMappingsRequest.
func (ListAdUnitMappingsResponse)MarshalJSON¶added inv0.139.0
func (sListAdUnitMappingsResponse) MarshalJSON() ([]byte,error)
typeListAdUnitsResponse¶
type ListAdUnitsResponse struct {// AdUnits: The resulting ad units for the requested account.AdUnits []*AdUnit `json:"adUnits,omitempty"`// NextPageToken: If not empty, indicates that there may be more ad units for// the request; this value should be passed in a new `ListAdUnitsRequest`.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AdUnits") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdUnits") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListAdUnitsResponse: Response for the ad units list request.
func (ListAdUnitsResponse)MarshalJSON¶
func (sListAdUnitsResponse) MarshalJSON() ([]byte,error)
typeListAdaptersResponse¶added inv0.139.0
type ListAdaptersResponse struct {// Adapters: The adapter.Adapters []*Adapter `json:"adapters,omitempty"`// NextPageToken: Used to set the `page_token` in the `ListAdapterRequest` to// retrieve the next page. If this field is omitted, there are no subsequent// pages.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Adapters") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Adapters") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListAdaptersResponse: Response for the ListAdaptersRequest.
func (ListAdaptersResponse)MarshalJSON¶added inv0.139.0
func (sListAdaptersResponse) MarshalJSON() ([]byte,error)
typeListAppsResponse¶
type ListAppsResponse struct {// Apps: The resulting apps for the requested account.Apps []*App `json:"apps,omitempty"`// NextPageToken: If not empty, indicates that there may be more apps for the// request; this value should be passed in a new `ListAppsRequest`.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Apps") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Apps") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListAppsResponse: Response for the apps list request.
func (ListAppsResponse)MarshalJSON¶
func (sListAppsResponse) MarshalJSON() ([]byte,error)
typeListMediationGroupsResponse¶added inv0.139.0
type ListMediationGroupsResponse struct {// MediationGroups: The resulting mediation groups for the requested account.MediationGroups []*MediationGroup `json:"mediationGroups,omitempty"`// NextPageToken: If not empty, indicates that there may be more mediation// groups for the request; this value should be passed in a new// `ListMediationGroupsRequest`.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "MediationGroups") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MediationGroups") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListMediationGroupsResponse: Response for the mediation groups list request.
func (ListMediationGroupsResponse)MarshalJSON¶added inv0.139.0
func (sListMediationGroupsResponse) MarshalJSON() ([]byte,error)
typeListPublisherAccountsResponse¶
type ListPublisherAccountsResponse struct {// Account: Publisher that the client credentials can access.Account []*PublisherAccount `json:"account,omitempty"`// NextPageToken: If not empty, indicates that there might be more accounts for// the request; you must pass this value in a new// `ListPublisherAccountsRequest`.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Account") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Account") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListPublisherAccountsResponse: Response for the publisher account listrequest.
func (ListPublisherAccountsResponse)MarshalJSON¶
func (sListPublisherAccountsResponse) MarshalJSON() ([]byte,error)
typeLocalizationSettings¶
type LocalizationSettings struct {// CurrencyCode: Currency code of the earning related metrics, which is the// 3-letter code defined in ISO 4217. The daily average rate is used for the// currency conversion. Defaults to the account currency code if unspecified.CurrencyCodestring `json:"currencyCode,omitempty"`// LanguageCode: Language used for any localized text, such as some dimension// value display labels. The language tag defined in the IETF BCP47. Defaults// to 'en-US' if unspecified.LanguageCodestring `json:"languageCode,omitempty"`// ForceSendFields is a list of field names (e.g. "CurrencyCode") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CurrencyCode") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}LocalizationSettings: Localization settings for reports, such as currencyand language. It affects how metrics are calculated.
func (LocalizationSettings)MarshalJSON¶
func (sLocalizationSettings) MarshalJSON() ([]byte,error)
typeMediationAbExperiment¶added inv0.139.0
type MediationAbExperiment struct {// ControlMediationLines: Output only. The experiment mediation lines for// control. They are inherited from the parent mediation group. It is an output// only field.ControlMediationLines []*MediationAbExperimentExperimentMediationLine `json:"controlMediationLines,omitempty"`// DisplayName: The display name for the mediation A/B experiment.DisplayNamestring `json:"displayName,omitempty"`// EndTime: Output only. The time at which the experiment was ended or target// to end (in UTC).EndTimestring `json:"endTime,omitempty"`// ExperimentId: Output only. Unique identifier for the mediation A/B// experiment. It is an output only property.ExperimentIdstring `json:"experimentId,omitempty"`// MediationGroupId: Output only. The mediation group id this experiment// belongs to. This can be used for filtering the experiments in the list// experiments API.MediationGroupIdstring `json:"mediationGroupId,omitempty"`// Name: Resource name for this experiment. The format is// accounts/{publisher_id}/// mediationGroups/{mediation_group_id}/mediationAbExperiment/// {mediation_group_experiment_id}. For example:// accounts/pub-9876543210987654/mediationGroups/0123456789/// mediationAbExperiment/12345Namestring `json:"name,omitempty"`// StartTime: Output only. The time at which the experiment was started (in// UTC).StartTimestring `json:"startTime,omitempty"`// State: Output only. The state of the experiment. It is an output only field.//// Possible values:// "EXPERIMENT_STATE_UNSPECIFIED" - Default for an unset field. Do not use.// "EXPIRED" - The experiment has expired.// "RUNNING" - The experiment is running and thus used in serving.// "ENDED" - The experiment is ended, but not yet expired. Serving continues// in the original configurations while the experiment is ready to call an// action.Statestring `json:"state,omitempty"`// TreatmentMediationLines: The experiment mediation lines created for the// treatment. They will be used for serving when the experiment status is// RUNNING.TreatmentMediationLines []*MediationAbExperimentExperimentMediationLine `json:"treatmentMediationLines,omitempty"`// TreatmentTrafficPercentage: The percentage of the mediation A/B experiment// traffic that will be send to the treatment (variant B). The remainder is// sent to the control (variant A). The percentage is expressed as an integer// in the inclusive range of [1,99]. See//https://support.google.com/admob/answer/9572326 for details.TreatmentTrafficPercentageint64 `json:"treatmentTrafficPercentage,omitempty,string"`// VariantLeader: Output only. The variant leader for the experiment according// to some key metrics.//// Possible values:// "VARIANT_LEADER_UNSPECIFIED" - Default value of the enum. Do not use.// "CONTROL" - The control leading the experiment.// "TREATMENT" - The treatment leading the experiment.// "INSUFFICIENT_DATA" - Collected data (impressions) are insufficient to// determine a leader.// "TOO_EARLY_TO_CALL" - Experiment hasn't run long enough to determine a// leader.// "NO_VARIANT_LEADER" - Neither variant is a decisive winner in the observed// data.VariantLeaderstring `json:"variantLeader,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "ControlMediationLines") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ControlMediationLines") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationAbExperiment: The mediation A/B experiment.
func (MediationAbExperiment)MarshalJSON¶added inv0.139.0
func (sMediationAbExperiment) MarshalJSON() ([]byte,error)
typeMediationAbExperimentExperimentMediationLine¶added inv0.139.0
type MediationAbExperimentExperimentMediationLine struct {// MediationGroupLine: The mediation group line used by the experiment.MediationGroupLine *MediationGroupMediationGroupLine `json:"mediationGroupLine,omitempty"`// ForceSendFields is a list of field names (e.g. "MediationGroupLine") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MediationGroupLine") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationAbExperimentExperimentMediationLine: The mediation group line forthe experiment. It will be used for serving during the run of theexperiment.
func (MediationAbExperimentExperimentMediationLine)MarshalJSON¶added inv0.139.0
func (sMediationAbExperimentExperimentMediationLine) MarshalJSON() ([]byte,error)
typeMediationGroup¶added inv0.139.0
type MediationGroup struct {// DisplayName: User provided name for the mediation group. The maximum length// allowed is 120 characters.DisplayNamestring `json:"displayName,omitempty"`// MediationAbExperimentState: Output only. The state of the mediation a/b// experiment that belongs to this mediation group.//// Possible values:// "EXPERIMENT_STATE_UNSPECIFIED" - Default value for an unset field. Do not// use.// "RUNNING" - The mediation group has an experiment in the RUNNING state.// "NOT_RUNNING" - There is no experiment in the RUNNING state in the// mediation group.MediationAbExperimentStatestring `json:"mediationAbExperimentState,omitempty"`// MediationGroupId: The ID of the mediation group. Example: "0123456789". This// is a read only property.MediationGroupIdstring `json:"mediationGroupId,omitempty"`// MediationGroupLines: The mediation lines used for serving for this mediation// group. Key is the ID of the mediation group line. For creation, use distinct// negative values as placeholder.MediationGroupLines map[string]MediationGroupMediationGroupLine `json:"mediationGroupLines,omitempty"`// Name: Resource name for this mediation group. Format is:// accounts/{publisher_id}/mediationGroups/{mediation_group_id} Example:// accounts/pub-9876543210987654/mediationGroups/0123456789Namestring `json:"name,omitempty"`// State: The status of the mediation group. Only enabled mediation groups will// be served.//// Possible values:// "STATE_UNSPECIFIED" - Default value for an unset field. Do not use.// "ENABLED" - The mediation group is active and used to serve ads or to// collect stats.// "DISABLED" - The mediation group has been disabled and is no longer// serving ads or collecting stats. Disabled mediation groups can be// re-enabled.Statestring `json:"state,omitempty"`// Targeting: Set of criteria targeted by this mediation group, such as ad// units and geo locations.Targeting *MediationGroupTargeting `json:"targeting,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "DisplayName") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DisplayName") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationGroup: Describes an AdMob Mediation group.
func (MediationGroup)MarshalJSON¶added inv0.139.0
func (sMediationGroup) MarshalJSON() ([]byte,error)
typeMediationGroupMediationGroupLine¶added inv0.139.0
type MediationGroupMediationGroupLine struct {// AdSourceId: The ID of the ad source this mediation line is associated with.AdSourceIdstring `json:"adSourceId,omitempty"`// AdUnitMappings: References of the ad unit mappings for each ad unit// associated with this mediation line. Key is the ad unit ID, value is// resource name of the ad unit mapping. For mediation lines where the ad// source id is the AdMob Network, ad unit mappings will be ignored.AdUnitMappings map[string]string `json:"adUnitMappings,omitempty"`// CpmMicros: The CPM for this allocation line. $0.01 is the minimum allowed// amount. For LIVE CPM modes, the default amount is $0.01. This value is// ignored if `cpm_mode` is `LIVE`. **Warning:** "USD" is the only supported// currency at the moment. The unit is in micros.CpmMicrosint64 `json:"cpmMicros,omitempty,string"`// CpmMode: Indicates how the CPM for this mediation line is provided. Note// that `MANUAL` and `LIVE` are the only fully-supported mode at the moment.// Please use the AdMob UI (https://admob.google.com) if you wish to create or// update to other cpm modes.//// Possible values:// "CPM_MODE_UNSPECIFIED" - Default value for an unset field. Do not use.// "LIVE" - CPM is calculated per ad request based on the ad auction.// "MANUAL" - CPM is set by the user manually.// "ANO" - CPM is retrieved from the ad network using the publisher specified// credentials. Output only.CpmModestring `json:"cpmMode,omitempty"`// DisplayName: User-provided label for this mediation line. The maximum length// allowed is 255 characters.DisplayNamestring `json:"displayName,omitempty"`// ExperimentVariant: Output only. The Mediation A/B experiment variant to// which the mediation group line belongs to.//// Possible values:// "VARIANT_UNSPECIFIED" - Default value for an unset field. Do not use.// "VARIANT_A" - The mediation group line belongs to the variant A.// "VARIANT_B" - The mediation group line belongs to the variant B.// "ORIGINAL" - The mediation group line isn't a part of an experiment.ExperimentVariantstring `json:"experimentVariant,omitempty"`// Id: The 16 digit ID for this mediation line e.g. 0123456789012345. When// creating a new mediation group line, use a distinct negative integer as the// ID place holder.Idstring `json:"id,omitempty"`// State: The status of the mediation group line. Only enabled mediation group// lines will be served.//// Possible values:// "STATE_UNSPECIFIED" - Default value for an unset field. Do not use.// "ENABLED" - The mediation group line is active and used to serve ads.// "DISABLED" - The mediation group line has been disabled and is no longer// served. Disabled mediation group lines can be re-enabled.// "REMOVED" - The mediation group line will be removed and no longer served.// Removed mediation group lines can not be re-enabled and will no longer be// visible. This is an input only field.Statestring `json:"state,omitempty"`// ForceSendFields is a list of field names (e.g. "AdSourceId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdSourceId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationGroupMediationGroupLine: Settings for an ad network used by amediation group.
func (MediationGroupMediationGroupLine)MarshalJSON¶added inv0.139.0
func (sMediationGroupMediationGroupLine) MarshalJSON() ([]byte,error)
typeMediationGroupTargeting¶added inv0.139.0
type MediationGroupTargeting struct {// AdUnitIds: Ad units targeted by this mediation group. Example:// "ca-app-pub-1234/8790".AdUnitIds []string `json:"adUnitIds,omitempty"`// ExcludedRegionCodes: The Unicode country/region code (CLDR) of a location,// such as "US". Unset if this mediation group does not exclude any region.ExcludedRegionCodes []string `json:"excludedRegionCodes,omitempty"`// Format: Ad format targeted by this mediation group. Examples: "banner",// "native".Formatstring `json:"format,omitempty"`// IdfaTargeting: The parameter can be used to target ad requests based on the// availability of the IDFA. If set to ALL, the mediation group applies to all// ad requests (with or without IDFA). If set to AVAILABLE, the mediation group// applies to ad requests with IDFA. If set to NOT_AVAILABLE, the mediation// group applies to ad requests without IDFA. Doesn't need to be specified for// an ANDROID device.//// Possible values:// "IDFA_TARGETING_UNSPECIFIED" - Default value. This value is unused.// "ALL" - All the devices are targeted, regardless of IDFA availability.// "AVAILABLE" - Only the devices with IDFA availability are targeted.// "NOT_AVAILABLE" - Only the devices without IDFA availability are targeted.IdfaTargetingstring `json:"idfaTargeting,omitempty"`// Platform: Describes the platform of the app. Examples: "IOS", "ANDROID".Platformstring `json:"platform,omitempty"`// TargetedRegionCodes: The Unicode country/region code (CLDR) of a location,// such as "US". Unset if this mediation group targets all available regions.// For more information, see//http://www.unicode.org/reports/tr35/#unicode_region_subtag.TargetedRegionCodes []string `json:"targetedRegionCodes,omitempty"`// ForceSendFields is a list of field names (e.g. "AdUnitIds") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdUnitIds") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationGroupTargeting: Set of criteria targeted by this mediation group.For example, a mediation group can target specific ad unit IDs, platform,format and geo location.
func (MediationGroupTargeting)MarshalJSON¶added inv0.139.0
func (sMediationGroupTargeting) MarshalJSON() ([]byte,error)
typeMediationReportSpec¶
type MediationReportSpec struct {// DateRange: The date range for which the report is generated.DateRange *DateRange `json:"dateRange,omitempty"`// DimensionFilters: Describes which report rows to match based on their// dimension values.DimensionFilters []*MediationReportSpecDimensionFilter `json:"dimensionFilters,omitempty"`// Dimensions: List of dimensions of the report. The value combination of these// dimensions determines the row of the report. If no dimensions are specified,// the report returns a single row of requested metrics for the entire account.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701"). Requests// can specify at most one time dimension.// "MONTH" - A month in the YYYYMM format (for example, "202107"). Requests// can specify at most one time dimension.// "WEEK" - The date of the first day of a week in the YYYYMMDD format (for// example, "20210701"). Requests can specify at most one time dimension.// "AD_SOURCE" - The [unique ID of the ad source](/admob/api/v1/ad_sources)// (for example, "5450213213286189855" and "AdMob Network" as label value).// "AD_SOURCE_INSTANCE" - The unique ID of the ad source instance (for// example, "ca-app-pub-1234:asi:5678" and "AdMob (default)" as label value).// "AD_UNIT" - The unique ID of the ad unit (for example,// "ca-app-pub-1234/8790"). If AD_UNIT dimension is specified, then APP is// included automatically.// "APP" - The unique ID of the mobile application (for example,// "ca-app-pub-1234~1234").// "MEDIATION_GROUP" - The unique ID of the mediation group (for example,// "ca-app-pub-1234:mg:1234" and "AdMob (default)" as label value).// "COUNTRY" - CLDR country code of the place where the ad views/clicks occur// (for example, "US" or "FR"). This is a geography dimension.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.// "PLATFORM" - Mobile OS platform of the app (for example, "Android" or// "iOS").// "MOBILE_OS_VERSION" - Mobile operating system version, e.g. "iOS 13.5.1".// "GMA_SDK_VERSION" - GMA SDK version, e.g. "iOS 7.62.0".// "APP_VERSION_NAME" - For Android, the app version name can be found in// versionName in PackageInfo. For iOS, the app version name can be found in// CFBundleShortVersionString.// "SERVING_RESTRICTION" - Restriction mode for ads serving (e.g.// "Non-personalized ads").Dimensions []string `json:"dimensions,omitempty"`// LocalizationSettings: Localization settings of the report.LocalizationSettings *LocalizationSettings `json:"localizationSettings,omitempty"`// MaxReportRows: Maximum number of report data rows to return. If the value is// not set, the API returns as many rows as possible, up to 100000. Acceptable// values are 1-100000, inclusive. Values larger than 100000 return an error.MaxReportRowsint64 `json:"maxReportRows,omitempty"`// Metrics: List of metrics of the report. A report must specify at least one// metric.//// Possible values:// "METRIC_UNSPECIFIED" - Default value for an unset field. Do not use.// "AD_REQUESTS" - The number of requests. The value is an integer.// "CLICKS" - The number of times a user clicks an ad. The value is an// integer.// "ESTIMATED_EARNINGS" - The estimated earnings of the AdMob publisher. The// currency unit (USD, EUR, or other) of the earning metrics are determined by// the localization setting for currency. The amount is in micros. For example,// $6.50 would be represented as 6500000. Estimated earnings per mediation// group and per ad source instance level is supported dating back to October// 20, 2019. Third-party estimated earnings will show 0 for dates prior to// October 20, 2019.// "IMPRESSIONS" - The total number of ads shown to users. The value is an// integer.// "IMPRESSION_CTR" - The ratio of clicks over impressions. The value is a// double precision (approximate) decimal value.// "MATCHED_REQUESTS" - The number of times ads are returned in response to a// request. The value is an integer.// "MATCH_RATE" - The ratio of matched ad requests over the total ad// requests. The value is a double precision (approximate) decimal value.// "OBSERVED_ECPM" - The third-party ad network's estimated average eCPM. The// currency unit (USD, EUR, or other) of the earning metrics are determined by// the localization setting for currency. The amount is in micros. For example,// $2.30 would be represented as 2300000. The estimated average eCPM per// mediation group and per ad source instance level is supported dating back to// October 20, 2019. Third-party estimated average eCPM will show 0 for dates// prior to October 20, 2019.Metrics []string `json:"metrics,omitempty"`// SortConditions: Describes the sorting of report rows. The order of the// condition in the list defines its precedence; the earlier the condition, the// higher its precedence. If no sort conditions are specified, the row ordering// is undefined.SortConditions []*MediationReportSpecSortCondition `json:"sortConditions,omitempty"`// TimeZone: A report time zone. Accepts an IANA TZ name values, such as// "America/Los_Angeles." If no time zone is defined, the account default takes// effect. Check default value by the get account action. **Warning:** The// "America/Los_Angeles" is the only supported value at the moment.TimeZonestring `json:"timeZone,omitempty"`// ForceSendFields is a list of field names (e.g. "DateRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DateRange") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationReportSpec: The specification for generating an AdMob Mediationreport. For example, the specification to get observed ECPM sliced by adsource and app for the 'US' and 'CN' countries can look like the followingexample: { "date_range": { "start_date": {"year": 2021, "month": 9, "day":1}, "end_date": {"year": 2021, "month": 9, "day": 30} }, "dimensions":["AD_SOURCE", "APP", "COUNTRY"], "metrics": ["OBSERVED_ECPM"],"dimension_filters": [ { "dimension": "COUNTRY", "matches_any": {"values":[{"value": "US", "value": "CN"}]} } ], "sort_conditions": [{"dimension":"APP", order: "ASCENDING"} ], "localization_settings": {"currency_code": "USD", "language_code": "en-US" } } For a betterunderstanding, you can treat the preceding specification like the followingpseudo SQL: SELECT AD_SOURCE, APP, COUNTRY, OBSERVED_ECPM FROMMEDIATION_REPORT WHERE DATE >= '2021-09-01' AND DATE <= '2021-09-30' ANDCOUNTRY IN ('US', 'CN') GROUP BY AD_SOURCE, APP, COUNTRY ORDER BY APP ASC;
func (MediationReportSpec)MarshalJSON¶
func (sMediationReportSpec) MarshalJSON() ([]byte,error)
typeMediationReportSpecDimensionFilter¶
type MediationReportSpecDimensionFilter struct {// Dimension: Applies the filter criterion to the specified dimension.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701"). Requests// can specify at most one time dimension.// "MONTH" - A month in the YYYYMM format (for example, "202107"). Requests// can specify at most one time dimension.// "WEEK" - The date of the first day of a week in the YYYYMMDD format (for// example, "20210701"). Requests can specify at most one time dimension.// "AD_SOURCE" - The [unique ID of the ad source](/admob/api/v1/ad_sources)// (for example, "5450213213286189855" and "AdMob Network" as label value).// "AD_SOURCE_INSTANCE" - The unique ID of the ad source instance (for// example, "ca-app-pub-1234:asi:5678" and "AdMob (default)" as label value).// "AD_UNIT" - The unique ID of the ad unit (for example,// "ca-app-pub-1234/8790"). If AD_UNIT dimension is specified, then APP is// included automatically.// "APP" - The unique ID of the mobile application (for example,// "ca-app-pub-1234~1234").// "MEDIATION_GROUP" - The unique ID of the mediation group (for example,// "ca-app-pub-1234:mg:1234" and "AdMob (default)" as label value).// "COUNTRY" - CLDR country code of the place where the ad views/clicks occur// (for example, "US" or "FR"). This is a geography dimension.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.// "PLATFORM" - Mobile OS platform of the app (for example, "Android" or// "iOS").// "MOBILE_OS_VERSION" - Mobile operating system version, e.g. "iOS 13.5.1".// "GMA_SDK_VERSION" - GMA SDK version, e.g. "iOS 7.62.0".// "APP_VERSION_NAME" - For Android, the app version name can be found in// versionName in PackageInfo. For iOS, the app version name can be found in// CFBundleShortVersionString.// "SERVING_RESTRICTION" - Restriction mode for ads serving (e.g.// "Non-personalized ads").Dimensionstring `json:"dimension,omitempty"`// MatchesAny: Matches a row if its value for the specified dimension is in one// of the values specified in this condition.MatchesAny *StringList `json:"matchesAny,omitempty"`// ForceSendFields is a list of field names (e.g. "Dimension") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Dimension") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationReportSpecDimensionFilter: Describes which report rows to matchbased on their dimension values.
func (MediationReportSpecDimensionFilter)MarshalJSON¶
func (sMediationReportSpecDimensionFilter) MarshalJSON() ([]byte,error)
typeMediationReportSpecSortCondition¶
type MediationReportSpecSortCondition struct {// Dimension: Sort by the specified dimension.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701"). Requests// can specify at most one time dimension.// "MONTH" - A month in the YYYYMM format (for example, "202107"). Requests// can specify at most one time dimension.// "WEEK" - The date of the first day of a week in the YYYYMMDD format (for// example, "20210701"). Requests can specify at most one time dimension.// "AD_SOURCE" - The [unique ID of the ad source](/admob/api/v1/ad_sources)// (for example, "5450213213286189855" and "AdMob Network" as label value).// "AD_SOURCE_INSTANCE" - The unique ID of the ad source instance (for// example, "ca-app-pub-1234:asi:5678" and "AdMob (default)" as label value).// "AD_UNIT" - The unique ID of the ad unit (for example,// "ca-app-pub-1234/8790"). If AD_UNIT dimension is specified, then APP is// included automatically.// "APP" - The unique ID of the mobile application (for example,// "ca-app-pub-1234~1234").// "MEDIATION_GROUP" - The unique ID of the mediation group (for example,// "ca-app-pub-1234:mg:1234" and "AdMob (default)" as label value).// "COUNTRY" - CLDR country code of the place where the ad views/clicks occur// (for example, "US" or "FR"). This is a geography dimension.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.// "PLATFORM" - Mobile OS platform of the app (for example, "Android" or// "iOS").// "MOBILE_OS_VERSION" - Mobile operating system version, e.g. "iOS 13.5.1".// "GMA_SDK_VERSION" - GMA SDK version, e.g. "iOS 7.62.0".// "APP_VERSION_NAME" - For Android, the app version name can be found in// versionName in PackageInfo. For iOS, the app version name can be found in// CFBundleShortVersionString.// "SERVING_RESTRICTION" - Restriction mode for ads serving (e.g.// "Non-personalized ads").Dimensionstring `json:"dimension,omitempty"`// Metric: Sort by the specified metric.//// Possible values:// "METRIC_UNSPECIFIED" - Default value for an unset field. Do not use.// "AD_REQUESTS" - The number of requests. The value is an integer.// "CLICKS" - The number of times a user clicks an ad. The value is an// integer.// "ESTIMATED_EARNINGS" - The estimated earnings of the AdMob publisher. The// currency unit (USD, EUR, or other) of the earning metrics are determined by// the localization setting for currency. The amount is in micros. For example,// $6.50 would be represented as 6500000. Estimated earnings per mediation// group and per ad source instance level is supported dating back to October// 20, 2019. Third-party estimated earnings will show 0 for dates prior to// October 20, 2019.// "IMPRESSIONS" - The total number of ads shown to users. The value is an// integer.// "IMPRESSION_CTR" - The ratio of clicks over impressions. The value is a// double precision (approximate) decimal value.// "MATCHED_REQUESTS" - The number of times ads are returned in response to a// request. The value is an integer.// "MATCH_RATE" - The ratio of matched ad requests over the total ad// requests. The value is a double precision (approximate) decimal value.// "OBSERVED_ECPM" - The third-party ad network's estimated average eCPM. The// currency unit (USD, EUR, or other) of the earning metrics are determined by// the localization setting for currency. The amount is in micros. For example,// $2.30 would be represented as 2300000. The estimated average eCPM per// mediation group and per ad source instance level is supported dating back to// October 20, 2019. Third-party estimated average eCPM will show 0 for dates// prior to October 20, 2019.Metricstring `json:"metric,omitempty"`// Order: Sorting order of the dimension or metric.//// Possible values:// "SORT_ORDER_UNSPECIFIED" - Default value for an unset field. Do not use.// "ASCENDING" - Sort dimension value or metric value in ascending order.// "DESCENDING" - Sort dimension value or metric value in descending order.Orderstring `json:"order,omitempty"`// ForceSendFields is a list of field names (e.g. "Dimension") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Dimension") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MediationReportSpecSortCondition: Sorting direction to be applied on adimension or a metric.
func (MediationReportSpecSortCondition)MarshalJSON¶
func (sMediationReportSpecSortCondition) MarshalJSON() ([]byte,error)
typeNetworkReportSpec¶
type NetworkReportSpec struct {// DateRange: The date range for which the report is generated.DateRange *DateRange `json:"dateRange,omitempty"`// DimensionFilters: Describes which report rows to match based on their// dimension values.DimensionFilters []*NetworkReportSpecDimensionFilter `json:"dimensionFilters,omitempty"`// Dimensions: List of dimensions of the report. The value combination of these// dimensions determines the row of the report. If no dimensions are specified,// the report returns a single row of requested metrics for the entire account.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701"). Requests// can specify at most one time dimension.// "MONTH" - A month in the YYYYMM format (for example, "202107"). Requests// can specify at most one time dimension.// "WEEK" - The date of the first day of a week in the YYYYMMDD format (for// example, "20210701"). Requests can specify at most one time dimension.// "AD_UNIT" - The unique ID of the ad unit (for example,// "ca-app-pub-1234/1234"). If AD_UNIT dimension is specified, then APP is// included automatically.// "APP" - The unique ID of the mobile application (for example,// "ca-app-pub-1234~1234").// "AD_TYPE" - Type of the ad (for example, "text" or "image"), an ad// delivery dimension. **Warning:** The dimension is incompatible with// [AD_REQUESTS](#Metric.ENUM_VALUES.AD_REQUESTS),// [MATCH_RATE](#Metric.ENUM_VALUES.MATCH_RATE) and// [IMPRESSION_RPM](#Metric.ENUM_VALUES.IMPRESSION_RPM) metrics.// "COUNTRY" - CLDR country code of the place where the ad views/clicks occur// (for example, "US" or "FR"). This is a geography dimension.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.// "PLATFORM" - Mobile OS platform of the app (for example, "Android" or// "iOS").// "MOBILE_OS_VERSION" - Mobile operating system version, e.g. "iOS 13.5.1".// "GMA_SDK_VERSION" - GMA SDK version, e.g. "iOS 7.62.0".// "APP_VERSION_NAME" - For Android, the app version name can be found in// versionName in PackageInfo. For iOS, the app version name can be found in// CFBundleShortVersionString.// "SERVING_RESTRICTION" - Restriction mode for ads serving (e.g.// "Non-personalized ads").Dimensions []string `json:"dimensions,omitempty"`// LocalizationSettings: Localization settings of the report.LocalizationSettings *LocalizationSettings `json:"localizationSettings,omitempty"`// MaxReportRows: Maximum number of report data rows to return. If the value is// not set, the API returns as many rows as possible, up to 100000. Acceptable// values are 1-100000, inclusive. Values larger than 100000 return an error.MaxReportRowsint64 `json:"maxReportRows,omitempty"`// Metrics: List of metrics of the report. A report must specify at least one// metric.//// Possible values:// "METRIC_UNSPECIFIED" - Default value for an unset field. Do not use.// "AD_REQUESTS" - The number of ad requests. The value is an integer.// **Warning:** The metric is incompatible with// [AD_TYPE](#Dimension.ENUM_VALUES.AD_TYPE) dimension.// "CLICKS" - The number of times a user clicks an ad. The value is an// integer.// "ESTIMATED_EARNINGS" - The estimated earnings of the AdMob publisher. The// currency unit (USD, EUR, or other) of the earning metrics are determined by// the localization setting for currency. The amount is in micros. For example,// $6.50 would be represented as 6500000.// "IMPRESSIONS" - The total number of ads shown to users. The value is an// integer.// "IMPRESSION_CTR" - The ratio of clicks over impressions. The value is a// double precision (approximate) decimal value.// "IMPRESSION_RPM" - The estimated earnings per thousand ad impressions. The// value is in micros. For example, $1.03 would be represented as 1030000.// Equivalent to eCPM in the AdMob UI. **Warning:** The metric is incompatible// with [AD_TYPE](#Dimension.ENUM_VALUES.AD_TYPE) dimension.// "MATCHED_REQUESTS" - The number of times ads are returned in response to a// request. The value is an integer.// "MATCH_RATE" - The ratio of matched ad requests over the total ad// requests. The value is a double precision (approximate) decimal value.// **Warning:** The metric is incompatible with// [AD_TYPE](#Dimension.ENUM_VALUES.AD_TYPE) dimension.// "SHOW_RATE" - The ratio of ads that are displayed over ads that are// returned, defined as impressions / matched requests. The value is a double// precision (approximate) decimal value.Metrics []string `json:"metrics,omitempty"`// SortConditions: Describes the sorting of report rows. The order of the// condition in the list defines its precedence; the earlier the condition, the// higher its precedence. If no sort conditions are specified, the row ordering// is undefined.SortConditions []*NetworkReportSpecSortCondition `json:"sortConditions,omitempty"`// TimeZone: A report time zone. Accepts an IANA TZ name values, such as// "America/Los_Angeles." If no time zone is defined, the account default takes// effect. Check default value by the get account action. **Warning:** The// "America/Los_Angeles" is the only supported value at the moment.TimeZonestring `json:"timeZone,omitempty"`// ForceSendFields is a list of field names (e.g. "DateRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DateRange") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}NetworkReportSpec: The specification for generating an AdMob Network report.For example, the specification to get clicks and estimated earnings for onlythe 'US' and 'CN' countries can look like the following example: {'date_range': { 'start_date': {'year': 2021, 'month': 9, 'day': 1},'end_date': {'year': 2021, 'month': 9, 'day': 30} }, 'dimensions': ['DATE','APP', 'COUNTRY'], 'metrics': ['CLICKS', 'ESTIMATED_EARNINGS'],'dimension_filters': [ { 'dimension': 'COUNTRY', 'matches_any': {'values':[{'value': 'US', 'value': 'CN'}]} } ], 'sort_conditions': [{'dimension':'APP', order: 'ASCENDING'}, {'metric':'CLICKS', order:'DESCENDING'} ], 'localization_settings': { 'currency_code': 'USD','language_code': 'en-US' } } For a better understanding, you can treat thepreceding specification like the following pseudo SQL: SELECT DATE, APP,COUNTRY, CLICKS, ESTIMATED_EARNINGS FROM NETWORK_REPORT WHERE DATE >='2021-09-01' AND DATE <= '2021-09-30' AND COUNTRY IN ('US', 'CN') GROUP BYDATE, APP, COUNTRY ORDER BY APP ASC, CLICKS DESC;
func (NetworkReportSpec)MarshalJSON¶
func (sNetworkReportSpec) MarshalJSON() ([]byte,error)
typeNetworkReportSpecDimensionFilter¶
type NetworkReportSpecDimensionFilter struct {// Dimension: Applies the filter criterion to the specified dimension.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701"). Requests// can specify at most one time dimension.// "MONTH" - A month in the YYYYMM format (for example, "202107"). Requests// can specify at most one time dimension.// "WEEK" - The date of the first day of a week in the YYYYMMDD format (for// example, "20210701"). Requests can specify at most one time dimension.// "AD_UNIT" - The unique ID of the ad unit (for example,// "ca-app-pub-1234/1234"). If AD_UNIT dimension is specified, then APP is// included automatically.// "APP" - The unique ID of the mobile application (for example,// "ca-app-pub-1234~1234").// "AD_TYPE" - Type of the ad (for example, "text" or "image"), an ad// delivery dimension. **Warning:** The dimension is incompatible with// [AD_REQUESTS](#Metric.ENUM_VALUES.AD_REQUESTS),// [MATCH_RATE](#Metric.ENUM_VALUES.MATCH_RATE) and// [IMPRESSION_RPM](#Metric.ENUM_VALUES.IMPRESSION_RPM) metrics.// "COUNTRY" - CLDR country code of the place where the ad views/clicks occur// (for example, "US" or "FR"). This is a geography dimension.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.// "PLATFORM" - Mobile OS platform of the app (for example, "Android" or// "iOS").// "MOBILE_OS_VERSION" - Mobile operating system version, e.g. "iOS 13.5.1".// "GMA_SDK_VERSION" - GMA SDK version, e.g. "iOS 7.62.0".// "APP_VERSION_NAME" - For Android, the app version name can be found in// versionName in PackageInfo. For iOS, the app version name can be found in// CFBundleShortVersionString.// "SERVING_RESTRICTION" - Restriction mode for ads serving (e.g.// "Non-personalized ads").Dimensionstring `json:"dimension,omitempty"`// MatchesAny: Matches a row if its value for the specified dimension is in one// of the values specified in this condition.MatchesAny *StringList `json:"matchesAny,omitempty"`// ForceSendFields is a list of field names (e.g. "Dimension") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Dimension") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}NetworkReportSpecDimensionFilter: Describes which report rows to match basedon their dimension values.
func (NetworkReportSpecDimensionFilter)MarshalJSON¶
func (sNetworkReportSpecDimensionFilter) MarshalJSON() ([]byte,error)
typeNetworkReportSpecSortCondition¶
type NetworkReportSpecSortCondition struct {// Dimension: Sort by the specified dimension.//// Possible values:// "DIMENSION_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATE" - A date in the YYYYMMDD format (for example, "20210701"). Requests// can specify at most one time dimension.// "MONTH" - A month in the YYYYMM format (for example, "202107"). Requests// can specify at most one time dimension.// "WEEK" - The date of the first day of a week in the YYYYMMDD format (for// example, "20210701"). Requests can specify at most one time dimension.// "AD_UNIT" - The unique ID of the ad unit (for example,// "ca-app-pub-1234/1234"). If AD_UNIT dimension is specified, then APP is// included automatically.// "APP" - The unique ID of the mobile application (for example,// "ca-app-pub-1234~1234").// "AD_TYPE" - Type of the ad (for example, "text" or "image"), an ad// delivery dimension. **Warning:** The dimension is incompatible with// [AD_REQUESTS](#Metric.ENUM_VALUES.AD_REQUESTS),// [MATCH_RATE](#Metric.ENUM_VALUES.MATCH_RATE) and// [IMPRESSION_RPM](#Metric.ENUM_VALUES.IMPRESSION_RPM) metrics.// "COUNTRY" - CLDR country code of the place where the ad views/clicks occur// (for example, "US" or "FR"). This is a geography dimension.// "FORMAT" - Format of the ad unit (for example, "banner", "native"), an ad// delivery dimension.// "PLATFORM" - Mobile OS platform of the app (for example, "Android" or// "iOS").// "MOBILE_OS_VERSION" - Mobile operating system version, e.g. "iOS 13.5.1".// "GMA_SDK_VERSION" - GMA SDK version, e.g. "iOS 7.62.0".// "APP_VERSION_NAME" - For Android, the app version name can be found in// versionName in PackageInfo. For iOS, the app version name can be found in// CFBundleShortVersionString.// "SERVING_RESTRICTION" - Restriction mode for ads serving (e.g.// "Non-personalized ads").Dimensionstring `json:"dimension,omitempty"`// Metric: Sort by the specified metric.//// Possible values:// "METRIC_UNSPECIFIED" - Default value for an unset field. Do not use.// "AD_REQUESTS" - The number of ad requests. The value is an integer.// **Warning:** The metric is incompatible with// [AD_TYPE](#Dimension.ENUM_VALUES.AD_TYPE) dimension.// "CLICKS" - The number of times a user clicks an ad. The value is an// integer.// "ESTIMATED_EARNINGS" - The estimated earnings of the AdMob publisher. The// currency unit (USD, EUR, or other) of the earning metrics are determined by// the localization setting for currency. The amount is in micros. For example,// $6.50 would be represented as 6500000.// "IMPRESSIONS" - The total number of ads shown to users. The value is an// integer.// "IMPRESSION_CTR" - The ratio of clicks over impressions. The value is a// double precision (approximate) decimal value.// "IMPRESSION_RPM" - The estimated earnings per thousand ad impressions. The// value is in micros. For example, $1.03 would be represented as 1030000.// Equivalent to eCPM in the AdMob UI. **Warning:** The metric is incompatible// with [AD_TYPE](#Dimension.ENUM_VALUES.AD_TYPE) dimension.// "MATCHED_REQUESTS" - The number of times ads are returned in response to a// request. The value is an integer.// "MATCH_RATE" - The ratio of matched ad requests over the total ad// requests. The value is a double precision (approximate) decimal value.// **Warning:** The metric is incompatible with// [AD_TYPE](#Dimension.ENUM_VALUES.AD_TYPE) dimension.// "SHOW_RATE" - The ratio of ads that are displayed over ads that are// returned, defined as impressions / matched requests. The value is a double// precision (approximate) decimal value.Metricstring `json:"metric,omitempty"`// Order: Sorting order of the dimension or metric.//// Possible values:// "SORT_ORDER_UNSPECIFIED" - Default value for an unset field. Do not use.// "ASCENDING" - Sort dimension value or metric value in ascending order.// "DESCENDING" - Sort dimension value or metric value in descending order.Orderstring `json:"order,omitempty"`// ForceSendFields is a list of field names (e.g. "Dimension") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Dimension") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}NetworkReportSpecSortCondition: Sorting direction to be applied on adimension or a metric.
func (NetworkReportSpecSortCondition)MarshalJSON¶
func (sNetworkReportSpecSortCondition) MarshalJSON() ([]byte,error)
typePublisherAccount¶
type PublisherAccount struct {// CurrencyCode: Currency code of the earning-related metrics, which is the// 3-letter code defined in ISO 4217. The daily average rate is used for the// currency conversion.CurrencyCodestring `json:"currencyCode,omitempty"`// Name: Resource name of this account. Format is accounts/{publisher_id}.Namestring `json:"name,omitempty"`// PublisherId: The unique ID by which this publisher account can be identified// in the API requests (for example, pub-1234567890).PublisherIdstring `json:"publisherId,omitempty"`// ReportingTimeZone: The time zone that is used in reports that are generated// for this account. The value is a time-zone ID as specified by the CLDR// project, for example, "America/Los_Angeles".ReportingTimeZonestring `json:"reportingTimeZone,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "CurrencyCode") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CurrencyCode") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PublisherAccount: A publisher account contains information relevant to theuse of this API, such as the time zone used for the reports.
func (PublisherAccount)MarshalJSON¶
func (sPublisherAccount) MarshalJSON() ([]byte,error)
typeReportFooter¶
type ReportFooter struct {// MatchingRowCount: Total number of rows that matched the request. Warning:// This count does NOT always match the number of rows in the response. Do not// make that assumption when processing the response.MatchingRowCountint64 `json:"matchingRowCount,omitempty,string"`// Warnings: Warnings associated with generation of the report.Warnings []*ReportWarning `json:"warnings,omitempty"`// ForceSendFields is a list of field names (e.g. "MatchingRowCount") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MatchingRowCount") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReportFooter: Groups data available after report generation, for example,warnings and row counts. Always sent as the last message in the streamresponse.
func (ReportFooter)MarshalJSON¶
func (sReportFooter) MarshalJSON() ([]byte,error)
typeReportHeader¶
type ReportHeader struct {// DateRange: The date range for which the report is generated. This is// identical to the range specified in the report request.DateRange *DateRange `json:"dateRange,omitempty"`// LocalizationSettings: Localization settings of the report. This is identical// to the settings in the report request.LocalizationSettings *LocalizationSettings `json:"localizationSettings,omitempty"`// ReportingTimeZone: The report time zone. The value is a time-zone ID as// specified by the CLDR project, for example, "America/Los_Angeles".ReportingTimeZonestring `json:"reportingTimeZone,omitempty"`// ForceSendFields is a list of field names (e.g. "DateRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DateRange") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReportHeader: Groups data helps to treat the generated report. Always sentas a first message in the stream response.
func (ReportHeader)MarshalJSON¶
func (sReportHeader) MarshalJSON() ([]byte,error)
typeReportRow¶
type ReportRow struct {// DimensionValues: Map of dimension values in a row, with keys as enum name of// the dimensions.DimensionValues map[string]ReportRowDimensionValue `json:"dimensionValues,omitempty"`// MetricValues: Map of metric values in a row, with keys as enum name of the// metrics. If a metric being requested has no value returned, the map will not// include it.MetricValues map[string]ReportRowMetricValue `json:"metricValues,omitempty"`// ForceSendFields is a list of field names (e.g. "DimensionValues") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DimensionValues") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReportRow: A row of the returning report.
func (ReportRow)MarshalJSON¶
typeReportRowDimensionValue¶
type ReportRowDimensionValue struct {// DisplayLabel: The localized string representation of the value. If// unspecified, the display label should be derived from the value.DisplayLabelstring `json:"displayLabel,omitempty"`// Value: Dimension value in the format specified in the report's spec// Dimension enum.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "DisplayLabel") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DisplayLabel") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReportRowDimensionValue: Representation of a dimension value.
func (ReportRowDimensionValue)MarshalJSON¶
func (sReportRowDimensionValue) MarshalJSON() ([]byte,error)
typeReportRowMetricValue¶
type ReportRowMetricValue struct {// DoubleValue: Double precision (approximate) decimal values. Rates are from 0// to 1.DoubleValuefloat64 `json:"doubleValue,omitempty"`// IntegerValue: Metric integer value.IntegerValueint64 `json:"integerValue,omitempty,string"`// MicrosValue: Amount in micros. One million is equivalent to one unit.// Currency value is in the unit (USD, EUR or other) specified by the request.// For example, $6.50 whould be represented as 6500000 micros.MicrosValueint64 `json:"microsValue,omitempty,string"`// ForceSendFields is a list of field names (e.g. "DoubleValue") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DoubleValue") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReportRowMetricValue: Representation of a metric value.
func (ReportRowMetricValue)MarshalJSON¶
func (sReportRowMetricValue) MarshalJSON() ([]byte,error)
func (*ReportRowMetricValue)UnmarshalJSON¶
func (s *ReportRowMetricValue) UnmarshalJSON(data []byte)error
typeReportWarning¶
type ReportWarning struct {// Description: Describes the details of the warning message, in English.Descriptionstring `json:"description,omitempty"`// Type: Type of the warning.//// Possible values:// "TYPE_UNSPECIFIED" - Default value for an unset field. Do not use.// "DATA_BEFORE_ACCOUNT_TIMEZONE_CHANGE" - Some data in this report is// aggregated based on a time zone different from the requested time zone. This// could happen if a local time-zone report has the start time before the last// time this time zone changed. The description field will contain the date of// the last time zone change.// "DATA_DELAYED" - There is an unusual delay in processing the source data// for the requested date range. The report results might be less up to date// than usual. AdMob is aware of the issue and is actively working to resolve// it.// "OTHER" - Warnings that are exposed without a specific type. Useful when// new warning types are added but the API is not changed yet.// "REPORT_CURRENCY_NOT_ACCOUNT_CURRENCY" - The currency being requested is// not the account currency. The earning metrics will be based on the requested// currency, and thus not a good estimation of the final payment anymore, due// to the currency rate fluctuation.Typestring `json:"type,omitempty"`// ForceSendFields is a list of field names (e.g. "Description") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Description") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReportWarning: Warnings associated with generation of the report.
func (ReportWarning)MarshalJSON¶
func (sReportWarning) MarshalJSON() ([]byte,error)
typeService¶
type Service struct {BasePathstring// API endpoint base URLUserAgentstring// optional additional User-Agent fragmentAccounts *AccountsService// contains filtered or unexported fields} funcNewdeprecated
New creates a new Service. It uses the provided http.Client for requests.
Deprecated: please use NewService instead.To provide a custom HTTP client, use option.WithHTTPClient.If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
funcNewService¶
NewService creates a new Service.
typeStopMediationAbExperimentRequest¶added inv0.139.0
type StopMediationAbExperimentRequest struct {// VariantChoice: The choice for the winning variant.//// Possible values:// "VARIANT_CHOICE_UNSPECIFIED" - Default value for an unset field. Do not// use.// "VARIANT_CHOICE_A" - Use the mediation lines from Variant A and complete// the experiment. Variant A contains the original serving lines before the// experiment creation.// "VARIANT_CHOICE_B" - Use the mediation lines form Variant B and complete// the experiment. Variant B contains the newly added serving lines.VariantChoicestring `json:"variantChoice,omitempty"`// ForceSendFields is a list of field names (e.g. "VariantChoice") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "VariantChoice") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}StopMediationAbExperimentRequest: Request to end the mediation A/Bexperiment and choose a winning variant.
func (StopMediationAbExperimentRequest)MarshalJSON¶added inv0.139.0
func (sStopMediationAbExperimentRequest) MarshalJSON() ([]byte,error)
typeStringList¶
type StringList struct {// Values: The string values.Values []string `json:"values,omitempty"`// ForceSendFields is a list of field names (e.g. "Values") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Values") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}StringList: List of string values.
func (StringList)MarshalJSON¶
func (sStringList) MarshalJSON() ([]byte,error)