What is the best way to intercompany an AP credit from one company to another company?

SOLVED

We have multiple companies that ultimately rolls into one set of financials.  Company A accidentally paid invoice #1 for $100.00 when invoice #1 actually belonged to Company B.  Company B also received and paid for invoice #1 already.  Company B wants to use the credit that belongs to Company A.  We do not utilize  AR for this purpose, so I need to do this through AP.  

There will be no actual money exchanged between A and B.  How can entries be made in AP so that a trail is left?  

Thanks.