ads

package
v1.260904.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 4, 2026 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func APICommand

func APICommand() *ffcli.Command

APICommand returns the raw Apple Ads API request command.

func APIRequestCommand

func APIRequestCommand() *ffcli.Command

func AdsCommand

func AdsCommand() *ffcli.Command

AdsCommand returns the Apple Ads root command.

func AuthCommand

func AuthCommand() *ffcli.Command

AuthCommand returns the Apple Ads auth command group.

func AuthDiscoverCommand

func AuthDiscoverCommand() *ffcli.Command

func AuthDoctorCommand

func AuthDoctorCommand() *ffcli.Command

func AuthLoginCommand

func AuthLoginCommand() *ffcli.Command

func AuthLogoutCommand

func AuthLogoutCommand() *ffcli.Command

func AuthStatusCommand

func AuthStatusCommand() *ffcli.Command

func AuthSwitchCommand

func AuthSwitchCommand() *ffcli.Command

func AuthTokenCommand

func AuthTokenCommand() *ffcli.Command

func PlatformAPICommand added in v1.260816.0

func PlatformAPICommand() *ffcli.Command

PlatformAPICommand returns the raw Apple Ads Platform API command group.

func PlatformAPIRequestCommand added in v1.260816.0

func PlatformAPIRequestCommand() *ffcli.Command

PlatformAPIRequestCommand returns the raw Apple Ads Platform API request command.

func PlatformAssetUploadCommand added in v1.260816.0

func PlatformAssetUploadCommand() *ffcli.Command

PlatformAssetUploadCommand returns the dedicated Platform API asset upload command. Unlike the generated mutation commands, this sends multipart image data rather than a JSON payload.

func ReportsPresetCommand

func ReportsPresetCommand() *ffcli.Command

ReportsPresetCommand returns an operator-friendly Apple Ads reporting helper.

func V5Command added in v1.260816.0

func V5Command() *ffcli.Command

V5Command returns the deprecated Campaign Management API v5 command group.

Types

type SearchCampaign added in v1.260819.0

type SearchCampaign struct {
	ID            int64    `json:"id"`
	Name          string   `json:"name,omitempty"`
	Status        string   `json:"status,omitempty"`
	DisplayStatus string   `json:"displayStatus,omitempty"`
	Countries     []string `json:"countries,omitempty"`
}

SearchCampaign is the app campaign context used to scope dependent queries.

type SearchEligibility added in v1.260819.0

type SearchEligibility struct {
	Country         string   `json:"country,omitempty"`
	SupplyPlacement string   `json:"supplyPlacement,omitempty"`
	DeviceClass     string   `json:"deviceClass,omitempty"`
	State           string   `json:"state"`
	Reasons         []string `json:"reasons,omitempty"`
}

SearchEligibility describes one placement/storefront eligibility row.

type SearchImpressionShare added in v1.260819.0

type SearchImpressionShare struct {
	Term        string   `json:"term"`
	Country     string   `json:"country,omitempty"`
	Day         string   `json:"day,omitempty"`
	Week        string   `json:"week,omitempty"`
	Low         *float64 `json:"low,omitempty"`
	High        *float64 `json:"high,omitempty"`
	Rank        *int     `json:"rank,omitempty"`
	Popularity5 *int     `json:"popularity5,omitempty"`
}

SearchImpressionShare is one app-specific paid reach row.

type SearchNegativeKeyword added in v1.260819.0

type SearchNegativeKeyword struct {
	Text       string `json:"text"`
	MatchType  string `json:"matchType"`
	Status     string `json:"status,omitempty"`
	CampaignID int64  `json:"campaignId"`
	AdGroupID  int64  `json:"adGroupId,omitempty"`
}

SearchNegativeKeyword is an existing paid exclusion.

type SearchOptimizationData added in v1.260819.0

type SearchOptimizationData struct {
	Sources                        []SearchOptimizationSourceStatus `json:"sources"`
	Suggestions                    []SearchSuggestion               `json:"suggestions,omitempty"`
	SuggestionsTruncated           bool                             `json:"-"`
	Popularities                   []SearchPopularity               `json:"popularities,omitempty"`
	ImpressionShares               []SearchImpressionShare          `json:"impressionShares,omitempty"`
	SearchTerms                    []SearchTermPerformance          `json:"searchTerms,omitempty"`
	Campaigns                      []SearchCampaign                 `json:"campaigns,omitempty"`
	Keywords                       []SearchTargetingKeyword         `json:"keywords,omitempty"`
	NegativeKeywords               []SearchNegativeKeyword          `json:"negativeKeywords,omitempty"`
	Eligibilities                  []SearchEligibility              `json:"eligibilities,omitempty"`
	DailyBudgetRecommendationItems []json.RawMessage                `json:"dailyBudgetRecommendationItems,omitempty"`
	TargetCPARecommendationItems   []json.RawMessage                `json:"targetCpaRecommendationItems,omitempty"`
	TargetCPASuggestion            json.RawMessage                  `json:"targetCpaSuggestion,omitempty"`
	DailyBudgetRecommendations     int                              `json:"dailyBudgetRecommendations"`
	TargetCPARecommendations       int                              `json:"targetCpaRecommendations"`
}

SearchOptimizationData is the normalized official Apple Ads evidence used by the top-level optimizer.

func CollectSearchOptimizationData added in v1.260819.0

func CollectSearchOptimizationData(ctx context.Context, adsProfile, adAccount string, request SearchOptimizationRequest) (SearchOptimizationData, error)

CollectSearchOptimizationData resolves official Apple Ads authentication and gathers the read-only evidence needed by `asc optimize search plan`.

func CollectSearchSuggestions added in v1.260825.0

func CollectSearchSuggestions(ctx context.Context, adsProfile, adAccount string, request SearchOptimizationRequest) (SearchOptimizationData, error)

CollectSearchSuggestions resolves official Apple Ads authentication and gathers only the keyword and phrase suggestions needed by `asc optimize keywords discover`. The request limit is applied to each documented suggestion endpoint before pagination, so discovery never walks the broader optimization data set or downloads a full 1000-item page just to truncate it locally.

type SearchOptimizationRequest added in v1.260819.0

type SearchOptimizationRequest struct {
	AppID           string
	Country         string
	Genre           string
	Start           string
	End             string
	PopularityStart string
	PopularityEnd   string
	// Limit bounds the suggestions-only collection used by keyword discovery.
	// The broader optimization plan leaves it unset and retains its existing
	// pagination behavior.
	Limit int
}

SearchOptimizationRequest identifies the official Apple Ads data window and market used by the cross-API search optimization workflow.

type SearchOptimizationSourceStatus added in v1.260819.0

type SearchOptimizationSourceStatus struct {
	Name   string `json:"name"`
	Status string `json:"status"`
	Count  int    `json:"count"`
	Error  string `json:"error,omitempty"`
}

SearchOptimizationSourceStatus describes the availability of one official Apple Ads source. Empty responses are distinct from unavailable sources.

type SearchPopularity added in v1.260819.0

type SearchPopularity struct {
	Term              string `json:"term"`
	Country           string `json:"country,omitempty"`
	Genre             string `json:"genre,omitempty"`
	Week              string `json:"week,omitempty"`
	Month             string `json:"month,omitempty"`
	RankInGenre       *int   `json:"rankInGenre,omitempty"`
	PopularityInGenre *int   `json:"popularityInGenre,omitempty"`
	Popularity100     *int   `json:"popularity100,omitempty"`
	Popularity5       *int   `json:"popularity5,omitempty"`
}

SearchPopularity is one country-and-genre search demand snapshot.

func CollectSearchPopularity added in v1.260825.0

func CollectSearchPopularity(ctx context.Context, adsProfile, adAccount string, request SearchOptimizationRequest) ([]SearchPopularity, error)

CollectSearchPopularity resolves official Apple Ads authentication and reads only country-and-genre search demand. Unlike the broader optimization plan, this source is not scoped to a promoted app.

type SearchSuggestion added in v1.260819.0

type SearchSuggestion struct {
	Text       string `json:"text"`
	Popularity *int   `json:"popularity,omitempty"`
	Kind       string `json:"kind"`
}

SearchSuggestion is one keyword or phrase returned by Apple's suggestion endpoints. Popularity is kept separate from market-scoped popularity.

type SearchTargetingKeyword added in v1.260819.0

type SearchTargetingKeyword struct {
	Text       string `json:"text"`
	MatchType  string `json:"matchType"`
	Status     string `json:"status,omitempty"`
	CampaignID int64  `json:"campaignId"`
	AdGroupID  int64  `json:"adGroupId"`
}

SearchTargetingKeyword is an existing paid targeting keyword.

type SearchTermPerformance added in v1.260819.0

type SearchTermPerformance struct {
	Term          string `json:"term"`
	KeywordText   string `json:"keywordText,omitempty"`
	MatchType     string `json:"matchType,omitempty"`
	Country       string `json:"country,omitempty"`
	CampaignID    int64  `json:"campaignId,omitempty"`
	AdGroupID     int64  `json:"adGroupId,omitempty"`
	Impressions   int64  `json:"impressions"`
	Taps          int64  `json:"taps"`
	TapInstalls   int64  `json:"tapInstalls"`
	TotalInstalls int64  `json:"totalInstalls"`
	SpendAmount   string `json:"spendAmount,omitempty"`
	SpendCurrency string `json:"spendCurrency,omitempty"`
}

SearchTermPerformance captures the actual user query and paid outcome from Apple's app Search Terms report.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL