This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% macro form_field(field) -%} | |
{% set with_label = kwargs.pop('with_label', False) %} | |
{% set placeholder = '' %} | |
{% if not with_label %} | |
{% set placeholder = field.label.text %} | |
{% endif %} | |
<div class="control-group {% if field.errors %}error{% endif %}"> | |
{% if with_label %} | |
<label for="{{ field.id }}" class="control-label"> | |
{{ field.label.text }}{% if field.flags.required %} *{% endif %}: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xivo_amid_client import Client as Amid | |
from xivo_auth_client import Client as Auth | |
auth = Auth('127.0.0.1', username='user-service', password='pass') | |
token_data = auth.token.new('xivo_service', expiration=10) | |
token = token_data['token'] | |
ami = Amid('127.0.0.1', port=9491, version='1.0', timeout=3) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xivo_amid_client import Client as amid | |
from xivo_auth_client import Client as auth | |
from xivo import agi | |
c = amid('localhost', verify_certificate=False) | |
agi = agi.AGI() | |
extension = agi.get_variable("EXTEN_GSM") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[txfax] | |
exten = s,1,Set(TIMEOUT(absolute)=5400) | |
same = n,SendFax(${XIVO_FAX_PATH}) | |
same = n,Set(XIVO_DSTID=${XIVO_USERID}) | |
same = n,AGI(agi://${XIVO_AGID_IP}/incoming_user_set_features) | |
same = n,Set(EXTEN_GSM=XIVO_MOBILEPHONENUMBER) | |
same = n,Set(EXTEN_CONTEXT=default) | |
same = n,Agi(originate) | |
same = n,System(rm ${XIVO_FAX_PATH}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[rxfax] | |
exten = handle_fax,1,NoOp() | |
same = n,GotoIf(${XIVO_FAXTOMAIL}?:return) | |
same = n,AGI(agi://${XIVO_AGID_IP}/handle_fax,${XIVO_FAXFILE},${XIVO_FAXEMAIL}) | |
same = n,Set(EXTEN_GSM="TELEPHONE A TROUVER COMMENT LE REMPLIR") | |
same = n,Set(EXTEN_CONTEXT=default) | |
same = n,Agi(originate) | |
same = n(return),Return() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xivo_ctid_ng_client import Client | |
from xivo_auth_client import Client as Auth | |
import time | |
c = Client('192.168.1.124', verify_certificate=False) | |
a = Auth('192.168.1.124', username='sylvain', password='sylvain') | |
t = a.token.new('xivo_user', expiration=10) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xivo_amid_client import Client as amid | |
from xivo_auth_client import Client as auth | |
from xivo import agi | |
extension = "8000" | |
context = "default" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xivo_amid_client import Client as Amid | |
from xivo_auth_client import Client as Auth | |
from xivo_confd_client import Client as Confd | |
username="sylvain" | |
password="sylvain" | |
auth = Auth('127.0.0.1', username=username, password=password, verify_certificate=False) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xivo_auth_client import Client as Auth | |
from xivo_confd_client import Client as Confd | |
username = "change_it" | |
password = "change_it" | |
############################# | |
auth = Auth('127.0.0.1', username=username, password=password, verify_certificate=False) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"id": null, | |
"title": "Grafana", | |
"originalTitle": "Grafana", | |
"tags": [], | |
"style": "dark", | |
"timezone": "browser", | |
"editable": true, | |
"hideControls": false, | |
"sharedCrosshair": false, |
OlderNewer