write 'json' when it's specified as the resposne type