APIGen: Automated PIpeline for Generating Verifiable and Diverse Function-Calling Datasets