Elohim visited Sarah and made her fertile. A full 25 years had passed since Elohim first promised prosperity to Abraham. It was a year after Elohim last visited Abraham and Sarah and she bore a son just as promised. This is the first recorded instance of circumcision on the eighth day.
Abram was already declared righteous by faithfulness in Gen. 15:6. Why must he now walk blameless before Elohim? Because Abram is demonstrating his faithfulness by walking blameless before Elohim. Israel was told to do the same thing (Deut. 18:13). We are told the same thing (Matt. 5:48).
Hagar was an Egyptian and was probably given to them by Pharaoh when they went to Egypt and Sarai was taken to Pharaoh. Hagar was given to Abram as a wife as desired by Sarai. We should keep in mind that all wives are not equal. If a man had more than one wife, one wife was primary and the others had a lower status. In this case, Sarai had primary status and Hagar was a lesser wife subject to Sarai as well as Abram.