Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add plugins docs #12

Merged
merged 2 commits into from
Sep 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion website/docs/adapters/google-adapter.md

This file was deleted.

2 changes: 0 additions & 2 deletions website/docs/changelog.md → website/docs/changelog.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,3 @@ sidebar_position: 1
---

# ChangeLog

12312
File renamed without changes.
8 changes: 1 addition & 7 deletions website/docs/intro/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,10 @@

## Install

```bash
```bash npm2yarn
npm install @hyperse/track --save
```

or you can use **yarn**

```bash
yarn add @hyperse/track
```

We have completed installing the package.

## Congratulations !
Expand Down
42 changes: 42 additions & 0 deletions website/docs/plugins/facebook-adapter.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
title: FacebookAdapter
description: FacebookAdapter
hide_table_of_contents: true
---

The FacebookAdapter streamlines the integration of Facebook Pixel event tracking within your @hyperse/track system, enabling you to leverage the full power of the Meta Pixel for comprehensive data collection and analysis.

**Key Features:**

- **Streamlined Pixel Integration:** Seamlessly integrate your Facebook Pixel with your @hyperse/track setup for a unified and efficient tracking experience.
- **TypeScript Typing:** Benefit from robust type safety and code completion through TypeScript definitions, ensuring accurate event data and reducing errors.
- **Comprehensive Event Tracking:** Track a wide range of events, including those essential for optimizing conversions, such as:
- **View Content:** Track when users view specific products or content.
- **Add to Cart:** Capture when users add items to their shopping carts.
- **Initiate Checkout:** Monitor when users begin the checkout process.
- **Complete Purchase:** Track successful purchases and their associated revenue.
- **Enhanced Conversion Optimization:** Leverage the rich event data collected through the Meta Pixel to create custom audiences, personalize ads, and optimize your Facebook Ads campaigns for better results.

**Benefits:**

- **Improved Audience Targeting:** Precisely target your Facebook Ads campaigns based on detailed user behavior data collected through the Meta Pixel, reaching your ideal audience effectively.
- **Enhanced Conversion Tracking:** Accurately track conversions and measure the effectiveness of your Facebook Ads, ensuring your advertising budget is allocated efficiently.
- **Data-Driven Insights:** Gain a deeper understanding of your audience and their engagement with your website, allowing you to make informed decisions about your marketing strategy.
- **Streamlined Workflow:** Simplify your tracking setup and management with a unified solution for both Facebook Pixel and your @hyperse/track system, reducing complexity and streamlining your workflow.
- **Improved Code Quality:** TypeScript types ensure accurate event data and prevent potential errors, leading to more reliable tracking and a cleaner codebase.

**With the FacebookAdapter, you can:**

- **Optimize Your Facebook Ads:** Use event data to create custom audiences, target relevant users, and personalize ads for higher conversion rates.
- **Analyze Customer Behavior:** Gain insights into customer journey stages, enabling you to identify areas for improvement and optimize user experience.
- **Increase Conversions:** Drive higher conversion rates by identifying and addressing potential pain points in the customer journey, ultimately leading to more sales.

**For a comprehensive guide on Facebook Pixel implementation, refer to the official documentation:** [https://developers.facebook.com/docs/meta-pixel/implementation/conversion-tracking](https://developers.facebook.com/docs/meta-pixel/implementation/conversion-tracking)

**Embrace the power of the Facebook Pixel and @hyperse/track with the FacebookAdapter. Unlock valuable data, optimize your advertising efforts, and drive better business outcomes.**

## Install

```bash npm2yarn
npm install @hyperse-hub/track-plugin-facebook --save
```
14 changes: 14 additions & 0 deletions website/docs/plugins/facebook-events/contact.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: contact
description: contact
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person initiates contact with your business via telephone, SMS, email, chat, etc.

## Parameters

This parameter is optional and can be defined by users
14 changes: 14 additions & 0 deletions website/docs/plugins/facebook-events/customize_product.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: customize_product
description: customize_product
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person customizes a product.

## Parameters

This parameter is optional and can be defined by users
14 changes: 14 additions & 0 deletions website/docs/plugins/facebook-events/donate.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: donate
description: donate
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person donates funds to your organization or cause.

## Parameters

This parameter is optional and can be defined by users
14 changes: 14 additions & 0 deletions website/docs/plugins/facebook-events/find_location.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: find_location
description: find_location
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person searches for a location of your store via a website or app, with an intention to visit the physical location.

## Parameters

This parameter is optional and can be defined by users
14 changes: 14 additions & 0 deletions website/docs/plugins/facebook-events/schedule.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: schedule
description: schedule
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person books an appointment to visit one of your locations.

## Parameters

This parameter is optional and can be defined by users
30 changes: 30 additions & 0 deletions website/docs/plugins/facebook-events/start_trial.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
title: start_trial
description: start_trial
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person starts a free trial of a product or service you offer.

## Parameters

### currency

<Property /> `string`

The currency of the specified `value`.

### predicted_ltv

<Property /> `number`

The predicted lifetime value of a subscriber, as defined by the advertiser, expressed as a precise value.

### value

<Property /> `number`

The value for the user performing this event to the business.
14 changes: 14 additions & 0 deletions website/docs/plugins/facebook-events/submit_application.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: submit_application
description: submit_application
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person applies for a product, service, or program you offer.

## Parameters

This parameter is optional and can be defined by users
28 changes: 28 additions & 0 deletions website/docs/plugins/facebook-events/subscribe.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
title: subscribe
description: subscribe
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="facebook" />

When a person applies to a start a paid subscription for a product or service you offer.

### currency

<Property /> `string`

The currency of the specified `value`.

### predicted_ltv

<Property /> `number`

The predicted lifetime value of a subscriber, as defined by the advertiser, expressed as a precise value.

### value

<Property /> `number`

The value for the user performing this event to the business.
37 changes: 37 additions & 0 deletions website/docs/plugins/google-adapter.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
title: GoogleAdapter
description: GoogleAdapter
hide_table_of_contents: true
---

The GoogleAdapter empowers you to seamlessly integrate your Google Analytics and Google Ads event tracking within your @hyperse/track setup.

**Key Features:**

- **Unified Tracking:** Capture and send events to both Google Analytics and Google Ads through a single, consistent interface.
- **TypeScript Typing:** Enjoy robust type safety and code completion through TypeScript definitions, ensuring accurate event data and reducing errors.
- **Effortless Integration:** Integrate the GoogleAdapter effortlessly into your @hyperse/track system, enabling fast and efficient tracking setup.
- **Comprehensive Event Data:** Track a wide range of events, including page views, form submissions, user interactions, and more, providing you with valuable insights.

**Benefits:**

- **Enhanced Insights:** Gain a deeper understanding of your users' behavior across both Google Analytics and Google Ads.
- **Improved Targeting:** Optimize your Google Ads campaigns by leveraging accurate user behavior data from your website.
- **Streamlined Workflow:** Simplify your tracking setup and management with a unified solution for both platforms.
- **Improved Code Quality:** TypeScript types ensure accurate event data and prevent potential errors.

**With the GoogleAdapter, you can:**

- Track critical events on your website.
- Analyze user behavior and engagement.
- Optimize your Google Ads campaigns for better results.

**For more information on Google Analytics and Google Ads, refer to the official documentation:** [https://developers.google.com/analytics/devguides/collection/](https://developers.google.com/analytics/devguides/collection/)

**Embrace the power of data-driven decision-making with the GoogleAdapter. Enhance your tracking capabilities, streamline your workflow, and unlock valuable insights for your business.**

## Install

```bash npm2yarn
npm install @hyperse-hub/track-plugin-google --save
```
50 changes: 50 additions & 0 deletions website/docs/plugins/google-events/add_shipping_info.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
title: add_shipping_info
description: add_shipping_info
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="google" />

This event signifies a user has submitted their shipping information in an ecommerce checkout process.

## Parameters

### currency

<Property /> `string` <Required required />

USD Currency of the items associated with the event, in 3-letter ISO 4217 format.

If you set value then currency is required for revenue metrics to be computed accurately.

### value

<Property /> `number` <Required required />

The monetary value of the event.

- Set value to the sum of (price \* quantity) for all items in items. Don't include shipping or tax.
- value is typically required for meaningful reporting. If you mark the event as a key event then it's recommended you set value.
- currency is required if you set value.

### coupon

<Property /> `string`

The coupon name/code associated with the event.

Event-level and item-level coupon parameters are independent.

### shipping_tier

<Property /> `string`

The shipping tier (e.g. Ground, Air, Next-day) selected for delivery of the purchased item.

### items

<Property /> [Item](../types/standard-goods-item.mdx)[] <Required required />

The items for the event.
18 changes: 18 additions & 0 deletions website/docs/plugins/google-events/login.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
title: login
description: login
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="google" />

Send this event to signify that a user has logged in to your website or app.

## Parameters

### method

<Property /> `string` <Required required />

The method used to login.
64 changes: 64 additions & 0 deletions website/docs/plugins/google-events/refund.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
---
title: refund
description: refund
hide_table_of_contents: false
toc_max_heading_level: 4
---

<NpmLink name="google" />

This event signifies when one or more items is refunded to a user.

## Parameters

### currency

<Property /> `string` <Required required />

USD Currency of the items associated with the event, in 3-letter ISO 4217 format.

If you set value then currency is required for revenue metrics to be computed accurately.

### value

<Property /> `number` <Required required />

The monetary value of the event.

- Set value to the sum of (price \* quantity) for all items in items. Don't include shipping or tax.
- value is typically required for meaningful reporting. If you mark the event as a key event then it's recommended you set value.
- currency is required if you set value.

### transaction_id

<Property /> `string` <Required required />

The unique identifier of a transaction.

The `transaction_id` parameter helps you avoid getting duplicate events for a purchase.

### coupon

<Property /> `string`

The coupon name/code associated with the event.

Event-level and item-level coupon parameters are independent.

### shipping

<Property /> `number`

Shipping cost associated with a transaction.

### tax

<Property /> `number`

Tax cost associated with a transaction.

### items

<Property /> [Item](../types/standard-goods-item.mdx)[] <Required required />

The items for the event.
Loading
Loading