@ucptools/validator 1.0.0 → 1.1.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/dist/auth/config.d.ts +20 -0
- package/dist/auth/config.d.ts.map +1 -0
- package/dist/auth/config.js +114 -0
- package/dist/auth/config.js.map +1 -0
- package/dist/auth/index.d.ts +5 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/index.js +17 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/auth/middleware.d.ts +45 -0
- package/dist/auth/middleware.d.ts.map +1 -0
- package/dist/auth/middleware.js +170 -0
- package/dist/auth/middleware.js.map +1 -0
- package/dist/auth/service.d.ts +80 -0
- package/dist/auth/service.d.ts.map +1 -0
- package/dist/auth/service.js +298 -0
- package/dist/auth/service.js.map +1 -0
- package/dist/cli/index.d.ts +6 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +375 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/cli/mock-server.d.ts +20 -0
- package/dist/cli/mock-server.d.ts.map +1 -0
- package/dist/cli/mock-server.js +261 -0
- package/dist/cli/mock-server.js.map +1 -0
- package/dist/compliance/compliance-generator.d.ts +34 -0
- package/dist/compliance/compliance-generator.d.ts.map +1 -0
- package/dist/compliance/compliance-generator.js +320 -0
- package/dist/compliance/compliance-generator.js.map +1 -0
- package/dist/compliance/index.d.ts +8 -0
- package/dist/compliance/index.d.ts.map +1 -0
- package/dist/compliance/index.js +17 -0
- package/dist/compliance/index.js.map +1 -0
- package/dist/compliance/templates.d.ts +34 -0
- package/dist/compliance/templates.d.ts.map +1 -0
- package/{src/compliance/templates.ts → dist/compliance/templates.js} +117 -155
- package/dist/compliance/templates.js.map +1 -0
- package/dist/compliance/types.d.ts +64 -0
- package/dist/compliance/types.d.ts.map +1 -0
- package/dist/compliance/types.js +64 -0
- package/dist/compliance/types.js.map +1 -0
- package/dist/db/index.d.ts +17 -0
- package/dist/db/index.d.ts.map +1 -0
- package/dist/db/index.js +80 -0
- package/dist/db/index.js.map +1 -0
- package/dist/db/schema.d.ts +3886 -0
- package/dist/db/schema.d.ts.map +1 -0
- package/dist/db/schema.js +425 -0
- package/dist/db/schema.js.map +1 -0
- package/dist/db/utils.d.ts +252 -0
- package/dist/db/utils.d.ts.map +1 -0
- package/dist/db/utils.js +295 -0
- package/dist/db/utils.js.map +1 -0
- package/dist/feed-analyzer/feed-analyzer.d.ts +26 -0
- package/dist/feed-analyzer/feed-analyzer.d.ts.map +1 -0
- package/{src/feed-analyzer/feed-analyzer.ts → dist/feed-analyzer/feed-analyzer.js} +856 -726
- package/dist/feed-analyzer/feed-analyzer.js.map +1 -0
- package/dist/feed-analyzer/index.d.ts +8 -0
- package/dist/feed-analyzer/index.d.ts.map +1 -0
- package/dist/feed-analyzer/index.js +19 -0
- package/dist/feed-analyzer/index.js.map +1 -0
- package/dist/feed-analyzer/types.d.ts +285 -0
- package/dist/feed-analyzer/types.d.ts.map +1 -0
- package/dist/feed-analyzer/types.js +175 -0
- package/dist/feed-analyzer/types.js.map +1 -0
- package/{src/generator/index.ts → dist/generator/index.d.ts} +1 -1
- package/dist/generator/index.d.ts.map +1 -0
- package/dist/generator/index.js +13 -0
- package/dist/generator/index.js.map +1 -0
- package/dist/generator/key-generator.d.ts +24 -0
- package/dist/generator/key-generator.d.ts.map +1 -0
- package/dist/generator/key-generator.js +144 -0
- package/dist/generator/key-generator.js.map +1 -0
- package/dist/generator/profile-builder.d.ts +15 -0
- package/dist/generator/profile-builder.d.ts.map +1 -0
- package/dist/generator/profile-builder.js +338 -0
- package/dist/generator/profile-builder.js.map +1 -0
- package/dist/hosting/artifacts-generator.d.ts +10 -0
- package/dist/hosting/artifacts-generator.d.ts.map +1 -0
- package/{src/hosting/artifacts-generator.ts → dist/hosting/artifacts-generator.js} +191 -241
- package/dist/hosting/artifacts-generator.js.map +1 -0
- package/{src/hosting/index.ts → dist/hosting/index.d.ts} +1 -1
- package/dist/hosting/index.d.ts.map +1 -0
- package/dist/hosting/index.js +10 -0
- package/dist/hosting/index.js.map +1 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +78 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/analytics.d.ts +337 -0
- package/dist/lib/analytics.d.ts.map +1 -0
- package/dist/lib/analytics.js +188 -0
- package/dist/lib/analytics.js.map +1 -0
- package/{src/security/index.ts → dist/security/index.d.ts} +8 -15
- package/dist/security/index.d.ts.map +1 -0
- package/dist/security/index.js +12 -0
- package/dist/security/index.js.map +1 -0
- package/dist/security/security-scanner.d.ts +10 -0
- package/dist/security/security-scanner.d.ts.map +1 -0
- package/dist/security/security-scanner.js +669 -0
- package/dist/security/security-scanner.js.map +1 -0
- package/dist/security/types.d.ts +80 -0
- package/dist/security/types.d.ts.map +1 -0
- package/dist/security/types.js +21 -0
- package/dist/security/types.js.map +1 -0
- package/dist/services/analytics.d.ts +114 -0
- package/dist/services/analytics.d.ts.map +1 -0
- package/dist/services/analytics.js +862 -0
- package/dist/services/analytics.js.map +1 -0
- package/dist/services/badge.d.ts +31 -0
- package/dist/services/badge.d.ts.map +1 -0
- package/dist/services/badge.js +152 -0
- package/dist/services/badge.js.map +1 -0
- package/dist/services/cron.d.ts +125 -0
- package/dist/services/cron.d.ts.map +1 -0
- package/dist/services/cron.js +613 -0
- package/dist/services/cron.js.map +1 -0
- package/dist/services/directory.d.ts +106 -0
- package/dist/services/directory.d.ts.map +1 -0
- package/dist/services/directory.js +351 -0
- package/dist/services/directory.js.map +1 -0
- package/dist/services/email.d.ts +112 -0
- package/dist/services/email.d.ts.map +1 -0
- package/dist/services/email.js +772 -0
- package/dist/services/email.js.map +1 -0
- package/dist/services/hosted-profiles.d.ts +77 -0
- package/dist/services/hosted-profiles.d.ts.map +1 -0
- package/dist/services/hosted-profiles.js +433 -0
- package/dist/services/hosted-profiles.js.map +1 -0
- package/dist/services/latency.d.ts +67 -0
- package/dist/services/latency.d.ts.map +1 -0
- package/dist/services/latency.js +274 -0
- package/dist/services/latency.js.map +1 -0
- package/dist/services/manifest-compliance.d.ts +64 -0
- package/dist/services/manifest-compliance.d.ts.map +1 -0
- package/dist/services/manifest-compliance.js +271 -0
- package/dist/services/manifest-compliance.js.map +1 -0
- package/dist/services/monitoring-diff.d.ts +31 -0
- package/dist/services/monitoring-diff.d.ts.map +1 -0
- package/dist/services/monitoring-diff.js +189 -0
- package/dist/services/monitoring-diff.js.map +1 -0
- package/dist/services/notifications.d.ts +46 -0
- package/dist/services/notifications.d.ts.map +1 -0
- package/dist/services/notifications.js +88 -0
- package/dist/services/notifications.js.map +1 -0
- package/dist/services/stripe.d.ts +93 -0
- package/dist/services/stripe.d.ts.map +1 -0
- package/dist/services/stripe.js +490 -0
- package/dist/services/stripe.js.map +1 -0
- package/dist/services/validation-history.d.ts +99 -0
- package/dist/services/validation-history.d.ts.map +1 -0
- package/dist/services/validation-history.js +344 -0
- package/dist/services/validation-history.js.map +1 -0
- package/dist/services/validation-logging.d.ts +103 -0
- package/dist/services/validation-logging.d.ts.map +1 -0
- package/dist/services/validation-logging.js +210 -0
- package/dist/services/validation-logging.js.map +1 -0
- package/dist/services/validation.d.ts +119 -0
- package/dist/services/validation.d.ts.map +1 -0
- package/dist/services/validation.js +1185 -0
- package/dist/services/validation.js.map +1 -0
- package/dist/simulator/agent-simulator.d.ts +69 -0
- package/dist/simulator/agent-simulator.d.ts.map +1 -0
- package/dist/simulator/agent-simulator.js +870 -0
- package/dist/simulator/agent-simulator.js.map +1 -0
- package/{src/simulator/index.ts → dist/simulator/index.d.ts} +7 -7
- package/dist/simulator/index.d.ts.map +1 -0
- package/dist/simulator/index.js +23 -0
- package/dist/simulator/index.js.map +1 -0
- package/{src/simulator/types.ts → dist/simulator/types.d.ts} +171 -170
- package/dist/simulator/types.d.ts.map +1 -0
- package/dist/simulator/types.js +18 -0
- package/dist/simulator/types.js.map +1 -0
- package/dist/types/acp-validation.d.ts +87 -0
- package/dist/types/acp-validation.d.ts.map +1 -0
- package/dist/types/acp-validation.js +40 -0
- package/dist/types/acp-validation.js.map +1 -0
- package/dist/types/analytics.d.ts +182 -0
- package/dist/types/analytics.d.ts.map +1 -0
- package/dist/types/analytics.js +7 -0
- package/dist/types/analytics.js.map +1 -0
- package/dist/types/generator.d.ts +106 -0
- package/dist/types/generator.d.ts.map +1 -0
- package/dist/types/generator.js +6 -0
- package/dist/types/generator.js.map +1 -0
- package/{src/types/index.ts → dist/types/index.d.ts} +1 -1
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +23 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/ucp-profile.d.ts +111 -0
- package/dist/types/ucp-profile.d.ts.map +1 -0
- package/dist/types/ucp-profile.js +45 -0
- package/dist/types/ucp-profile.js.map +1 -0
- package/dist/types/validation.d.ts +76 -0
- package/dist/types/validation.d.ts.map +1 -0
- package/dist/types/validation.js +42 -0
- package/dist/types/validation.js.map +1 -0
- package/dist/validator/acp/index.d.ts +31 -0
- package/dist/validator/acp/index.d.ts.map +1 -0
- package/dist/validator/acp/index.js +574 -0
- package/dist/validator/acp/index.js.map +1 -0
- package/dist/validator/index.d.ts +26 -0
- package/dist/validator/index.d.ts.map +1 -0
- package/dist/validator/index.js +161 -0
- package/dist/validator/index.js.map +1 -0
- package/dist/validator/network-validator.d.ts +28 -0
- package/dist/validator/network-validator.d.ts.map +1 -0
- package/dist/validator/network-validator.js +319 -0
- package/dist/validator/network-validator.js.map +1 -0
- package/dist/validator/rules-validator.d.ts +19 -0
- package/dist/validator/rules-validator.d.ts.map +1 -0
- package/dist/validator/rules-validator.js +306 -0
- package/dist/validator/rules-validator.js.map +1 -0
- package/dist/validator/sdk-validator.d.ts +58 -0
- package/dist/validator/sdk-validator.d.ts.map +1 -0
- package/{src/validator/sdk-validator.ts → dist/validator/sdk-validator.js} +273 -330
- package/dist/validator/sdk-validator.js.map +1 -0
- package/dist/validator/structural-validator.d.ts +11 -0
- package/dist/validator/structural-validator.d.ts.map +1 -0
- package/dist/validator/structural-validator.js +549 -0
- package/dist/validator/structural-validator.js.map +1 -0
- package/dist/validator/utils.d.ts +51 -0
- package/dist/validator/utils.d.ts.map +1 -0
- package/dist/validator/utils.js +132 -0
- package/dist/validator/utils.js.map +1 -0
- package/package.json +44 -12
- package/CLAUDE.md +0 -109
- package/api/analyze-feed.js +0 -140
- package/api/badge.js +0 -185
- package/api/benchmark.js +0 -177
- package/api/directory-stats.ts +0 -29
- package/api/directory.ts +0 -73
- package/api/generate-compliance.js +0 -143
- package/api/generate-schema.js +0 -457
- package/api/generate.js +0 -132
- package/api/security-scan.js +0 -133
- package/api/simulate.js +0 -187
- package/api/tsconfig.json +0 -10
- package/api/validate.js +0 -1351
- package/apify-actor/.actor/actor.json +0 -68
- package/apify-actor/.actor/input_schema.json +0 -32
- package/apify-actor/APIFY-STORE-LISTING.md +0 -412
- package/apify-actor/Dockerfile +0 -8
- package/apify-actor/README.md +0 -166
- package/apify-actor/main.ts +0 -111
- package/apify-actor/package.json +0 -17
- package/apify-actor/src/main.js +0 -199
- package/docs/BRAND-IDENTITY.md +0 -238
- package/docs/BRAND-STYLE-GUIDE.md +0 -356
- package/drizzle/0000_black_king_cobra.sql +0 -39
- package/drizzle/meta/0000_snapshot.json +0 -309
- package/drizzle/meta/_journal.json +0 -13
- package/drizzle.config.ts +0 -10
- package/public/.well-known/ucp +0 -25
- package/public/android-chrome-192x192.png +0 -0
- package/public/android-chrome-512x512.png +0 -0
- package/public/apple-touch-icon.png +0 -0
- package/public/brand.css +0 -321
- package/public/directory.html +0 -701
- package/public/favicon-16x16.png +0 -0
- package/public/favicon-32x32.png +0 -0
- package/public/favicon.ico +0 -0
- package/public/guides/bigcommerce.html +0 -743
- package/public/guides/fastucp.html +0 -838
- package/public/guides/magento.html +0 -779
- package/public/guides/shopify.html +0 -726
- package/public/guides/squarespace.html +0 -749
- package/public/guides/wix.html +0 -747
- package/public/guides/woocommerce.html +0 -733
- package/public/index.html +0 -3835
- package/public/learn.html +0 -396
- package/public/logo.jpeg +0 -0
- package/public/og-image-icon.png +0 -0
- package/public/og-image.png +0 -0
- package/public/robots.txt +0 -6
- package/public/site.webmanifest +0 -31
- package/public/sitemap.xml +0 -69
- package/public/social/linkedin-banner-1128x191.png +0 -0
- package/public/social/temp.PNG +0 -0
- package/public/social/x-header-1500x500.png +0 -0
- package/public/verify.html +0 -410
- package/scripts/generate-favicons.js +0 -44
- package/scripts/generate-ico.js +0 -23
- package/scripts/generate-og-image.js +0 -45
- package/scripts/reset-db.ts +0 -77
- package/scripts/seed-db.ts +0 -71
- package/scripts/setup-benchmark-db.js +0 -70
- package/src/api/server.ts +0 -266
- package/src/cli/index.ts +0 -302
- package/src/compliance/compliance-generator.ts +0 -452
- package/src/compliance/index.ts +0 -28
- package/src/compliance/types.ts +0 -170
- package/src/db/index.ts +0 -28
- package/src/db/schema.ts +0 -84
- package/src/feed-analyzer/index.ts +0 -34
- package/src/feed-analyzer/types.ts +0 -354
- package/src/generator/key-generator.ts +0 -124
- package/src/generator/profile-builder.ts +0 -402
- package/src/index.ts +0 -105
- package/src/security/security-scanner.ts +0 -604
- package/src/security/types.ts +0 -55
- package/src/services/directory.ts +0 -434
- package/src/simulator/agent-simulator.ts +0 -941
- package/src/types/generator.ts +0 -140
- package/src/types/ucp-profile.ts +0 -140
- package/src/types/validation.ts +0 -89
- package/src/validator/index.ts +0 -194
- package/src/validator/network-validator.ts +0 -417
- package/src/validator/rules-validator.ts +0 -297
- package/src/validator/structural-validator.ts +0 -476
- package/tests/fixtures/non-compliant-profile.json +0 -25
- package/tests/fixtures/official-sample-profile.json +0 -75
- package/tests/integration/benchmark.test.ts +0 -207
- package/tests/integration/database.test.ts +0 -163
- package/tests/integration/directory-api.test.ts +0 -268
- package/tests/integration/simulate-api.test.ts +0 -230
- package/tests/integration/validate-api.test.ts +0 -269
- package/tests/setup.ts +0 -15
- package/tests/unit/agent-simulator.test.ts +0 -575
- package/tests/unit/compliance-generator.test.ts +0 -374
- package/tests/unit/directory-service.test.ts +0 -272
- package/tests/unit/feed-analyzer.test.ts +0 -517
- package/tests/unit/lint-suggestions.test.ts +0 -423
- package/tests/unit/official-samples.test.ts +0 -211
- package/tests/unit/pdf-report.test.ts +0 -390
- package/tests/unit/sdk-validator.test.ts +0 -531
- package/tests/unit/security-scanner.test.ts +0 -410
- package/tests/unit/validation.test.ts +0 -390
- package/tsconfig.json +0 -20
- package/vercel.json +0 -34
- package/vitest.config.ts +0 -22
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GDPR/Privacy Compliance Generator Module
|
|
3
|
+
* Generates privacy policy addendums and consent language for agentic commerce
|
|
4
|
+
*/
|
|
5
|
+
export { generateComplianceDocuments, getAvailableRegions, getLawfulBasisOptions, getAiPlatformOptions, } from './compliance-generator.js';
|
|
6
|
+
export type { ComplianceRegion, LawfulBasis, AgentPlatform, ComplianceGeneratorInput, ComplianceGeneratorOutput, ComplianceDocument, ComplianceSection, DataProcessor, } from './types.js';
|
|
7
|
+
export { AI_PLATFORM_PROCESSORS, REGION_NAMES, LAWFUL_BASIS_DESCRIPTIONS, } from './types.js';
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/compliance/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACL,2BAA2B,EAC3B,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,GACrB,MAAM,2BAA2B,CAAC;AAEnC,YAAY,EACV,gBAAgB,EAChB,WAAW,EACX,aAAa,EACb,wBAAwB,EACxB,yBAAyB,EACzB,kBAAkB,EAClB,iBAAiB,EACjB,aAAa,GACd,MAAM,YAAY,CAAC;AAEpB,OAAO,EACL,sBAAsB,EACtB,YAAY,EACZ,yBAAyB,GAC1B,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* GDPR/Privacy Compliance Generator Module
|
|
4
|
+
* Generates privacy policy addendums and consent language for agentic commerce
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.LAWFUL_BASIS_DESCRIPTIONS = exports.REGION_NAMES = exports.AI_PLATFORM_PROCESSORS = exports.getAiPlatformOptions = exports.getLawfulBasisOptions = exports.getAvailableRegions = exports.generateComplianceDocuments = void 0;
|
|
8
|
+
var compliance_generator_js_1 = require("./compliance-generator.js");
|
|
9
|
+
Object.defineProperty(exports, "generateComplianceDocuments", { enumerable: true, get: function () { return compliance_generator_js_1.generateComplianceDocuments; } });
|
|
10
|
+
Object.defineProperty(exports, "getAvailableRegions", { enumerable: true, get: function () { return compliance_generator_js_1.getAvailableRegions; } });
|
|
11
|
+
Object.defineProperty(exports, "getLawfulBasisOptions", { enumerable: true, get: function () { return compliance_generator_js_1.getLawfulBasisOptions; } });
|
|
12
|
+
Object.defineProperty(exports, "getAiPlatformOptions", { enumerable: true, get: function () { return compliance_generator_js_1.getAiPlatformOptions; } });
|
|
13
|
+
var types_js_1 = require("./types.js");
|
|
14
|
+
Object.defineProperty(exports, "AI_PLATFORM_PROCESSORS", { enumerable: true, get: function () { return types_js_1.AI_PLATFORM_PROCESSORS; } });
|
|
15
|
+
Object.defineProperty(exports, "REGION_NAMES", { enumerable: true, get: function () { return types_js_1.REGION_NAMES; } });
|
|
16
|
+
Object.defineProperty(exports, "LAWFUL_BASIS_DESCRIPTIONS", { enumerable: true, get: function () { return types_js_1.LAWFUL_BASIS_DESCRIPTIONS; } });
|
|
17
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/compliance/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,qEAKmC;AAJjC,sIAAA,2BAA2B,OAAA;AAC3B,8HAAA,mBAAmB,OAAA;AACnB,gIAAA,qBAAqB,OAAA;AACrB,+HAAA,oBAAoB,OAAA;AActB,uCAIoB;AAHlB,kHAAA,sBAAsB,OAAA;AACtB,wGAAA,YAAY,OAAA;AACZ,qHAAA,yBAAyB,OAAA"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GDPR/Privacy Compliance Templates
|
|
3
|
+
* Template content for privacy policy addendums and consent language
|
|
4
|
+
*/
|
|
5
|
+
import type { ComplianceRegion, LawfulBasis, DataProcessor } from './types.js';
|
|
6
|
+
/**
|
|
7
|
+
* Generate the AI Commerce privacy policy section
|
|
8
|
+
*/
|
|
9
|
+
export declare function generateAiCommerceSection(companyName: string, platforms: DataProcessor[], lawfulBasis: LawfulBasis, regions: ComplianceRegion[]): string;
|
|
10
|
+
/**
|
|
11
|
+
* Generate data processor disclosures
|
|
12
|
+
*/
|
|
13
|
+
export declare function generateProcessorDisclosures(processors: DataProcessor[], regions: ComplianceRegion[]): string;
|
|
14
|
+
/**
|
|
15
|
+
* Generate consent language for checkout
|
|
16
|
+
*/
|
|
17
|
+
export declare function generateConsentLanguage(companyName: string, lawfulBasis: LawfulBasis, includeMarketing: boolean): string;
|
|
18
|
+
/**
|
|
19
|
+
* Generate marketing opt-in text
|
|
20
|
+
*/
|
|
21
|
+
export declare function generateMarketingOptIn(companyName: string): string;
|
|
22
|
+
/**
|
|
23
|
+
* Generate data subject rights notice
|
|
24
|
+
*/
|
|
25
|
+
export declare function generateDataSubjectRights(companyName: string, contactEmail: string, dpoEmail: string | undefined, regions: ComplianceRegion[]): string;
|
|
26
|
+
/**
|
|
27
|
+
* Generate tracking/cookie notice for agent transactions
|
|
28
|
+
*/
|
|
29
|
+
export declare function generateTrackingNotice(companyName: string, regions: ComplianceRegion[]): string;
|
|
30
|
+
/**
|
|
31
|
+
* Generate the legal disclaimer
|
|
32
|
+
*/
|
|
33
|
+
export declare function generateDisclaimer(): string;
|
|
34
|
+
//# sourceMappingURL=templates.d.ts.map
|
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
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* GDPR/Privacy Compliance Templates
|
|
4
|
+
* Template content for privacy policy addendums and consent language
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.generateAiCommerceSection = generateAiCommerceSection;
|
|
8
|
+
exports.generateProcessorDisclosures = generateProcessorDisclosures;
|
|
9
|
+
exports.generateConsentLanguage = generateConsentLanguage;
|
|
10
|
+
exports.generateMarketingOptIn = generateMarketingOptIn;
|
|
11
|
+
exports.generateDataSubjectRights = generateDataSubjectRights;
|
|
12
|
+
exports.generateTrackingNotice = generateTrackingNotice;
|
|
13
|
+
exports.generateDisclaimer = generateDisclaimer;
|
|
14
|
+
const types_js_1 = require("./types.js");
|
|
15
|
+
/**
|
|
16
|
+
* Generate the AI Commerce privacy policy section
|
|
17
|
+
*/
|
|
18
|
+
function generateAiCommerceSection(companyName, platforms, lawfulBasis, regions) {
|
|
19
|
+
const basisInfo = types_js_1.LAWFUL_BASIS_DESCRIPTIONS[lawfulBasis];
|
|
20
|
+
const platformList = platforms.map(p => p.name).join(', ');
|
|
21
|
+
let section = `## AI-Powered Shopping and Agentic Commerce
|
|
22
22
|
|
|
23
23
|
### How We Use AI Shopping Agents
|
|
24
24
|
|
|
@@ -43,21 +43,19 @@ When you make a purchase through an AI shopping agent, we may collect:
|
|
|
43
43
|
- Payment confirmation (we do not receive full payment card details)
|
|
44
44
|
- Transaction identifiers for order tracking
|
|
45
45
|
- Communication preferences
|
|
46
|
-
`;
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
section += `
|
|
46
|
+
`;
|
|
47
|
+
if (regions.includes('eu') || regions.includes('uk')) {
|
|
48
|
+
section += `
|
|
50
49
|
### International Data Transfers
|
|
51
50
|
|
|
52
51
|
Some AI agent providers are based outside the European Economic Area (EEA) or United Kingdom. When your data is transferred to these providers, it is protected by:
|
|
53
52
|
- Standard Contractual Clauses (SCCs) approved by the European Commission
|
|
54
53
|
- The provider's certification under applicable data protection frameworks
|
|
55
54
|
- Additional technical and organizational security measures
|
|
56
|
-
`;
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
section += `
|
|
55
|
+
`;
|
|
56
|
+
}
|
|
57
|
+
if (regions.includes('california')) {
|
|
58
|
+
section += `
|
|
61
59
|
### California Privacy Rights (CCPA/CPRA)
|
|
62
60
|
|
|
63
61
|
California residents have additional rights regarding personal information collected through AI shopping agents:
|
|
@@ -67,60 +65,46 @@ California residents have additional rights regarding personal information colle
|
|
|
67
65
|
- **Right to Non-Discrimination**: We will not discriminate against you for exercising your privacy rights
|
|
68
66
|
|
|
69
67
|
To exercise these rights, contact us at the email address provided below.
|
|
70
|
-
`;
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
export function generateProcessorDisclosures(
|
|
80
|
-
processors: DataProcessor[],
|
|
81
|
-
regions: ComplianceRegion[]
|
|
82
|
-
): string {
|
|
83
|
-
let disclosure = `## Third-Party Data Processors (AI Commerce)
|
|
68
|
+
`;
|
|
69
|
+
}
|
|
70
|
+
return section;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Generate data processor disclosures
|
|
74
|
+
*/
|
|
75
|
+
function generateProcessorDisclosures(processors, regions) {
|
|
76
|
+
let disclosure = `## Third-Party Data Processors (AI Commerce)
|
|
84
77
|
|
|
85
78
|
We work with the following third-party service providers to enable AI-powered shopping:
|
|
86
79
|
|
|
87
80
|
| Provider | Purpose | Location | Privacy Policy |
|
|
88
81
|
|----------|---------|----------|----------------|
|
|
89
|
-
`;
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
disclosure += `
|
|
82
|
+
`;
|
|
83
|
+
for (const processor of processors) {
|
|
84
|
+
const privacyLink = processor.privacyPolicyUrl
|
|
85
|
+
? `[View Policy](${processor.privacyPolicyUrl})`
|
|
86
|
+
: 'Contact provider';
|
|
87
|
+
disclosure += `| ${processor.name} | ${processor.purpose} | ${processor.country || 'Various'} | ${privacyLink} |\n`;
|
|
88
|
+
}
|
|
89
|
+
disclosure += `
|
|
99
90
|
These processors are contractually bound to:
|
|
100
91
|
- Process data only on our documented instructions
|
|
101
92
|
- Ensure appropriate security measures are in place
|
|
102
93
|
- Assist us in responding to data subject requests
|
|
103
94
|
- Delete or return all personal data at the end of the service relationship
|
|
104
|
-
`;
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
disclosure += `
|
|
95
|
+
`;
|
|
96
|
+
if (regions.includes('eu') || regions.includes('uk')) {
|
|
97
|
+
disclosure += `
|
|
108
98
|
All processors have entered into Data Processing Agreements (DPAs) that comply with Article 28 of the GDPR.
|
|
109
|
-
`;
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
export function generateConsentLanguage(
|
|
119
|
-
companyName: string,
|
|
120
|
-
lawfulBasis: LawfulBasis,
|
|
121
|
-
includeMarketing: boolean
|
|
122
|
-
): string {
|
|
123
|
-
let consent = `## Consent Language for AI-Assisted Checkout
|
|
99
|
+
`;
|
|
100
|
+
}
|
|
101
|
+
return disclosure;
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Generate consent language for checkout
|
|
105
|
+
*/
|
|
106
|
+
function generateConsentLanguage(companyName, lawfulBasis, includeMarketing) {
|
|
107
|
+
let consent = `## Consent Language for AI-Assisted Checkout
|
|
124
108
|
|
|
125
109
|
Use the following language at checkout or in order confirmations:
|
|
126
110
|
|
|
@@ -130,18 +114,16 @@ Use the following language at checkout or in order confirmations:
|
|
|
130
114
|
> - Your order information will be processed by ${companyName} and the AI platform provider
|
|
131
115
|
> - We will use your data to fulfill your order, process payment, and provide customer support
|
|
132
116
|
> - Your data will be handled in accordance with our Privacy Policy
|
|
133
|
-
`;
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
consent += `
|
|
117
|
+
`;
|
|
118
|
+
if (lawfulBasis === 'consent') {
|
|
119
|
+
consent += `
|
|
137
120
|
### Explicit Consent (for consent-based processing)
|
|
138
121
|
|
|
139
122
|
> [ ] I consent to ${companyName} processing my personal data for the purpose of completing this purchase and providing related services. I understand I can withdraw my consent at any time.
|
|
140
|
-
`;
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
consent += `
|
|
123
|
+
`;
|
|
124
|
+
}
|
|
125
|
+
if (includeMarketing) {
|
|
126
|
+
consent += `
|
|
145
127
|
### Marketing Consent (Optional)
|
|
146
128
|
|
|
147
129
|
> [ ] I would like to receive marketing communications from ${companyName} about products, offers, and updates. I understand I can unsubscribe at any time.
|
|
@@ -150,23 +132,20 @@ Use the following language at checkout or in order confirmations:
|
|
|
150
132
|
- Freely given (not a condition of purchase)
|
|
151
133
|
- Specific and informed
|
|
152
134
|
- Indicated by clear affirmative action (pre-ticked boxes are not valid consent)
|
|
153
|
-
`;
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
consent += `
|
|
135
|
+
`;
|
|
136
|
+
}
|
|
137
|
+
consent += `
|
|
157
138
|
### Agent-Originated Orders Notice
|
|
158
139
|
|
|
159
140
|
> This order was initiated through an AI shopping assistant. The AI platform may retain conversation history in accordance with their privacy policy. Your transaction data with ${companyName} is subject to our Privacy Policy.
|
|
160
|
-
`;
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
export function generateMarketingOptIn(companyName: string): string {
|
|
169
|
-
return `## Marketing Opt-In for Agent-Acquired Customers
|
|
141
|
+
`;
|
|
142
|
+
return consent;
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Generate marketing opt-in text
|
|
146
|
+
*/
|
|
147
|
+
function generateMarketingOptIn(companyName) {
|
|
148
|
+
return `## Marketing Opt-In for Agent-Acquired Customers
|
|
170
149
|
|
|
171
150
|
For customers acquired through AI shopping agents, use the following opt-in language:
|
|
172
151
|
|
|
@@ -187,19 +166,13 @@ For customers who made purchases via AI agents without opting in, you may send O
|
|
|
187
166
|
> [Subscribe to Updates] [No Thanks]
|
|
188
167
|
|
|
189
168
|
**Important**: Do not add customers to marketing lists without explicit consent. Agent-originated orders do not imply marketing permission.
|
|
190
|
-
`;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
companyName: string,
|
|
198
|
-
contactEmail: string,
|
|
199
|
-
dpoEmail: string | undefined,
|
|
200
|
-
regions: ComplianceRegion[]
|
|
201
|
-
): string {
|
|
202
|
-
let rights = `## Your Data Rights (AI Commerce Transactions)
|
|
169
|
+
`;
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* Generate data subject rights notice
|
|
173
|
+
*/
|
|
174
|
+
function generateDataSubjectRights(companyName, contactEmail, dpoEmail, regions) {
|
|
175
|
+
let rights = `## Your Data Rights (AI Commerce Transactions)
|
|
203
176
|
|
|
204
177
|
You have the following rights regarding personal data collected through AI-assisted purchases:
|
|
205
178
|
|
|
@@ -214,31 +187,28 @@ You have the following rights regarding personal data collected through AI-assis
|
|
|
214
187
|
### Objection and Restriction
|
|
215
188
|
- Object to processing based on legitimate interests
|
|
216
189
|
- Request restriction of processing in certain circumstances
|
|
217
|
-
`;
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
rights += `
|
|
190
|
+
`;
|
|
191
|
+
if (regions.includes('eu') || regions.includes('uk')) {
|
|
192
|
+
rights += `
|
|
221
193
|
### GDPR-Specific Rights
|
|
222
194
|
- **Right to be Forgotten**: Request erasure under Article 17
|
|
223
195
|
- **Right to Restrict Processing**: Under Article 18
|
|
224
196
|
- **Right to Data Portability**: Under Article 20
|
|
225
197
|
- **Right to Object**: Under Article 21
|
|
226
198
|
- **Lodge a Complaint**: With your local data protection authority
|
|
227
|
-
`;
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
rights += `
|
|
199
|
+
`;
|
|
200
|
+
}
|
|
201
|
+
if (regions.includes('california')) {
|
|
202
|
+
rights += `
|
|
232
203
|
### CCPA/CPRA Rights
|
|
233
204
|
- **Right to Know**: Categories and specific pieces of personal information collected
|
|
234
205
|
- **Right to Delete**: Request deletion of personal information
|
|
235
206
|
- **Right to Correct**: Request correction of inaccurate information
|
|
236
207
|
- **Right to Opt-Out**: Of sale or sharing of personal information
|
|
237
208
|
- **Right to Limit Use**: Of sensitive personal information
|
|
238
|
-
`;
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
rights += `
|
|
209
|
+
`;
|
|
210
|
+
}
|
|
211
|
+
rights += `
|
|
242
212
|
### How to Exercise Your Rights
|
|
243
213
|
|
|
244
214
|
To exercise any of these rights, contact us:
|
|
@@ -255,19 +225,14 @@ To protect your privacy, we may need to verify your identity before processing y
|
|
|
255
225
|
- Order number or transaction ID
|
|
256
226
|
- Email address used for the order
|
|
257
227
|
- Delivery address associated with the order
|
|
258
|
-
`;
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
export function generateTrackingNotice(
|
|
267
|
-
companyName: string,
|
|
268
|
-
regions: ComplianceRegion[]
|
|
269
|
-
): string {
|
|
270
|
-
let notice = `## Tracking and Cookies for AI Agent Transactions
|
|
228
|
+
`;
|
|
229
|
+
return rights;
|
|
230
|
+
}
|
|
231
|
+
/**
|
|
232
|
+
* Generate tracking/cookie notice for agent transactions
|
|
233
|
+
*/
|
|
234
|
+
function generateTrackingNotice(companyName, regions) {
|
|
235
|
+
let notice = `## Tracking and Cookies for AI Agent Transactions
|
|
271
236
|
|
|
272
237
|
### How Tracking Works with AI Agents
|
|
273
238
|
|
|
@@ -288,10 +253,9 @@ For AI agent transactions, we collect data through:
|
|
|
288
253
|
- We do **not** place cookies on your device through AI agent transactions
|
|
289
254
|
- We do **not** build behavioral profiles based solely on AI agent purchases
|
|
290
255
|
- We **do** collect necessary transaction data to fulfill your order
|
|
291
|
-
`;
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
notice += `
|
|
256
|
+
`;
|
|
257
|
+
if (regions.includes('eu') || regions.includes('uk')) {
|
|
258
|
+
notice += `
|
|
295
259
|
### ePrivacy Compliance
|
|
296
260
|
|
|
297
261
|
AI agent transactions are processed under:
|
|
@@ -299,10 +263,9 @@ AI agent transactions are processed under:
|
|
|
299
263
|
- **Contract Performance**: Data processing necessary to deliver your order
|
|
300
264
|
|
|
301
265
|
No consent is required for strictly necessary processing of transaction data.
|
|
302
|
-
`;
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
notice += `
|
|
266
|
+
`;
|
|
267
|
+
}
|
|
268
|
+
notice += `
|
|
306
269
|
### AI Platform Tracking
|
|
307
270
|
|
|
308
271
|
The AI shopping agent (ChatGPT, Google AI, Copilot) may have its own data collection practices. Please review their privacy policies:
|
|
@@ -311,16 +274,14 @@ The AI shopping agent (ChatGPT, Google AI, Copilot) may have its own data collec
|
|
|
311
274
|
- Account information you've provided to the AI service
|
|
312
275
|
|
|
313
276
|
${companyName} is not responsible for data collected directly by AI platform providers.
|
|
314
|
-
`;
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
export function generateDisclaimer(): string {
|
|
323
|
-
return `---
|
|
277
|
+
`;
|
|
278
|
+
return notice;
|
|
279
|
+
}
|
|
280
|
+
/**
|
|
281
|
+
* Generate the legal disclaimer
|
|
282
|
+
*/
|
|
283
|
+
function generateDisclaimer() {
|
|
284
|
+
return `---
|
|
324
285
|
|
|
325
286
|
**IMPORTANT DISCLAIMER**
|
|
326
287
|
|
|
@@ -334,5 +295,6 @@ This document was generated by an automated tool and is provided for information
|
|
|
334
295
|
We recommend consulting with a privacy lawyer or data protection specialist to ensure your privacy policy fully complies with applicable laws.
|
|
335
296
|
|
|
336
297
|
Generated by [UCP.tools](https://ucptools.dev) - AI Commerce Readiness Platform
|
|
337
|
-
`;
|
|
338
|
-
}
|
|
298
|
+
`;
|
|
299
|
+
}
|
|
300
|
+
//# sourceMappingURL=templates.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"templates.js","sourceRoot":"","sources":["../../src/compliance/templates.ts"],"names":[],"mappings":";AAAA;;;GAGG;;AAQH,8DA8DC;AAKD,oEAkCC;AAKD,0DA6CC;AAKD,wDAuBC;AAKD,8DAiEC;AAKD,wDAmDC;AAKD,gDAgBC;AA3UD,yCAA+E;AAE/E;;GAEG;AACH,SAAgB,yBAAyB,CACvC,WAAmB,EACnB,SAA0B,EAC1B,WAAwB,EACxB,OAA2B;IAE3B,MAAM,SAAS,GAAG,oCAAyB,CAAC,WAAW,CAAC,CAAC;IACzD,MAAM,YAAY,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAE3D,IAAI,OAAO,GAAG;;;;EAId,WAAW,gJAAgJ,YAAY;;;;;;;;;iFASxF,SAAS,CAAC,KAAK,OAAO,SAAS,CAAC,WAAW;;EAE1H,SAAS,CAAC,WAAW;;;;;;;;;;CAUtB,CAAC;IAEA,IAAI,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC;QACrD,OAAO,IAAI;;;;;;;CAOd,CAAC;IACA,CAAC;IAED,IAAI,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,EAAE,CAAC;QACnC,OAAO,IAAI;;;;;;;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AChC,OAAO;;;;;;;;;IASL,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;;;;;CAK3B,CAAC;AACF,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GDPR/Privacy Compliance Generator Types
|
|
3
|
+
* Types for generating privacy policy addendums and consent language
|
|
4
|
+
*/
|
|
5
|
+
export type ComplianceRegion = 'eu' | 'uk' | 'california' | 'global';
|
|
6
|
+
export type LawfulBasis = 'contract' | 'consent' | 'legitimate' | 'legal';
|
|
7
|
+
export type AgentPlatform = 'openai' | 'google' | 'microsoft' | 'other';
|
|
8
|
+
export interface ComplianceGeneratorInput {
|
|
9
|
+
companyName: string;
|
|
10
|
+
companyEmail?: string;
|
|
11
|
+
companyAddress?: string;
|
|
12
|
+
dpoEmail?: string;
|
|
13
|
+
regions: ComplianceRegion[];
|
|
14
|
+
platforms: AgentPlatform[];
|
|
15
|
+
lawfulBasis: LawfulBasis;
|
|
16
|
+
includeMarketingConsent?: boolean;
|
|
17
|
+
includeDataRetention?: boolean;
|
|
18
|
+
retentionPeriodYears?: number;
|
|
19
|
+
additionalProcessors?: DataProcessor[];
|
|
20
|
+
}
|
|
21
|
+
export interface DataProcessor {
|
|
22
|
+
name: string;
|
|
23
|
+
purpose: string;
|
|
24
|
+
country?: string;
|
|
25
|
+
privacyPolicyUrl?: string;
|
|
26
|
+
}
|
|
27
|
+
export interface ComplianceDocument {
|
|
28
|
+
title: string;
|
|
29
|
+
sections: ComplianceSection[];
|
|
30
|
+
disclaimer: string;
|
|
31
|
+
generatedAt: string;
|
|
32
|
+
regions: ComplianceRegion[];
|
|
33
|
+
}
|
|
34
|
+
export interface ComplianceSection {
|
|
35
|
+
id: string;
|
|
36
|
+
title: string;
|
|
37
|
+
content: string;
|
|
38
|
+
required: boolean;
|
|
39
|
+
applicableRegions: ComplianceRegion[];
|
|
40
|
+
}
|
|
41
|
+
export interface ComplianceGeneratorOutput {
|
|
42
|
+
privacyAddendum: ComplianceDocument;
|
|
43
|
+
snippets: {
|
|
44
|
+
aiCommerceSection: string;
|
|
45
|
+
processorDisclosures: string;
|
|
46
|
+
consentLanguage: string;
|
|
47
|
+
marketingOptIn?: string;
|
|
48
|
+
dataSubjectRights: string;
|
|
49
|
+
trackingNotice: string;
|
|
50
|
+
};
|
|
51
|
+
embedHtml: string;
|
|
52
|
+
plainText: string;
|
|
53
|
+
generatedAt: string;
|
|
54
|
+
lawfulBasis: LawfulBasis;
|
|
55
|
+
regions: ComplianceRegion[];
|
|
56
|
+
}
|
|
57
|
+
export declare const AI_PLATFORM_PROCESSORS: Record<AgentPlatform, DataProcessor>;
|
|
58
|
+
export declare const REGION_NAMES: Record<ComplianceRegion, string>;
|
|
59
|
+
export declare const LAWFUL_BASIS_DESCRIPTIONS: Record<LawfulBasis, {
|
|
60
|
+
title: string;
|
|
61
|
+
description: string;
|
|
62
|
+
gdprArticle: string;
|
|
63
|
+
}>;
|
|
64
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/compliance/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,MAAM,MAAM,gBAAgB,GAAG,IAAI,GAAG,IAAI,GAAG,YAAY,GAAG,QAAQ,CAAC;AAGrE,MAAM,MAAM,WAAW,GACnB,UAAU,GACV,SAAS,GACT,YAAY,GACZ,OAAO,CAAC;AAGZ,MAAM,MAAM,aAAa,GACrB,QAAQ,GACR,QAAQ,GACR,WAAW,GACX,OAAO,CAAC;AAGZ,MAAM,WAAW,wBAAwB;IAEvC,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAGlB,OAAO,EAAE,gBAAgB,EAAE,CAAC;IAG5B,SAAS,EAAE,aAAa,EAAE,CAAC;IAG3B,WAAW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B,EAAE,MAAM,CAAC,aAAa,EAAE,aAAa,CAwBvE,CAAC;AAGF,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,gBAAgB,EAAE,MAAM,CAKzD,CAAC;AAGF,eAAO,MAAM,yBAAyB,EAAE,MAAM,CAAC,WAAW,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,MAAM,CAAA;CAAE,CAqBtH,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* GDPR/Privacy Compliance Generator Types
|
|
4
|
+
* Types for generating privacy policy addendums and consent language
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.LAWFUL_BASIS_DESCRIPTIONS = exports.REGION_NAMES = exports.AI_PLATFORM_PROCESSORS = void 0;
|
|
8
|
+
// Predefined data processors for AI platforms
|
|
9
|
+
exports.AI_PLATFORM_PROCESSORS = {
|
|
10
|
+
openai: {
|
|
11
|
+
name: 'OpenAI, LLC',
|
|
12
|
+
purpose: 'AI-powered shopping assistant and checkout processing',
|
|
13
|
+
country: 'United States',
|
|
14
|
+
privacyPolicyUrl: 'https://openai.com/privacy/',
|
|
15
|
+
},
|
|
16
|
+
google: {
|
|
17
|
+
name: 'Google LLC',
|
|
18
|
+
purpose: 'AI shopping agent (Google AI Mode, Gemini) and checkout processing',
|
|
19
|
+
country: 'United States',
|
|
20
|
+
privacyPolicyUrl: 'https://policies.google.com/privacy',
|
|
21
|
+
},
|
|
22
|
+
microsoft: {
|
|
23
|
+
name: 'Microsoft Corporation',
|
|
24
|
+
purpose: 'AI shopping assistant (Copilot) and checkout processing',
|
|
25
|
+
country: 'United States',
|
|
26
|
+
privacyPolicyUrl: 'https://privacy.microsoft.com/privacystatement',
|
|
27
|
+
},
|
|
28
|
+
other: {
|
|
29
|
+
name: 'Third-party AI Agent Provider',
|
|
30
|
+
purpose: 'AI-powered shopping and checkout assistance',
|
|
31
|
+
country: 'Various',
|
|
32
|
+
},
|
|
33
|
+
};
|
|
34
|
+
// Region display names
|
|
35
|
+
exports.REGION_NAMES = {
|
|
36
|
+
eu: 'European Union (GDPR)',
|
|
37
|
+
uk: 'United Kingdom (UK GDPR)',
|
|
38
|
+
california: 'California (CCPA/CPRA)',
|
|
39
|
+
global: 'Global (General Best Practices)',
|
|
40
|
+
};
|
|
41
|
+
// Lawful basis descriptions
|
|
42
|
+
exports.LAWFUL_BASIS_DESCRIPTIONS = {
|
|
43
|
+
contract: {
|
|
44
|
+
title: 'Performance of a Contract',
|
|
45
|
+
description: 'Processing is necessary for the performance of a contract with the data subject or to take steps at their request prior to entering into a contract.',
|
|
46
|
+
gdprArticle: 'Article 6(1)(b)',
|
|
47
|
+
},
|
|
48
|
+
consent: {
|
|
49
|
+
title: 'Consent',
|
|
50
|
+
description: 'The data subject has given consent to the processing of their personal data for one or more specific purposes.',
|
|
51
|
+
gdprArticle: 'Article 6(1)(a)',
|
|
52
|
+
},
|
|
53
|
+
legitimate: {
|
|
54
|
+
title: 'Legitimate Interests',
|
|
55
|
+
description: 'Processing is necessary for the purposes of the legitimate interests pursued by the controller or by a third party.',
|
|
56
|
+
gdprArticle: 'Article 6(1)(f)',
|
|
57
|
+
},
|
|
58
|
+
legal: {
|
|
59
|
+
title: 'Legal Obligation',
|
|
60
|
+
description: 'Processing is necessary for compliance with a legal obligation to which the controller is subject.',
|
|
61
|
+
gdprArticle: 'Article 6(1)(c)',
|
|
62
|
+
},
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/compliance/types.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AA6GH,8CAA8C;AACjC,QAAA,sBAAsB,GAAyC;IAC1E,MAAM,EAAE;QACN,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,uDAAuD;QAChE,OAAO,EAAE,eAAe;QACxB,gBAAgB,EAAE,6BAA6B;KAChD;IACD,MAAM,EAAE;QACN,IAAI,EAAE,YAAY;QAClB,OAAO,EAAE,oEAAoE;QAC7E,OAAO,EAAE,eAAe;QACxB,gBAAgB,EAAE,qCAAqC;KACxD;IACD,SAAS,EAAE;QACT,IAAI,EAAE,uBAAuB;QAC7B,OAAO,EAAE,yDAAyD;QAClE,OAAO,EAAE,eAAe;QACxB,gBAAgB,EAAE,gDAAgD;KACnE;IACD,KAAK,EAAE;QACL,IAAI,EAAE,+BAA+B;QACrC,OAAO,EAAE,6CAA6C;QACtD,OAAO,EAAE,SAAS;KACnB;CACF,CAAC;AAEF,uBAAuB;AACV,QAAA,YAAY,GAAqC;IAC5D,EAAE,EAAE,uBAAuB;IAC3B,EAAE,EAAE,0BAA0B;IAC9B,UAAU,EAAE,wBAAwB;IACpC,MAAM,EAAE,iCAAiC;CAC1C,CAAC;AAEF,4BAA4B;AACf,QAAA,yBAAyB,GAAqF;IACzH,QAAQ,EAAE;QACR,KAAK,EAAE,2BAA2B;QAClC,WAAW,EAAE,sJAAsJ;QACnK,WAAW,EAAE,iBAAiB;KAC/B;IACD,OAAO,EAAE;QACP,KAAK,EAAE,SAAS;QAChB,WAAW,EAAE,gHAAgH;QAC7H,WAAW,EAAE,iBAAiB;KAC/B;IACD,UAAU,EAAE;QACV,KAAK,EAAE,sBAAsB;QAC7B,WAAW,EAAE,qHAAqH;QAClI,WAAW,EAAE,iBAAiB;KAC/B;IACD,KAAK,EAAE;QACL,KAAK,EAAE,kBAAkB;QACzB,WAAW,EAAE,oGAAoG;QACjH,WAAW,EAAE,iBAAiB;KAC/B;CACF,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { NodePgDatabase } from 'drizzle-orm/node-postgres';
|
|
2
|
+
import * as schema from './schema.js';
|
|
3
|
+
type Database = NodePgDatabase<typeof schema>;
|
|
4
|
+
/**
|
|
5
|
+
* Get the Drizzle database instance.
|
|
6
|
+
* Lazily creates the connection on first use.
|
|
7
|
+
*/
|
|
8
|
+
export declare function getDb(): Database;
|
|
9
|
+
/**
|
|
10
|
+
* Close database connection pool.
|
|
11
|
+
* Call this when shutting down the server.
|
|
12
|
+
*/
|
|
13
|
+
export declare function closeDb(): Promise<void>;
|
|
14
|
+
export * from './schema.js';
|
|
15
|
+
export { schema };
|
|
16
|
+
export * from './utils.js';
|
|
17
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/db/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAW,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAEpE,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AAGtC,KAAK,QAAQ,GAAG,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC;AAM9C;;;GAGG;AACH,wBAAgB,KAAK,IAAI,QAAQ,CAWhC;AAED;;;GAGG;AACH,wBAAsB,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAM7C;AAGD,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,MAAM,EAAE,CAAC;AAGlB,cAAc,YAAY,CAAC"}
|