methods for post, get and update.