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

feat: accoil analytics documentation #1196

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
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
146 changes: 146 additions & 0 deletions docs/destinations/streaming-destinations/accoil-analytics.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
---
title: "Accoil Analytics"
description: Send data from RudderStack to **Accoil Analytics**.
aliases: ["accoil","accoil analytics"]
---

[Accoil](https://www.accoil.com) is a product analytics platform built specifically for B2B go-to-market (GTM) teams, like product, sales, marketing, customer success, and support. It enables you to track feature adoption, monitor user journeys, and enhance activation and conversion rates. By sending your product event data to Accoil using Segment, you unlock actionable insights that drive informed decisions across your organization.

For any questions or help with Accoil, <a href="https://help.accoil.com">contact the Accoil support team</a>.

<div class="infoBlock">
Find the open source transformer code for this destination in the <a href="https://github.com/rudderlabs/rudder-transformer/tree/master/src/cdk/v2/destinations/accoil_analytics">GitHub repository</a>.
</div>

## Getting started

RudderStack supports sending events to Accoil via the following <Link to="/destinations/rudderstack-connection-modes/">connection modes</Link>:

| **Connection Mode** | **Web** | **Mobile** | **Server** |
| :------------------ | :------------ | :------------ | :------------ |
| **Cloud mode** | **Supported** | **Supported** | **Supported** |


Once you have confirmed that the source platform supports sending events to Accoil, follow these steps:

1. From your [RudderStack dashboard](https://app.rudderstack.com/), add the source. Then, from the list of destinations, select **Accoil Analytics**.
2. Assign a name to your destination and click **Continue**.

### Connection settings

To successfully set up Accoil as a destination, you need to configure the following settings:

- **API Key**: Navigate to your Accoil dashboard and find your API Key under **General Account Settings**. Copy this API Key and paste it here.

## Identify

Identify calls recognize individual users and their attributes.

Example Call:
```javascript
analytics.identify('userId123', {
email: '[email protected]',
name: 'John Doe',
createdAt: '2023-05-12T08:00:00Z' // ISO 8601 or Unix timestamp format
});
```

### Supported mappings

| **RudderStack property** | **Accoil property** | **Note** |
| :----------------------- | :------------------ | :------- |
| `userId` <br/> `traits.userId` <br/> `traits.id` <br/> `context.traits.userId` <br/> `context.traits.id` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | tracking_id | |
| `traits` <br/> `context.traits` | Passed through as is to Accoil | See traits mapping for details |
| `timestamp` <br/> `originalTimestamp` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | timestamp | ISO 8601 format datetime or unix timestamp |

#### Traits mapping

| **RudderStack trait** | **Note** |
| :-------------------- | :------- |
| `email` | Email addresses are highly recommended as they are often used to identify users across multiple platforms. (Highly Recommended) |
| `name` | Providing a name helps display users in Accoil. If no name is provided, the email address is displayed instead. (Highly Recommended) |
| `role` | Describes the user’s role in your product such as Admin, Owner, Team Member. (Suggested) |
| `accountStatus` | Capturing the account status on the user can be helpful to segment users. Possible options include: Free, Trial, Paid, Cancelled. (Suggested) |
| `createdAt` | When was the user created, including this ensures that tenure tracking is accurate. (Highly Recommended) |

## Group

Group calls link users to accounts and records account-level attributes.

Example Call:
```javascript
analytics.group('accountId123', {
name: 'Example Company',
createdAt: '2021-03-15T09:00:00Z', // ISO 8601 or Unix timestamp format
mrr: 3000,
status: 'active'
});
```

### Supported mappings

| **RudderStack property** | **Accoil property** | **Note** |
| :----------------------- | :------------------ | :------- |
| `userId` <br/> `traits.userId` <br/> `traits.id` <br/> `context.traits.userId` <br/> `context.traits.id` <br/> | tracking_id | |
| `groupId` <span style="color: #4D4DFF;font-size:12px;">Required</span> | tracking_id | |
| `traits` <br/> `context.traits` | Passed through as is to Accoil | See traits mapping for details |
| `timestamp` <br/> `originalTimestamp` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | timestamp | ISO 8601 format datetime or unix timestamp |

#### Traits mapping

| **RudderStack trait** | **Note** |
| :-------------------- | :------- |
| `name` | The name of the account. Without providing a name, accounts are displayed using a numeric ID, making them harder to identify. (Highly Recommended) |
| `createdAt` | Helps calculate account tenure. If no createdAt is provided, the earliest createdAt from the associated users will be used. (Highly Recommended) |
| `status` | The overall status of your the account subscription. Possible options include: Free, Trial, Paid, Cancelled (Highly Recommended) |
| `plan` | The plan type helps in segmenting accounts by their subscription tier (e.g., starter, pro, enterprise). (Recommended) |
| `mrr` | Monthly recurring revenue (MRR) is important for segmenting accounts by value. It also allows Accoil to show the dollar value of different segments. Ideally this is passed in cents eg $99 becomes 9900. (Highly Recommended) |

## Track

Track calls record specific user actions, like "Login" or "Purchase".

Use the "Noun_Verb" format to name your events, for example, `Report Created` or `Purchase Completed`.

Example Call:
```javascript
analytics.track('Purchase Completed', {
item: 'Book',
price: 25.00
});
```

### Supported mappings

| **RudderStack property** | **Accoil property** | **Note** |
| :----------------------- | :------------------ | :------- |
| `userId` <br/> `traits.userId` <br/> `traits.id` <br/> `context.traits.userId` <br/> `context.traits.id` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | tracking_id | |
| `event` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | Event name | |
| `timestamp` <br/> `originalTimestamp` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | timestamp | ISO 8601 format datetime or unix timestamp |

## Page and screen

Page and Screen calls convert navigation calls into Track events to monitor user interactions within your product.

Example Calls:
```javascript
analytics.page('Home Page');
analytics.screen('Dashboard');
```

### Supported mappings

| **RudderStack property** | **Accoil property** | **Note** |
| :----------------------- | :------------------ | :------- |
| `userId` <br/> `traits.userId` <br/> `traits.id` <br/> `context.traits.userId` <br/> `context.traits.id` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | tracking_id | |
| `name` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | Page or screen name | |
| `timestamp` <br/> `originalTimestamp` <br/> <span style="color: #4D4DFF;font-size:12px;">Required</span> | timestamp | ISO 8601 format datetime or unix timestamp |

## Key Notes

- **Created At Date**: Ensure the `createdAt` field for users and accounts is in ISO 8601 or Unix timestamp format for accurate tenure tracking.
- **Trait Handling**: Accoil stores traits sent with Identify and Group calls, but traits passed with Track calls are not stored. Only event names and counts are recorded.
- **Event Aggregation**: Accoil simplifies event tracking by aggregating daily event counts.
- **Page and Screen Calls**: These calls are automatically converted into Track events for easier monitoring of user navigation.

This integration empowers your team to make data-driven decisions, improving your product and customer experiences. For further assistance, please [contact the Accoil support team](https://help.accoil.com).