1 year ago
#181682
Dennis Ashford
Firebase Dynamic Links Not Working on Apple iMessage (Flutter)
I have implemented dynamic links into a flutter app I am working on. They are working as expected on everything I have tested EXCEPT iMessage. What is odd is if I copy and paste the link from the share popup, the message appears and send correctly. However, if I share it directly to iMessage (without the copy/paste step) the text preview is fine, but when it send it only shows the long link and not any of the preview meta data.
Link Generation:
class DynamicLinkService {
Future<Uri> createDynamicLink(String navPage, String id) async {
final DynamicLinkParameters parameters = DynamicLinkParameters(
uriPrefix: 'https://example.page.link',
link: Uri.parse('https://example.com/?navPage=$navPage&id=$id'),
androidParameters: AndroidParameters(
packageName: 'com.example.example',
minimumVersion: 1,
),
iosParameters: IosParameters(
bundleId: 'com.example.example',
minimumVersion: '1',
appStoreId: '12345678',
),
);
var dynamicUrl = await parameters.buildShortLink();
final Uri shortUrl = dynamicUrl.shortUrl;
return shortUrl;
}
On press link generation:
class _FeedPageWidgetState extends State<FeedPageWidget>
final DynamicLinkService _dynamicLinkService = DynamicLinkService();
Align(
alignment: AlignmentDirectional(0, 0),
child: FlutterFlowIconButton(
icon: Icon(),
onPressed: () async {
var uri = await _dynamicLinkService
.createDynamicLink('param 1', 'param 2');
await Share.share(uri.toString());
print(uri.toString());
},
),
),
Below are some image examples of what I am seeing: Image preview selecting iMessage directly from the share popup.
Image of link after sending. Notice it only shows the full dynamic link.
Image showing copying and pasting the dynamic link from the share pop-up. Notice how it sends correctly in this manner.
Any help on this?
ios
firebase
flutter
dynamic-linking
imessage
0 Answers
Your Answer