Refactor contact type parsing to dynamic