The sample code for api automation