sdk-aws-lambda 0.7.1 → 0.7.3

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 (153) hide show
  1. package/dist/domain.objects/TrailCarrier.d.ts +17 -0
  2. package/dist/domain.objects/TrailCarrier.js +3 -0
  3. package/dist/domain.objects/TrailCarrier.js.map +1 -0
  4. package/dist/domain.objects/TrailExidHeader.d.ts +10 -0
  5. package/dist/domain.objects/TrailExidHeader.js +14 -0
  6. package/dist/domain.objects/TrailExidHeader.js.map +1 -0
  7. package/dist/domain.operations/asLambdaEvent/asLambdaEvent.fromApiGateway.js +15 -1
  8. package/dist/domain.operations/asLambdaEvent/asLambdaEvent.fromApiGateway.js.map +1 -1
  9. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.d.ts +50 -27
  10. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.js +18 -61
  11. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.js.map +1 -1
  12. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.viaApiGateway.d.ts +35 -0
  13. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.viaApiGateway.js +80 -0
  14. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.viaApiGateway.js.map +1 -0
  15. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.viaInvoke.d.ts +37 -0
  16. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.viaInvoke.js +70 -0
  17. package/dist/domain.operations/askLambdaEndpoint/askLambdaEndpoint.viaInvoke.js.map +1 -0
  18. package/dist/domain.operations/askLambdaEndpoint/invoke/executeHttpRequest.d.ts +17 -0
  19. package/dist/domain.operations/askLambdaEndpoint/invoke/executeHttpRequest.js +34 -0
  20. package/dist/domain.operations/askLambdaEndpoint/invoke/executeHttpRequest.js.map +1 -0
  21. package/dist/domain.operations/askLambdaEndpoint/serde/asErrorFromHttpResponse.d.ts +31 -0
  22. package/dist/domain.operations/askLambdaEndpoint/serde/asErrorFromHttpResponse.js +55 -0
  23. package/dist/domain.operations/askLambdaEndpoint/serde/asErrorFromHttpResponse.js.map +1 -0
  24. package/dist/domain.operations/askLambdaEndpoint/serde/asHeadersRecord.d.ts +13 -0
  25. package/dist/domain.operations/askLambdaEndpoint/serde/asHeadersRecord.js +22 -0
  26. package/dist/domain.operations/askLambdaEndpoint/serde/asHeadersRecord.js.map +1 -0
  27. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpMethod.d.ts +16 -0
  28. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpMethod.js +22 -0
  29. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpMethod.js.map +1 -0
  30. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpRequestBody.d.ts +17 -0
  31. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpRequestBody.js +28 -0
  32. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpRequestBody.js.map +1 -0
  33. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpRequestHeaders.d.ts +23 -0
  34. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpRequestHeaders.js +39 -0
  35. package/dist/domain.operations/askLambdaEndpoint/serde/asHttpRequestHeaders.js.map +1 -0
  36. package/dist/domain.operations/askLambdaEndpoint/serde/getOneBodyFromHttpText.d.ts +10 -0
  37. package/dist/domain.operations/askLambdaEndpoint/serde/getOneBodyFromHttpText.js +19 -0
  38. package/dist/domain.operations/askLambdaEndpoint/serde/getOneBodyFromHttpText.js.map +1 -0
  39. package/dist/domain.operations/askLambdaEndpoint/serde/getOneCorrelationIdFromBody.d.ts +11 -0
  40. package/dist/domain.operations/askLambdaEndpoint/serde/getOneCorrelationIdFromBody.js +19 -0
  41. package/dist/domain.operations/askLambdaEndpoint/serde/getOneCorrelationIdFromBody.js.map +1 -0
  42. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/asCorsHeadersWithTrail.d.ts +12 -0
  43. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/asCorsHeadersWithTrail.js +27 -0
  44. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/asCorsHeadersWithTrail.js.map +1 -0
  45. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/genLambdaEndpoint.forApiGateway.d.ts +3 -0
  46. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/genLambdaEndpoint.forApiGateway.js +32 -7
  47. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/genLambdaEndpoint.forApiGateway.js.map +1 -1
  48. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/middleware/genApiGatewayRequestEventNormalizationMiddleware.js +22 -0
  49. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forApiGateway/middleware/genApiGatewayRequestEventNormalizationMiddleware.js.map +1 -1
  50. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forAsk/genLambdaEndpoint.forAsk.js +13 -2
  51. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forAsk/genLambdaEndpoint.forAsk.js.map +1 -1
  52. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asCallerFault.d.ts +14 -0
  53. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asCallerFault.js +20 -0
  54. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asCallerFault.js.map +1 -0
  55. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asSqsBatchResponse.d.ts +9 -0
  56. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asSqsBatchResponse.js +13 -0
  57. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asSqsBatchResponse.js.map +1 -0
  58. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asSqsRecordIds.d.ts +10 -0
  59. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asSqsRecordIds.js +11 -0
  60. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/asSqsRecordIds.js.map +1 -0
  61. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genLambdaEndpoint.forSqs.perBatch.d.ts +9 -3
  62. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genLambdaEndpoint.forSqs.perBatch.js +40 -38
  63. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genLambdaEndpoint.forSqs.perBatch.js.map +1 -1
  64. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genLambdaEndpoint.forSqs.perRecord.d.ts +12 -6
  65. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genLambdaEndpoint.forSqs.perRecord.js +59 -35
  66. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genLambdaEndpoint.forSqs.perRecord.js.map +1 -1
  67. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genSqsEndpointMiddlewares.d.ts +20 -7
  68. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genSqsEndpointMiddlewares.js +21 -9
  69. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/genSqsEndpointMiddlewares.js.map +1 -1
  70. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsIdsRetried.d.ts +19 -0
  71. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsIdsRetried.js +22 -0
  72. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsIdsRetried.js.map +1 -0
  73. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsIdsUnclaimable.d.ts +11 -0
  74. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsIdsUnclaimable.js +13 -0
  75. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsIdsUnclaimable.js.map +1 -0
  76. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsSuccessRefsMalformed.d.ts +11 -0
  77. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsSuccessRefsMalformed.js +18 -0
  78. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/getAllSqsSuccessRefsMalformed.js.map +1 -0
  79. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/isSqsSuccessRef.d.ts +8 -0
  80. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/isSqsSuccessRef.js +14 -0
  81. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/isSqsSuccessRef.js.map +1 -0
  82. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/logSqsRecordInvalid.d.ts +15 -0
  83. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/logSqsRecordInvalid.js +22 -0
  84. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/logSqsRecordInvalid.js.map +1 -0
  85. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/logSqsRecordRefused.d.ts +27 -0
  86. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/logSqsRecordRefused.js +33 -0
  87. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/logSqsRecordRefused.js.map +1 -0
  88. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/setSqsRecordValidated.d.ts +6 -5
  89. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/setSqsRecordValidated.js +6 -5
  90. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/setSqsRecordValidated.js.map +1 -1
  91. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/setSqsRecordsValidated.d.ts +31 -0
  92. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/setSqsRecordsValidated.js +46 -0
  93. package/dist/domain.operations/genLambdaEndpoint/genLambdaEndpoint.forSqs/setSqsRecordsValidated.js.map +1 -0
  94. package/dist/domain.operations/genLambdaEndpoint/middleware/genTrailMiddleware.d.ts +15 -8
  95. package/dist/domain.operations/genLambdaEndpoint/middleware/genTrailMiddleware.js +57 -12
  96. package/dist/domain.operations/genLambdaEndpoint/middleware/genTrailMiddleware.js.map +1 -1
  97. package/dist/domain.operations/lambdaEndpointWire/frame/asHeadersWithoutKey.d.ts +11 -0
  98. package/dist/domain.operations/lambdaEndpointWire/frame/asHeadersWithoutKey.js +13 -0
  99. package/dist/domain.operations/lambdaEndpointWire/frame/asHeadersWithoutKey.js.map +1 -0
  100. package/dist/domain.operations/lambdaEndpointWire/frame/asTrailExidHeaders.d.ts +23 -0
  101. package/dist/domain.operations/lambdaEndpointWire/frame/asTrailExidHeaders.js +32 -0
  102. package/dist/domain.operations/lambdaEndpointWire/frame/asTrailExidHeaders.js.map +1 -0
  103. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfEvent.d.ts +20 -0
  104. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfEvent.js +23 -0
  105. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfEvent.js.map +1 -0
  106. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfHandler.d.ts +9 -0
  107. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfHandler.js +19 -0
  108. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfHandler.js.map +1 -0
  109. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailExidFromHeaders.d.ts +16 -0
  110. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailExidFromHeaders.js +24 -0
  111. package/dist/domain.operations/lambdaEndpointWire/frame/getOneTrailExidFromHeaders.js.map +1 -0
  112. package/dist/domain.operations/lambdaEndpointWire/frame/isEventDeclaredAsApiGateway.d.ts +9 -0
  113. package/dist/domain.operations/lambdaEndpointWire/frame/isEventDeclaredAsApiGateway.js +15 -0
  114. package/dist/domain.operations/lambdaEndpointWire/frame/isEventDeclaredAsApiGateway.js.map +1 -0
  115. package/dist/domain.operations/lambdaEndpointWire/frame/isTrailExid.d.ts +19 -0
  116. package/dist/domain.operations/lambdaEndpointWire/frame/isTrailExid.js +27 -0
  117. package/dist/domain.operations/lambdaEndpointWire/frame/isTrailExid.js.map +1 -0
  118. package/dist/domain.operations/lambdaEndpointWire/frame/isTrailExidHeaderMalformed.d.ts +11 -0
  119. package/dist/domain.operations/lambdaEndpointWire/frame/isTrailExidHeaderMalformed.js +21 -0
  120. package/dist/domain.operations/lambdaEndpointWire/frame/isTrailExidHeaderMalformed.js.map +1 -0
  121. package/dist/domain.operations/lambdaEndpointWire/frame/setEventDeclaredAsApiGateway.d.ts +21 -0
  122. package/dist/domain.operations/lambdaEndpointWire/frame/setEventDeclaredAsApiGateway.js +27 -0
  123. package/dist/domain.operations/lambdaEndpointWire/frame/setEventDeclaredAsApiGateway.js.map +1 -0
  124. package/dist/domain.operations/lambdaEndpointWire/frame/setHandlerTrailCarrier.d.ts +24 -0
  125. package/dist/domain.operations/lambdaEndpointWire/frame/setHandlerTrailCarrier.js +28 -0
  126. package/dist/domain.operations/lambdaEndpointWire/frame/setHandlerTrailCarrier.js.map +1 -0
  127. package/dist/domain.operations/runLambdaEndpoint/error/isErrorLike.d.ts +6 -1
  128. package/dist/domain.operations/runLambdaEndpoint/error/isErrorLike.js +6 -1
  129. package/dist/domain.operations/runLambdaEndpoint/error/isErrorLike.js.map +1 -1
  130. package/dist/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onReferenced.d.ts +7 -0
  131. package/dist/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onReferenced.js +18 -2
  132. package/dist/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onReferenced.js.map +1 -1
  133. package/dist/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onSerialized.js +43 -7
  134. package/dist/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onSerialized.js.map +1 -1
  135. package/dist/domain.operations/runLambdaEndpoint/serde/asCarriedPayload.d.ts +35 -0
  136. package/dist/domain.operations/runLambdaEndpoint/serde/asCarriedPayload.js +81 -0
  137. package/dist/domain.operations/runLambdaEndpoint/serde/asCarriedPayload.js.map +1 -0
  138. package/dist/domain.operations/runLambdaEndpoint/serde/asErrorTypeOfErrorLike.d.ts +41 -0
  139. package/dist/domain.operations/runLambdaEndpoint/serde/asErrorTypeOfErrorLike.js +116 -0
  140. package/dist/domain.operations/runLambdaEndpoint/serde/asErrorTypeOfErrorLike.js.map +1 -0
  141. package/dist/domain.operations/runLambdaEndpoint/serde/asWireFunctionErrorPayload.js +52 -17
  142. package/dist/domain.operations/runLambdaEndpoint/serde/asWireFunctionErrorPayload.js.map +1 -1
  143. package/dist/domain.operations/runLambdaEndpoint/serde/getOneTrailWithExid.d.ts +14 -0
  144. package/dist/domain.operations/runLambdaEndpoint/serde/getOneTrailWithExid.js +18 -0
  145. package/dist/domain.operations/runLambdaEndpoint/serde/getOneTrailWithExid.js.map +1 -0
  146. package/dist/domain.operations/runLambdaEndpoint/serde/isEventWithHeaders.d.ts +17 -0
  147. package/dist/domain.operations/runLambdaEndpoint/serde/isEventWithHeaders.js +19 -0
  148. package/dist/domain.operations/runLambdaEndpoint/serde/isEventWithHeaders.js.map +1 -0
  149. package/dist/index.d.ts +8 -1
  150. package/dist/index.js +10 -2
  151. package/dist/index.js.map +1 -1
  152. package/package.json +6 -6
  153. package/readme.md +65 -4
@@ -0,0 +1,20 @@
1
+ import type { TrailCarrier } from '../../../domain.objects/TrailCarrier';
2
+ /**
3
+ * .what = which carrier an event's caller must put its trail and contemp opt-in in
4
+ * .why = an event the builder declared as api gateway is built by aws in prod, so no caller can wrap
5
+ * it; its opt-in rides the request's `headers`. every other event keeps the `{ event, trail }`
6
+ * wrapper (`invariant.ancient-vs-contemp-callers.md`)
7
+ *
8
+ * .note = the declaration is the builder's alone. an event's own contents never choose its carrier:
9
+ * an event cannot know which family receives it, and a forwarded request that happens to hold
10
+ * an `x-trail-exid` header is a valid payload for a direct invoke
11
+ * .note = this is the fallback. where the runner holds the handler (`onReferenced`, and the local locus
12
+ * of `onSerialized`) the handler's own declaration decides first (`getOneTrailCarrierOfHandler`),
13
+ * so a copy of a built event is framed for the family that receives it. the event's mark is the
14
+ * only declaration at the cloud locus, which holds no handler
15
+ * .note = both run boundaries (`onReferenced`, and `onSerialized` at cloud) pick the carrier here, so
16
+ * the two cannot disagree. read it BEFORE the json strip, which drops the declaration
17
+ */
18
+ export declare const getOneTrailCarrierOfEvent: (input: {
19
+ event: unknown;
20
+ }) => TrailCarrier;
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getOneTrailCarrierOfEvent = void 0;
4
+ const isEventDeclaredAsApiGateway_1 = require("./isEventDeclaredAsApiGateway");
5
+ /**
6
+ * .what = which carrier an event's caller must put its trail and contemp opt-in in
7
+ * .why = an event the builder declared as api gateway is built by aws in prod, so no caller can wrap
8
+ * it; its opt-in rides the request's `headers`. every other event keeps the `{ event, trail }`
9
+ * wrapper (`invariant.ancient-vs-contemp-callers.md`)
10
+ *
11
+ * .note = the declaration is the builder's alone. an event's own contents never choose its carrier:
12
+ * an event cannot know which family receives it, and a forwarded request that happens to hold
13
+ * an `x-trail-exid` header is a valid payload for a direct invoke
14
+ * .note = this is the fallback. where the runner holds the handler (`onReferenced`, and the local locus
15
+ * of `onSerialized`) the handler's own declaration decides first (`getOneTrailCarrierOfHandler`),
16
+ * so a copy of a built event is framed for the family that receives it. the event's mark is the
17
+ * only declaration at the cloud locus, which holds no handler
18
+ * .note = both run boundaries (`onReferenced`, and `onSerialized` at cloud) pick the carrier here, so
19
+ * the two cannot disagree. read it BEFORE the json strip, which drops the declaration
20
+ */
21
+ const getOneTrailCarrierOfEvent = (input) => (0, isEventDeclaredAsApiGateway_1.isEventDeclaredAsApiGateway)({ event: input.event }) ? 'headers' : 'wrapper';
22
+ exports.getOneTrailCarrierOfEvent = getOneTrailCarrierOfEvent;
23
+ //# sourceMappingURL=getOneTrailCarrierOfEvent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getOneTrailCarrierOfEvent.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfEvent.ts"],"names":[],"mappings":";;;AACA,+EAA4E;AAE5E;;;;;;;;;;;;;;;GAeG;AACI,MAAM,yBAAyB,GAAG,CAAC,KAEzC,EAAgB,EAAE,CACjB,IAAA,yDAA2B,EAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC;AAHjE,QAAA,yBAAyB,6BAGwC"}
@@ -0,0 +1,9 @@
1
+ import type { TrailCarrier } from '../../../domain.objects/TrailCarrier';
2
+ /**
3
+ * .what = the carrier a handler declares, or null for a handler that declares none
4
+ * .why = a plain lambda handler (an unmigrated `createStandardHandler`) is built by no `genLambdaEndpoint`
5
+ * family, so it declares none, and the caller falls back to the event's own declaration
6
+ */
7
+ export declare const getOneTrailCarrierOfHandler: (input: {
8
+ handler: unknown;
9
+ }) => TrailCarrier | null;
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getOneTrailCarrierOfHandler = void 0;
4
+ const setHandlerTrailCarrier_1 = require("./setHandlerTrailCarrier");
5
+ /**
6
+ * .what = the carrier a handler declares, or null for a handler that declares none
7
+ * .why = a plain lambda handler (an unmigrated `createStandardHandler`) is built by no `genLambdaEndpoint`
8
+ * family, so it declares none, and the caller falls back to the event's own declaration
9
+ */
10
+ const getOneTrailCarrierOfHandler = (input) => {
11
+ if (typeof input.handler !== 'function')
12
+ return null;
13
+ const carrier = Reflect.get(input.handler, setHandlerTrailCarrier_1.HANDLER_TRAIL_CARRIER);
14
+ if (carrier === 'wrapper' || carrier === 'headers')
15
+ return carrier;
16
+ return null;
17
+ };
18
+ exports.getOneTrailCarrierOfHandler = getOneTrailCarrierOfHandler;
19
+ //# sourceMappingURL=getOneTrailCarrierOfHandler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getOneTrailCarrierOfHandler.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/getOneTrailCarrierOfHandler.ts"],"names":[],"mappings":";;;AACA,qEAAiE;AAEjE;;;;GAIG;AACI,MAAM,2BAA2B,GAAG,CAAC,KAE3C,EAAuB,EAAE;IACxB,IAAI,OAAO,KAAK,CAAC,OAAO,KAAK,UAAU;QAAE,OAAO,IAAI,CAAC;IACrD,MAAM,OAAO,GAAY,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,OAAO,EAAE,8CAAqB,CAAC,CAAC;IAC3E,IAAI,OAAO,KAAK,SAAS,IAAI,OAAO,KAAK,SAAS;QAAE,OAAO,OAAO,CAAC;IACnE,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAPW,QAAA,2BAA2B,+BAOtC"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * .what = reads the caller's exid out of a headers bag, or null when the bag carries none
3
+ * .why = the exid's presence IS the contemp opt-in at an aws-delivered family
4
+ * (`invariant.ancient-vs-contemp-callers.md`)
5
+ *
6
+ * .note = a value that is not a well-formed exid (empty, past the length bound, or with a control
7
+ * character) reads as ABSENT, so a public caller cannot place unbounded or forged text in the
8
+ * sdk's logs and responses. the request then reads as ancient, with a fresh exid
9
+ * .note = exactly one key is read — no generic correlation header (`x-amzn-trace-id`, `traceparent`,
10
+ * `x-request-id`) ever opts a caller in, since a proxy that forwards one must not flip an
11
+ * error body (`domain.terms/x-trail-exid.md`)
12
+ * .note = the bag's keys are lowercase by now — event normalization folds them (`headers.md`)
13
+ */
14
+ export declare const getOneTrailExidFromHeaders: (input: {
15
+ headers: Record<string, string | undefined> | null | undefined;
16
+ }) => string | null;
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getOneTrailExidFromHeaders = void 0;
4
+ const TrailExidHeader_1 = require("../../../domain.objects/TrailExidHeader");
5
+ const isTrailExid_1 = require("./isTrailExid");
6
+ /**
7
+ * .what = reads the caller's exid out of a headers bag, or null when the bag carries none
8
+ * .why = the exid's presence IS the contemp opt-in at an aws-delivered family
9
+ * (`invariant.ancient-vs-contemp-callers.md`)
10
+ *
11
+ * .note = a value that is not a well-formed exid (empty, past the length bound, or with a control
12
+ * character) reads as ABSENT, so a public caller cannot place unbounded or forged text in the
13
+ * sdk's logs and responses. the request then reads as ancient, with a fresh exid
14
+ * .note = exactly one key is read — no generic correlation header (`x-amzn-trace-id`, `traceparent`,
15
+ * `x-request-id`) ever opts a caller in, since a proxy that forwards one must not flip an
16
+ * error body (`domain.terms/x-trail-exid.md`)
17
+ * .note = the bag's keys are lowercase by now — event normalization folds them (`headers.md`)
18
+ */
19
+ const getOneTrailExidFromHeaders = (input) => {
20
+ const value = input.headers?.[TrailExidHeader_1.TRAIL_EXID_HEADER];
21
+ return isTrailExid_1.isTrailExid.assess(value) ? value : null;
22
+ };
23
+ exports.getOneTrailExidFromHeaders = getOneTrailExidFromHeaders;
24
+ //# sourceMappingURL=getOneTrailExidFromHeaders.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getOneTrailExidFromHeaders.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/getOneTrailExidFromHeaders.ts"],"names":[],"mappings":";;;AAAA,6EAA4E;AAC5E,+CAA4C;AAE5C;;;;;;;;;;;;GAYG;AACI,MAAM,0BAA0B,GAAG,CAAC,KAE1C,EAAiB,EAAE;IAClB,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,EAAE,CAAC,mCAAiB,CAAC,CAAC;IACjD,OAAO,yBAAW,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;AAClD,CAAC,CAAC;AALW,QAAA,0BAA0B,8BAKrC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * .what = whether an event carries the api gateway declaration
3
+ * .why = the carrier follows the declaration, never the event's shape
4
+ * (`invariant.ancient-vs-contemp-callers.md`). an event built by hand, or spread from a
5
+ * declared one, is undeclared and keeps the `{ event, trail }` wrapper
6
+ */
7
+ export declare const isEventDeclaredAsApiGateway: (input: {
8
+ event: unknown;
9
+ }) => boolean;
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isEventDeclaredAsApiGateway = void 0;
4
+ const setEventDeclaredAsApiGateway_1 = require("./setEventDeclaredAsApiGateway");
5
+ /**
6
+ * .what = whether an event carries the api gateway declaration
7
+ * .why = the carrier follows the declaration, never the event's shape
8
+ * (`invariant.ancient-vs-contemp-callers.md`). an event built by hand, or spread from a
9
+ * declared one, is undeclared and keeps the `{ event, trail }` wrapper
10
+ */
11
+ const isEventDeclaredAsApiGateway = (input) => typeof input.event === 'object' &&
12
+ input.event !== null &&
13
+ Reflect.get(input.event, setEventDeclaredAsApiGateway_1.EVENT_DECLARED_AS_API_GATEWAY) === true;
14
+ exports.isEventDeclaredAsApiGateway = isEventDeclaredAsApiGateway;
15
+ //# sourceMappingURL=isEventDeclaredAsApiGateway.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isEventDeclaredAsApiGateway.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/isEventDeclaredAsApiGateway.ts"],"names":[],"mappings":";;;AAAA,iFAA+E;AAE/E;;;;;GAKG;AACI,MAAM,2BAA2B,GAAG,CAAC,KAE3C,EAAW,EAAE,CACZ,OAAO,KAAK,CAAC,KAAK,KAAK,QAAQ;IAC/B,KAAK,CAAC,KAAK,KAAK,IAAI;IACpB,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,EAAE,4DAA6B,CAAC,KAAK,IAAI,CAAC;AALtD,QAAA,2BAA2B,+BAK2B"}
@@ -0,0 +1,19 @@
1
+ /**
2
+ * .what = the longest exid the sdk accepts from, or writes to, a header
3
+ * .why = an exid is a correlation key, not a payload. the form the sdk mints is `exid:<uuid>`, 41
4
+ * characters, so 128 leaves room for a request id or a prefixed trace without a header that
5
+ * can hold a page of text
6
+ */
7
+ export declare const TRAIL_EXID_LENGTH_MAX = 128;
8
+ /**
9
+ * .what = whether a value is a well-formed trail exid: a string of 1 to 128 printable ascii characters
10
+ * .why = `x-trail-exid` is the first value a public caller can place in this sdk's logs, in every 500's
11
+ * `correlationId`, and in the trail of every downstream call. a caller who sends a page of text,
12
+ * or a control character, would write it all into those places. a bounded printable value cannot
13
+ * forge a log line or grow a header without limit (`domain.terms/x-trail-exid.md`)
14
+ *
15
+ * .note = printable ascii is U+0020 to U+007E. a space is allowed inside the value, never at an end: http
16
+ * trims the ends of a header value, so a padded exid would read differently at each side of the
17
+ * wire and the trace would not join. a tab, a newline, and every control character are not allowed
18
+ */
19
+ export declare const isTrailExid: import("type-fns").AssessWithAssure<unknown, string>;
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isTrailExid = exports.TRAIL_EXID_LENGTH_MAX = void 0;
4
+ const type_fns_1 = require("type-fns");
5
+ /**
6
+ * .what = the longest exid the sdk accepts from, or writes to, a header
7
+ * .why = an exid is a correlation key, not a payload. the form the sdk mints is `exid:<uuid>`, 41
8
+ * characters, so 128 leaves room for a request id or a prefixed trace without a header that
9
+ * can hold a page of text
10
+ */
11
+ exports.TRAIL_EXID_LENGTH_MAX = 128;
12
+ /**
13
+ * .what = whether a value is a well-formed trail exid: a string of 1 to 128 printable ascii characters
14
+ * .why = `x-trail-exid` is the first value a public caller can place in this sdk's logs, in every 500's
15
+ * `correlationId`, and in the trail of every downstream call. a caller who sends a page of text,
16
+ * or a control character, would write it all into those places. a bounded printable value cannot
17
+ * forge a log line or grow a header without limit (`domain.terms/x-trail-exid.md`)
18
+ *
19
+ * .note = printable ascii is U+0020 to U+007E. a space is allowed inside the value, never at an end: http
20
+ * trims the ends of a header value, so a padded exid would read differently at each side of the
21
+ * wire and the trace would not join. a tab, a newline, and every control character are not allowed
22
+ */
23
+ exports.isTrailExid = (0, type_fns_1.withAssure)((value) => typeof value === 'string' &&
24
+ value.length >= 1 &&
25
+ value.length <= exports.TRAIL_EXID_LENGTH_MAX &&
26
+ /^[\x21-\x7e]([\x20-\x7e]*[\x21-\x7e])?$/.test(value), { name: 'isTrailExid' });
27
+ //# sourceMappingURL=isTrailExid.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isTrailExid.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/isTrailExid.ts"],"names":[],"mappings":";;;AAAA,uCAAsC;AAEtC;;;;;GAKG;AACU,QAAA,qBAAqB,GAAG,GAAG,CAAC;AAEzC;;;;;;;;;;GAUG;AACU,QAAA,WAAW,GAAG,IAAA,qBAAU,EACnC,CAAC,KAAc,EAAmB,EAAE,CAClC,OAAO,KAAK,KAAK,QAAQ;IACzB,KAAK,CAAC,MAAM,IAAI,CAAC;IACjB,KAAK,CAAC,MAAM,IAAI,6BAAqB;IACrC,yCAAyC,CAAC,IAAI,CAAC,KAAK,CAAC,EACvD,EAAE,IAAI,EAAE,aAAa,EAAE,CACxB,CAAC"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * .what = whether a headers bag holds an `x-trail-exid` a caller meant as the opt-in, which the endpoint
3
+ * reads as absent because the value is malformed
4
+ * .why = a malformed value opts a caller out in silence: the caller is answered ancient and its trace does
5
+ * not join. the endpoint logs this, with the length and never the text, so the drop leaves a signal
6
+ *
7
+ * .note = an empty value is absent, not malformed: a client that sends an empty header meant no opt-in
8
+ */
9
+ export declare const isTrailExidHeaderMalformed: (input: {
10
+ headers: Record<string, string | undefined> | null | undefined;
11
+ }) => boolean;
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isTrailExidHeaderMalformed = void 0;
4
+ const TrailExidHeader_1 = require("../../../domain.objects/TrailExidHeader");
5
+ const isTrailExid_1 = require("./isTrailExid");
6
+ /**
7
+ * .what = whether a headers bag holds an `x-trail-exid` a caller meant as the opt-in, which the endpoint
8
+ * reads as absent because the value is malformed
9
+ * .why = a malformed value opts a caller out in silence: the caller is answered ancient and its trace does
10
+ * not join. the endpoint logs this, with the length and never the text, so the drop leaves a signal
11
+ *
12
+ * .note = an empty value is absent, not malformed: a client that sends an empty header meant no opt-in
13
+ */
14
+ const isTrailExidHeaderMalformed = (input) => {
15
+ const value = input.headers?.[TrailExidHeader_1.TRAIL_EXID_HEADER];
16
+ if (typeof value !== 'string' || value === '')
17
+ return false;
18
+ return !isTrailExid_1.isTrailExid.assess(value);
19
+ };
20
+ exports.isTrailExidHeaderMalformed = isTrailExidHeaderMalformed;
21
+ //# sourceMappingURL=isTrailExidHeaderMalformed.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isTrailExidHeaderMalformed.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/isTrailExidHeaderMalformed.ts"],"names":[],"mappings":";;;AAAA,6EAA4E;AAC5E,+CAA4C;AAE5C;;;;;;;GAOG;AACI,MAAM,0BAA0B,GAAG,CAAC,KAE1C,EAAW,EAAE;IACZ,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,EAAE,CAAC,mCAAiB,CAAC,CAAC;IACjD,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,EAAE;QAAE,OAAO,KAAK,CAAC;IAC5D,OAAO,CAAC,yBAAW,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AACpC,CAAC,CAAC;AANW,QAAA,0BAA0B,8BAMrC"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * .what = the mark `asLambdaEvent.fromApiGateway` leaves on an event it built
3
+ * .why = `runLambdaEndpoint` must pick the carrier — header or wrapper — and the sdk never sniffs an
4
+ * event's shape for it (`invariant.ancient-vs-contemp-callers.md`). the builder knows what it
5
+ * built, so it declares it
6
+ *
7
+ * .note = `Symbol.for`, so two copies of this package in one process still agree on the mark
8
+ */
9
+ export declare const EVENT_DECLARED_AS_API_GATEWAY: unique symbol;
10
+ /**
11
+ * .what = declares an event as an api gateway event, and returns the same event
12
+ * .why = the declaration travels WITH the event object, so a test author's event reaches
13
+ * `runLambdaEndpoint` still declared
14
+ *
15
+ * .note = non-enumerable, so it appears in no spread, no snapshot, no `toEqual`, and no json —
16
+ * `runLambdaEndpoint` reads it BEFORE its json strip, which would drop it
17
+ * .note = DELIBERATE MUTATION — of the fresh object the builder just made, never of a caller's
18
+ */
19
+ export declare const setEventDeclaredAsApiGateway: <TEvent extends object>(input: {
20
+ event: TEvent;
21
+ }) => TEvent;
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.setEventDeclaredAsApiGateway = exports.EVENT_DECLARED_AS_API_GATEWAY = void 0;
4
+ /**
5
+ * .what = the mark `asLambdaEvent.fromApiGateway` leaves on an event it built
6
+ * .why = `runLambdaEndpoint` must pick the carrier — header or wrapper — and the sdk never sniffs an
7
+ * event's shape for it (`invariant.ancient-vs-contemp-callers.md`). the builder knows what it
8
+ * built, so it declares it
9
+ *
10
+ * .note = `Symbol.for`, so two copies of this package in one process still agree on the mark
11
+ */
12
+ exports.EVENT_DECLARED_AS_API_GATEWAY = Symbol.for('sdk-aws-lambda.event.declaredAs.apiGateway');
13
+ /**
14
+ * .what = declares an event as an api gateway event, and returns the same event
15
+ * .why = the declaration travels WITH the event object, so a test author's event reaches
16
+ * `runLambdaEndpoint` still declared
17
+ *
18
+ * .note = non-enumerable, so it appears in no spread, no snapshot, no `toEqual`, and no json —
19
+ * `runLambdaEndpoint` reads it BEFORE its json strip, which would drop it
20
+ * .note = DELIBERATE MUTATION — of the fresh object the builder just made, never of a caller's
21
+ */
22
+ const setEventDeclaredAsApiGateway = (input) => Object.defineProperty(input.event, exports.EVENT_DECLARED_AS_API_GATEWAY, {
23
+ value: true,
24
+ enumerable: false,
25
+ });
26
+ exports.setEventDeclaredAsApiGateway = setEventDeclaredAsApiGateway;
27
+ //# sourceMappingURL=setEventDeclaredAsApiGateway.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setEventDeclaredAsApiGateway.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/setEventDeclaredAsApiGateway.ts"],"names":[],"mappings":";;;AAAA;;;;;;;GAOG;AACU,QAAA,6BAA6B,GAAG,MAAM,CAAC,GAAG,CACrD,4CAA4C,CAC7C,CAAC;AAEF;;;;;;;;GAQG;AACI,MAAM,4BAA4B,GAAG,CAAwB,KAEnE,EAAU,EAAE,CACX,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,KAAK,EAAE,qCAA6B,EAAE;IAChE,KAAK,EAAE,IAAI;IACX,UAAU,EAAE,KAAK;CAClB,CAAC,CAAC;AANQ,QAAA,4BAA4B,gCAMpC"}
@@ -0,0 +1,24 @@
1
+ import type { TrailCarrier } from '../../../domain.objects/TrailCarrier';
2
+ /**
3
+ * .what = the mark a `genLambdaEndpoint` builder leaves on the handler it returns, which names the
4
+ * carrier that family reads
5
+ * .why = the receiver owns the carrier, and the handler is the receiver. `runLambdaEndpoint` holds the
6
+ * handler at `onReferenced` and at the local locus of `onSerialized`, so it reads the carrier
7
+ * off the handler, and an event copied from a built one (a spread, a clone, a captured request)
8
+ * reaches the endpoint still framed for its family
9
+ *
10
+ * .note = `Symbol.for`, so two copies of this package in one process still agree on the mark
11
+ */
12
+ export declare const HANDLER_TRAIL_CARRIER: unique symbol;
13
+ /**
14
+ * .what = declares the carrier a handler reads, and returns the same handler
15
+ * .why = each family states its carrier once, beside the `genTrailMiddleware({ carrier })` that reads
16
+ * it, so the endpoint and the runner cannot disagree
17
+ *
18
+ * .note = non-enumerable, so it appears in no spread and no snapshot of the handler
19
+ * .note = DELIBERATE MUTATION — of the fresh handler the builder just made, never of a caller's
20
+ */
21
+ export declare const setHandlerTrailCarrier: <THandler extends object>(input: {
22
+ handler: THandler;
23
+ carrier: TrailCarrier;
24
+ }) => THandler;
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.setHandlerTrailCarrier = exports.HANDLER_TRAIL_CARRIER = void 0;
4
+ /**
5
+ * .what = the mark a `genLambdaEndpoint` builder leaves on the handler it returns, which names the
6
+ * carrier that family reads
7
+ * .why = the receiver owns the carrier, and the handler is the receiver. `runLambdaEndpoint` holds the
8
+ * handler at `onReferenced` and at the local locus of `onSerialized`, so it reads the carrier
9
+ * off the handler, and an event copied from a built one (a spread, a clone, a captured request)
10
+ * reaches the endpoint still framed for its family
11
+ *
12
+ * .note = `Symbol.for`, so two copies of this package in one process still agree on the mark
13
+ */
14
+ exports.HANDLER_TRAIL_CARRIER = Symbol.for('sdk-aws-lambda.handler.trailCarrier');
15
+ /**
16
+ * .what = declares the carrier a handler reads, and returns the same handler
17
+ * .why = each family states its carrier once, beside the `genTrailMiddleware({ carrier })` that reads
18
+ * it, so the endpoint and the runner cannot disagree
19
+ *
20
+ * .note = non-enumerable, so it appears in no spread and no snapshot of the handler
21
+ * .note = DELIBERATE MUTATION — of the fresh handler the builder just made, never of a caller's
22
+ */
23
+ const setHandlerTrailCarrier = (input) => Object.defineProperty(input.handler, exports.HANDLER_TRAIL_CARRIER, {
24
+ value: input.carrier,
25
+ enumerable: false,
26
+ });
27
+ exports.setHandlerTrailCarrier = setHandlerTrailCarrier;
28
+ //# sourceMappingURL=setHandlerTrailCarrier.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setHandlerTrailCarrier.js","sourceRoot":"","sources":["../../../../src/domain.operations/lambdaEndpointWire/frame/setHandlerTrailCarrier.ts"],"names":[],"mappings":";;;AAEA;;;;;;;;;GASG;AACU,QAAA,qBAAqB,GAAG,MAAM,CAAC,GAAG,CAC7C,qCAAqC,CACtC,CAAC;AAEF;;;;;;;GAOG;AACI,MAAM,sBAAsB,GAAG,CAA0B,KAG/D,EAAY,EAAE,CACb,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,OAAO,EAAE,6BAAqB,EAAE;IAC1D,KAAK,EAAE,KAAK,CAAC,OAAO;IACpB,UAAU,EAAE,KAAK;CAClB,CAAC,CAAC;AAPQ,QAAA,sBAAsB,0BAO9B"}
@@ -14,7 +14,7 @@
14
14
  *
15
15
  * | site | what it wanted |
16
16
  * |---|---|
17
- * | `runLambdaEndpoint.onSerialized.ts` (`asWireFunctionErrorPayload`) | `message` · `stack` · `constructor.name` |
17
+ * | `runLambdaEndpoint.onSerialized.ts` (`asWireFunctionErrorPayload`) | `message` · `stack` · `name` |
18
18
  * | `serde/asWireStripped.ts` | the whole `Error`, to hang as a `cause` |
19
19
  * | `local/getOneHandlerFromServerlessYml.ts` | `message`, to branch on a text match |
20
20
  *
@@ -46,5 +46,10 @@
46
46
  * optional on a real `Error` and absent on a plain thrown object; `.name` is
47
47
  * present on a bare `{ name }` bag. `.message` as a string is the one field
48
48
  * every `Error` carries and few impostors do.
49
+ *
50
+ * .note = this is the COARSE narrow, for a site that reads fields. the wire LABEL
51
+ * follows a stricter rule — the aws runtime's `_isError` trio — which lives in
52
+ * `serde/asErrorTypeOfErrorLike.ts`. the two answer different questions, so
53
+ * neither replaces the other.
49
54
  */
50
55
  export declare const isErrorLike: (value: unknown) => value is Error;
@@ -17,7 +17,7 @@ exports.isErrorLike = void 0;
17
17
  *
18
18
  * | site | what it wanted |
19
19
  * |---|---|
20
- * | `runLambdaEndpoint.onSerialized.ts` (`asWireFunctionErrorPayload`) | `message` · `stack` · `constructor.name` |
20
+ * | `runLambdaEndpoint.onSerialized.ts` (`asWireFunctionErrorPayload`) | `message` · `stack` · `name` |
21
21
  * | `serde/asWireStripped.ts` | the whole `Error`, to hang as a `cause` |
22
22
  * | `local/getOneHandlerFromServerlessYml.ts` | `message`, to branch on a text match |
23
23
  *
@@ -49,6 +49,11 @@ exports.isErrorLike = void 0;
49
49
  * optional on a real `Error` and absent on a plain thrown object; `.name` is
50
50
  * present on a bare `{ name }` bag. `.message` as a string is the one field
51
51
  * every `Error` carries and few impostors do.
52
+ *
53
+ * .note = this is the COARSE narrow, for a site that reads fields. the wire LABEL
54
+ * follows a stricter rule — the aws runtime's `_isError` trio — which lives in
55
+ * `serde/asErrorTypeOfErrorLike.ts`. the two answer different questions, so
56
+ * neither replaces the other.
52
57
  */
53
58
  const isErrorLike = (value) => typeof value?.message === 'string';
54
59
  exports.isErrorLike = isErrorLike;
@@ -1 +1 @@
1
- {"version":3,"file":"isErrorLike.js","sourceRoot":"","sources":["../../../../src/domain.operations/runLambdaEndpoint/error/isErrorLike.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;AACI,MAAM,WAAW,GAAG,CAAC,KAAc,EAAkB,EAAE,CAC5D,OAAQ,KAA+B,EAAE,OAAO,KAAK,QAAQ,CAAC;AADnD,QAAA,WAAW,eACwC"}
1
+ {"version":3,"file":"isErrorLike.js","sourceRoot":"","sources":["../../../../src/domain.operations/runLambdaEndpoint/error/isErrorLike.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDG;AACI,MAAM,WAAW,GAAG,CAAC,KAAc,EAAkB,EAAE,CAC5D,OAAQ,KAA+B,EAAE,OAAO,KAAK,QAAQ,CAAC;AADnD,QAAA,WAAW,eACwC"}
@@ -44,6 +44,13 @@ export type LambdaEndpointHandlerReferenced<TEvent, TOutput> = (event: TEvent, c
44
44
  * reads `event.uuid` off the wrapper, finds `undefined`, and takes its own reject
45
45
  * branch — a rejection envelope on the success case, with no type error anywhere.
46
46
  *
47
+ * ⚠️ an event built by `asLambdaEvent.fromApiGateway` is the one exception to the wrapper: aws builds
48
+ * that envelope and no caller can wrap it, so contemp rides the `x-trail-exid` request header
49
+ * instead, and the event is never wrapped. `ancient` sends it raw, with no header. a hand-built
50
+ * api gateway object carries no declaration, so it gets the wrapper and an api gateway endpoint
51
+ * refuses it — build it with `asLambdaEvent.fromApiGateway`
52
+ * (`invariant.ancient-vs-contemp-callers.md`).
53
+ *
47
54
  * ⇒ so a legacy `createStandardHandler` handler needs `struct: { payload: 'ancient' }`.
48
55
  * the frame is DERIVED from `struct.payload`, never from `trail`, so the two
49
56
  * cannot disagree.
@@ -1,11 +1,13 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.onReferenced = void 0;
4
+ const getOneTrailCarrierOfEvent_1 = require("../lambdaEndpointWire/frame/getOneTrailCarrierOfEvent");
5
+ const getOneTrailCarrierOfHandler_1 = require("../lambdaEndpointWire/frame/getOneTrailCarrierOfHandler");
4
6
  const asLambdaContext_1 = require("./context/asLambdaContext");
5
7
  const asLambdaEndpointDialect_1 = require("./dialect/asLambdaEndpointDialect");
6
8
  const assertEventIsGiven_1 = require("./guard/assertEventIsGiven");
7
9
  const assertHandlerIsRunnable_1 = require("./guard/assertHandlerIsRunnable");
8
- const asFramedPayload_1 = require("./serde/asFramedPayload");
10
+ const asCarriedPayload_1 = require("./serde/asCarriedPayload");
9
11
  const asWireStripped_1 = require("./serde/asWireStripped");
10
12
  /**
11
13
  * .what = runs a lambda endpoint you hold a REFERENCE to — the handler function
@@ -42,6 +44,13 @@ const asWireStripped_1 = require("./serde/asWireStripped");
42
44
  * reads `event.uuid` off the wrapper, finds `undefined`, and takes its own reject
43
45
  * branch — a rejection envelope on the success case, with no type error anywhere.
44
46
  *
47
+ * ⚠️ an event built by `asLambdaEvent.fromApiGateway` is the one exception to the wrapper: aws builds
48
+ * that envelope and no caller can wrap it, so contemp rides the `x-trail-exid` request header
49
+ * instead, and the event is never wrapped. `ancient` sends it raw, with no header. a hand-built
50
+ * api gateway object carries no declaration, so it gets the wrapper and an api gateway endpoint
51
+ * refuses it — build it with `asLambdaEvent.fromApiGateway`
52
+ * (`invariant.ancient-vs-contemp-callers.md`).
53
+ *
45
54
  * ⇒ so a legacy `createStandardHandler` handler needs `struct: { payload: 'ancient' }`.
46
55
  * the frame is DERIVED from `struct.payload`, never from `trail`, so the two
47
56
  * cannot disagree.
@@ -89,14 +98,21 @@ const onReferenced = async (input) => {
89
98
  const dialect = (0, asLambdaEndpointDialect_1.asLambdaEndpointDialect)({
90
99
  declared: input.struct?.payload,
91
100
  });
101
+ // the carrier is the receiver's: a handler a `genLambdaEndpoint` builder returned declares it, so a
102
+ // copy of a built event still reaches its family framed right. a plain handler declares none, and
103
+ // the event's own declaration decides, read BEFORE the strip — it is a non-enumerable mark, and the
104
+ // json strip would drop it
105
+ const carrier = (0, getOneTrailCarrierOfHandler_1.getOneTrailCarrierOfHandler)({ handler: input.handler }) ??
106
+ (0, getOneTrailCarrierOfEvent_1.getOneTrailCarrierOfEvent)({ event: input.event });
92
107
  // strip inbound, so no live object reaches the handler that the wire could not deliver
93
108
  // `of: 'event'` — a refusal here is the CALLER's payload, so it raises a ConstraintError
94
109
  const eventStripped = (0, asWireStripped_1.asWireStripped)({ value: input.event, of: 'event' });
95
110
  // frame the payload, so the endpoint reads the dialect the caller declared
96
- const payload = (0, asFramedPayload_1.asFramedPayload)({
111
+ const payload = (0, asCarriedPayload_1.asCarriedPayload)({
97
112
  event: eventStripped,
98
113
  trail: input.trail ?? null,
99
114
  dialect,
115
+ carrier,
100
116
  });
101
117
  const context = (0, asLambdaContext_1.asLambdaContext)(input.context);
102
118
  // shared with the serialized boundary, which needs it ahead of its delegation
@@ -1 +1 @@
1
- {"version":3,"file":"runLambdaEndpoint.onReferenced.js","sourceRoot":"","sources":["../../../src/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onReferenced.ts"],"names":[],"mappings":";;;AAGA,+DAA4D;AAC5D,+EAA4E;AAE5E,mEAAgE;AAChE,6EAA0E;AAC1E,6DAA0D;AAC1D,2DAAwD;AAcxD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkEG;AACI,MAAM,YAAY,GAAG,KAAK,EAI/B,KAyCD,EAAuD,EAAE;IACxD,6EAA6E;IAC7E,2EAA2E;IAC3E,6EAA6E;IAC7E,EAAE;IACF,2EAA2E;IAC3E,8EAA8E;IAC9E,2DAA2D;IAC3D,kCAAkC;IAClC,IAAA,uCAAkB,EAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IAE3D,4EAA4E;IAC5E,kDAAkD;IAClD,MAAM,OAAO,GAA0B,IAAA,iDAAuB,EAAC;QAC7D,QAAQ,EAAE,KAAK,CAAC,MAAM,EAAE,OAAO;KAChC,CAAC,CAAC;IAEH,uFAAuF;IACvF,yFAAyF;IACzF,MAAM,aAAa,GAAG,IAAA,+BAAc,EAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC;IAE1E,2EAA2E;IAC3E,MAAM,OAAO,GAAG,IAAA,iCAAe,EAAC;QAC9B,KAAK,EAAE,aAAa;QACpB,KAAK,EAAE,KAAK,CAAC,KAAK,IAAI,IAAI;QAC1B,OAAO;KACR,CAAC,CAAC;IAEH,MAAM,OAAO,GAAG,IAAA,iCAAe,EAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAE/C,8EAA8E;IAC9E,IAAA,iDAAuB,EAAC,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;IAEpD,+EAA+E;IAC/E,kEAAkE;IAClE,MAAM,MAAM,GAAG,MAAM,KAAK,CAAC,OAAO,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAErD,mFAAmF;IACnF,6EAA6E;IAC7E,EAAE;IACF,gFAAgF;IAChF,4EAA4E;IAC5E,2DAA2D;IAC3D,OAAO,IAAA,+BAAc,EAAC;QACpB,KAAK,EAAE,MAAM;QACb,EAAE,EAAE,QAAQ;KACb,CAA+C,CAAC;AACnD,CAAC,CAAC;AA5FW,QAAA,YAAY,gBA4FvB"}
1
+ {"version":3,"file":"runLambdaEndpoint.onReferenced.js","sourceRoot":"","sources":["../../../src/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onReferenced.ts"],"names":[],"mappings":";;;AAGA,qGAAkG;AAClG,yGAAsG;AACtG,+DAA4D;AAC5D,+EAA4E;AAE5E,mEAAgE;AAChE,6EAA0E;AAC1E,+DAA4D;AAC5D,2DAAwD;AAcxD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyEG;AACI,MAAM,YAAY,GAAG,KAAK,EAI/B,KAyCD,EAAuD,EAAE;IACxD,6EAA6E;IAC7E,2EAA2E;IAC3E,6EAA6E;IAC7E,EAAE;IACF,2EAA2E;IAC3E,8EAA8E;IAC9E,2DAA2D;IAC3D,kCAAkC;IAClC,IAAA,uCAAkB,EAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IAE3D,4EAA4E;IAC5E,kDAAkD;IAClD,MAAM,OAAO,GAA0B,IAAA,iDAAuB,EAAC;QAC7D,QAAQ,EAAE,KAAK,CAAC,MAAM,EAAE,OAAO;KAChC,CAAC,CAAC;IAEH,oGAAoG;IACpG,kGAAkG;IAClG,oGAAoG;IACpG,2BAA2B;IAC3B,MAAM,OAAO,GACX,IAAA,yDAA2B,EAAC,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,CAAC;QACvD,IAAA,qDAAyB,EAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC;IAEpD,uFAAuF;IACvF,yFAAyF;IACzF,MAAM,aAAa,GAAG,IAAA,+BAAc,EAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC;IAE1E,2EAA2E;IAC3E,MAAM,OAAO,GAAG,IAAA,mCAAgB,EAAC;QAC/B,KAAK,EAAE,aAAa;QACpB,KAAK,EAAE,KAAK,CAAC,KAAK,IAAI,IAAI;QAC1B,OAAO;QACP,OAAO;KACR,CAAC,CAAC;IAEH,MAAM,OAAO,GAAG,IAAA,iCAAe,EAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAE/C,8EAA8E;IAC9E,IAAA,iDAAuB,EAAC,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;IAEpD,+EAA+E;IAC/E,kEAAkE;IAClE,MAAM,MAAM,GAAG,MAAM,KAAK,CAAC,OAAO,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAErD,mFAAmF;IACnF,6EAA6E;IAC7E,EAAE;IACF,gFAAgF;IAChF,4EAA4E;IAC5E,2DAA2D;IAC3D,OAAO,IAAA,+BAAc,EAAC;QACpB,KAAK,EAAE,MAAM;QACb,EAAE,EAAE,QAAQ;KACb,CAA+C,CAAC;AACnD,CAAC,CAAC;AArGW,QAAA,YAAY,gBAqGvB"}
@@ -6,6 +6,7 @@ const askLambdaEndpoint_1 = require("../askLambdaEndpoint/askLambdaEndpoint");
6
6
  const asLambdaEndpoint_1 = require("../asLambdaEndpoint/asLambdaEndpoint");
7
7
  const getOneTrailExid_1 = require("../lambdaEndpointWire/context/getOneTrailExid");
8
8
  const throwIfCredentialsError_1 = require("../lambdaEndpointWire/error/throwIfCredentialsError");
9
+ const getOneTrailCarrierOfEvent_1 = require("../lambdaEndpointWire/frame/getOneTrailCarrierOfEvent");
9
10
  const getParsedResponse_1 = require("../lambdaEndpointWire/getParsedResponse");
10
11
  const asLambdaEndpointDialect_1 = require("./dialect/asLambdaEndpointDialect");
11
12
  const assertEventIsGiven_1 = require("./guard/assertEventIsGiven");
@@ -13,6 +14,7 @@ const assertHandlerIsRunnable_1 = require("./guard/assertHandlerIsRunnable");
13
14
  const asLocalRunIdentity_1 = require("./local/asLocalRunIdentity");
14
15
  const getOneHandlerFromServerlessYml_1 = require("./local/getOneHandlerFromServerlessYml");
15
16
  const runLambdaEndpoint_onReferenced_1 = require("./runLambdaEndpoint.onReferenced");
17
+ const asCarriedPayload_1 = require("./serde/asCarriedPayload");
16
18
  const asWireFunctionErrorPayload_1 = require("./serde/asWireFunctionErrorPayload");
17
19
  const asWirePayload_1 = require("./serde/asWirePayload");
18
20
  /**
@@ -110,12 +112,12 @@ const onSerialized = async (input, context) => {
110
112
  // `LambdaCredentialsAbsentError extends ConstraintError` ⇒ caller fault, NO
111
113
  // ALARM. to map it on the runtime path would suppress the prod alarm that
112
114
  // names a broken role (`invariant.badrequesterror-not-lambda-error`).
113
- if (at === 'cloud')
114
- return (0, askLambdaEndpoint_1.askLambdaEndpoint)({
115
- which: input.which,
116
- event: input.event,
117
- struct: structValidated,
118
- }, context).catch((error) => (0, throwIfCredentialsError_1.throwIfCredentialsError)({
115
+ if (at === 'cloud') {
116
+ /**
117
+ * .what = names an absent-credentials fault for a developer at a terminal
118
+ * .why = both calls below reach aws, so both owe the same diagnosis
119
+ */
120
+ const asCredentialsFault = (error) => (0, throwIfCredentialsError_1.throwIfCredentialsError)({
119
121
  error,
120
122
  message: 'aws credentials are absent or expired, so the deployed endpoint cannot be invoked',
121
123
  access: context.env.access,
@@ -124,7 +126,41 @@ const onSerialized = async (input, context) => {
124
126
  access: context.env.access,
125
127
  at,
126
128
  },
127
- }));
129
+ });
130
+ // 🔴 an event the builder declared as api gateway carries the opt-in in its `headers`,
131
+ // since aws builds that envelope and a deployed `forApiGateway` endpoint refuses a
132
+ // `{ event, trail }` wrapper. `askLambdaEndpoint` sends the event as is on the ancient
133
+ // struct, so the carried event goes with that struct — the DIALECT is still the caller's
134
+ // declaration, carried by the header rather than the frame
135
+ const carrier = (0, getOneTrailCarrierOfEvent_1.getOneTrailCarrierOfEvent)({ event: input.event });
136
+ if (carrier === 'headers') {
137
+ // 🔴 the exid is minted ONCE, here, and pinned onto the context `askLambdaEndpoint` reads
138
+ // its own from. two mints would put one exid in the header and another in the call's
139
+ // log and errors (`getOneTrailExid` states the parity this keeps)
140
+ const exid = (0, getOneTrailExid_1.getOneTrailExid)({ log: context.log });
141
+ return (0, askLambdaEndpoint_1.askLambdaEndpoint)({
142
+ which: input.which,
143
+ event: (0, asCarriedPayload_1.asCarriedPayload)({
144
+ event: input.event,
145
+ trail: { exid },
146
+ dialect: dialectValidated,
147
+ carrier,
148
+ }),
149
+ struct: { payload: 'ancient' },
150
+ }, {
151
+ ...context,
152
+ log: {
153
+ ...context.log,
154
+ trail: { exid, stack: context.log.trail?.stack ?? [] },
155
+ },
156
+ }).catch(asCredentialsFault);
157
+ }
158
+ return (0, askLambdaEndpoint_1.askLambdaEndpoint)({
159
+ which: input.which,
160
+ event: input.event,
161
+ struct: structValidated,
162
+ }, context).catch(asCredentialsFault);
163
+ }
128
164
  // the local locus: look the handler up, run it, then hydrate exactly as the wire does
129
165
  const endpoint = (0, asLambdaEndpoint_1.asLambdaEndpoint)({
130
166
  service: input.which.service,
@@ -1 +1 @@
1
- {"version":3,"file":"runLambdaEndpoint.onSerialized.js","sourceRoot":"","sources":["../../../src/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onSerialized.ts"],"names":[],"mappings":";;;AAAA,mDAAiD;AAIjD,8EAA2E;AAC3E,2EAAwE;AACxE,mFAAgF;AAChF,iGAA8F;AAC9F,+EAA4E;AAC5E,+EAA4E;AAE5E,mEAAgE;AAChE,6EAA0E;AAC1E,mEAAgE;AAChE,2FAAwF;AACxF,qFAAgE;AAChE,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,MAAM,IAAA,6CAAY,EAAC;QAChC,KAAK,EAAE,KAAK,CAAC,KAAK;QAClB,OAAO;QACP,MAAM,EAAE,eAAe;QAEvB,6EAA6E;QAC7E,4EAA4E;QAC5E,OAAO,EAAE,IAAA,uCAAkB,EAAC,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,CAAC;QAErE,uEAAuE;QACvE,6EAA6E;QAC7E,kDAAkD;QAClD,0EAA0E;QAC1E,KAAK,EAAE,EAAE,IAAI,EAAE;KAChB,CAAC,CAAC,KAAK,CAAC,uDAA0B,CAAC,CAAC;IAErC,2EAA2E;IAC3E,8EAA8E;IAC9E,yDAAyD;IACzD,OAAO,IAAA,qCAAiB,EAAyB;QAC/C,OAAO,EAAE,IAAA,6BAAa,EAAC,MAAM,CAAC;QAC9B,aAAa,EAAE,SAAS;QACxB,QAAQ;QACR,IAAI;KACL,CAAC,CAAC;AACL,CAAC,CAAC;AAjKW,QAAA,YAAY,gBAiKvB"}
1
+ {"version":3,"file":"runLambdaEndpoint.onSerialized.js","sourceRoot":"","sources":["../../../src/domain.operations/runLambdaEndpoint/runLambdaEndpoint.onSerialized.ts"],"names":[],"mappings":";;;AAAA,mDAAiD;AAIjD,8EAA2E;AAC3E,2EAAwE;AACxE,mFAAgF;AAChF,iGAA8F;AAC9F,qGAAkG;AAClG,+EAA4E;AAC5E,+EAA4E;AAE5E,mEAAgE;AAChE,6EAA0E;AAC1E,mEAAgE;AAChE,2FAAwF;AACxF,qFAAgE;AAChE,+DAA4D;AAC5D,mFAAgF;AAChF,yDAAsD;AAWtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AACI,MAAM,YAAY,GAAG,KAAK,EAC/B,KAiCC,EACD,OAA+B,EACE,EAAE;IACnC,gFAAgF;IAChF,yEAAyE;IACzE,iFAAiF;IACjF,IAAA,uCAAkB,EAAC;QACjB,KAAK,EAAE,KAAK,CA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