start_date_iso = args.start_date
    end_date_iso = args.end_date
    phone_uuid_path = args.phone_uuid_table_path
    message_uuid_path = args.message_uuid_table_path
    json_output_path = args.json_output_path

    # Parse the provided ISO dates
    user_start_date = isoparse(start_date_iso)
    user_end_date = isoparse(end_date_iso)

    # TODO: Test that isoparse is only accepting dates with time-zone offsets.
    # TODO: Print a helpful message if the user enters an invalid ISO date.

    # Load the existing UUID tables
    with open(phone_uuid_path, "r") as f:
        phone_uuids = PhoneNumberUuidTable.load(f)
    with open(message_uuid_path, "r") as f:
        message_uuids = MessageUuidTable.load(f)

    session = EchoMobileSession(verbose=verbose_mode)
    try:
        # Download inbox report from Echo Mobile.
        session.login(echo_mobile_username, echo_mobile_password)
        session.use_account_with_name(account_name)

        # Convert start/end dates into an Echo Mobile time zone.
        echo_mobile_start_date = session.datetime_to_echo_mobile_datetime(user_start_date)
        echo_mobile_end_date = session.datetime_to_echo_mobile_datetime(user_end_date)

        report = session.messages_report(
            echo_mobile_start_date.strftime("%Y-%m-%d"), echo_mobile_end_date.strftime("%Y-%m-%d"),
                             "datasets")
    parser.add_argument("output_path", metavar="output-path",
                        help="CSV file to write the REACH contacts to")

    args = parser.parse_args()

    traced_data_path = args.traced_data_path
    phone_number_uuid_table_path = args.phone_number_uuid_table_path
    output_path = args.output_path

    sys.setrecursionlimit(15000)

    # Load the phone number <-> uuid table
    log.info(f"Loading the phone number <-> uuid table from file '{phone_number_uuid_table_path}'...")
    with open(phone_number_uuid_table_path, "r") as f:
        phone_number_uuid_table = PhoneNumberUuidTable.load(f)
    log.info(f"Loaded {len(phone_number_uuid_table.numbers())} contacts")
    
    # Load the REACH traced data
    log.info(f"Loading REACH traced data from file '{traced_data_path}'...")
    with open(traced_data_path, "r") as f:
        data = TracedDataJsonIO.import_json_to_traced_data_iterable(f)
    log.info(f"Loaded {len(data)} traced data objects")

    # Search the TracedData for consenting contacts
    log.info("Searching for consenting uuids...")
    consenting_uuids = set()
    for td in data:
        if td["withdrawn_consent"] == Codes.TRUE:
            continue
        consenting_uuids.add(td["UID"])