#dataname = Object name

#Deselect and select
bpy.ops.object.mode_set(mode='OBJECT', toggle=False)
bpy.ops.object.select_all(action='DESELECT')
bpy.data.objects[dataname].select_set(state=True)
bpy.context.view_layer.objects.active = bpy.data.objects[dataname]

# Remove vertecies to clean mesh blank before add new imported
bpy.ops.object.mode_set(mode='EDIT')
bpy.ops.mesh.reveal()
bpy.ops.mesh.select_all(action='DESELECT')
bpy.ops.mesh.select_all(action='SELECT')
bpy.ops.mesh.delete(type='VERT')
bpy.ops.object.mode_set(mode='OBJECT')

me = bpy.data.meshes[dataname]

default obj import script follows…

me.vertices.add(len(verts_loc))
me.loops.add(tot_loops)
me.polygons.add(len(faces))



obj = bpy.context.selected_objects[0]
        active_material
        active_material_index
        active_shape_key
        active_shape_key_index
        animation_data
        animation_data_clear(
        animation_data_create(
        animation_visualization
        as_pointer(
        bl_rna
        bl_rna_get_subclass(
        bl_rna_get_subclass_py(
        bound_box
        cache_release(
        calc_matrix_camera(
        camera_fit_coords(
        children
        closest_point_on_mesh(
        collision
        color
        constraints
        convert_space(
        copy(
        cycles
        cycles_visibility
        data
        delta_location
        delta_rotation_euler
        delta_rotation_quaternion
        delta_scale
        dimensions
        display
        display_bounds_type
        display_type
        driver_add(
        driver_remove(
        empty_display_size
        empty_display_type
        empty_image_depth
        empty_image_offset
        empty_image_side
        evaluated_get(
        face_maps
        field
        find_armature(
        generate_gpencil_strokes(
        get(
        grease_pencil_modifiers
        hide_get(
        hide_render
        hide_select
        hide_set(
        hide_viewport
        holdout_get(
        id_data
        image_user
        indirect_only_get(
        instance_collection
        instance_faces_scale
        instance_type
        is_deform_modified(
        is_evaluated
        is_from_instancer
        is_from_set
        is_instancer
        is_library_indirect
        is_modified(
        is_property_hidden(
        is_property_overridable_library(
        is_property_readonly(
        is_property_set(
        items(
        keyframe_delete(
        keyframe_insert(
        keys(
        library
        local_view_get(
        local_view_set(
        location
        lock_location
        lock_rotation
        lock_rotation_w
        lock_rotations_4d
        lock_scale
        make_local(
        material_slots
        matrix_basis
        matrix_local
        matrix_parent_inverse
        matrix_world
        mode
        modifiers
        motion_path
        name
        name_full
        original
        override_create(
        override_library
        parent
        parent_bone
        parent_type
        parent_vertices
        particle_systems
        pass_index
        path_from_id(
        path_resolve(
        pop(
        pose
        pose_library
        preview
        property_overridable_library_set(
        property_unset(
        proxy
        proxy_collection
        ray_cast(
        rigid_body
        rigid_body_constraint
        rna_type
        rotation_axis_angle
        rotation_euler
        rotation_mode
        rotation_quaternion
        scale
        select_get(
        select_set(
        shader_effects
        shape_key_add(
        shape_key_clear(
        shape_key_remove(
        show_all_edges
        show_axis
        show_bounds
        show_empty_image_only_axis_aligned
        show_empty_image_orthographic
        show_empty_image_perspective
        show_in_front
        show_instancer_for_render
        show_instancer_for_viewport
        show_name
        show_only_shape_key
        show_texture_space
        show_transparent
        show_wire
        soft_body
        tag
        to_mesh(
        to_mesh_clear(
        track_axis
        type
        type_recast(
        up_axis
        update_from_editmode(
        update_tag(
        use_dynamic_topology_sculpting
        use_empty_image_alpha
        use_fake_user
        use_instance_faces_scale
        use_instance_vertices_rotation
        use_shape_key_edit_mode
        user_clear(
        user_of_id(
        user_remap(
        users
        users_collection
        users_scene
        values(
        vertex_groups
        visible_get(
        visible_in_viewport_get(

obj.active_material.
                        alpha_threshold
                        animation_data
                        animation_data_clear(
                        animation_data_create(
                        as_pointer(
                        bl_rna
                        bl_rna_get_subclass(
                        bl_rna_get_subclass_py(
                        blend_method
                        copy(
                        cycles
                        diffuse_color
                        driver_add(
                        driver_remove(
                        evaluated_get(
                        get(
                        grease_pencil
                        id_data
                        is_evaluated
                        is_grease_pencil
                        is_library_indirect
                        is_property_hidden(
                        is_property_overridable_library(
                        is_property_readonly(
                        is_property_set(
                        items(
                        keyframe_delete(
                        keyframe_insert(
                        keys(
                        library
                        line_color
                        line_priority
                        make_local(
                        metallic
                        name
                        name_full
                        node_tree
                        original
                        override_create(
                        override_library
                        paint_active_slot
                        paint_clone_slot
                        pass_index
                        path_from_id(
                        path_resolve(
                        pop(
                        preview
                        preview_render_type
                        property_overridable_library_set(
                        property_unset(
                        refraction_depth
                        rna_type
                        roughness
                        shadow_method
                        show_transparent_back
                        specular_color
                        specular_intensity
                        tag
                        texture_paint_images
                        texture_paint_slots
                        type_recast(
                        update_tag(
                        use_backface_culling
                        use_fake_user
                        use_nodes
                        use_preview_world
                        use_screen_refraction
                        use_sss_translucency
                        user_clear(
                        user_of_id(
                        user_remap(
                        users
                        values(