Is there a way to append all materials in a Blender files with Python?
Example using BlendDataLibraries based on How can I import BI materials from another blender file with python?. The script scans the given directory for blend files and appends all materials:

import bpy
import os

blend_files = []
for root, dirs, files in os.walk("/home/&lt;USER&gt;/..."):
    for file in files:
        if file.endswith(".blend"):
             blend_files.append(os.path.join(root, file))

# Append all materials from all blends within the folder
for filepath in blend_files:
    with bpy.data.libraries.load(filepath, link=False) as (data_from, data_to):
        data_to.materials = data_from.materials 


A little bit of housekeeping might be nice in this case:

with bpy.data.libraries.load(filepath, link=False) as (data_from, data_to):
    data_to.materials = [m for m in data_from.materials if m.startswith("MATLIB_")]