All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad  is His slave and Messenger.
  is His slave and Messenger.
At-Tawassul by the Prophet  is of three kinds:
  is of three kinds:
1- Seeking Tawassul by declaring your belief in the Prophet  like saying: “O Allah! Forgive me for believing in You and in Your Prophet
  like saying: “O Allah! Forgive me for believing in You and in Your Prophet  . This kind of Tawassul is lawful during the life time of the Prophet
. This kind of Tawassul is lawful during the life time of the Prophet  and after his death.
  and after his death.
2- Seeking Tawassul of the Prophet  by supplicating him, i.e. by asking the Prophet to supplicate Allah for you. This kind of Tawassul is lawful only during the life time of the Prophet
  by supplicating him, i.e. by asking the Prophet to supplicate Allah for you. This kind of Tawassul is lawful only during the life time of the Prophet  and not after his death as this is impossible after his death. It is confirmed that ‘Umar
  and not after his death as this is impossible after his death. It is confirmed that ‘Umar  said: “O Allah, we used to request our Prophet to supplicate to You for rain and You would grant us rain, and now we are requesting the uncle of our Prophet (i.e. Al-Abbaas Ibn Abdul Muttalib) to supplicate to You for rain, so grant us rain." Then he ordered Al-‘Abbaas to stand and supplicate Allah for rain. [Al-Bukhari] And his saying "O Allah, we used to request our Prophet to supplicate to You for rain and You would grant us rain”, means we make Tawassul to You with our Prophet
  said: “O Allah, we used to request our Prophet to supplicate to You for rain and You would grant us rain, and now we are requesting the uncle of our Prophet (i.e. Al-Abbaas Ibn Abdul Muttalib) to supplicate to You for rain, so grant us rain." Then he ordered Al-‘Abbaas to stand and supplicate Allah for rain. [Al-Bukhari] And his saying "O Allah, we used to request our Prophet to supplicate to You for rain and You would grant us rain”, means we make Tawassul to You with our Prophet  and he would supplicate for us. Had this kind of Tawassul (asking supplication from a dead person) after the death of the Prophet
  and he would supplicate for us. Had this kind of Tawassul (asking supplication from a dead person) after the death of the Prophet  been permissible, ‘Umar, would not have asked Al-‘Abbaas
  been permissible, ‘Umar, would not have asked Al-‘Abbaas  to supplicate for them but he would have asked this from the Prophet
  to supplicate for them but he would have asked this from the Prophet  .
.
3- Seeking Tawassul by the high rank and status of the Prophet  in the sight of Allah. This kind of Tawassul is not permissible neither during the life time of the Prophet
  in the sight of Allah. This kind of Tawassul is not permissible neither during the life time of the Prophet  nor after his death as this is not confirmed from the Prophet
  nor after his death as this is not confirmed from the Prophet  and because Allah Says (what means): {O you who have believed, fear Allaah and seek the means [of nearness] to Him.} [Quran 5:34] The scholars interpreted {means [of nearness] to Him} to mean the good deeds. Qatadah
  and because Allah Says (what means): {O you who have believed, fear Allaah and seek the means [of nearness] to Him.} [Quran 5:34] The scholars interpreted {means [of nearness] to Him} to mean the good deeds. Qatadah  said: “You should get near to Allah by obeying Him and doing what pleases Him.” There are some people who think that they can get near to Allah by means of the high rank of His Prophet
  said: “You should get near to Allah by obeying Him and doing what pleases Him.” There are some people who think that they can get near to Allah by means of the high rank of His Prophet  giving evidence of some objectionable, Dha’eef (weak) or fabricated Ahadeeth on the Prophet
  giving evidence of some objectionable, Dha’eef (weak) or fabricated Ahadeeth on the Prophet  like the Hadeeth which reads “Seek Tawassul by my high rank. Indeed, my high rank is great in the sight of Allaah.” Imaam Ash-Shawkaani
  like the Hadeeth which reads “Seek Tawassul by my high rank. Indeed, my high rank is great in the sight of Allaah.” Imaam Ash-Shawkaani  said: “There is no foundation for this Hadeeth (i.e. it is not authentic).”
  said: “There is no foundation for this Hadeeth (i.e. it is not authentic).”
Some people may even resort to clear polytheism by seeking Tawassul as they ask the Prophet  or some Awliyah (pious people) to make a way out to their hardship, repel harm from them or bring benefit for them. One of them says in this respect: “O, Prophet of Allah help us! Every thing depends on you! Make a way out to our difficulty! Indeed, worries run away from you when they see you.” Whereas, it is Allah Alone who makes a way out to difficulties, repels harm and brings benefit, and this should not be asked except from Allah Alone but they call it Tawassul to deceive and mislead the people.
  or some Awliyah (pious people) to make a way out to their hardship, repel harm from them or bring benefit for them. One of them says in this respect: “O, Prophet of Allah help us! Every thing depends on you! Make a way out to our difficulty! Indeed, worries run away from you when they see you.” Whereas, it is Allah Alone who makes a way out to difficulties, repels harm and brings benefit, and this should not be asked except from Allah Alone but they call it Tawassul to deceive and mislead the people.
Finally, here are some references that could be consulted for more details:
1- The Book entitled: Qa’idah Jaleelah fi At-Tawassul wal-Waseelah (A good rule concerning Tawassul and Waseelah), authored by Ibn Taymiyyah  .
.
2- The Book entitled: At-Tawassul Ah-kaamuhu wa An-Waa’uhu (Tawassul: its kinds and Rulings), authored by Shaykh Al-Albaani  .
.
For more benefit, please refer to Fataawa 142097, 89076 and 89352.
Allah knows best.