Skip to main content@codeqr/analytics is a client-side script for tracking conversion events with CodeQR.
By default, the script handles the detection of the cq_id query parameter and storing it as a first-party cookie:
Then, when a conversion event occurs (e.g. a user signs up for an account), you can check for the cq_id cookie and attribute the conversion to the original click by tracking a lead event.
Finally, when the user completes a purchase (e.g. subscribing to a plan, purchasing a product, etc.), you can track a sale event. Under the hood, CodeQR will automatically attribute the sale to the original link click.