fix module error in mock, document api generator