from pxr import Usd

pts_attr: Usd.Attribute = mesh_prim.GetAttribute("points")
if pts_attr.IsValid():
    print("Attribute exists!")

Alternatively, Usd.Object overrides the boolean operator so you can check with a simple boolean expression.

from pxr import Usd

pts_attr: Usd.Attribute = mesh_prim.GetAttribute("points")
if pts_attr:
    print("Attribute exists!")