Skip to content

bzdvdn/sipuni-api-wrapper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sipuni api client

Installation

Install using pip...

pip install sipuni-api

Usage

from sipuni_api import Sipuni
client = Sipuni('<user_id>', '<api_key>')

Make calls

# create simple call
client.make_call(phone='79379992', sipnumber='201')

# create call tree
client.make_tree_call(phone='79379992', sipnumber='201', tree='000658610')

# create call external
client.make_external_call(from_phone='79379992', to_phone='79379993', first_sipnumber='201', second_sipnumber='204')

Make voice call

client.make_voice_call(phone='79379992', sipnumber='201', message='test 123', voice_type='Vladimir')

Hangup call

client.hangup_call(call_id='123456789.123')

Statistic

# call statistic
from datetime import datetime, timedelta
client.get_call_stats(from_date=(datetime.now() - timedelta(days=1)), to_date=datetime.now())   # return csv data

# get call record
client.get_record('<record_id>')    # return bytes

# get list of managers
client.get_managers()

TODO

  • examples
  • tests

License

MIT

About

Api wrapper at python for Sipuni telephony

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages