import java.util.HashMap; import java.util.Map; public class AccountDemo { /** * 微米账号查询 */ public static void account_api() { Map<String, String> para = new HashMap<String, String>(); /** * 微米账号的接口UID */ para.put("uid", "<enter your UID>"); /** * 微米账号的接口密码 */ para.put("pas", "<enter your UID Pass>"); /** * 接口返回类型:json、xml、txt。默认值为txt */ para.put("type", "json"); try { System.out .println(HttpClientHelper.convertStreamToString( HttpClientHelper .get("http://api.weimi.cc/2/account/balance.html", para), "UTF-8")); } catch (Exception e) { e.printStackTrace(); } } public static void main(String[] a) { // 测试账号查询API account_api(); /* 注意:以上参数传入时不包括“<>”符号 */ } }
{ "sms-left":157, "sms-sent":13, "sms-total":190, "mms-left":90, "mms-sent":10, "mms-total":100,"ivr-left":90, "ivr-sent":10, "ivr-total":100,,"gj-left":90, "gj-sent":10, "gj-total":100 "msg":"微米账户余额查询" }
√ 开发文档
√ 短信接口
√ 彩信接口
√ 账户余额查询接口
√ PHP示例
√ Python示例
√ C#示例