指定模板单发接口 tpl_value 参数参考示例


请参考如下示例对批量个性化发送接口中 tpl_value 参数传参


Java


String tpl_value = URLEncoder.encode("#min#",ENCODING) +"="
+ URLEncoder.encode("5", ENCODING) + "&"
+ URLEncoder.encode("#code#",ENCODING) + "="
+ URLEncoder.encode("1234",ENCODING);


python


tpl_value = urllib.urlencode({'#min#':'5','#code#':'1234'})


C Sharp


string tpl_value = HttpUtility.UrlEncode(
HttpUtility.UrlEncode("#min#", Encoding.UTF8)    + "=" +
HttpUtility.UrlEncode("5", Encoding.UTF8)      + "&" +
HttpUtility.UrlEncode("#code#", Encoding.UTF8) + "=" +
HttpUtility.UrlEncode("1234", Encoding.UTF8), Encoding.UTF8);


php


$data = array('tpl_id' => '365741', 'tpl_value' => ('#min#').
    '='.urlencode('5').
    '&'.urlencode('#code#').
    '='.urlencode('1234'), 'apikey' => $apikey, 'mobile' => $mobile);