added credentials support