用于与Clickatell短信网关交互的库
clickatell的Python项目详细描述
单击atell python library
==
master:[![构建状态](https://secure.travis-ci.org/arcturial/clickatell-python.png?branch=master)](http://travis ci.org/arcturial/clickatell python)
安装
----
您可以通过PIP安装此库,作为需求文件的一部分。
`````
PIP安装clickatell
`````
[clickatell python pypi](https://pypi.python.org/pypi?name=clickatell&;version=0.0.1&;:action=display)
2。用法
----
库当前支持“http”和“rest”协议。
http api
``python
from clickatell.http import http
response=clickatell.sendmessage(['1111111111'],“我的消息”)
>对于响应条目:
>print(entry['id']])
entry['id']
>print(entry['id'']
<
```````
````python
>对于响应条目:
>prin(entry['id''id''''''''''''destinentry''']]
>
clickatell=rest(令牌);
response=clickatell.sendmessage(['1111111111111111111111'],“我的消息”)
print(entry['id'])
>
“sendmessage”call“to”参数可以接受数组数不胜数。如果只指定一个数字,如“clickatell.sendmessage(1111111111,“message”)”,库将自动将其转换为数组,以方便使用。
3。支持的API调用
----
可用调用在“clickatell.transport”接口中定义。
def sendmessage(self,to,message,extra={})
def routecoverage(self,apimsgid)
def routecoverage(self,msisdn)
def getMessageCharge(self,apimsgid)
````
>4。处理sendmessage中的额外参数时,出于可用性目的,“sendmessage”调用将重点放在收件人和内容上。为了指定和指定在[Clickatell文档](http://www.clickatell.com)中定义的附加参数
,可以使用“extra”参数并将其作为字典传递。
==
master:[![构建状态](https://secure.travis-ci.org/arcturial/clickatell-python.png?branch=master)](http://travis ci.org/arcturial/clickatell python)
安装
----
您可以通过PIP安装此库,作为需求文件的一部分。
`````
PIP安装clickatell
`````
[clickatell python pypi](https://pypi.python.org/pypi?name=clickatell&;version=0.0.1&;:action=display)
2。用法
----
库当前支持“http”和“rest”协议。
http api
``python
from clickatell.http import http
>对于响应条目:
>print(entry['id']])
entry['id']
>print(entry['id'']
<
```````
````python
>对于响应条目:
>prin(entry['id''id''''''''''''destinentry''']]
>
clickatell=rest(令牌);
response=clickatell.sendmessage(['1111111111111111111111'],“我的消息”)
print(entry['id'])
>
“sendmessage”call“to”参数可以接受数组数不胜数。如果只指定一个数字,如“clickatell.sendmessage(1111111111,“message”)”,库将自动将其转换为数组,以方便使用。
3。支持的API调用
----
可用调用在“clickatell.transport”接口中定义。
def sendmessage(self,to,message,extra={})
def routecoverage(self,apimsgid)
def routecoverage(self,msisdn)
def getMessageCharge(self,apimsgid)
````
>4。处理sendmessage中的额外参数时,出于可用性目的,“sendmessage”调用将重点放在收件人和内容上。为了指定和指定在[Clickatell文档](http://www.clickatell.com)中定义的附加参数
,可以使用“extra”参数并将其作为字典传递。