Calling a line of one context into another context

My Question:
Is there a way for me to pull one line of an extension in the [play-system-recording] context into my existing custom dialplan [custom-1]?

What’s the correct way to write the dialplan for [custom-1] so that it calls step two of exten 57 before going to the next s step of the custom-1 context? I cannot alter the play-system-recording context in any way.

Example:
I need extension 57 custom recording on line 2 (just line 2) to play on my custom context before proceeding on with my custom context:

[play-system-recording]
include => play-system-recording-custom
exten => 57,1,Answer
exten => 57,n,Playback(custom/1021132)
exten => 57,n,Hangup

[custom-1]
exten => s,1,Answer
exten => s,n,play-system-recording,57,2
exten => s,n,...

Thanks for your help!

You can use the goto function

exten => 400,1,Goto(JumpingContext,start,1) 

GoTo is a permanent transfer. The OP wants a subroutine type access, with an implied return, after only one only one line. Chances are that they also don’t want to modify the called code.

3 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.