I’m trying to have a user dial an extension/feature code, reach a CFC feature code and do it’s regular thing of changing the state etc, and then go to an IVR.
I tried to
[cfc-test]
exten => s,1,noop(Entering context in extensions_custom.conf)
exten => s,n,GoSub(to the CFC feature code) ; forgot the actual string
exten => s,n,Playback(hello-world)
exten => s,n,Goto(ivr-1,s,1)
Seems like the CFC has it’s own hangup once it’s done with changing the state, so it does not return to continue with the Playback and Goto the IVR. Anyway of getting the CFC to return to this context, or to do something similar?
-- Executing [s@custom-code:4] Originate("SIP/TrunkName-000206d6", "local/*282@from-internal") in new stack
[2019-11-19 08:29:25] ERROR[77326][C-00010b07]: app_originate.c:144 originate_exec: Incorrect number of arguments
lorne14-pro*CLI> core show application Originate
-= Info about application 'Originate' =-
[Synopsis]
Originate a call.
[Description]
This application originates an outbound call and connects it to a specified
extension or application. This application will block until the outgoing call
fails or gets answered. At that point, this application will exit with the
status variable set and dialplan processing will continue.
This application sets the following channel variable before exiting:
${ORIGINATE_STATUS}: This indicates the result of the call origination.
FAILED
SUCCESS
BUSY
CONGESTION
HANGUP
RINGING
UNKNOWN: In practice, you should never see this value. Please report it to
the issue tracker if you ever see it.
[Syntax]
Originate(tech_data,type,arg1[,arg2[,arg3[,timeout]]])
[Arguments]
tech_data
Channel technology and data for creating the outbound channel.
For example, SIP/1234.
type
This should be 'app' or 'exten', depending on whether the outbound channel
should be connected to an application or extension.
arg1
If the type is 'app', then this is the application name. If the type is
'exten', then this is the context that the channel will be sent to.
arg2
If the type is 'app', then this is the data passed as arguments to the
application. If the type is 'exten', then this is the extension that the
channel will be sent to.
arg3
If the type is 'exten', then this is the priority that the channel is sent
to. If the type is 'app', then this parameter is ignored.
timeout
Timeout in seconds. Default is 30 seconds.
Something like Originate(local/*282@from-internal,app,wait,15). Didn’t test.
arg1 – If the type is ‘app’, then this is the application name. If the type is ‘exten’, then this is the context that the channel will be sent to.
arg2 – If the type is ‘app’, then this is the data passed as arguments to the application. If the type is ‘exten’, then this is the extension that the channel will be sent to.
arg3 – If the type is ‘exten’, then this is the priority that the channel is sent to. If the type is ‘app’, then this parameter is ignored
I think you are going to need to use the arguments to make this execute.
you cannot use extension, since there is not a matching extension. You could make an extension that dials the feature code. That might work.