Built main api method