Add documentation to router code