Skip to Content
JourneyKit

Quickstart

Let your coding agent do it

The Get started page in the dashboard installs the JourneyKit plugin in Claude Code, Codex or Cursor. Your agent reads your codebase, defines your fields and events, adds the tracking code, and creates branded emails and workflows. The steps below are the manual route.

1. Create API keys

Settings → API keys. Create one of each:

  • Public key (jk_pub_…), for the browser SDK. Safe to ship to contacts: it can only track and identify, and cannot backdate events.
  • Secret key (jk_live_…), for your backend. Can do everything, including setting timestamp to backfill history.

Keys are shown once. Revoking a key takes effect immediately.

2. Install the browser SDK

<script src="https://journeykit.io/sdk.js"></script>
<script>
  JourneyKit.init({ key: "jk_pub_…" });

  // After login, once you know who this is:
  JourneyKit.identify("user-123", {
    email: "ada@example.com",
    name: "Ada Lovelace",
    firstName: "Ada",
    plan: "trial",
  });

  // Whenever something meaningful happens:
  JourneyKit.track("project_created", { template: "blank" });
</script>

identify must be called before track, events are always attached to a contact. See the SDK reference.

3. Send server-side events

Payments, renewals, cancellations, things the browser can't see, come from your backend with the secret key:

curl -X POST https://journeykit.io/api/ingest/track \
  -H "Authorization: Bearer jk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "contactId": "user-123", "event": "subscription_started", "properties": { "plan": "pro" } }'

Batch up to 500 with { "events": [ … ] }. Full details in the track reference.

4. Build a workflow

Workflows → New workflow. For example, an activation nudge:

  • When a contact performs account_created
  • Then: wait 24 hours → only continue if the contact has not performed project_created → send email (pick a preset, bind {{firstName}} to the contact field properties.firstName)
  • Measure: goal event project_created within 168 hours, holdout 10%

Create it, then flip Enabled. From now on every account_created event enters that contact into the workflow once. See Workflows for how steps, bindings and measurement work.

On this page