made the api respond only to post