update api method