I'm currently incorporating Firebase Dynamic Links in Flutter to allow users to send training plans to one another. I shorten the URL before sending and the flow works as expected on most apps/messaging. However, on iMessage specifically, the sent message is pasting additional text. Would love any help on getting to the root of this problem!
final DynamicLinkParameters parameters = DynamicLinkParameters(
// This should match firebase but without the username query param
uriPrefix: 'https://trainsolosoccer.page.link',
// This can be whatever you want for the uri, https://yourapp.com/groupinvite?username=$userName
link: Uri.parse(
'https://trainsolotest.page.link/planId?planId=$planId&userId=$userId&planName=$planName'),
androidParameters: AndroidParameters(
packageName: 'com.trainsolo',
minimumVersion: 1,
),
iosParameters: IosParameters(
bundleId: 'com.trainsolo',
minimumVersion: '1',
appStoreId: appStoreId,
),
socialMetaTagParameters: SocialMetaTagParameters(
title: '${username} has shared a training plan with you!',
description:
"Please download the Trainsolo app to access ${username}'s plan along with hundreds of other drills ...",
imageUrl: Uri.parse(
"https://static.wixstatic.com/media/30d704_86712894e6964d56a397977a37080252~mv2.jpg")),
);
final ShortDynamicLink shortDynamicLink = await parameters.buildShortLink();
final Uri link = shortDynamicLink.shortUrl;
// Flutter package: https://pub.dev/packages/share
Share.share(link)