tadforce 0.0.0-stage → 0.3.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.
Files changed (141) hide show
  1. package/.claude-plugin/marketplace.json +20 -0
  2. package/.claude-plugin/plugin.json +13 -0
  3. package/LICENSE +202 -0
  4. package/NOTICE +11 -0
  5. package/README.md +266 -2
  6. package/assets/logo-mark.svg +24 -0
  7. package/assets/logo.svg +31 -0
  8. package/bin/tadforce.js +4 -0
  9. package/commands/tadforce-review.md +8 -0
  10. package/commands/tadforce-update.md +6 -0
  11. package/commands/tadforce.md +10 -0
  12. package/package.json +60 -4
  13. package/skills/tadforce/SKILL.md +73 -0
  14. package/skills/tadforce/references/axes-rules.md +29 -0
  15. package/skills/tadforce/references/evidence-rules.md +40 -0
  16. package/skills/tadforce/references/exclusion-heuristics.md +40 -0
  17. package/skills/tadforce/references/figure-rules.md +42 -0
  18. package/skills/tadforce/references/markdown-conventions.md +67 -0
  19. package/skills/tadforce/references/modules/agentforce-ai.md +24 -0
  20. package/skills/tadforce/references/modules/analytics.md +19 -0
  21. package/skills/tadforce/references/modules/commerce.md +25 -0
  22. package/skills/tadforce/references/modules/data-cloud.md +23 -0
  23. package/skills/tadforce/references/modules/experience-cloud.md +24 -0
  24. package/skills/tadforce/references/modules/field-service.md +25 -0
  25. package/skills/tadforce/references/modules/industries.md +21 -0
  26. package/skills/tadforce/references/modules/integration-platforms.md +19 -0
  27. package/skills/tadforce/references/modules/marketing.md +24 -0
  28. package/skills/tadforce/references/modules/omnistudio.md +24 -0
  29. package/skills/tadforce/references/modules/platform-events.md +19 -0
  30. package/skills/tadforce/references/modules/revenue-cpq.md +25 -0
  31. package/skills/tadforce/references/modules/sales-cloud.md +26 -0
  32. package/skills/tadforce/references/modules/security-shield.md +18 -0
  33. package/skills/tadforce/references/modules/service-cloud.md +27 -0
  34. package/skills/tadforce/references/naming-external-systems.md +32 -0
  35. package/skills/tadforce/references/questions.md +59 -0
  36. package/skills/tadforce/references/salesforce-skills.md +27 -0
  37. package/skills/tadforce/references/workflow.md +95 -0
  38. package/skills/tadforce/references/writing-rules.md +47 -0
  39. package/skills/tadforce-review/SKILL.md +53 -0
  40. package/skills/tadforce-update/SKILL.md +48 -0
  41. package/src/build/brand.js +107 -0
  42. package/src/build/browser.js +70 -0
  43. package/src/build/directives.js +293 -0
  44. package/src/build/export.js +60 -0
  45. package/src/build/figures.js +119 -0
  46. package/src/build/mermaid.js +107 -0
  47. package/src/build/render.js +299 -0
  48. package/src/build/serve.js +59 -0
  49. package/src/cli.js +68 -0
  50. package/src/commands/docs.js +204 -0
  51. package/src/commands/doctor.js +370 -0
  52. package/src/commands/init.js +132 -0
  53. package/src/commands/org.js +151 -0
  54. package/src/commands/review.js +35 -0
  55. package/src/commands/spec.js +91 -0
  56. package/src/commands/update.js +154 -0
  57. package/src/facts/extractors/apex.js +111 -0
  58. package/src/facts/extractors/automation.js +85 -0
  59. package/src/facts/extractors/data.js +94 -0
  60. package/src/facts/extractors/integration.js +76 -0
  61. package/src/facts/extractors/misc.js +100 -0
  62. package/src/facts/extractors/security.js +92 -0
  63. package/src/facts/extractors/ui.js +120 -0
  64. package/src/facts/fingerprints.js +32 -0
  65. package/src/facts/heuristics/exclusions.js +143 -0
  66. package/src/facts/heuristics/modules.js +85 -0
  67. package/src/facts/heuristics/naming.js +31 -0
  68. package/src/facts/heuristics/signals.js +76 -0
  69. package/src/facts/index.js +197 -0
  70. package/src/facts/org.js +87 -0
  71. package/src/facts/xml.js +85 -0
  72. package/src/sf/sf.js +120 -0
  73. package/src/util/args.js +21 -0
  74. package/src/util/config.js +104 -0
  75. package/src/util/fsx.js +58 -0
  76. package/src/util/i18n.js +49 -0
  77. package/src/util/log.js +31 -0
  78. package/src/util/paths.js +11 -0
  79. package/src/validate/index.js +126 -0
  80. package/templates/axes/en/00-document-control.md +3 -0
  81. package/templates/axes/en/01-summary.md +7 -0
  82. package/templates/axes/en/02-method.md +9 -0
  83. package/templates/axes/en/03-findings.md +19 -0
  84. package/templates/axes/en/04-register.md +3 -0
  85. package/templates/axes/en/05-roadmap.md +3 -0
  86. package/templates/axes/en/99-appendix.md +5 -0
  87. package/templates/axes/fr/00-document-control.md +3 -0
  88. package/templates/axes/fr/01-summary.md +7 -0
  89. package/templates/axes/fr/02-method.md +9 -0
  90. package/templates/axes/fr/03-findings.md +19 -0
  91. package/templates/axes/fr/04-register.md +3 -0
  92. package/templates/axes/fr/05-roadmap.md +3 -0
  93. package/templates/axes/fr/99-appendix.md +5 -0
  94. package/templates/html/cover.html +12 -0
  95. package/templates/html/editor.js +502 -0
  96. package/templates/html/style.css +255 -0
  97. package/templates/html/template.html +88 -0
  98. package/templates/i18n/en.json +366 -0
  99. package/templates/i18n/fr.json +366 -0
  100. package/templates/manifest/package-tad.xml +543 -0
  101. package/templates/specs/sections.yml +494 -0
  102. package/templates/tad/en/00-document-control.md +7 -0
  103. package/templates/tad/en/01-summary.md +17 -0
  104. package/templates/tad/en/02-purpose.md +35 -0
  105. package/templates/tad/en/03-context.md +17 -0
  106. package/templates/tad/en/04-general.md +29 -0
  107. package/templates/tad/en/05-functional.md +7 -0
  108. package/templates/tad/en/06-data.md +71 -0
  109. package/templates/tad/en/07-application.md +49 -0
  110. package/templates/tad/en/08-ui.md +41 -0
  111. package/templates/tad/en/09-integrations.md +53 -0
  112. package/templates/tad/en/10-security.md +59 -0
  113. package/templates/tad/en/11-reporting.md +13 -0
  114. package/templates/tad/en/12-operations.md +25 -0
  115. package/templates/tad/en/13-nfr.md +9 -0
  116. package/templates/tad/en/14-decisions.md +3 -0
  117. package/templates/tad/en/15-outlook.md +3 -0
  118. package/templates/tad/en/99-appendices.md +119 -0
  119. package/templates/tad/fr/00-document-control.md +7 -0
  120. package/templates/tad/fr/01-summary.md +17 -0
  121. package/templates/tad/fr/02-purpose.md +35 -0
  122. package/templates/tad/fr/03-context.md +17 -0
  123. package/templates/tad/fr/04-general.md +29 -0
  124. package/templates/tad/fr/05-functional.md +7 -0
  125. package/templates/tad/fr/06-data.md +71 -0
  126. package/templates/tad/fr/07-application.md +49 -0
  127. package/templates/tad/fr/08-ui.md +41 -0
  128. package/templates/tad/fr/09-integrations.md +53 -0
  129. package/templates/tad/fr/10-security.md +59 -0
  130. package/templates/tad/fr/11-reporting.md +13 -0
  131. package/templates/tad/fr/12-operations.md +25 -0
  132. package/templates/tad/fr/13-nfr.md +9 -0
  133. package/templates/tad/fr/14-decisions.md +3 -0
  134. package/templates/tad/fr/15-outlook.md +3 -0
  135. package/templates/tad/fr/99-appendices.md +119 -0
  136. package/templates/vendor/LICENSE-html-docx-js.txt +21 -0
  137. package/templates/vendor/LICENSE-html2canvas.txt +22 -0
  138. package/templates/vendor/LICENSE-mermaid.txt +21 -0
  139. package/templates/vendor/html-docx.js +13216 -0
  140. package/templates/vendor/html2canvas.min.js +20 -0
  141. package/templates/vendor/mermaid.min.js +2314 -0
@@ -0,0 +1,494 @@
1
+ # TADForce section specifications.
2
+ # One entry per `<!-- tad:pending <id> -->` marker of the skeletons. The agent replaces the marker with
3
+ # content that satisfies the spec. Specs are written in English; the content is written in the
4
+ # document language (tadforce.config.json > language).
5
+ #
6
+ # intent what the reader must understand after reading the section
7
+ # facts facts.json paths to read first (use {{n:...}} placeholders for every count)
8
+ # modules skills/tadforce/references/modules/*.md files to read when the module is detected
9
+ # must elements that must appear
10
+ # never what must not appear (debt goes to the Improvement Axes document, not to the client TAD)
11
+ # figure expected figure, if any (see skills/tadforce/references/figure-rules.md)
12
+ # length indicative size
13
+ version: 1
14
+
15
+ requiredAnchors:
16
+ tad: [doc-control, ch-summary, ch-purpose, method, ch-context, ch-general, general-context, ch-functional, ch-data, data-overview, ch-application, ch-ui, ch-integration, ch-security, sec-sharing, ch-reporting, ch-operations, ch-nfr, ch-decisions, ch-outlook, appendices, annex-apex, annex-automation, annex-objects, annex-apps, annex-lwc, annex-security, annex-integration, annex-glossary]
17
+ axes: [doc-control, ax-summary, ax-method, ax-findings, ax-register, ax-roadmap]
18
+
19
+ sections:
20
+ # ------------------------------------------------------------------ 1 Executive summary
21
+ summary.overview:
22
+ doc: tad
23
+ intent: "In one screen: what the platform is, who uses it and on which Salesforce products it stands."
24
+ facts: [ui.apps, modules.clouds, counts]
25
+ must:
26
+ - "Name the solution and its role in the client's information system (system of engagement, service desk, commerce front-office, partner portal...)."
27
+ - "The user populations and the application each one uses (from ui.apps and glossary.actors)."
28
+ - "The 2 to 5 Salesforce products actually used (modules.clouds), one line each on what they bring to this client."
29
+ never:
30
+ - "Counts written as raw numbers (the KPI tiles below carry them)."
31
+ - "Defects, risks or roadmap items."
32
+ length: "2 short paragraphs and 2 bullet lists."
33
+ summary.capabilities:
34
+ doc: tad
35
+ intent: "The business capabilities covered, grouped by domain."
36
+ facts: [ui.apps, data.objects, automation.flows, systems]
37
+ must:
38
+ - "Table 'Domain | Main capabilities' with 5 to 9 rows, each row grounded on components that exist."
39
+ never:
40
+ - "Capabilities that no component supports."
41
+ - "Decommissioned features (knowledge/exclusions.yml > features)."
42
+ summary.achievements:
43
+ doc: tad
44
+ intent: "The 4 to 6 achievements that make this implementation remarkable: what the integrator built, not what Salesforce provides."
45
+ facts: [apex.classes, data.cmdtTypes, automation, security.permissionSetGroups, integration]
46
+ must:
47
+ - "Raw HTML block <div class=\"cards\"> with one <div class=\"card\"><h4>Title</h4><p>2 to 4 sentences</p></div> per achievement."
48
+ - "Each card names the mechanism and its key component in code font, and says why it matters (configurable without code, scales, secure by design...)."
49
+ never:
50
+ - "Marketing superlatives."
51
+ - "Anything not visible in the metadata or in the inputs."
52
+ summary.principles:
53
+ doc: tad
54
+ intent: "The architecture principles actually applied, as a numbered list of 4 to 7 items."
55
+ facts: [modules, counts.apex, data.cmdtTypes, integration.namedCredentials]
56
+ must:
57
+ - "Each principle in bold followed by one sentence of evidence (example: 'Configuration in Custom Metadata: scoring rules and thresholds are records, not code')."
58
+
59
+ # ------------------------------------------------------------------ 2 Purpose, scope, references
60
+ purpose.object:
61
+ doc: tad
62
+ intent: "Why this document exists and who reads it."
63
+ must:
64
+ - "Purposes: shared understanding, run and maintenance, evolutions, architecture and security reviews, knowledge transfer."
65
+ - "Audience list (architects, application owners, operations, security, developers)."
66
+ length: "1 paragraph and 1 list."
67
+ purpose.scope:
68
+ doc: tad
69
+ intent: "What is in and out of scope."
70
+ must:
71
+ - "Two-column table 'Included | Excluded'."
72
+ - "Excluded column names the internals of external systems, package internals, business data, and CI/CD administration when the client owns it."
73
+ purpose.references:
74
+ doc: tad
75
+ intent: "Documents used as inputs."
76
+ facts: [knowledge/inputs]
77
+ must:
78
+ - "Table 'Ref. | Document | Purpose' with DR-01, DR-02... identifiers."
79
+ - "Include the official Salesforce documentation relied on (Well-Architected, Integration Patterns, product documentation)."
80
+ never:
81
+ - "Documents that were not provided."
82
+
83
+ # ------------------------------------------------------------------ 3 Context
84
+ context.drivers:
85
+ doc: tad
86
+ intent: "The business drivers that justify the platform."
87
+ must:
88
+ - "3 to 6 bullets, each a business outcome (not a feature)."
89
+ never:
90
+ - "Invented figures."
91
+ context.actors:
92
+ doc: tad
93
+ intent: "Who uses the platform and through which application."
94
+ facts: [ui.apps, security.permissionSetGroups, security.profiles, org.usersByProfile, org.usersByLicense]
95
+ must:
96
+ - "Table 'Population | Application | Main activities'. Users per population only when org facts exist."
97
+ - "External populations (customers, partners, citizens) when Experience Cloud or a mobile app exists."
98
+ context.scope:
99
+ doc: tad
100
+ intent: "Functional perimeter in one table."
101
+ must:
102
+ - "Table 'Domain | Covered by' linking to the chapter 5 sections with {{ref:...}} placeholders."
103
+
104
+ # ------------------------------------------------------------------ 4 General architecture
105
+ general.context:
106
+ doc: tad
107
+ intent: "Explain the context view above."
108
+ facts: [systems, integration, ui.apps]
109
+ must:
110
+ - "One paragraph per side of the figure (users, Salesforce, connected systems)."
111
+ - "External systems named exactly as in glossary.systems."
112
+ never:
113
+ - "System names not confirmed in the glossary."
114
+ general.products:
115
+ doc: tad
116
+ intent: "What each Salesforce product, industry cloud or package is used for in this org."
117
+ facts: [modules.clouds, namespaces, org.packages]
118
+ modules: [all detected]
119
+ must:
120
+ - "Table 'Product | Use in the solution', one row per entry of modules.clouds that is really used."
121
+ - "A 'standard first' statement: what is standard, what is specific."
122
+ general.layers:
123
+ doc: tad
124
+ intent: "Explain the layered view and the responsibility of each layer."
125
+ must:
126
+ - "Table 'Layer | Components | Responsibility' (Presentation, Orchestration, Apex services, Data, Integration)."
127
+ general.principles:
128
+ doc: tad
129
+ intent: "Design principles with their concrete application."
130
+ must:
131
+ - "4 to 8 bullets 'principle: how it is applied' (standard first, configuration over code, bulk-safe, secure server-side...)."
132
+ general.naming:
133
+ doc: tad
134
+ intent: "Naming conventions observed in the metadata (table above) and their meaning."
135
+ facts: [naming]
136
+ must:
137
+ - "Interpret the prefixes and suffixes (example: '*TriggerHandler', 'lwcNNN_')."
138
+ - "Where the convention is not followed, state it as a neutral fact."
139
+
140
+ # ------------------------------------------------------------------ 5 Functional
141
+ functional.domains:
142
+ doc: tad
143
+ intent: "Map of the functional domains and where each one is described."
144
+ must:
145
+ - "A Mermaid flowchart of domains (classes actor, sf, ext, data) followed by a Figure caption, or a table 'Domain | Objects | Main components | Section'."
146
+ figure: "flowchart LR of the domains."
147
+ functional.processes:
148
+ doc: tad
149
+ intent: "One '##' section per business domain, describing the business process as implemented."
150
+ facts: [data.objects, automation.flows, apex.classes, ui.lwc, automation.omnistudio]
151
+ modules: [all detected]
152
+ must:
153
+ - "Write one '## <Domain> {#fn-<slug>}' section per domain (typically 5 to 10)."
154
+ - "For each domain: what the user does, what the platform does (components in code font), statuses and transitions, notifications."
155
+ - "Cloud-specific processes follow the module reference (case management for Service Cloud, quote-to-cash for CPQ/Revenue, appointment lifecycle for Field Service, checkout for Commerce...)."
156
+ - "A sequence or state diagram when the process has branches or asynchronous steps (only observed calls)."
157
+ - "Optional '> [!INTEGRATOR]' callout for a notable design choice of the integrator."
158
+ never:
159
+ - "Decommissioned features."
160
+ - "Screens or steps not evidenced by metadata or inputs."
161
+
162
+ # ------------------------------------------------------------------ 6 Data
163
+ data.principles:
164
+ doc: tad
165
+ intent: "Modeling choices."
166
+ facts: [data.objects, namespaces, modules.clouds]
167
+ must:
168
+ - "Standard and industry objects first, custom objects for specific needs only."
169
+ - "Lookup versus master-detail policy, external IDs for integrations, configuration in Custom Metadata."
170
+ data.overview:
171
+ doc: tad
172
+ intent: "Explain the overview ERD generated above."
173
+ must:
174
+ - "The central objects and how the domains hang off them (1 to 2 paragraphs)."
175
+ never:
176
+ - "Relationships that are not Lookup or Master-Detail fields."
177
+ data.domains:
178
+ doc: tad
179
+ intent: "One '###' per data domain with its ERD and an object table."
180
+ facts: [data.objects]
181
+ must:
182
+ - "'### <Domain>' then '@@ERD:Obj1,Obj2,Obj3|<caption>@@' (4 to 9 objects) then a table 'Object | Role | Key fields'."
183
+ - "Only objects of the inventory."
184
+ data.industry:
185
+ doc: tad
186
+ intent: "Industry cloud objects actually used, and for what."
187
+ facts: [namespaces, data.objects, modules.clouds]
188
+ modules: [industries]
189
+ must:
190
+ - "Table 'Object | Use'. Only objects referenced by the local metadata."
191
+ data.externalIds:
192
+ doc: tad
193
+ intent: "Role of each external ID: which system feeds it, matching key for upserts."
194
+ must:
195
+ - "One sentence per key family."
196
+ data.recordTypes:
197
+ doc: tad
198
+ intent: "Why record types exist and what differs between them."
199
+ data.cmdt:
200
+ doc: tad
201
+ intent: "Which business rules are configured in Custom Metadata (changed without deploying code)."
202
+ must:
203
+ - "Table 'Type | What it configures'."
204
+ - "Optional '> [!INTEGRATOR]' callout."
205
+ data.events:
206
+ doc: tad
207
+ intent: "Platform events and change data capture: publishers and subscribers."
208
+ modules: [platform-events]
209
+ data.dataCloud:
210
+ doc: tad
211
+ intent: "Data Cloud: data streams, data model objects, identity resolution, segments and activations used by the CRM."
212
+ modules: [data-cloud]
213
+ data.files:
214
+ doc: tad
215
+ intent: "How documents and files are stored (Salesforce Files, external document store, attachments)."
216
+ data.volumes:
217
+ doc: tad
218
+ intent: "Comment the volumes table (largest objects, growth drivers, large data volume measures)."
219
+ never:
220
+ - "Record-level data."
221
+ data.lifecycle:
222
+ doc: tad
223
+ intent: "Creation, update, archiving and deletion of data; history tracking; retention."
224
+ must:
225
+ - "When nothing is configured, state it as a fact to confirm, not as a defect."
226
+
227
+ # ------------------------------------------------------------------ 7 Application
228
+ application.principles:
229
+ doc: tad
230
+ intent: "Apex design principles observed (one trigger per object, handler pattern, selector and service separation, bulkification, user mode)."
231
+ facts: [counts.apex, naming.apex]
232
+ application.layers:
233
+ doc: tad
234
+ intent: "Code layers and naming conventions."
235
+ must:
236
+ - "Mermaid flowchart TB of the layers (LWC or Flow, controllers, services, selectors, integration) with a Figure caption."
237
+ - "Table 'Layer | Convention | Examples'."
238
+ figure: "flowchart TB"
239
+ application.domains:
240
+ doc: tad
241
+ intent: "Main classes grouped by functional domain."
242
+ must:
243
+ - "Table 'Domain | Main classes | Role'; at most 6 classes per row, the rest in the appendix ({{ref:annex-apex}})."
244
+ application.triggers:
245
+ doc: tad
246
+ intent: "Trigger framework and order of execution."
247
+ facts: [apex.triggers, signals]
248
+ must:
249
+ - "Table 'Object | Trigger | Handler | Events'."
250
+ - "A '### Order of execution' subsection when several automations act on the same object."
251
+ application.mechanisms:
252
+ doc: tad
253
+ intent: "The 1 to 3 cross-cutting mechanisms that drive the solution (ownership propagation, rules engine, provisioning...), each with a sequence diagram."
254
+ must:
255
+ - "Name the thresholds and switches visible in code (example: synchronous up to N records, then batch) with the class that implements them."
256
+ application.async:
257
+ doc: tad
258
+ intent: "Batch, queueable, schedulable and @future processing."
259
+ facts: [apex.classes, org.scheduledJobs]
260
+ must:
261
+ - "Table 'Job | Type | Trigger or schedule | Purpose'."
262
+ - "Mermaid flowchart of chaining when jobs chain."
263
+ application.flows:
264
+ doc: tad
265
+ intent: "Role of flows next to Apex, and the main active flows."
266
+ facts: [automation.flows]
267
+ must:
268
+ - "Table 'Flow | Type | Object | Purpose' for the active flows; the full list stays in the appendix ({{ref:annex-automation}})."
269
+ application.omnistudio:
270
+ doc: tad
271
+ intent: "How OmniStudio is used: OmniScripts for guided journeys, Integration Procedures for orchestration, Data Mappers for data access, FlexCards for display."
272
+ facts: [automation.omnistudio]
273
+ modules: [omnistudio]
274
+ must:
275
+ - "Mermaid flowchart OmniScript > Integration Procedure > Data Mapper / Apex / HTTP, then one '###' per family with a table."
276
+ application.ai:
277
+ doc: tad
278
+ intent: "Agentforce agents, Einstein features and prompt templates: topics, actions, grounding, guardrails, channels."
279
+ modules: [agentforce-ai]
280
+ must:
281
+ - "Table 'Agent or feature | Channel | Topics or use | Actions (Flow, Apex, prompt)'."
282
+ application.sequences:
283
+ doc: tad
284
+ intent: "2 to 4 key end-to-end sequences (sequenceDiagram), each with a short introduction."
285
+ must:
286
+ - "Only calls observed in code or metadata; participants named by component."
287
+ never:
288
+ - "Participants that are not in the inventory or the glossary."
289
+
290
+ # ------------------------------------------------------------------ 8 UI
291
+ ui.apps:
292
+ doc: tad
293
+ intent: "Applications, their audience and navigation (console or standard, utility bar, mobile)."
294
+ facts: [ui.apps]
295
+ ui.pages:
296
+ doc: tad
297
+ intent: "Key Lightning pages and their composition."
298
+ facts: [ui.flexipages]
299
+ must:
300
+ - "Table 'Page | Object | Custom components'."
301
+ - "Optional composition diagram for the main record page."
302
+ ui.lwc:
303
+ doc: tad
304
+ intent: "LWC organised by domain, with the 2 or 3 key components described."
305
+ facts: [ui.lwc]
306
+ must:
307
+ - "'### By domain' table 'Domain | Components | Role'; the full list is in the appendix ({{ref:annex-lwc}})."
308
+ ui.communication:
309
+ doc: tad
310
+ intent: "How components talk: events, Lightning Message Service, navigation, wire adapters, Apex."
311
+ facts: [ui.lwc, ui.messageChannels]
312
+ ui.aura:
313
+ doc: tad
314
+ intent: "Remaining Aura components and their role (stated neutrally)."
315
+ ui.sites:
316
+ doc: tad
317
+ intent: "Experience Cloud sites, public sites and Visualforce pages: audience, templates, authentication, purpose."
318
+ modules: [experience-cloud]
319
+ ui.omnichannel:
320
+ doc: tad
321
+ intent: "Telephony (call centers, CTI adapter or Service Cloud Voice) and Omni-Channel routing (channels, queues, skills, capacity), messaging channels."
322
+ facts: [integration.callCenters, misc.signals]
323
+ modules: [service-cloud]
324
+
325
+ # ------------------------------------------------------------------ 9 Integrations
326
+ integration.principles:
327
+ doc: tad
328
+ intent: "Integration principles (credentials externalised, the system of record stays master, idempotent upserts with external IDs, asynchronous for volume)."
329
+ integration.patterns:
330
+ doc: tad
331
+ intent: "Classify each flow with the Salesforce Integration Patterns."
332
+ must:
333
+ - "Table 'Pattern | Flows' using: Remote Process Invocation (Request and Reply, Fire and Forget), Batch Data Synchronization, Remote Call-In, UI Update Based on Data Changes, Data Virtualization."
334
+ integration.flows:
335
+ doc: tad
336
+ intent: "Catalogue of the integration flows."
337
+ must:
338
+ - "Table 'ID | Flow | Direction | System | Salesforce component | Pattern' with FLX-01, FLX-02..."
339
+ never:
340
+ - "Systems not in glossary.systems."
341
+ - "Flows that no component implements."
342
+ integration.systems:
343
+ doc: tad
344
+ intent: "One '###' per connected system, with a sequence diagram for the main exchange."
345
+ facts: [systems, integration.namedCredentials, apex.classes]
346
+ modules: [integration-platforms]
347
+ must:
348
+ - "For each system: purpose, Salesforce endpoints (named credential, authentication), main calls with their Apex class, flow or Integration Procedure."
349
+ integration.inbound:
350
+ doc: tad
351
+ intent: "Exposed APIs (Apex REST or SOAP): callers, payload in one line, security (integration user, permission set, connected app)."
352
+ integration.marketing:
353
+ doc: tad
354
+ intent: "Marketing integration: Marketing Cloud Connect or Account Engagement (synchronised objects, sends, tracking, consent)."
355
+ modules: [marketing]
356
+ integration.commerce:
357
+ doc: tad
358
+ intent: "Commerce: stores, catalogs, buyer groups, checkout integrations (payment, tax, shipping, inventory) and order management."
359
+ modules: [commerce]
360
+ integration.sso:
361
+ doc: tad
362
+ intent: "Authentication providers, SSO, registration handlers, connected apps."
363
+ facts: [integration.authProviders, integration.connectedApps]
364
+ integration.domains:
365
+ doc: tad
366
+ intent: "Why each allowed domain exists (CSP, CORS, remote sites)."
367
+
368
+ # ------------------------------------------------------------------ 10 Security
369
+ security.principles:
370
+ doc: tad
371
+ intent: "Security principles (least privilege, persona-based access, server-side checks, no secrets in code)."
372
+ security.auth:
373
+ doc: tad
374
+ intent: "How users log in and how their access is provisioned (SSO, registration handler, provisioning automation)."
375
+ must:
376
+ - "A sequence diagram when provisioning is automated."
377
+ security.personas:
378
+ doc: tad
379
+ intent: "Personas and the permission set groups that implement them."
380
+ facts: [security.permissionSetGroups, org.psgAssignments]
381
+ must:
382
+ - "Table 'Persona | Permission set group | Main rights'."
383
+ security.roles:
384
+ doc: tad
385
+ intent: "Comment the role hierarchy: structure and technical roots."
386
+ security.owd:
387
+ doc: tad
388
+ intent: "Default sharing choices and their rationale."
389
+ security.rules:
390
+ doc: tad
391
+ intent: "Sharing rules and queues: what they open and to whom."
392
+ security.app:
393
+ doc: tad
394
+ intent: "Application security in code: sharing keywords, user mode, FLS and CRUD checks, input validation."
395
+ facts: [counts.apex.withSharing, counts.apex.withoutSharing, apex.classes]
396
+ must:
397
+ - "Neutral facts with placeholders, for example '{{n:apex.withSharing}} classes declare with sharing'."
398
+ never:
399
+ - "Findings phrased as defects: they go to the Improvement Axes."
400
+ security.shield:
401
+ doc: tad
402
+ intent: "Shield and compliance capabilities in use: platform encryption, event monitoring, transaction security, field audit trail, data masking."
403
+ modules: [security-shield]
404
+ security.session:
405
+ doc: tad
406
+ intent: "Session and password settings in force."
407
+ facts: [security.session, security.passwordPolicies]
408
+ security.integrationUsers:
409
+ doc: tad
410
+ intent: "Technical users used by integrations and their permissions."
411
+ security.public:
412
+ doc: tad
413
+ intent: "Guest access and public exposure of sites and APIs."
414
+
415
+ # ------------------------------------------------------------------ 11-15
416
+ reporting.reports:
417
+ doc: tad
418
+ intent: "Reporting and dashboards: folders, audiences, KPI components."
419
+ reporting.analytics:
420
+ doc: tad
421
+ intent: "CRM Analytics or Tableau: apps, dataflows or recipes, datasets, embedding in Lightning pages, security predicates."
422
+ modules: [analytics]
423
+ operations.environments:
424
+ doc: tad
425
+ intent: "Environments (production, sandboxes and their purpose) and their refresh policy."
426
+ never:
427
+ - "Environments not confirmed by the client."
428
+ operations.release:
429
+ doc: tad
430
+ intent: "How a release is prepared and delivered: pipeline, order of deployment, manual steps."
431
+ must:
432
+ - "A sequence or flowchart when the release has phases."
433
+ operations.scheduled:
434
+ doc: tad
435
+ intent: "Scheduled processing to monitor in run."
436
+ operations.logging:
437
+ doc: tad
438
+ intent: "Logging, error handling and monitoring."
439
+ operations.tests:
440
+ doc: tad
441
+ intent: "Test strategy: test classes, data factories, mocks, coverage."
442
+ facts: [counts.apex.tests, org.coverage]
443
+ nfr.measures:
444
+ doc: tad
445
+ intent: "Non-functional requirements and the measures in place."
446
+ must:
447
+ - "Table 'Requirement | Measures in place' (security, performance, volume, availability, maintainability, traceability)."
448
+ nfr.wellArchitected:
449
+ doc: tad
450
+ intent: "Reading of the solution through Salesforce Well-Architected (Trusted, Easy, Adaptable)."
451
+ must:
452
+ - "Table 'Pillar | Strengths observed'. Optionally run the platform-architecture-analyze skill first."
453
+ never:
454
+ - "Scores or defects: keep them for the Improvement Axes."
455
+ decisions.adr:
456
+ doc: tad
457
+ intent: "Architecture decisions taken."
458
+ must:
459
+ - "Table 'ID | Decision | Rationale | Consequence' with ADR-01...; only decisions visible in the metadata or provided by the client."
460
+ outlook.roadmap:
461
+ doc: tad
462
+ intent: "Evolution perspectives, stated positively."
463
+ must:
464
+ - "Bullets; refer to the Improvement Axes document for the detailed register without quoting its findings."
465
+
466
+ # ------------------------------------------------------------------ Improvement Axes
467
+ axes.summary:
468
+ doc: axes
469
+ intent: "The 5 most important axes, and the overall health in one paragraph per pillar."
470
+ facts: [signals, counts]
471
+ axes.method:
472
+ doc: axes
473
+ intent: "Optional details on how the signals were obtained (Code Analyzer report, Well-Architected skill run, interviews)."
474
+ axes.trusted:
475
+ doc: axes
476
+ intent: "Qualify each Trusted signal: real risk, scope, remediation."
477
+ must:
478
+ - "One paragraph per signal kept, with its AX-nn reference."
479
+ axes.easy:
480
+ doc: axes
481
+ intent: "Qualify each Easy signal."
482
+ axes.adaptable:
483
+ doc: axes
484
+ intent: "Qualify each Adaptable signal."
485
+ axes.register:
486
+ doc: axes
487
+ intent: "The register of improvement axes."
488
+ must:
489
+ - "Table 'ID | Axis | Finding | Impact | Recommendation | Priority | Effort' with AX-01..., priority written <span class=\"b p1\">P1</span>."
490
+ axes.roadmap:
491
+ doc: axes
492
+ intent: "Sequencing of the axes over releases or quarters."
493
+ must:
494
+ - "A Mermaid gantt or a table 'Horizon | Axes'."
@@ -0,0 +1,7 @@
1
+ # Document control {- #doc-control}
2
+
3
+ @@ANNEX:doc-control@@
4
+
5
+ ## Version history {- #version-history}
6
+
7
+ @@ANNEX:version-history@@
@@ -0,0 +1,17 @@
1
+ # Executive summary {#ch-summary}
2
+
3
+ <!-- tad:pending summary.overview -->
4
+
5
+ @@KPIS@@
6
+
7
+ ## Business capabilities covered {#summary-capabilities}
8
+
9
+ <!-- tad:pending summary.capabilities -->
10
+
11
+ ## Key achievements {#summary-achievements}
12
+
13
+ <!-- tad:pending summary.achievements -->
14
+
15
+ ## Architecture principles applied {#summary-principles}
16
+
17
+ <!-- tad:pending summary.principles -->
@@ -0,0 +1,35 @@
1
+ # Purpose, scope and references {#ch-purpose}
2
+
3
+ ## Purpose of the document {#purpose}
4
+
5
+ <!-- tad:pending purpose.object -->
6
+
7
+ ## Scope {#scope}
8
+
9
+ <!-- tad:pending purpose.scope -->
10
+
11
+ ## References {#references}
12
+
13
+ <!-- tad:pending purpose.references -->
14
+
15
+ ## Method {#method}
16
+
17
+ This document describes the architecture **as implemented** in the Salesforce organization of {{cfg:client.name}} ({{cfg:document.environment}}), as of {{cfg:document.date}}. It was produced from the metadata of the organization, retrieved in read-only mode, and from the inputs provided by {{cfg:client.name}} and {{cfg:integrator.name}}.
18
+
19
+ - Inventories and counts cover the components built for {{cfg:client.name}}. Components delivered by managed packages and unused standard samples are excluded.
20
+ - Each statement relies on the metadata, on a document provided by the project, or is explicitly marked as to be confirmed.
21
+ - Authentication parameters (identifiers, secrets, certificates) and business data are never reproduced.
22
+
23
+ <!-- tad:if facts.exclusions.applied -->
24
+ The following components exist in the organization but are outside the documented architecture:
25
+
26
+ @@ANNEX:exclusions@@
27
+ <!-- tad:endif -->
28
+
29
+ ## Reading conventions {#conventions}
30
+
31
+ - Technical names (objects, fields, classes, flows, components) are written in monospace, for example `Account`. Business labels are written in quotes, for example « Customer ».
32
+ - Salesforce terms in common use (Lead, Queue, Record Type, Permission Set, Named Credential…) are kept as is.
33
+ - Diagrams share one colour code:
34
+
35
+ @@ANNEX:legend@@
@@ -0,0 +1,17 @@
1
+ # Context and vision {#ch-context}
2
+
3
+ ## Business drivers {#context-drivers}
4
+
5
+ <!-- tad:pending context.drivers -->
6
+
7
+ ## Actors and user populations {#context-actors}
8
+
9
+ <!-- tad:pending context.actors -->
10
+
11
+ ## Functional scope {#context-scope}
12
+
13
+ <!-- tad:pending context.scope -->
14
+
15
+ ## Key figures {#context-figures}
16
+
17
+ @@ANNEX:key-figures@@
@@ -0,0 +1,29 @@
1
+ # General architecture {#ch-general}
2
+
3
+ ## Context view {#general-context}
4
+
5
+ @@FIGURE:context@@
6
+
7
+ <!-- tad:pending general.context -->
8
+
9
+ ## Salesforce foundation and products {#general-products}
10
+
11
+ @@ANNEX:products@@
12
+
13
+ <!-- tad:pending general.products -->
14
+
15
+ ## Logical architecture in layers {#general-layers}
16
+
17
+ @@FIGURE:layers@@
18
+
19
+ <!-- tad:pending general.layers -->
20
+
21
+ ## Design principles {#general-principles}
22
+
23
+ <!-- tad:pending general.principles -->
24
+
25
+ ## Naming conventions {#general-naming}
26
+
27
+ @@ANNEX:naming@@
28
+
29
+ <!-- tad:pending general.naming -->
@@ -0,0 +1,7 @@
1
+ # Functional architecture and business processes {#ch-functional}
2
+
3
+ ## Functional domains {#functional-domains}
4
+
5
+ <!-- tad:pending functional.domains -->
6
+
7
+ <!-- tad:pending functional.processes -->
@@ -0,0 +1,71 @@
1
+ # Data architecture {#ch-data}
2
+
3
+ ## Modeling principles {#data-principles}
4
+
5
+ <!-- tad:pending data.principles -->
6
+
7
+ ## Overview {#data-overview}
8
+
9
+ @@ERD:auto|Main objects and their relationships@@
10
+
11
+ <!-- tad:pending data.overview -->
12
+
13
+ ## Objects by domain {#data-domains}
14
+
15
+ <!-- tad:pending data.domains -->
16
+
17
+ <!-- tad:if modules.industryCloud -->
18
+ ## Industry cloud objects {#data-industry}
19
+
20
+ <!-- tad:pending data.industry -->
21
+ <!-- tad:endif -->
22
+
23
+ ## External IDs and integration keys {#data-external-ids}
24
+
25
+ @@ANNEX:external-ids@@
26
+
27
+ <!-- tad:pending data.externalIds -->
28
+
29
+ ## Record types and business processes {#data-record-types}
30
+
31
+ @@ANNEX:record-types@@
32
+
33
+ <!-- tad:pending data.recordTypes -->
34
+
35
+ <!-- tad:if counts.cmdt.types -->
36
+ ## Configuration in Custom Metadata {#data-cmdt}
37
+
38
+ @@ANNEX:cmdt@@
39
+
40
+ <!-- tad:pending data.cmdt -->
41
+ <!-- tad:endif -->
42
+
43
+ <!-- tad:if modules.events -->
44
+ ## Platform events and change data capture {#data-events}
45
+
46
+ @@ANNEX:platform-events@@
47
+
48
+ <!-- tad:pending data.events -->
49
+ <!-- tad:endif -->
50
+
51
+ <!-- tad:if modules.dataCloud -->
52
+ ## Data Cloud {#data-cloud}
53
+
54
+ <!-- tad:pending data.dataCloud -->
55
+ <!-- tad:endif -->
56
+
57
+ ## Files and documents {#data-files}
58
+
59
+ <!-- tad:pending data.files -->
60
+
61
+ <!-- tad:if org.volumes -->
62
+ ## Data volumes {#data-volumes}
63
+
64
+ @@ANNEX:volumes@@
65
+
66
+ <!-- tad:pending data.volumes -->
67
+ <!-- tad:endif -->
68
+
69
+ ## Data lifecycle {#data-lifecycle}
70
+
71
+ <!-- tad:pending data.lifecycle -->