fixes to posting json data, split up post and put for resources