Skip to main content

Server SDKs

The server SDKs send events from your backend to Hober — the server-side counterpart of the client SDKs' track(). Events drive segments, journey triggers, and in-app display rules; see Server-Side Event Tracking for the full API semantics.

Four languages, one behavior contract (every SDK passes the same conformance suite):

  • Go — Go 1.22+, standard library only
  • Node.js — Node ≥ 18, zero runtime dependencies
  • Python — Python ≥ 3.9, standard library only
  • Java — Java 11+ HttpClient, zero runtime dependencies; usable from Kotlin and Scala

Availability: the packages (npm, PyPI, Maven Central, Go module) publish with Hober's public launch. The API documented here is final and conformance-tested — contact us if you want early access before the registries go live.

What every SDK does​

  • track(event) — queue a named event with an externalId (your user ID) and properties. Hober's registry resolves the externalId to a subscriber.
  • identify(anonymousId, subscriberId) — merge pre-signup activity into a subscriber.
  • Batching — events queue in memory and ship in batches of 100 or every 5 seconds (both configurable); flush()/close() drain synchronously. The queue holds 10k events, then track fails fast rather than blocking or growing unbounded.
  • Retries — 429 (honoring Retry-After) and 5xx retry with exponential backoff and jitter, 4 retries by default. Other 4xx are permanent and surface through the error callback; by default they are dropped silently — tracking never takes your process down.
  • Idempotency — every event gets a UUIDv7 idempotency key unless you supply one. Pass your own (outbox row ID, order ID) to make cross-process retries safe.

Authentication​

Server SDKs authenticate with a server key (hober_srv_…), created in the dashboard under Settings → Server Keys. It is a secret — unlike the publishable client SDK key — so keep it in your environment, not your codebase.

Identity tokens​

When your workspace uses identity verification, your backend signs each user's externalId with your workspace's identity secret and hands the token to your app with the user's session. The app passes it to the client SDK's identifySubscriber. Keep the identity secret on your server, like the server key.

SDKCall
Gohober.IdentityToken(identitySecret, user.ID)
NodeidentityToken(identitySecret, user.id)
Pythonidentity_token(identity_secret, user.id)
JavaIdentityToken.of(identitySecret, user.getId())

Each returns hex(HMAC-SHA256(identity_secret, externalId)), with both strings encoded as UTF-8.

Looking to send notifications from your backend? Use the REST API — the server SDKs are focused on event ingestion.