How to add custom logging to incoming and outgoing calls

I have asterisk and freepbx set up and working great now. I am trying to incoroporate an autodialer to asterisk.
The instructions for the autodialer require additions to extensions.conf. I would like to make these additions without starting a dialplan from scratch. Where can i add the following so that it would be included on all incoming and outgoing calls respectively. This is supposed to log all of the calls for outbound this line is supposed to go one step ahead of the dial application. For example.

(THIS) exten => _91NXXNXXXXXX, 1,AGI(call_log.agi, ${EXTEN})
exten => _91NXXNXXXXXX, 2,Dial(${TRUNK}/${EXTEN},tTo)
exten => _91NXXNXXXXXX, 3,Hangup

for incoming it should be like this:
; Extension 3429 - Inbound 800 number (1-800-555-3429)
exten => _**3429,1,Ringing
(THIS) exten => _**3429,2,AGI(call_log.agi,${EXTEN})
exten => _**3429,3,Answer
exten => _**3429,4,Dial,sip/spa2000&sip/spa2001|30|to
exten => _**3429,5,Voicemail,u2000

Did you ever figure out how to make this type of change? I’ve been trying to create a custom modification for all inbound calls that check for fax detection on all extensions. I haven’t had any luck yet.

You may want to add that line to all the dial-out macros in the extensions.conf file. This file will not get overwritten, but as it is a stock file do it at your own risk.

I’m pretty sure you are right in that I’ll have to modify the core dialplan. I’m trying to figure out a way to use the _custom files to add to it but no luck so far. Thanks for your reply.