@warpgogol/werkstatt-shared 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +352 -0
- package/src/checks/index.ts +24 -0
- package/src/checks/lib/astro-site-url.ts +30 -0
- package/src/checks/lib/i18n.ts +30 -0
- package/src/checks/result-helpers.ts +102 -0
- package/src/checks/suppressions-config.ts +195 -0
- package/src/index.ts +14 -0
- package/src/integration/README.md +38 -0
- package/src/integration/adapters.ts +143 -0
- package/src/integration/crm-buffer.ts +491 -0
- package/src/integration/dispatch.ts +106 -0
- package/src/integration/funnel.ts +379 -0
- package/src/integration/index.ts +56 -0
- package/src/integration/lifecycle.ts +155 -0
- package/src/integration/orchestration.ts +439 -0
- package/src/integration/port-barrel.ts +124 -0
- package/src/integration/port.ts +143 -0
- package/src/integration/qstash.ts +134 -0
- package/src/integration/sharding.ts +133 -0
- package/src/integration/tests/deliver-event.test.ts +52 -0
- package/src/integration/tests/dispatch.test.ts +88 -0
- package/src/integration/tests/funnel-bridge.test.ts +46 -0
- package/src/integration/tests/hub-runtime.test.ts +128 -0
- package/src/integration/tests/lifecycle.test.ts +69 -0
- package/src/integration/tests/qstash.test.ts +83 -0
- package/src/integration/tests/sharding.test.ts +64 -0
- package/src/integration/vitest.config.ts +8 -0
- package/src/integration-adapter-supabase-crm/adapter.ts +437 -0
- package/src/integration-adapter-supabase-crm/client.ts +605 -0
- package/src/integration-adapter-supabase-crm/index.ts +28 -0
- package/src/integration-adapter-supabase-crm/pipedrive-sync-target.ts +482 -0
- package/src/integration-adapter-supabase-crm/supabase-rest.ts +89 -0
- package/src/integration-adapter-supabase-crm/tenant-registry.ts +334 -0
- package/src/integration-adapter-supabase-crm/tests/change-balance.pbt.test.ts +83 -0
- package/src/integration-adapter-supabase-crm/tests/funnel-persistence.test.ts +409 -0
- package/src/integration-adapter-supabase-crm/tests/lifecycle-sync.test.ts +288 -0
- package/src/integration-adapter-supabase-crm/tests/stage-map.test.ts +80 -0
- package/src/integration-adapter-supabase-crm/vitest.config.ts +8 -0
- package/src/integration-adapter-supabase-crm/worker.ts +223 -0
- package/src/observability/conventions.ts +93 -0
- package/src/observability/env-resolver.ts +57 -0
- package/src/observability/index.ts +57 -0
- package/src/observability/metric-registry.ts +184 -0
- package/src/observability/otlp-converter.ts +125 -0
- package/src/observability/otlp-json.ts +135 -0
- package/src/observability/otlp-transport.ts +68 -0
- package/src/observability/pusher.ts +142 -0
- package/src/observability/redact.ts +27 -0
- package/src/observability/tests/conventions.test.ts +100 -0
- package/src/observability/tests/metric-registry.test.ts +117 -0
- package/src/observability/tests/otlp-converter.pbt.test.ts +77 -0
- package/src/observability/tests/otlp-converter.test.ts +157 -0
- package/src/observability/tests/otlp-json.test.ts +120 -0
- package/src/observability/tests/pusher.test.ts +75 -0
- package/src/observability/tests/redact.pbt.test.ts +71 -0
- package/src/observability/tests/redact.test.ts +37 -0
- package/src/observability/typed-refs.ts +137 -0
- package/src/observability/vitest.config.ts +8 -0
- package/src/ontology/analytics/matomo-binding.yaml +172 -0
- package/src/ontology/analytics/matomo-fleet.registry.yaml +26 -0
- package/src/ontology/analytics/messkanon.yaml +151 -0
- package/src/ontology/archetype-registry.ts +61 -0
- package/src/ontology/archetypes/components/brand-label.yaml +19 -0
- package/src/ontology/archetypes/components/copyright.yaml +19 -0
- package/src/ontology/archetypes/components/currency-aware-price-display.yaml +19 -0
- package/src/ontology/archetypes/components/currency-selector.yaml +19 -0
- package/src/ontology/archetypes/components/footer-promo.yaml +19 -0
- package/src/ontology/archetypes/components/lang-switcher.yaml +19 -0
- package/src/ontology/archetypes/components/layout.yaml +19 -0
- package/src/ontology/archetypes/components/live-photo.yaml +20 -0
- package/src/ontology/archetypes/components/material-credit.yaml +20 -0
- package/src/ontology/archetypes/components/media.yaml +21 -0
- package/src/ontology/archetypes/components/nachweis-card.yaml +34 -0
- package/src/ontology/archetypes/components/nachweis-detail.yaml +43 -0
- package/src/ontology/archetypes/components/nachweis-list.yaml +37 -0
- package/src/ontology/archetypes/components/nachweis-verify.yaml +31 -0
- package/src/ontology/archetypes/components/not-found.yaml +22 -0
- package/src/ontology/archetypes/components/offer-capacity.yaml +21 -0
- package/src/ontology/archetypes/components/passport-header.yaml +19 -0
- package/src/ontology/archetypes/components/passport-provenance.yaml +20 -0
- package/src/ontology/archetypes/components/passport-score-grid.yaml +20 -0
- package/src/ontology/archetypes/components/passport-star-map.yaml +20 -0
- package/src/ontology/archetypes/components/person-profile.yaml +20 -0
- package/src/ontology/archetypes/components/pulsar.yaml +20 -0
- package/src/ontology/archetypes/components/responsive-image.yaml +19 -0
- package/src/ontology/archetypes/components/scroll-to-top.yaml +22 -0
- package/src/ontology/archetypes/components/social-meta.yaml +20 -0
- package/src/ontology/archetypes/components/structured-data.yaml +19 -0
- package/src/ontology/archetypes/index.json +1003 -0
- package/src/ontology/archetypes/index.yaml +821 -0
- package/src/ontology/archetypes/sections/approach.yaml +23 -0
- package/src/ontology/archetypes/sections/article-list.yaml +30 -0
- package/src/ontology/archetypes/sections/audience-cards.yaml +30 -0
- package/src/ontology/archetypes/sections/breadcrumbs.yaml +21 -0
- package/src/ontology/archetypes/sections/chat-widget.yaml +37 -0
- package/src/ontology/archetypes/sections/comparison-cards.yaml +31 -0
- package/src/ontology/archetypes/sections/controlled-responsibility-block.yaml +34 -0
- package/src/ontology/archetypes/sections/credits.yaml +29 -0
- package/src/ontology/archetypes/sections/donation-card.yaml +53 -0
- package/src/ontology/archetypes/sections/donation-use.yaml +23 -0
- package/src/ontology/archetypes/sections/dynamic-status-block.yaml +35 -0
- package/src/ontology/archetypes/sections/faq-list.yaml +26 -0
- package/src/ontology/archetypes/sections/final-cta.yaml +53 -0
- package/src/ontology/archetypes/sections/hero-decision-card.yaml +65 -0
- package/src/ontology/archetypes/sections/hero.yaml +50 -0
- package/src/ontology/archetypes/sections/impact.yaml +23 -0
- package/src/ontology/archetypes/sections/markdown.yaml +43 -0
- package/src/ontology/archetypes/sections/mountain-journey.yaml +43 -0
- package/src/ontology/archetypes/sections/navigation.yaml +20 -0
- package/src/ontology/archetypes/sections/notausgang-block.yaml +41 -0
- package/src/ontology/archetypes/sections/open-source-registry.yaml +26 -0
- package/src/ontology/archetypes/sections/ownership-block.yaml +57 -0
- package/src/ontology/archetypes/sections/people.yaml +48 -0
- package/src/ontology/archetypes/sections/price-card.yaml +50 -0
- package/src/ontology/archetypes/sections/problem.yaml +23 -0
- package/src/ontology/archetypes/sections/send-message.yaml +63 -0
- package/src/ontology/archetypes/sections/service-metadata-block.yaml +40 -0
- package/src/ontology/archetypes/sections/social-proof.yaml +27 -0
- package/src/ontology/archetypes/sections/transparency.yaml +32 -0
- package/src/ontology/archetypes/sections/trust-strip.yaml +42 -0
- package/src/ontology/archetypes/sections/video-section.yaml +27 -0
- package/src/ontology/archetypes/sections/women.yaml +29 -0
- package/src/ontology/biome-token-projection.ts +229 -0
- package/src/ontology/biomes/check-concrete-blueprint.yaml +118 -0
- package/src/ontology/biomes/handwerk-material-warm.yaml +135 -0
- package/src/ontology/biomes/nonprofit-trust.yaml +123 -0
- package/src/ontology/blueprints/offer.yaml +39 -0
- package/src/ontology/blueprints/prompts/local-market-signal.md +13 -0
- package/src/ontology/blueprints/prompts/website-local-narrative.md +24 -0
- package/src/ontology/blueprints/ratgeber.yaml +62 -0
- package/src/ontology/blueprints/website-local.yaml +309 -0
- package/src/ontology/blueprints/website-service.yaml +84 -0
- package/src/ontology/capabilities/lead.submit.yaml +44 -0
- package/src/ontology/cosmic/index.ts +48 -0
- package/src/ontology/cosmic/moon-catalog.ts +173 -0
- package/src/ontology/cosmic/planet-catalog.ts +82 -0
- package/src/ontology/cosmic/star-catalog.ts +337 -0
- package/src/ontology/enums.ts +159 -0
- package/src/ontology/external-surfaces/index.ts +158 -0
- package/src/ontology/external-surfaces/jsonld-types.yaml +135 -0
- package/src/ontology/external-surfaces/sitemap-shape.yaml +6 -0
- package/src/ontology/external-surfaces/url-schema.yaml +95 -0
- package/src/ontology/growth/events/contact-email-click.yaml +21 -0
- package/src/ontology/growth/events/contact-form-submit.yaml +25 -0
- package/src/ontology/growth/events/contact-phone-click.yaml +21 -0
- package/src/ontology/growth/events/contact-route-click.yaml +21 -0
- package/src/ontology/growth/events/contact-submit.yaml +28 -0
- package/src/ontology/growth/events/contact-whatsapp-click.yaml +21 -0
- package/src/ontology/growth/events/cta-click.yaml +30 -0
- package/src/ontology/growth/events/donation-confirmed.yaml +32 -0
- package/src/ontology/growth/events/donation-form-start.yaml +21 -0
- package/src/ontology/growth/events/donation-form-submit.yaml +29 -0
- package/src/ontology/growth/events/donation-intent.yaml +29 -0
- package/src/ontology/growth/events/form-error.yaml +27 -0
- package/src/ontology/growth/events/form-start.yaml +21 -0
- package/src/ontology/growth/events/form-submit.yaml +21 -0
- package/src/ontology/growth/events/outbound-click.yaml +25 -0
- package/src/ontology/growth/events/page-view.yaml +24 -0
- package/src/ontology/growth/events/passport-view.yaml +28 -0
- package/src/ontology/growth/events/star-map-navigate.yaml +30 -0
- package/src/ontology/index.ts +165 -0
- package/src/ontology/manifest.ts +344 -0
- package/src/ontology/operations/index.ts +1 -0
- package/src/ontology/schemas/biome.ts +303 -0
- package/src/ontology/schemas/capability.ts +104 -0
- package/src/ontology/schemas/constellation.ts +114 -0
- package/src/ontology/schemas/dns-records.ts +53 -0
- package/src/ontology/schemas/index.ts +95 -0
- package/src/ontology/schemas/manifest-resolver.ts +123 -0
- package/src/ontology/schemas/page-entry.ts +213 -0
- package/src/ontology/schemas/section-archetype.ts +109 -0
- package/src/ontology/schemas/site-family.ts +98 -0
- package/src/ontology/schemas/system/growth.ts +80 -0
- package/src/ontology/schemas/system/integrations.ts +143 -0
- package/src/ontology/schemas/system/manifest.ts +492 -0
- package/src/ontology/schemas/system/page-output.ts +99 -0
- package/src/ontology/schemas/system/release.ts +58 -0
- package/src/ontology/schemas/system/text.ts +58 -0
- package/src/ontology/schemas/system.ts +53 -0
- package/src/ontology/shared-section-props/body-fragments.ts +182 -0
- package/src/ontology/shared-section-props/catalog.ts +195 -0
- package/src/ontology/shared-section-props/common.ts +178 -0
- package/src/ontology/shared-section-props/index.ts +34 -0
- package/src/ontology/shared-section-props/visual-header.ts +163 -0
- package/src/ontology/site-families/charity-donation-trust/cultural-rules.yaml +6 -0
- package/src/ontology/site-families/charity-donation-trust/family.yaml +44 -0
- package/src/ontology/site-families/charity-donation-trust/linguistic-rules.yaml +6 -0
- package/src/ontology/site-families/check-quality-operator/cultural-rules.yaml +6 -0
- package/src/ontology/site-families/check-quality-operator/family.yaml +40 -0
- package/src/ontology/site-families/check-quality-operator/linguistic-rules.yaml +6 -0
- package/src/ontology/site-families/handwerk-trust-engineering/cultural-rules.yaml +6 -0
- package/src/ontology/site-families/handwerk-trust-engineering/family.yaml +53 -0
- package/src/ontology/site-families/handwerk-trust-engineering/linguistic-rules.yaml +6 -0
- package/src/ontology/tests/catalogs.pbt.test.ts +89 -0
- package/src/ontology/tests/enums.test.ts +203 -0
- package/src/ontology/tests/sternsystem-owner.test.ts +63 -0
- package/src/ontology/vitest.config.ts +8 -0
- package/src/passport/dht-sign.test.ts +99 -0
- package/src/passport/dht-sign.ts +73 -0
- package/src/passport/identity-sign.test.ts +134 -0
- package/src/passport/identity-sign.ts +85 -0
- package/src/passport/index.ts +53 -0
- package/src/passport/key-rotate.ts +133 -0
- package/src/passport/schema.ts +198 -0
- package/src/passport/sign.ts +225 -0
- package/src/passport/tests/schema.pbt.test.ts +93 -0
- package/src/passport/tests/schema.test.ts +222 -0
- package/src/passport/vitest.config.ts +8 -0
- package/src/share/agent/api-catalog.ts +77 -0
- package/src/share/agent/capability.ts +68 -0
- package/src/share/agent/dns-aid.test.ts +74 -0
- package/src/share/agent/dns-aid.ts +53 -0
- package/src/share/agent/fleet-catalog.ts +149 -0
- package/src/share/agent/index.ts +29 -0
- package/src/share/agent/knowledge.ts +96 -0
- package/src/share/agent/manifest.ts +126 -0
- package/src/share/agent/mcp-card.ts +63 -0
- package/src/share/agent/omit-empty.ts +77 -0
- package/src/share/agent/openapi.ts +157 -0
- package/src/share/agent/proof.ts +61 -0
- package/src/share/attribution-display.ts +86 -0
- package/src/share/check-hints.ts +38 -0
- package/src/share/content/entity-id.ts +65 -0
- package/src/share/content/index.ts +16 -0
- package/src/share/content/merge.ts +86 -0
- package/src/share/content/resolve-field-path.ts +39 -0
- package/src/share/content/substitute-deep.ts +47 -0
- package/src/share/content-discipline/index.ts +14 -0
- package/src/share/content-discipline/parsers.ts +66 -0
- package/src/share/content-discipline/types.ts +118 -0
- package/src/share/content-reference.ts +333 -0
- package/src/share/counter-utils.ts +75 -0
- package/src/share/css-value-normalize.ts +48 -0
- package/src/share/dev-props-validator.ts +131 -0
- package/src/share/entitlement.ts +172 -0
- package/src/share/env.d.ts +73 -0
- package/src/share/feature-policy.ts +367 -0
- package/src/share/formula-eval.ts +364 -0
- package/src/share/fs/index.ts +96 -0
- package/src/share/i18n/localization.ts +57 -0
- package/src/share/image-provider.ts +314 -0
- package/src/share/index.ts +86 -0
- package/src/share/knowledge/claim.ts +129 -0
- package/src/share/knowledge/derivation.ts +55 -0
- package/src/share/knowledge/freshness.ts +127 -0
- package/src/share/knowledge/index.ts +23 -0
- package/src/share/knowledge/ledger.ts +222 -0
- package/src/share/knowledge/plan.ts +122 -0
- package/src/share/knowledge/source.ts +170 -0
- package/src/share/legal/translation-policy.ts +133 -0
- package/src/share/material-credits.ts +181 -0
- package/src/share/middleware/language-redirect.ts +49 -0
- package/src/share/offer-capacity.ts +149 -0
- package/src/share/onboarding-yaml/index.ts +162 -0
- package/src/share/page.ts +351 -0
- package/src/share/redirects.test.ts +62 -0
- package/src/share/redirects.ts +54 -0
- package/src/share/rfc0042-utils.ts +95 -0
- package/src/share/runtime-context.ts +70 -0
- package/src/share/schemas/claim-records.ts +69 -0
- package/src/share/schemas/claims.ts +150 -0
- package/src/share/schemas/effects.ts +212 -0
- package/src/share/schemas/features.ts +147 -0
- package/src/share/schemas/horizontal-align.ts +22 -0
- package/src/share/schemas/icon-color.ts +27 -0
- package/src/share/schemas/index.ts +43 -0
- package/src/share/schemas/live-photo.ts +53 -0
- package/src/share/schemas/material-credit.ts +292 -0
- package/src/share/schemas/media.ts +220 -0
- package/src/share/schemas/navigation.ts +74 -0
- package/src/share/schemas/page-base.ts +33 -0
- package/src/share/schemas/participant.ts +247 -0
- package/src/share/schemas/person.ts +24 -0
- package/src/share/schemas/print.ts +93 -0
- package/src/share/schemas/section-background.ts +106 -0
- package/src/share/schemas/section-body.ts +138 -0
- package/src/share/schemas/section-cards.ts +37 -0
- package/src/share/schemas/section-cta.ts +74 -0
- package/src/share/schemas/section-header.ts +77 -0
- package/src/share/schemas/section-image.ts +77 -0
- package/src/share/schemas/section-motion.ts +52 -0
- package/src/share/schemas/section-shell.ts +63 -0
- package/src/share/schemas/section-stats.ts +37 -0
- package/src/share/schemas/site-background.ts +78 -0
- package/src/share/schemas/standard-list-item.ts +38 -0
- package/src/share/scripts/external-links.ts +45 -0
- package/src/share/scripts/gsap-counter.ts +168 -0
- package/src/share/scripts/gsap-mountain-journey.ts +236 -0
- package/src/share/scripts/gsap-parallax.ts +50 -0
- package/src/share/scripts/gsap-reveal.ts +65 -0
- package/src/share/scripts/gsap-stagger.ts +54 -0
- package/src/share/scripts/index.ts +25 -0
- package/src/share/scripts/inline-number-animation.ts +120 -0
- package/src/share/scripts/lenis.ts +109 -0
- package/src/share/scripts/live-photos.ts +250 -0
- package/src/share/scripts/lordicon.ts +94 -0
- package/src/share/scripts/orchestrator.ts +138 -0
- package/src/share/scripts/scheduler.ts +53 -0
- package/src/share/scripts/video-player.ts +116 -0
- package/src/share/semantic/ai.ts +140 -0
- package/src/share/semantic/block-extraction.ts +52 -0
- package/src/share/semantic/block-extractors/index.ts +502 -0
- package/src/share/semantic/breadcrumbs.ts +120 -0
- package/src/share/semantic/build-page.ts +309 -0
- package/src/share/semantic/business-projection.ts +278 -0
- package/src/share/semantic/derived-prices-loader.ts +36 -0
- package/src/share/semantic/extract.ts +118 -0
- package/src/share/semantic/feed.ts +124 -0
- package/src/share/semantic/ids.ts +76 -0
- package/src/share/semantic/image-sitemap.ts +153 -0
- package/src/share/semantic/index.ts +36 -0
- package/src/share/semantic/jsonld/article.ts +47 -0
- package/src/share/semantic/jsonld/breadcrumb.ts +47 -0
- package/src/share/semantic/jsonld/collection-list.ts +30 -0
- package/src/share/semantic/jsonld/context.ts +46 -0
- package/src/share/semantic/jsonld/faq.ts +49 -0
- package/src/share/semantic/jsonld/initiative.ts +53 -0
- package/src/share/semantic/jsonld/organization.ts +101 -0
- package/src/share/semantic/jsonld/person.ts +71 -0
- package/src/share/semantic/jsonld/service.ts +80 -0
- package/src/share/semantic/jsonld/shared.ts +31 -0
- package/src/share/semantic/jsonld/types.ts +18 -0
- package/src/share/semantic/jsonld/webpage.ts +98 -0
- package/src/share/semantic/jsonld/website.ts +27 -0
- package/src/share/semantic/jsonld.ts +75 -0
- package/src/share/semantic/llms-policy.ts +74 -0
- package/src/share/semantic/llms.ts +394 -0
- package/src/share/semantic/markdown-hygiene.ts +68 -0
- package/src/share/semantic/markdown-twin-provenance.ts +242 -0
- package/src/share/semantic/models.ts +402 -0
- package/src/share/semantic/organization-profile.ts +160 -0
- package/src/share/semantic/output-projection.ts +131 -0
- package/src/share/semantic/page-builders/markdown-page.ts +84 -0
- package/src/share/semantic/page-markdown.ts +234 -0
- package/src/share/semantic/page-utils.ts +125 -0
- package/src/share/semantic/price-marker-resolver.ts +92 -0
- package/src/share/semantic/robots.ts +127 -0
- package/src/share/semantic/update-stamp.ts +136 -0
- package/src/share/shared-context.ts +177 -0
- package/src/share/string-utils.ts +19 -0
- package/src/share/tests/api-catalog.test.ts +97 -0
- package/src/share/tests/breadcrumbs.test.ts +126 -0
- package/src/share/tests/build-page-price-markers.test.ts +160 -0
- package/src/share/tests/capability.test.ts +107 -0
- package/src/share/tests/claim.test.ts +90 -0
- package/src/share/tests/content-ref-index.test.ts +328 -0
- package/src/share/tests/create-dev-props-validator.test.ts +38 -0
- package/src/share/tests/derivation.test.ts +39 -0
- package/src/share/tests/dev-props-validator.test.ts +88 -0
- package/src/share/tests/fleet-catalog.test.ts +134 -0
- package/src/share/tests/formula-eval.test.ts +619 -0
- package/src/share/tests/freshness.test.ts +60 -0
- package/src/share/tests/hero-section-numbering-parity.test.ts +51 -0
- package/src/share/tests/image-sitemap.test.ts +101 -0
- package/src/share/tests/jsonld-service.test.ts +282 -0
- package/src/share/tests/knowledge.test.ts +86 -0
- package/src/share/tests/ledger.test.ts +125 -0
- package/src/share/tests/llms-0789.test.ts +63 -0
- package/src/share/tests/manifest.test.ts +100 -0
- package/src/share/tests/markdown-twin-provenance.test.ts +108 -0
- package/src/share/tests/mcp-card.test.ts +57 -0
- package/src/share/tests/onboarding-yaml.test.ts +111 -0
- package/src/share/tests/ontology-role-by-cosmic-name.test.ts +28 -0
- package/src/share/tests/openapi.test.ts +116 -0
- package/src/share/tests/organization-jsonld.test.ts +74 -0
- package/src/share/tests/output-projection.test.ts +61 -0
- package/src/share/tests/plan.test.ts +97 -0
- package/src/share/tests/price-marker-resolver.test.ts +141 -0
- package/src/share/tests/proof.test.ts +72 -0
- package/src/share/tests/resolve-field-path.test.ts +52 -0
- package/src/share/tests/source.test.ts +81 -0
- package/src/share/tests/substitute-deep.test.ts +65 -0
- package/src/share/tests/text-normalize.pbt.test.ts +143 -0
- package/src/share/tests/text-normalize.test.ts +285 -0
- package/src/share/tests/twin-path.test.ts +43 -0
- package/src/share/text-normalize.ts +548 -0
- package/src/share/text-position.ts +19 -0
- package/src/share/types/hls-js-light.d.ts +16 -0
- package/src/share/visibility.ts +167 -0
- package/src/share/vitest.config.ts +8 -0
- package/src/share/wrap-inline-numbers.ts +139 -0
- package/src/surface/blueprint-schema.ts +314 -0
- package/src/surface/blueprint-types.ts +256 -0
- package/src/surface/blueprint.ts +300 -0
- package/src/surface/breaker.ts +57 -0
- package/src/surface/decision-composer.ts +156 -0
- package/src/surface/eligibility.ts +372 -0
- package/src/surface/evidence-records.ts +97 -0
- package/src/surface/fleet.ts +60 -0
- package/src/surface/geo.ts +170 -0
- package/src/surface/governance.ts +146 -0
- package/src/surface/index.ts +216 -0
- package/src/surface/io/index.ts +18 -0
- package/src/surface/io/surface-module-context-io.ts +60 -0
- package/src/surface/io/visibility-outcomes-io.ts +46 -0
- package/src/surface/module-context.ts +120 -0
- package/src/surface/substance.ts +161 -0
- package/src/surface/tests/eligibility.pbt.test.ts +137 -0
- package/src/surface/tests/eligibility.test.ts +302 -0
- package/src/surface/types.ts +289 -0
- package/src/surface/visibility.ts +57 -0
- package/src/surface/vitest.config.ts +8 -0
- package/tsconfig.json +17 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>RFC-0347: property-based tests for redactUrl safety invariants.</purpose>
|
|
4
|
+
<keywords>RFC-0347, PBT, fast-check, redact, url, observability</keywords>
|
|
5
|
+
<responsibilities>
|
|
6
|
+
<item>Verify redactUrl never contains a query string in output.</item>
|
|
7
|
+
<item>Verify redactUrl never contains a fragment in output.</item>
|
|
8
|
+
<item>Verify redactUrl is idempotent.</item>
|
|
9
|
+
<item>Verify redactUrl host is always lowercase.</item>
|
|
10
|
+
</responsibilities>
|
|
11
|
+
</MODULE_CONTRACT>
|
|
12
|
+
<MODULE_MAP><entry key="pbt-redact-url">Property-based tests for redactUrl safety invariants.</entry></MODULE_MAP>
|
|
13
|
+
<CHANGE_SUMMARY><item>RFC-0347: initial PBT illustrative example for redactUrl invariants.</item></CHANGE_SUMMARY>
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
import { test, expect } from "vitest";
|
|
17
|
+
import fc from "fast-check";
|
|
18
|
+
import { redactUrl } from "../redact.ts";
|
|
19
|
+
|
|
20
|
+
const urlArbitrary = fc.webUrl();
|
|
21
|
+
|
|
22
|
+
test("PBT: redactUrl output never contains a query string", () => {
|
|
23
|
+
fc.assert(
|
|
24
|
+
fc.property(urlArbitrary, (url) => {
|
|
25
|
+
const redacted = redactUrl(url);
|
|
26
|
+
try {
|
|
27
|
+
const parsed = new URL(redacted);
|
|
28
|
+
expect(parsed.search).toBe("");
|
|
29
|
+
} catch {
|
|
30
|
+
// non-URL input passes through unchanged — skip
|
|
31
|
+
}
|
|
32
|
+
}),
|
|
33
|
+
);
|
|
34
|
+
});
|
|
35
|
+
|
|
36
|
+
test("PBT: redactUrl output never contains a fragment", () => {
|
|
37
|
+
fc.assert(
|
|
38
|
+
fc.property(urlArbitrary, (url) => {
|
|
39
|
+
const redacted = redactUrl(url);
|
|
40
|
+
try {
|
|
41
|
+
const parsed = new URL(redacted);
|
|
42
|
+
expect(parsed.hash).toBe("");
|
|
43
|
+
} catch {
|
|
44
|
+
// non-URL input passes through unchanged — skip
|
|
45
|
+
}
|
|
46
|
+
}),
|
|
47
|
+
);
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
test("PBT: redactUrl is idempotent — redact(redact(url)) === redact(url)", () => {
|
|
51
|
+
fc.assert(
|
|
52
|
+
fc.property(urlArbitrary, (url) => {
|
|
53
|
+
const once = redactUrl(url);
|
|
54
|
+
expect(redactUrl(once)).toBe(once);
|
|
55
|
+
}),
|
|
56
|
+
);
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
test("PBT: redactUrl host is always lowercase", () => {
|
|
60
|
+
fc.assert(
|
|
61
|
+
fc.property(urlArbitrary, (url) => {
|
|
62
|
+
const redacted = redactUrl(url);
|
|
63
|
+
try {
|
|
64
|
+
const parsed = new URL(redacted);
|
|
65
|
+
expect(parsed.hostname).toBe(parsed.hostname.toLowerCase());
|
|
66
|
+
} catch {
|
|
67
|
+
// non-URL input passes through unchanged — skip
|
|
68
|
+
}
|
|
69
|
+
}),
|
|
70
|
+
);
|
|
71
|
+
});
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { describe, it, expect } from "vitest";
|
|
2
|
+
import { redactUrl } from "../redact.ts";
|
|
3
|
+
|
|
4
|
+
describe("redactUrl", () => {
|
|
5
|
+
it("strips query string and fragment", () => {
|
|
6
|
+
expect(redactUrl("https://a.b/p?q=1#f")).toBe("https://a.b/p");
|
|
7
|
+
});
|
|
8
|
+
|
|
9
|
+
it("strips only query string when no fragment", () => {
|
|
10
|
+
expect(redactUrl("https://a.b/p?q=1")).toBe("https://a.b/p");
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
it("strips only fragment when no query string", () => {
|
|
14
|
+
expect(redactUrl("https://a.b/p#section")).toBe("https://a.b/p");
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
it("lowercases the host", () => {
|
|
18
|
+
expect(redactUrl("https://EXAMPLE.COM/Path")).toBe("https://example.com/Path");
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
it("preserves path case", () => {
|
|
22
|
+
expect(redactUrl("https://a.b/CaseSensitive/Path?q=1")).toBe("https://a.b/CaseSensitive/Path");
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
it("returns input unchanged for invalid URLs", () => {
|
|
26
|
+
expect(redactUrl("not a url")).toBe("not a url");
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
it("handles root path", () => {
|
|
30
|
+
expect(redactUrl("https://a.b/?q=1#f")).toBe("https://a.b");
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
it("preserves non-root path slashes so repeated redaction is stable", () => {
|
|
34
|
+
expect(redactUrl("http://a.aa//")).toBe("http://a.aa//");
|
|
35
|
+
expect(redactUrl(redactUrl("http://a.aa//"))).toBe("http://a.aa//");
|
|
36
|
+
});
|
|
37
|
+
});
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>Maintains packages/observability/src/typed-refs.ts as an authored observability authored module so agents can evolve it without rediscovering local boundaries.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>Do not import node: modules — must be Workers-compatible.</item>
|
|
6
|
+
<item>Do not define metric specs (kind, help, unit, buckets) — metric-registry.ts is the runtime authority.</item>
|
|
7
|
+
</non-goals>
|
|
8
|
+
@ai-invariant: METRIC_REFS keys must match WARPGOGOL_METRIC_REGISTRY names exactly — enforced by compile-time type assertion below.
|
|
9
|
+
</MODULE_CONTRACT>
|
|
10
|
+
<CHANGE_SUMMARY>
|
|
11
|
+
<item>Add typed metric references for compile-time label-key enforcement across all consumers.</item>
|
|
12
|
+
<item>wg-review: correct non-goals, add compile-time registry-coverage assertion.</item>
|
|
13
|
+
<item>RFC-0807: add back prefix metric refs for service health monitoring.</item>
|
|
14
|
+
</CHANGE_SUMMARY>
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import type { MetricsPusher } from "./pusher.ts";
|
|
18
|
+
import { WARPGOGOL_METRIC_REGISTRY } from "./metric-registry.ts";
|
|
19
|
+
|
|
20
|
+
type LabelKeys<L extends readonly string[]> = L[number];
|
|
21
|
+
type LabelMap<L extends readonly string[]> = Partial<Record<LabelKeys<L>, string>>;
|
|
22
|
+
|
|
23
|
+
export interface TypedCounter<L extends readonly string[]> {
|
|
24
|
+
readonly name: string;
|
|
25
|
+
add(pusher: MetricsPusher, value: number, labels?: LabelMap<L>): void;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface TypedGauge<L extends readonly string[]> {
|
|
29
|
+
readonly name: string;
|
|
30
|
+
set(pusher: MetricsPusher, value: number, labels?: LabelMap<L>): void;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export interface TypedHistogram<L extends readonly string[]> {
|
|
34
|
+
readonly name: string;
|
|
35
|
+
record(pusher: MetricsPusher, value: number, labels?: LabelMap<L>): void;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
function defineCounter<L extends readonly string[]>(name: string, _labelKeys: L): TypedCounter<L> {
|
|
39
|
+
return {
|
|
40
|
+
name,
|
|
41
|
+
add(pusher, value, labels) {
|
|
42
|
+
pusher.counterAdd(name, value, (labels ?? {}) as Record<string, string>);
|
|
43
|
+
},
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
function defineGauge<L extends readonly string[]>(name: string, _labelKeys: L): TypedGauge<L> {
|
|
48
|
+
return {
|
|
49
|
+
name,
|
|
50
|
+
set(pusher, value, labels) {
|
|
51
|
+
pusher.gaugeSet(name, value, (labels ?? {}) as Record<string, string>);
|
|
52
|
+
},
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
function defineHistogram<L extends readonly string[]>(
|
|
57
|
+
name: string,
|
|
58
|
+
_labelKeys: L,
|
|
59
|
+
): TypedHistogram<L> {
|
|
60
|
+
return {
|
|
61
|
+
name,
|
|
62
|
+
record(pusher, value, labels) {
|
|
63
|
+
pusher.histogramRecord(name, value, (labels ?? {}) as Record<string, string>);
|
|
64
|
+
},
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export const METRIC_REFS = {
|
|
69
|
+
warpgogol_factory_smoke_total: defineCounter("warpgogol_factory_smoke_total", [] as const),
|
|
70
|
+
warpgogol_factory_command_runs_total: defineCounter("warpgogol_factory_command_runs_total", [
|
|
71
|
+
"command",
|
|
72
|
+
"status",
|
|
73
|
+
"site_id",
|
|
74
|
+
] as const),
|
|
75
|
+
warpgogol_factory_command_duration_seconds: defineHistogram(
|
|
76
|
+
"warpgogol_factory_command_duration_seconds",
|
|
77
|
+
["command", "site_id"] as const,
|
|
78
|
+
),
|
|
79
|
+
warpgogol_factory_diagnostics_total: defineCounter("warpgogol_factory_diagnostics_total", [
|
|
80
|
+
"command",
|
|
81
|
+
"severity",
|
|
82
|
+
"site_id",
|
|
83
|
+
] as const),
|
|
84
|
+
warpgogol_probe_up: defineGauge("warpgogol_probe_up", ["site_id", "route"] as const),
|
|
85
|
+
warpgogol_probe_ttfb_seconds: defineGauge("warpgogol_probe_ttfb_seconds", [
|
|
86
|
+
"site_id",
|
|
87
|
+
"route",
|
|
88
|
+
] as const),
|
|
89
|
+
warpgogol_probe_http_status_class_total: defineCounter(
|
|
90
|
+
"warpgogol_probe_http_status_class_total",
|
|
91
|
+
["site_id", "route", "status_class"] as const,
|
|
92
|
+
),
|
|
93
|
+
warpgogol_probe_content_ok: defineGauge("warpgogol_probe_content_ok", [
|
|
94
|
+
"site_id",
|
|
95
|
+
"route",
|
|
96
|
+
] as const),
|
|
97
|
+
warpgogol_probe_cert_expiry_days: defineGauge("warpgogol_probe_cert_expiry_days", [
|
|
98
|
+
"site_id",
|
|
99
|
+
] as const),
|
|
100
|
+
warpgogol_probe_deep_ok: defineGauge("warpgogol_probe_deep_ok", ["site_id"] as const),
|
|
101
|
+
warpgogol_delivery_requests_total: defineCounter("warpgogol_delivery_requests_total", [
|
|
102
|
+
"site_id",
|
|
103
|
+
"cache_status",
|
|
104
|
+
"status_class",
|
|
105
|
+
] as const),
|
|
106
|
+
warpgogol_delivery_bytes_total: defineCounter("warpgogol_delivery_bytes_total", [
|
|
107
|
+
"site_id",
|
|
108
|
+
] as const),
|
|
109
|
+
warpgogol_workers_requests_total: defineCounter("warpgogol_workers_requests_total", [
|
|
110
|
+
"site_id",
|
|
111
|
+
] as const),
|
|
112
|
+
warpgogol_workers_errors_total: defineCounter("warpgogol_workers_errors_total", [
|
|
113
|
+
"site_id",
|
|
114
|
+
] as const),
|
|
115
|
+
warpgogol_back_requests_total: defineCounter("warpgogol_back_requests_total", [
|
|
116
|
+
"service",
|
|
117
|
+
"status_class",
|
|
118
|
+
] as const),
|
|
119
|
+
warpgogol_back_up: defineGauge("warpgogol_back_up", ["service"] as const),
|
|
120
|
+
warpgogol_back_last_run_total: defineCounter("warpgogol_back_last_run_total", [
|
|
121
|
+
"service",
|
|
122
|
+
"status",
|
|
123
|
+
] as const),
|
|
124
|
+
warpgogol_back_last_error_total: defineCounter("warpgogol_back_last_error_total", [
|
|
125
|
+
"service",
|
|
126
|
+
] as const),
|
|
127
|
+
warpgogol_back_queue_depth: defineGauge("warpgogol_back_queue_depth", ["service"] as const),
|
|
128
|
+
} as const;
|
|
129
|
+
|
|
130
|
+
// Compile-time assertion: every METRIC_REFS key must be a declared registry metric name.
|
|
131
|
+
// If a metric is added to METRIC_REFS but not to WARPGOGOL_METRIC_REGISTRY (or vice versa),
|
|
132
|
+
// this type expression produces a compile error.
|
|
133
|
+
type _RegistryNames = (typeof WARPGOGOL_METRIC_REGISTRY)[number]["name"];
|
|
134
|
+
type _RefKeys = keyof typeof METRIC_REFS;
|
|
135
|
+
type _DriftCheck = _RefKeys extends _RegistryNames ? true : never;
|
|
136
|
+
const _assertNoDrift: _DriftCheck = true;
|
|
137
|
+
void _assertNoDrift;
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
kind: analytics-matomo-binding
|
|
2
|
+
id: warpgogol-matomo-binding
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
rfc: RFC-0305
|
|
5
|
+
messkanonVersion: 1.0.0
|
|
6
|
+
|
|
7
|
+
meta:
|
|
8
|
+
title: Warpgogol Matomo Binding
|
|
9
|
+
description: Replaceable mapping from Warpgogol Messkanon v1 to Matomo Cloud/On-Premise entities.
|
|
10
|
+
status: active
|
|
11
|
+
changelog:
|
|
12
|
+
- version: 1.0.0
|
|
13
|
+
date: 2026-07-06
|
|
14
|
+
summary: Initial RFC-0305 Matomo event, goal, dimension, provisioning, and export mapping.
|
|
15
|
+
|
|
16
|
+
tracker:
|
|
17
|
+
proxyPath: /_wg/analytics/
|
|
18
|
+
scriptPath: matomo.js
|
|
19
|
+
endpointPath: matomo.php
|
|
20
|
+
privacyProfile: bannerfrei-v1
|
|
21
|
+
requestMethod: POST
|
|
22
|
+
requiredQueueCalls:
|
|
23
|
+
- disableCookies
|
|
24
|
+
- disableBrowserFeatureDetection
|
|
25
|
+
- setDoNotTrack
|
|
26
|
+
- setTrackerUrl
|
|
27
|
+
- setSiteId
|
|
28
|
+
- trackPageView
|
|
29
|
+
- enableLinkTracking
|
|
30
|
+
forbiddenQueueCalls:
|
|
31
|
+
- rememberConsentGiven
|
|
32
|
+
- rememberCookieConsentGiven
|
|
33
|
+
- enableHeartBeatTimer
|
|
34
|
+
- setUserId
|
|
35
|
+
- enableCrossDomainLinking
|
|
36
|
+
|
|
37
|
+
events:
|
|
38
|
+
- semanticId: contact.phone_click
|
|
39
|
+
matomo:
|
|
40
|
+
category: contact
|
|
41
|
+
action: phone_click
|
|
42
|
+
nameFrom: payload.placement
|
|
43
|
+
- semanticId: contact.form_submit
|
|
44
|
+
matomo:
|
|
45
|
+
category: contact
|
|
46
|
+
action: form_submit
|
|
47
|
+
nameFrom: payload.formId
|
|
48
|
+
- semanticId: contact.whatsapp_click
|
|
49
|
+
matomo:
|
|
50
|
+
category: contact
|
|
51
|
+
action: whatsapp_click
|
|
52
|
+
nameFrom: payload.placement
|
|
53
|
+
- semanticId: contact.email_click
|
|
54
|
+
matomo:
|
|
55
|
+
category: contact
|
|
56
|
+
action: email_click
|
|
57
|
+
nameFrom: payload.placement
|
|
58
|
+
- semanticId: contact.route_click
|
|
59
|
+
matomo:
|
|
60
|
+
category: contact
|
|
61
|
+
action: route_click
|
|
62
|
+
nameFrom: payload.placement
|
|
63
|
+
|
|
64
|
+
goals:
|
|
65
|
+
- key: anfrage_telefon
|
|
66
|
+
name: Anfrage Telefon
|
|
67
|
+
semanticId: contact.phone_click
|
|
68
|
+
match:
|
|
69
|
+
type: event
|
|
70
|
+
category: contact
|
|
71
|
+
action: phone_click
|
|
72
|
+
- key: anfrage_formular
|
|
73
|
+
name: Anfrage Formular
|
|
74
|
+
semanticId: contact.form_submit
|
|
75
|
+
match:
|
|
76
|
+
type: event
|
|
77
|
+
category: contact
|
|
78
|
+
action: form_submit
|
|
79
|
+
- key: anfrage_whatsapp
|
|
80
|
+
name: Anfrage WhatsApp
|
|
81
|
+
semanticId: contact.whatsapp_click
|
|
82
|
+
match:
|
|
83
|
+
type: event
|
|
84
|
+
category: contact
|
|
85
|
+
action: whatsapp_click
|
|
86
|
+
- key: anfrage_email
|
|
87
|
+
name: Anfrage E-Mail
|
|
88
|
+
semanticId: contact.email_click
|
|
89
|
+
match:
|
|
90
|
+
type: event
|
|
91
|
+
category: contact
|
|
92
|
+
action: email_click
|
|
93
|
+
|
|
94
|
+
dimensions:
|
|
95
|
+
visit:
|
|
96
|
+
- name: client_id
|
|
97
|
+
required: true
|
|
98
|
+
idSource: fleet.registry
|
|
99
|
+
- name: messkanon_version
|
|
100
|
+
required: true
|
|
101
|
+
idSource: fleet.registry
|
|
102
|
+
- name: consent_level
|
|
103
|
+
required: true
|
|
104
|
+
idSource: fleet.registry
|
|
105
|
+
action:
|
|
106
|
+
- name: site_type
|
|
107
|
+
required: true
|
|
108
|
+
idSource: fleet.registry
|
|
109
|
+
- name: page_type
|
|
110
|
+
required: true
|
|
111
|
+
idSource: fleet.registry
|
|
112
|
+
- name: surface_module
|
|
113
|
+
required: false
|
|
114
|
+
idSource: fleet.registry
|
|
115
|
+
- name: pseo_industry
|
|
116
|
+
required: false
|
|
117
|
+
idSource: fleet.registry
|
|
118
|
+
- name: pseo_city
|
|
119
|
+
required: false
|
|
120
|
+
idSource: fleet.registry
|
|
121
|
+
- name: pseo_demand
|
|
122
|
+
required: false
|
|
123
|
+
idSource: fleet.registry
|
|
124
|
+
- name: pseo_locale
|
|
125
|
+
required: false
|
|
126
|
+
idSource: fleet.registry
|
|
127
|
+
- name: pseo_arm
|
|
128
|
+
required: false
|
|
129
|
+
idSource: fleet.registry
|
|
130
|
+
- name: pseo_experiment
|
|
131
|
+
required: false
|
|
132
|
+
idSource: fleet.registry
|
|
133
|
+
- name: pseo_substance_band
|
|
134
|
+
required: false
|
|
135
|
+
idSource: fleet.registry
|
|
136
|
+
- name: pseo_link_model
|
|
137
|
+
required: false
|
|
138
|
+
idSource: fleet.registry
|
|
139
|
+
|
|
140
|
+
siteDefaults:
|
|
141
|
+
timezone: Europe/Berlin
|
|
142
|
+
currency: EUR
|
|
143
|
+
excludeUnknownUrls: true
|
|
144
|
+
rawRetentionMonths: 24
|
|
145
|
+
reportRetention: forever
|
|
146
|
+
heatmapsEnabled: false
|
|
147
|
+
sessionRecordingsEnabled: false
|
|
148
|
+
|
|
149
|
+
provisioning:
|
|
150
|
+
apiMethods:
|
|
151
|
+
- SitesManager.addSite
|
|
152
|
+
- Goals.addGoal
|
|
153
|
+
- CustomDimensions.configureNewCustomDimension
|
|
154
|
+
idempotencyKey: clientSemanticId
|
|
155
|
+
registryRequired: true
|
|
156
|
+
|
|
157
|
+
smoke:
|
|
158
|
+
syntheticEvent: contact.route_click
|
|
159
|
+
syntheticName: anfahrt
|
|
160
|
+
expectFirstSignal: true
|
|
161
|
+
|
|
162
|
+
exportPackage:
|
|
163
|
+
includes:
|
|
164
|
+
- aggregateReports
|
|
165
|
+
- rawVisitsWithinRetention
|
|
166
|
+
- siteConfiguration
|
|
167
|
+
- goals
|
|
168
|
+
- dimensions
|
|
169
|
+
- messkanonVersion
|
|
170
|
+
- matomoBindingVersion
|
|
171
|
+
- readme
|
|
172
|
+
- manifestHashes
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
kind: analytics-matomo-fleet-registry
|
|
2
|
+
schemaVersion: 1
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
updatedAt: 2026-08-08
|
|
5
|
+
owner: architecture
|
|
6
|
+
policy:
|
|
7
|
+
sourceOfTruth: git
|
|
8
|
+
manualMatomoUiChanges: forbidden
|
|
9
|
+
productionAdapterRequiresRecord: true
|
|
10
|
+
siteIdSource: provisioning
|
|
11
|
+
noSecrets: true
|
|
12
|
+
sites:
|
|
13
|
+
- appId: warpgogol-com
|
|
14
|
+
clientSemanticId: warpgogol-com
|
|
15
|
+
siteId: "1"
|
|
16
|
+
matomoCloudHost: warpgogol.matomo.cloud
|
|
17
|
+
status: active
|
|
18
|
+
provisionedAt: "2026-08-08"
|
|
19
|
+
dimensions:
|
|
20
|
+
visit:
|
|
21
|
+
client_id: 1
|
|
22
|
+
messkanon_version: 2
|
|
23
|
+
consent_level: 3
|
|
24
|
+
action:
|
|
25
|
+
site_type: 4
|
|
26
|
+
page_type: 5
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
kind: analytics-messkanon
|
|
2
|
+
id: warpgogol-messkanon
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
rfc: RFC-0305
|
|
5
|
+
|
|
6
|
+
meta:
|
|
7
|
+
title: Warpgogol Messkanon
|
|
8
|
+
description: Tool-independent analytics vocabulary for thin Warpgogol sites.
|
|
9
|
+
status: active
|
|
10
|
+
changelog:
|
|
11
|
+
- version: 1.0.0
|
|
12
|
+
date: 2026-07-06
|
|
13
|
+
summary: Initial RFC-0305 contact-outcome vocabulary.
|
|
14
|
+
|
|
15
|
+
principles:
|
|
16
|
+
measureOutcomesNotBehavior: true
|
|
17
|
+
noPii: true
|
|
18
|
+
noBehavioralSessionReplay: true
|
|
19
|
+
defaultConsentLevel: bannerfrei
|
|
20
|
+
|
|
21
|
+
events:
|
|
22
|
+
- semanticId: contact.phone_click
|
|
23
|
+
category: contact
|
|
24
|
+
action: phone_click
|
|
25
|
+
nameValues: [header, footer, sticky, contact_page]
|
|
26
|
+
goalEligible: true
|
|
27
|
+
goalKey: anfrage_telefon
|
|
28
|
+
payload:
|
|
29
|
+
required: [placement]
|
|
30
|
+
properties:
|
|
31
|
+
placement:
|
|
32
|
+
type: enum
|
|
33
|
+
values: [header, footer, sticky, contact_page]
|
|
34
|
+
- semanticId: contact.form_submit
|
|
35
|
+
category: contact
|
|
36
|
+
action: form_submit
|
|
37
|
+
nameValues: [kontaktformular, send_message, lead_form]
|
|
38
|
+
goalEligible: true
|
|
39
|
+
goalKey: anfrage_formular
|
|
40
|
+
payload:
|
|
41
|
+
required: [formId]
|
|
42
|
+
properties:
|
|
43
|
+
formId:
|
|
44
|
+
type: string
|
|
45
|
+
- semanticId: contact.whatsapp_click
|
|
46
|
+
category: contact
|
|
47
|
+
action: whatsapp_click
|
|
48
|
+
nameValues: [sticky, footer, contact_page]
|
|
49
|
+
goalEligible: true
|
|
50
|
+
goalKey: anfrage_whatsapp
|
|
51
|
+
payload:
|
|
52
|
+
required: [placement]
|
|
53
|
+
properties:
|
|
54
|
+
placement:
|
|
55
|
+
type: enum
|
|
56
|
+
values: [sticky, footer, contact_page]
|
|
57
|
+
- semanticId: contact.email_click
|
|
58
|
+
category: contact
|
|
59
|
+
action: email_click
|
|
60
|
+
nameValues: [footer, impressum, contact_page]
|
|
61
|
+
goalEligible: true
|
|
62
|
+
goalKey: anfrage_email
|
|
63
|
+
payload:
|
|
64
|
+
required: [placement]
|
|
65
|
+
properties:
|
|
66
|
+
placement:
|
|
67
|
+
type: enum
|
|
68
|
+
values: [footer, impressum, contact_page]
|
|
69
|
+
- semanticId: contact.route_click
|
|
70
|
+
category: contact
|
|
71
|
+
action: route_click
|
|
72
|
+
nameValues: [anfahrt, map, footer]
|
|
73
|
+
goalEligible: false
|
|
74
|
+
payload:
|
|
75
|
+
required: [placement]
|
|
76
|
+
properties:
|
|
77
|
+
placement:
|
|
78
|
+
type: enum
|
|
79
|
+
values: [anfahrt, map, footer]
|
|
80
|
+
|
|
81
|
+
kpis:
|
|
82
|
+
- id: visits_30d
|
|
83
|
+
source: matomo.report
|
|
84
|
+
report: VisitsSummary.get
|
|
85
|
+
period: last_30_days
|
|
86
|
+
- id: anfragen_30d
|
|
87
|
+
source: messkanon.goals
|
|
88
|
+
goals: [anfrage_telefon, anfrage_formular, anfrage_whatsapp, anfrage_email]
|
|
89
|
+
period: last_30_days
|
|
90
|
+
- id: top_source_30d
|
|
91
|
+
source: matomo.report
|
|
92
|
+
report: Referrers.getAll
|
|
93
|
+
period: last_30_days
|
|
94
|
+
- id: anfrage_by_channel_30d
|
|
95
|
+
source: messkanon.goals
|
|
96
|
+
goals: [anfrage_telefon, anfrage_formular, anfrage_whatsapp, anfrage_email]
|
|
97
|
+
period: last_30_days
|
|
98
|
+
- id: kontaktbilanz_quarter
|
|
99
|
+
source: messkanon.goals
|
|
100
|
+
goals: [anfrage_telefon, anfrage_formular, anfrage_whatsapp, anfrage_email]
|
|
101
|
+
period: quarter
|
|
102
|
+
|
|
103
|
+
campaignParameters:
|
|
104
|
+
allowed: [utm_source, utm_medium, utm_campaign, utm_content, utm_term]
|
|
105
|
+
forbidPii: true
|
|
106
|
+
|
|
107
|
+
dimensions:
|
|
108
|
+
visit:
|
|
109
|
+
- name: client_id
|
|
110
|
+
required: true
|
|
111
|
+
valueSource: fleet.clientSemanticId
|
|
112
|
+
- name: messkanon_version
|
|
113
|
+
required: true
|
|
114
|
+
valueSource: ontology.analytics.messkanon.version
|
|
115
|
+
- name: consent_level
|
|
116
|
+
required: true
|
|
117
|
+
valueSource: constant.bannerfrei
|
|
118
|
+
action:
|
|
119
|
+
- name: site_type
|
|
120
|
+
required: true
|
|
121
|
+
valueSource: system.growth.vendor.options.siteType
|
|
122
|
+
- name: page_type
|
|
123
|
+
required: true
|
|
124
|
+
valueSource: page.context.pageType
|
|
125
|
+
- name: surface_module
|
|
126
|
+
required: false
|
|
127
|
+
valueSource: page.context.surfaceModule
|
|
128
|
+
- name: pseo_industry
|
|
129
|
+
required: false
|
|
130
|
+
valueSource: page.context.pseo.industry
|
|
131
|
+
- name: pseo_city
|
|
132
|
+
required: false
|
|
133
|
+
valueSource: page.context.pseo.city
|
|
134
|
+
- name: pseo_demand
|
|
135
|
+
required: false
|
|
136
|
+
valueSource: page.context.pseo.demand
|
|
137
|
+
- name: pseo_locale
|
|
138
|
+
required: false
|
|
139
|
+
valueSource: page.context.pseo.locale
|
|
140
|
+
- name: pseo_arm
|
|
141
|
+
required: false
|
|
142
|
+
valueSource: page.context.pseo.arm
|
|
143
|
+
- name: pseo_experiment
|
|
144
|
+
required: false
|
|
145
|
+
valueSource: page.context.pseo.experiment
|
|
146
|
+
- name: pseo_substance_band
|
|
147
|
+
required: false
|
|
148
|
+
valueSource: page.context.pseo.substanceBand
|
|
149
|
+
- name: pseo_link_model
|
|
150
|
+
required: false
|
|
151
|
+
valueSource: page.context.pseo.linkModel
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>
|
|
4
|
+
Re-export the derived planetImportPaths, blockTypeToCosmicName, moonImportPaths,
|
|
5
|
+
and roleByCosmicName maps from the canonical archetype registry index.json
|
|
6
|
+
(RFC-0091). Validates the JSON shape at import time so registry drift fails
|
|
7
|
+
fast instead of producing silently empty maps.
|
|
8
|
+
</purpose>
|
|
9
|
+
<non-goals>
|
|
10
|
+
<item>Do not own the build logic that produces index.json.</item>
|
|
11
|
+
<item>Do not re-derive or transform the maps.</item>
|
|
12
|
+
</non-goals>
|
|
13
|
+
</MODULE_CONTRACT>
|
|
14
|
+
<CHANGE_SUMMARY>
|
|
15
|
+
<item>RFC-0091: Initial creation — typed re-export of derived archetype registry maps.</item>
|
|
16
|
+
<item>RFC-0263: also re-export roleByCosmicName (manifest-authored role, derived) — replaces name-keyed dispatch literals in packages/share.</item>
|
|
17
|
+
<item>Architecture review 2026-07-10: validate index.json with Zod instead of unchecked cast — fail-fast on registry shape drift.</item>
|
|
18
|
+
</CHANGE_SUMMARY>
|
|
19
|
+
*/
|
|
20
|
+
|
|
21
|
+
import { z } from "zod";
|
|
22
|
+
import indexJson from "./archetypes/index.json";
|
|
23
|
+
|
|
24
|
+
const recordStringString = z.record(z.string(), z.string());
|
|
25
|
+
|
|
26
|
+
const archetypeRegistryIndexSchema = z.object({
|
|
27
|
+
schemaVersion: z.string().min(1),
|
|
28
|
+
totalCount: z.number().int().nonnegative(),
|
|
29
|
+
entries: z.array(
|
|
30
|
+
z.object({
|
|
31
|
+
id: z.string().min(1),
|
|
32
|
+
displayName: z.string().min(1),
|
|
33
|
+
semanticRole: z.string().min(1),
|
|
34
|
+
version: z.string().min(1),
|
|
35
|
+
layoutHint: z.string().min(1),
|
|
36
|
+
acceptedCosmicNames: z.array(z.string().min(1)),
|
|
37
|
+
sourceFile: z.string().min(1),
|
|
38
|
+
layer: z.enum(["section", "component"]),
|
|
39
|
+
}),
|
|
40
|
+
),
|
|
41
|
+
sectionRoles: z.array(z.string().min(1)),
|
|
42
|
+
componentRoles: z.array(z.string().min(1)),
|
|
43
|
+
planetImportPaths: recordStringString,
|
|
44
|
+
blockTypeToCosmicName: recordStringString,
|
|
45
|
+
moonImportPaths: recordStringString.optional().default({}),
|
|
46
|
+
roleByCosmicName: recordStringString.optional().default({}),
|
|
47
|
+
});
|
|
48
|
+
|
|
49
|
+
const _parsed = archetypeRegistryIndexSchema.safeParse(indexJson);
|
|
50
|
+
if (!_parsed.success) {
|
|
51
|
+
const issues = _parsed.error.issues.map((i) => `${i.path.join(".")}: ${i.message}`).join("; ");
|
|
52
|
+
throw new Error(
|
|
53
|
+
`archetype-registry: archetypes/index.yaml failed validation — ${issues}. Regenerate with the archetype registry build command.`,
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
const registry = _parsed.data;
|
|
57
|
+
|
|
58
|
+
export const planetImportPaths: Record<string, string> = registry.planetImportPaths;
|
|
59
|
+
export const blockTypeToCosmicName: Record<string, string> = registry.blockTypeToCosmicName;
|
|
60
|
+
export const moonImportPaths: Record<string, string> = registry.moonImportPaths;
|
|
61
|
+
export const roleByCosmicName: Record<string, string> = registry.roleByCosmicName;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
id: brand-label
|
|
2
|
+
displayName: Brand Label
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
semanticRole: component-brand-label
|
|
5
|
+
description: |
|
|
6
|
+
Starter RFC-0072 archetype seeded from existing manifest metadata.
|
|
7
|
+
expectedIntents:
|
|
8
|
+
- establish-identity
|
|
9
|
+
- guide-navigation
|
|
10
|
+
expectedIndustryFit:
|
|
11
|
+
- non-profit
|
|
12
|
+
layoutHint: split
|
|
13
|
+
propsSchema:
|
|
14
|
+
$shape: zod
|
|
15
|
+
shape: |
|
|
16
|
+
z.object({}).passthrough()
|
|
17
|
+
acceptedCosmicNames:
|
|
18
|
+
- Proteus
|
|
19
|
+
constraints: {}
|