Skip to content

Getting started

Sentori is an error-tracking + APM platform. There’s a 5-minute quickstart for each supported stack — pick yours:

StackQuickstart
React (Vite / CRA / any bundler)getting-started/react
React Native (bare or Expo)getting-started/react-native
Next.js (App Router or Pages)getting-started/nextjs
Node.js / Bun (Express, Hono, Fastify, scripts)getting-started/node

All four assume you already have:

  • a token (st_pk_...)
  • an ingest URL

For SaaS: sign up at https://sentori.golia.jp and copy from project settings. For self-hosted: see Self-hosting.

Don’t have a backend yet?

If you’re prototyping or writing your own client, you can POST directly to the ingest endpoint:

Terminal window
curl -X POST "$SENTORI_INGEST_URL/v1/events" \
-H "Authorization: Bearer $SENTORI_TOKEN" \
-H "Sentori-Sdk: curl/0.0.0" \
-H "Content-Type: application/json" \
-d '{
"id": "01000000-0000-7000-8000-000000000001",
"timestamp": "'"$(date -u +%FT%T.000Z)"'",
"kind": "error",
"platform": "javascript",
"release": "myapp@0.1.0+1",
"environment": "dev",
"device": {"os": "other", "osVersion": "0"},
"app": {"version": "0.1.0"},
"error": {
"type": "TypeError",
"message": "hello sentori",
"stack": [{"file": "shell.ts", "line": 1, "inApp": true}]
}
}'

See the Protocol reference for the full schema.

Add one line to your CI right after the build is uploaded:

Terminal window
curl -fsS -X POST "$SENTORI_INGEST_URL/v1/deploys" \
-H "Authorization: Bearer $SENTORI_TOKEN" \
-H "Content-Type: application/json" \
-d "{\"release\":\"myapp@$VERSION+$BUILD\",\"environment\":\"prod\"}"

Idempotent — re-running the same release just refreshes deployAt, so flaky-CI retry is safe.

Terminal window
# Latest 20 active issues — one line per issue.
npx @goliapkg/sentori-cli issue list \
--project "$PROJECT_ID" --status active --limit 20
# Mark resolved, tagging the fix release. The dashboard's regression
# detector flips it back to `regressed` if a matching event lands later.
npx @goliapkg/sentori-cli issue resolve <issue-uuid> \
--project "$PROJECT_ID" \
--in-release "myapp@1.2.4+457"
# Silence a known-noisy issue.
npx @goliapkg/sentori-cli issue silence <issue-uuid> \
--project "$PROJECT_ID"

The admin token (SENTORI_ADMIN_TOKEN, sk_ prefix) is in project settings → tokens.

So a stack trace points at src/Foo.tsx:42, not index.bundle:1:288432. After a release build, upload the source map tagged to the release — byte-for-byte the same string you pass to init({ release }):

Terminal window
npx @goliapkg/sentori-cli@latest upload sourcemap \
--release "myapp@$VERSION+$BUILD" --token "$SENTORI_TOKEN" \
dist/assets/ # a build dir, or specific .map / .js files

The server symbolicates matching events at ingest and groups the issue on the original-source frame. React Native (Hermes) needs the Metro and Hermes maps composed first — see Source map upload for the per-platform steps and CI recipes (GitHub Actions / GitLab / Vercel / EAS).

All optional. Existing v1.x code keeps working. Pick what’s useful.

If your users are in multiple projects within one org, Sentori can join their events across projects — without ever storing raw email / phone / OAuth sub:

sentori.setUser({
id: 'usr_internal_123',
name: 'Lihao',
linkBy: { // SDK hashes client-side
email: 'lihao@example.com',
googleSub: '108293…',
},
})

In the dashboard, the Users page lets an operator paste a real email, browser-side hashes it, and the URL/query only ever carries the hash. See Privacy & identity.

Sentori is silent on the host’s console by default. To know when it’s live, wire onReady:

sentori.init({
token, release,
onReady: (info) => {
// info.sdkVersion / info.coldStartMs / info.native.bound
console.log('sentori live', info)
},
})

For host-side log routing (Datadog / OpenTelemetry / etc.):

import { setLogTransport } from '@goliapkg/sentori-react-native'
setLogTransport((level, tag, args) => {
myLogger.log({ source: `sentori/${tag}`, level, args })
})

captureMessage, startTrace, startSpan / withScopedSpan, startMoment, recordMetric, track, addBreadcrumb. See the recipes directory:

If your codebase or LLM uses @sentry/react-native:

import * as Sentry from '@goliapkg/sentori-react-native/compat'
Sentry.init({ dsn: 'https://st_pk_…@ingest.sentori.golia.jp/proj' })
Sentry.captureException(err)
Sentry.setUser({ id, email })
// email → linkBy.email (hashed); ip_address dropped + hint

See Sentry compat.