Hierarchy

  • Operation
    • SponsoredProductsAdGroupKeywordsOperation

Constructors

Methods

  • Sets the keyword status to archived. This same operation can be performed via an update, but is included for completeness. Archived entities cannot be made active again. See developer notes for more information.

    Returns

    Parameters

    • keywordId: number

    Returns Promise<{ code: "NOT_FOUND" | "SUCCESS" | "INVALID_ARGUMENT"; keywordId: number } & { details: undefined | string }>

  • Creates one or more keywords. Successfully created keywords will be assigned a unique keywordId.

    Returns

    Parameters

    • keywords: { adGroupId: number; campaignId: number; keywordText: string; matchType: "exact" | "broad" | "phrase"; state: "paused" | "enabled" | "archived" }[]

    Returns Promise<({ code: "NOT_FOUND" | "SUCCESS" | "INVALID_ARGUMENT"; keywordId: number } & { details: undefined | string })[]>

  • Retrieves a keyword by ID. Note that this call returns the minimal set of keyword fields, but is more efficient than getBiddableKeywordEx

    Returns

    Parameters

    • keywordId: number

    Returns Promise<{ adGroupId: number; campaignId: number; keywordId: number; keywordText: string; matchType: "exact" | "broad" | "phrase"; state: "paused" | "enabled" | "archived" } & { bid: undefined | number }>

  • Retrieves a keyword and its extended fields by ID. Note that this call returns the complete set of keyword fields (including serving status and other read-only fields), but is less efficient than getBiddableKeyword. There is no extended keywords interface for Sponsored Brands.

    Returns

    Parameters

    • keywordId: number

    Returns Promise<{ adGroupId: number; campaignId: number; keywordId: number; keywordText: string; matchType: "exact" | "broad" | "phrase"; state: "paused" | "enabled" | "archived" } & { bid: undefined | number } & { creationDate: Date; lastUpdatedDate: Date; servingStatus: "CAMPAIGN_ARCHIVED" | "CAMPAIGN_PAUSED" | "ADVERTISER_PAYMENT_FAILURE" | "CAMPAIGN_OUT_OF_BUDGET" | "ACCOUNT_OUT_OF_BUDGET" | "CAMPAIGN_INCOMPLETE" | "AD_GROUP_ARCHIVED" | "AD_GROUP_PAUSED" | "TARGETING_CLAUSE_ARCHIVED" | "TARGETING_CLAUSE_PAUSED" | "TARGETING_CLAUSE_STATUS_LIVE" | "TARGETING_CLAUSE_POLICING_SUSPENDED" }>

  • Retrieves a list of keywords satisfying optional criteria for Sponsored Products. List keyword operations are not supported for Sponsored Brands.

    Returns

    Parameters

    • Optional params: { count: undefined | number; startIndex: undefined | number } & { adGroupIdFilter: undefined | number[]; campaignIdFilter: undefined | number[]; keywordText: undefined | string; matchTypeFilter: undefined | "exact" | "broad" | "phrase"; stateFilter: undefined | "paused" | "enabled" | "archived" }

    Returns Promise<({ adGroupId: number; campaignId: number; keywordId: number; keywordText: string; matchType: "exact" | "broad" | "phrase"; state: "paused" | "enabled" | "archived" } & { bid: undefined | number })[]>

  • Retrieves a list of keywords and its extended fields satisfying optional criteria for Sponsored Products. List keyword operations are not supported for Sponsored Brands.

    Returns

    Parameters

    • Optional params: { count: undefined | number; startIndex: undefined | number } & { adGroupIdFilter: undefined | number[]; campaignIdFilter: undefined | number[]; keywordText: undefined | string; matchTypeFilter: undefined | "exact" | "broad" | "phrase"; stateFilter: undefined | "paused" | "enabled" | "archived" } & { campaignType: undefined | "exact" | "broad" | "phrase"; keywordIdFilter: undefined | number[] }

    Returns Promise<({ adGroupId: number; campaignId: number; keywordId: number; keywordText: string; matchType: "exact" | "broad" | "phrase"; state: "paused" | "enabled" | "archived" } & { bid: undefined | number } & { creationDate: Date; lastUpdatedDate: Date; servingStatus: "CAMPAIGN_ARCHIVED" | "CAMPAIGN_PAUSED" | "ADVERTISER_PAYMENT_FAILURE" | "CAMPAIGN_OUT_OF_BUDGET" | "ACCOUNT_OUT_OF_BUDGET" | "CAMPAIGN_INCOMPLETE" | "AD_GROUP_ARCHIVED" | "AD_GROUP_PAUSED" | "TARGETING_CLAUSE_ARCHIVED" | "TARGETING_CLAUSE_PAUSED" | "TARGETING_CLAUSE_STATUS_LIVE" | "TARGETING_CLAUSE_POLICING_SUSPENDED" })[]>

  • Updates one or more keywords. While keywords are in a pending state you can only update the bid amount, or archive them. You cannot change the state from pending

    Returns

    Parameters

    • keywords: { bid: number; keywordId: number; state: "paused" | "enabled" | "archived" }[]

    Returns Promise<({ code: "NOT_FOUND" | "SUCCESS" | "INVALID_ARGUMENT"; keywordId: number } & { details: undefined | string })[]>