Skip to content

docs(sdk): add data inventory and proposed privacy label mappings - #821

Closed
unjica wants to merge 2 commits into
developfrom
codex/o20-sdk-privacy-docs
Closed

unjica wants to merge 2 commits into
developfrom
codex/o20-sdk-privacy-docs

Conversation

@unjica

@unjica unjica commented Oct 19, 2026

Copy link
Copy Markdown
Collaborator

Change

Add /docs/sdk-privacy with a browser/core, Next.js and React Native payload inventory, storage/identity behavior, IP/logging caveats, and honest client/server scrubbing limits. Add proposed Apple App Privacy and Google Play Data safety tables, with app-specific classification caveats and deletion/retention explicitly UNVERIFIED. Link from SDK navigation and SDK/Next.js/React Native docs.

Docs only; no SDK/API behavior changes. Keep this PR draft pending Sanja’s claim review. Do not merge, release or deploy.

Related: #470 (scrubbing shipped), #476 (custom regex remains open). No issues created.

Official guidance checked 19 October 2026:

Validation

  • pnpm install --frozen-lockfile: passed; no lockfile changes.
  • pnpm --filter dashboard lint: passed, no errors/warnings (also run by final build).
  • pnpm --filter dashboard test: 60 files, 354 tests passed, 0 failed.
  • pnpm --filter dashboard build: passed; 60/60 static pages generated, including /docs/sdk-privacy. Repeated after final text edits, passed again. Existing Sentry instrumentation advisory remains.
  • pnpm --filter dashboard exec tsc --noEmit: fails with 6 existing errors in unchanged test files: four TS2540 readonly NODE_ENV assignments in lib/google-analytics.test.ts:22,30,37,46; two TS1501 regex target errors in lib/marketing-seo-head.test.ts:13,14. Both files are byte-for-byte unchanged against origin/develop; no docs errors reported. Next build’s configured type validation passes.
  • Built HTML checked: 3 captioned tables, one h1, required caveats and all 3 integration-page cross-links present. No browser screenshot QA performed.
  • git diff --check: passed. Reviewed all modified files and full new page against verified SDK/API code.

Full privacy-claim checklist

  • JSON ingest endpoints and envelope: packages/telemetry-core/src/index.ts:185, packages/telemetry-core/src/index.ts:460, packages/telemetry-core/src/index.ts:500.
  • Content-Type and optional Bearer authorization; configurable URL without HTTPS enforcement: packages/telemetry-core/src/index.ts:160, packages/telemetry-core/src/index.ts:442.
  • No explicit cookie capture or credential override in these requests; runtime/origin caveat retained: packages/telemetry-core/src/index.ts:188, packages/telemetry-core/src/index.ts:463, packages/telemetry-core/src/index.ts:514.
  • Error message, stack, context and optional user/session IDs: packages/telemetry-core/src/index.ts:607, packages/telemetry-core/src/index.ts:626.
  • Browser automatic error sources and filename/line/column fields: packages/telemetry-core/src/index.ts:313, packages/telemetry-core/src/index.ts:350.
  • Sanitized script error diagnostic fields: packages/telemetry-core/src/sanitized-script-error.ts:98.
  • Full session payload, including timestamps and optional identity: packages/telemetry-core/src/index.ts:165.
  • Browser/OS family hints from UA; raw UA is not a session field: packages/telemetry-core/src/device-context.ts:9, packages/telemetry-core/src/device-context.ts:42, packages/telemetry-core/src/index.ts:165.
  • Country is best-effort Intl locale region, not measured GPS/IP location: packages/telemetry-core/src/device-context.ts:27.
  • Event/batch fields and manual screen name property: packages/telemetry-core/src/index.ts:500, packages/telemetry-core/src/index.ts:554, packages/telemetry-core/src/index.ts:648.
  • Web Vitals default on and can be disabled: packages/telemetry-core/src/index.ts:388.
  • Web Vitals metric/value/rating/path/id/navigation/connection fields; pathname excludes query/hash: packages/telemetry-core/src/web-vitals.ts:37, packages/telemetry-core/src/web-vitals.ts:49.
  • Browser-only metric listener guard and LCP/INP/CLS/TTFB registration: packages/telemetry-core/src/web-vitals.ts:80.
  • Next provider delegates to core; route hooks send supplied pathname; boundary context: packages/telemetry-next/src/index.tsx:20, packages/telemetry-next/src/index.tsx:49, packages/telemetry-next/src/index.tsx:68, packages/telemetry-next/src/index.tsx:96.
  • Default capture has no replay, breadcrumbs, GPS, contacts, photos, clipboard or full incoming HTTP body/header capture; scoped to reviewed capture code, not arbitrary app context: packages/telemetry-core/src/index.ts:165, packages/telemetry-core/src/index.ts:304, packages/telemetry-core/src/index.ts:500, packages/telemetry-core/src/index.ts:626, packages/telemetry-next/src/server.ts:215, packages/telemetry-react-native/src/index.ts:34.
  • Next server helper full envelope and route/runtime context: packages/telemetry-next/src/server.ts:215.
  • Next helper strips request path query/hash, ignores incoming headers, but does not sanitize every report string: packages/telemetry-next/src/server.ts:137, packages/telemetry-next/src/server.ts:215, packages/telemetry-next/src/server.ts:256.
  • RN core initialization, default platform, ErrorUtils source/isFatal, JavaScript-only handler: packages/telemetry-react-native/src/index.ts:34.
  • RN adds no native module or OS permissions; no model/manufacturer/native crash fields: packages/telemetry-react-native/src/index.ts:1, packages/telemetry-react-native/package.json:18 (exports/files/dependencies), package tree inspected with rg --files packages/telemetry-react-native.
  • Anonymous UUID-form identifier; Web Crypto preference and fallback: packages/telemetry-core/src/index.ts:58, packages/telemetry-core/src/index.ts:66.
  • localStorage key and in-memory fallback, including RN without storage: packages/telemetry-core/src/index.ts:47, packages/telemetry-core/src/index.ts:86.
  • New session identifier on start/init and browser lifecycle restart: packages/telemetry-core/src/index.ts:223, packages/telemetry-core/src/index.ts:254, packages/telemetry-core/src/index.ts:368.
  • identify/email optional and app-supplied; explicit email clearing required: packages/telemetry-core/src/index.ts:136, packages/telemetry-core/src/index.ts:420.
  • No dedicated SDK IP payload field: packages/telemetry-core/src/index.ts:165, packages/telemetry-core/src/index.ts:460, packages/telemetry-core/src/index.ts:500, packages/telemetry-next/src/server.ts:215.
  • API client IP resolution and ingest rate limiting: apps/api/src/lib/client-ip.ts:64, apps/api/src/lib/client-ip.ts:88, apps/api/src/app.ts:103.
  • No IP columns on Event/ErrorOccurrence/Session; no broad log-storage guarantee: apps/api/prisma/schema.prisma:575, apps/api/prisma/schema.prisma:627, apps/api/prisma/schema.prisma:651.
  • Optional IP diagnostic logging can record IPs: apps/api/src/lib/client-ip.ts:100.
  • Server scrub default on; env false/0/off/no disables: apps/api/src/lib/ingest-pii-scrub.ts:20.
  • Server scrub covers error message/stack/context and event properties before writes: apps/api/src/lib/ingest-pii-scrub.ts:58, apps/api/src/lib/ingest-pii-scrub.ts:78, apps/api/src/routes/ingest.ts:159, apps/api/src/routes/ingest.ts:267, apps/api/src/routes/ingest.ts:297.
  • Best-effort server patterns/keys and additive deny-keys, not complete removal: apps/api/src/lib/pii-scrub.ts:24, apps/api/src/lib/pii-scrub.ts:71, apps/api/src/lib/pii-scrub.ts:116.
  • Client scrub opt-in, default off; limited to event properties and error text/context: packages/telemetry-core/src/index.ts:530, packages/telemetry-core/src/index.ts:544, packages/telemetry-core/src/index.ts:614.
  • Client sensitive named URL params only, not all query strings: packages/telemetry-core/src/pii-scrub.ts:25, packages/telemetry-core/src/pii-scrub.ts:76.
  • Default identity fields untouched; session email scrub separately opt-in and requires enabled server scrub: apps/api/src/lib/project-pii-scrub-settings.ts:20, apps/api/src/lib/ingest-pii-scrub.ts:98, packages/telemetry-core/src/index.ts:165.
  • Store mappings are proposals tied to the verified fields above, not guaranteed answers; linked identity/tracking, purposes, sharing and locale-location categorization remain app-specific: apps/dashboard/app/docs/sdk-privacy/page.tsx:64 (Apple section), apps/dashboard/app/docs/sdk-privacy/page.tsx:76 (Google section); official definitions linked on page.
  • Encryption conditional on deployment, deletion/retention explicitly UNVERIFIED; no compliance or processing-region guarantee: packages/telemetry-core/src/index.ts:160, apps/dashboard/app/docs/sdk-privacy/page.tsx:76 (Google section). Code inventory cannot verify customer policies, contracts or downstream use.

unjica and others added 2 commits October 19, 2026 09:34
Add a code-verified browser and React Native data inventory, identifiers,
scrubbing caveats, and proposed Apple/Google disclosure mappings.
Link the guide from SDK navigation and integration docs.
Keep O20 sdk-privacy link and O22 numbered Next.js headings.
@unjica

unjica commented Oct 19, 2026

Copy link
Copy Markdown
Collaborator Author

Superseded by merged #816 (docs/o20-sdk-privacy on develop). Closing duplicate draft from codex/o20-sdk-privacy-docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant