Add support for cookies and headers