@jaypie/mcp 0.8.155 → 0.8.156

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.
@@ -13,7 +13,7 @@ import { RELEASE_NOTES_HELP } from './help.js';
13
13
  /**
14
14
  * Docs Suite - Documentation services (skill, version, release_notes)
15
15
  */
16
- const BUILD_VERSION_STRING = "@jaypie/mcp@0.8.155#dee71f8c"
16
+ const BUILD_VERSION_STRING = "@jaypie/mcp@0.8.156#2f9f851b"
17
17
  ;
18
18
  // =============================================================================
19
19
  // ASSET PATHS
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jaypie/mcp",
3
- "version": "0.8.155",
3
+ "version": "0.8.156",
4
4
  "description": "Jaypie MCP",
5
5
  "repository": {
6
6
  "type": "git",
@@ -0,0 +1,19 @@
1
+ ---
2
+ version: 1.2.84
3
+ date: 2026-09-13
4
+ summary: JaypieLambda and JaypieMigration grant Query and Scan on table indexes CDK does not declare
5
+ ---
6
+
7
+ ## Changes
8
+
9
+ - **`JaypieLambda` `tables`** grants `dynamodb:Query` and `dynamodb:Scan` on
10
+ `${tableArn}/index/*` for every table. CDK adds index ARNs only for indexes
11
+ declared in CDK, so a Lambda could not query a GSI created by a migration or
12
+ owned by an imported table (#546).
13
+ - **`JaypieMigration`** inherits the grant, so a migration can query an index an
14
+ earlier migration created in the same deploy.
15
+
16
+ ## Upgrade
17
+
18
+ Remove workarounds that add `dynamodb:Query` or `dynamodb:Scan` on
19
+ `${tableArn}/index/*` to a `JaypieLambda` or `JaypieMigration` role.
@@ -0,0 +1,11 @@
1
+ ---
2
+ version: 0.8.156
3
+ date: 2026-09-13
4
+ summary: Skills document index Query and Scan grants for tables passed to JaypieLambda and JaypieMigration
5
+ ---
6
+
7
+ ## Changes
8
+
9
+ - **`cdk`, `dynamodb`, and `migrations` skills** document that tables passed
10
+ via `tables` get `Query` and `Scan` on `${tableArn}/index/*`, covering
11
+ indexes created by migrations that CDK never declares (#546).
package/skills/cdk.md CHANGED
@@ -232,8 +232,10 @@ const handler = new JaypieLambda(this, "ApiHandler", {
232
232
 
233
233
  | Tables Count | Permissions | Environment |
234
234
  |-------------|-------------|-------------|
235
- | 1 table | `grantReadWriteData()` | `DYNAMODB_TABLE_NAME` set automatically |
236
- | 2+ tables | `grantReadWriteData()` for each | No auto env var — set `CDK_ENV_TABLE` manually |
235
+ | 1 table | `grantReadWriteData()` plus `Query`/`Scan` on `index/*` | `DYNAMODB_TABLE_NAME` set automatically |
236
+ | 2+ tables | `grantReadWriteData()` plus `Query`/`Scan` on `index/*` for each | No auto env var — set `CDK_ENV_TABLE` manually |
237
+
238
+ CDK grants index ARNs only for indexes declared in CDK. The explicit `index/*` grant covers GSIs created by migrations (`UpdateTable`) and indexes on imported tables.
237
239
 
238
240
  Single table example — at runtime, use `process.env.DYNAMODB_TABLE_NAME`:
239
241
 
@@ -272,6 +272,8 @@ GSIs are defined using `fabricIndex()` from `@jaypie/fabric`. **Do not create al
272
272
 
273
273
  **Important:** DynamoDB allows only **one GSI to be added per deployment**. If you need multiple GSIs, add them sequentially across separate deploys. For production tables, the AWS CLI is often better suited for adding GSIs than CDK (which may try to replace the table).
274
274
 
275
+ **Grants:** CDK adds `${tableArn}/index/*` to grants only for indexes declared in CDK. GSIs created by migrations or the CLI are invisible to CDK, so a role needs `Query` and `Scan` on the index ARN explicitly. `JaypieLambda` and `JaypieMigration` grant this for every table in `tables`; hand-rolled roles must add it.
276
+
275
277
  All GSIs use a composite sort key of `scope#updatedAt` (stored as `{indexName}Sk`). Queries use `begins_with` on the sk to filter by scope; omitting scope lists across all scopes.
276
278
 
277
279
  | GSI Name | Partition Key Pattern | Sort Key | Purpose | Add When |
@@ -47,7 +47,7 @@ new JaypieMigration(this, "SeedData", {
47
47
  - **Role**: Tagged as `CDK.ROLE.PROCESSING`
48
48
  - **Execution**: Uses `cr.Provider` with both `onEventHandler` and `isCompleteHandler` pointing to the same Lambda. The `onEventHandler` returns `PhysicalResourceId` immediately; the migration code runs in `isCompleteHandler` invocations, which are polled by Step Functions until `IsComplete: true`. `Delete` requests skip the migration entirely.
49
49
  - **Dependencies**: Use `dependencies` to ensure tables and other resources exist before the migration executes
50
- - **Permissions**: Tables passed via `tables` get data-plane (`grantReadWriteData`) plus control-plane access (`DescribeTable`, `UpdateTable`, `UpdateTimeToLive`, `UpdateContinuousBackups`) scoped to the table ARN and its indexes — migrations that add GSIs, toggle TTL, or change backups work without extra IAM
50
+ - **Permissions**: Tables passed via `tables` get data-plane (`grantReadWriteData`), `Query` and `Scan` on `${tableArn}/index/*`, plus control-plane access (`DescribeTable`, `UpdateTable`, `UpdateTimeToLive`, `UpdateContinuousBackups`) scoped to the table ARN and its indexes — migrations that add GSIs, toggle TTL, or change backups work without extra IAM, and later migrations can query the GSIs earlier ones created
51
51
 
52
52
  ## Migration Lambda Handler
53
53