AccoilAccoil Developer Docs
Concepts

Track Call

The track call records user actions in Accoil. Only the event name is accepted -- no properties. Use Object_Verb naming in Title_Case.

The track call records that a user performed a specific action. These events form the foundation of engagement scoring and feature adoption analysis in Accoil.

Event name only -- no properties

Accoil accepts only the event name in a track call. Event properties (metadata, dimensions, custom fields) are not accepted and will be ignored. If you need to associate contextual data with a user or account, use identify or group traits instead.

When to fire a track call

Fire a track call whenever a user performs a meaningful action in your product:

  • Creating, editing, or deleting core objects (reports, projects, tasks)
  • Completing key workflows (onboarding, setup, export)
  • Account-level actions (inviting a team member, upgrading a plan)
  • Feature engagement (using a specific tool or integration)

Do not track low-value interactions like page views, hovers, or scroll events. Focus on actions that signal real product engagement.

Required fields

FieldTypeDescription
userIdstringThe unique identifier of the user who performed the action.
eventstringThe name of the event. Use Object_Verb format in Title_Case.
timestampstring (ISO 8601)When the event occurred. Defaults to current UTC time if omitted.

Naming convention: Object_Verb in Title_Case

Consistent event naming is critical. Accoil recommends the Object_Verb format with Title_Case and underscore separators.

The pattern is: what was acted on + what happened to it.

PatternExampleDescription
Object_VerbReport_CreatedA report was created
Object_VerbTeam_Member_InvitedA team member was invited
Object_VerbAccount_UpgradedAn account was upgraded

Rules

  • Title_Case with underscores: Report_Created, not report_created or reportCreated
  • Past tense verbs: Created, Deleted, Updated, not Create, Delete, Update
  • No dynamic values: Report_Created, not Report_Created_2025 or Report_Created_Weekly
  • No properties in the name: Report_Exported, not Report_Exported_PDF

Common events

EventDescription
Account_CreatedA new account was created
User_Signed_UpA new user registered
User_Logged_InA user started a session
Report_CreatedA user created a report
Report_ExportedA user exported a report
Team_Member_InvitedA user invited someone to the account
Account_UpgradedAn account upgraded its plan
Account_DowngradedAn account downgraded its plan
Account_CanceledAn account was canceled
Integration_ConnectedA user connected an external integration
Project_CreatedA user created a new project
Dashboard_ViewedA user viewed a dashboard

Example payload

{
  "userId": "user_12345",
  "event": "Report_Created",
  "timestamp": "2025-01-28T12:00:00Z"
}

cURL example (v2)

curl -X POST https://in.accoil.com/v2/track \
  -H "Content-Type: application/json" \
  -H "Authorization: Basic YOUR_API_KEY" \
  -d '{
    "userId": "user_12345",
    "event": "Report_Created",
    "timestamp": "2025-01-28T12:00:00Z"
  }'

The API returns 202 Accepted. Processing happens asynchronously.

Best practices

  1. Send identify and group first. Ensure the user and account exist in Accoil before recording events. Events against unknown users are still accepted but cannot be fully attributed until an identify call arrives.
  2. Be selective. Track 10-30 meaningful events, not hundreds. Focus on actions that correlate with product value and engagement.
  3. Use consistent naming. Agree on naming conventions with your team before instrumenting. Inconsistent names (e.g., Report_Created vs Created_Report vs report.created) fragment your data.
  4. Avoid encoding data in event names. Since properties are not supported, it may be tempting to create events like Report_Created_PDF or Report_Created_CSV. Resist this -- it creates event sprawl. Use a single Report_Exported event instead.
  5. Document your events. Maintain a shared event dictionary that lists every event name, what triggers it, and who owns the instrumentation.

On this page