This passage contains one of the most problematic statements for people who feel like God causes bad things to happen. Joseph reveals himself to his brothers, and they must have immediately assumed he would want revenge for what they had done to them. He reassures them that he holds them no ill will, that it was God that sent him to Egypt to save them from the drought.
I cannot answer empirically, authoritatively, how literally this was meant. I certainly can’t tell you how literally Joseph meant it, but I can’t tell you how literally we are meant to accept it, either. I can only tell you how I respond to it, how I feel led to respond to it.
Personally, I go back to the dreams. The dreams were given to a young man, a boy. He was 17 when he took a bad report to his father regarding his brothers. It isn’t clear how much time passes between that and his dreams, his being sold, but he was young. He was young, and he knew his father favored him. He was young, and he knew his brothers hated him. Whether he was naive and sharing dreams he found amusing (which seems unlikely) or intentionally trying to antagonize brothers he did not get along with (you don’t like me? Fine, you don’t have to; I’m special,) the dreams were a catalyst.
God knew what the response to them would be. Did he cause the response? I don’t believe so. Who knows how the relationships would have played out without them. It wouldn’t have been good, we can safely assume that.
I conclude that God uses our proclivities, good and bad, to further his plan. I believe he used the dreams to instigate a chain of events without forcing anyone’s hand. I believe that had anyone, Joseph or his brothers, made a different, better choice, there would have been another path forward. I do not believe that God causes anything bad to happen. I do not believe that God’s plan requires bad things to happen. I believe God makes use of the bad that exists and will exist.
(Don’t ask me how redemption would have come about without the corruption of the Jewish leadership. I don’t know. I would hazard a guess that it was simply unavoidable, that redemption would have simply happened in a different time.)
So when Joseph says “God sent me,” it can be understood both literally and figuratively. God influenced the timing. God had a purpose, a plan in place. God was in no way caught off guard by the course of events and did not have to scramble for a back-up plan. God had a reason for Joseph to be in Egypt when he was in Egypt. But his brothers absolutely sinned against both him and God when they betrayed him the way they did, and God was not responsible for making them do so.
When you lose your job, or someone dies tragically, or anything at all happens in your life that you did not expect and are grieving, I will not be the one to tell you it is all in God’s plan. I will sit with you, walk with you, until you are ready to consider how it can be redeemed, to be assured that he was not surprised, and that he can, will, use it to bring about something even better, at the very least something good.