flowdock-api-wrapper

Flowdock API Wrapper


Keywords
flowdock
License
MIT
Install
pip install flowdock-api-wrapper==1.1

Documentation

Flowdock API wrapper

This API wrapper provides methods with intuitive implementation to make development simpler.

With Flowdock API, developers are able to:

Create chatbots
>>> import flowdock
>>> flow = flowdock.connect(token=TOKEN, org='apua', flow='main')
>>> msg = flow.send('Message')  # send a message
>>> thread = flow.thread(msg['thread']['id'])
>>> reply = thread.send('Reply')  # reply the message
>>> flow.list(limit=1)['content']  # get last message content
'Reply'
Integrate external services
>>> from flowdock import constructors as new
>>> apua = new.author('Apua', avatar='http://gravatar.com/apua.jpg')
>>> item = new.thread(
...     'Item 42',
...     external_url = 'https://external.service/item/42',
...     body = '<strong>The detail of Item 01</strong>',
...     fields = [
...         new.field(label='Project', value='F.A.W.'),
...         new.field(label='<em>Creator</em>', value='<em>Apua</em>'),
...     ],
...     status = new.status(color='green', value='WIP'),
... )
>>> import flowdock
>>> serivce = flowdock.connect(flow_token=FLOW_TOKEN)
>>> service.present('42', apua, 'created item 42', item)
Monitor Flowdock flows
>>> import flowdock
>>> flow = flowdock.connect(token=TOKEN, org='apua', flow='main')
>>> ev = next(flow.events())
>>> ev['content'])
'New message!!'

How to Install

This package is available on PyPI:

$ pip install flowdock-api-wrapper

How to Use

The reference is available to detail the library usage.

It also summarizes the usage of Flowdock API while the wrapped methods map to the API directly.

Please refer to reference for further usage.

How to Contribute

To contribute the package, refer to development guide, which decribe the design, implementation, and maintenance.