added parameter API_FILE_PATH for testing with local output files