Skip to main content
Version: 3.0.0-beta.1

StorifyMeExperience

Flutter SDK 3.0 callbacks use StorifyMeExperience, the shared model for stories, shorts, snaps, and ad experiences. It replaces the older StorifyMeStory callback model.

Properties​

PropertyDescription
id, widgetIdExperience and widget identifiers
typestory, shorts, snap, ad, or unknown
name, handle, tagsExperience metadata
navigationUrlApp link or web URL configured for the experience
thumbnailUrlBest available preview image URL
totalDurationPlayback duration in seconds, when available
isSeenWhether the user completed the experience
adInfoAd source and custom creative data for ad experiences

deeplink remains as a deprecated alias for navigationUrl. The legacy Flutter model still has older fields; the v3 native SDKs do not expose isLive, isNew, or seenAtMillis as public experience properties.

Branch on content type​

void onOpened(StorifyMeExperience? experience, int index) {
switch (experience?.type) {
case StorifyMeExperienceType.story:
analytics.track('story_opened', experience!.id);
break;
case StorifyMeExperienceType.shorts:
analytics.track('short_opened', experience!.id);
break;
case StorifyMeExperienceType.snap:
analytics.track('snap_opened', experience!.id);
break;
case StorifyMeExperienceType.ad:
analytics.track('ad_opened', experience!.id);
break;
default:
break;
}
}

StorifyMeExperienceType.short is a deprecated enum alias. Use shorts in new code.

Ad metadata​

final adInfo = experience.adInfo;
if (adInfo?.source == StorifyMeAdSource.custom) {
debugPrint('Advertiser: ${adInfo?.ad?.advertiserName}');
}

StorifyMeAdInfo.source can be custom, storifyme, google, or unknown. Custom ads include a typed StorifyMeAd payload.

Open an experience from a widget​

The widget state exposes v3 navigator names:

await widgetKey.currentState?.openWidgetExperienceByHandle(
'summer-campaign',
experienceBehaviour: const StorifyMeExperienceBehaviour(
playbackBehaviour: StorifyMeExperiencePlaybackBehaviour.restartExperiencesWhenOpen,
),
);

The same API is available by position and ID. openWidgetItemByPosition, openWidgetItemByHandle, and openWidgetItemById remain available for existing apps.