Dialplan to detect if context have includes

Hi. I need help.

I have this:

[internal]
include => A
include => B
exten=>71,1,Dial(SIP/71)

I need a way to display inside a NoOp() if the context [interna] have the include => Ainside of it.

If the context have the include => A, set the variable: TEST=1

I need help here. I was trying using EXIST_DB but, any function check if EXIST something inside of context?

Thanks!

I think there is no way of knowing this in Asterisk dialplan. The “include =>” statements are read only when Asterisk is parsing the dialplans on boot or on “dialplan reload”.

What is the use case that requires this?

include needs to be encoded in the internal data structures. It is #include that is resolved at load time. However, I agree that the use case is needed here.