The type of anesthesia you receive to prevent pain during surgery depends on the procedure you’re having. The type of procedure also can affect your considerations for recovery, including your options for managing postsurgical pain.