testing conditional outcomes for each api method