Is using the referrerURL NSuseractivity an option?
https://developer.apple.com/documentation/foundation/nsuseractivity/2875762-referrerurl
https://developer.apple.com/documentation/xcode/allowing_apps_and_websites_to_link_to_your_content/supporting_universal_links_in_your_app