Documentation ¶
Overview ¶
Package adexchangebuyer provides access to the Ad Exchange Buyer API.
See https://developers.google.com/ad-exchange/buyer-rest
Usage example:
import "google.golang.org/api/adexchangebuyer/v1" ... adexchangebuyerService, err := adexchangebuyer.New(oauthHttpClient)
Index ¶
- Constants
- type Account
- type AccountBidderLocation
- type AccountsGetCall
- type AccountsList
- type AccountsListCall
- type AccountsPatchCall
- type AccountsService
- type AccountsUpdateCall
- type Creative
- type CreativesGetCall
- type CreativesInsertCall
- type CreativesList
- type CreativesListCall
- type CreativesService
- type Service
Constants ¶
const (
// Manage your Ad Exchange buyer account configuration
AdexchangeBuyerScope = "https://www.googleapis.com/auth/adexchange.buyer"
)
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { // BidderLocation: Your bidder locations that have distinct URLs. BidderLocation []*AccountBidderLocation `json:"bidderLocation,omitempty"` // CookieMatchingNid: The nid parameter value used in cookie match // requests. Please contact your technical account manager if you need // to change this. CookieMatchingNid string `json:"cookieMatchingNid,omitempty"` // CookieMatchingUrl: The base URL used in cookie match requests. CookieMatchingUrl string `json:"cookieMatchingUrl,omitempty"` // Id: Account id. Id int64 `json:"id,omitempty"` // Kind: Resource type. Kind string `json:"kind,omitempty"` // MaximumActiveCreatives: The maximum number of active creatives that // an account can have, where a creative is active if it was inserted or // bid with in the last 30 days. Please contact your technical account // manager if you need to change this. MaximumActiveCreatives int64 `json:"maximumActiveCreatives,omitempty"` // MaximumTotalQps: The sum of all bidderLocation.maximumQps values // cannot exceed this. Please contact your technical account manager if // you need to change this. MaximumTotalQps int64 `json:"maximumTotalQps,omitempty"` // NumberActiveCreatives: The number of creatives that this account // inserted or bid with in the last 30 days. NumberActiveCreatives int64 `json:"numberActiveCreatives,omitempty"` }
type AccountBidderLocation ¶
type AccountBidderLocation struct { // MaximumQps: The maximum queries per second the Ad Exchange will send. MaximumQps int64 `json:"maximumQps,omitempty"` // Region: The geographical region the Ad Exchange should send requests // from. Only used by some quota systems, but always setting the value // is recommended. Allowed values: // - ASIA // - EUROPE // - US_EAST // - // US_WEST Region string `json:"region,omitempty"` // Url: The URL to which the Ad Exchange will send bid requests. Url string `json:"url,omitempty"` }
type AccountsGetCall ¶
type AccountsGetCall struct {
// contains filtered or unexported fields
}
func (*AccountsGetCall) Do ¶
func (c *AccountsGetCall) Do() (*Account, error)
func (*AccountsGetCall) Fields ¶
func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type AccountsList ¶
type AccountsListCall ¶
type AccountsListCall struct {
// contains filtered or unexported fields
}
func (*AccountsListCall) Do ¶
func (c *AccountsListCall) Do() (*AccountsList, error)
func (*AccountsListCall) Fields ¶
func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type AccountsPatchCall ¶
type AccountsPatchCall struct {
// contains filtered or unexported fields
}
func (*AccountsPatchCall) Do ¶
func (c *AccountsPatchCall) Do() (*Account, error)
func (*AccountsPatchCall) Fields ¶
func (c *AccountsPatchCall) Fields(s ...googleapi.Field) *AccountsPatchCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type AccountsService ¶
type AccountsService struct {
// contains filtered or unexported fields
}
func NewAccountsService ¶
func NewAccountsService(s *Service) *AccountsService
func (*AccountsService) Get ¶
func (r *AccountsService) Get(id int64) *AccountsGetCall
Get: Gets one account by ID.
func (*AccountsService) List ¶
func (r *AccountsService) List() *AccountsListCall
List: Retrieves the authenticated user's list of accounts.
func (*AccountsService) Patch ¶
func (r *AccountsService) Patch(id int64, account *Account) *AccountsPatchCall
Patch: Updates an existing account. This method supports patch semantics.
func (*AccountsService) Update ¶
func (r *AccountsService) Update(id int64, account *Account) *AccountsUpdateCall
Update: Updates an existing account.
type AccountsUpdateCall ¶
type AccountsUpdateCall struct {
// contains filtered or unexported fields
}
func (*AccountsUpdateCall) Do ¶
func (c *AccountsUpdateCall) Do() (*Account, error)
func (*AccountsUpdateCall) Fields ¶
func (c *AccountsUpdateCall) Fields(s ...googleapi.Field) *AccountsUpdateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type Creative ¶
type Creative struct { // HTMLSnippet: The HTML snippet that displays the ad when inserted in // the web page. If set, videoURL should not be set. HTMLSnippet string `json:"HTMLSnippet,omitempty"` // AccountId: Account id. AccountId int64 `json:"accountId,omitempty"` // AdgroupId: The pretargeting adgroup id that this creative will be // associated with. AdgroupId int64 `json:"adgroupId,omitempty,string"` // AdvertiserId: Detected advertiser id, if any. Read-only. This field // should not be set in requests. AdvertiserId googleapi.Int64s `json:"advertiserId,omitempty"` // AdvertiserName: The name of the company being advertised in the // creative. AdvertiserName string `json:"advertiserName,omitempty"` // Attribute: All attributes for the ads that may be shown from this // snippet. Attribute []int64 `json:"attribute,omitempty"` // BuyerCreativeId: A buyer-specific id identifying the creative in this // ad. BuyerCreativeId string `json:"buyerCreativeId,omitempty"` // ClickThroughUrl: The set of destination urls for the snippet. ClickThroughUrl []string `json:"clickThroughUrl,omitempty"` // DisapprovalReasons: The reason for disapproval, if any. Note that not // all disapproval reasons may be categorized, so it is possible for the // creative to have a status of DISAPPROVED with an empty list for // disapproval_reasons. In this case, please reach out to your TAM to // help debug the issue. Read-only. This field should not be set in // requests. DisapprovalReasons []string `json:"disapprovalReasons,omitempty"` // Height: Ad height. Height int64 `json:"height,omitempty"` // Kind: Resource type. Kind string `json:"kind,omitempty"` // ProductCategories: Detected product categories, if any. Read-only. // This field should not be set in requests. ProductCategories []int64 `json:"productCategories,omitempty"` // RestrictedCategories: All restricted categories for the ads that may // be shown from this snippet. RestrictedCategories []int64 `json:"restrictedCategories,omitempty"` // SensitiveCategories: Detected sensitive categories, if any. // Read-only. This field should not be set in requests. SensitiveCategories []int64 `json:"sensitiveCategories,omitempty"` // Status: Creative serving status. Read-only. This field should not be // set in requests. Status string `json:"status,omitempty"` // VendorType: All vendor types for the ads that may be shown from this // snippet. VendorType []int64 `json:"vendorType,omitempty"` // VideoURL: The url to fetch a video ad. If set, HTMLSnippet should not // be set. VideoURL string `json:"videoURL,omitempty"` // Width: Ad width. Width int64 `json:"width,omitempty"` }
type CreativesGetCall ¶
type CreativesGetCall struct {
// contains filtered or unexported fields
}
func (*CreativesGetCall) Do ¶
func (c *CreativesGetCall) Do() (*Creative, error)
func (*CreativesGetCall) Fields ¶
func (c *CreativesGetCall) Fields(s ...googleapi.Field) *CreativesGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type CreativesInsertCall ¶
type CreativesInsertCall struct {
// contains filtered or unexported fields
}
func (*CreativesInsertCall) Do ¶
func (c *CreativesInsertCall) Do() (*Creative, error)
func (*CreativesInsertCall) Fields ¶
func (c *CreativesInsertCall) Fields(s ...googleapi.Field) *CreativesInsertCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type CreativesList ¶
type CreativesList struct { // Items: A list of creatives. Items []*Creative `json:"items,omitempty"` // Kind: Resource type. Kind string `json:"kind,omitempty"` // NextPageToken: Continuation token used to page through creatives. To // retrieve the next page of results, set the next request's "pageToken" // value to this. NextPageToken string `json:"nextPageToken,omitempty"` }
type CreativesListCall ¶
type CreativesListCall struct {
// contains filtered or unexported fields
}
func (*CreativesListCall) Do ¶
func (c *CreativesListCall) Do() (*CreativesList, error)
func (*CreativesListCall) Fields ¶
func (c *CreativesListCall) Fields(s ...googleapi.Field) *CreativesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*CreativesListCall) MaxResults ¶
func (c *CreativesListCall) MaxResults(maxResults int64) *CreativesListCall
MaxResults sets the optional parameter "maxResults": Maximum number of entries returned on one result page. If not set, the default is 100.
func (*CreativesListCall) PageToken ¶
func (c *CreativesListCall) PageToken(pageToken string) *CreativesListCall
PageToken sets the optional parameter "pageToken": A continuation token, used to page through ad clients. To retrieve the next page, set this parameter to the value of "nextPageToken" from the previous response.
type CreativesService ¶
type CreativesService struct {
// contains filtered or unexported fields
}
func NewCreativesService ¶
func NewCreativesService(s *Service) *CreativesService
func (*CreativesService) Get ¶
func (r *CreativesService) Get(accountId int64, buyerCreativeId string, adgroupId int64) *CreativesGetCall
Get: Gets the status for a single creative.
func (*CreativesService) Insert ¶
func (r *CreativesService) Insert(creative *Creative) *CreativesInsertCall
Insert: Submit a new creative.
func (*CreativesService) List ¶
func (r *CreativesService) List() *CreativesListCall
List: Retrieves a list of the authenticated user's active creatives.