清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>
维美WebService说明文档
WebService简介
WebService针对软件开发和系统集成商提供移动商务的接入WebService具有稳定、跨平台、跨开发语言、穿透防火墙等特点因此深受企业开发亲睐。适应 WEB、VB 、Delphi、.NET、VC 、 JAVA 等多种主流开发语言及 Windows 、Linux 、Unix 等运行环境的短信通讯开发接口,让企业的 OA 、CRM 、ERP 、SCM 等系统快速、轻松实现移动商务应用。
适用于
1. CRM、ERP、OA、SCM软件系统
2. 网站 B2B、B2C类
3. 系统集成商
4. 中间件开发商
5. ……
典型应用:
●与Web嵌入 ● 与OA嵌入 ●与ERP嵌入 ● 与CRM嵌入● 软件开发商嵌入 ...
WebService 地址
电信服务器:http://www.chinaweimei.com/smsapi/Service.asmx
联通服务器:http://lt.chinaweimei.com.cn/smsapi/Service.asmx
电信WSDL地址:http://www.chinaweimei.com/smsapi/Service.asmx?wsdl
联通WSDL地址:http://lt.chinaweimei.com.cn/smsapi/Service.asmx?wsdl
请根据自身实际情况选择
WebService 函数描述
发送短信 函数原型:
string SendSMS(string user,string pass,string moblie,string content)
参数描述
string user :短信帐号名 请注意区分大小写
string pass :短信密码 请注意区分大小写
string moblie :要发送的号码 多个号码请用半角逗号分隔,一次提交最多不应超过500个号码
string content:短信内容 字数最多不应超过390 个字,并且不能含有系统限定的关键词,关键词可以通过函数GetSmsKeys()来获得
XML描述:
POST /smsapi/Service.asmx HTTP/1.1
Host: www.chinaweimei.com.cn
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://tempuri.org/SendSMS"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<SendSMS xmlns="http://tempuri.org/">
<user>string</user>
<pass>string</pass>
<moblie>string</moblie>
<content>string</content>
</SendSMS>
</soap:Body>
</soap:Envelope>
返回值描述:return string
成功返回:"1|扣费条数" 例如:"1|1" "1|2"
失败返回:"0|失败原因" 例如:"0|帐号或密码为空" "0|短信内容为空"
返回值 XML描述:
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<SendSMSResponse xmlns="http://tempuri.org/">
<SendSMSResult>string</SendSMSResult>
</SendSMSResponse>
</soap:Body>
</soap:Envelope>
获取短信余额 函数原型:
string GetBalance(string user, string pass)
参数描述
string user :短信帐号名 请注意区分大小写
string pass :短信密码 请注意区分大小写
XML描述:
POST /smsapi/Service.asmx HTTP/1.1
Host: www.chinaweimei.com.cn
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://tempuri.org/GetBalance"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetBalance xmlns="http://tempuri.org/">
<user>string</user>
<pass>string</pass>
</GetBalance>
</soap:Body>
</soap:Envelope>
返回值描述:return string
成功返回:"1|帐号剩余条" 例如:"1|99999" "1|90000"
失败返回:"0|失败原因" 例如:"0|帐号或密码为空" "0|帐号或密码错误,请区分大小写"
返回值 XML描述:
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetBalanceResponse xmlns="http://tempuri.org/">
<GetBalanceResult>string</GetBalanceResult>
</GetBalanceResponse>
</soap:Body>
</soap:Envelope>
获取短信关键词库 函数原型:
string[] GetSmsKeys()
XML描述:
POST /smsapi/Service.asmx HTTP/1.1
Host: wt.chinaweimei.com.cn
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://tempuri.org/GetSmsKeys"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetSmsKeys xmlns="http://tempuri.org/" />
</soap:Body>
</soap:Envelope>
返回值描述:return string[]
以字符串数组形式为返回值,一个字符串为一个关键词,短信内容包含其中任何一个关键词都会导致发送失败。
温馨提示:由于关键词库较大并且更新频率很慢,请不要频繁调用,尤其是网络不好的用户。建议在第一次调用之后保存至本地,之后从本地读取对比,这样会节约大量时间和流量。
返回值 XML描述:
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<GetSmsKeysResponse xmlns="http://tempuri.org/">
<GetSmsKeysResult>
<string>string</string>
<string>string</string>
<string>string</string>
</GetSmsKeysResult>
</GetSmsKeysResponse>
</soap:Body>
</soap:Envelope>
再次感谢您使用维美WebService程序!祝您使用愉快,工作顺利!我们将竭诚为您服务!
维美网络科技有限公司 API产品团队敬上!