As reported to the FAA. Reports are unverified, and codes are left as the FAA publishes them.
What was found
WHILE CLIMBING OUT THE COCKPIT DOOR OPENED. THE CREW TRIED TO SECURE THE DOOR CLOSED BUT A HINGE WAS BROKEN & LOOSE & THE DOOR WOULD NOT SECURE. THE CREW ADVISED THE TRAVELING FAMS. THE CREW ELECTED TO DIVERT FOR MX. AN EMER WAS DECLARED & THE FLIGHT LANDED & TAXIED TO GATE WITHOUT INCIDENT. R & R THE COCKPIT DOOR HINGES.