Reputation: 2178
In my Ionic 5 app, I am trying to provide functionality for users to copy a Branch.io link from anywhere and paste/type it in the App. I want to use the link and trigger the same action when it is clicked to get the data and perform the action in the App.
I am using Ionic BranchIo plugin.
I am not getting any Branch method to do this action and decode the link. Method branch.initSession()
will only work if the link is clicked.
Any ideas on how can I achieve this?
Upvotes: 0
Views: 1207
Reputation: 3924
Since you are trying to read the link data associated to the deep link you can use the Branch Deep Linking API for this use case.
Example Request Payload -
curl -XGET 'https://api2.branch.io/v1/url?url=https://example.app.link/WgiqvsepqF&branch_key=key_live_xxxxxxxx'
Upvotes: 1