Can't directly open whatsapp chat group invite

3,027

For universal links to work with url_launcher on iOS you need to pass the forceSafariVC param as false so that it doesn't open the Safari view first:

launch(url, forceSafariVC: false);
Share:
3,027
Vinícius Assis Neves
Author by

Vinícius Assis Neves

Updated on December 21, 2022

Comments

  • Vinícius Assis Neves
    Vinícius Assis Neves over 1 year

    I need to open a whatsapp chat group link invite (https://chat.whatsapp.com/############) from my flutter app without opening the browser first. just using url_launcher and launch('https://chat.whatsapp.com/############') works on android, but on IOS it opens Safari first.

    I had the same problem for telegram, but I found this: tg://join?invite=XXXXXX, which I'm 99% sure it will work for IOS, but I didn't find anything similar for Whatsapp, except for Whatsapp://send= but it doesn't work to open the invite

    • Sami Haddad
      Sami Haddad almost 4 years
      Which iOS version are you trying, I tried it now on 13.5 and it's working.
    • Sami Haddad
      Sami Haddad almost 4 years
      Also do you have latest Whatsapp version?
    • Vinícius Assis Neves
      Vinícius Assis Neves almost 4 years
      Yes I do, I don't believe it has to do with Whatsapp version since I had the same problem on telegram, but to solve it just needed to use the URL scheme tg://join?invite=
    • Vinícius Assis Neves
      Vinícius Assis Neves almost 4 years
      Sorry, didn't see your first question, I'll check
    • Sami Haddad
      Sami Haddad almost 4 years
      Can you confirm that the new solution works for you.
    • Vinícius Assis Neves
      Vinícius Assis Neves almost 4 years
      I don't have an IOS with me, waiting for my boss to test it, I'll let you know and confirm your answer, thanks
  • Vinícius Assis Neves
    Vinícius Assis Neves almost 4 years
    Please read the question, I don't want to send a message to one user, I want to open a group invite.
  • Vinícius Assis Neves
    Vinícius Assis Neves almost 4 years
    Sorry the delay, Worked very well now, thank you very much!