<html dir="ltr"><head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="GENERATOR" content="MSHTML 10.00.9200.16721">
<style title="owaParaStyle"><!--P {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
--></style>
</head>
<body ocsi="x">
<div dir="ltr"><font color="#000000" size="2" face="Tahoma">Unfortunately I do not have the ability / permission to alter the dialplan used for this customer.  Odd requirement I know...</font><font size="2" face="tahoma"></font><font size="2" face="tahoma"></font></div>
<div id="divRpF534170" style="DIRECTION: ltr">
<hr tabindex="-1">
<font size="2" face="Tahoma"><b>From:</b> asterisk-users-bounces@lists.digium.com [asterisk-users-bounces@lists.digium.com] On Behalf Of Darryl Moore [darryl@moores.ca]<br>
<b>Sent:</b> Wednesday, October 23, 2013 6:38 AM<br>
<b>To:</b> Asterisk Users List<br>
<b>Subject:</b> Re: [asterisk-users] Disable peer from AMI<br>
</font><br>
</div>
<div></div>
<div>
<p dir="ltr">put it in a different context in your dial plan and use a gotoif statement to control the times it is allowed to dial out. you can also redirect it to a prerecorded message whenever someone tries to use it during the 'off' time. no need for anything
 as brutal as disabling it in sip.conf.</p>
<div class="gmail_quote">On 2013-10-23 12:37 AM, "Michelle Dupuis" <<a href="mailto:mdupuis@ocg.ca">mdupuis@ocg.ca</a>> wrote:<br type="attribution">
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div>
<div dir="ltr"><font color="#000000" face="Tahoma">I need to disable/enable a peer after hours automatically, and am thinking about doing so via the AMI.</font></div>
<div dir="ltr"><font face="tahoma"></font> </div>
<div dir="ltr"><font face="tahoma">Is there a command to enable/disable (or perhaps delete/add) a peer via the AMI?  I could create code to modify sip.conf and force a reload, but that seems like the wrong approach...</font></div>
</div>
<br>
--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">
http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
               <a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>
</blockquote>
</div>
</div>
</body>
</html>