@monorise/sst 1.0.0-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (710) hide show
  1. package/dist/.sst/platform/src/components/aws/analog.d.ts +423 -0
  2. package/dist/.sst/platform/src/components/aws/analog.d.ts.map +1 -0
  3. package/dist/.sst/platform/src/components/aws/analog.js +118 -0
  4. package/dist/.sst/platform/src/components/aws/analog.js.map +1 -0
  5. package/dist/.sst/platform/src/components/aws/apigateway-websocket-route.d.ts +74 -0
  6. package/dist/.sst/platform/src/components/aws/apigateway-websocket-route.d.ts.map +1 -0
  7. package/dist/.sst/platform/src/components/aws/apigateway-websocket-route.js +110 -0
  8. package/dist/.sst/platform/src/components/aws/apigateway-websocket-route.js.map +1 -0
  9. package/dist/.sst/platform/src/components/aws/apigateway-websocket.d.ts +542 -0
  10. package/dist/.sst/platform/src/components/aws/apigateway-websocket.d.ts.map +1 -0
  11. package/dist/.sst/platform/src/components/aws/apigateway-websocket.js +409 -0
  12. package/dist/.sst/platform/src/components/aws/apigateway-websocket.js.map +1 -0
  13. package/dist/.sst/platform/src/components/aws/apigatewayv1-api-key.d.ts +48 -0
  14. package/dist/.sst/platform/src/components/aws/apigatewayv1-api-key.d.ts.map +1 -0
  15. package/dist/.sst/platform/src/components/aws/apigatewayv1-api-key.js +55 -0
  16. package/dist/.sst/platform/src/components/aws/apigatewayv1-api-key.js.map +1 -0
  17. package/dist/.sst/platform/src/components/aws/apigatewayv1-authorizer.d.ts +55 -0
  18. package/dist/.sst/platform/src/components/aws/apigatewayv1-authorizer.d.ts.map +1 -0
  19. package/dist/.sst/platform/src/components/aws/apigatewayv1-authorizer.js +110 -0
  20. package/dist/.sst/platform/src/components/aws/apigatewayv1-authorizer.js.map +1 -0
  21. package/dist/.sst/platform/src/components/aws/apigatewayv1-base-route.d.ts +36 -0
  22. package/dist/.sst/platform/src/components/aws/apigatewayv1-base-route.d.ts.map +1 -0
  23. package/dist/.sst/platform/src/components/aws/apigatewayv1-base-route.js +34 -0
  24. package/dist/.sst/platform/src/components/aws/apigatewayv1-base-route.js.map +1 -0
  25. package/dist/.sst/platform/src/components/aws/apigatewayv1-integration-route.d.ts +39 -0
  26. package/dist/.sst/platform/src/components/aws/apigatewayv1-integration-route.d.ts.map +1 -0
  27. package/dist/.sst/platform/src/components/aws/apigatewayv1-integration-route.js +49 -0
  28. package/dist/.sst/platform/src/components/aws/apigatewayv1-integration-route.js.map +1 -0
  29. package/dist/.sst/platform/src/components/aws/apigatewayv1-lambda-route.d.ts +53 -0
  30. package/dist/.sst/platform/src/components/aws/apigatewayv1-lambda-route.d.ts.map +1 -0
  31. package/dist/.sst/platform/src/components/aws/apigatewayv1-lambda-route.js +85 -0
  32. package/dist/.sst/platform/src/components/aws/apigatewayv1-lambda-route.js.map +1 -0
  33. package/dist/.sst/platform/src/components/aws/apigatewayv1-usage-plan.d.ts +53 -0
  34. package/dist/.sst/platform/src/components/aws/apigatewayv1-usage-plan.d.ts.map +1 -0
  35. package/dist/.sst/platform/src/components/aws/apigatewayv1-usage-plan.js +66 -0
  36. package/dist/.sst/platform/src/components/aws/apigatewayv1-usage-plan.js.map +1 -0
  37. package/dist/.sst/platform/src/components/aws/apigatewayv1.d.ts +1002 -0
  38. package/dist/.sst/platform/src/components/aws/apigatewayv1.d.ts.map +1 -0
  39. package/dist/.sst/platform/src/components/aws/apigatewayv1.js +749 -0
  40. package/dist/.sst/platform/src/components/aws/apigatewayv1.js.map +1 -0
  41. package/dist/.sst/platform/src/components/aws/apigatewayv2-authorizer.d.ts +54 -0
  42. package/dist/.sst/platform/src/components/aws/apigatewayv2-authorizer.d.ts.map +1 -0
  43. package/dist/.sst/platform/src/components/aws/apigatewayv2-authorizer.js +98 -0
  44. package/dist/.sst/platform/src/components/aws/apigatewayv2-authorizer.js.map +1 -0
  45. package/dist/.sst/platform/src/components/aws/apigatewayv2-base-route.d.ts +28 -0
  46. package/dist/.sst/platform/src/components/aws/apigatewayv2-base-route.d.ts.map +1 -0
  47. package/dist/.sst/platform/src/components/aws/apigatewayv2-base-route.js +28 -0
  48. package/dist/.sst/platform/src/components/aws/apigatewayv2-base-route.js.map +1 -0
  49. package/dist/.sst/platform/src/components/aws/apigatewayv2-lambda-route.d.ts +59 -0
  50. package/dist/.sst/platform/src/components/aws/apigatewayv2-lambda-route.d.ts.map +1 -0
  51. package/dist/.sst/platform/src/components/aws/apigatewayv2-lambda-route.js +84 -0
  52. package/dist/.sst/platform/src/components/aws/apigatewayv2-lambda-route.js.map +1 -0
  53. package/dist/.sst/platform/src/components/aws/apigatewayv2-private-route.d.ts +54 -0
  54. package/dist/.sst/platform/src/components/aws/apigatewayv2-private-route.d.ts.map +1 -0
  55. package/dist/.sst/platform/src/components/aws/apigatewayv2-private-route.js +55 -0
  56. package/dist/.sst/platform/src/components/aws/apigatewayv2-private-route.js.map +1 -0
  57. package/dist/.sst/platform/src/components/aws/apigatewayv2-url-route.d.ts +44 -0
  58. package/dist/.sst/platform/src/components/aws/apigatewayv2-url-route.d.ts.map +1 -0
  59. package/dist/.sst/platform/src/components/aws/apigatewayv2-url-route.js +53 -0
  60. package/dist/.sst/platform/src/components/aws/apigatewayv2-url-route.js.map +1 -0
  61. package/dist/.sst/platform/src/components/aws/apigatewayv2.d.ts +933 -0
  62. package/dist/.sst/platform/src/components/aws/apigatewayv2.d.ts.map +1 -0
  63. package/dist/.sst/platform/src/components/aws/apigatewayv2.js +648 -0
  64. package/dist/.sst/platform/src/components/aws/apigatewayv2.js.map +1 -0
  65. package/dist/.sst/platform/src/components/aws/app-sync-data-source.d.ts +52 -0
  66. package/dist/.sst/platform/src/components/aws/app-sync-data-source.d.ts.map +1 -0
  67. package/dist/.sst/platform/src/components/aws/app-sync-data-source.js +208 -0
  68. package/dist/.sst/platform/src/components/aws/app-sync-data-source.js.map +1 -0
  69. package/dist/.sst/platform/src/components/aws/app-sync-function.d.ts +33 -0
  70. package/dist/.sst/platform/src/components/aws/app-sync-function.d.ts.map +1 -0
  71. package/dist/.sst/platform/src/components/aws/app-sync-function.js +52 -0
  72. package/dist/.sst/platform/src/components/aws/app-sync-function.js.map +1 -0
  73. package/dist/.sst/platform/src/components/aws/app-sync-resolver.d.ts +41 -0
  74. package/dist/.sst/platform/src/components/aws/app-sync-resolver.d.ts.map +1 -0
  75. package/dist/.sst/platform/src/components/aws/app-sync-resolver.js +70 -0
  76. package/dist/.sst/platform/src/components/aws/app-sync-resolver.js.map +1 -0
  77. package/dist/.sst/platform/src/components/aws/app-sync.d.ts +638 -0
  78. package/dist/.sst/platform/src/components/aws/app-sync.d.ts.map +1 -0
  79. package/dist/.sst/platform/src/components/aws/app-sync.js +330 -0
  80. package/dist/.sst/platform/src/components/aws/app-sync.js.map +1 -0
  81. package/dist/.sst/platform/src/components/aws/astro.d.ts +421 -0
  82. package/dist/.sst/platform/src/components/aws/astro.d.ts.map +1 -0
  83. package/dist/.sst/platform/src/components/aws/astro.js +156 -0
  84. package/dist/.sst/platform/src/components/aws/astro.js.map +1 -0
  85. package/dist/.sst/platform/src/components/aws/aurora.d.ts +702 -0
  86. package/dist/.sst/platform/src/components/aws/aurora.d.ts.map +1 -0
  87. package/dist/.sst/platform/src/components/aws/aurora.js +678 -0
  88. package/dist/.sst/platform/src/components/aws/aurora.js.map +1 -0
  89. package/dist/.sst/platform/src/components/aws/auth-v1.d.ts +26 -0
  90. package/dist/.sst/platform/src/components/aws/auth-v1.d.ts.map +1 -0
  91. package/dist/.sst/platform/src/components/aws/auth-v1.js +36 -0
  92. package/dist/.sst/platform/src/components/aws/auth-v1.js.map +1 -0
  93. package/dist/.sst/platform/src/components/aws/auth.d.ts +260 -0
  94. package/dist/.sst/platform/src/components/aws/auth.d.ts.map +1 -0
  95. package/dist/.sst/platform/src/components/aws/auth.js +209 -0
  96. package/dist/.sst/platform/src/components/aws/auth.js.map +1 -0
  97. package/dist/.sst/platform/src/components/aws/bucket-lambda-subscriber.d.ts +61 -0
  98. package/dist/.sst/platform/src/components/aws/bucket-lambda-subscriber.d.ts.map +1 -0
  99. package/dist/.sst/platform/src/components/aws/bucket-lambda-subscriber.js +99 -0
  100. package/dist/.sst/platform/src/components/aws/bucket-lambda-subscriber.js.map +1 -0
  101. package/dist/.sst/platform/src/components/aws/bucket-notification.d.ts +47 -0
  102. package/dist/.sst/platform/src/components/aws/bucket-notification.d.ts.map +1 -0
  103. package/dist/.sst/platform/src/components/aws/bucket-notification.js +170 -0
  104. package/dist/.sst/platform/src/components/aws/bucket-notification.js.map +1 -0
  105. package/dist/.sst/platform/src/components/aws/bucket-queue-subscriber.d.ts +55 -0
  106. package/dist/.sst/platform/src/components/aws/bucket-queue-subscriber.d.ts.map +1 -0
  107. package/dist/.sst/platform/src/components/aws/bucket-queue-subscriber.js +77 -0
  108. package/dist/.sst/platform/src/components/aws/bucket-queue-subscriber.js.map +1 -0
  109. package/dist/.sst/platform/src/components/aws/bucket-topic-subscriber.d.ts +55 -0
  110. package/dist/.sst/platform/src/components/aws/bucket-topic-subscriber.d.ts.map +1 -0
  111. package/dist/.sst/platform/src/components/aws/bucket-topic-subscriber.js +99 -0
  112. package/dist/.sst/platform/src/components/aws/bucket-topic-subscriber.js.map +1 -0
  113. package/dist/.sst/platform/src/components/aws/bucket.d.ts +1115 -0
  114. package/dist/.sst/platform/src/components/aws/bucket.d.ts.map +1 -0
  115. package/dist/.sst/platform/src/components/aws/bucket.js +754 -0
  116. package/dist/.sst/platform/src/components/aws/bucket.js.map +1 -0
  117. package/dist/.sst/platform/src/components/aws/bus-base-subscriber.d.ts +20 -0
  118. package/dist/.sst/platform/src/components/aws/bus-base-subscriber.d.ts.map +1 -0
  119. package/dist/.sst/platform/src/components/aws/bus-base-subscriber.js +19 -0
  120. package/dist/.sst/platform/src/components/aws/bus-base-subscriber.js.map +1 -0
  121. package/dist/.sst/platform/src/components/aws/bus-lambda-subscriber.d.ts +49 -0
  122. package/dist/.sst/platform/src/components/aws/bus-lambda-subscriber.d.ts.map +1 -0
  123. package/dist/.sst/platform/src/components/aws/bus-lambda-subscriber.js +81 -0
  124. package/dist/.sst/platform/src/components/aws/bus-lambda-subscriber.js.map +1 -0
  125. package/dist/.sst/platform/src/components/aws/bus-queue-subscriber.d.ts +44 -0
  126. package/dist/.sst/platform/src/components/aws/bus-queue-subscriber.d.ts.map +1 -0
  127. package/dist/.sst/platform/src/components/aws/bus-queue-subscriber.js +63 -0
  128. package/dist/.sst/platform/src/components/aws/bus-queue-subscriber.js.map +1 -0
  129. package/dist/.sst/platform/src/components/aws/bus.d.ts +403 -0
  130. package/dist/.sst/platform/src/components/aws/bus.d.ts.map +1 -0
  131. package/dist/.sst/platform/src/components/aws/bus.js +350 -0
  132. package/dist/.sst/platform/src/components/aws/bus.js.map +1 -0
  133. package/dist/.sst/platform/src/components/aws/cdn.d.ts +299 -0
  134. package/dist/.sst/platform/src/components/aws/cdn.d.ts.map +1 -0
  135. package/dist/.sst/platform/src/components/aws/cdn.js +234 -0
  136. package/dist/.sst/platform/src/components/aws/cdn.js.map +1 -0
  137. package/dist/.sst/platform/src/components/aws/cluster-v1.d.ts +882 -0
  138. package/dist/.sst/platform/src/components/aws/cluster-v1.d.ts.map +1 -0
  139. package/dist/.sst/platform/src/components/aws/cluster-v1.js +245 -0
  140. package/dist/.sst/platform/src/components/aws/cluster-v1.js.map +1 -0
  141. package/dist/.sst/platform/src/components/aws/cluster.d.ts +308 -0
  142. package/dist/.sst/platform/src/components/aws/cluster.d.ts.map +1 -0
  143. package/dist/.sst/platform/src/components/aws/cluster.js +321 -0
  144. package/dist/.sst/platform/src/components/aws/cluster.js.map +1 -0
  145. package/dist/.sst/platform/src/components/aws/cognito-identity-pool.d.ts +194 -0
  146. package/dist/.sst/platform/src/components/aws/cognito-identity-pool.d.ts.map +1 -0
  147. package/dist/.sst/platform/src/components/aws/cognito-identity-pool.js +263 -0
  148. package/dist/.sst/platform/src/components/aws/cognito-identity-pool.js.map +1 -0
  149. package/dist/.sst/platform/src/components/aws/cognito-identity-provider.d.ts +38 -0
  150. package/dist/.sst/platform/src/components/aws/cognito-identity-provider.d.ts.map +1 -0
  151. package/dist/.sst/platform/src/components/aws/cognito-identity-provider.js +67 -0
  152. package/dist/.sst/platform/src/components/aws/cognito-identity-provider.js.map +1 -0
  153. package/dist/.sst/platform/src/components/aws/cognito-user-pool-client.d.ts +50 -0
  154. package/dist/.sst/platform/src/components/aws/cognito-user-pool-client.d.ts.map +1 -0
  155. package/dist/.sst/platform/src/components/aws/cognito-user-pool-client.js +81 -0
  156. package/dist/.sst/platform/src/components/aws/cognito-user-pool-client.js.map +1 -0
  157. package/dist/.sst/platform/src/components/aws/cognito-user-pool.d.ts +599 -0
  158. package/dist/.sst/platform/src/components/aws/cognito-user-pool.d.ts.map +1 -0
  159. package/dist/.sst/platform/src/components/aws/cognito-user-pool.js +368 -0
  160. package/dist/.sst/platform/src/components/aws/cognito-user-pool.js.map +1 -0
  161. package/dist/.sst/platform/src/components/aws/cron.d.ts +250 -0
  162. package/dist/.sst/platform/src/components/aws/cron.d.ts.map +1 -0
  163. package/dist/.sst/platform/src/components/aws/cron.js +200 -0
  164. package/dist/.sst/platform/src/components/aws/cron.js.map +1 -0
  165. package/dist/.sst/platform/src/components/aws/dns-validated-certificate.d.ts +27 -0
  166. package/dist/.sst/platform/src/components/aws/dns-validated-certificate.d.ts.map +1 -0
  167. package/dist/.sst/platform/src/components/aws/dns-validated-certificate.js +55 -0
  168. package/dist/.sst/platform/src/components/aws/dns-validated-certificate.js.map +1 -0
  169. package/dist/.sst/platform/src/components/aws/dns.d.ts +94 -0
  170. package/dist/.sst/platform/src/components/aws/dns.d.ts.map +1 -0
  171. package/dist/.sst/platform/src/components/aws/dns.js +121 -0
  172. package/dist/.sst/platform/src/components/aws/dns.js.map +1 -0
  173. package/dist/.sst/platform/src/components/aws/dynamo-lambda-subscriber.d.ts +55 -0
  174. package/dist/.sst/platform/src/components/aws/dynamo-lambda-subscriber.d.ts.map +1 -0
  175. package/dist/.sst/platform/src/components/aws/dynamo-lambda-subscriber.js +79 -0
  176. package/dist/.sst/platform/src/components/aws/dynamo-lambda-subscriber.js.map +1 -0
  177. package/dist/.sst/platform/src/components/aws/dynamo.d.ts +569 -0
  178. package/dist/.sst/platform/src/components/aws/dynamo.d.ts.map +1 -0
  179. package/dist/.sst/platform/src/components/aws/dynamo.js +291 -0
  180. package/dist/.sst/platform/src/components/aws/dynamo.js.map +1 -0
  181. package/dist/.sst/platform/src/components/aws/efs.d.ts +217 -0
  182. package/dist/.sst/platform/src/components/aws/efs.d.ts.map +1 -0
  183. package/dist/.sst/platform/src/components/aws/efs.js +241 -0
  184. package/dist/.sst/platform/src/components/aws/efs.js.map +1 -0
  185. package/dist/.sst/platform/src/components/aws/email.d.ts +291 -0
  186. package/dist/.sst/platform/src/components/aws/email.d.ts.map +1 -0
  187. package/dist/.sst/platform/src/components/aws/email.js +276 -0
  188. package/dist/.sst/platform/src/components/aws/email.js.map +1 -0
  189. package/dist/.sst/platform/src/components/aws/fargate.d.ts +769 -0
  190. package/dist/.sst/platform/src/components/aws/fargate.d.ts.map +1 -0
  191. package/dist/.sst/platform/src/components/aws/fargate.js +434 -0
  192. package/dist/.sst/platform/src/components/aws/fargate.js.map +1 -0
  193. package/dist/.sst/platform/src/components/aws/function.d.ts +1631 -0
  194. package/dist/.sst/platform/src/components/aws/function.d.ts.map +1 -0
  195. package/dist/.sst/platform/src/components/aws/function.js +1041 -0
  196. package/dist/.sst/platform/src/components/aws/function.js.map +1 -0
  197. package/dist/.sst/platform/src/components/aws/helpers/apigateway-account.d.ts +3 -0
  198. package/dist/.sst/platform/src/components/aws/helpers/apigateway-account.d.ts.map +1 -0
  199. package/dist/.sst/platform/src/components/aws/helpers/apigateway-account.js +31 -0
  200. package/dist/.sst/platform/src/components/aws/helpers/apigateway-account.js.map +1 -0
  201. package/dist/.sst/platform/src/components/aws/helpers/apigatewayv2-domain.d.ts +144 -0
  202. package/dist/.sst/platform/src/components/aws/helpers/apigatewayv2-domain.d.ts.map +1 -0
  203. package/dist/.sst/platform/src/components/aws/helpers/apigatewayv2-domain.js +2 -0
  204. package/dist/.sst/platform/src/components/aws/helpers/apigatewayv2-domain.js.map +1 -0
  205. package/dist/.sst/platform/src/components/aws/helpers/arn.d.ts +35 -0
  206. package/dist/.sst/platform/src/components/aws/helpers/arn.d.ts.map +1 -0
  207. package/dist/.sst/platform/src/components/aws/helpers/arn.js +86 -0
  208. package/dist/.sst/platform/src/components/aws/helpers/arn.js.map +1 -0
  209. package/dist/.sst/platform/src/components/aws/helpers/bootstrap.d.ts +13 -0
  210. package/dist/.sst/platform/src/components/aws/helpers/bootstrap.d.ts.map +1 -0
  211. package/dist/.sst/platform/src/components/aws/helpers/bootstrap.js +7 -0
  212. package/dist/.sst/platform/src/components/aws/helpers/bootstrap.js.map +1 -0
  213. package/dist/.sst/platform/src/components/aws/helpers/container-builder.d.ts +4 -0
  214. package/dist/.sst/platform/src/components/aws/helpers/container-builder.d.ts.map +1 -0
  215. package/dist/.sst/platform/src/components/aws/helpers/container-builder.js +27 -0
  216. package/dist/.sst/platform/src/components/aws/helpers/container-builder.js.map +1 -0
  217. package/dist/.sst/platform/src/components/aws/helpers/function-builder.d.ts +10 -0
  218. package/dist/.sst/platform/src/components/aws/helpers/function-builder.d.ts.map +1 -0
  219. package/dist/.sst/platform/src/components/aws/helpers/function-builder.js +51 -0
  220. package/dist/.sst/platform/src/components/aws/helpers/function-builder.js.map +1 -0
  221. package/dist/.sst/platform/src/components/aws/helpers/provider.d.ts +3 -0
  222. package/dist/.sst/platform/src/components/aws/helpers/provider.d.ts.map +1 -0
  223. package/dist/.sst/platform/src/components/aws/helpers/provider.js +34 -0
  224. package/dist/.sst/platform/src/components/aws/helpers/provider.js.map +1 -0
  225. package/dist/.sst/platform/src/components/aws/helpers/quota.d.ts +7 -0
  226. package/dist/.sst/platform/src/components/aws/helpers/quota.d.ts.map +1 -0
  227. package/dist/.sst/platform/src/components/aws/helpers/quota.js +20 -0
  228. package/dist/.sst/platform/src/components/aws/helpers/quota.js.map +1 -0
  229. package/dist/.sst/platform/src/components/aws/helpers/site-builder.d.ts +4 -0
  230. package/dist/.sst/platform/src/components/aws/helpers/site-builder.d.ts.map +1 -0
  231. package/dist/.sst/platform/src/components/aws/helpers/site-builder.js +36 -0
  232. package/dist/.sst/platform/src/components/aws/helpers/site-builder.js.map +1 -0
  233. package/dist/.sst/platform/src/components/aws/helpers/subscriber.d.ts +6 -0
  234. package/dist/.sst/platform/src/components/aws/helpers/subscriber.d.ts.map +1 -0
  235. package/dist/.sst/platform/src/components/aws/helpers/subscriber.js +13 -0
  236. package/dist/.sst/platform/src/components/aws/helpers/subscriber.js.map +1 -0
  237. package/dist/.sst/platform/src/components/aws/https-redirect.d.ts +38 -0
  238. package/dist/.sst/platform/src/components/aws/https-redirect.d.ts.map +1 -0
  239. package/dist/.sst/platform/src/components/aws/https-redirect.js +124 -0
  240. package/dist/.sst/platform/src/components/aws/https-redirect.js.map +1 -0
  241. package/dist/.sst/platform/src/components/aws/iam-edit.d.ts +39 -0
  242. package/dist/.sst/platform/src/components/aws/iam-edit.d.ts.map +1 -0
  243. package/dist/.sst/platform/src/components/aws/iam-edit.js +40 -0
  244. package/dist/.sst/platform/src/components/aws/iam-edit.js.map +1 -0
  245. package/dist/.sst/platform/src/components/aws/index.d.ts +48 -0
  246. package/dist/.sst/platform/src/components/aws/index.d.ts.map +1 -0
  247. package/dist/.sst/platform/src/components/aws/index.js +49 -0
  248. package/dist/.sst/platform/src/components/aws/index.js.map +1 -0
  249. package/dist/.sst/platform/src/components/aws/kinesis-stream-lambda-subscriber.d.ts +48 -0
  250. package/dist/.sst/platform/src/components/aws/kinesis-stream-lambda-subscriber.d.ts.map +1 -0
  251. package/dist/.sst/platform/src/components/aws/kinesis-stream-lambda-subscriber.js +82 -0
  252. package/dist/.sst/platform/src/components/aws/kinesis-stream-lambda-subscriber.js.map +1 -0
  253. package/dist/.sst/platform/src/components/aws/kinesis-stream.d.ts +249 -0
  254. package/dist/.sst/platform/src/components/aws/kinesis-stream.d.ts.map +1 -0
  255. package/dist/.sst/platform/src/components/aws/kinesis-stream.js +134 -0
  256. package/dist/.sst/platform/src/components/aws/kinesis-stream.js.map +1 -0
  257. package/dist/.sst/platform/src/components/aws/linkable.d.ts +17 -0
  258. package/dist/.sst/platform/src/components/aws/linkable.d.ts.map +1 -0
  259. package/dist/.sst/platform/src/components/aws/linkable.js +25 -0
  260. package/dist/.sst/platform/src/components/aws/linkable.js.map +1 -0
  261. package/dist/.sst/platform/src/components/aws/logging.d.ts +26 -0
  262. package/dist/.sst/platform/src/components/aws/logging.d.ts.map +1 -0
  263. package/dist/.sst/platform/src/components/aws/logging.js +26 -0
  264. package/dist/.sst/platform/src/components/aws/logging.js.map +1 -0
  265. package/dist/.sst/platform/src/components/aws/mysql.d.ts +496 -0
  266. package/dist/.sst/platform/src/components/aws/mysql.d.ts.map +1 -0
  267. package/dist/.sst/platform/src/components/aws/mysql.js +514 -0
  268. package/dist/.sst/platform/src/components/aws/mysql.js.map +1 -0
  269. package/dist/.sst/platform/src/components/aws/nextjs.d.ts +517 -0
  270. package/dist/.sst/platform/src/components/aws/nextjs.d.ts.map +1 -0
  271. package/dist/.sst/platform/src/components/aws/nextjs.js +444 -0
  272. package/dist/.sst/platform/src/components/aws/nextjs.js.map +1 -0
  273. package/dist/.sst/platform/src/components/aws/nuxt.d.ts +495 -0
  274. package/dist/.sst/platform/src/components/aws/nuxt.d.ts.map +1 -0
  275. package/dist/.sst/platform/src/components/aws/nuxt.js +113 -0
  276. package/dist/.sst/platform/src/components/aws/nuxt.js.map +1 -0
  277. package/dist/.sst/platform/src/components/aws/open-search.d.ts +295 -0
  278. package/dist/.sst/platform/src/components/aws/open-search.d.ts.map +1 -0
  279. package/dist/.sst/platform/src/components/aws/open-search.js +365 -0
  280. package/dist/.sst/platform/src/components/aws/open-search.js.map +1 -0
  281. package/dist/.sst/platform/src/components/aws/opencontrol.d.ts +165 -0
  282. package/dist/.sst/platform/src/components/aws/opencontrol.d.ts.map +1 -0
  283. package/dist/.sst/platform/src/components/aws/opencontrol.js +164 -0
  284. package/dist/.sst/platform/src/components/aws/opencontrol.js.map +1 -0
  285. package/dist/.sst/platform/src/components/aws/permission.d.ts +27 -0
  286. package/dist/.sst/platform/src/components/aws/permission.d.ts.map +1 -0
  287. package/dist/.sst/platform/src/components/aws/permission.js +19 -0
  288. package/dist/.sst/platform/src/components/aws/permission.js.map +1 -0
  289. package/dist/.sst/platform/src/components/aws/postgres-v1.d.ts +317 -0
  290. package/dist/.sst/platform/src/components/aws/postgres-v1.d.ts.map +1 -0
  291. package/dist/.sst/platform/src/components/aws/postgres-v1.js +304 -0
  292. package/dist/.sst/platform/src/components/aws/postgres-v1.js.map +1 -0
  293. package/dist/.sst/platform/src/components/aws/postgres.d.ts +500 -0
  294. package/dist/.sst/platform/src/components/aws/postgres.d.ts.map +1 -0
  295. package/dist/.sst/platform/src/components/aws/postgres.js +532 -0
  296. package/dist/.sst/platform/src/components/aws/postgres.js.map +1 -0
  297. package/dist/.sst/platform/src/components/aws/providers/bucket-files.d.ts +18 -0
  298. package/dist/.sst/platform/src/components/aws/providers/bucket-files.d.ts.map +1 -0
  299. package/dist/.sst/platform/src/components/aws/providers/bucket-files.js +8 -0
  300. package/dist/.sst/platform/src/components/aws/providers/bucket-files.js.map +1 -0
  301. package/dist/.sst/platform/src/components/aws/providers/distribution-deployment-waiter.d.ts +13 -0
  302. package/dist/.sst/platform/src/components/aws/providers/distribution-deployment-waiter.d.ts.map +1 -0
  303. package/dist/.sst/platform/src/components/aws/providers/distribution-deployment-waiter.js +8 -0
  304. package/dist/.sst/platform/src/components/aws/providers/distribution-deployment-waiter.js.map +1 -0
  305. package/dist/.sst/platform/src/components/aws/providers/distribution-invalidation.d.ts +11 -0
  306. package/dist/.sst/platform/src/components/aws/providers/distribution-invalidation.d.ts.map +1 -0
  307. package/dist/.sst/platform/src/components/aws/providers/distribution-invalidation.js +8 -0
  308. package/dist/.sst/platform/src/components/aws/providers/distribution-invalidation.js.map +1 -0
  309. package/dist/.sst/platform/src/components/aws/providers/function-environment-update.d.ts +29 -0
  310. package/dist/.sst/platform/src/components/aws/providers/function-environment-update.d.ts.map +1 -0
  311. package/dist/.sst/platform/src/components/aws/providers/function-environment-update.js +18 -0
  312. package/dist/.sst/platform/src/components/aws/providers/function-environment-update.js.map +1 -0
  313. package/dist/.sst/platform/src/components/aws/providers/hosted-zone-lookup.d.ts +11 -0
  314. package/dist/.sst/platform/src/components/aws/providers/hosted-zone-lookup.d.ts.map +1 -0
  315. package/dist/.sst/platform/src/components/aws/providers/hosted-zone-lookup.js +8 -0
  316. package/dist/.sst/platform/src/components/aws/providers/hosted-zone-lookup.js.map +1 -0
  317. package/dist/.sst/platform/src/components/aws/providers/kv-keys.d.ts +11 -0
  318. package/dist/.sst/platform/src/components/aws/providers/kv-keys.d.ts.map +1 -0
  319. package/dist/.sst/platform/src/components/aws/providers/kv-keys.js +8 -0
  320. package/dist/.sst/platform/src/components/aws/providers/kv-keys.js.map +1 -0
  321. package/dist/.sst/platform/src/components/aws/providers/kv-routes-update.d.ts +11 -0
  322. package/dist/.sst/platform/src/components/aws/providers/kv-routes-update.d.ts.map +1 -0
  323. package/dist/.sst/platform/src/components/aws/providers/kv-routes-update.js +8 -0
  324. package/dist/.sst/platform/src/components/aws/providers/kv-routes-update.js.map +1 -0
  325. package/dist/.sst/platform/src/components/aws/providers/origin-access-control.d.ts +8 -0
  326. package/dist/.sst/platform/src/components/aws/providers/origin-access-control.d.ts.map +1 -0
  327. package/dist/.sst/platform/src/components/aws/providers/origin-access-control.js +8 -0
  328. package/dist/.sst/platform/src/components/aws/providers/origin-access-control.js.map +1 -0
  329. package/dist/.sst/platform/src/components/aws/providers/rds-role-lookup.d.ts +8 -0
  330. package/dist/.sst/platform/src/components/aws/providers/rds-role-lookup.d.ts.map +1 -0
  331. package/dist/.sst/platform/src/components/aws/providers/rds-role-lookup.js +8 -0
  332. package/dist/.sst/platform/src/components/aws/providers/rds-role-lookup.js.map +1 -0
  333. package/dist/.sst/platform/src/components/aws/providers/vector-table.d.ts +12 -0
  334. package/dist/.sst/platform/src/components/aws/providers/vector-table.d.ts.map +1 -0
  335. package/dist/.sst/platform/src/components/aws/providers/vector-table.js +8 -0
  336. package/dist/.sst/platform/src/components/aws/providers/vector-table.js.map +1 -0
  337. package/dist/.sst/platform/src/components/aws/queue-lambda-subscriber.d.ts +48 -0
  338. package/dist/.sst/platform/src/components/aws/queue-lambda-subscriber.d.ts.map +1 -0
  339. package/dist/.sst/platform/src/components/aws/queue-lambda-subscriber.js +81 -0
  340. package/dist/.sst/platform/src/components/aws/queue-lambda-subscriber.js.map +1 -0
  341. package/dist/.sst/platform/src/components/aws/queue.d.ts +485 -0
  342. package/dist/.sst/platform/src/components/aws/queue.d.ts.map +1 -0
  343. package/dist/.sst/platform/src/components/aws/queue.js +322 -0
  344. package/dist/.sst/platform/src/components/aws/queue.js.map +1 -0
  345. package/dist/.sst/platform/src/components/aws/react.d.ts +416 -0
  346. package/dist/.sst/platform/src/components/aws/react.d.ts.map +1 -0
  347. package/dist/.sst/platform/src/components/aws/react.js +157 -0
  348. package/dist/.sst/platform/src/components/aws/react.js.map +1 -0
  349. package/dist/.sst/platform/src/components/aws/realtime-lambda-subscriber.d.ts +53 -0
  350. package/dist/.sst/platform/src/components/aws/realtime-lambda-subscriber.d.ts.map +1 -0
  351. package/dist/.sst/platform/src/components/aws/realtime-lambda-subscriber.js +78 -0
  352. package/dist/.sst/platform/src/components/aws/realtime-lambda-subscriber.js.map +1 -0
  353. package/dist/.sst/platform/src/components/aws/realtime.d.ts +226 -0
  354. package/dist/.sst/platform/src/components/aws/realtime.d.ts.map +1 -0
  355. package/dist/.sst/platform/src/components/aws/realtime.js +221 -0
  356. package/dist/.sst/platform/src/components/aws/realtime.js.map +1 -0
  357. package/dist/.sst/platform/src/components/aws/redis-v1.d.ts +338 -0
  358. package/dist/.sst/platform/src/components/aws/redis-v1.d.ts.map +1 -0
  359. package/dist/.sst/platform/src/components/aws/redis-v1.js +335 -0
  360. package/dist/.sst/platform/src/components/aws/redis-v1.js.map +1 -0
  361. package/dist/.sst/platform/src/components/aws/redis.d.ts +364 -0
  362. package/dist/.sst/platform/src/components/aws/redis.d.ts.map +1 -0
  363. package/dist/.sst/platform/src/components/aws/redis.js +382 -0
  364. package/dist/.sst/platform/src/components/aws/redis.js.map +1 -0
  365. package/dist/.sst/platform/src/components/aws/remix.d.ts +423 -0
  366. package/dist/.sst/platform/src/components/aws/remix.d.ts.map +1 -0
  367. package/dist/.sst/platform/src/components/aws/remix.js +212 -0
  368. package/dist/.sst/platform/src/components/aws/remix.js.map +1 -0
  369. package/dist/.sst/platform/src/components/aws/router-base-route.d.ts +28 -0
  370. package/dist/.sst/platform/src/components/aws/router-base-route.d.ts.map +1 -0
  371. package/dist/.sst/platform/src/components/aws/router-base-route.js +40 -0
  372. package/dist/.sst/platform/src/components/aws/router-base-route.js.map +1 -0
  373. package/dist/.sst/platform/src/components/aws/router-bucket-route.d.ts +29 -0
  374. package/dist/.sst/platform/src/components/aws/router-bucket-route.d.ts.map +1 -0
  375. package/dist/.sst/platform/src/components/aws/router-bucket-route.js +40 -0
  376. package/dist/.sst/platform/src/components/aws/router-bucket-route.js.map +1 -0
  377. package/dist/.sst/platform/src/components/aws/router-url-route.d.ts +28 -0
  378. package/dist/.sst/platform/src/components/aws/router-url-route.d.ts.map +1 -0
  379. package/dist/.sst/platform/src/components/aws/router-url-route.js +51 -0
  380. package/dist/.sst/platform/src/components/aws/router-url-route.js.map +1 -0
  381. package/dist/.sst/platform/src/components/aws/router.d.ts +1266 -0
  382. package/dist/.sst/platform/src/components/aws/router.d.ts.map +1 -0
  383. package/dist/.sst/platform/src/components/aws/router.js +1156 -0
  384. package/dist/.sst/platform/src/components/aws/router.js.map +1 -0
  385. package/dist/.sst/platform/src/components/aws/service-v1.d.ts +78 -0
  386. package/dist/.sst/platform/src/components/aws/service-v1.d.ts.map +1 -0
  387. package/dist/.sst/platform/src/components/aws/service-v1.js +606 -0
  388. package/dist/.sst/platform/src/components/aws/service-v1.js.map +1 -0
  389. package/dist/.sst/platform/src/components/aws/service.d.ts +1599 -0
  390. package/dist/.sst/platform/src/components/aws/service.d.ts.map +1 -0
  391. package/dist/.sst/platform/src/components/aws/service.js +924 -0
  392. package/dist/.sst/platform/src/components/aws/service.js.map +1 -0
  393. package/dist/.sst/platform/src/components/aws/sns-topic-lambda-subscriber.d.ts +53 -0
  394. package/dist/.sst/platform/src/components/aws/sns-topic-lambda-subscriber.d.ts.map +1 -0
  395. package/dist/.sst/platform/src/components/aws/sns-topic-lambda-subscriber.js +75 -0
  396. package/dist/.sst/platform/src/components/aws/sns-topic-lambda-subscriber.js.map +1 -0
  397. package/dist/.sst/platform/src/components/aws/sns-topic-queue-subscriber.d.ts +55 -0
  398. package/dist/.sst/platform/src/components/aws/sns-topic-queue-subscriber.d.ts.map +1 -0
  399. package/dist/.sst/platform/src/components/aws/sns-topic-queue-subscriber.js +59 -0
  400. package/dist/.sst/platform/src/components/aws/sns-topic-queue-subscriber.js.map +1 -0
  401. package/dist/.sst/platform/src/components/aws/sns-topic.d.ts +389 -0
  402. package/dist/.sst/platform/src/components/aws/sns-topic.d.ts.map +1 -0
  403. package/dist/.sst/platform/src/components/aws/sns-topic.js +233 -0
  404. package/dist/.sst/platform/src/components/aws/sns-topic.js.map +1 -0
  405. package/dist/.sst/platform/src/components/aws/solid-start.d.ts +414 -0
  406. package/dist/.sst/platform/src/components/aws/solid-start.d.ts.map +1 -0
  407. package/dist/.sst/platform/src/components/aws/solid-start.js +120 -0
  408. package/dist/.sst/platform/src/components/aws/solid-start.js.map +1 -0
  409. package/dist/.sst/platform/src/components/aws/ssr-site.d.ts +494 -0
  410. package/dist/.sst/platform/src/components/aws/ssr-site.d.ts.map +1 -0
  411. package/dist/.sst/platform/src/components/aws/ssr-site.js +792 -0
  412. package/dist/.sst/platform/src/components/aws/ssr-site.js.map +1 -0
  413. package/dist/.sst/platform/src/components/aws/static-site.d.ts +736 -0
  414. package/dist/.sst/platform/src/components/aws/static-site.d.ts.map +1 -0
  415. package/dist/.sst/platform/src/components/aws/static-site.js +583 -0
  416. package/dist/.sst/platform/src/components/aws/static-site.js.map +1 -0
  417. package/dist/.sst/platform/src/components/aws/step-functions/choice.d.ts +73 -0
  418. package/dist/.sst/platform/src/components/aws/step-functions/choice.d.ts.map +1 -0
  419. package/dist/.sst/platform/src/components/aws/step-functions/choice.js +98 -0
  420. package/dist/.sst/platform/src/components/aws/step-functions/choice.js.map +1 -0
  421. package/dist/.sst/platform/src/components/aws/step-functions/fail.d.ts +63 -0
  422. package/dist/.sst/platform/src/components/aws/step-functions/fail.d.ts.map +1 -0
  423. package/dist/.sst/platform/src/components/aws/step-functions/fail.js +25 -0
  424. package/dist/.sst/platform/src/components/aws/step-functions/fail.js.map +1 -0
  425. package/dist/.sst/platform/src/components/aws/step-functions/map.d.ts +236 -0
  426. package/dist/.sst/platform/src/components/aws/step-functions/map.d.ts.map +1 -0
  427. package/dist/.sst/platform/src/components/aws/step-functions/map.js +108 -0
  428. package/dist/.sst/platform/src/components/aws/step-functions/map.js.map +1 -0
  429. package/dist/.sst/platform/src/components/aws/step-functions/parallel.d.ts +127 -0
  430. package/dist/.sst/platform/src/components/aws/step-functions/parallel.d.ts.map +1 -0
  431. package/dist/.sst/platform/src/components/aws/step-functions/parallel.js +129 -0
  432. package/dist/.sst/platform/src/components/aws/step-functions/parallel.js.map +1 -0
  433. package/dist/.sst/platform/src/components/aws/step-functions/pass.d.ts +39 -0
  434. package/dist/.sst/platform/src/components/aws/step-functions/pass.d.ts.map +1 -0
  435. package/dist/.sst/platform/src/components/aws/step-functions/pass.js +41 -0
  436. package/dist/.sst/platform/src/components/aws/step-functions/pass.js.map +1 -0
  437. package/dist/.sst/platform/src/components/aws/step-functions/state.d.ts +197 -0
  438. package/dist/.sst/platform/src/components/aws/step-functions/state.d.ts.map +1 -0
  439. package/dist/.sst/platform/src/components/aws/step-functions/state.js +134 -0
  440. package/dist/.sst/platform/src/components/aws/step-functions/state.js.map +1 -0
  441. package/dist/.sst/platform/src/components/aws/step-functions/succeed.d.ts +26 -0
  442. package/dist/.sst/platform/src/components/aws/step-functions/succeed.d.ts.map +1 -0
  443. package/dist/.sst/platform/src/components/aws/step-functions/succeed.js +25 -0
  444. package/dist/.sst/platform/src/components/aws/step-functions/succeed.js.map +1 -0
  445. package/dist/.sst/platform/src/components/aws/step-functions/task.d.ts +477 -0
  446. package/dist/.sst/platform/src/components/aws/step-functions/task.d.ts.map +1 -0
  447. package/dist/.sst/platform/src/components/aws/step-functions/task.js +116 -0
  448. package/dist/.sst/platform/src/components/aws/step-functions/task.js.map +1 -0
  449. package/dist/.sst/platform/src/components/aws/step-functions/wait.d.ts +91 -0
  450. package/dist/.sst/platform/src/components/aws/step-functions/wait.d.ts.map +1 -0
  451. package/dist/.sst/platform/src/components/aws/step-functions/wait.js +46 -0
  452. package/dist/.sst/platform/src/components/aws/step-functions/wait.js.map +1 -0
  453. package/dist/.sst/platform/src/components/aws/step-functions.d.ts +473 -0
  454. package/dist/.sst/platform/src/components/aws/step-functions.d.ts.map +1 -0
  455. package/dist/.sst/platform/src/components/aws/step-functions.js +576 -0
  456. package/dist/.sst/platform/src/components/aws/step-functions.js.map +1 -0
  457. package/dist/.sst/platform/src/components/aws/svelte-kit.d.ts +417 -0
  458. package/dist/.sst/platform/src/components/aws/svelte-kit.d.ts.map +1 -0
  459. package/dist/.sst/platform/src/components/aws/svelte-kit.js +144 -0
  460. package/dist/.sst/platform/src/components/aws/svelte-kit.js.map +1 -0
  461. package/dist/.sst/platform/src/components/aws/tan-stack-start.d.ts +354 -0
  462. package/dist/.sst/platform/src/components/aws/tan-stack-start.d.ts.map +1 -0
  463. package/dist/.sst/platform/src/components/aws/tan-stack-start.js +143 -0
  464. package/dist/.sst/platform/src/components/aws/tan-stack-start.js.map +1 -0
  465. package/dist/.sst/platform/src/components/aws/task.d.ts +322 -0
  466. package/dist/.sst/platform/src/components/aws/task.d.ts.map +1 -0
  467. package/dist/.sst/platform/src/components/aws/task.js +311 -0
  468. package/dist/.sst/platform/src/components/aws/task.js.map +1 -0
  469. package/dist/.sst/platform/src/components/aws/vector.d.ts +150 -0
  470. package/dist/.sst/platform/src/components/aws/vector.d.ts.map +1 -0
  471. package/dist/.sst/platform/src/components/aws/vector.js +224 -0
  472. package/dist/.sst/platform/src/components/aws/vector.js.map +1 -0
  473. package/dist/.sst/platform/src/components/aws/vpc-v1.d.ts +208 -0
  474. package/dist/.sst/platform/src/components/aws/vpc-v1.d.ts.map +1 -0
  475. package/dist/.sst/platform/src/components/aws/vpc-v1.js +355 -0
  476. package/dist/.sst/platform/src/components/aws/vpc-v1.js.map +1 -0
  477. package/dist/.sst/platform/src/components/aws/vpc.d.ts +444 -0
  478. package/dist/.sst/platform/src/components/aws/vpc.d.ts.map +1 -0
  479. package/dist/.sst/platform/src/components/aws/vpc.js +834 -0
  480. package/dist/.sst/platform/src/components/aws/vpc.js.map +1 -0
  481. package/dist/.sst/platform/src/components/base/base-site.d.ts +53 -0
  482. package/dist/.sst/platform/src/components/base/base-site.d.ts.map +1 -0
  483. package/dist/.sst/platform/src/components/base/base-site.js +47 -0
  484. package/dist/.sst/platform/src/components/base/base-site.js.map +1 -0
  485. package/dist/.sst/platform/src/components/base/base-ssr-site.d.ts +111 -0
  486. package/dist/.sst/platform/src/components/base/base-ssr-site.d.ts.map +1 -0
  487. package/dist/.sst/platform/src/components/base/base-ssr-site.js +72 -0
  488. package/dist/.sst/platform/src/components/base/base-ssr-site.js.map +1 -0
  489. package/dist/.sst/platform/src/components/base/base-static-site.d.ts +199 -0
  490. package/dist/.sst/platform/src/components/base/base-static-site.d.ts.map +1 -0
  491. package/dist/.sst/platform/src/components/base/base-static-site.js +87 -0
  492. package/dist/.sst/platform/src/components/base/base-static-site.js.map +1 -0
  493. package/dist/.sst/platform/src/components/cloudflare/account-id.d.ts +2 -0
  494. package/dist/.sst/platform/src/components/cloudflare/account-id.d.ts.map +1 -0
  495. package/dist/.sst/platform/src/components/cloudflare/account-id.js +2 -0
  496. package/dist/.sst/platform/src/components/cloudflare/account-id.js.map +1 -0
  497. package/dist/.sst/platform/src/components/cloudflare/auth.d.ts +22 -0
  498. package/dist/.sst/platform/src/components/cloudflare/auth.d.ts.map +1 -0
  499. package/dist/.sst/platform/src/components/cloudflare/auth.js +37 -0
  500. package/dist/.sst/platform/src/components/cloudflare/auth.js.map +1 -0
  501. package/dist/.sst/platform/src/components/cloudflare/binding.d.ts +69 -0
  502. package/dist/.sst/platform/src/components/cloudflare/binding.d.ts.map +1 -0
  503. package/dist/.sst/platform/src/components/cloudflare/binding.js +25 -0
  504. package/dist/.sst/platform/src/components/cloudflare/binding.js.map +1 -0
  505. package/dist/.sst/platform/src/components/cloudflare/bucket.d.ts +101 -0
  506. package/dist/.sst/platform/src/components/cloudflare/bucket.d.ts.map +1 -0
  507. package/dist/.sst/platform/src/components/cloudflare/bucket.js +98 -0
  508. package/dist/.sst/platform/src/components/cloudflare/bucket.js.map +1 -0
  509. package/dist/.sst/platform/src/components/cloudflare/cron.d.ts +121 -0
  510. package/dist/.sst/platform/src/components/cloudflare/cron.d.ts.map +1 -0
  511. package/dist/.sst/platform/src/components/cloudflare/cron.js +86 -0
  512. package/dist/.sst/platform/src/components/cloudflare/cron.js.map +1 -0
  513. package/dist/.sst/platform/src/components/cloudflare/d1.d.ts +107 -0
  514. package/dist/.sst/platform/src/components/cloudflare/d1.d.ts.map +1 -0
  515. package/dist/.sst/platform/src/components/cloudflare/d1.js +104 -0
  516. package/dist/.sst/platform/src/components/cloudflare/d1.js.map +1 -0
  517. package/dist/.sst/platform/src/components/cloudflare/dns.d.ts +94 -0
  518. package/dist/.sst/platform/src/components/cloudflare/dns.d.ts.map +1 -0
  519. package/dist/.sst/platform/src/components/cloudflare/dns.js +138 -0
  520. package/dist/.sst/platform/src/components/cloudflare/dns.js.map +1 -0
  521. package/dist/.sst/platform/src/components/cloudflare/helpers/fetch.d.ts +19 -0
  522. package/dist/.sst/platform/src/components/cloudflare/helpers/fetch.d.ts.map +1 -0
  523. package/dist/.sst/platform/src/components/cloudflare/helpers/fetch.js +39 -0
  524. package/dist/.sst/platform/src/components/cloudflare/helpers/fetch.js.map +1 -0
  525. package/dist/.sst/platform/src/components/cloudflare/helpers/worker-builder.d.ts +10 -0
  526. package/dist/.sst/platform/src/components/cloudflare/helpers/worker-builder.d.ts.map +1 -0
  527. package/dist/.sst/platform/src/components/cloudflare/helpers/worker-builder.js +25 -0
  528. package/dist/.sst/platform/src/components/cloudflare/helpers/worker-builder.js.map +1 -0
  529. package/dist/.sst/platform/src/components/cloudflare/index.d.ts +13 -0
  530. package/dist/.sst/platform/src/components/cloudflare/index.d.ts.map +1 -0
  531. package/dist/.sst/platform/src/components/cloudflare/index.js +13 -0
  532. package/dist/.sst/platform/src/components/cloudflare/index.js.map +1 -0
  533. package/dist/.sst/platform/src/components/cloudflare/kv.d.ts +101 -0
  534. package/dist/.sst/platform/src/components/cloudflare/kv.d.ts.map +1 -0
  535. package/dist/.sst/platform/src/components/cloudflare/kv.js +98 -0
  536. package/dist/.sst/platform/src/components/cloudflare/kv.js.map +1 -0
  537. package/dist/.sst/platform/src/components/cloudflare/providers/dns-record.d.ts +20 -0
  538. package/dist/.sst/platform/src/components/cloudflare/providers/dns-record.d.ts.map +1 -0
  539. package/dist/.sst/platform/src/components/cloudflare/providers/dns-record.js +11 -0
  540. package/dist/.sst/platform/src/components/cloudflare/providers/dns-record.js.map +1 -0
  541. package/dist/.sst/platform/src/components/cloudflare/providers/kv-data.d.ts +23 -0
  542. package/dist/.sst/platform/src/components/cloudflare/providers/kv-data.d.ts.map +1 -0
  543. package/dist/.sst/platform/src/components/cloudflare/providers/kv-data.js +63 -0
  544. package/dist/.sst/platform/src/components/cloudflare/providers/kv-data.js.map +1 -0
  545. package/dist/.sst/platform/src/components/cloudflare/providers/worker-url.d.ts +22 -0
  546. package/dist/.sst/platform/src/components/cloudflare/providers/worker-url.d.ts.map +1 -0
  547. package/dist/.sst/platform/src/components/cloudflare/providers/worker-url.js +83 -0
  548. package/dist/.sst/platform/src/components/cloudflare/providers/worker-url.js.map +1 -0
  549. package/dist/.sst/platform/src/components/cloudflare/providers/zone-lookup.d.ts +22 -0
  550. package/dist/.sst/platform/src/components/cloudflare/providers/zone-lookup.d.ts.map +1 -0
  551. package/dist/.sst/platform/src/components/cloudflare/providers/zone-lookup.js +54 -0
  552. package/dist/.sst/platform/src/components/cloudflare/providers/zone-lookup.js.map +1 -0
  553. package/dist/.sst/platform/src/components/cloudflare/queue.d.ts +60 -0
  554. package/dist/.sst/platform/src/components/cloudflare/queue.d.ts.map +1 -0
  555. package/dist/.sst/platform/src/components/cloudflare/queue.js +57 -0
  556. package/dist/.sst/platform/src/components/cloudflare/queue.js.map +1 -0
  557. package/dist/.sst/platform/src/components/cloudflare/remix.d.ts +223 -0
  558. package/dist/.sst/platform/src/components/cloudflare/remix.d.ts.map +1 -0
  559. package/dist/.sst/platform/src/components/cloudflare/remix.js +291 -0
  560. package/dist/.sst/platform/src/components/cloudflare/remix.js.map +1 -0
  561. package/dist/.sst/platform/src/components/cloudflare/ssr-site.d.ts +59 -0
  562. package/dist/.sst/platform/src/components/cloudflare/ssr-site.d.ts.map +1 -0
  563. package/dist/.sst/platform/src/components/cloudflare/ssr-site.js +177 -0
  564. package/dist/.sst/platform/src/components/cloudflare/ssr-site.js.map +1 -0
  565. package/dist/.sst/platform/src/components/cloudflare/static-site.d.ts +262 -0
  566. package/dist/.sst/platform/src/components/cloudflare/static-site.d.ts.map +1 -0
  567. package/dist/.sst/platform/src/components/cloudflare/static-site.js +315 -0
  568. package/dist/.sst/platform/src/components/cloudflare/static-site.js.map +1 -0
  569. package/dist/.sst/platform/src/components/cloudflare/worker.d.ts +273 -0
  570. package/dist/.sst/platform/src/components/cloudflare/worker.d.ts.map +1 -0
  571. package/dist/.sst/platform/src/components/cloudflare/worker.js +326 -0
  572. package/dist/.sst/platform/src/components/cloudflare/worker.js.map +1 -0
  573. package/dist/.sst/platform/src/components/component.d.ts +37 -0
  574. package/dist/.sst/platform/src/components/component.d.ts.map +1 -0
  575. package/dist/.sst/platform/src/components/component.js +395 -0
  576. package/dist/.sst/platform/src/components/component.js.map +1 -0
  577. package/dist/.sst/platform/src/components/cpu.d.ts +3 -0
  578. package/dist/.sst/platform/src/components/cpu.d.ts.map +1 -0
  579. package/dist/.sst/platform/src/components/cpu.js +9 -0
  580. package/dist/.sst/platform/src/components/cpu.js.map +1 -0
  581. package/dist/.sst/platform/src/components/dns.d.ts +59 -0
  582. package/dist/.sst/platform/src/components/dns.d.ts.map +1 -0
  583. package/dist/.sst/platform/src/components/dns.js +7 -0
  584. package/dist/.sst/platform/src/components/dns.js.map +1 -0
  585. package/dist/.sst/platform/src/components/duration.d.ts +6 -0
  586. package/dist/.sst/platform/src/components/duration.d.ts.map +1 -0
  587. package/dist/.sst/platform/src/components/duration.js +19 -0
  588. package/dist/.sst/platform/src/components/duration.js.map +1 -0
  589. package/dist/.sst/platform/src/components/error.d.ts +4 -0
  590. package/dist/.sst/platform/src/components/error.d.ts.map +1 -0
  591. package/dist/.sst/platform/src/components/error.js +6 -0
  592. package/dist/.sst/platform/src/components/error.js.map +1 -0
  593. package/dist/.sst/platform/src/components/experimental/dev-command.d.ts +99 -0
  594. package/dist/.sst/platform/src/components/experimental/dev-command.d.ts.map +1 -0
  595. package/dist/.sst/platform/src/components/experimental/dev-command.js +59 -0
  596. package/dist/.sst/platform/src/components/experimental/dev-command.js.map +1 -0
  597. package/dist/.sst/platform/src/components/experimental/index.d.ts +2 -0
  598. package/dist/.sst/platform/src/components/experimental/index.d.ts.map +1 -0
  599. package/dist/.sst/platform/src/components/experimental/index.js +2 -0
  600. package/dist/.sst/platform/src/components/experimental/index.js.map +1 -0
  601. package/dist/.sst/platform/src/components/hint.d.ts +7 -0
  602. package/dist/.sst/platform/src/components/hint.d.ts.map +1 -0
  603. package/dist/.sst/platform/src/components/hint.js +20 -0
  604. package/dist/.sst/platform/src/components/hint.js.map +1 -0
  605. package/dist/.sst/platform/src/components/index.d.ts +16 -0
  606. package/dist/.sst/platform/src/components/index.d.ts.map +1 -0
  607. package/dist/.sst/platform/src/components/index.js +16 -0
  608. package/dist/.sst/platform/src/components/index.js.map +1 -0
  609. package/dist/.sst/platform/src/components/input.d.ts +3 -0
  610. package/dist/.sst/platform/src/components/input.d.ts.map +1 -0
  611. package/dist/.sst/platform/src/components/input.js +2 -0
  612. package/dist/.sst/platform/src/components/input.js.map +1 -0
  613. package/dist/.sst/platform/src/components/link.d.ts +41 -0
  614. package/dist/.sst/platform/src/components/link.d.ts.map +1 -0
  615. package/dist/.sst/platform/src/components/link.js +138 -0
  616. package/dist/.sst/platform/src/components/link.js.map +1 -0
  617. package/dist/.sst/platform/src/components/linkable.d.ts +271 -0
  618. package/dist/.sst/platform/src/components/linkable.d.ts.map +1 -0
  619. package/dist/.sst/platform/src/components/linkable.js +244 -0
  620. package/dist/.sst/platform/src/components/linkable.js.map +1 -0
  621. package/dist/.sst/platform/src/components/naming.d.ts +7 -0
  622. package/dist/.sst/platform/src/components/naming.d.ts.map +1 -0
  623. package/dist/.sst/platform/src/components/naming.js +58 -0
  624. package/dist/.sst/platform/src/components/naming.js.map +1 -0
  625. package/dist/.sst/platform/src/components/path.d.ts +2 -0
  626. package/dist/.sst/platform/src/components/path.d.ts.map +1 -0
  627. package/dist/.sst/platform/src/components/path.js +5 -0
  628. package/dist/.sst/platform/src/components/path.js.map +1 -0
  629. package/dist/.sst/platform/src/components/rpc/rpc.d.ts +18 -0
  630. package/dist/.sst/platform/src/components/rpc/rpc.d.ts.map +1 -0
  631. package/dist/.sst/platform/src/components/rpc/rpc.js +120 -0
  632. package/dist/.sst/platform/src/components/rpc/rpc.js.map +1 -0
  633. package/dist/.sst/platform/src/components/secret.d.ts +125 -0
  634. package/dist/.sst/platform/src/components/secret.d.ts.map +1 -0
  635. package/dist/.sst/platform/src/components/secret.js +143 -0
  636. package/dist/.sst/platform/src/components/secret.js.map +1 -0
  637. package/dist/.sst/platform/src/components/size.d.ts +5 -0
  638. package/dist/.sst/platform/src/components/size.d.ts.map +1 -0
  639. package/dist/.sst/platform/src/components/size.js +29 -0
  640. package/dist/.sst/platform/src/components/size.js.map +1 -0
  641. package/dist/.sst/platform/src/components/vercel/account-id.d.ts +2 -0
  642. package/dist/.sst/platform/src/components/vercel/account-id.d.ts.map +1 -0
  643. package/dist/.sst/platform/src/components/vercel/account-id.js +2 -0
  644. package/dist/.sst/platform/src/components/vercel/account-id.js.map +1 -0
  645. package/dist/.sst/platform/src/components/vercel/dns.d.ts +73 -0
  646. package/dist/.sst/platform/src/components/vercel/dns.d.ts.map +1 -0
  647. package/dist/.sst/platform/src/components/vercel/dns.js +104 -0
  648. package/dist/.sst/platform/src/components/vercel/dns.js.map +1 -0
  649. package/dist/.sst/platform/src/components/vercel/index.d.ts +3 -0
  650. package/dist/.sst/platform/src/components/vercel/index.d.ts.map +1 -0
  651. package/dist/.sst/platform/src/components/vercel/index.js +3 -0
  652. package/dist/.sst/platform/src/components/vercel/index.js.map +1 -0
  653. package/dist/.sst/platform/src/components/vercel/providers/dns-record.d.ts +14 -0
  654. package/dist/.sst/platform/src/components/vercel/providers/dns-record.d.ts.map +1 -0
  655. package/dist/.sst/platform/src/components/vercel/providers/dns-record.js +8 -0
  656. package/dist/.sst/platform/src/components/vercel/providers/dns-record.js.map +1 -0
  657. package/dist/.sst/platform/src/config.d.ts +1243 -0
  658. package/dist/.sst/platform/src/config.d.ts.map +1 -0
  659. package/dist/.sst/platform/src/config.js +5 -0
  660. package/dist/.sst/platform/src/config.js.map +1 -0
  661. package/dist/.sst/platform/src/util/compare-semver.d.ts +4 -0
  662. package/dist/.sst/platform/src/util/compare-semver.d.ts.map +1 -0
  663. package/dist/.sst/platform/src/util/compare-semver.js +24 -0
  664. package/dist/.sst/platform/src/util/compare-semver.js.map +1 -0
  665. package/dist/.sst/platform/src/util/lazy.d.ts +2 -0
  666. package/dist/.sst/platform/src/util/lazy.d.ts.map +1 -0
  667. package/dist/.sst/platform/src/util/lazy.js +12 -0
  668. package/dist/.sst/platform/src/util/lazy.js.map +1 -0
  669. package/dist/.sst/platform/src/util/path-to-regex.d.ts +128 -0
  670. package/dist/.sst/platform/src/util/path-to-regex.d.ts.map +1 -0
  671. package/dist/.sst/platform/src/util/path-to-regex.js +392 -0
  672. package/dist/.sst/platform/src/util/path-to-regex.js.map +1 -0
  673. package/dist/.sst/platform/src/util/semaphore.d.ts +9 -0
  674. package/dist/.sst/platform/src/util/semaphore.d.ts.map +1 -0
  675. package/dist/.sst/platform/src/util/semaphore.js +36 -0
  676. package/dist/.sst/platform/src/util/semaphore.js.map +1 -0
  677. package/dist/.sst/platform/src/util/warn.d.ts +2 -0
  678. package/dist/.sst/platform/src/util/warn.d.ts.map +1 -0
  679. package/dist/.sst/platform/src/util/warn.js +8 -0
  680. package/dist/.sst/platform/src/util/warn.js.map +1 -0
  681. package/dist/components/monorise-core.d.ts +17 -0
  682. package/dist/components/monorise-core.d.ts.map +1 -0
  683. package/dist/components/monorise-core.js +134 -0
  684. package/dist/components/monorise-core.js.map +1 -0
  685. package/dist/components/q-function.d.ts +17 -0
  686. package/dist/components/q-function.d.ts.map +1 -0
  687. package/dist/components/q-function.js +53 -0
  688. package/dist/components/q-function.js.map +1 -0
  689. package/dist/components/single-table.d.ts +12 -0
  690. package/dist/components/single-table.d.ts.map +1 -0
  691. package/dist/components/single-table.js +71 -0
  692. package/dist/components/single-table.js.map +1 -0
  693. package/dist/constants/event.d.ts +73 -0
  694. package/dist/constants/event.d.ts.map +1 -0
  695. package/dist/constants/event.js +74 -0
  696. package/dist/constants/event.js.map +1 -0
  697. package/dist/constants/table.d.ts +3 -0
  698. package/dist/constants/table.d.ts.map +1 -0
  699. package/dist/constants/table.js +3 -0
  700. package/dist/constants/table.js.map +1 -0
  701. package/dist/index.d.ts +11 -0
  702. package/dist/index.d.ts.map +1 -0
  703. package/dist/index.js +11 -0
  704. package/dist/index.js.map +1 -0
  705. package/dist/sst.config.d.ts +3 -0
  706. package/dist/sst.config.d.ts.map +1 -0
  707. package/dist/sst.config.js +24 -0
  708. package/dist/sst.config.js.map +1 -0
  709. package/dist/tsconfig.tsbuildinfo +1 -0
  710. package/package.json +25 -0
@@ -0,0 +1,1041 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import fs from "fs";
11
+ import path from "path";
12
+ import crypto from "crypto";
13
+ import archiver from "archiver";
14
+ import { glob } from "glob";
15
+ import { all, asset, interpolate, output, secret, unsecret, } from "@pulumi/pulumi";
16
+ import { bootstrap } from "./helpers/bootstrap.js";
17
+ import { toSeconds } from "../duration.js";
18
+ import { toMBs } from "../size.js";
19
+ import { Component, transform } from "../component.js";
20
+ import { Link } from "../link.js";
21
+ import { VisibleError } from "../error.js";
22
+ import { physicalName } from "../naming.js";
23
+ import { RETENTION } from "./logging.js";
24
+ import { cloudwatch, ecr, getCallerIdentityOutput, getPartitionOutput, getRegionOutput, iam, lambda, s3, } from "@pulumi/aws";
25
+ import { permission } from "./permission.js";
26
+ import { Vpc } from "./vpc.js";
27
+ import { Image } from "@pulumi/docker-build";
28
+ import { rpc } from "../rpc/rpc.js";
29
+ import { parseRoleArn } from "./helpers/arn.js";
30
+ import { RandomBytes } from "@pulumi/random";
31
+ import { lazy } from "../../util/lazy.js";
32
+ import { Efs } from "./efs.js";
33
+ import { FunctionEnvironmentUpdate } from "./providers/function-environment-update.js";
34
+ import { warnOnce } from "../../util/warn.js";
35
+ import { normalizeRouteArgs, } from "./router.js";
36
+ import { KvRoutesUpdate } from "./providers/kv-routes-update.js";
37
+ import { KvKeys } from "./providers/kv-keys.js";
38
+ /**
39
+ * The `Function` component lets you add serverless functions to your app.
40
+ * It uses [AWS Lambda](https://aws.amazon.com/lambda/).
41
+ *
42
+ * #### Supported runtimes
43
+ *
44
+ * Currently supports **Node.js** and **Golang** functions. **Python** and **Rust**
45
+ * are community supported. Other runtimes are on the roadmap.
46
+ *
47
+ * @example
48
+ *
49
+ * #### Minimal example
50
+ *
51
+ *
52
+ * <Tabs>
53
+ * <TabItem label="Node">
54
+ * Pass in the path to your handler function.
55
+ *
56
+ * ```ts title="sst.config.ts"
57
+ * new sst.aws.Function("MyFunction", {
58
+ * handler: "src/lambda.handler"
59
+ * });
60
+ * ```
61
+ *
62
+ * [Learn more below](#handler).
63
+ * </TabItem>
64
+ * <TabItem label="Python">
65
+ * Pass in the path to your handler function.
66
+ *
67
+ * ```ts title="sst.config.ts"
68
+ * new sst.aws.Function("MyFunction", {
69
+ * runtime: "python3.11",
70
+ * handler: "functions/src/functions/api.handler"
71
+ * });
72
+ * ```
73
+ *
74
+ * You need to have uv installed and your handler function needs to be in a uv workspace. [Learn more below](#handler).
75
+ * </TabItem>
76
+ * <TabItem label="Go">
77
+ * Pass in the directory to your Go module.
78
+ *
79
+ * ```ts title="sst.config.ts"
80
+ * new sst.aws.Function("MyFunction", {
81
+ * runtime: "go",
82
+ * handler: "./src"
83
+ * });
84
+ * ```
85
+ *
86
+ * [Learn more below](#handler).
87
+ * </TabItem>
88
+ * <TabItem label="Rust">
89
+ * Pass in the directory where your Cargo.toml lives.
90
+ *
91
+ * ```ts title="sst.config.ts"
92
+ * new sst.aws.Function("MyFunction", {
93
+ * runtime: "rust",
94
+ * handler: "./crates/api/"
95
+ * });
96
+ * ```
97
+ *
98
+ * [Learn more below](#handler).
99
+ * </TabItem>
100
+ * </Tabs>
101
+ *
102
+ * #### Set additional config
103
+ *
104
+ * Pass in additional Lambda config.
105
+ *
106
+ * ```ts {3,4} title="sst.config.ts"
107
+ * new sst.aws.Function("MyFunction", {
108
+ * handler: "src/lambda.handler",
109
+ * timeout: "3 minutes",
110
+ * memory: "1024 MB"
111
+ * });
112
+ * ```
113
+ *
114
+ * #### Link resources
115
+ *
116
+ * [Link resources](/docs/linking/) to the function. This will grant permissions
117
+ * to the resources and allow you to access it in your handler.
118
+ *
119
+ * ```ts {5} title="sst.config.ts"
120
+ * const bucket = new sst.aws.Bucket("MyBucket");
121
+ *
122
+ * new sst.aws.Function("MyFunction", {
123
+ * handler: "src/lambda.handler",
124
+ * link: [bucket]
125
+ * });
126
+ * ```
127
+ *
128
+ * You can use the [SDK](/docs/reference/sdk/) to access the linked resources
129
+ * in your handler.
130
+ *
131
+ * <Tabs>
132
+ * <TabItem label="Node">
133
+ * ```ts title="src/lambda.ts"
134
+ * import { Resource } from "sst";
135
+ *
136
+ * console.log(Resource.MyBucket.name);
137
+ * ```
138
+ * </TabItem>
139
+ * <TabItem label="Python">
140
+ * ```ts title="functions/src/functions/api.py"
141
+ * from sst import Resource
142
+ *
143
+ * def handler(event, context):
144
+ * print(Resource.MyBucket.name)
145
+ * ```
146
+ *
147
+ * Where the `sst` package can be added to your `pyproject.toml`.
148
+ *
149
+ * ```toml title="functions/pyproject.toml"
150
+ * [tool.uv.sources]
151
+ * sst = { git = "https://github.com/sst/sst.git", subdirectory = "sdk/python", branch = "dev" }
152
+ * ```
153
+ * </TabItem>
154
+ * <TabItem label="Go">
155
+ * ```go title="src/main.go"
156
+ * import (
157
+ * "github.com/sst/sst/v3/sdk/golang/resource"
158
+ * )
159
+ *
160
+ * resource.Get("MyBucket", "name")
161
+ * ```
162
+ * </TabItem>
163
+ * <TabItem label="Rust">
164
+ * ```rust title="src/main.rs"
165
+ * use sst_sdk::Resource;
166
+ * #[derive(serde::Deserialize, Debug)]
167
+ * struct Bucket {
168
+ * name: String,
169
+ * }
170
+ *
171
+ * let resource = Resource::init().unwrap();
172
+ * let Bucket { name } = resource.get("Bucket").unwrap();
173
+ * ```
174
+ * </TabItem>
175
+ * </Tabs>
176
+ *
177
+ * #### Set environment variables
178
+ *
179
+ * Set environment variables that you can read in your function. For example, using
180
+ * `process.env` in your Node.js functions.
181
+ *
182
+ * ```ts {4} title="sst.config.ts"
183
+ * new sst.aws.Function("MyFunction", {
184
+ * handler: "src/lambda.handler",
185
+ * environment: {
186
+ * DEBUG: "true"
187
+ * }
188
+ * });
189
+ * ```
190
+ *
191
+ * #### Enable function URLs
192
+ *
193
+ * Enable function URLs to invoke the function over HTTP.
194
+ *
195
+ * ```ts {3} title="sst.config.ts"
196
+ * new sst.aws.Function("MyFunction", {
197
+ * handler: "src/lambda.handler",
198
+ * url: true
199
+ * });
200
+ * ```
201
+ *
202
+ * #### Bundling
203
+ *
204
+ * Customize how SST uses [esbuild](https://esbuild.github.io/) to bundle your Node.js
205
+ * functions with the `nodejs` property.
206
+ *
207
+ * ```ts title="sst.config.ts" {3-5}
208
+ * new sst.aws.Function("MyFunction", {
209
+ * handler: "src/lambda.handler",
210
+ * nodejs: {
211
+ * install: ["pg"]
212
+ * }
213
+ * });
214
+ * ```
215
+ *
216
+ * Or override it entirely by passing in your own function `bundle`.
217
+ */
218
+ export class Function extends Component {
219
+ constructor(name, args, opts) {
220
+ var _a, _b;
221
+ super(__pulumiType, name, args, opts);
222
+ this.constructorName = name;
223
+ const parent = this;
224
+ const dev = normalizeDev();
225
+ const isContainer = all([args.python, dev]).apply(([python, dev]) => { var _a; return !dev && ((_a = python === null || python === void 0 ? void 0 : python.container) !== null && _a !== void 0 ? _a : false); });
226
+ const partition = getPartitionOutput({}, opts).partition;
227
+ const region = getRegionOutput({}, opts).name;
228
+ const bootstrapData = region.apply((region) => bootstrap.forRegion(region));
229
+ const injections = normalizeInjections();
230
+ const runtime = output((_a = args.runtime) !== null && _a !== void 0 ? _a : "nodejs20.x");
231
+ const timeout = normalizeTimeout();
232
+ const memory = normalizeMemory();
233
+ const storage = output(args.storage).apply((v) => v !== null && v !== void 0 ? v : "512 MB");
234
+ const architecture = output(args.architecture).apply((v) => v !== null && v !== void 0 ? v : "x86_64");
235
+ const environment = normalizeEnvironment();
236
+ const streaming = normalizeStreaming();
237
+ const logging = normalizeLogging();
238
+ const volume = normalizeVolume();
239
+ const url = normalizeUrl();
240
+ const copyFiles = normalizeCopyFiles();
241
+ const policies = output((_b = args.policies) !== null && _b !== void 0 ? _b : []);
242
+ const vpc = normalizeVpc();
243
+ const linkData = buildLinkData();
244
+ const linkPermissions = buildLinkPermissions();
245
+ const { bundle, handler: handler0, sourcemaps } = buildHandler();
246
+ const { handler, wrapper } = buildHandlerWrapper();
247
+ const role = createRole();
248
+ const imageAsset = createImageAsset();
249
+ const logGroup = createLogGroup();
250
+ const zipAsset = createZipAsset();
251
+ const fn = createFunction();
252
+ const urlEndpoint = createUrl();
253
+ createProvisioned();
254
+ const eventInvokeConfig = createEventInvokeConfig();
255
+ const links = linkData.apply((input) => input.map((item) => item.name));
256
+ this.function = fn;
257
+ this.role = role;
258
+ this.logGroup = logGroup;
259
+ this.urlEndpoint = urlEndpoint;
260
+ this.eventInvokeConfig = eventInvokeConfig;
261
+ const buildInput = output({
262
+ functionID: name,
263
+ handler: args.handler,
264
+ bundle: args.bundle,
265
+ logGroup: logGroup.apply((l) => l === null || l === void 0 ? void 0 : l.name),
266
+ encryptionKey: Function.encryptionKey().base64,
267
+ runtime,
268
+ links: output(linkData).apply((input) => Object.fromEntries(input.map((item) => [item.name, item.properties]))),
269
+ copyFiles,
270
+ properties: output({ nodejs: args.nodejs, python: args.python }).apply((val) => (Object.assign(Object.assign({}, (val.nodejs || val.python)), { architecture }))),
271
+ dev,
272
+ });
273
+ buildInput.apply((input) => __awaiter(this, void 0, void 0, function* () {
274
+ if (!input.dev)
275
+ return;
276
+ yield rpc.call("Runtime.AddTarget", input);
277
+ }));
278
+ this.registerOutputs({
279
+ _live: unsecret(output(dev).apply((dev) => {
280
+ if (!dev)
281
+ return undefined;
282
+ return all([
283
+ name,
284
+ links,
285
+ args.handler,
286
+ args.bundle,
287
+ args.runtime,
288
+ args.nodejs,
289
+ copyFiles,
290
+ ]).apply(([name, links, handler, bundle, runtime, nodejs, copyFiles]) => {
291
+ return {
292
+ functionID: name,
293
+ links,
294
+ handler: handler,
295
+ bundle: bundle,
296
+ runtime: runtime || "nodejs20.x",
297
+ copyFiles,
298
+ properties: nodejs,
299
+ };
300
+ });
301
+ })),
302
+ _metadata: {
303
+ handler: args.handler,
304
+ internal: args._skipMetadata,
305
+ dev: dev,
306
+ },
307
+ _hint: args._skipHint ? undefined : urlEndpoint,
308
+ });
309
+ function normalizeDev() {
310
+ return all([args.dev, args.live]).apply(([d, l]) => $dev && d !== false && l !== false);
311
+ }
312
+ function normalizeInjections() {
313
+ return output(args.injections).apply((injections) => injections !== null && injections !== void 0 ? injections : []);
314
+ }
315
+ function normalizeTimeout() {
316
+ return output(args.timeout).apply((timeout) => timeout !== null && timeout !== void 0 ? timeout : "20 seconds");
317
+ }
318
+ function normalizeMemory() {
319
+ return output(args.memory).apply((memory) => memory !== null && memory !== void 0 ? memory : "1024 MB");
320
+ }
321
+ function normalizeEnvironment() {
322
+ return all([
323
+ args.environment,
324
+ dev,
325
+ bootstrapData,
326
+ Function.encryptionKey().base64,
327
+ args.link,
328
+ ]).apply((_a) => __awaiter(this, [_a], void 0, function* ([environment, dev, bootstrap, key, link]) {
329
+ const result = environment !== null && environment !== void 0 ? environment : {};
330
+ result.SST_RESOURCE_App = JSON.stringify({
331
+ name: $app.name,
332
+ stage: $app.stage,
333
+ });
334
+ for (const linkable of link || []) {
335
+ if (!Link.isLinkable(linkable))
336
+ continue;
337
+ const def = linkable.getSSTLink();
338
+ for (const item of def.include || []) {
339
+ if (item.type === "environment")
340
+ Object.assign(result, item.env);
341
+ }
342
+ }
343
+ result.SST_KEY = key;
344
+ result.SST_KEY_FILE = "resource.enc";
345
+ if (dev) {
346
+ const appsync = yield Function.appsync();
347
+ result.SST_REGION = process.env.SST_AWS_REGION;
348
+ result.SST_APPSYNC_HTTP = appsync.http;
349
+ result.SST_APPSYNC_REALTIME = appsync.realtime;
350
+ result.SST_FUNCTION_ID = name;
351
+ result.SST_APP = $app.name;
352
+ result.SST_STAGE = $app.stage;
353
+ result.SST_ASSET_BUCKET = bootstrap.asset;
354
+ if (process.env.SST_FUNCTION_TIMEOUT) {
355
+ result.SST_FUNCTION_TIMEOUT = process.env.SST_FUNCTION_TIMEOUT;
356
+ }
357
+ }
358
+ return result;
359
+ }));
360
+ }
361
+ function normalizeStreaming() {
362
+ return output(args.streaming).apply((streaming) => streaming !== null && streaming !== void 0 ? streaming : false);
363
+ }
364
+ function normalizeLogging() {
365
+ return output(args.logging).apply((logging) => {
366
+ var _a, _b;
367
+ if (logging === false)
368
+ return undefined;
369
+ if ((logging === null || logging === void 0 ? void 0 : logging.retention) && (logging === null || logging === void 0 ? void 0 : logging.logGroup)) {
370
+ throw new VisibleError(`Cannot set both "logging.retention" and "logging.logGroup"`);
371
+ }
372
+ return {
373
+ logGroup: logging === null || logging === void 0 ? void 0 : logging.logGroup,
374
+ retention: (_a = logging === null || logging === void 0 ? void 0 : logging.retention) !== null && _a !== void 0 ? _a : "1 month",
375
+ format: (_b = logging === null || logging === void 0 ? void 0 : logging.format) !== null && _b !== void 0 ? _b : "text",
376
+ };
377
+ });
378
+ }
379
+ function normalizeVolume() {
380
+ if (!args.volume)
381
+ return;
382
+ return output(args.volume).apply((volume) => {
383
+ var _a;
384
+ return ({
385
+ efs: volume.efs instanceof Efs
386
+ ? volume.efs.nodes.accessPoint.arn
387
+ : output(volume.efs),
388
+ path: (_a = volume.path) !== null && _a !== void 0 ? _a : "/mnt/efs",
389
+ });
390
+ });
391
+ }
392
+ function normalizeUrl() {
393
+ return output(args.url).apply((url) => {
394
+ var _a;
395
+ if (url === false || url === undefined)
396
+ return;
397
+ if (url === true) {
398
+ url = {};
399
+ }
400
+ // normalize authorization
401
+ const defaultAuthorization = "none";
402
+ const authorization = (_a = url.authorization) !== null && _a !== void 0 ? _a : defaultAuthorization;
403
+ // normalize cors
404
+ const defaultCors = {
405
+ allowHeaders: ["*"],
406
+ allowMethods: ["*"],
407
+ allowOrigins: ["*"],
408
+ };
409
+ const cors = url.cors === false
410
+ ? undefined
411
+ : url.cors === true || url.cors === undefined
412
+ ? defaultCors
413
+ : Object.assign(Object.assign(Object.assign({}, defaultCors), url.cors), { maxAge: url.cors.maxAge && toSeconds(url.cors.maxAge) });
414
+ return {
415
+ authorization,
416
+ cors,
417
+ route: normalizeRouteArgs(url.router, url.route),
418
+ };
419
+ });
420
+ }
421
+ function normalizeCopyFiles() {
422
+ var _a;
423
+ return output((_a = args.copyFiles) !== null && _a !== void 0 ? _a : []).apply((copyFiles) => Promise.all(copyFiles.map((entry) => __awaiter(this, void 0, void 0, function* () {
424
+ const from = path.join($cli.paths.root, entry.from);
425
+ const to = entry.to || entry.from;
426
+ if (path.isAbsolute(to)) {
427
+ throw new VisibleError(`Copy destination path "${to}" must be relative`);
428
+ }
429
+ const stats = yield fs.promises.stat(from);
430
+ const isDir = stats.isDirectory();
431
+ return { from, to, isDir };
432
+ }))));
433
+ }
434
+ function normalizeVpc() {
435
+ // "vpc" is undefined
436
+ if (!args.vpc)
437
+ return;
438
+ // "vpc" is a Vpc component
439
+ if (args.vpc instanceof Vpc) {
440
+ const result = {
441
+ privateSubnets: args.vpc.privateSubnets,
442
+ securityGroups: args.vpc.securityGroups,
443
+ };
444
+ return all([
445
+ args.vpc.id,
446
+ args.vpc.nodes.natGateways,
447
+ args.vpc.nodes.natInstances,
448
+ ]).apply(([id, natGateways, natInstances]) => {
449
+ if (natGateways.length === 0 && natInstances.length === 0) {
450
+ warnOnce(`\nWarning: One or more functions are deployed in the "${id}" VPC, which does not have a NAT gateway. As a result, these functions cannot access the internet. If your functions need internet access, enable it by setting the "nat" prop on the "Vpc" component.\n`);
451
+ }
452
+ return result;
453
+ });
454
+ }
455
+ return output(args.vpc).apply((vpc) => {
456
+ // "vpc" is object
457
+ if (vpc.subnets) {
458
+ throw new VisibleError(`The "vpc.subnets" property has been renamed to "vpc.privateSubnets". Update your code to use "vpc.privateSubnets" instead.`);
459
+ }
460
+ return vpc;
461
+ });
462
+ }
463
+ function buildLinkData() {
464
+ return output(args.link || []).apply((links) => Link.build(links));
465
+ }
466
+ function buildLinkPermissions() {
467
+ return Link.getInclude("aws.permission", args.link);
468
+ }
469
+ function buildHandler() {
470
+ return all([runtime, dev, isContainer]).apply((_a) => __awaiter(this, [_a], void 0, function* ([runtime, dev, isContainer]) {
471
+ if (dev) {
472
+ return {
473
+ handler: "bootstrap",
474
+ bundle: path.join($cli.paths.platform, "dist", "bridge"),
475
+ };
476
+ }
477
+ const buildResult = buildInput.apply((input) => __awaiter(this, void 0, void 0, function* () {
478
+ var _a;
479
+ const result = yield rpc.call("Runtime.Build", Object.assign(Object.assign({}, input), { isContainer }));
480
+ if (result.errors.length > 0) {
481
+ throw new Error(result.errors.join("\n"));
482
+ }
483
+ if ((_a = args.hook) === null || _a === void 0 ? void 0 : _a.postbuild)
484
+ yield args.hook.postbuild(result.out);
485
+ return result;
486
+ }));
487
+ return {
488
+ handler: buildResult.handler,
489
+ bundle: buildResult.out,
490
+ sourcemaps: buildResult.sourcemaps,
491
+ };
492
+ }));
493
+ }
494
+ function buildHandlerWrapper() {
495
+ const ret = all([
496
+ dev,
497
+ bundle,
498
+ handler0,
499
+ linkData,
500
+ streaming,
501
+ injections,
502
+ runtime,
503
+ ]).apply((_a) => __awaiter(this, [_a], void 0, function* ([dev, bundle, handler, linkData, streaming, injections, runtime,]) {
504
+ if (dev)
505
+ return { handler };
506
+ if (!runtime.startsWith("nodejs")) {
507
+ return { handler };
508
+ }
509
+ const hasUserInjections = injections.length > 0;
510
+ if (!hasUserInjections)
511
+ return { handler };
512
+ const parsed = path.posix.parse(handler);
513
+ const handlerDir = parsed.dir;
514
+ const oldHandlerFileName = parsed.name;
515
+ const oldHandlerFunction = parsed.ext.replace(/^\./, "");
516
+ const newHandlerFileName = "server-index";
517
+ const newHandlerFunction = "handler";
518
+ // Validate handler file exists
519
+ const newHandlerFileExt = [".js", ".mjs", ".cjs"].find((ext) => fs.existsSync(path.join(bundle, handlerDir, oldHandlerFileName + ext)));
520
+ if (!newHandlerFileExt) {
521
+ throw new VisibleError(`Could not find handler file "${handler}" for function "${name}"`);
522
+ }
523
+ const split = injections.reduce((acc, item) => {
524
+ if (item.startsWith("outer:")) {
525
+ acc.outer.push(item.substring("outer:".length));
526
+ return acc;
527
+ }
528
+ acc.inner.push(item);
529
+ return acc;
530
+ }, { outer: [], inner: [] });
531
+ return {
532
+ handler: path.posix.join(handlerDir, `${newHandlerFileName}.${newHandlerFunction}`),
533
+ wrapper: {
534
+ name: path.posix.join(handlerDir, `${newHandlerFileName}.mjs`),
535
+ content: streaming
536
+ ? [
537
+ ...split.outer,
538
+ `export const ${newHandlerFunction} = awslambda.streamifyResponse(async (event, responseStream, context) => {`,
539
+ ...split.inner,
540
+ ` const { ${oldHandlerFunction}: rawHandler} = await import("./${oldHandlerFileName}${newHandlerFileExt}");`,
541
+ ` return rawHandler(event, responseStream, context);`,
542
+ `});`,
543
+ ].join("\n")
544
+ : [
545
+ ...split.outer,
546
+ `export const ${newHandlerFunction} = async (event, context) => {`,
547
+ ...split.inner,
548
+ ` const { ${oldHandlerFunction}: rawHandler} = await import("./${oldHandlerFileName}${newHandlerFileExt}");`,
549
+ ` return rawHandler(event, context);`,
550
+ `};`,
551
+ ].join("\n"),
552
+ },
553
+ };
554
+ }));
555
+ return {
556
+ handler: ret.handler,
557
+ wrapper: ret.wrapper,
558
+ };
559
+ }
560
+ function createRole() {
561
+ var _a;
562
+ if (args.role) {
563
+ return iam.Role.get(`${name}Role`, output(args.role).apply(parseRoleArn).roleName, {}, { parent });
564
+ }
565
+ const policy = all([args.permissions || [], linkPermissions, dev]).apply(([argsPermissions, linkPermissions, dev]) => iam.getPolicyDocumentOutput({
566
+ statements: [
567
+ ...argsPermissions,
568
+ ...linkPermissions,
569
+ ...(dev
570
+ ? [
571
+ {
572
+ effect: "allow",
573
+ actions: ["appsync:*"],
574
+ resources: ["*"],
575
+ },
576
+ {
577
+ effect: "allow",
578
+ actions: ["s3:*"],
579
+ resources: [
580
+ interpolate `arn:${partition}:s3:::${bootstrapData.asset}`,
581
+ interpolate `arn:${partition}:s3:::${bootstrapData.asset}/*`,
582
+ ],
583
+ },
584
+ ]
585
+ : []),
586
+ ].map((item) => ({
587
+ effect: (() => {
588
+ var _a;
589
+ const effect = (_a = item.effect) !== null && _a !== void 0 ? _a : "allow";
590
+ return effect.charAt(0).toUpperCase() + effect.slice(1);
591
+ })(),
592
+ actions: item.actions,
593
+ resources: item.resources,
594
+ })),
595
+ }));
596
+ return new iam.Role(...transform((_a = args.transform) === null || _a === void 0 ? void 0 : _a.role, `${name}Role`, {
597
+ assumeRolePolicy: !dev
598
+ ? iam.assumeRolePolicyForPrincipal({
599
+ Service: "lambda.amazonaws.com",
600
+ })
601
+ : iam.getPolicyDocumentOutput({
602
+ statements: [
603
+ {
604
+ actions: ["sts:AssumeRole"],
605
+ principals: [
606
+ {
607
+ type: "Service",
608
+ identifiers: ["lambda.amazonaws.com"],
609
+ },
610
+ {
611
+ type: "AWS",
612
+ identifiers: [
613
+ interpolate `arn:${partition}:iam::${getCallerIdentityOutput({}, opts).accountId}:root`,
614
+ ],
615
+ },
616
+ ],
617
+ },
618
+ ],
619
+ }).json,
620
+ // if there are no statements, do not add an inline policy.
621
+ // adding an inline policy with no statements will cause an error.
622
+ inlinePolicies: policy.apply(({ statements }) => statements ? [{ name: "inline", policy: policy.json }] : []),
623
+ managedPolicyArns: all([logging, policies]).apply(([logging, policies]) => [
624
+ ...policies,
625
+ ...(logging
626
+ ? [
627
+ interpolate `arn:${partition}:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole`,
628
+ ]
629
+ : []),
630
+ ...(vpc
631
+ ? [
632
+ interpolate `arn:${partition}:iam::aws:policy/service-role/AWSLambdaVPCAccessExecutionRole`,
633
+ ]
634
+ : []),
635
+ ]),
636
+ }, { parent }));
637
+ }
638
+ function createImageAsset() {
639
+ // The build artifact directory already exists, with all the user code and
640
+ // config files. It also has the dockerfile, we need to now just build and push to
641
+ // the container registry.
642
+ return all([isContainer, dev, bundle]).apply(([isContainer, dev, bundle, // We need the bundle to be resolved because of implicit dockerfiles even though we don't use it here
643
+ ]) => {
644
+ if (!isContainer || dev)
645
+ return;
646
+ const authToken = ecr.getAuthorizationTokenOutput({
647
+ registryId: bootstrapData.assetEcrRegistryId,
648
+ });
649
+ return new Image(`${name}Image`, {
650
+ tags: [$interpolate `${bootstrapData.assetEcrUrl}:latest`],
651
+ context: {
652
+ location: path.join($cli.paths.work, "artifacts", `${name}-src`),
653
+ },
654
+ cacheFrom: [
655
+ {
656
+ registry: {
657
+ ref: $interpolate `${bootstrapData.assetEcrUrl}:${name}-cache`,
658
+ },
659
+ },
660
+ ],
661
+ cacheTo: [
662
+ {
663
+ registry: {
664
+ ref: $interpolate `${bootstrapData.assetEcrUrl}:${name}-cache`,
665
+ imageManifest: true,
666
+ ociMediaTypes: true,
667
+ mode: "max",
668
+ },
669
+ },
670
+ ],
671
+ platforms: [
672
+ architecture.apply((v) => v === "arm64" ? "linux/arm64" : "linux/amd64"),
673
+ ],
674
+ push: true,
675
+ registries: [
676
+ authToken.apply((authToken) => ({
677
+ address: authToken.proxyEndpoint,
678
+ username: authToken.userName,
679
+ password: secret(authToken.password),
680
+ })),
681
+ ],
682
+ }, { parent });
683
+ });
684
+ }
685
+ function createZipAsset() {
686
+ // Note: cannot point the bundle to the `.open-next/server-function`
687
+ // b/c the folder contains node_modules. And pnpm node_modules
688
+ // contains symlinks. Pulumi cannot zip symlinks correctly.
689
+ // We will zip the folder ourselves.
690
+ return all([
691
+ bundle,
692
+ wrapper,
693
+ sourcemaps,
694
+ copyFiles,
695
+ isContainer,
696
+ logGroup.apply((l) => l === null || l === void 0 ? void 0 : l.arn),
697
+ dev,
698
+ ]).apply((_a) => __awaiter(this, [_a], void 0, function* ([bundle, wrapper, sourcemaps, copyFiles, isContainer, logGroupArn, dev,]) {
699
+ if (isContainer)
700
+ return;
701
+ const zipPath = path.resolve($cli.paths.work, "artifacts", name, "code.zip");
702
+ yield fs.promises.mkdir(path.dirname(zipPath), {
703
+ recursive: true,
704
+ });
705
+ yield new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () {
706
+ const ws = fs.createWriteStream(zipPath);
707
+ const archive = archiver("zip", {
708
+ // Ensure deterministic zip file hashes
709
+ // https://github.com/archiverjs/node-archiver/issues/397#issuecomment-554327338
710
+ statConcurrency: 1,
711
+ });
712
+ archive.on("warning", reject);
713
+ archive.on("error", reject);
714
+ // archive has been finalized and the output file descriptor has closed, resolve promise
715
+ // this has to be done before calling `finalize` since the events may fire immediately after.
716
+ // see https://www.npmjs.com/package/archiver
717
+ ws.once("close", () => {
718
+ resolve(zipPath);
719
+ });
720
+ archive.pipe(ws);
721
+ const files = [];
722
+ for (const item of [
723
+ {
724
+ from: bundle,
725
+ to: ".",
726
+ isDir: true,
727
+ },
728
+ ...(!dev ? copyFiles : []),
729
+ ]) {
730
+ if (!item.isDir) {
731
+ files.push({
732
+ from: item.from,
733
+ to: item.to,
734
+ });
735
+ }
736
+ const found = yield glob("**", {
737
+ cwd: item.from,
738
+ dot: true,
739
+ ignore: (sourcemaps === null || sourcemaps === void 0 ? void 0 : sourcemaps.map((item) => path.relative(bundle, item))) || [],
740
+ });
741
+ files.push(...found.map((file) => ({
742
+ from: path.join(item.from, file),
743
+ to: path.join(item.to, file),
744
+ })));
745
+ }
746
+ files.sort((a, b) => a.to.localeCompare(b.to));
747
+ for (const file of files) {
748
+ archive.file(file.from, {
749
+ name: file.to,
750
+ date: new Date(0),
751
+ });
752
+ }
753
+ // Add handler wrapper into the zip
754
+ if (wrapper) {
755
+ archive.append(wrapper.content, {
756
+ name: wrapper.name,
757
+ date: new Date(0),
758
+ });
759
+ }
760
+ yield archive.finalize();
761
+ }));
762
+ // Calculate hash of the zip file
763
+ const hash = crypto.createHash("sha256");
764
+ hash.update(yield fs.promises.readFile(zipPath, "utf-8"));
765
+ const hashValue = hash.digest("hex");
766
+ const assetBucket = region.apply((region) => bootstrap.forRegion(region).then((d) => d.asset));
767
+ if (logGroupArn && sourcemaps) {
768
+ let index = 0;
769
+ for (const file of sourcemaps) {
770
+ new s3.BucketObjectv2(`${name}Sourcemap${index}`, {
771
+ key: interpolate `sourcemap/${logGroupArn}/${hashValue}.${path.basename(file)}`,
772
+ bucket: assetBucket,
773
+ source: new asset.FileAsset(file),
774
+ }, { parent, retainOnDelete: true });
775
+ index++;
776
+ }
777
+ }
778
+ return new s3.BucketObjectv2(`${name}Code`, {
779
+ key: interpolate `assets/${name}-code-${hashValue}.zip`,
780
+ bucket: assetBucket,
781
+ source: new asset.FileArchive(zipPath),
782
+ }, { parent });
783
+ }));
784
+ }
785
+ function createLogGroup() {
786
+ return logging.apply((logging) => {
787
+ var _a, _b;
788
+ if (!logging)
789
+ return;
790
+ if (logging.logGroup)
791
+ return;
792
+ return new cloudwatch.LogGroup(...transform((_a = args.transform) === null || _a === void 0 ? void 0 : _a.logGroup, `${name}LogGroup`, {
793
+ name: interpolate `/aws/lambda/${(_b = args.name) !== null && _b !== void 0 ? _b : physicalName(64, `${name}Function`)}`,
794
+ retentionInDays: RETENTION[logging.retention],
795
+ }, { parent, ignoreChanges: ["name"] }));
796
+ });
797
+ }
798
+ function createFunction() {
799
+ return all([
800
+ logging,
801
+ logGroup,
802
+ isContainer,
803
+ imageAsset,
804
+ zipAsset,
805
+ args.concurrency,
806
+ dev,
807
+ ]).apply(([logging, logGroup, isContainer, imageAsset, zipAsset, concurrency, dev,]) => {
808
+ var _a, _b, _c, _d;
809
+ // This is a hack to avoid handler being marked as having propertyDependencies.
810
+ // There is an unresolved bug in pulumi that causes issues when it does
811
+ // @ts-expect-error
812
+ handler.allResources = () => Promise.resolve(new Set());
813
+ const transformed = transform((_a = args.transform) === null || _a === void 0 ? void 0 : _a.function, `${name}Function`, Object.assign({ name: args.name, description: (_b = args.description) !== null && _b !== void 0 ? _b : "", role: (_c = args.role) !== null && _c !== void 0 ? _c : role.arn, timeout: timeout.apply((timeout) => toSeconds(timeout)), memorySize: memory.apply((memory) => toMBs(memory)), ephemeralStorage: { size: storage.apply((v) => toMBs(v)) }, environment: {
814
+ variables: environment,
815
+ }, architectures: [architecture], loggingConfig: logging && {
816
+ logFormat: logging.format === "json" ? "JSON" : "Text",
817
+ logGroup: (_d = logging.logGroup) !== null && _d !== void 0 ? _d : logGroup.name,
818
+ }, vpcConfig: vpc && {
819
+ securityGroupIds: vpc.securityGroups,
820
+ subnetIds: vpc.privateSubnets,
821
+ }, fileSystemConfig: volume && {
822
+ arn: volume.efs,
823
+ localMountPath: volume.path,
824
+ }, layers: args.layers, tags: args.tags, publish: output(args.versioning).apply((v) => v !== null && v !== void 0 ? v : false), reservedConcurrentExecutions: concurrency === null || concurrency === void 0 ? void 0 : concurrency.reserved }, (isContainer
825
+ ? {
826
+ packageType: "Image",
827
+ imageUri: imageAsset.ref.apply((ref) => ref === null || ref === void 0 ? void 0 : ref.replace(":latest", "")),
828
+ imageConfig: {
829
+ commands: [
830
+ all([handler, runtime]).apply(([handler, runtime]) => {
831
+ // If a python container image we have to rewrite the handler path so lambdaric is happy
832
+ // This means no leading . and replace all / with .
833
+ if (isContainer && runtime.includes("python")) {
834
+ return handler
835
+ .replace(/\.\//g, "")
836
+ .replace(/\//g, ".");
837
+ }
838
+ return handler;
839
+ }),
840
+ ],
841
+ },
842
+ }
843
+ : {
844
+ packageType: "Zip",
845
+ s3Bucket: zipAsset.bucket,
846
+ s3Key: zipAsset.key,
847
+ handler: unsecret(handler),
848
+ runtime: runtime.apply((v) => v === "go" || v === "rust" ? "provided.al2023" : v),
849
+ })), { parent });
850
+ return new lambda.Function(transformed[0], Object.assign(Object.assign({}, transformed[1]), (dev
851
+ ? {
852
+ description: transformed[1].description
853
+ ? output(transformed[1].description).apply((v) => `${v.substring(0, 240)} (live)`)
854
+ : "live",
855
+ runtime: "provided.al2023",
856
+ architectures: ["x86_64"],
857
+ }
858
+ : {})), transformed[2]);
859
+ });
860
+ }
861
+ function createUrl() {
862
+ return url.apply((url) => {
863
+ if (url === undefined)
864
+ return output(undefined);
865
+ // create the function url
866
+ const fnUrl = new lambda.FunctionUrl(`${name}Url`, {
867
+ functionName: fn.name,
868
+ authorizationType: url.authorization === "iam" ? "AWS_IAM" : "NONE",
869
+ invokeMode: streaming.apply((streaming) => streaming ? "RESPONSE_STREAM" : "BUFFERED"),
870
+ cors: url.cors,
871
+ }, { parent });
872
+ if (!url.route)
873
+ return fnUrl.functionUrl;
874
+ // add router route
875
+ const routeNamespace = crypto
876
+ .createHash("md5")
877
+ .update(`${$app.name}-${$app.stage}-${name}`)
878
+ .digest("hex")
879
+ .substring(0, 4);
880
+ new KvKeys(`${name}RouteKey`, {
881
+ store: url.route.routerKvStoreArn,
882
+ namespace: routeNamespace,
883
+ entries: fnUrl.functionUrl.apply((fnUrl) => ({
884
+ metadata: JSON.stringify({
885
+ host: new URL(fnUrl).host,
886
+ }),
887
+ })),
888
+ purge: false,
889
+ }, { parent });
890
+ new KvRoutesUpdate(`${name}RoutesUpdate`, {
891
+ store: url.route.routerKvStoreArn,
892
+ namespace: url.route.routerKvNamespace,
893
+ key: "routes",
894
+ entry: url.route.apply((route) => ["url", routeNamespace, route.hostPattern, route.pathPrefix].join(",")),
895
+ }, { parent });
896
+ return url.route.routerUrl;
897
+ });
898
+ }
899
+ function createProvisioned() {
900
+ return all([args.concurrency, fn.publish]).apply(([concurrency, publish]) => {
901
+ if (!(concurrency === null || concurrency === void 0 ? void 0 : concurrency.provisioned) || concurrency.provisioned === 0) {
902
+ return;
903
+ }
904
+ if (publish !== true) {
905
+ throw new VisibleError(`Provisioned concurrency requires function versioning. Set "versioning: true" to enable function versioning.`);
906
+ }
907
+ return new lambda.ProvisionedConcurrencyConfig(`${name}Provisioned`, {
908
+ functionName: fn.name,
909
+ qualifier: fn.version,
910
+ provisionedConcurrentExecutions: concurrency.provisioned,
911
+ }, { parent });
912
+ });
913
+ }
914
+ function createEventInvokeConfig() {
915
+ var _a;
916
+ if (args.retries === undefined) {
917
+ return undefined;
918
+ }
919
+ return new lambda.FunctionEventInvokeConfig(...transform((_a = args.transform) === null || _a === void 0 ? void 0 : _a.eventInvokeConfig, `${name}EventInvokeConfig`, {
920
+ functionName: fn.name,
921
+ maximumRetryAttempts: args.retries,
922
+ }, { parent }));
923
+ }
924
+ }
925
+ /**
926
+ * The underlying [resources](/docs/components/#nodes) this component creates.
927
+ */
928
+ get nodes() {
929
+ return {
930
+ /**
931
+ * The IAM Role the function will use.
932
+ */
933
+ role: this.role,
934
+ /**
935
+ * The AWS Lambda function.
936
+ */
937
+ function: this.function,
938
+ /**
939
+ * The CloudWatch Log Group the function logs are stored.
940
+ */
941
+ logGroup: this.logGroup,
942
+ /**
943
+ * The Function Event Invoke Config resource if retries are configured.
944
+ */
945
+ eventInvokeConfig: this.eventInvokeConfig,
946
+ };
947
+ }
948
+ /**
949
+ * The Lambda function URL if `url` is enabled.
950
+ */
951
+ get url() {
952
+ return this.urlEndpoint.apply((url) => {
953
+ if (!url) {
954
+ throw new VisibleError(`Function URL is not enabled. Enable it with "url: true".`);
955
+ }
956
+ return url;
957
+ });
958
+ }
959
+ /**
960
+ * The name of the Lambda function.
961
+ */
962
+ get name() {
963
+ return this.function.name;
964
+ }
965
+ /**
966
+ * The ARN of the Lambda function.
967
+ */
968
+ get arn() {
969
+ return this.function.arn;
970
+ }
971
+ /**
972
+ * Add environment variables lazily to the function after the function is created.
973
+ *
974
+ * This is useful for adding environment variables that are only available after the
975
+ * function is created, like the function URL.
976
+ *
977
+ * @param environment The environment variables to add to the function.
978
+ *
979
+ * @example
980
+ * Add the function URL as an environment variable.
981
+ *
982
+ * ```ts title="sst.config.ts"
983
+ * const fn = new sst.aws.Function("MyFunction", {
984
+ * handler: "src/handler.handler",
985
+ * url: true,
986
+ * });
987
+ *
988
+ * fn.addEnvironment({
989
+ * URL: fn.url,
990
+ * });
991
+ * ```
992
+ */
993
+ addEnvironment(environment) {
994
+ return new FunctionEnvironmentUpdate(`${this.constructorName}EnvironmentUpdate`, {
995
+ functionName: this.name,
996
+ environment,
997
+ region: getRegionOutput(undefined, { parent: this }).name,
998
+ }, { parent: this });
999
+ }
1000
+ /** @internal */
1001
+ static fromDefinition(name, definition, override, argsTransform, opts) {
1002
+ return output(definition).apply((definition) => {
1003
+ if (typeof definition === "string") {
1004
+ return new Function(...transform(argsTransform, name, Object.assign({ handler: definition }, override), opts || {}));
1005
+ }
1006
+ else if (definition.handler) {
1007
+ return new Function(...transform(argsTransform, name, Object.assign(Object.assign(Object.assign({}, definition), override), { permissions: all([
1008
+ definition.permissions,
1009
+ override === null || override === void 0 ? void 0 : override.permissions,
1010
+ ]).apply(([permissions, overridePermissions]) => [
1011
+ ...(permissions !== null && permissions !== void 0 ? permissions : []),
1012
+ ...(overridePermissions !== null && overridePermissions !== void 0 ? overridePermissions : []),
1013
+ ]) }), opts || {}));
1014
+ }
1015
+ throw new Error(`Invalid function definition for the "${name}" Function`);
1016
+ });
1017
+ }
1018
+ /** @internal */
1019
+ getSSTLink() {
1020
+ return {
1021
+ properties: {
1022
+ name: this.name,
1023
+ url: this.urlEndpoint,
1024
+ },
1025
+ include: [
1026
+ permission({
1027
+ actions: ["lambda:InvokeFunction"],
1028
+ resources: [this.function.arn],
1029
+ }),
1030
+ ],
1031
+ };
1032
+ }
1033
+ }
1034
+ Function.encryptionKey = lazy(() => new RandomBytes("LambdaEncryptionKey", {
1035
+ length: 32,
1036
+ }));
1037
+ Function.appsync = lazy(() => rpc.call("Provider.Aws.Appsync", {}));
1038
+ const __pulumiType = "sst:aws:Function";
1039
+ // @ts-expect-error
1040
+ Function.__pulumiType = __pulumiType;
1041
+ //# sourceMappingURL=function.js.map