json-rest-api 1.0.20 → 1.0.22

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 (173) hide show
  1. package/audit/00-charter.md +103 -0
  2. package/audit/01-scope-map.md +84 -0
  3. package/audit/02-coverage-matrix.csv +174 -0
  4. package/audit/03-invariants.md +123 -0
  5. package/audit/04-standards-rubric.md +56 -0
  6. package/audit/05-competitor-rubric.md +77 -0
  7. package/audit/06-findings.md +160 -0
  8. package/audit/07-risk-register.csv +10 -0
  9. package/audit/08-remediation-roadmap.md +177 -0
  10. package/audit/09-signoff-check.md +23 -0
  11. package/audit/10-final-synthesis.md +29 -0
  12. package/audit/evidence/code/all-files-json-rest-api.txt +168 -0
  13. package/audit/evidence/code/all-files-json-rest-schema.txt +12 -0
  14. package/audit/evidence/code/boundary-leak-checks.txt +72 -0
  15. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__bulk-operations-plugin.js.txt +480 -0
  16. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__express-plugin.js.txt +532 -0
  17. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__lib__busboy-detector.js.txt +175 -0
  18. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__lib__formidable-detector.js.txt +138 -0
  19. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__lib__request-helpers.js.txt +222 -0
  20. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__file-handling-plugin.js.txt +342 -0
  21. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__dbTablesOperations.js.txt +304 -0
  22. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__fractional-positioning.js.txt +188 -0
  23. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__compile-schemas.js.txt +336 -0
  24. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__connectors-query-parser.js.txt +165 -0
  25. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__database-capabilities.js.txt +265 -0
  26. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__database-value-normalizers.js.txt +369 -0
  27. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__default-data-helpers.js.txt +72 -0
  28. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__field-utils.js.txt +139 -0
  29. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__knex-constants.js.txt +45 -0
  30. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__knex-field-helpers.js.txt +396 -0
  31. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__knex-json-api-transformers.js.txt +162 -0
  32. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__payload-validators.js.txt +1314 -0
  33. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__schema-helpers.js.txt +488 -0
  34. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__scope-validations.js.txt +484 -0
  35. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__simplified-helpers.js.txt +857 -0
  36. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-cross-table-search.js.txt +565 -0
  37. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-json-api-transformers-querying.js.txt +485 -0
  38. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-pagination-helpers.js.txt +560 -0
  39. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-process-includes.js.txt +167 -0
  40. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-query-helpers-base.js.txt +109 -0
  41. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-query-helpers.js.txt +1064 -0
  42. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-relationship-includes.js.txt +1983 -0
  43. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-window-queries.js.txt +328 -0
  44. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__url-helpers.js.txt +119 -0
  45. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__storage__storage-adapter.js.txt +160 -0
  46. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__writing__many-to-many-manipulations.js.txt +300 -0
  47. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__writing__relationship-processor.js.txt +245 -0
  48. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-access.js.txt +459 -0
  49. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-cors-plugin.js.txt +237 -0
  50. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-knex-plugin.js.txt +1135 -0
  51. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-multihome-plugin.js.txt +314 -0
  52. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__compile-resource-schemas.js.txt +7 -0
  53. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__register-relationship-routes.js.txt +71 -0
  54. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__register-scope-routes.js.txt +102 -0
  55. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__turn-scope-init-into-vars.js.txt +49 -0
  56. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__validate-include-configurations.js.txt +39 -0
  57. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__add-route.js.txt +23 -0
  58. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__check-permissions.js.txt +13 -0
  59. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__common.js.txt +639 -0
  60. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__delete-relationship.js.txt +117 -0
  61. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__delete.js.txt +104 -0
  62. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__enrich-attributes.js.txt +199 -0
  63. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__get-related.js.txt +353 -0
  64. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__get-relationship.js.txt +61 -0
  65. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__get.js.txt +184 -0
  66. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__patch-relationship.js.txt +55 -0
  67. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__patch.js.txt +191 -0
  68. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__post-relationship.js.txt +110 -0
  69. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__post.js.txt +168 -0
  70. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__put.js.txt +253 -0
  71. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__query.js.txt +207 -0
  72. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__release.js.txt +12 -0
  73. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin.js.txt +165 -0
  74. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-positioning-plugin.js.txt +668 -0
  75. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__socketio-plugin.js.txt +621 -0
  76. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__storage__local-storage.js.txt +218 -0
  77. package/audit/evidence/code/critical-pass1/json-rest-api__plugins__storage__s3-storage.js.txt +124 -0
  78. package/audit/evidence/code/critical-pass1/json-rest-schema__src__CorePlugin.js.txt +269 -0
  79. package/audit/evidence/code/critical-pass1/json-rest-schema__src__Schema.js.txt +242 -0
  80. package/audit/evidence/code/critical-pass1/json-rest-schema__src__index.js.txt +77 -0
  81. package/audit/evidence/code/critical-pass1-risk-keywords.txt +238 -0
  82. package/audit/evidence/code/critical-pass1-summary.csv +67 -0
  83. package/audit/evidence/code/critical-pass2-summary.csv +67 -0
  84. package/audit/evidence/code/early-silent-zones-no-test-token.txt +57 -0
  85. package/audit/evidence/code/error-model-signals.txt +98 -0
  86. package/audit/evidence/code/git-files-json-rest-api.txt +171 -0
  87. package/audit/evidence/code/git-files-json-rest-schema.txt +27 -0
  88. package/audit/evidence/code/hook-flow-signals.txt +282 -0
  89. package/audit/evidence/code/idproperty-signals.txt +157 -0
  90. package/audit/evidence/code/import-cycles-non-anyapi.txt +3 -0
  91. package/audit/evidence/code/import-hotspots-non-anyapi.txt +96 -0
  92. package/audit/evidence/code/imports-json-rest-api.txt +354 -0
  93. package/audit/evidence/code/imports-json-rest-schema.txt +15 -0
  94. package/audit/evidence/code/in-scope-files-json-rest-api.txt +160 -0
  95. package/audit/evidence/code/in-scope-files-json-rest-schema.txt +13 -0
  96. package/audit/evidence/code/non-anyapi-core-files.txt +101 -0
  97. package/audit/evidence/code/permission-signals.txt +193 -0
  98. package/audit/evidence/code/query-include-signals.txt +687 -0
  99. package/audit/evidence/code/transaction-signals.txt +28 -0
  100. package/audit/evidence/code/validation-signals.txt +650 -0
  101. package/audit/evidence/code/write-path-signals.txt +61 -0
  102. package/audit/evidence/docs/docs-claims-signals.txt +1075 -0
  103. package/audit/evidence/docs/schema-docs-claims-signals.txt +179 -0
  104. package/audit/evidence/external/corpus-freeze.md +21 -0
  105. package/audit/evidence/external/npm-competitor-metadata.txt +70 -0
  106. package/audit/evidence/external/npm-download-signals.txt +23 -0
  107. package/audit/evidence/external/npm-jsonapi-server.txt +8 -0
  108. package/audit/evidence/external/npm-modern-jsonapi-metadata.txt +38 -0
  109. package/audit/evidence/external/readme-fortune-signals.txt +26 -0
  110. package/audit/evidence/external/readme-fortune.md +165 -0
  111. package/audit/evidence/external/readme-json-api-serializer-signals.txt +80 -0
  112. package/audit/evidence/external/readme-json-api-serializer.md +690 -0
  113. package/audit/evidence/external/readme-jsonapi-serde-server-signals.txt +0 -0
  114. package/audit/evidence/external/readme-jsonapi-serde-server.md +22 -0
  115. package/audit/evidence/external/readme-jsonapi-serializer-signals.txt +63 -0
  116. package/audit/evidence/external/readme-jsonapi-serializer.md +315 -0
  117. package/audit/evidence/external/readme-jsonapi-server-signals.txt +19 -0
  118. package/audit/evidence/external/readme-jsonapi-server.md +104 -0
  119. package/audit/evidence/external/readme-nestjs-json-api-signals.txt +4 -0
  120. package/audit/evidence/external/readme-nestjs-json-api.md +94 -0
  121. package/audit/evidence/external/readme-yaser-json-api-nestjs-signals.txt +47 -0
  122. package/audit/evidence/external/readme-yaser-json-api-nestjs.md +447 -0
  123. package/audit/evidence/external/standard-jsonapi-snippets.txt +84 -0
  124. package/audit/evidence/external/standard-rfc-snippets.txt +168 -0
  125. package/audit/evidence/external/standards-sources.txt +6 -0
  126. package/audit/evidence/runtime/baseline-commits.txt +2 -0
  127. package/audit/evidence/runtime/db-adapter-assumptions.txt +3 -0
  128. package/audit/evidence/runtime/environment.txt +4 -0
  129. package/audit/evidence/runtime/invariant-runtime-mapping.md +38 -0
  130. package/audit/evidence/runtime/probe-patch-relationship-error.exitcode +1 -0
  131. package/audit/evidence/runtime/probe-patch-relationship-error.log +76 -0
  132. package/audit/evidence/runtime/probe-patch-relationship-error.mjs +67 -0
  133. package/audit/evidence/runtime/probe-patch-relationship-referenceerror.exitcode +1 -0
  134. package/audit/evidence/runtime/probe-patch-relationship-referenceerror.log +62 -0
  135. package/audit/evidence/runtime/probe-patch-relationship-referenceerror.mjs +47 -0
  136. package/audit/evidence/runtime/test-exitcodes.txt +4 -0
  137. package/audit/evidence/runtime/test-summary.md +107 -0
  138. package/audit/evidence/runtime/trace-anchors.txt +61 -0
  139. package/audit/evidence/tests/access-multitenancy-test-signals.txt +125 -0
  140. package/audit/evidence/tests/failing-tests-summary.txt +25 -0
  141. package/audit/evidence/tests/npm-test-json-rest-api.exitcode +1 -0
  142. package/audit/evidence/tests/npm-test-json-rest-api.log +5885 -0
  143. package/audit/evidence/tests/npm-test-json-rest-schema.exitcode +1 -0
  144. package/audit/evidence/tests/npm-test-json-rest-schema.log +356 -0
  145. package/audit/evidence/tests/query-include-test-signals.txt +948 -0
  146. package/audit/evidence/tests/relationship-test-signals.txt +223 -0
  147. package/audit/evidence/tests/skipped-tests.txt +10 -0
  148. package/audit/evidence/tests/test-suite-list-non-anyapi.txt +30 -0
  149. package/audit/evidence/tests/test-suite-list.txt +32 -0
  150. package/audit/subsystems/docs-drift.md +49 -0
  151. package/audit/subsystems/pass2-cross-review.md +131 -0
  152. package/audit/subsystems/plugins-access.md +51 -0
  153. package/audit/subsystems/plugins-bulk.md +50 -0
  154. package/audit/subsystems/plugins-cors.md +48 -0
  155. package/audit/subsystems/plugins-file.md +53 -0
  156. package/audit/subsystems/plugins-multihome.md +50 -0
  157. package/audit/subsystems/plugins-positioning.md +54 -0
  158. package/audit/subsystems/plugins-socketio.md +50 -0
  159. package/audit/subsystems/query-engine.md +61 -0
  160. package/audit/subsystems/relationships.md +55 -0
  161. package/audit/subsystems/rest-orchestration.md +66 -0
  162. package/audit/subsystems/schema-core.md +64 -0
  163. package/audit/subsystems/storage-knex.md +57 -0
  164. package/audit/subsystems/tests.md +48 -0
  165. package/audit/subsystems/transport-express.md +55 -0
  166. package/audit/traces/trace-read-get.md +22 -0
  167. package/audit/traces/trace-read-query.md +25 -0
  168. package/audit/traces/trace-relationship-endpoints.md +31 -0
  169. package/audit/traces/trace-write-delete.md +17 -0
  170. package/audit/traces/trace-write-patch.md +26 -0
  171. package/audit/traces/trace-write-post.md +22 -0
  172. package/audit/traces/trace-write-put.md +23 -0
  173. package/package.json +5 -5
@@ -0,0 +1,25 @@
1
+ # Trace: Read Query
2
+
3
+ ## Scope
4
+ - Non-anyapi path only.
5
+
6
+ ## Scenario
7
+ - Query collection of resources (`books.query`) with JSON:API envelope.
8
+
9
+ ## Input shape
10
+ - Method call: `api.resources.books.query({ queryParams, simplified: false })`
11
+
12
+ ## Call path
13
+ 1. `register-scope-routes` binds `GET /:scope` to `scope.query` ([plugins/core/rest-api-plugin-hooks/register-scope-routes.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-hooks/register-scope-routes.js)).
14
+ 2. `query.js` validates query params then runs `scope.checkPermissions` before storage ([query.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/query.js)).
15
+ 3. `helpers.dataQuery` builds SQL + include/pagination transforms in knex plugin ([rest-api-knex-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-knex-plugin.js)).
16
+ 4. JSON:API response assembly flows through query transformers and field helpers ([plugins/core/lib/querying/knex-json-api-transformers-querying.js](/home/merc/Development/current/json-rest-api/plugins/core/lib/querying/knex-json-api-transformers-querying.js)).
17
+
18
+ ## Runtime evidence
19
+ - `npm test` confirms collection query path in CRUD suite:
20
+ - `ok 3 - should retrieve collection of resources` at `audit/evidence/tests/npm-test-json-rest-api.log:5490`
21
+ - suite pass marker `ok 2 - GET - Retrieve Resources` at `...:5495`
22
+
23
+ ## Result
24
+ - [Verified][C4] Standard read-query path executes successfully in regression suite.
25
+ - [Unknown][C2] Query-count bound (N+1 avoidance budget) is not asserted by runtime tests.
@@ -0,0 +1,31 @@
1
+ # Trace: Relationship Endpoints
2
+
3
+ ## Scope
4
+ - Non-anyapi path only.
5
+
6
+ ## Scenarios
7
+ 1. Add to-many members: `postRelationship`
8
+ 2. Remove to-many members: `deleteRelationship`
9
+ 3. Replace relationship via patch endpoint: `patchRelationship` error-path probe
10
+
11
+ ## Call path
12
+ - Entry points in relationship method files:
13
+ - [post-relationship.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/post-relationship.js)
14
+ - [delete-relationship.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/delete-relationship.js)
15
+ - [patch-relationship.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/patch-relationship.js)
16
+ - Core relationship mutation helpers:
17
+ - [relationship-processor.js](/home/merc/Development/current/json-rest-api/plugins/core/lib/writing/relationship-processor.js)
18
+ - [many-to-many-manipulations.js](/home/merc/Development/current/json-rest-api/plugins/core/lib/writing/many-to-many-manipulations.js)
19
+
20
+ ## Runtime evidence
21
+ - Relationship endpoint suite passes post/delete paths:
22
+ - `ok 2 - should add authors to book via POST relationship endpoint` (`...log:5050`)
23
+ - `ok 4 - should remove specific authors via DELETE relationship endpoint` (`...log:5060`)
24
+ - Patch endpoint failure-path defect reproduced by dedicated probe:
25
+ - `handleWriteMethodError is not defined`
26
+ - [probe-patch-relationship-referenceerror.log](/home/merc/Development/current/json-rest-api/audit/evidence/runtime/probe-patch-relationship-referenceerror.log)
27
+
28
+ ## Result
29
+ - [Verified][C4] POST/DELETE relationship endpoint behavior is covered and passing.
30
+ - [Verified][C5] PATCH relationship endpoint has a runtime error-handling defect on failure paths.
31
+ - [Unknown][C2] No upstream suite currently asserts successful `patchRelationship` endpoint behavior directly.
@@ -0,0 +1,17 @@
1
+ # Trace: Write Delete
2
+
3
+ ## Scope
4
+ - Non-anyapi path only.
5
+
6
+ ## Scenario
7
+ - Delete single resource and return 204-style no-content path.
8
+
9
+ ## Call path
10
+ 1. `delete.js` creates/uses transaction, fetches minimal record, checks permissions, then invokes `helpers.dataDelete` ([delete.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/delete.js)).
11
+ 2. Commit and afterCommit hooks run on success; rollback on errors via common handling.
12
+
13
+ ## Runtime evidence
14
+ - CRUD suite: `ok 1 - should delete an existing resource` at `audit/evidence/tests/npm-test-json-rest-api.log:5514`.
15
+
16
+ ## Result
17
+ - [Verified][C4] Delete flow is validated in regression suite.
@@ -0,0 +1,26 @@
1
+ # Trace: Write Patch
2
+
3
+ ## Scope
4
+ - Non-anyapi path only.
5
+
6
+ ## Scenario A
7
+ - Standard partial update (`scope.patch`) in CRUD path.
8
+
9
+ ## Scenario B
10
+ - Relationship endpoint patch error-path (`patchRelationship`) with malformed relationship payload.
11
+
12
+ ## Call path
13
+ 1. Standard patch: `patch.js` -> `setupCommonRequest` -> validators -> permission checks -> `helpers.dataPatch` -> commit/rollback ([patch.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/patch.js)).
14
+ 2. Relationship patch: `patch-relationship.js` wraps and delegates to `scope.patch` with synthesized `relationships` payload.
15
+ 3. Catch path in `patch-relationship.js` calls undefined `handleWriteMethodError` symbol ([patch-relationship.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/patch-relationship.js:53)).
16
+
17
+ ## Runtime evidence
18
+ - Standard patch success: `ok 1 - should partially update a resource` at `audit/evidence/tests/npm-test-json-rest-api.log:5502`.
19
+ - Error-path probe reproduces runtime defect:
20
+ - `ERROR_NAME=ReferenceError`
21
+ - `ERROR_MESSAGE=handleWriteMethodError is not defined`
22
+ - Evidence log: [probe-patch-relationship-referenceerror.log](/home/merc/Development/current/json-rest-api/audit/evidence/runtime/probe-patch-relationship-referenceerror.log)
23
+
24
+ ## Result
25
+ - [Verified][C5] Standard patch path passes.
26
+ - [Verified][C5] Relationship patch error path is broken in runtime (ReferenceError masks original error and bypasses canonical handler flow).
@@ -0,0 +1,22 @@
1
+ # Trace: Write Post
2
+
3
+ ## Scope
4
+ - Non-anyapi path only.
5
+
6
+ ## Scenario
7
+ - Create resource (`countries.post`) with JSON:API payload.
8
+
9
+ ## Input shape
10
+ - `inputRecord.data = { type, attributes, relationships? }`
11
+
12
+ ## Call path
13
+ 1. `post.js` calls `setupCommonRequest` (transaction/context/type checks) ([post.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/post.js)).
14
+ 2. Validation + relationship access checks run before `scope.checkPermissions` and before `helpers.dataPost`.
15
+ 3. `helpers.dataPost` inserts row through knex adapter and returns new ID ([rest-api-knex-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-knex-plugin.js)).
16
+ 4. Commit/rollback handled in method catch/finalization via common helper.
17
+
18
+ ## Runtime evidence
19
+ - `ok 1 - should create a country` and `ok 1 - POST - Create Resources` at `audit/evidence/tests/npm-test-json-rest-api.log:5458,5473`.
20
+
21
+ ## Result
22
+ - [Verified][C4] Post path executes as expected in core CRUD suite.
@@ -0,0 +1,23 @@
1
+ # Trace: Write Put
2
+
3
+ ## Scope
4
+ - Non-anyapi path only.
5
+
6
+ ## Scenario
7
+ - Complete relationship replacement via PUT semantics in relationship-heavy flow.
8
+
9
+ ## Input shape
10
+ - `api.resources.books.put({ id, inputRecord, simplified: false })`
11
+
12
+ ## Call path
13
+ 1. `put.js` runs `setupCommonRequest`, minimal-record lookup, validation, and permission checks before storage ([put.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/put.js)).
14
+ 2. Storage update via `helpers.dataPut` with idProperty-aware adapter path ([rest-api-knex-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-knex-plugin.js)).
15
+ 3. Relationship reconciliation routed through common relationship helpers.
16
+
17
+ ## Runtime evidence
18
+ - Relationship suite confirms PUT replacement path:
19
+ - `ok 2 - should update many-to-many relationships via PUT (complete replacement)` at `audit/evidence/tests/npm-test-json-rest-api.log:5199`
20
+ - Additional custom-id PUT coverage at `...:1869`.
21
+
22
+ ## Result
23
+ - [Verified][C4] Put path works on non-anyapi coverage scenarios.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "json-rest-api",
3
- "version": "1.0.20",
3
+ "version": "1.0.22",
4
4
  "main": "index.js",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -24,8 +24,8 @@
24
24
  "homepage": "https://mobily-enterprises.github.io/json-rest-api",
25
25
  "description": "REST API plugin for hooked-api with JSON:API compliance",
26
26
  "dependencies": {
27
- "hooked-api": "^1.0.23",
28
- "json-rest-schema": "^1.0.11",
27
+ "hooked-api": "^1.0.24",
28
+ "json-rest-schema": "^1.0.12",
29
29
  "semver": "^7.7.2"
30
30
  },
31
31
  "peerDependencies": {
@@ -35,7 +35,7 @@
35
35
  "express": "^4.0.0 || ^5.0.0",
36
36
  "formidable": "^3.0.0",
37
37
  "fractional-indexing": "^3.2.0",
38
- "jose": "^5.10.0",
38
+ "jose": "^5.10.0 || ^6.0.0",
39
39
  "knex": "^3.1.0",
40
40
  "raw-body": "^2.0.0",
41
41
  "redis": "^5.6.0",
@@ -81,7 +81,7 @@
81
81
  "better-sqlite3": "^11.10.0",
82
82
  "express": "^5.1.0",
83
83
  "fractional-indexing": "^3.2.0",
84
- "jose": "^5.10.0",
84
+ "jose": "^6.2.2",
85
85
  "knex": "^3.1.0",
86
86
  "redis": "^5.6.0",
87
87
  "socket.io": "^4.8.1",