Asterisk AsyncAGI

How can I exec the dialplan command such as ExecIf with AGICommand: EXEC? I tried to run it through the AMI (AsyncAGI)

Ex: “Command: EXEC ExecIf $[${STAT(e,filename)}]?PlayBack(something1):PlayBack(something)”

P. S. Asterisk 13.7.2