Very slow when try to get result by API

Hi i have made small webapp which uses your api to show few sites result

look at here

here is list of all test with dates and firstbyte value in right column have link to it’s test result url.

So when i am doing test vai API it’s showing slow like 300-500 for firstbyte but same site when i am doing manually by your site like this

it’s showing faster result with value of firstbyte around 100-200. can any one tell me why this is happens ?

Thank you so much