Getting Started with Accoil
Read below for an overview of the Accoil API and tracking script.
Welcome to Accoil! This guide will help you get started with the Accoil API and JavaScript tracking library, enabling you to seamlessly send product engagement data to your Accoil account. Whether you’re identifying users, organizing accounts, or tracking user actions, this documentation will guide you every step of the way.
Overview
The Accoil JavaScript tracking library and REST API allow you to:
- Identify and manage users and their traits.
- Group users into accounts and assign account traits.
- Track events that capture user actions within your product.
By integrating Accoil into your app, you can gain actionable insights into user behavior and product performance to drive engagement, retention, and growth.
Prerequisite: API key
In order to use this API, you must have an active Accoil account and custom API key.
The API Key can be found under Account > General. The API key is specific to each product in Accoil.
Want to learn more about product data analytics?
Sign up for the Product Data Masterclass to gain the skills you need for data-driven decision-making. Led by Derek Skaletsky, a seasoned expert with years of experience, this no-nonsense course is designed to hone your skills quickly.
The Three Main Calls
Accoil’s API and tracking library are built around three core calls:
1. Identify Call
The .identify
call is used to identify individual users and assign traits to them. This is essential for linking actions to specific users and building detailed user profiles.
- Example use case: Capture a user’s email, subscription status, or signup date.
- When to use:
- When a user signs up.
- When a user logs in.
- When updating user traits (e.g., a change in subscription level).
2. Group Call
The .group
call is used to associate users with specific accounts (e.g., companies, teams, or organizations). It’s also used to assign traits at the account level.
- Example use case: Capture the name, plan, or industry of an account.
- When to use:
- When a user joins or is linked to an account.
- When updating account details (e.g., upgrading to an enterprise plan).
3. Track Call
The .track
call is used to capture specific user actions (also referred to as events) that occur in your app. Events give you detailed insights into how users are interacting with your product.
- Example use case: Log when a user creates a report, completes a purchase, or views a feature.
- When to use:
- Every time a meaningful user action occurs (e.g., clicking a button, completing a workflow).
- To monitor key events that align with your business goals, like sign-ups or purchases.
Putting It All Together
Here’s a quick overview of how these calls work together in your tracking setup:
- Use the Identify Call to create or update user profiles.
- Use the Group Call to associate users with accounts and define account-level traits.
- Use the Track Call to log user actions and events.
With these three calls, you’ll have everything you need to start capturing valuable insights about your product’s users and accounts.
Updated 25 days ago
Now that you’ve got a basic understanding of Accoil’s tracking framework, dive deeper into how to use the JS Tracking library to make these calls or explore the specific of the API to under what's possible to send to Accoil.