@webex/internal-plugin-call-ai-summary 3.12.0-next.59 → 3.12.0-next.60

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.
@@ -0,0 +1,287 @@
1
+ ---
2
+ type: Architecture
3
+ title: '@webex/internal-plugin-call-ai-summary architecture'
4
+ description: Repository-wide boundaries, resources, interactions, dependencies, and cross-cutting architecture.
5
+ tags: [architecture]
6
+ ---
7
+ <!-- sdd-generated-metadata
8
+ doc_kind: standing-doc
9
+ generated_from: architecture@0.3.0
10
+ generated_by: claude-code
11
+ approved_by: "@riag"
12
+ updated_at: 2026-09-23T14:03:22Z
13
+ validation_status: pass
14
+ -->
15
+
16
+ # @webex/internal-plugin-call-ai-summary architecture
17
+
18
+ Canonical repository-wide architecture. This document owns facts that span
19
+ multiple services, packages, modules, applications, or repositories. Link to
20
+ the owning service, module, feature, ADR, or native contract instead of
21
+ duplicating owner-local detail.
22
+
23
+ Related context: [specification registry](specs/README.md) ·
24
+ [repository agent instructions](../AGENTS.md)
25
+
26
+ ## Applicability
27
+
28
+ | Condition ID | Status | Evidence or reason | Owned section |
29
+ | ------------------------------------ | ------ | ------------------ | ----------------------------------- |
30
+ | `repo.owns_datastore` | N/A | The package persists nothing; all content is fetched per call from Pragya and AI Bridge. `src/ai-summary.ts` | Repository data and schema |
31
+ | `repo.holds_client_state` | N/A | The WebexPlugin.extend object holds no session state between calls. `src/ai-summary.ts` | Client state model |
32
+ | `repo.components_interact` | N/A | Single module; interaction with upstream services is covered by Interaction and execution flows. `src/` | Dependency and interaction topology |
33
+ | `repo.domain_data_across_components` | N/A | One module owns all domain data in this package. `src/types.ts` | Object and data ownership |
34
+ | `repo.caches_data` | N/A | No cache layer exists in the source. `src/ai-summary.ts` | Caching catalog |
35
+ | `repo.observability_convention` | Applicable | Every public method logs failures through this.logger.error before rethrowing. `src/ai-summary.ts` | Observability patterns |
36
+ | `repo.deploys_to_infra` | N/A | Published library; no deployment surface or infrastructure. `package.json` | Runtime and infrastructure |
37
+ | `repo.shared_base_libs` | Applicable | Inherits WebexPlugin, request handling, and the auth interceptor from @webex/webex-core. `package.json` | Shared and base libraries |
38
+ | `repo.is_monorepo` | N/A | The SDD root is one package; the surrounding monorepo is out of this scope. `package.json` | Package map and dependencies |
39
+ | `repo.multi_platform` | Applicable | Supports both browser and Node.js environments. `package.json` | Platform matrix |
40
+ | `repo.published_package` | Applicable | Published to npm via the deploy:npm script. `package.json` | Release and versioning |
41
+ | `repo.embedded_in_host` | Applicable | Registers into a host Webex SDK instance as webex.internal.aisummary. `src/index.ts` | Host integration and theming |
42
+ | `repo.exposes_commands_or_artifacts` | Applicable | Publishes a build artifact to dist/ and exposes documented yarn commands. `package.json` | Commands and generated artifacts |
43
+ | `repo.cross_repo_deps_material` | Applicable | Behavior depends on the externally owned Pragya, AI Bridge, Janus, and KMS services. `src/constants.ts` | Cross-repository topology |
44
+ | `repo.security_arch_warranted` | Applicable | All content is KMS-encrypted and every call is token-authenticated. `src/ai-summary.ts` | Security architecture |
45
+
46
+ ## Design overview
47
+
48
+ The Webex JS SDK will provide AI-generated call summary retrieval capabilities through a new **`internal-plugin-call-ai-summary`** internal plugin. This document describes the architecture for retrieving AI-generated notes, action items, and transcripts from completed calls.
49
+
50
+ AI summary content is discovered through a two-step lookup: **Janus** (call history) provides container IDs, and **Pragya** (AI container service) resolves those IDs into content URLs and an encryption key.
51
+
52
+ The package pursues these goals:
53
+
54
+ - Resolve AI summary container IDs from Janus call history via Pragya
55
+ - Retrieve AI-generated notes (full notes) for a call
56
+ - Retrieve AI-generated action items for a call
57
+ - Retrieve transcript download URLs for a call
58
+ - Handle encrypted content decryption via KMS
59
+ - Maintain consistency with existing Webex JS SDK internal plugin patterns
60
+ - Provide type-safe interfaces for all operations
61
+ - Support both browser and Node.js environments
62
+
63
+ The following are explicitly out of scope:
64
+
65
+ - Start/stop AI assistant during active calls (handled by Pragya start/stop APIs, out of scope)
66
+ - Generate or regenerate summaries (backend-managed during/after calls)
67
+ - Provide real-time in-call AI responses
68
+ - Handle recording storage or deletion
69
+ - Implement feedback UI components
70
+
71
+ Operation depends on two prerequisites:
72
+
73
+ 1. Janus API already returns `extensionPayload.callingContainerIds` in the response
74
+ 2. Testing environment with AI-enabled calls that generate summaries
75
+
76
+ The decisions that shape this structure are recorded in
77
+ [ADR-0001](adr/0001-flatten-container-response-and-prefer-single-request-summary.md).
78
+
79
+ ## Resource inventory and responsibilities
80
+
81
+ | Component | Responsibility |
82
+ | --------- | -------------- |
83
+ | `internal-plugin-call-ai-summary` | Internal plugin; resolves Pragya containers, fetches and decrypts summary content |
84
+ | `internal-plugin-encryption` | KMS integration for decrypting AI-generated content using `encryptionKeyUrl` |
85
+ | `http-core` | HTTP transport; adds authorization headers, handles retries |
86
+ | Pragya Service | Container metadata; provides content URLs and encryption key |
87
+ | Summary Content Endpoints | Serve encrypted AI-generated content (notes, action items, transcripts) |
88
+
89
+ Only the first component is owned by this repository. Its source is `src/` and its canonical
90
+ specification is [`src/docs/README.md`](../src/docs/README.md); it is owned by the Webex JS SDK Team.
91
+ The encryption plugin and HTTP transport are sibling workspace packages, and the Pragya and summary
92
+ content services are externally owned.
93
+
94
+ ## Interaction and execution flows
95
+
96
+ AI summary content is discovered in three steps.
97
+
98
+ **Step 1: Get container IDs from Janus call history**
99
+
100
+ The Janus `UserSession` response includes an `extensionPayload` field containing container IDs for AI artifacts related to a call:
101
+
102
+ The `extensionPayload.callingContainerIds` field is already present in the Janus API response but is not yet in the SDK's `UserSession` type definition, so consumers read it from the raw session payload. The exact session shape is owned by the Janus call-history type declaration rather than restated here.
103
+
104
+ **Step 2: Resolve container IDs via Pragya**
105
+
106
+ For each `containerId`, call the Pragya container API at `GET https://{pragya-host}/pragya/api/v1/containers/{containerId}`. The raw Pragya response nests summary URLs under `summaryData.data`. The plugin's `getContainer()` method flattens this so consumers can access `summaryData.summaryUrl` directly; the exact response body is owned by `src/types.ts`.
107
+
108
+ **Step 3: Fetch summary content from the URLs**
109
+
110
+ The `summaryData` object provides direct, region-correct URLs to each content type. The plugin fetches content from these URLs and decrypts it using the `encryptionKeyUrl` returned alongside them.
111
+
112
+ ```mermaid
113
+ flowchart LR
114
+ Client[Client application] -->|getCallHistoryData| Janus[Janus call history]
115
+ Janus -->|extensionPayload.callingContainerIds| Client
116
+ Client -->|getContainer| Plugin[internal-plugin-call-ai-summary]
117
+ Plugin -->|GET containers/id| Pragya[Pragya service]
118
+ Pragya -->|summaryData URLs + encryptionKeyUrl| Plugin
119
+ Plugin -->|GET summaryUrl / notesUrl / actionItemsUrl / transcriptUrl| Bridge[AI Bridge content endpoints]
120
+ Bridge -->|encrypted content| Plugin
121
+ Plugin -->|decryptText| KMS[internal-plugin-encryption + KMS]
122
+ KMS -->|plaintext| Plugin
123
+ Plugin -->|decrypted summary| Client
124
+ ```
125
+
126
+ The component architecture places the client application above the SDK, the plugin beside the
127
+ encryption plugin and HTTP transport inside `webex.internal`, and the Pragya and summary-content
128
+ services outside the SDK boundary. The end-to-end retrieval flow runs call history, then container
129
+ resolution, then content fetch and decryption, in that order.
130
+
131
+ | From | To | Interaction or transport | Purpose | Failure or compatibility behavior |
132
+ | ---- | -- | ------------------------ | ------- | --------------------------------- |
133
+ | Client | Janus | HTTPS call | Get call history and container IDs | Owned by the call-history plugin |
134
+ | Plugin | Pragya | `webex.request` with `service: 'pragya'` | Resolve container metadata, content URLs, and encryption key | 401/403/404 normalized by `_handleError`; see the module spec |
135
+ | Plugin | AI Bridge | `webex.request` with an absolute `uri` | Fetch encrypted note, short note, action items, and transcript | 404 becomes `Summary content not available or expired` |
136
+ | Plugin | `internal-plugin-encryption` | In-process call to `decryptText` | Decrypt every `aiGeneratedContent` field | Rejection propagates through `_handleError` |
137
+
138
+ Get-container, get-notes and get-action-items each follow the same shape: validate input, issue one
139
+ request, then decrypt. Per-method sequence detail and failure branches are owned by
140
+ [the module specification](../src/docs/README.md).
141
+
142
+ ## Dependency topology
143
+
144
+ Internal workspace dependencies, both declared `workspace:*` in `package.json` and both consumed by
145
+ `src/`:
146
+
147
+ | Package | Purpose |
148
+ | ------- | ------- |
149
+ | `@webex/webex-core` | Plugin infrastructure (`WebexPlugin`, `registerInternalPlugin`) |
150
+ | `@webex/internal-plugin-encryption` | Content decryption via `decryptText()` |
151
+
152
+ External service dependencies. A `webex-core` request rejection or a `decryptText` rejection
153
+ propagates to the caller through `_handleError`:
154
+
155
+ | Service | Purpose | Discovery |
156
+ | ------- | ------- | --------- |
157
+ | **Janus** | Call history; provides `extensionPayload.callingContainerIds` | U2C: `serviceName: "janus"` |
158
+ | **Pragya** | Container metadata; provides content URLs and encryption key | U2C: `serviceName: "pragya"` |
159
+ | **Summary Content Endpoints** | Serve encrypted AI-generated content | Direct URLs from Pragya response |
160
+ | **KMS** | Encryption key management | Via `encryptionKeyUrl` from Pragya |
161
+
162
+ Pragya is discoverable via U2C as `serviceName: "pragya"` (validated: e.g., load-us resolves to `https://pragya-loada.ciscospark.com/pragya/api/v1`). There are no dependency cycles: the package is
163
+ a leaf consumer of `webex-core` and the encryption plugin. Exact versions stay in `package.json`.
164
+
165
+ ## Public and consumer surfaces
166
+
167
+ | Surface | Type | Owner | Consumers | Compatibility policy | Source |
168
+ | ------- | ---- | ----- | --------- | -------------------- | ------ |
169
+ | `aisummary-sdk` | SDK | `src/` | Webex SDK consumers via `webex.internal.aisummary` | Internal plugin; does not strictly adhere to semantic versioning | `src/ai-summary.ts` |
170
+ | `aisummary-package-entry` | SDK | `src/` | Anything importing the package | Internal; import performs registration | `src/index.ts` |
171
+ | `aisummary-types` | SDK | `src/` | TypeScript consumers | Internal; shipped as declarations with the package | `src/types.ts` |
172
+ | `pragya-containers-http` | API | Pragya service team | `src/` | Externally owned; consumed, not published here | External: Webex service catalog pragya. `src/constants.ts` |
173
+ | `ai-bridge-content-http` | API | AI Bridge service team | `src/` | Externally owned; URLs supplied at runtime by PragyaSummaryData | `src/types.ts` |
174
+ | `webex-encryption-sdk` | SDK | Webex JS SDK Team | `src/` | Workspace peer; decryptText contract from @webex/internal-plugin-encryption | `package.json` |
175
+
176
+ No repository-owned HTTP API exists, so no OpenAPI document is selected. See
177
+ `.sdd/manifest.json` `contract_catalog` for the authoritative registry.
178
+
179
+ ## Cross-cutting architecture
180
+
181
+ ### Security
182
+
183
+ - Trust boundaries and identity flow: all API calls (Pragya and content URLs) require a valid user bearer token, and the token is automatically attached by the SDK's HTTP layer.
184
+ - Sensitive surfaces and data classes: AI-generated call content — notes, short notes, action items, and transcripts — is personal meeting content and is never logged in plaintext.
185
+ - Encryption and secret boundaries: all AI-generated content is encrypted at rest with KMS, `encryptionKeyUrl` from Pragya container is the decryption key, and HTTPS required for all API calls.
186
+
187
+ ### Observability and operations
188
+
189
+ - Logging and correlation: every public method catches failures and calls `this.logger.error` with a `AISummary->{method} failed` label before rethrowing a normalized error.
190
+ - Metrics, traces, and audit signals: none are emitted by this package; the host SDK owns transport-level telemetry.
191
+ - Ownership and operational entry points: Webex JS SDK Team; upstream availability is owned by the Pragya and AI Bridge service teams.
192
+
193
+ ### Quality attributes
194
+
195
+ The package is an SDK, so its measurable boundaries are footprint and compatibility rather than
196
+ service SLOs: it adds two workspace dependencies and no transitive runtime services, supports both
197
+ browser and Node.js environments, and holds no state between calls. Content latency is dominated by
198
+ the upstream Pragya and AI Bridge calls plus per-field KMS decryption, which runs concurrently
199
+ through `Promise.all` for snippet collections.
200
+
201
+ ## Observability patterns
202
+
203
+ | Signal | Convention or required fields | Propagation or naming rule | Primary evidence |
204
+ | ------ | ----------------------------- | -------------------------- | ---------------- |
205
+ | Logs | `this.logger.error` with the error and relevant identifiers | `AISummary->{methodName} failed` | `src/ai-summary.ts` |
206
+ | Metrics | None emitted by this package | N/A | `src/ai-summary.ts` |
207
+ | Traces | None emitted by this package | N/A | `src/ai-summary.ts` |
208
+ | Audit | None emitted by this package; access control is enforced upstream | N/A | `src/ai-summary.ts` |
209
+
210
+ ## Shared and base libraries
211
+
212
+ | Library | Inherited responsibility | Consumers | Version floor | Compatibility rule |
213
+ | ------- | ------------------------ | --------- | ------------- | ------------------ |
214
+ | `@webex/webex-core` | Base plugin class, request handling, auth interceptor | `src/` | `workspace:*` | Follows the monorepo's synchronized workspace version |
215
+ | `@webex/internal-plugin-encryption` | KMS decryption via `decryptText` | `src/` | `workspace:*` | Follows the monorepo's synchronized workspace version |
216
+
217
+ ## Platform matrix
218
+
219
+ | Platform | Shared versus platform-specific boundary | Entry or build | Support and compatibility constraints |
220
+ | -------- | ---------------------------------------- | -------------- | ------------------------------------- |
221
+ | Browser | Fully shared; no platform-specific source | `dist/index.js` via `yarn build` | Requires a registered device and Mercury connection for KMS |
222
+ | Node.js | Fully shared; no platform-specific source | `dist/index.js` via `yarn build` | `engines.node >=16` per `package.json` |
223
+
224
+ ## Release and versioning
225
+
226
+ | Artifact | Publish target | Versioning rule | Deprecation window | Changelog or migration obligation |
227
+ | -------- | -------------- | --------------- | ------------------ | --------------------------------- |
228
+ | `@webex/internal-plugin-call-ai-summary` | npm via `yarn deploy:npm` | Internal plugin; does not strictly adhere to semantic versioning | None declared | Monorepo release tooling owns changelog generation |
229
+
230
+ ## Host integration and theming
231
+
232
+ | Host or integration | Mount or entry contract | Required providers or peers | Theming and accessibility constraints |
233
+ | ------------------- | ----------------------- | --------------------------- | ------------------------------------- |
234
+ | Webex JS SDK instance | `registerInternalPlugin('aisummary', ...)` on import; reachable at `webex.internal.aisummary` | An authenticated SDK instance with a registered device, plus `@webex/internal-plugin-encryption` | N/A — no UI surface |
235
+
236
+ ## Commands and generated artifacts
237
+
238
+ | Command or artifact | Owner | Inputs | Output or side effect | Compatibility boundary |
239
+ | ------------------- | ----- | ------ | --------------------- | ---------------------- |
240
+ | `yarn build` | `src/` | `src/**/*.ts` | Compiled JS, type declarations, and maps in `dist/` | `main` entry point `dist/index.js` |
241
+ | `yarn test:style` | `src/` | `src/**/*` | ESLint report | Repository lint configuration |
242
+ | `yarn test:unit` | `src/` | Unit test sources | Jest run | No test sources exist yet; see the module spec |
243
+
244
+ ## Cross-repository topology
245
+
246
+ | Repository or external system | Relationship | Exchanged contract or artifact | Owner | Sequencing constraint |
247
+ | ----------------------------- | ------------ | ------------------------------ | ----- | --------------------- |
248
+ | Janus | Consumes | `extensionPayload.callingContainerIds` from call history | Janus service team | Must run before container resolution |
249
+ | Pragya | Consumes | Container metadata, content URLs, `encryptionKeyUrl` | Pragya service team | Must run before any content fetch |
250
+ | AI Bridge | Consumes | Encrypted note, short note, action items, transcript | AI Bridge service team | Requires URLs from Pragya |
251
+ | KMS | Consumes | Decryption keys addressed by `encryptionKeyUrl` | KMS service team | Requires device registration and Mercury |
252
+
253
+ ## Security architecture
254
+
255
+ Authentication, authorization, and content protection are enforced across three boundaries. Only call participants or authorized users can access containers and summaries; org-level AI features must be enabled; and per-call consent means the AI assistant must have been enabled during the call. The package itself enforces none of these — it presents the user's bearer token and surfaces upstream 401/403 responses as normalized errors.
256
+
257
+ All AI-generated content is encrypted using KMS (Key Management Service). The **Encryption Key** is the `encryptionKeyUrl` from the Pragya container response (format: `kms://kms-{region}.wbx2.com/keys/{key-id}`); the **Encrypted Fields** are `aiGeneratedContent` in notes and action item snippets; and **Decryption** uses `@webex/internal-plugin-encryption` via `decryptText()`. The SDK uses the existing `@webex/internal-plugin-encryption` plugin rather than implementing key handling locally.
258
+
259
+ This is the same pattern used by existing plugins — the **AI Assistant Plugin** (`internal-plugin-ai-assistant/src/utils.ts`) and the **Task Plugin** (`internal-plugin-task/src/helpers/decrypt.helper.js`) both call `decryptText` with a key URL and ciphertext. The exact call shape is owned by `src/ai-summary.ts`.
260
+
261
+ ```mermaid
262
+ flowchart LR
263
+ Principal[Webex user] -->|bearer token| Boundary[SDK auth interceptor]
264
+ Boundary --> Pragya[Pragya container ACL]
265
+ Pragya -->|encryptionKeyUrl| KMS[KMS key authority]
266
+ KMS -->|decrypted content| Protected[AI-generated call content]
267
+ ```
268
+
269
+ ## Domain language
270
+
271
+ | Term | Repository-specific meaning | Authoritative source |
272
+ | ---- | --------------------------- | -------------------- |
273
+ | Container | A Pragya-owned record grouping the AI artifacts for one call, addressed by `containerId` | `src/types.ts` |
274
+ | Pragya | The AI container service that resolves container IDs into content URLs and an encryption key | `src/constants.ts` |
275
+ | AI Bridge | The service behind `summaryUrl`, `notesUrl`, `actionItemsUrl`, and `transcriptUrl` that serves encrypted content | `src/types.ts` |
276
+ | Janus | The call-history service that surfaces `extensionPayload.callingContainerIds` | External |
277
+ | Note / short note | The long and condensed AI-generated summaries of a call | `src/types.ts` |
278
+ | Snippet | One action item or one timed transcript segment | `src/types.ts` |
279
+
280
+ ## References and maintenance
281
+
282
+ - Decisions: [adr/](adr/)
283
+ - Instantiated specifications and routing: [specs/README.md](specs/README.md)
284
+ - Repository rules and patterns: [module specification](../src/docs/README.md)
285
+ - Update this document in the same change that alters repository boundaries,
286
+ resource ownership, cross-resource interaction, or cross-cutting
287
+ architecture.
@@ -0,0 +1,147 @@
1
+ ---
2
+ type: Getting Started
3
+ title: Getting started
4
+ description: Local setup, build, run, and test routing for @webex/internal-plugin-call-ai-summary.
5
+ tags: [onboarding]
6
+ ---
7
+ <!-- sdd-generated-metadata
8
+ doc_kind: standing-doc
9
+ generated_from: getting-started@0.3.0
10
+ generated_by: claude-code
11
+ approved_by: "@riag"
12
+ updated_at: 2026-09-23T14:03:22Z
13
+ validation_status: pass
14
+ -->
15
+
16
+ # Getting started
17
+
18
+ Onboarding for **@webex/internal-plugin-call-ai-summary**.
19
+
20
+ ## Prerequisites
21
+
22
+ | Tool or access | Version or requirement |
23
+ | -------------------------------------- | ---------------------- |
24
+ | Node.js | `>=16` per `package.json` |
25
+ | Yarn (berry, workspace protocol) | As pinned by the monorepo |
26
+ | An authenticated Webex SDK instance with a registered device | Required |
27
+ | `@webex/internal-plugin-encryption` (pulled in automatically as a dependency) | Workspace dependency |
28
+ | A valid Pragya container ID (obtained from Janus call history `extensionPayload.callingContainerIds`) | Required for any live call |
29
+
30
+ ## Install
31
+
32
+ This plugin is part of the Webex JS SDK monorepo. It self-registers when imported — no changes to `packages/webex` are needed.
33
+
34
+ ```bash
35
+ yarn install # From the SDK monorepo root
36
+ ```
37
+
38
+ To use in a consuming application:
39
+
40
+ ```js
41
+ // Importing the plugin auto-registers it on webex.internal.aisummary
42
+ import '@webex/internal-plugin-call-ai-summary';
43
+ ```
44
+
45
+ ## Build
46
+
47
+ ```bash
48
+ cd packages/@webex/internal-plugin-call-ai-summary
49
+ yarn build
50
+ ```
51
+
52
+ ## Run
53
+
54
+ This package is a library, not a runnable application. It becomes active when a consuming
55
+ application imports it, exposing `webex.internal.aisummary`. To exercise it directly, use the manual
56
+ scripts in the Tests section below.
57
+
58
+ ## Tests
59
+
60
+ ```bash
61
+ yarn test:unit
62
+ ```
63
+
64
+ Use the table as the repository-level test router. List only tiers that
65
+ actually exist; behavioral intent belongs in the owning module specifications and exact
66
+ cases remain in the repository's native test sources.
67
+
68
+ | Tier | Command | Test location | Framework | External dependencies |
69
+ | ------------ | -------------------- | ------------- | ----------- | ----------------------------------- |
70
+ | Unit | `yarn test:unit` | `test/unit/spec/` | Jest via `@webex/jest-config-legacy` | None |
71
+ | Manual | `node src/manual-pragya-api-test.js` | `src/manual-pragya-api-test.js` | Plain Node script | Live Webex token |
72
+ | Manual | `node src/manual-integration-test.js` | `src/manual-integration-test.js` | Plain Node script | Live Webex token and container ID |
73
+
74
+ - Coverage or quality gate: none. The repository owner verified on 2026-09-23 that no coverage gate applies to this package; no threshold exists in this package, in `@webex/jest-config-legacy`, or in any repository-level Sonar configuration.
75
+ - Enforcement source: none found.
76
+ - Test environment or QA dependencies: the manual scripts require live Pragya and AI Bridge access.
77
+
78
+ The unit tier runs 38 tests from `test/unit/spec/ai-summary.ts`, with upstream wire fixtures in
79
+ `test/unit/fixture/responses.ts`. Jest collects `test/unit/**` excluding `lib` and `fixture`, so new
80
+ fixture files belong under `fixture/`.
81
+
82
+ The suite needs only `engines.node >=16`; it is verified on Node 24.10 as well as the monorepo's
83
+ pinned 22.14, so `nvm` is not required to run it.
84
+
85
+ ### Manual verification scripts
86
+
87
+ Two manual test scripts are provided in `src/`. Both scripts require a valid Webex access token. Set `WEBEX_TOKEN` and optionally `CONTAINER_ID` as environment variables, or update the placeholders inside the scripts.
88
+
89
+ `manual-pragya-api-test.js` validates the Pragya container response structure (34 checks).
90
+
91
+ ```bash
92
+ cd packages/@webex/internal-plugin-call-ai-summary
93
+ node src/manual-pragya-api-test.js
94
+ ```
95
+
96
+ Provide the token as `WEBEX_TOKEN='<token>'` on the same line.
97
+
98
+ A manual integration test is provided for verifying against live APIs. `manual-integration-test.js` tests the full end-to-end flow using the SDK service catalog:
99
+
100
+ 1. Device registration (WDM) to populate the service catalog
101
+ 2. `getContainer` via plugin (resolves `service: 'pragya'` from the catalog)
102
+ 3. `getSummary` via plugin (fetches + decrypts note, short note, and action items via KMS)
103
+ 4. `getTranscriptUrl` via plugin
104
+ 5. Transcript content fetch
105
+
106
+ ```bash
107
+ cd packages/@webex/internal-plugin-call-ai-summary
108
+ node src/manual-integration-test.js
109
+ ```
110
+
111
+ Provide a fresh token and container ID as `WEBEX_TOKEN='<token>' CONTAINER_ID='<id>'` on the same line.
112
+
113
+ This script registers a device (WDM), resolves the Pragya service via the SDK service catalog, fetches the container, decrypts summary content, and prints the results.
114
+
115
+ ## Configuration and secrets
116
+
117
+ - Required configuration: none. `src/config.ts` declares an empty `aisummary` namespace.
118
+ - Secret source: a Webex access token supplied at runtime by the host application, or `WEBEX_TOKEN` for the manual scripts.
119
+ - Package or artifact access: the monorepo's configured npm registry.
120
+ - Required neighboring repositories or workspace layout: the `webex-js-sdk` monorepo, because dependencies use the `workspace:*` protocol.
121
+ - Platform, simulator, device, or SDK setup: a registered Webex device is required before any decryption can succeed.
122
+ - Never commit credentials or copy production secrets into a local config.
123
+
124
+ ## Development
125
+
126
+ ```bash
127
+ cd packages/@webex/internal-plugin-call-ai-summary
128
+ yarn build # Build
129
+ yarn test:style # Lint
130
+ yarn test:unit # Unit tests
131
+ yarn test # All checks
132
+ ```
133
+
134
+ ## First-run verification
135
+
136
+ 1. Run `yarn build` from the package directory.
137
+ 2. Check that `dist/index.js` and its type declarations are produced.
138
+ 3. Run `yarn test:style`.
139
+
140
+ Expected result: the build emits `dist/` output and ESLint reports no errors.
141
+
142
+ ## Next steps
143
+
144
+ - [Repository architecture](architecture.md)
145
+ - [Module specification](../src/docs/README.md)
146
+ - [Specification registry](specs/README.md)
147
+ - [Documentation index](index.md)
package/docs/index.md ADDED
@@ -0,0 +1,53 @@
1
+ ---
2
+ okf_version: '0.1'
3
+ ---
4
+ <!-- sdd-generated-metadata
5
+ doc_kind: standing-doc
6
+ generated_from: docs-index@0.3.0
7
+ generated_by: claude-code
8
+ approved_by: "@riag"
9
+ updated_at: 2026-09-23T14:03:22Z
10
+ validation_status: pass
11
+ -->
12
+
13
+ # @webex/internal-plugin-call-ai-summary documentation
14
+
15
+ Internal Webex JS SDK plugin for retrieving AI-generated call summaries, notes, action items, and transcripts from completed calls.
16
+
17
+ This plugin resolves AI summary containers via the **Pragya** service and fetches encrypted summary content from URLs returned by Pragya. All content is decrypted through the Webex KMS encryption plugin before it reaches the caller.
18
+
19
+ **Discovery flow:**
20
+
21
+ 1. **Janus** (call history) returns `extensionPayload.callingContainerIds` per call session
22
+ 2. **Pragya** resolves a container ID into metadata including content URLs and encryption key
23
+ 3. **Plugin** fetches content from those URLs and decrypts using `@webex/internal-plugin-encryption`
24
+
25
+ ## Start here
26
+
27
+ - [Getting started](getting-started.md)
28
+ - [Repository architecture](architecture.md)
29
+ - [Module specification](../src/docs/README.md)
30
+
31
+ This package is a published SDK plugin, not a deployable service, so no service specification or
32
+ OpenAPI document is generated. See `.sdd/manifest.json` `layout.artifact_decisions` for the
33
+ recorded reasoning.
34
+
35
+ ## Decisions
36
+
37
+ - [adr/](adr/) — architectural decision records
38
+
39
+ ## Specifications and contracts
40
+
41
+ - [architecture.md](architecture.md) — canonical repository-wide architecture
42
+ - [specs/README.md](specs/README.md) — manifest-backed module and contract registry
43
+ - `src/docs/README.md` — the owning specification beside the module's code
44
+ - [adr/](adr/) — concrete architectural decisions; blank ADR templates remain under `.sdd/`
45
+
46
+ Use the manifest-linked native source for exact contract details. The published SDK surface is owned
47
+ by `src/index.ts` and `src/types.ts`; the Pragya and AI Bridge HTTP surfaces are externally owned and
48
+ are registered in `.sdd/manifest.json` `contract_catalog` rather than copied into Markdown.
49
+
50
+ ## Related repository resources
51
+
52
+ - `README.md` — the npm-facing package readme, including the full end-to-end usage example
53
+ - `src/manual-pragya-api-test.js` and `src/manual-integration-test.js` — manual verification scripts
@@ -0,0 +1,83 @@
1
+ ---
2
+ type: Reference
3
+ title: Specification registry
4
+ description: Canonical specification registry and change-routing guide.
5
+ tags: [specifications, registry]
6
+ ---
7
+ <!-- sdd-generated-metadata
8
+ doc_kind: standing-doc
9
+ generated_from: spec-index@0.3.0
10
+ generated_by: claude-code
11
+ approved_by: "@riag"
12
+ updated_at: 2026-09-23T14:03:22Z
13
+ validation_status: pass
14
+ -->
15
+
16
+ # Specification registry
17
+
18
+ Use this page to find the canonical repository architecture and every
19
+ instantiated service and module specification plus native contract. Keep technical facts
20
+ in one owning document and use this page only for navigation, ownership,
21
+ status, and change/test routing.
22
+
23
+ Start with the [repository architecture](../architecture.md). This package contains no deployable
24
+ service, so no service specification is generated.
25
+
26
+ ## Document roles
27
+
28
+ | Document | Canonical ownership |
29
+ | --------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
30
+ | [Repository architecture](../architecture.md) | Repository boundaries, resource inventory, interactions, dependency topology, and cross-cutting architecture |
31
+ | Module specifications | Stable behavior and design at each manifest-routed `<module-path>/docs/README.md` |
32
+ | [ADR](../adr/) | A durable decision, its deciders, rationale, consequences, and supersession lineage |
33
+
34
+ ## Instantiated specification registry
35
+
36
+ | Resource | Role | Canonical path | Owner | Status | Last verified |
37
+ | ---------- | -------------------------- | ---------------------- | -------------- | --------------------------------------- | ------------- |
38
+ | Repository | Architecture | `docs/architecture.md` | Webex JS SDK Team | Active | 2026-09-23 |
39
+ | AI call summary plugin | Module | `src/docs/README.md` | Webex JS SDK Team | Active | 2026-09-23 |
40
+ | ADR-0001 | Contract | `docs/adr/0001-flatten-container-response-and-prefer-single-request-summary.md` | Webex JS SDK Team | Active | 2026-09-23 |
41
+
42
+ ### Module registry
43
+
44
+ One row per module in `.sdd/manifest.json`, which stays authoritative; this table is its
45
+ human-readable mirror and the reconciliation surface for `scripts/check_spec_index.py`.
46
+
47
+ | Module | Responsibility | Manifest coverage state | Start here |
48
+ | --- | --- | --- | --- |
49
+ | `src/` | Resolve Pragya containers and return decrypted AI call summary, notes, action items, and transcript content | Specced | `src/docs/README.md` |
50
+
51
+ Coverage state is mirrored from `.sdd/manifest.json`. Generator-side field measurement is complete:
52
+ the module is `Specced` at 100% public-surface coverage, assessed 2026-09-23, with independent
53
+ validation reporting no drift. Behavior is verified by 38 unit tests in
54
+ `test/unit/spec/ai-summary.ts`, covering every documented requirement including plugin registration.
55
+
56
+ ## Change and verification routing
57
+
58
+ | Change affects | Load and update | Verification route |
59
+ | ------------------------------------------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------ |
60
+ | Repository boundaries or cross-cutting architecture | `docs/architecture.md` and applicable ADRs | Repository test routing and affected owner specs |
61
+ | A stable code, package, or component boundary | `src/docs/README.md` | Module tests plus affected contracts |
62
+ | A public API, event, command, package, or file contract | The owning architecture/module section plus the native definition | Compatibility and contract tests |
63
+ | The published SDK surface or its types | `src/docs/README.md` Public surface plus `src/index.ts` and `src/types.ts` | Compatibility checks; no automated tests exist yet |
64
+
65
+ ## Module and contract registration
66
+
67
+ The module specification is generated directly at the exact `modules[].canonical_spec` path recorded
68
+ in `.sdd/manifest.json`, which is `src/docs/README.md`.
69
+
70
+ Six contracts are registered in `.sdd/manifest.json` `contract_catalog`:
71
+
72
+ | Contract ID | Publication | Native source |
73
+ | ----------- | ----------- | ------------- |
74
+ | `aisummary-sdk` | internal | `src/ai-summary.ts` |
75
+ | `aisummary-package-entry` | internal | `src/index.ts` |
76
+ | `aisummary-types` | internal | `src/types.ts` |
77
+ | `pragya-containers-http` | published, externally owned | External: Webex service catalog pragya. `src/constants.ts` |
78
+ | `ai-bridge-content-http` | published, externally owned | URLs supplied at runtime by PragyaSummaryData. `src/types.ts` |
79
+ | `webex-encryption-sdk` | internal | Workspace package @webex/internal-plugin-encryption. `package.json` |
80
+
81
+ No repository-owned HTTP surface exists, so no `api-specs/openapi.yaml` is selected. The published
82
+ SDK surface retains its ecosystem-native TypeScript declarations as the contract source. This page
83
+ provides navigation and ownership rather than a copied contract.
package/package.json CHANGED
@@ -40,8 +40,8 @@
40
40
  "build:src": "webex-legacy-tools build -dest \"./dist\" -src \"./src\" -js -ts -maps",
41
41
  "deploy:npm": "yarn npm publish",
42
42
  "test": "yarn test:style && yarn test:unit",
43
- "test:style": "eslint ./src/**/*.*",
43
+ "test:style": "eslint ./src/**/*.{ts,js}",
44
44
  "test:unit": "webex-legacy-tools test --unit --runner jest"
45
45
  },
46
- "version": "3.12.0-next.59"
46
+ "version": "3.12.0-next.60"
47
47
  }