lib/tbkapi/api_taobaoke.rb in tbkapi-0.0.7 vs lib/tbkapi/api_taobaoke.rb in tbkapi-0.0.8

- old
+ new

@@ -92,7 +92,19 @@ params = system_params("taobao.ju.items.search", api_key).merge(action_params) my_sign = get_sign(params, secret).upcase Net::HTTP.get(URI(TBURI + '?' + URI.encode(build_query(params.merge({sign: my_sign}))))) end + def taobao_tbk_dg_item_coupon_get(q, adzone_id, api_key, secret, page_no = 1, page_size = 20) + action_params = { + adzone_id: adzone_id, + page_size: page_size, + page_no: page_no, + q: q + } + params = system_params("taobao.tbk.dg.item.coupon.get", api_key).merge(action_params) + my_sign = get_sign(params, secret).upcase + Net::HTTP.get(URI(TBURI + '?' + URI.encode(build_query(params.merge({sign: my_sign}))))) + end + end end