I am running an Asterisk/FreePBX with time conditions
- timecondition-1 (durin working hours)
- timecondition-2 (offhours)
timecondition-2 just runs ivr-3 that plays a message (no dial opportunities there)
timecondition-1 runs ivr-2 that plays a message for 20 seconds and transfers the call to a Ring Group (where the agents are)
(ivr-1 just plays a bussy message and returns the call to ivr-2)
I am not using Queues.
Anyway: I need to LIMIT the CALL DURATION to 4 minutes
I know this is done with:
exten => _1XX,1,NoOp(Limiting maximum call duration)
exten => _1XX,n,Set(TIMEOUT(absolute)=240)
BUT I DO NOT KNOW the proper CONTEXT to put it in ‘extensions_custom.conf’, for what I need.
I need to have the call end 4 minutes after the agents accepts the call.
The only way I can limit the call (from the moment it is answered by and agent from within the Ring Group) is when I put a contect [from-did-direct]
but this works only if and when the caller DIALS the extension number of the agent, and I can’t have this.
It needs to work ‘on it’s own’: with the call timeout trigered from the moment the call is answed by an agent from within the Ring Group.
Some excerpts from the verbocity
– Executing [[email protected]:4] Goto(“SIP/telekomout-000000df”, “ext-did,s,1”) in new stack
; this is where the call comes in
– Executing [[email protected]:21] Goto(“SIP/telekomout-000000df”, “timeconditions,1,1”) in new stack
; this is where it gets in the timecondition
– Executing [[email protected]:10] GotoIf(“SIP/telekomout-000000df”, “1?ivr-2,s,1”) in new stack
– Executing [[email protected]:1] Set(“SIP/telekomout-000000df”, “_IVR_CONTEXT_ivr-2=”) in new stack
; this is where it gets into the ivr-2
– Executing [[email protected]:1] Goto(“SIP/telekomout-000000df”, “ext-group,200,1”) in new stack
– Goto (ext-group,200,1)
; this is where it gets into the Ring Group
– Executing [[email protected]:5] Set(“PJSIP/112-000000f0”, “FORWARD_CONTEXT=from-internal”) in new stack
– Executing [[email protected]:6] Set(“PJSIP/112-000000f0”, “MASTER_CHANNEL(FORWARD_CONTEXT)=from-internal”) in new stack
; where it rings (the only avaialble extension in the Ring Group)
This is the only CONTEXT I have got it to work with
from-did-direct
[from-did-direct]
exten => _1XX,1,NoOp(Limiting maximum call duration)
exten => _1XX,2,Set(TIMEOUT(absolute)=10)
(placing it in: extensions_custom.conf, and dialing a working agent's extension, i.e. 112 while the IVR is playing the message)
Agents extension numbers are: 101, 102, 103 - 112
The Ring Group Number is: 200
Is there anything I need to enter in ‘Custom Destinations’?
Again, the point is to have the calls getting in from the Ring Group 200 ending (terminating, or rather timeouting) after 4 minutes (240 seconds)
Thanks!