FreePBX, I need an AGI script added to all sip extensions

When I create a SIP extension in FreePBX it adds the data to [ext-local]. When it does that I need it to add an extra line

Where the “2000” is the extension number.

I manually added the line to the extensions_additional.conf just to test my code and it worked, but that is a file managed by FreePBX so it removes it at every update.

Is there a config file or setting I can modify to have this done automatically? or a plugin/module perhaps? Or am I going to have to resort to editing the “” file in FreePBX?

Maybe I am going in the wrong direction completely and there is another place I can add it that will apply it to all extensions.

Thanks in advance.

Yes you need to edit the if that file have the realted code to generate the dialplan that you want to edit.