Created
June 22, 2023 15:05
-
-
Save davidknipe/2ba0727f1fb2aba5a9f3ea89f2fe62eb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
EPiServer.Cms.WelcomeIntegration.Core.IDAMAssetIdentityResolver _damAssetIdentityResolver; | |
var damUrl = "https://images2.welcomesoftware.com/assets/UrlOfImageFromOptimizely.com"; | |
DAMMetadata damMetadata = new DAMMetadata("Title of the asset", DAMAssetType.Image); // Swap to .Video if appropriate | |
var mappedIdentity = _damAssetIdentityResolver.Get(new Uri(damUrl), JsonSerializer.Serialize<DAMMetadata>(damMetadata), true); | |
var contentLinkToSave = mappedIdentity.ContentLink; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment