mirror of
https://github.com/hanzoai/agency.git
synced 2026-11-02 19:13:28 +00:00
61 lines
2.0 KiB
Plaintext
61 lines
2.0 KiB
Plaintext
// @hanzo/event — framework-agnostic entry. The ONE telemetry client.
|
|
//
|
|
// import { createAnalytics, EVENTS } from '@hanzo/event'
|
|
// const a = createAnalytics({ product: 'console' }) // same-origin, cookie auth
|
|
// a.pageview(); a.capture(EVENTS.SIGNUP_COMPLETED)
|
|
// a.captureError(err) // errors are events too — one stream
|
|
//
|
|
// React apps use the './react' entry for the provider + hooks + error boundary.
|
|
|
|
export {
|
|
Analytics,
|
|
createAnalytics,
|
|
resetClients,
|
|
VERSION,
|
|
getCohort,
|
|
getFirstTouch,
|
|
} from './core'
|
|
export { parseDsn, buildSentryEvent, buildEnvelope, framesFromStack } from './sentry'
|
|
export { uuidv7, uuidv7Time } from './uid'
|
|
export { PRODUCT_PROJECT, dsnForProduct } from './dsn'
|
|
export type { ErrorIdentity } from './sentry'
|
|
export { scrubText, redactSecrets, scrubPII } from './scrub'
|
|
export { EVENTS, EXCEPTION, PAGEVIEW } from './events'
|
|
export { exceptionEntry, exceptionProperties, fingerprint, digest } from './exception'
|
|
export type { EventName } from './events'
|
|
export { GOALS, COHORTS } from './goals'
|
|
export type { GoalDef, CohortDef } from './goals'
|
|
export { FUNNELS, PRODUCTS, eventsOf } from './funnels'
|
|
export type { FunnelDef, FunnelStep, FunnelId, ProductId } from './funnels'
|
|
export {
|
|
parseAttribution,
|
|
deriveChannel,
|
|
hasAttribution,
|
|
hostOf,
|
|
isoWeek,
|
|
} from './attribution'
|
|
export type {
|
|
AnalyticsConfig,
|
|
Attribution,
|
|
CaptureErrorOptions,
|
|
Cohort,
|
|
Dsn,
|
|
EventKind,
|
|
Exception,
|
|
ExceptionEntry,
|
|
ExceptionFrame,
|
|
ExceptionProperties,
|
|
SentryEvent,
|
|
SentryFrame,
|
|
SentryLevel,
|
|
Transport,
|
|
WireEvent,
|
|
} from './types'
|
|
|
|
/** Which org owns a host's telemetry — the resolution that lets a surface report
|
|
* correctly while configuring nothing. `keyFor` takes an optional keyring so a
|
|
* runtime that receives one (hanzo.id serves every brand from one image) resolves
|
|
* through this same function rather than a second copy of it. */
|
|
export { ORG_DOMAIN, ORG_KEY, orgOf, keyFor, keyForPage } from './org'
|
|
export type { Keyring } from './org'
|