java smgp_SMGP 3.0 Java API

海叶秋
2023-12-01

软件简介

SMGP协议是中国电信为短信增值业务指定的接口协议,协议在在SMPP协议基础上进行扩展,扩展了相关计费和鉴权信息。目前

SMGP协议有1.0,2.0,3.0三个版本的协议。1.0协议目前基本上停用,而2.0目前在部分省小灵通接入仍然在使用。3.0协议时目前最新的协

议,相比2.0协议主要增加了tlv可选字段。

该项目主要针对SMGP 3.0协议进行开发。

程序使用JAVA开发。

示例代码:

//Client("服务器ip地址","服务器端口号",LoginMode,"账号","密码","企业代码",显示模式)

Client client = new Client("189.189.189.189", 8890, 2, "account","password", "12100001", 0);

Result result = client.Login();

System.out.println("ErrorCode:"+result.ErrorCode);

System.out.println("ErrorDescription:"+result.ErrorDescription);

//Client("服务器ip地址","服务器端口号",LoginMode,"账号","密码","企业代码",显示模式)

Client client = new Client("189.189.189.189", 8890, 2, "account","password", "12100001", 0);

//submit("主叫号码","被叫号码","内容","产品编号")

Submit submit = new Submit("10620068", "18967441118", "你好!","112000000000061090527");

Result result = client.Send(submit);

System.out.println("ErrorCode:"+result.ErrorCode);

System.out.println("MsgID:"+result.ErrorDescription);

 类似资料:

相关阅读

相关文章

相关问答