package com.yunsms.interfacej;

import com.yunsms.tool.SmsClientAccessTool;

public class Test {

	public static String url = "http://116.62.155.121:8888/sms.aspx";   //编码不同，提交入口不同。sms.aspx为utf-8提交入口，smsGBK.aspx为GBK提交入口，详见接口文档说明
	public static String userid = "1169"; //企业ID（userid）登陆后台：http://cloud.yunsms.cn 通过“客户管理”-“我的信息”查询。
	public static String account = "test"; //账号
	public static String password = "123456";//密码
	public static String checkWord = "【云消息】今天下午开会！";

	public static void main(String[] args) {

		keyword();
		// overage();
	}

	public static void keyword() {

		String keyword = SmsClientKeyword.queryKeyWord(url, userid, account,
				password, checkWord);
		System.out.println(keyword);
	}

	public static void overage() {

		String overage = SmsClientOverage.queryOverage(url, userid, account,
				password);
		System.out.println(overage);
	}

	public static void test() {
		String send = SmsClientAccessTool.getInstance().doAccessHTTPPost(
				"http://116.62.155.121:8888/sms.aspx", "", "utf-8");   //编码不同，提交入口不同。sms.aspx为utf-8提交入口，smsGBK.aspx为GBK提交入口，详见接口文档说明
		System.out.println(send);
	}
}
