Possible to pass the source of a visitor to another application or cookie?

Hi All!
I’m looking for a solution to collect the source of a visitor and pass that to a CRM (Neolane / Adobe campaign) that tracks the page visits of a user. Please note: we don’t have access to Adobe Analytics, before you suggest it.

Right now we don’t know if they came from Social, Referral, Direct, Organic or Paid source but we know they visited.
Could I collect the source of a visit from Piwik and pass it to a cookie or another application easily?


Yes it is possible. Check out the Piwik JS function getAttributionInfo, reference: JavaScript Tracking Client: API Reference - Matomo Analytics (formerly Piwik Analytics) - Developer Docs - v3