added contact template, fixed authorization