文档中心 > API类目 > 万相台无界API

taobao.universalbp.new.algo.getbudgetsuggestion (预算预估)

预算预估

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
top_service_context TopServiceContext 必须 topServiceContext
  • └ biz_code
  • String
  • 必须
  • xxxxx
  • api业务线编码
  • └ login_type
  • Number
  • 可选
  • 1
  • 1: 直客(正常)登录 2: 代理直投(叉乘账号)
  • └ member_id
  • Number
  • 可选
  • 12345
  • 代理直投时被代理商家账号, 代理直投(叉乘)时必填。 直客 时也可以填入 memberId
  • └ ext
  • String
  • 可选
  • {}
  • 扩展内容, 暂时无用
algo_query_v_o AlgoQueryVO 必须 algoQueryVO
  • campaign
  • AlgoCampaignQueryVO
  • 可选
  • 计划维度算法请求参数
  • └ campaign_id
  • Number
  • 可选
  • 68799007001
  • 计划id
  • └ promotion_model
  • String
  • 可选
  • display
  • 推广类型
  • └ promotion_scene
  • String
  • 可选
  • promotion_scene_crowd
  • 推广场景
  • └ promotion_goals
  • String
  • 可选
  • shop_crowd
  • 推广目标
  • └ optimize_target
  • String
  • 可选
  • shop_visit_new
  • 优化目标
  • └ dmc_type
  • String
  • 可选
  • normal
  • 预算类型
  • └ day_budget
  • Number
  • 可选
  • 60
  • 日预算
  • └ total_budget
  • Number
  • 可选
  • 350
  • 周预算
  • └ budget_period
  • Number
  • 可选
  • 1
  • 周期
  • └ bid_type
  • String
  • 可选
  • roi_control
  • 出价方式
  • └ constraint_type
  • String
  • 可选
  • roi
  • 出价约束
  • └ promotion_type
  • String
  • 可选
  • item
  • 主体类型
  • └ item_selected_mode
  • String
  • 可选
  • user_define
  • 选品方式
  • launch_period_list
  • CampaignLaunchPeriodCommandVO []
  • 可选
  • 投放折扣时段设置
  • └ day_of_week
  • Number
  • 可选
  • 1
  • 本周的第x天
  • time_span_list
  • TimeSpanVO []
  • 可选
  • 第x天各时段的折扣情况
  • └ discount
  • Number
  • 可选
  • 100
  • 折扣
  • └ time
  • String
  • 可选
  • 00:00-24:00
  • 折扣时间段
  • └ launch_area_str_list
  • String []
  • 可选
  • ["all"]
  • 投放地域
  • launch_time
  • CampaignLaunchTimeCommandVO
  • 可选
  • 计划投放时间
  • └ start_time
  • Date
  • 可选
  • 2023-06-09 00:00:00
  • 计划开始时间
  • └ end_time
  • Date
  • 可选
  • 2199-02-01 00:00:00
  • 计划结束时间
  • └ launch_forever
  • Boolean
  • 可选
  • true
  • 是否长期投放,true:是,false:否
  • └ bid_type_v2
  • String
  • 可选
  • smart_bid
  • 智能出价升级,出价类型
  • └ bid_target_v2
  • String
  • 可选
  • conv
  • 出价目标
  • └ set_single_cost_v2
  • Boolean
  • 可选
  • true
  • 是否设置单次成本
  • └ item_rec_strategy
  • String []
  • 可选
  • ["effect_gmv","effect_coll"]
  • 选品方向
  • adgroup_list
  • AlgoAdgroupQueryVO []
  • 可选
  • 单元维度算法请求参数
  • material
  • AdgroupMaterialCommandVO
  • 可选
  • 主体类型对应的物料信息
  • └ material_id
  • Number
  • 可选
  • 714616513841
  • 物料id
  • └ material_name
  • String
  • 可选
  • yiliantest测试请不要拍22
  • 物料名称
  • └ promotion_type
  • String
  • 可选
  • item
  • 推广主体类型,item:商品,item_private_mini:独享橱窗,shop:店铺,content:内容,short_video:短视频,user_define:自定义;
  • └ sub_promotion_type
  • String
  • 可选
  • item
  • 推广子主体类型,item:商品,item_private_mini:独享橱窗,shop:店铺,you_hao_huo:有好货,picture:图文,short_video:短视频,live_room:直播间,live_spot:看点,tao_blocks:淘积木,user_define_url:自定义url
  • └ link_url
  • String
  • 可选
  • http://shop191070507.taobao.com/index.htm
  • 物料地址
  • goal_life_cycle_list
  • ItemLifeCycleViewVO []
  • 可选
  • [{color: "#FFA53D", bizCode: null, lifeCycleDesc: "冷启期", type: 1, tips: "近30日GMV排名在叶子类目55%以下的新品"}]
  • 货品序列化越迁目标
  • └ life_cycle_desc
  • String
  • 可选
  • 新品打爆期
  • 周期文案
  • └ color
  • String
  • 可选
  • #36A2FC
  • 文案颜色
  • └ tips
  • String
  • 可选
  • 近30日GMV排名在叶子类目5%以内的新品
  • 周期提示文案
  • └ type
  • Number
  • 可选
  • 1
  • 生命周期类型
  • └ dmc_type_element
  • String
  • 可选
  • dayBudget
  • 组件类型

响应参数

名称 类型 示例值 描述
top_result TopResult topResult
  • info
  • TopInfo
  • 通用前端结果的Info信息
  • 请求系统信息
  • └ ok
  • Boolean
  • true
  • 是否成功
  • └ message
  • String
  • 参数错误
  • 错误信息
  • └ error_code
  • String
  • xxxxx
  • 错误编码
  • budget_suggest_v_o
  • BudgetSuggestVO
  • 结果集
  • └ budget_left
  • Number
  • 200
  • 预算左值
  • └ budget_middle
  • Number
  • 220
  • 预算中值
  • └ budget_right
  • Number
  • 260
  • 预算右值
  • └ budget_upper
  • Number
  • 260
  • 预算上限(元)
  • └ budget_lower
  • Number
  • 200
  • 预算下限(元)
  • └ algo_budget
  • Number
  • 220
  • 直接销量达成:给出的预算
  • └ reason
  • String
  • 根据同类目投放情况,建议每日预算不低于<span class='font-number bold color-3'>200</span>元
  • 算法建议文案
  • └ budget_default
  • Number
  • 200
  • 默认预算
  • └ budget_min
  • Number
  • 100
  • 默认最低值

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
UniversalbpNewAlgoGetbudgetsuggestionRequest req = new UniversalbpNewAlgoGetbudgetsuggestionRequest();
UniversalbpNewAlgoGetbudgetsuggestionRequest.TopServiceContext obj1 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.TopServiceContext();
obj1.setBizCode("xxxxx");
obj1.setLoginType(1L);
obj1.setMemberId(12345L);
obj1.setExt("{}");
req.setTopServiceContext(obj1);
UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoQueryVO obj2 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoQueryVO();
UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoCampaignQueryVO obj3 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoCampaignQueryVO();
obj3.setCampaignId(68799007001L);
obj3.setPromotionModel("display");
obj3.setPromotionScene("promotion_scene_crowd");
obj3.setPromotionGoals("shop_crowd");
obj3.setOptimizeTarget("shop_visit_new");
obj3.setDmcType("normal");
obj3.setDayBudget(60L);
obj3.setTotalBudget(350L);
obj3.setBudgetPeriod(1L);
obj3.setBidType("roi_control");
obj3.setConstraintType("roi");
obj3.setPromotionType("item");
obj3.setItemSelectedMode("user_define");
List<UniversalbpNewAlgoGetbudgetsuggestionRequest.CampaignLaunchPeriodCommandVO> list5 = new ArrayList<UniversalbpNewAlgoGetbudgetsuggestionRequest.CampaignLaunchPeriodCommandVO>();
UniversalbpNewAlgoGetbudgetsuggestionRequest.CampaignLaunchPeriodCommandVO obj6 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.CampaignLaunchPeriodCommandVO();
list5.add(obj6);
obj6.setDayOfWeek(1L);
List<UniversalbpNewAlgoGetbudgetsuggestionRequest.TimeSpanVO> list9 = new ArrayList<UniversalbpNewAlgoGetbudgetsuggestionRequest.TimeSpanVO>();
UniversalbpNewAlgoGetbudgetsuggestionRequest.TimeSpanVO obj10 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.TimeSpanVO();
list9.add(obj10);
obj10.setDiscount(100L);
obj10.setTime("00:00-24:00");
list7.setTimeSpanList(list9);
obj3.setLaunchPeriodList(list5);
obj3.setLaunchAreaStrList(""all"");
UniversalbpNewAlgoGetbudgetsuggestionRequest.CampaignLaunchTimeCommandVO obj11 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.CampaignLaunchTimeCommandVO();
obj11.setStartTime(StringUtils.parseDateTime("2023-06-09 00:00:00"));
obj11.setEndTime(StringUtils.parseDateTime("2199-02-01 00:00:00"));
obj11.setLaunchForever(true);
obj3.setLaunchTime(obj11);
obj3.setBidTypeV2("smart_bid");
obj3.setBidTargetV2("conv");
obj3.setSetSingleCostV2(true);
obj3.setItemRecStrategy(""effect_gmv","effect_coll"");
obj2.setCampaign(obj3);
List<UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoAdgroupQueryVO> list13 = new ArrayList<UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoAdgroupQueryVO>();
UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoAdgroupQueryVO obj14 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.AlgoAdgroupQueryVO();
list13.add(obj14);
UniversalbpNewAlgoGetbudgetsuggestionRequest.AdgroupMaterialCommandVO obj16 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.AdgroupMaterialCommandVO();
obj16.setMaterialId(714616513841L);
obj16.setMaterialName("yiliantest测试请不要拍22");
obj16.setPromotionType("item");
obj16.setSubPromotionType("item");
obj16.setLinkUrl("http://shop191070507.taobao.com/index.htm");
List<UniversalbpNewAlgoGetbudgetsuggestionRequest.ItemLifeCycleViewVO> list18 = new ArrayList<UniversalbpNewAlgoGetbudgetsuggestionRequest.ItemLifeCycleViewVO>();
UniversalbpNewAlgoGetbudgetsuggestionRequest.ItemLifeCycleViewVO obj19 = new UniversalbpNewAlgoGetbudgetsuggestionRequest.ItemLifeCycleViewVO();
list18.add(obj19);
obj19.setLifeCycleDesc("新品打爆期");
obj19.setColor("#36A2FC");
obj19.setTips("近30日GMV排名在叶子类目5%以内的新品");
obj19.setType(1L);
obj16.setGoalLifeCycleList(list18);
list15.setMaterial(obj16);
obj2.setAdgroupList(list13);
obj2.setDmcTypeElement("dayBudget");
req.setAlgoQueryVO(obj2);
UniversalbpNewAlgoGetbudgetsuggestionResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<universalbp_new_algo_getbudgetsuggestion_response>
    <top_result>
        <info>
            <ok>true</ok>
            <message>参数错误</message>
            <error_code>xxxxx</error_code>
        </info>
        <budget_suggest_v_o>
            <budget_left>200</budget_left>
            <budget_middle>220</budget_middle>
            <budget_right>260</budget_right>
            <budget_upper>260</budget_upper>
            <budget_lower>200</budget_lower>
            <algo_budget>220</algo_budget>
            <reason>根据同类目投放情况,建议每日预算不低于&lt;span class=&apos;font-number bold color-3&apos;&gt;200&lt;/span&gt;元</reason>
            <budget_default>200</budget_default>
            <budget_min>100</budget_min>
        </budget_suggest_v_o>
    </top_result>
</universalbp_new_algo_getbudgetsuggestion_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部