added delete function and optimized auth parameters