Potiphar (his name a derivate of Potiphera meaning that he was given by Ra) was an Egyptian official, serving the Pharaoh of the Exodus, as his captain of the guard. He was responsible for the personal protection of the Egyptian King, his family and court; as well as presiding over the Royal Prison. Potiphar being a high ranking official of the Pharaoh, owned his own field as well as his house. He is most notable for purchasing Joseph as a slave, and promoting him to an attendant, as well as the adulterous behaviors of his wife.
Potiphar was one of the Pharaoh's officials, and was the Captain of the Guard of the Pharaoh at the time of Joseph. As the Captain of the Guard he was responsible for the Pharoah's security, and oversaw the royal prison in which people sentenced to imprisonment by Pharaoh or an official were imprisoned.
Obviously, as Captain of the Guard he was amongst the Pharoah's most trusted officials and was given high authority in the kingdom. Potiphar owned a house and had several servants. At one point he purchased Joseph from Ishmaelite traders from Midian. Potiphar's property likely had a place where his servants could stay as Joseph lived on the estate. Potiphar began to enjoy Joseph and seeing that he had been divinely blessed, put him in charge of management of his entire property, making Jospeh his personal attendant. The only thing that Potiphar restricted Joseph's authority from was his wife. While Joseph was his attendant, Potiphar was immensely blessed both in his house and in his fields.
Eventually Potiphar's wife began to notice that Joseph was attractive and attempted to seduce him into adultery against her husband. Joseph refused her advances several times. One day Potiphar's wife was able to pull a garment off Joseph when no one was in the house, yet he still refused bed with her. When Potiphar was home, he was told by his wife that Joseph had attempted to rape her.
Outraged by this alleged atrocity, Potiphar used his authority over the Royal Prison to have Joseph put in prison. While in prison, Joseph flourished and was given authority over all the prisoners by Potiphar's subordinate, the manager of the Royal Prison.
Potiphar likely was the Captain of the Guard when the King's Chief Cupbearer and Chief Baker were both imprisoned under his jurisdiction. At one point, Potiphar may have specially assigned Joseph to oversee the King's former officials.