script for api method testing