From b718473c1ae7ab585e504a164c6e2c5721abf0fa Mon Sep 17 00:00:00 2001 From: Syd Xu Date: Mon, 12 Dec 2022 18:58:27 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=9B=B4=E6=96=B0=E9=83=A8=E5=88=86api?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- marketing-api/enum/smart_bid_type.go | 2 ++ marketing-api/model/advertiser/transferable_fund_get.go | 4 ++++ marketing-api/model/campaign/create.go | 6 ++++++ marketing-api/model/campaign/get_response.go | 6 ++++++ marketing-api/model/tools/clue/clue.go | 5 +++++ 5 files changed, 23 insertions(+) diff --git a/marketing-api/enum/smart_bid_type.go b/marketing-api/enum/smart_bid_type.go index 7300e72a..a8e67526 100644 --- a/marketing-api/enum/smart_bid_type.go +++ b/marketing-api/enum/smart_bid_type.go @@ -8,4 +8,6 @@ const ( SMART_BID_CUSTOM SmartBidType = "SMART_BID_CUSTOM" // SMART_BID_CONSERVATIVE 自动出价 SMART_BID_CONSERVATIVE SmartBidType = "SMART_BID_CONSERVATIVE" + // SMART_BID_NO_BID + SMART_BID_NO_BID SmartBidType = "SMART_BID_NO_BID" ) diff --git a/marketing-api/model/advertiser/transferable_fund_get.go b/marketing-api/model/advertiser/transferable_fund_get.go index 7d43c56f..3f22ba10 100644 --- a/marketing-api/model/advertiser/transferable_fund_get.go +++ b/marketing-api/model/advertiser/transferable_fund_get.go @@ -47,4 +47,8 @@ type TransferableFund struct { BrandCreditValid float64 `json:"brand_credit_valid,omitempty"` // BidCreditValid 竞价授信可用余额(单位元) BidCreditValid float64 `json:"bid_credit_valid,omitempty"` + // DepositAmount 保证金(单位元) + DepositAmount float64 `json:"deposit_amount,omitempty"` + // TotalTransferBalance 总可转余额 + TotalTransferBalance float64 `json:"total_transfer_balance,omitempty"` } diff --git a/marketing-api/model/campaign/create.go b/marketing-api/model/campaign/create.go index 8e7f6408..9b5099ef 100644 --- a/marketing-api/model/campaign/create.go +++ b/marketing-api/model/campaign/create.go @@ -27,6 +27,12 @@ type CreateRequest struct { MarketingPurpose enum.MarketingPurpose `json:"marketing_purpose,omitempty"` // DeliveryRelatedNum 广告组商品类型 DeliveryRelatedNum enum.CampaignDPA `json:"delivery_related_num,omitempty"` + // CampaignBudgetOptimization 支持预算择优分配允许值: + // ON 开启,OFF 不开启(默认值) + // 广告主商品类型为CAMPAIGN_DPA_MULTI_DELIVERY时不允许开启预算择优分配 + CampaignBudgetOptimization string `json:"campaign_budget_optimization,omitempty"` + // SmartBidType 出价方式(投放场景),campaign_budget_optimization为ON时必填,且必须为SMART_BID_NO_BID + SmartBidType enum.SmartBidType `json:"smart_bid_type,omitempty"` // UniqueFk 第三方唯一键,传该值时保证接口重试的幂等性,请注意,带有相同unique_fk的请求服务端会视为同一个广告处理。仅在创建接口传入且无法修改,如果创建时传入了已存在的唯一键值,那么会返回该唯一键值所对应的广告组ID。该值可用于内部系统会生成的唯一ID与头条ID做关联的场景,避免超时重试实际上一次创建请求又成功导致的重复创建问题,通过unique_fk可与内部系统ID实现关联并避免重复创建,可结合实际场景选择使用,广告组中的unique_fk要求不重复,与计划中的unique_fk无相关。 UniqueFk string `json:"unique_fk,omitempty"` } diff --git a/marketing-api/model/campaign/get_response.go b/marketing-api/model/campaign/get_response.go index 839bd21f..362bfd22 100644 --- a/marketing-api/model/campaign/get_response.go +++ b/marketing-api/model/campaign/get_response.go @@ -44,4 +44,10 @@ type Campaign struct { DeliveryRelatedNum enum.CampaignDPA `json:"delivery_related_num,omitempty"` // DeliveryMode 投放类型,允许值:MANUAL(手动)、PROCEDURAL(自动,投放管家) DeliveryMode string `json:"delivery_mode,omitempty"` + // CampaignBudgetOptimization 支持预算择优分配允许值: + // ON 开启,OFF 不开启(默认值) + // 广告主商品类型为CAMPAIGN_DPA_MULTI_DELIVERY时不允许开启预算择优分配 + CampaignBudgetOptimization string `json:"campaign_budget_optimization,omitempty"` + // SmartBidType 出价方式(投放场景),campaign_budget_optimization为ON时必填,且必须为SMART_BID_NO_BID + SmartBidType enum.SmartBidType `json:"smart_bid_type,omitempty"` } diff --git a/marketing-api/model/tools/clue/clue.go b/marketing-api/model/tools/clue/clue.go index dbf98136..6e582466 100644 --- a/marketing-api/model/tools/clue/clue.go +++ b/marketing-api/model/tools/clue/clue.go @@ -16,6 +16,11 @@ type Clue struct { AdName string `json:"ad_name,omitempty"` // CreativeID 广告创意id CreativeID model.FlexUint64 `json:"creative_id,omitempty"` + // PromotionName 体验版广告名称 + PromotionName string `json:"promotion_name,omitempty"` + // PromotionID 体验版广告ID + // 注意:体验版广告信息与计划/创意信息互斥,不会同时返回 + PromotionID uint64 `json:"promotion_id,omitempty"` // SiteID 站点ID SiteID model.FlexUint64 `json:"site_id,omitempty"` // SiteName 站点名称