Amafilliate is a project mainly written in Python, it's free.
Django middleware/view decorator to put amazon affiliate into pages
This is just a basic middleware/decorator pair to put in amazon affiliate links from a setting variable. I get the feeling I could change it a bit to replace links for a few more services. It's all pretty much the same thing.
Add to your settings.py
file middleware tuple:
('amazonaffiliate.middleware.AmazonAffiliateMiddleware'),