@readmagic/workmate 0.0.1

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 (552) hide show
  1. package/dist/chunks/AddWorkspaceDirectory-BSLHrjbt.js +1 -0
  2. package/dist/chunks/App-DY5O6IKw.js +1 -0
  3. package/dist/chunks/ApproveApiKey-BEzfC6r3.js +1 -0
  4. package/dist/chunks/ApproveApiKey-DfAPwDix.js +1 -0
  5. package/dist/chunks/AssistantSessionChooser-Ce3PraaD.js +1 -0
  6. package/dist/chunks/BackgroundTasksDialog-Dvhcgahe.js +2 -0
  7. package/dist/chunks/BypassPermissionsModeDialog-B68V1bCq.js +1 -0
  8. package/dist/chunks/ClaudeMdExternalIncludesDialog-BV7HHcgL.js +1 -0
  9. package/dist/chunks/ClaudeMdExternalIncludesDialog-CTWhpIm8.js +1 -0
  10. package/dist/chunks/ConsoleOAuthFlow-CU5fCPKq.js +1 -0
  11. package/dist/chunks/DesktopHandoff-BRbU4is4.js +1 -0
  12. package/dist/chunks/Dialog-vfLXEPed.js +1 -0
  13. package/dist/chunks/DiffDialog-CBluIK-x.js +6 -0
  14. package/dist/chunks/Doctor-B0CRtxi2.js +1 -0
  15. package/dist/chunks/Doctor-WxNv49HC.js +3 -0
  16. package/dist/chunks/ExitFlow-CRPgptCN.js +2 -0
  17. package/dist/chunks/Feedback-CEtzaLr3.js +2 -0
  18. package/dist/chunks/Grove--kttLxvs.js +11 -0
  19. package/dist/chunks/Grove-CelgLWH4.js +1 -0
  20. package/dist/chunks/HybridTransport-BgV5_7Az.js +4 -0
  21. package/dist/chunks/InvalidConfigDialog-DCGwXW_p.js +1 -0
  22. package/dist/chunks/InvalidSettingsDialog-jTwsdXWr.js +1 -0
  23. package/dist/chunks/ListItem-vfLXEPed.js +1 -0
  24. package/dist/chunks/MCPConnectionManager-BX0LMz9J.js +1 -0
  25. package/dist/chunks/McpParsingWarnings-WQrWJeWP.js +1 -0
  26. package/dist/chunks/MessageSelector-_UZB8cGb.js +3 -0
  27. package/dist/chunks/Messages-jCoW_1Rr.js +11 -0
  28. package/dist/chunks/Onboarding-BoIVNCgc.js +1 -0
  29. package/dist/chunks/OverageCreditUpsell-1FCN8bH3.js +1 -0
  30. package/dist/chunks/PermissionDialog-0ya1CU5k.js +1 -0
  31. package/dist/chunks/PluginSettings-BD9JLV9-.js +17 -0
  32. package/dist/chunks/PressEnterToContinue-Dl9Hg9Mf.js +1 -0
  33. package/dist/chunks/PromptInputFooterSuggestions-CrGST0Cq.js +1 -0
  34. package/dist/chunks/PromptInputHelpMenu-B2TDpbpw.js +1 -0
  35. package/dist/chunks/QueryEngine-D2HUnwmU.js +1 -0
  36. package/dist/chunks/REPL-BV4WyYMg.js +142 -0
  37. package/dist/chunks/REPL-DcpN3MRC.js +1 -0
  38. package/dist/chunks/RemoteCallout-DS_EV6Fh.js +1 -0
  39. package/dist/chunks/RemoteSessionManager-Tx1N2uVL.js +2 -0
  40. package/dist/chunks/ResumeConversation-Cw3vP4G8.js +1 -0
  41. package/dist/chunks/SSETransport-BXiEBMpb.js +4 -0
  42. package/dist/chunks/SearchBox-vfLXEPed.js +1 -0
  43. package/dist/chunks/SearchExtraToolsTool-D3VOFq9R.js +1 -0
  44. package/dist/chunks/Settings-ns6mRsDc.js +2 -0
  45. package/dist/chunks/TeleportProgress-CcDzMC5L.js +1 -0
  46. package/dist/chunks/TeleportRepoMismatchDialog-DZbxl4sD.js +1 -0
  47. package/dist/chunks/TeleportResumeWrapper-EowJO5nm.js +1 -0
  48. package/dist/chunks/ThemePicker-BYbChJpu.js +1 -0
  49. package/dist/chunks/TrustDialog-DA3YTk_k.js +1 -0
  50. package/dist/chunks/TungstenTool-Cb7gJvq4.js +1 -0
  51. package/dist/chunks/TungstenTool-CxMQVCuF.js +1 -0
  52. package/dist/chunks/ValidationErrorsList-Cx-hoRwG.js +2 -0
  53. package/dist/chunks/WelcomeV2-BTfttGcv.js +1 -0
  54. package/dist/chunks/add-dir-CWt69NAZ.js +1 -0
  55. package/dist/chunks/agentDisplay-CQ4mZWFH.js +1 -0
  56. package/dist/chunks/agents-C6jzKOit.js +2 -0
  57. package/dist/chunks/agents-D4clhuCl.js +103 -0
  58. package/dist/chunks/ajv-5vMo9UcX.js +8 -0
  59. package/dist/chunks/allErrors-HMPqE0jK.js +1 -0
  60. package/dist/chunks/analytics-BotDBGh0.js +1 -0
  61. package/dist/chunks/ant-9Z5bppVC.js +1 -0
  62. package/dist/chunks/api-L2IgleTV.js +1 -0
  63. package/dist/chunks/api-TgV7fl9V.js +1 -0
  64. package/dist/chunks/asciicast-DYbkzGCN.js +1 -0
  65. package/dist/chunks/asciicast-n-BBfgDq.js +4 -0
  66. package/dist/chunks/assistant-BA9_Mo9U.js +1 -0
  67. package/dist/chunks/assistant-BiNOSla3.js +1 -0
  68. package/dist/chunks/assistant-YvbVKjVh.js +1 -0
  69. package/dist/chunks/attributionHooks-CUAoGkU6.js +1 -0
  70. package/dist/chunks/attributionTrailer-oKKrF3z8.js +1 -0
  71. package/dist/chunks/auth-CEig4Gxp.js +1 -0
  72. package/dist/chunks/auth-CbGDlhyO.js +1 -0
  73. package/dist/chunks/auth-DHyCIxCk.js +15 -0
  74. package/dist/chunks/autoMode-Db4QrgFr.js +45 -0
  75. package/dist/chunks/autoModeDenials-BxNzGJdR.js +1 -0
  76. package/dist/chunks/autonomy-BkAMA7du.js +1 -0
  77. package/dist/chunks/autonomy-D4Vy-RPQ.js +15 -0
  78. package/dist/chunks/autonomyPanel-EjfO8jvg.js +1 -0
  79. package/dist/chunks/axios-BHBm_hhU.js +1 -0
  80. package/dist/chunks/axios-DaWTGg7G.js +16 -0
  81. package/dist/chunks/backgroundHousekeeping-BNEKWHhH.js +1 -0
  82. package/dist/chunks/backgroundHousekeeping-hDDE8mJC.js +17 -0
  83. package/dist/chunks/banner-hD6wZygx.js +2 -0
  84. package/dist/chunks/base64-js-0wLHn8zB.js +1 -0
  85. package/dist/chunks/bedrockClient-DxE_mHFI.js +15 -0
  86. package/dist/chunks/bg-BzG63WOm.js +1 -0
  87. package/dist/chunks/bg-DQ0Q3Qv-.js +9 -0
  88. package/dist/chunks/branch-CeQ9IyZk.js +3 -0
  89. package/dist/chunks/break-cache-Bd0clV2N.js +8 -0
  90. package/dist/chunks/bridge-yerAiaK2.js +2 -0
  91. package/dist/chunks/bridgeConfig-CCtXe8ak.js +1 -0
  92. package/dist/chunks/bridgeConfig-D5dB38xD.js +1 -0
  93. package/dist/chunks/bridgeEnabled--F-6TUi4.js +1 -0
  94. package/dist/chunks/bridgeEnabled-DKX8-T_H.js +1 -0
  95. package/dist/chunks/bridgeMain--R1HFbOv.js +68 -0
  96. package/dist/chunks/bridgeMain-d06JByZn.js +1 -0
  97. package/dist/chunks/bridgeMessaging-CqbLTDcx.js +1 -0
  98. package/dist/chunks/bridgePointer-W_jdQ8zf.js +1 -0
  99. package/dist/chunks/browser-Bd7GeBH1.js +1 -0
  100. package/dist/chunks/btw-CVGRmL9a.js +1 -0
  101. package/dist/chunks/bundledMode--fG1S62b.js +1 -0
  102. package/dist/chunks/caches-BtmAri4e.js +3 -0
  103. package/dist/chunks/caches-BuTIAOtY.js +1 -0
  104. package/dist/chunks/capacityWake-CV_x9H8j.js +1 -0
  105. package/dist/chunks/ccrClient-HqMi5Kfu.js +1 -0
  106. package/dist/chunks/checksum-DgbnMdM-.js +1 -0
  107. package/dist/chunks/classPrivateFieldSet2-D4U5K-I3.js +1 -0
  108. package/dist/chunks/classPrivateMethodInitSpec-BXQD0Vh4.js +1 -0
  109. package/dist/chunks/claudeDesktop-aUMx06RK.js +1 -0
  110. package/dist/chunks/clear-C6nRzIQE.js +1 -0
  111. package/dist/chunks/cliLaunch-2AUoMnqx.js +1 -0
  112. package/dist/chunks/client-BeET1hnC.js +1 -0
  113. package/dist/chunks/client-DchQnIJD.js +36 -0
  114. package/dist/chunks/client-DvAL7lY8.js +8 -0
  115. package/dist/chunks/color-DXI_4ibU.js +1 -0
  116. package/dist/chunks/color-convert-p91EwGT7.js +1 -0
  117. package/dist/chunks/commands-VjcG4qFq.js +1 -0
  118. package/dist/chunks/commitAttribution-Cm40fdNU.js +2 -0
  119. package/dist/chunks/commitAttribution-Lb3qUlAR.js +1 -0
  120. package/dist/chunks/compact-DPTVpJ4D.js +2 -0
  121. package/dist/chunks/completionCache-BQaLkB4d.js +4 -0
  122. package/dist/chunks/completionCache-CW8lKIgy.js +1 -0
  123. package/dist/chunks/config-0cRberzR.js +1 -0
  124. package/dist/chunks/config-BSXLgwpD.js +1 -0
  125. package/dist/chunks/config-BrxKpHpR.js +1 -0
  126. package/dist/chunks/config-C7YHKCPV.js +3 -0
  127. package/dist/chunks/config-CLmFk-5V.js +1 -0
  128. package/dist/chunks/connectHeadless-CqRoEtrg.js +1 -0
  129. package/dist/chunks/context-C_cKrBUn.js +1 -0
  130. package/dist/chunks/context-noninteractive-DnH6Q9Lu.js +54 -0
  131. package/dist/chunks/context-noninteractive-rUZ3ydmJ.js +1 -0
  132. package/dist/chunks/controlMessageCompat-IFu4Gc1y.js +1 -0
  133. package/dist/chunks/conversation-GJxfkr6M.js +1 -0
  134. package/dist/chunks/conversation-oK3aFzqO.js +1 -0
  135. package/dist/chunks/createSSHSession--bWmmIk9.js +6 -0
  136. package/dist/chunks/createSession-DIr4sUp6.js +1 -0
  137. package/dist/chunks/createSession-DM4acqaC.js +1 -0
  138. package/dist/chunks/cron-3LntnnhJ.js +1 -0
  139. package/dist/chunks/crossProjectResume-DKrtjTpm.js +40 -0
  140. package/dist/chunks/cwd-BuJhkTrc.js +1 -0
  141. package/dist/chunks/cwd-D-tY2NKc.js +1 -0
  142. package/dist/chunks/daemon-B9lBPdBJ.js +2 -0
  143. package/dist/chunks/dangerousBackend-DwcP0P08.js +1 -0
  144. package/dist/chunks/datadog-ByS7LGGa.js +1 -0
  145. package/dist/chunks/datadog-DNCsyfSO.js +1 -0
  146. package/dist/chunks/debug-DzZUT2Wv.js +1 -0
  147. package/dist/chunks/debug-IKW-jE7K.js +39 -0
  148. package/dist/chunks/debugUtils-D2981c0Z.js +1 -0
  149. package/dist/chunks/defineProperty-C-QyHrDq.js +1 -0
  150. package/dist/chunks/desktop-B5cvrcOQ.js +1 -0
  151. package/dist/chunks/detached-rfIUyc-B.js +5 -0
  152. package/dist/chunks/detect-libc-CxbBtWJu.js +1 -0
  153. package/dist/chunks/detectRepository-6nw-Aw3v.js +1 -0
  154. package/dist/chunks/detectRepository-ReZ0Fz8Z.js +1 -0
  155. package/dist/chunks/diff-cXAp9cNN.js +1 -0
  156. package/dist/chunks/directoryCompletion-DBM2o5kx.js +1 -0
  157. package/dist/chunks/dist-CXlEpGqr.js +20 -0
  158. package/dist/chunks/dist-DESLAofA.js +1 -0
  159. package/dist/chunks/dist-DIee4wq1.js +29 -0
  160. package/dist/chunks/dist-Dopnn8wS.js +5 -0
  161. package/dist/chunks/dist-es-5t7v8oaj.js +1 -0
  162. package/dist/chunks/dist-es-BF6bR-Ik.js +2 -0
  163. package/dist/chunks/dist-es-BIjDeceU.js +1 -0
  164. package/dist/chunks/dist-es-BOPBJQo3.js +1 -0
  165. package/dist/chunks/dist-es-Bfr4TzQe.js +3 -0
  166. package/dist/chunks/dist-es-Byxccz_-.js +1 -0
  167. package/dist/chunks/dist-es-C-OjW2Ao.js +1 -0
  168. package/dist/chunks/dist-es-C3reqy7X.js +1 -0
  169. package/dist/chunks/dist-es-C7vygWzp.js +1 -0
  170. package/dist/chunks/dist-es-CEk66gUu.js +1 -0
  171. package/dist/chunks/dist-es-CIULjvtA2.js +1 -0
  172. package/dist/chunks/dist-es-CMtO44xC.js +1 -0
  173. package/dist/chunks/dist-es-CQMt6zRM.js +1 -0
  174. package/dist/chunks/dist-es-CYPVg66r.js +9 -0
  175. package/dist/chunks/dist-es-Cd_AeqMK.js +6 -0
  176. package/dist/chunks/dist-es-Cgsa8pb82.js +1 -0
  177. package/dist/chunks/dist-es-Cwru7c2B2.js +1 -0
  178. package/dist/chunks/dist-es-D1Y8zSMI.js +1 -0
  179. package/dist/chunks/dist-es-D1wHe_zh.js +1 -0
  180. package/dist/chunks/dist-es-DKFm0FJ7.js +1 -0
  181. package/dist/chunks/dist-es-DKIwwJME.js +1 -0
  182. package/dist/chunks/dist-es-DNFTCbrP.js +1 -0
  183. package/dist/chunks/dist-es-DXIR5NLi2.js +1 -0
  184. package/dist/chunks/dist-es-DelBIxNM.js +1 -0
  185. package/dist/chunks/dist-es-DmdZmEJ-.js +1 -0
  186. package/dist/chunks/dist-es-Gt_DpXlP.js +1 -0
  187. package/dist/chunks/dist-es-gUzZ_7Vf.js +1 -0
  188. package/dist/chunks/dist-es-kj-F5A132.js +1 -0
  189. package/dist/chunks/dist-es-yHGBqhBe.js +1 -0
  190. package/dist/chunks/doctor-CTMHXZvQ.js +1 -0
  191. package/dist/chunks/earlyInput-BTC_Wucv.js +2 -0
  192. package/dist/chunks/earlyInput-xcoTbKQn.js +1 -0
  193. package/dist/chunks/effort-Br8KKHdx.js +9 -0
  194. package/dist/chunks/entry-4lIRMrLI.js +14 -0
  195. package/dist/chunks/envLessBridgeConfig-CGuIxFzJ.js +1 -0
  196. package/dist/chunks/envLessBridgeConfig-D_Jg4fJy.js +1 -0
  197. package/dist/chunks/envUtils-DSxRz_kt.js +1 -0
  198. package/dist/chunks/esm-BYnFh4pG.js +1 -0
  199. package/dist/chunks/esm-Bx6rTxIs.js +1 -0
  200. package/dist/chunks/esm-C367Cyo-.js +1 -0
  201. package/dist/chunks/esm-C8Zkk1Ux.js +1 -0
  202. package/dist/chunks/esm-CGx9qY3q.js +56 -0
  203. package/dist/chunks/esm-CXM9jqO_.js +1 -0
  204. package/dist/chunks/esm-CXczu_-W.js +1 -0
  205. package/dist/chunks/esm-CXt5K8Xt.js +1 -0
  206. package/dist/chunks/esm-Cb-L4oAk.js +1 -0
  207. package/dist/chunks/esm-D6ZZCdtk.js +1 -0
  208. package/dist/chunks/esm-DhRjocaU.js +1 -0
  209. package/dist/chunks/esm-DklLYEuz.js +1 -0
  210. package/dist/chunks/esm-IYgGg4wR.js +1 -0
  211. package/dist/chunks/esm-lWlUmoUA.js +1 -0
  212. package/dist/chunks/esm-lyfry1WB.js +10 -0
  213. package/dist/chunks/esm-wGnzjq4Z.js +1 -0
  214. package/dist/chunks/event-streams-C0Zy0Uqv.js +1 -0
  215. package/dist/chunks/event-streams-DoqJmjFN.js +1 -0
  216. package/dist/chunks/eventLoopStallDetector-Cg_RXU1q.js +1 -0
  217. package/dist/chunks/execAsync-Bv2yxuGe.js +1 -0
  218. package/dist/chunks/execFileNoThrow-COKYqVQj.js +34 -0
  219. package/dist/chunks/execSyncWrapper-DZJ3tNWF.js +1 -0
  220. package/dist/chunks/exit-BOhGfSlm.js +2 -0
  221. package/dist/chunks/exit-Z9oWrqE4.js +1 -0
  222. package/dist/chunks/extra-usage-BS4aVOt5.js +1 -0
  223. package/dist/chunks/extra-usage-DtAIhW74.js +1 -0
  224. package/dist/chunks/extra-usage-core-CdL1ltqq.js +1 -0
  225. package/dist/chunks/extra-usage-noninteractive-DxxRI0Yx.js +1 -0
  226. package/dist/chunks/extraUsage-BYZdi44Y.js +1 -0
  227. package/dist/chunks/extractMemories-C4f9JWuI.js +1 -0
  228. package/dist/chunks/fast-B0OB4x7K.js +1 -0
  229. package/dist/chunks/fast-DKqiojzf.js +1 -0
  230. package/dist/chunks/featureCheck-CrJeuheQ.js +1 -0
  231. package/dist/chunks/featureCheck-HslM03dr.js +1 -0
  232. package/dist/chunks/feedback-yB19xph5.js +1 -0
  233. package/dist/chunks/figures-5ThXQEtq.js +1 -0
  234. package/dist/chunks/file-D1cN3LMK.js +12 -0
  235. package/dist/chunks/fileStateCache-DDW5toIs.js +1 -0
  236. package/dist/chunks/files-DAzGtmzz.js +2 -0
  237. package/dist/chunks/firstPartyEventLogger-CdUpe6Lh.js +1 -0
  238. package/dist/chunks/firstPartyEventLogger-hU-LPkje.js +5 -0
  239. package/dist/chunks/flushGate-ZFr8yv7F.js +1 -0
  240. package/dist/chunks/foundry-sdk-BdeF2aBu.js +1 -0
  241. package/dist/chunks/fpsMetrics-Cf_hdtiJ.js +1 -0
  242. package/dist/chunks/from-CgDRRLiX.js +4 -0
  243. package/dist/chunks/gemini-DqAv8_GY.js +1 -0
  244. package/dist/chunks/generateRecap-lO2PDlx8.js +1 -0
  245. package/dist/chunks/generateSessionName-48veu5dv.js +1 -0
  246. package/dist/chunks/genericProcessUtils-F1Qcb1sO.js +23 -0
  247. package/dist/chunks/getMachineId-bsd-Cut1kHoA.js +1 -0
  248. package/dist/chunks/getMachineId-darwin-CsRhaP3y.js +2 -0
  249. package/dist/chunks/getMachineId-linux-Bd7UBNRQ.js +1 -0
  250. package/dist/chunks/getMachineId-unsupported-vFGP8E_8.js +1 -0
  251. package/dist/chunks/getMachineId-win-DamF2CH_.js +1 -0
  252. package/dist/chunks/git-BE_FiJZp.js +1 -0
  253. package/dist/chunks/git-tyaWOgRL.js +6 -0
  254. package/dist/chunks/githubRepoPathMapping-BlR0BphY.js +1 -0
  255. package/dist/chunks/goal-Bn8Kz2Dp.js +3 -0
  256. package/dist/chunks/graceful-fs-DDVg0cja.js +2 -0
  257. package/dist/chunks/grok-DhnO_KDC.js +1 -0
  258. package/dist/chunks/grove-DotW04-v.js +7 -0
  259. package/dist/chunks/hash-Tu-My5Vp.js +1 -0
  260. package/dist/chunks/heapdump-DkZSKNbp.js +5 -0
  261. package/dist/chunks/help-DU_BcZtU.js +1 -0
  262. package/dist/chunks/hooks-BTMWE5Qx.js +79 -0
  263. package/dist/chunks/hooks-DONAb_nq.js +1 -0
  264. package/dist/chunks/hostGuard-Dh296c6q.js +1 -0
  265. package/dist/chunks/inboundAttachments-BcEgi49j.js +1 -0
  266. package/dist/chunks/inboundAttachments-DVs3_m48.js +1 -0
  267. package/dist/chunks/index.min-D75yiGLN.js +1 -0
  268. package/dist/chunks/initReplBridge-D0Xec8S-.js +1 -0
  269. package/dist/chunks/install-BkfXeXpv.js +1 -0
  270. package/dist/chunks/instinctParser-Dt-lqnDe.js +1 -0
  271. package/dist/chunks/instrumentation-H0XRS1yG.js +21 -0
  272. package/dist/chunks/intl-cKc-V6Mq.js +1 -0
  273. package/dist/chunks/isObject-C6qM3WEW.js +1 -0
  274. package/dist/chunks/isSymbol-BO6cdPI7.js +1 -0
  275. package/dist/chunks/job-DKtLkF8V.js +2 -0
  276. package/dist/chunks/json-bigint-bonnP-Hz.js +8 -0
  277. package/dist/chunks/jsx-runtime-Bb4Xn-E0.js +1 -0
  278. package/dist/chunks/jws-BscXOT9I.js +3 -0
  279. package/dist/chunks/jwtUtils-C-ojmb8W.js +1 -0
  280. package/dist/chunks/keybindings-ez51eHHp.js +2 -0
  281. package/dist/chunks/language-BuRSO2sR.js +1 -0
  282. package/dist/chunks/language-Da4KNbjm.js +1 -0
  283. package/dist/chunks/launchAgentsPlatform-BQyPdrHp.js +1 -0
  284. package/dist/chunks/launchCommand-1qkTCKpf.js +1 -0
  285. package/dist/chunks/launchLocalMemory-CWHAj7CX.js +3 -0
  286. package/dist/chunks/launchLocalVault-D8iJdtsP.js +3 -0
  287. package/dist/chunks/launchMemoryStores-W7jWG2uH.js +1 -0
  288. package/dist/chunks/launchOnboarding-q__LaLy1.js +8 -0
  289. package/dist/chunks/launchSchedule-BWi9F5vh.js +1 -0
  290. package/dist/chunks/launchSkillStore-4wd4MQBc.js +1 -0
  291. package/dist/chunks/launchTeleport-BlCf2QM_.js +3 -0
  292. package/dist/chunks/launchVault-C7u7LZV7.js +1 -0
  293. package/dist/chunks/lazySchema-uxlVVNM1.js +1 -0
  294. package/dist/chunks/lib-BSzUGQb_.js +2 -0
  295. package/dist/chunks/lib-BlVGipXx.js +14 -0
  296. package/dist/chunks/lib-rQZENxQg.js +8 -0
  297. package/dist/chunks/loadAgentsDir-Dgd-fzNt.js +1 -0
  298. package/dist/chunks/loadAgentsDir-nzr38hai.js +3990 -0
  299. package/dist/chunks/loadPluginHooks-z1-zvBLw.js +1 -0
  300. package/dist/chunks/loadSso-DSxfVpgX.js +1 -0
  301. package/dist/chunks/localSearch-B-L_ldos.js +1 -0
  302. package/dist/chunks/localSearch-D-FprOMr.js +1 -0
  303. package/dist/chunks/lockfile-D5-j7HOZ.js +1 -0
  304. package/dist/chunks/log-B3eB4EFv.js +1 -0
  305. package/dist/chunks/logoV2Utils-RQ160dI2.js +1 -0
  306. package/dist/chunks/magicDocs-BqZ0GewA.js +57 -0
  307. package/dist/chunks/main-DeFMhaFE.js +31 -0
  308. package/dist/chunks/main-y7LJ5qUc.js +1243 -0
  309. package/dist/chunks/mappers-CWykjGfP.js +1 -0
  310. package/dist/chunks/mcp-CSFPAfaW.js +2 -0
  311. package/dist/chunks/mcp-DBwT4pa9.js +6 -0
  312. package/dist/chunks/mcp-DvZTaHZE.js +1 -0
  313. package/dist/chunks/memoize-BK3gG5ob.js +1 -0
  314. package/dist/chunks/memoize-BO31Ws9Q.js +1 -0
  315. package/dist/chunks/memory-DcpPpYN0.js +1 -0
  316. package/dist/chunks/metadata-BRLJvh61.js +1 -0
  317. package/dist/chunks/modalContext-DFjKLCB6.js +1 -0
  318. package/dist/chunks/mode-BkViT_0o.js +2 -0
  319. package/dist/chunks/model--z4Di9QO.js +1 -0
  320. package/dist/chunks/model-CZktWw6o.js +1 -0
  321. package/dist/chunks/model-DfFA3qMO.js +1 -0
  322. package/dist/chunks/multipart-parser-DDLYsngd.js +2 -0
  323. package/dist/chunks/nativeInstaller-GcIk7G2Y.js +1 -0
  324. package/dist/chunks/oauth-BqJqV-2M.js +1 -0
  325. package/dist/chunks/oauth-C8X_p8Gc.js +1 -0
  326. package/dist/chunks/observationStore-DzCdXq8U.js +4 -0
  327. package/dist/chunks/onChangeAppState-DwGVi-BC.js +1 -0
  328. package/dist/chunks/open-BtQHzzL9.js +1 -0
  329. package/dist/chunks/openai-B2wxZDQx.js +10 -0
  330. package/dist/chunks/openaiShared-G2-w4gJt.js +1 -0
  331. package/dist/chunks/output-style-BM3qAHLA.js +1 -0
  332. package/dist/chunks/overageCreditGrant-CjK49axw.js +1 -0
  333. package/dist/chunks/p-map-B1EeBuI8.js +1 -0
  334. package/dist/chunks/p-map-HKDr3iDo.js +1 -0
  335. package/dist/chunks/package-BC0bllK8.js +1 -0
  336. package/dist/chunks/panel-B-nrcHpm.js +1 -0
  337. package/dist/chunks/panel-R4ue6pSW.js +1 -0
  338. package/dist/chunks/panelCall-I_fbgub5.js +1 -0
  339. package/dist/chunks/parseConnectUrl-BiyKR5-x.js +1 -0
  340. package/dist/chunks/parser-BlM_Fk4J.js +1 -0
  341. package/dist/chunks/parser-CQrasoUB.js +1 -0
  342. package/dist/chunks/partition-CxRF7T-f.js +1 -0
  343. package/dist/chunks/passes-U_h-hNu-.js +1 -0
  344. package/dist/chunks/path-BCSE0S-c.js +1 -0
  345. package/dist/chunks/permissions-B8epy16o.js +3 -0
  346. package/dist/chunks/permissions-CeYKbtSC.js +1 -0
  347. package/dist/chunks/permissions-Cn_6f8CB.js +1 -0
  348. package/dist/chunks/pidLock-CBJDnBG_.js +3 -0
  349. package/dist/chunks/pipeTransport-D3Qx9v1V.js +1 -0
  350. package/dist/chunks/plan-BAhStVci.js +1 -0
  351. package/dist/chunks/platform-EtecGacO.js +2 -0
  352. package/dist/chunks/plist-Bzo2VMe9.js +6 -0
  353. package/dist/chunks/plugin-D9huNnv6.js +1 -0
  354. package/dist/chunks/pluginAutoupdate-BfmyxR5g.js +1 -0
  355. package/dist/chunks/pluginBlocklist-03sZaZa6.js +1 -0
  356. package/dist/chunks/pluginCliCommands-P2Ndi1r1.js +1 -0
  357. package/dist/chunks/pluginFlagging-BVy7Xv_0.js +1 -0
  358. package/dist/chunks/pluginOperations-Cz37qcjF.js +2 -0
  359. package/dist/chunks/pluginStartupCheck-BqUwHcMD.js +1 -0
  360. package/dist/chunks/pluginStartupCheck-w24D-wwk.js +1 -0
  361. package/dist/chunks/plugins-B0hiIN4q.js +4 -0
  362. package/dist/chunks/policyLimits-Dem-XJ_h.js +1 -0
  363. package/dist/chunks/pollConfig-C2Ac8WMU.js +1 -0
  364. package/dist/chunks/poller-CpLBoB-N.js +1 -0
  365. package/dist/chunks/poor-CfbMKZNJ.js +1 -0
  366. package/dist/chunks/poorMode-Bsw2V-V_.js +1 -0
  367. package/dist/chunks/poorMode-jvImnkty.js +1 -0
  368. package/dist/chunks/postCommitAttribution-DoSP9wZD.js +1 -0
  369. package/dist/chunks/print-ozjC0Mhg.js +23 -0
  370. package/dist/chunks/privacy-settings-DeGoBRrZ.js +1 -0
  371. package/dist/chunks/process-CNfq37LF.js +1 -0
  372. package/dist/chunks/process-gEbdy6uY.js +1 -0
  373. package/dist/chunks/processBashCommand-loWZ8MSE.js +1 -0
  374. package/dist/chunks/processSlashCommand-BdouajZb.js +5 -0
  375. package/dist/chunks/projectContext-BaDZBAoK.js +1 -0
  376. package/dist/chunks/projectContext-D9MDwJUF.js +1 -0
  377. package/dist/chunks/prompt-Bef63FhB.js +132 -0
  378. package/dist/chunks/prompt-C7wd1H_i.js +1 -0
  379. package/dist/chunks/prompt-DIoNqZvO.js +1 -0
  380. package/dist/chunks/promptEditor-foiayhdY.js +4 -0
  381. package/dist/chunks/protocolHandler-BsiB1oW_.js +13 -0
  382. package/dist/chunks/protocols-CCsohXid.js +18 -0
  383. package/dist/chunks/protocols-CnYQjBlj.js +2 -0
  384. package/dist/chunks/proxy-Cn2YwITp.js +99 -0
  385. package/dist/chunks/rate-limit-options-DTJPDcTr.js +1 -0
  386. package/dist/chunks/rcDebugLog-BUuD-X1D.js +11 -0
  387. package/dist/chunks/reconciler-DqXTmV3J.js +4 -0
  388. package/dist/chunks/referral-DP_GshTS.js +1 -0
  389. package/dist/chunks/refresh-CNzXPAFw.js +1 -0
  390. package/dist/chunks/registerProtocol-CjxlFsKw.js +36 -0
  391. package/dist/chunks/release-notes-BxgK8zWO.js +4 -0
  392. package/dist/chunks/releaseNotes-CbSktIJW.js +2 -0
  393. package/dist/chunks/reload-plugins-CDu6yU5-.js +1 -0
  394. package/dist/chunks/remote-env-B4HnhISc.js +1 -0
  395. package/dist/chunks/remoteBridgeCore-D-wG5jau.js +1 -0
  396. package/dist/chunks/remoteManagedSettings-B7gt0VAX.js +1 -0
  397. package/dist/chunks/rename-DlbMb24l.js +1 -0
  398. package/dist/chunks/renderOptions-5kWQpVr2.js +1 -0
  399. package/dist/chunks/resume-BB5iBogS.js +2 -0
  400. package/dist/chunks/rewind-D12hCfZD.js +1 -0
  401. package/dist/chunks/ripgrep-BQgJ02F9.js +1 -0
  402. package/dist/chunks/ripgrep-BvDwiKJ3.js +5 -0
  403. package/dist/chunks/rollback-BPWRKlIZ.js +11 -0
  404. package/dist/chunks/rolldown-runtime-DaDcL9Zw.js +1 -0
  405. package/dist/chunks/runtimeObserver-BNH2WGE3.js +1 -0
  406. package/dist/chunks/runtimeObserver-Ci-5gvYg.js +10 -0
  407. package/dist/chunks/sandbox-adapter-Coe1GDAE.js +1 -0
  408. package/dist/chunks/sandbox-toggle-B2Yk4y2V.js +1 -0
  409. package/dist/chunks/sanitization-DV-94a9Z.js +1 -0
  410. package/dist/chunks/satisfies-DQJHNtpQ.js +1 -0
  411. package/dist/chunks/sdkHeapDumpMonitor-WdXUV7DV.js +1 -0
  412. package/dist/chunks/searchExtraTools-BnWZ9roi.js +1 -0
  413. package/dist/chunks/semver-BMRJYn3q.js +1 -0
  414. package/dist/chunks/semver-DQo45qGo.js +1 -0
  415. package/dist/chunks/serde-f76bObzR.js +4 -0
  416. package/dist/chunks/server-LdbAb0sV.js +1 -0
  417. package/dist/chunks/serverBanner-BdExKFHT.js +1 -0
  418. package/dist/chunks/serverLog-BFmvyJ93.js +1 -0
  419. package/dist/chunks/session-Bmx7L3Mt.js +2 -0
  420. package/dist/chunks/sessionDataUploader-CaCjwsA2.js +1 -0
  421. package/dist/chunks/sessionDiscovery-DcEAr5vJ.js +1 -0
  422. package/dist/chunks/sessionFileAccessHooks-BhdOmW9o.js +1 -0
  423. package/dist/chunks/sessionManager-CPa049BO.js +1 -0
  424. package/dist/chunks/sessionMemory-Bsg2unYX.js +1 -0
  425. package/dist/chunks/sessionMemory-CIbCojm-.js +1 -0
  426. package/dist/chunks/sessionMemoryUtils-Cjb57wtC.js +1 -0
  427. package/dist/chunks/sessionObserver-CRU1qWnP.js +1 -0
  428. package/dist/chunks/sessionObserver-DQwHsDrM.js +20 -0
  429. package/dist/chunks/sessionStorage-BxDN8qRc.js +1 -0
  430. package/dist/chunks/sessionStoragePortable-Cx6JQ5Ye.js +3 -0
  431. package/dist/chunks/sessionTitle-B8jcexkQ.js +14 -0
  432. package/dist/chunks/sessionTracing-BuLsL6qA.js +11 -0
  433. package/dist/chunks/settings-5PQdphqC.js +19 -0
  434. package/dist/chunks/settingsSync-BDeuErb5.js +1 -0
  435. package/dist/chunks/setup-BKEnSLR9.js +3 -0
  436. package/dist/chunks/shadowedRuleDetection-7Z8ezTKF.js +1 -0
  437. package/dist/chunks/shellQuote-fB02N16J.js +4 -0
  438. package/dist/chunks/sideQuestion-CYdNATPW.js +20 -0
  439. package/dist/chunks/signin-CPaEtsnK.js +1 -0
  440. package/dist/chunks/sink-DjKoYMsA.js +1 -0
  441. package/dist/chunks/sink-iYxWapbU.js +1 -0
  442. package/dist/chunks/sinks-GryGVRT8.js +2 -0
  443. package/dist/chunks/sinks-jfaIjsRJ.js +1 -0
  444. package/dist/chunks/skill-learning-E8tQed-Q.js +5 -0
  445. package/dist/chunks/skillChangeDetector-A8SAuyo9.js +1 -0
  446. package/dist/chunks/skillGapStore-B5rl12bV.js +1 -0
  447. package/dist/chunks/skillGapStore-CjJrxxjk.js +5 -0
  448. package/dist/chunks/skillGenerator-BDR_z3-X.js +8 -0
  449. package/dist/chunks/skillLearning-BQtfFE0g.js +1 -0
  450. package/dist/chunks/skillLearning-C8ihdryM.js +1 -0
  451. package/dist/chunks/skillPanel-yR8Oi-mO.js +28 -0
  452. package/dist/chunks/skillSearchPanel-DUQQUCUS.js +21 -0
  453. package/dist/chunks/skills-NAZQ3j-t.js +1 -0
  454. package/dist/chunks/slashCommandParsing-RQb_7Xzt.js +1 -0
  455. package/dist/chunks/src-CDCSSo0U2.js +53 -0
  456. package/dist/chunks/src-CHw1lvBc.js +3 -0
  457. package/dist/chunks/src-CST_jFnT.js +1 -0
  458. package/dist/chunks/src-CgZmCiiH.js +2 -0
  459. package/dist/chunks/src-CiJCsqUl.js +9 -0
  460. package/dist/chunks/src-D06Xyj4g.js +2 -0
  461. package/dist/chunks/src-DCUgdrYl.js +5 -0
  462. package/dist/chunks/src-DLz3FZm1.js +1 -0
  463. package/dist/chunks/src-DPUAq5Ty.js +1 -0
  464. package/dist/chunks/src-DQOX_xI1.js +1 -0
  465. package/dist/chunks/src-Dt5IJd3C.js +1 -0
  466. package/dist/chunks/src-Dvp6-vB7.js +19 -0
  467. package/dist/chunks/src-PM8NIIu_.js +1 -0
  468. package/dist/chunks/src-l6_O0K-a.js +1 -0
  469. package/dist/chunks/src-xRRBgNzF.js +25 -0
  470. package/dist/chunks/sso-oidc-DFJ7SBvI.js +1 -0
  471. package/dist/chunks/startupProfiler-B0m6crkd.js +1 -0
  472. package/dist/chunks/startupProfiler-DxRQteII.js +3 -0
  473. package/dist/chunks/state-4KQ3kaqz.js +1 -0
  474. package/dist/chunks/state-53JDbNQM.js +1 -0
  475. package/dist/chunks/state-Cn_m2NOf.js +1 -0
  476. package/dist/chunks/staticRender-BIxpgNUq.js +1 -0
  477. package/dist/chunks/stats-h4yu84Q-.js +1 -0
  478. package/dist/chunks/status-BbdeubJG.js +1 -0
  479. package/dist/chunks/status-is_Bg_IB.js +2 -0
  480. package/dist/chunks/statusNoticeHelpers-CQ7CUugR.js +1 -0
  481. package/dist/chunks/stdio-4S7b8Uhx.js +1 -0
  482. package/dist/chunks/stdio-W_Kokrkh.js +3 -0
  483. package/dist/chunks/stickers-qJoNhPk4.js +1 -0
  484. package/dist/chunks/store-Z8rTjDHe.js +1 -0
  485. package/dist/chunks/stringUtils-CvXbHQRH.js +4 -0
  486. package/dist/chunks/sts-C2Gf2WYN.js +1 -0
  487. package/dist/chunks/subprocessEnv-BSQSomcK.js +1 -0
  488. package/dist/chunks/subprocessEnv-vrwzMgKn.js +1 -0
  489. package/dist/chunks/supports-color-uJ1LqA-P.js +1 -0
  490. package/dist/chunks/systemPromptSections-CgpggIYX.js +1 -0
  491. package/dist/chunks/systemPromptSections-IePG5K8r.js +1 -0
  492. package/dist/chunks/systemTheme-Ceakddth.js +1 -0
  493. package/dist/chunks/tag-i3HZ4lhj.js +11 -0
  494. package/dist/chunks/tasks-HzsYNTZ1.js +1 -0
  495. package/dist/chunks/teleport-hN3cAbYC.js +1 -0
  496. package/dist/chunks/templateJobs-CIv_ysje.js +12 -0
  497. package/dist/chunks/terminalSetup-C0PF87iu.js +33 -0
  498. package/dist/chunks/terminalSetup-CxniwSF-.js +1 -0
  499. package/dist/chunks/theme-BKIHX_Dx.js +1 -0
  500. package/dist/chunks/thinkback-BA4cMz4D.js +1 -0
  501. package/dist/chunks/thinkback-mT-8FIT-.js +1 -0
  502. package/dist/chunks/thinkback-play-Cfk49mvF.js +1 -0
  503. package/dist/chunks/tmux-CbsW-VDJ.js +1 -0
  504. package/dist/chunks/toolEventObserver-8FQtxeVv.js +1 -0
  505. package/dist/chunks/toolEventObserver-B1xvyKdE.js +1 -0
  506. package/dist/chunks/toolPool-CHVDZqh7.js +1 -0
  507. package/dist/chunks/trustedDevice-BYCh1ff7.js +1 -0
  508. package/dist/chunks/trustedDevice-DnIWErCt.js +1 -0
  509. package/dist/chunks/tui-fTa_pzdA.js +6 -0
  510. package/dist/chunks/types-BUyOCzUt.js +1 -0
  511. package/dist/chunks/types-Czs-_G1S.js +3 -0
  512. package/dist/chunks/types-a7X-tJpJ.js +17 -0
  513. package/dist/chunks/udsClient-Cg9bBD0p.js +1 -0
  514. package/dist/chunks/ultrareviewCommand-DCFRZsKp.js +3 -0
  515. package/dist/chunks/undercover-B-kKUWtK.js +1 -0
  516. package/dist/chunks/undercover-CsLPQb-a.js +31 -0
  517. package/dist/chunks/up-dO5BcPaq.js +12 -0
  518. package/dist/chunks/updateCCB-CfUnkOLT.js +11 -0
  519. package/dist/chunks/upgrade-CngUwvY4.js +1 -0
  520. package/dist/chunks/upgrade-kpttjebY.js +1 -0
  521. package/dist/chunks/upload-DDhQqV8n.js +1 -0
  522. package/dist/chunks/upstreamproxy-CvcjNY7J.js +11 -0
  523. package/dist/chunks/usage-CJ5w0907.js +1 -0
  524. package/dist/chunks/usage-eZRwLa77.js +1 -0
  525. package/dist/chunks/useExitOnCtrlCDWithKeybindings-yAroCqu4.js +1 -0
  526. package/dist/chunks/useMainLoopModel-BNFW-g8E.js +1 -0
  527. package/dist/chunks/useManagePlugins-CTtPaQRP.js +1 -0
  528. package/dist/chunks/useMergedTools-CZJffsmf.js +1 -0
  529. package/dist/chunks/useSearchInput-C-CqUK6w.js +1 -0
  530. package/dist/chunks/useSettingsErrors-BWlJCgYF.js +1 -0
  531. package/dist/chunks/util-DJV0joAW.js +1 -0
  532. package/dist/chunks/v4-jw6qOKwQ.js +65 -0
  533. package/dist/chunks/validatePlugin-CRmpIGLV.js +1 -0
  534. package/dist/chunks/vertex-sdk-DjXcZ2J7.js +9 -0
  535. package/dist/chunks/vim-n8-UT5w-.js +1 -0
  536. package/dist/chunks/which-BBCjXfI2.js +1 -0
  537. package/dist/chunks/windowsPaths-D6T_3XaU.js +1 -0
  538. package/dist/chunks/windowsPaths-DUKTzBck.js +1 -0
  539. package/dist/chunks/workSecret-C_lv0dRh.js +1 -0
  540. package/dist/chunks/workerRegistry-BdHi7_sN.js +1 -0
  541. package/dist/chunks/worktree-YDeHMlHZ.js +1 -0
  542. package/dist/chunks/worktreeModeEnabled-BFOYTTTr.js +1 -0
  543. package/dist/chunks/worktreeModeEnabled-D68iEHpC.js +1 -0
  544. package/dist/chunks/wrapper-K8ZapJVu.js +6 -0
  545. package/dist/chunks/xdg-DcF9ejUM.js +1 -0
  546. package/dist/chunks/zod-CuNujUwx.js +1 -0
  547. package/dist/cli-bun.js +2 -0
  548. package/dist/cli-node.js +2 -0
  549. package/dist/cli.js +2 -0
  550. package/dist/vendor/ripgrep/x64-linux/rg +0 -0
  551. package/package.json +218 -0
  552. package/scripts/postinstall.cjs +389 -0
@@ -0,0 +1,18 @@
1
+ import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./defineProperty-C-QyHrDq.js";import{Q as r,_t as i,ct as a,q as o,t as s}from"./client-DvAL7lY8.js";import{A as c,C as l,D as u,G as d,H as f,O as p,P as m,T as h,_ as g,d as ee,h as te,i as _,p as ne,q as v,t as y,x as re,y as ie}from"./protocols-CnYQjBlj.js";import{A as ae,B as oe,F as se,G as ce,H as le,L as ue,M as de,O as fe,P as pe,g as b,h as x,n as me,p as he,r as S,u as C,z as w}from"./serde-f76bObzR.js";import{t as ge,z as _e}from"./config-BSXLgwpD.js";import{_ as T,i as ve,o as ye,s as be,t as xe}from"./dist-es-BF6bR-Ik.js";var E,Se=e((()=>{y(),E=e=>d.isInstance(e)?e.headers?.date??e.headers?.Date:void 0})),D,Ce=e((()=>{D=e=>new Date(Date.now()+e)})),we,Te=e((()=>{Ce(),we=(e,t)=>Math.abs(D(t).getTime()-e)>=3e5})),O,Ee=e((()=>{Te(),O=(e,t)=>{let n=Date.parse(e);return we(n,t)?n-Date.now():t}})),De=e((()=>{Se(),Ce(),Ee()})),k,A,j,M=e((()=>{y(),De(),k=(e,t)=>{if(!t)throw Error(`Property \`${e}\` is not resolved for AWS SDK SigV4Auth`);return t},A=async e=>{let t=k(`context`,e.context),n=k(`config`,e.config),r=t.endpointV2?.properties?.authSchemes?.[0];return{config:n,signer:await k(`signer`,n.signer)(r),signingRegion:e?.signingRegion,signingRegionSet:e?.signingRegionSet,signingName:e?.signingName}},j=class{async sign(e,t,n){if(!v.isInstance(e))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let r=await A(n),{config:i,signer:a}=r,{signingRegion:o,signingName:s}=r,c=n.context;if(c?.authSchemes?.length??!1){let[e,t]=c.authSchemes;e?.name===`sigv4a`&&t?.name===`sigv4`&&(o=t?.signingRegion??o,s=t?.signingName??s)}return n._preRequestSystemClockOffset=i.systemClockOffset,await a.sign(e,{signingDate:D(i.systemClockOffset),signingRegion:o,signingService:s})}errorHandler(e){return t=>{let n=t,r=n.ServerTime??E(n.$response);if(r){let t=k(`config`,e.config),i=e._preRequestSystemClockOffset,a=O(r,t.systemClockOffset);(a!==t.systemClockOffset||i!==void 0&&i!==a)&&n.$metadata&&(t.systemClockOffset=a,n.$metadata.clockSkewCorrected=!0)}throw t}}successHandler(e,t){let n=E(e);if(n){let e=k(`config`,t.config);e.systemClockOffset=O(n,e.systemClockOffset)}}}})),Oe,ke=e((()=>{y(),De(),M(),Oe=class extends j{async sign(e,t,n){if(!v.isInstance(e))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let{config:r,signer:i,signingRegion:a,signingRegionSet:o,signingName:s}=await A(n),c=(await r.sigv4aSigningRegionSet?.()??o??[a]).join(`,`);return n._preRequestSystemClockOffset=r.systemClockOffset,await i.sign(e,{signingDate:D(r.systemClockOffset),signingRegion:c,signingService:s})}}})),N,Ae=e((()=>{N=e=>typeof e==`string`&&e.length>0?e.split(`,`).map(e=>e.trim()):[]})),P,F=e((()=>{P=e=>`AWS_BEARER_TOKEN_${e.replace(/[\s-]/g,`_`).toUpperCase()}`})),je,Me,Ne,Pe=e((()=>{Ae(),F(),je=`AWS_AUTH_SCHEME_PREFERENCE`,Me=`auth_scheme_preference`,Ne={environmentVariableSelector:(e,t)=>{if(t?.signingName&&P(t.signingName)in e)return[`httpBearerAuth`];if(je in e)return N(e[je])},configFileSelector:e=>{if(Me in e)return N(e[Me])},default:[]}})),Fe,Ie,Le=e((()=>{xe(),ge(),Fe=e=>(e.sigv4aSigningRegionSet=T(e.sigv4aSigningRegionSet),e),Ie={environmentVariableSelector(e){if(e.AWS_SIGV4A_SIGNING_REGION_SET)return e.AWS_SIGV4A_SIGNING_REGION_SET.split(`,`).map(e=>e.trim());throw new _e(`AWS_SIGV4A_SIGNING_REGION_SET not set in env.`,{tryNextLink:!0})},configFileSelector(e){if(e.sigv4a_signing_region_set)return(e.sigv4a_signing_region_set??``).split(`,`).map(e=>e.trim());throw new _e(`sigv4a_signing_region_set not set in profile.`,{tryNextLink:!0})},default:void 0}}));function Re(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,e[t]===0);t--);}var ze,Be,Ve,He,Ue=e((()=>{S(),t(),ze=class{format(e){let t=[];for(let n of Object.keys(e)){let r=oe(n);t.push(Uint8Array.from([r.byteLength]),r,this.formatHeaderValue(e[n]))}let n=new Uint8Array(t.reduce((e,t)=>e+t.byteLength,0)),r=0;for(let e of t)n.set(e,r),r+=e.byteLength;return n}formatHeaderValue(e){switch(e.type){case`boolean`:return Uint8Array.from([+!e.value]);case`byte`:return Uint8Array.from([2,e.value]);case`short`:let t=new DataView(new ArrayBuffer(3));return t.setUint8(0,3),t.setInt16(1,e.value,!1),new Uint8Array(t.buffer);case`integer`:let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,e.value,!1),new Uint8Array(n.buffer);case`long`:let r=new Uint8Array(9);return r[0]=5,r.set(e.value.bytes,1),r;case`binary`:let i=new DataView(new ArrayBuffer(3+e.value.byteLength));i.setUint8(0,6),i.setUint16(1,e.value.byteLength,!1);let a=new Uint8Array(i.buffer);return a.set(e.value,3),a;case`string`:let o=oe(e.value),s=new DataView(new ArrayBuffer(3+o.byteLength));s.setUint8(0,7),s.setUint16(1,o.byteLength,!1);let c=new Uint8Array(s.buffer);return c.set(o,3),c;case`timestamp`:let l=new Uint8Array(9);return l[0]=8,l.set(He.fromNumber(e.value.valueOf()).bytes,1),l;case`uuid`:if(!Ve.test(e.value))throw Error(`Invalid UUID received: ${e.value}`);let u=new Uint8Array(17);return u[0]=9,u.set(he(e.value.replace(/\-/g,``)),1),u}}},(function(e){e[e.boolTrue=0]=`boolTrue`,e[e.boolFalse=1]=`boolFalse`,e[e.byte=2]=`byte`,e[e.short=3]=`short`,e[e.integer=4]=`integer`,e[e.long=5]=`long`,e[e.byteArray=6]=`byteArray`,e[e.string=7]=`string`,e[e.timestamp=8]=`timestamp`,e[e.uuid=9]=`uuid`})(Be||(Be={})),Ve=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/,He=class e{constructor(e){if(n(this,`bytes`,void 0),this.bytes=e,e.byteLength!==8)throw Error(`Int64 buffers must be exactly 8 bytes`)}static fromNumber(t){if(t>0x8000000000000000||t<-0x8000000000000000)throw Error(`${t} is too large (or, if negative, too small) to represent as an Int64`);let n=new Uint8Array(8);for(let e=7,r=Math.abs(Math.round(t));e>-1&&r>0;e--,r/=256)n[e]=r;return t<0&&Re(n),new e(n)}valueOf(){let e=this.bytes.slice(0),t=e[0]&128;return t&&Re(e),parseInt(x(e),16)*(t?-1:1)}toString(){return String(this.valueOf())}}})),We,Ge,Ke,qe,Je,Ye,I,L,R,Xe,Ze,Qe,$e,et,tt,nt,z,rt,it,B,V=e((()=>{We=`X-Amz-Algorithm`,Ge=`X-Amz-Credential`,Ke=`X-Amz-Date`,qe=`X-Amz-SignedHeaders`,Je=`X-Amz-Expires`,Ye=`X-Amz-Signature`,I=`X-Amz-Security-Token`,L=`authorization`,R=Ke.toLowerCase(),Xe=`date`,Ze=[L,R,Xe],Ye.toLowerCase(),Qe=`x-amz-content-sha256`,$e=I.toLowerCase(),et={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},tt=/^proxy-/,nt=/^sec-/,z=`AWS4-HMAC-SHA256`,rt=`AWS4-HMAC-SHA256-PAYLOAD`,it=`UNSIGNED-PAYLOAD`,B=`aws4_request`})),at,ot=e((()=>{y(),V(),at=({query:e={}})=>{let t=[],n={};for(let r of Object.keys(e)){if(r.toLowerCase()===`x-amz-signature`)continue;let i=_(r);t.push(i);let a=e[r];typeof a==`string`?n[i]=`${i}=${_(a)}`:Array.isArray(a)&&(n[i]=a.slice(0).reduce((e,t)=>e.concat([`${i}=${_(t)}`]),[]).sort().join(`&`))}return t.sort().map(e=>n[e]).filter(e=>e).join(`&`)}})),st,ct,lt=e((()=>{st=e=>ct(e).toISOString().replace(/\.\d{3}Z$/,`Z`),ct=e=>typeof e==`number`?new Date(e*1e3):typeof e==`string`?Number(e)?new Date(Number(e)*1e3):new Date(e):e})),ut,dt=e((()=>{o(),y(),S(),ot(),lt(),t(),ut=class{constructor({applyChecksum:e,credentials:t,region:r,service:i,sha256:a,uriEscapePath:o=!0}){n(this,`service`,void 0),n(this,`regionProvider`,void 0),n(this,`credentialProvider`,void 0),n(this,`sha256`,void 0),n(this,`uriEscapePath`,void 0),n(this,`applyChecksum`,void 0),this.service=i,this.sha256=a,this.uriEscapePath=o,this.applyChecksum=typeof e!=`boolean`||e,this.regionProvider=f(r),this.credentialProvider=f(t)}createCanonicalRequest(e,t,n){let r=Object.keys(t).sort();return`${e.method}
2
+ ${this.getCanonicalPath(e)}
3
+ ${at(e)}
4
+ ${r.map(e=>`${e}:${t[e]}`).join(`
5
+ `)}
6
+
7
+ ${r.join(`;`)}
8
+ ${n}`}async createStringToSign(e,t,n,r){let i=new this.sha256;return i.update(C(n)),`${r}
9
+ ${e}
10
+ ${t}
11
+ ${x(await i.digest())}`}getCanonicalPath({path:e}){if(this.uriEscapePath){let t=[];for(let n of e.split(`/`))n?.length!==0&&n!==`.`&&(n===`..`?t.pop():t.push(n));return _(`${e?.startsWith(`/`)?`/`:``}${t.join(`/`)}${t.length>0&&e?.endsWith(`/`)?`/`:``}`).replace(/%2F/g,`/`)}return e}validateResolvedCredentials(e){if(typeof e!=`object`||typeof e.accessKeyId!=`string`||typeof e.secretAccessKey!=`string`)throw Error(`Resolved credential object is not valid`)}formatDate(e){let t=st(e).replace(/[\-:]/g,``);return{longDate:t,shortDate:t.slice(0,8)}}getCanonicalHeaderList(e){return Object.keys(e).sort().join(`;`)}}})),H,U,W,ft,G,pt=e((()=>{S(),V(),H={},U=[],W=(e,t,n)=>`${e}/${t}/${n}/${B}`,ft=async(e,t,n,r,i)=>{let a=`${n}:${r}:${i}:${x(await G(e,t.secretAccessKey,t.accessKeyId))}:${t.sessionToken}`;if(a in H)return H[a];for(U.push(a);U.length>50;)delete H[U.shift()];let o=`AWS4${t.secretAccessKey}`;for(let t of[n,r,i,B])o=await G(e,o,t);return H[a]=o},G=(e,t,n)=>{let r=new e(t);return r.update(C(n)),r.digest()}})),K,mt=e((()=>{V(),K=({headers:e},t,n)=>{let r={};for(let i of Object.keys(e).sort()){if(e[i]==null)continue;let a=i.toLowerCase();(a in et||t?.has(a)||tt.test(a)||nt.test(a))&&(!n||n&&!n.has(a))||(r[a]=e[i].trim().replace(/\s+/g,` `))}return r}})),q,ht=e((()=>{S(),V(),q=async({headers:e,body:t},n)=>{for(let t of Object.keys(e))if(t.toLowerCase()===`x-amz-content-sha256`)return e[t];if(t==null)return`e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855`;if(typeof t==`string`||ArrayBuffer.isView(t)||ce(t)){let e=new n;return e.update(C(t)),x(await e.digest())}return it}})),gt,_t=e((()=>{gt=(e,t)=>{e=e.toLowerCase();for(let n of Object.keys(t))if(e===n.toLowerCase())return!0;return!1}})),vt,yt=e((()=>{y(),vt=(e,t={})=>{let{headers:n,query:r={}}=v.clone(e);for(let e of Object.keys(n)){let i=e.toLowerCase();(i.slice(0,6)===`x-amz-`&&!t.unhoistableHeaders?.has(i)||t.hoistableHeaders?.has(i))&&(r[e]=n[e],delete n[e])}return{...e,headers:n,query:r}}})),J,bt=e((()=>{y(),V(),J=e=>{e=v.clone(e);for(let t of Object.keys(e.headers))Ze.indexOf(t.toLowerCase())>-1&&delete e.headers[t];return e}})),Y,xt=e((()=>{S(),Ue(),dt(),V(),pt(),mt(),ht(),_t(),yt(),bt(),t(),Y=class extends ut{constructor({applyChecksum:e,credentials:t,region:r,service:i,sha256:a,uriEscapePath:o=!0}){super({applyChecksum:e,credentials:t,region:r,service:i,sha256:a,uriEscapePath:o}),n(this,`headerFormatter`,new ze)}async presign(e,t={}){let{signingDate:n=new Date,expiresIn:r=3600,unsignableHeaders:i,unhoistableHeaders:a,signableHeaders:o,hoistableHeaders:s,signingRegion:c,signingService:l}=t,u=await this.credentialProvider();this.validateResolvedCredentials(u);let d=c??await this.regionProvider(),{longDate:f,shortDate:p}=this.formatDate(n);if(r>604800)return Promise.reject(`Signature version 4 presigned URLs must have an expiration date less than one week in the future`);let m=W(p,d,l??this.service),h=vt(J(e),{unhoistableHeaders:a,hoistableHeaders:s});u.sessionToken&&(h.query[I]=u.sessionToken),h.query[We]=z,h.query[Ge]=`${u.accessKeyId}/${m}`,h.query[Ke]=f,h.query[Je]=r.toString(10);let g=K(h,i,o);return h.query[qe]=this.getCanonicalHeaderList(g),h.query[Ye]=await this.getSignature(f,m,this.getSigningKey(u,d,p,l),this.createCanonicalRequest(h,g,await q(e,this.sha256))),h}async sign(e,t){return typeof e==`string`?this.signString(e,t):e.headers&&e.payload?this.signEvent(e,t):e.message?this.signMessage(e,t):this.signRequest(e,t)}async signEvent({headers:e,payload:t},{signingDate:n=new Date,priorSignature:r,signingRegion:i,signingService:a,eventStreamCredentials:o}){let s=i??await this.regionProvider(),{shortDate:c,longDate:l}=this.formatDate(n),u=W(c,s,a??this.service),d=await q({headers:{},body:t},this.sha256),f=new this.sha256;f.update(e);let p=[rt,l,u,r,x(await f.digest()),d].join(`
12
+ `);return this.signString(p,{signingDate:n,signingRegion:s,signingService:a,eventStreamCredentials:o})}async signMessage(e,{signingDate:t=new Date,signingRegion:n,signingService:r,eventStreamCredentials:i}){return this.signEvent({headers:this.headerFormatter.format(e.message.headers),payload:e.message.body},{signingDate:t,signingRegion:n,signingService:r,priorSignature:e.priorSignature,eventStreamCredentials:i}).then(t=>({message:e.message,signature:t}))}async signString(e,{signingDate:t=new Date,signingRegion:n,signingService:r,eventStreamCredentials:i}={}){let a=i??await this.credentialProvider();this.validateResolvedCredentials(a);let o=n??await this.regionProvider(),{shortDate:s}=this.formatDate(t),c=new this.sha256(await this.getSigningKey(a,o,s,r));return c.update(C(e)),x(await c.digest())}async signRequest(e,{signingDate:t=new Date,signableHeaders:n,unsignableHeaders:r,signingRegion:i,signingService:a}={}){let o=await this.credentialProvider();this.validateResolvedCredentials(o);let s=i??await this.regionProvider(),c=J(e),{longDate:l,shortDate:u}=this.formatDate(t),d=W(u,s,a??this.service);c.headers[R]=l,o.sessionToken&&(c.headers[$e]=o.sessionToken);let f=await q(c,this.sha256);!gt(`x-amz-content-sha256`,c.headers)&&this.applyChecksum&&(c.headers[Qe]=f);let p=K(c,r,n),m=await this.getSignature(l,d,this.getSigningKey(o,s,u,a),this.createCanonicalRequest(c,p,f));return c.headers[L]=`${z} Credential=${o.accessKeyId}/${d}, SignedHeaders=${this.getCanonicalHeaderList(p)}, Signature=${m}`,c}async getSignature(e,t,n,r){let i=await this.createStringToSign(e,t,r,z),a=new this.sha256(await n);return a.update(C(i)),x(await a.digest())}getSigningKey(e,t,n,r){return ft(this.sha256,e,n,t,r||this.service)}}})),St,Ct=e((()=>{St={SignatureV4a:null}})),wt=e((()=>{xt(),V(),mt(),ot(),ht(),yt(),bt(),pt(),dt(),_t(),Ct()}));function Tt(e,{credentials:t,credentialDefaultProvider:n}){let r;return r=t?t?.memoized?t:be(t,ye,ve):n?T(n(Object.assign({},e,{parentClientConfig:e}))):async()=>{throw Error("@aws-sdk/core::resolveAwsSdkSigV4Config - `credentials` not provided and no credentialDefaultProvider was configured.")},r.memoized=!0,r}function Et(e,t){if(t.configBound)return t;let n=async n=>t({...n,callerClientConfig:e});return n.memoized=t.memoized,n.configBound=!0,n}var Dt,Ot=e((()=>{s(),xe(),wt(),Dt=e=>{let t=e.credentials,n=!!e.credentials,r;Object.defineProperty(e,"credentials",{set(a){a&&a!==t&&a!==r&&(n=!0),t=a;let o=Et(e,Tt(e,{credentials:t,credentialDefaultProvider:e.credentialDefaultProvider}));if(n&&!o.attributed){let e=typeof t==`object`&&!!t;r=async t=>{let n=await o(t);return e&&(!n.$source||Object.keys(n.$source).length===0)?i(n,`CREDENTIALS_CODE`,`e`):n},r.memoized=o.memoized,r.configBound=o.configBound,r.attributed=!0}else r=o},get(){return r},enumerable:!0,configurable:!0}),e.credentials=t;let{signingEscapePath:a=!0,systemClockOffset:o=e.systemClockOffset||0,sha256:s}=e,c;return c=e.signer?T(e.signer):e.regionInfoProvider?()=>T(e.region)().then(async t=>[await e.regionInfoProvider(t,{useFipsEndpoint:await e.useFipsEndpoint(),useDualstackEndpoint:await e.useDualstackEndpoint()})||{},t]).then(([t,n])=>{let{signingRegion:r,signingService:i}=t;e.signingRegion=e.signingRegion||r||n,e.signingName=e.signingName||i||e.serviceId;let o={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:s,uriEscapePath:a};return new(e.signerConstructor||Y)(o)}):async t=>{t=Object.assign({},{name:`sigv4`,signingName:e.signingName||e.defaultSigningName,signingRegion:await T(e.region)(),properties:{}},t);let n=t.signingRegion,r=t.signingName;e.signingRegion=e.signingRegion||n,e.signingName=e.signingName||r||e.serviceId;let i={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:s,uriEscapePath:a};return new(e.signerConstructor||Y)(i)},Object.assign(e,{systemClockOffset:o,signingEscapePath:a,signer:c})}})),kt=e((()=>{M(),ke(),Pe(),Le(),Ot()})),At=e((()=>{kt(),F()})),X,jt=e((()=>{o(),u(),t(),X=class{constructor(e=!1){n(this,`queryCompat`,void 0),n(this,`errorRegistry`,void 0),this.queryCompat=e}resolveRestContentType(e,t){let n=t.getMemberSchemas(),r=Object.values(n).find(e=>!!e.getMergedTraits().httpPayload);if(r)return r.getMergedTraits().mediaType||(r.isStringSchema()?`text/plain`:r.isBlobSchema()?`application/octet-stream`:e);if(!t.isUnitSchema()&&Object.values(n).find(e=>{let{httpQuery:t,httpQueryParams:n,httpHeader:r,httpLabel:i,httpPrefixHeaders:a}=e.getMergedTraits();return!t&&!n&&!r&&!i&&a===void 0}))return e}async getErrorSchemaOrThrowBaseException(e,t,n,r,i,a){let o=e;e.includes(`#`)&&([,o]=e.split(`#`));let s={$metadata:i,$fault:n.statusCode<500?`client`:`server`};if(!this.errorRegistry)throw Error(`@aws-sdk/core/protocols - error handler not initialized.`);try{return{errorSchema:a?.(this.errorRegistry,o)??this.errorRegistry.getSchema(e),errorMetadata:s}}catch{r.message=r.message??r.Message??`UnknownError`;let e=this.errorRegistry,t=e.getBaseException();if(t){let n=e.getErrorCtor(t)??Error;throw this.decorateServiceException(Object.assign(new n({name:o}),s),r)}let n=r,i=n?.message??n?.Message??n?.Error?.Message??n?.Error?.message;throw this.decorateServiceException(Object.assign(Error(i),{name:o},s),r)}}compose(e,t,n){let r=n;t.includes(`#`)&&([r]=t.split(`#`));let i=p.for(r),a=p.for(`smithy.ts.sdk.synthetic.`+n);e.copyFrom(i),e.copyFrom(a),this.errorRegistry=e}decorateServiceException(e,t={}){if(this.queryCompat){let n=e.Message??t.Message,r=a(e,t);n&&(r.message=n);let i=r.Error??{};i.Type=r.Error?.Type,i.Code=r.Error?.Code,i.Message=r.Error?.message??r.Error?.Message??n,r.Error=i;let o=r.$metadata.requestId;return o&&(r.RequestId=o),r}return a(e,t)}setQueryCompatError(e,t){let n=t.headers?.[`x-amzn-query-error`];if(e!==void 0&&n!=null){let[t,r]=n.split(`;`),i=Object.keys(e),a={Code:t,Type:r};e.Code=t,e.Type=r;for(let t=0;t<i.length;t++){let n=i[t];a[n===`message`?`Message`:n]=e[n]}delete a.__type,e.Error=a}}queryCompatOutput(e,t){e.Error&&(t.Error=e.Error),e.Type&&(t.Type=e.Type),e.Code&&(t.Code=e.Code)}findQueryCompatibleError(e,t){try{return e.getSchema(t)}catch{return e.find(e=>c.of(e).getMergedTraits().awsQueryError?.[0]===t)}}}})),Z,Q=e((()=>{t(),Z=class{constructor(){n(this,`serdeContext`,void 0)}setSerdeContext(e){this.serdeContext=e}}})),Mt,Nt=e((()=>{t(),Mt=class{constructor(e,t){n(this,`from`,void 0),n(this,`to`,void 0),n(this,`keys`,void 0),this.from=e,this.to=t;let r=Object.keys(this.from),i=new Set(r);i.delete(`__type`),this.keys=i}mark(e){this.keys.delete(e)}hasUnknown(){return this.keys.size===1&&Object.keys(this.to).length===0}writeUnknown(){if(this.hasUnknown()){let e=this.keys.values().next().value,t=this.from[e];this.to.$unknown=[e,t]}}}}));function Pt(e,t,n){if(n?.source){let e=n.source;if(typeof t==`number`&&(t>2**53-1||t<-(2**53-1)||e!==String(t)))return e.includes(`.`)?new b(e,`bigDecimal`):BigInt(e)}return t}var Ft=e((()=>{S()})),It,Lt=e((()=>{y(),S(),It=(e,t)=>h(e,t).then(e=>(t?.utf8Encoder??ue)(e))})),Rt,zt,$,Bt,Vt,Ht=e((()=>{Lt(),Rt=(e,t)=>It(e,t).then(e=>{if(e.length)try{return JSON.parse(e)}catch(t){throw t?.name===`SyntaxError`&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}return{}}),zt=(e,t)=>Object.keys(e).find(e=>e.toLowerCase()===t.toLowerCase()),$=e=>{let t=e;return typeof t==`number`&&(t=t.toString()),t.indexOf(`,`)>=0&&(t=t.split(`,`)[0]),t.indexOf(`:`)>=0&&(t=t.split(`:`)[0]),t.indexOf(`#`)>=0&&(t=t.split(`#`)[1]),t},Bt=(e,t)=>Vt(e,t,[`header`,`code`,`type`]),Vt=({headers:e},t,n)=>{for(;n.length>0;)switch(n.shift()){case`header`:let n=zt(e??{},`x-amzn-errortype`);if(n!==void 0)return $(e[n]);break;case`code`:let r=zt(t??{},`code`);if(r&&t[r]!==void 0)return $(t[r]);break;case`type`:if(t?.__type!==void 0)return $(t.__type);break}}})),Ut,Wt=e((()=>{y(),u(),S(),Q(),Nt(),Ft(),Ht(),t(),Ut=class extends Z{constructor(e){super(),n(this,`settings`,void 0),this.settings=e}async read(e,t){return this._read(e,typeof t==`string`?JSON.parse(t,Pt):await Rt(t,this.serdeContext))}readObject(e,t){return this._read(e,t)}_read(e,t){let n=typeof t==`object`&&!!t,r=c.of(e);if(n){if(r.isStructSchema()){let e=t,n=r.isUnionSchema(),i={},a,{jsonName:o}=this.settings;o&&(a={});let s;n&&(s=new Mt(e,i));for(let[t,c]of r.structIterator()){let r=t;o&&(r=c.getMergedTraits().jsonName??r,a[r]=t),n&&s.mark(r),e[r]!=null&&(i[t]=this._read(c,e[r]))}if(n)s.writeUnknown();else if(typeof e.__type==`string`)for(let t in e){let n=e[t],r=o?a[t]??t:t;r in i||(i[r]=n)}return i}if(Array.isArray(t)&&r.isListSchema()){let e=r.getValueSchema(),n=[];for(let r of t)n.push(this._read(e,r));return n}if(r.isMapSchema()){let e=r.getValueSchema(),n={};for(let r in t)n[r]=this._read(e,t[r]);return n}}if(r.isBlobSchema()&&typeof t==`string`)return le(t);let i=r.getMergedTraits().mediaType;if(r.isStringSchema()&&typeof t==`string`&&i)return i===`application/json`||i.endsWith(`+json`)?fe.from(t):t;if(r.isTimestampSchema()&&t!=null)switch(g(r,this.settings)){case 5:return pe(t);case 6:return se(t);case 7:return de(t);default:return console.warn(`Missing timestamp format, parsing value with Date constructor:`,t),new Date(t)}if(r.isBigIntegerSchema()&&(typeof t==`number`||typeof t==`string`))return BigInt(t);if(r.isBigDecimalSchema()&&t!=null){if(t instanceof b)return t;let e=t;return e.type===`bigDecimal`&&`string`in e?new b(e.string,e.type):new b(String(t),`bigDecimal`)}if(r.isNumericSchema()&&typeof t==`string`){switch(t){case`Infinity`:return 1/0;case`-Infinity`:return-1/0;case`NaN`:return NaN}return t}if(r.isDocumentSchema())if(n){let e=Array.isArray(t)?[]:{};for(let n in t){let i=t[n];i instanceof b?e[n]=i:e[n]=this._read(r,i)}return e}else return structuredClone(t);return t}}})),Gt,Kt=e((()=>{S(),t(),Gt=class{constructor(){n(this,`values`,new Map),n(this,`counter`,0),n(this,`stage`,0)}createReplacer(){if(this.stage===1)throw Error(`@aws-sdk/core/protocols - JsonReplacer already created.`);if(this.stage===2)throw Error(`@aws-sdk/core/protocols - JsonReplacer exhausted.`);return this.stage=1,(e,t)=>{if(t instanceof b){let e=`${`Νnv`+this.counter++}_`+t.string;return this.values.set(`"${e}"`,t.string),e}if(typeof t==`bigint`){let e=t.toString(),n=`${`Νb`+this.counter++}_`+e;return this.values.set(`"${n}"`,e),n}return t}}replaceInJson(e){if(this.stage===0)throw Error(`@aws-sdk/core/protocols - JsonReplacer not created yet.`);if(this.stage===2)throw Error(`@aws-sdk/core/protocols - JsonReplacer exhausted.`);if(this.stage=2,this.counter===0)return e;for(let[t,n]of this.values)e=e.replace(t,n);return e}}})),qt,Jt=e((()=>{y(),u(),S(),Q(),Kt(),t(),qt=class extends Z{constructor(e){super(),n(this,`settings`,void 0),n(this,`buffer`,void 0),n(this,`useReplacer`,!1),n(this,`rootSchema`,void 0),this.settings=e}write(e,t){this.rootSchema=c.of(e),this.buffer=this._write(this.rootSchema,t)}flush(){let{rootSchema:e,useReplacer:t}=this;if(this.rootSchema=void 0,this.useReplacer=!1,e?.isStructSchema()||e?.isDocumentSchema()){if(!t)return JSON.stringify(this.buffer);let e=new Gt;return e.replaceInJson(JSON.stringify(this.buffer,e.createReplacer(),0))}return this.buffer}writeDiscriminatedDocument(e,t){this.write(e,t),typeof this.buffer==`object`&&(this.buffer.__type=c.of(e).getName(!0))}_write(e,t,n){let r=typeof t==`object`&&!!t,i=c.of(e);if(r){if(i.isStructSchema()){let e=t,n={},{jsonName:r}=this.settings,a;r&&(a={});let o=0;for(let[t,s]of i.structIterator()){let c=this._write(s,e[t],i);if(c!==void 0){let e=t;r&&(e=s.getMergedTraits().jsonName??t,a[t]=e),n[e]=c,o++}}if(i.isUnionSchema()&&o===0){let{$unknown:t}=e;if(Array.isArray(t)){let[e,r]=t;n[e]=this._write(15,r)}}else if(typeof e.__type==`string`)for(let t in e){let i=e[t],o=r?a[t]??t:t;o in n||(n[o]=this._write(15,i))}return n}if(Array.isArray(t)&&i.isListSchema()){let e=i.getValueSchema(),n=[],r=!!i.getMergedTraits().sparse;for(let i of t)(r||i!=null)&&n.push(this._write(e,i));return n}if(i.isMapSchema()){let e=i.getValueSchema(),n={},r=!!i.getMergedTraits().sparse;for(let i in t){let a=t[i];(r||a!=null)&&(n[i]=this._write(e,a))}return n}if(t instanceof Uint8Array&&(i.isBlobSchema()||i.isDocumentSchema()))return i===this.rootSchema?t:(this.serdeContext?.base64Encoder??w)(t);if(t instanceof Date&&(i.isTimestampSchema()||i.isDocumentSchema()))switch(g(i,this.settings)){case 5:return t.toISOString().replace(`.000Z`,`Z`);case 6:return ae(t);case 7:return t.getTime()/1e3;default:return console.warn(`Missing timestamp format, using epoch seconds`,t),t.getTime()/1e3}t instanceof b&&(this.useReplacer=!0)}if(!(t===null&&n?.isStructSchema())){if(i.isStringSchema()){if(t===void 0&&i.isIdempotencyToken())return me();let e=i.getMergedTraits().mediaType;return t!=null&&e&&(e===`application/json`||e.endsWith(`+json`))?fe.from(t):t}if(typeof t==`number`&&i.isNumericSchema())return Math.abs(t)===1/0||isNaN(t)?String(t):t;if(typeof t==`string`&&i.isBlobSchema())return i===this.rootSchema?t:(this.serdeContext?.base64Encoder??w)(t);if(typeof t==`bigint`&&(this.useReplacer=!0),i.isDocumentSchema())if(r){let e=Array.isArray(t)?[]:{};for(let n in t){let r=t[n];r instanceof b?(this.useReplacer=!0,e[n]=r):e[n]=this._write(i,r)}return e}else return structuredClone(t);return t}}}})),Yt,Xt=e((()=>{Q(),Wt(),Jt(),t(),Yt=class extends Z{constructor(e){super(),n(this,`settings`,void 0),this.settings=e}createSerializer(){let e=new qt(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new Ut(this.settings);return e.setSerdeContext(this.serdeContext),e}}})),Zt,Qt=e((()=>{y(),u(),jt(),Xt(),Ht(),t(),Zt=class extends re{constructor({defaultNamespace:e,errorTypeRegistries:t}){super({defaultNamespace:e,errorTypeRegistries:t}),n(this,`serializer`,void 0),n(this,`deserializer`,void 0),n(this,`codec`,void 0),n(this,`mixin`,new X);let r={timestampFormat:{useTrait:!0,default:7},httpBindings:!0,jsonName:!0};this.codec=new Yt(r),this.serializer=new ee(this.codec.createSerializer(),r),this.deserializer=new ne(this.codec.createDeserializer(),r)}getShapeId(){return`aws.protocols#restJson1`}getPayloadCodec(){return this.codec}setSerdeContext(e){this.codec.setSerdeContext(e),super.setSerdeContext(e)}async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n),i=c.of(e.input);if(!r.headers[`content-type`]){let e=this.mixin.resolveRestContentType(this.getDefaultContentType(),i);e&&(r.headers[`content-type`]=e)}return r.body==null&&r.headers[`content-type`]===this.getDefaultContentType()&&(r.body=`{}`),r}async deserializeResponse(e,t,n){let r=await super.deserializeResponse(e,t,n),i=c.of(e.output);for(let[e,t]of i.structIterator())t.getMemberTraits().httpPayload&&!(e in r)&&(r[e]=null);return r}async handleError(e,t,n,r,i){let a=Bt(n,r)??`Unknown`;this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace);let{errorSchema:o,errorMetadata:s}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,r,i),l=c.of(o),u=r.message??r.Message??`UnknownError`,d=new((this.compositeErrorRegistry.getErrorCtor(o))??Error)({});await this.deserializeHttpMessage(o,t,n,r);let f={},p=this.codec.createDeserializer();for(let[e,t]of l.structIterator()){let n=t.getMergedTraits().jsonName??e;f[e]=p.readObject(t,r[n])}throw this.mixin.decorateServiceException(Object.assign(d,s,{$fault:l.getMergedTraits().error,message:u},f),r)}getDefaultContentType(){return`application/json`}}}));function $t(e){return new en(e).parse()}var en,tn=e((()=>{t(),en=class e{constructor(e){n(this,`x`,void 0),n(this,`i`,0),n(this,`z`,void 0),this.x=e,this.x=e.replace(/\r\n?/g,`
13
+ `),this.z=this.x.length}parse(){let e=this,{z:t}=e;for(;e.i<t&&(e.trim(),!(e.i>=t));)if(e.isNext(`<?`))e.readTo(`?>`),e.trim();else if(e.isNext(`<!--`))e.readTo(`-->`),e.trim();else if(e.isNext(`<!DOCTYPE`,!1))e.skipDoctype(),e.trim();else if(e.x[e.i]===`<`){let t=e.parseTag();return{[t.tag]:t.value}}else throw Error(`@aws-sdk XML parse error: unexpected content.`);throw Error(`@aws-sdk XML parse error: no root element.`)}isNext(e,t=!0){let n=this;return t?n.x.startsWith(e,n.i):n.x.toLowerCase().startsWith(e.toLowerCase(),n.i)}readTo(e){let t=this,n=t.x.indexOf(e,t.i);if(n===-1)throw Error(`@aws-sdk XML parse error: expected "${e}" not found.`);let r=t.x.slice(t.i,n);return t.i=n+e.length,r}trim(){let e=this;for(;e.i<e.z&&` \r
14
+ `.includes(e.x[e.i]);)++e.i}readAttrValue(){let e=this,t=e.x[e.i];++e.i;let n=``;for(;e.i<e.z&&e.x[e.i]!==t;)n+=e.x[e.i++];return++e.i,e.decodeEntities(n)}parseTag(){let e=this;++e.i;let t=``;for(;e.i<e.z&&!` \r
15
+ >/`.includes(e.x[e.i]);)t+=e.x[e.i++];let n=!1,r=Object.create(null);for(;e.i<e.z&&(e.trim(),!`>/`.includes(e.x[e.i]));){let t=``;for(;e.i<e.z&&!`= \r
16
+ >/?`.includes(e.x[e.i]);)t+=e.x[e.i++];if(e.trim(),e.x[e.i]!==`=`)break;++e.i,e.trim(),r[t]=e.readAttrValue(),n=!0}if(e.i>=e.z)throw Error(`@aws-sdk XML parse error: unexpected end of input.`);if(e.x[e.i]===`/`){if(++e.i,e.i>=e.z||e.x[e.i]!==`>`)throw Error(`@aws-sdk XML parse error: expected > at the end of self-closing tag.`);return++e.i,Object.setPrototypeOf(r,Object.prototype),{tag:t,value:n?r:``}}if(e.x[e.i]!==`>`)throw Error(`@aws-sdk XML parse error: expected > at the end of opening tag.`);++e.i;let i=[],a=[],o=!1;for(;e.i<e.z&&!e.isNext(`</`);)if(e.x[e.i]===`<`)e.isNext(`<!--`)?e.readTo(`-->`):e.isNext(`<![CDATA[`)?(e.i+=9,i.push(e.readTo(`]]>`))):e.isNext(`<?`)?e.readTo(`?>`):(o=!0,a.push(e.parseTag()));else{let t=``;for(;e.i<e.z&&e.x[e.i]!==`<`;)t+=e.x[e.i++];i.push(e.decodeEntities(t))}if(!e.isNext(`</`))throw Error(`@aws-sdk XML parse error: missing closing tag </${t}>.`);e.i+=2;let s=e.readTo(`>`).trim();if(s!==t)throw Error(`@aws-sdk XML parse error: mismatched tags <${t}> and </${s}>.`);if(!n&&i.length===0&&!o)return{tag:t,value:``};if(!n&&!o){let e=i.length===1?i[0]:i.join(``);return e.trim()===``&&e.includes(`
17
+ `)?{tag:t,value:``}:{tag:t,value:e}}let c=Object.create(null);for(let e of i)e.trim()===``&&e.includes(`
18
+ `)||(c[`#text`]=`#text`in c?c[`#text`]+e:e);for(let e of a)e.tag in c?Array.isArray(c[e.tag])?c[e.tag].push(e.value):c[e.tag]=[c[e.tag],e.value]:c[e.tag]=e.value;for(let[e,t]of Object.entries(r))c[e]=t;return Object.setPrototypeOf(c,Object.prototype),{tag:t,value:c}}skipDoctype(){let e=this;e.i+=9;let t=0;for(;e.i<e.z;){let n=e.x[e.i];if(n===`[`)++t;else if(n===`]`)--t;else if(n===`>`&&t===0){++e.i;return}++e.i}throw Error(`@aws-sdk XML parse error: unclosed DOCTYPE.`)}decodeEntities(t){return t.replace(/&(?:#x([0-9a-fA-F]{1,6})|#(\d{1,7})|([a-zA-Z][a-zA-Z0-9]{0,30}));/g,(t,n,r,i)=>n?String.fromCharCode(parseInt(n,16)):r?String.fromCharCode(parseInt(r,10)):e.ENTITIES[i]??``)}},n(en,`ENTITIES`,{amp:`&`,lt:`<`,gt:`>`,quot:`"`,apos:`'`})})),nn=e((()=>{tn()})),rn,an=e((()=>{nn(),o(),y(),u(),S(),Q(),Nt(),t(),rn=class extends Z{constructor(e){super(),n(this,`settings`,void 0),n(this,`stringDeserializer`,void 0),this.settings=e,this.stringDeserializer=new te(e)}setSerdeContext(e){this.serdeContext=e,this.stringDeserializer.setSerdeContext(e)}read(e,t,n){let r=c.of(e),i=r.getMemberSchemas();if(r.isStructSchema()&&r.isMemberSchema()&&Object.values(i).find(e=>!!e.getMemberTraits().eventPayload)){let e={},n=Object.keys(i)[0];return i[n].isBlobSchema()?e[n]=t:e[n]=this.read(i[n],t),e}let a=(this.serdeContext?.utf8Encoder??ue)(t),o=this.parseXml(a);return this.readSchema(e,n?o[n]:o)}readSchema(e,t){let n=c.of(e);if(n.isUnitSchema())return;let r=n.getMergedTraits();if(n.isListSchema()&&!Array.isArray(t))return this.readSchema(n,[t]);if(t==null)return t;if(typeof t==`object`){let e=!!r.xmlFlattened;if(n.isListSchema()){let r=n.getValueSchema(),i=[],a=r.getMergedTraits().xmlName??`member`,o=e?t:(t[0]??t)[a];if(o==null)return i;let s=Array.isArray(o)?o:[o];for(let e of s)i.push(this.readSchema(r,e));return i}let i={};if(n.isMapSchema()){let r=n.getKeySchema(),a=n.getValueSchema(),o;o=e?Array.isArray(t)?t:[t]:Array.isArray(t.entry)?t.entry:[t.entry];let s=r.getMergedTraits().xmlName??`key`,c=a.getMergedTraits().xmlName??`value`;for(let e of o){let t=e[s],n=e[c];i[t]=this.readSchema(a,n)}return i}if(n.isStructSchema()){let e=n.isUnionSchema(),r;e&&(r=new Mt(t,i));for(let[a,o]of n.structIterator()){let n=o.getMergedTraits(),s=n.httpPayload?n.xmlName??o.getName():o.getMemberTraits().xmlName??a;e&&r.mark(s),t[s]!=null&&(i[a]=this.readSchema(o,t[s]))}return e&&r.writeUnknown(),i}if(n.isDocumentSchema())return t;throw Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${n.getName(!0)}`)}return n.isListSchema()?[]:n.isMapSchema()||n.isStructSchema()?{}:this.stringDeserializer.read(n,t)}parseXml(e){if(e.length){let t;try{t=$t(e)}catch(t){throw t&&typeof t==`object`&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}let n=`#text`,i=Object.keys(t)[0],a=t[i];return a[n]&&(a[i]=a[n],delete a[n]),r(a)}return{}}}})),on,sn=e((()=>{y(),u(),S(),Q(),t(),on=class extends Z{constructor(e){super(),n(this,`settings`,void 0),n(this,`buffer`,void 0),this.settings=e}write(e,t,n=``){this.buffer===void 0&&(this.buffer=``);let r=c.of(e);if(n&&!n.endsWith(`.`)&&(n+=`.`),r.isBlobSchema())(typeof t==`string`||t instanceof Uint8Array)&&(this.writeKey(n),this.writeValue((this.serdeContext?.base64Encoder??w)(t)));else if(r.isBooleanSchema()||r.isNumericSchema()||r.isStringSchema())t==null?r.isIdempotencyToken()&&(this.writeKey(n),this.writeValue(me())):(this.writeKey(n),this.writeValue(String(t)));else if(r.isBigIntegerSchema())t!=null&&(this.writeKey(n),this.writeValue(String(t)));else if(r.isBigDecimalSchema())t!=null&&(this.writeKey(n),this.writeValue(t instanceof b?t.string:String(t)));else if(r.isTimestampSchema()){if(t instanceof Date)switch(this.writeKey(n),g(r,this.settings)){case 5:this.writeValue(t.toISOString().replace(`.000Z`,`Z`));break;case 6:this.writeValue(ae(t));break;case 7:this.writeValue(String(t.getTime()/1e3));break}}else if(r.isDocumentSchema())Array.isArray(t)?this.write(79,t,n):t instanceof Date?this.write(4,t,n):t instanceof Uint8Array?this.write(21,t,n):t&&typeof t==`object`?this.write(143,t,n):(this.writeKey(n),this.writeValue(String(t)));else if(r.isListSchema()){if(Array.isArray(t))if(t.length===0)this.settings.serializeEmptyLists&&(this.writeKey(n),this.writeValue(``));else{let e=r.getValueSchema(),i=this.settings.flattenLists||r.getMergedTraits().xmlFlattened,a=1;for(let r of t){if(r==null)continue;let t=e.getMergedTraits(),o=this.getKey(`member`,t.xmlName,t.ec2QueryName),s=i?`${n}${a}`:`${n}${o}.${a}`;this.write(e,r,s),++a}}}else if(r.isMapSchema()){if(t&&typeof t==`object`){let e=r.getKeySchema(),i=r.getValueSchema(),a=r.getMergedTraits().xmlFlattened,o=1;for(let r in t){let s=t[r];if(s==null)continue;let c=e.getMergedTraits(),l=this.getKey(`key`,c.xmlName,c.ec2QueryName),u=a?`${n}${o}.${l}`:`${n}entry.${o}.${l}`,d=i.getMergedTraits(),f=this.getKey(`value`,d.xmlName,d.ec2QueryName),p=a?`${n}${o}.${f}`:`${n}entry.${o}.${f}`;this.write(e,r,u),this.write(i,s,p),++o}}}else if(r.isStructSchema()){if(t&&typeof t==`object`){let e=!1;for(let[i,a]of r.structIterator()){if(t[i]==null&&!a.isIdempotencyToken())continue;let r=a.getMergedTraits(),o=this.getKey(i,r.xmlName,r.ec2QueryName,`struct`),s=`${n}${o}`;this.write(a,t[i],s),e=!0}if(!e&&r.isUnionSchema()){let{$unknown:e}=t;if(Array.isArray(e)){let[t,r]=e,i=`${n}${t}`;this.write(15,r,i)}}}}else if(!r.isUnitSchema())throw Error(`@aws-sdk/core/protocols - QuerySerializer unrecognized schema type ${r.getName(!0)}`)}flush(){if(this.buffer===void 0)throw Error(`@aws-sdk/core/protocols - QuerySerializer cannot flush with nothing written to buffer.`);let e=this.buffer;return delete this.buffer,e}getKey(e,t,n,r){let{ec2:i,capitalizeKeys:a}=this.settings;if(i&&n)return n;let o=t??e;return a&&r===`struct`?o[0].toUpperCase()+o.slice(1):o}writeKey(e){e.endsWith(`.`)&&(e=e.slice(0,e.length-1)),this.buffer+=`&${l(e)}=`}writeValue(e){this.buffer+=l(e)}}})),cn,ln=e((()=>{y(),u(),jt(),an(),sn(),t(),cn=class extends ie{constructor(e){super({defaultNamespace:e.defaultNamespace,errorTypeRegistries:e.errorTypeRegistries}),n(this,`options`,void 0),n(this,`serializer`,void 0),n(this,`deserializer`,void 0),n(this,`mixin`,new X),this.options=e;let t={timestampFormat:{useTrait:!0,default:5},httpBindings:!1,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace,serializeEmptyLists:!0};this.serializer=new on(t),this.deserializer=new rn(t)}getShapeId(){return`aws.protocols#awsQuery`}setSerdeContext(e){this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e)}getPayloadCodec(){throw Error(`AWSQuery protocol has no payload codec.`)}async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n);return r.path.endsWith(`/`)||(r.path+=`/`),r.headers[`content-type`]=`application/x-www-form-urlencoded`,(m(e.input)===`unit`||!r.body)&&(r.body=``),r.body=`Action=${e.name.split(`#`)[1]??e.name}&Version=${this.options.version}`+r.body,r.body.endsWith(`&`)&&(r.body=r.body.slice(-1)),r}async deserializeResponse(e,t,n){let r=this.deserializer,i=c.of(e.output),a={};if(n.statusCode>=300){let i=await h(n.body,t);i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n))}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=e.name.split(`#`)[1]??e.name,s=i.isStructSchema()&&this.useNestedResult()?o+`Result`:void 0,l=await h(n.body,t);return l.byteLength>0&&Object.assign(a,await r.read(i,l,s)),a.$metadata=this.deserializeMetadata(n),a}useNestedResult(){return!0}async handleError(e,t,n,r,i){let a=this.loadQueryErrorCode(n,r)??`Unknown`;this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace);let o=this.loadQueryError(r)??{},s=this.loadQueryErrorMessage(r);o.message=s,o.Error={Type:o.Type,Code:o.Code,Message:s};let{errorSchema:l,errorMetadata:u}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,o,i,this.mixin.findQueryCompatibleError),d=c.of(l),f=new((this.compositeErrorRegistry.getErrorCtor(l))??Error)({}),p={Type:o.Error.Type,Code:o.Error.Code,Error:o.Error};for(let[e,t]of d.structIterator()){let n=t.getMergedTraits().xmlName??e,i=o[n]??r[n];p[e]=this.deserializer.readSchema(t,i)}throw this.mixin.decorateServiceException(Object.assign(f,u,{$fault:d.getMergedTraits().error,message:s},p),r)}loadQueryErrorCode(e,t){let n=(t.Errors?.[0]?.Error??t.Errors?.Error??t.Error)?.Code;if(n!==void 0)return n;if(e.statusCode==404)return`NotFound`}loadQueryError(e){return e.Errors?.[0]?.Error??e.Errors?.Error??e.Error}loadQueryErrorMessage(e){let t=this.loadQueryError(e);return t?.message??t?.Message??e.message??e.Message??`Unknown`}getDefaultContentType(){return`application/x-www-form-urlencoded`}}})),un=e((()=>{jt(),Xt(),Ht(),Qt(),Wt(),Jt(),ln(),sn(),nn(),Lt(),Q(),an()}));export{j as C,ke as S,Ne as _,Qt as a,F as b,Dt as c,St as d,Y as f,Fe as g,Le as h,Zt as i,wt as l,Ie as m,cn as n,At as o,xt as p,ln as r,Ot as s,un as t,Ct as u,Pe as v,M as w,Oe as x,P as y};
@@ -0,0 +1,2 @@
1
+ import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./defineProperty-C-QyHrDq.js";import{A as r,B as i,C as a,D as o,H as s,L as c,O as l,S as u,g as d,n as f,o as p,r as m,t as ee,w as te,x as ne,y as re,z as ie}from"./serde-f76bObzR.js";var h,ae=e((()=>{(function(e){e.HTTP=`http`,e.HTTPS=`https`})(h||(h={}))})),g,oe=e((()=>{(function(e){e.MD5=`md5`,e.CRC32=`crc32`,e.CRC32C=`crc32c`,e.SHA1=`sha1`,e.SHA256=`sha256`})(g||(g={}))})),se=e((()=>{oe()})),ce,le=e((()=>{ce=`__smithy_context`})),_,ue=e((()=>{(function(e){e.PROFILE=`profile`,e.SSO_SESSION=`sso-session`,e.SERVICES=`services`})(_||(_={}))})),de=e((()=>{ae(),se(),le(),ue()})),v,fe=e((()=>{de(),v=e=>e.__smithy_context||(e.__smithy_context={})}));function pe(e){return Object.keys(e).reduce((t,n)=>{let r=e[n];return{...t,[n]:Array.isArray(r)?[...r]:r}},{})}var y,me=e((()=>{t(),y=class e{constructor(e){n(this,`method`,void 0),n(this,`protocol`,void 0),n(this,`hostname`,void 0),n(this,`port`,void 0),n(this,`path`,void 0),n(this,`query`,void 0),n(this,`headers`,void 0),n(this,`username`,void 0),n(this,`password`,void 0),n(this,`fragment`,void 0),n(this,`body`,void 0),this.method=e.method||`GET`,this.hostname=e.hostname||`localhost`,this.port=e.port,this.query=e.query||{},this.headers=e.headers||{},this.body=e.body,this.protocol=e.protocol?e.protocol.slice(-1)===`:`?e.protocol:`${e.protocol}:`:`https:`,this.path=e.path?e.path.charAt(0)===`/`?e.path:`/${e.path}`:`/`,this.username=e.username,this.password=e.password,this.fragment=e.fragment}static clone(t){let n=new e({...t,headers:{...t.headers}});return n.query&&(n.query=pe(n.query)),n}static isInstance(e){if(!e)return!1;let t=e;return`method`in t&&`protocol`in t&&`hostname`in t&&`path`in t&&typeof t.query==`object`&&typeof t.headers==`object`}clone(){return e.clone(this)}}})),b,he=e((()=>{t(),b=class{constructor(e){n(this,`statusCode`,void 0),n(this,`reason`,void 0),n(this,`headers`,void 0),n(this,`body`,void 0),this.statusCode=e.statusCode,this.reason=e.reason,this.headers=e.headers||{},this.body=e.body}static isInstance(e){if(!e)return!1;let t=e;return typeof t.statusCode==`number`&&typeof t.headers==`object`}}})),ge,x,_e=e((()=>{ge=RegExp(`^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$`),x=(e,t=!1)=>{if(!t)return ge.test(e);let n=e.split(`.`);for(let e of n)if(!x(e))return!1;return!0}}));function ve(e){return/^[a-z0-9][a-z0-9\.\-]*[a-z0-9]$/.test(e)}var ye=e((()=>{})),be,xe=e((()=>{be=e=>{if(typeof e==`function`)return e;let t=Promise.resolve(e);return()=>t}}));function Se(e){let t={};if(e=e.replace(/^\?/,``),e)for(let n of e.split(`&`)){let[e,r=null]=n.split(`=`);e=decodeURIComponent(e),r&&(r=decodeURIComponent(r)),e in t?Array.isArray(t[e])?t[e].push(r):t[e]=[t[e],r]:t[e]=r}return t}var Ce=e((()=>{})),S,C=e((()=>{Ce(),S=e=>{if(typeof e==`string`)return S(new URL(e));let{hostname:t,pathname:n,port:r,protocol:i,search:a}=e,o;return a&&(o=Se(a)),{hostname:t,port:r?parseInt(r):void 0,protocol:i,path:n,query:o}}})),w,we=e((()=>{C(),w=e=>{if(typeof e==`object`){if(`url`in e){let t=S(e.url);if(e.headers){t.headers={};for(let n in e.headers)t.headers[n.toLowerCase()]=e.headers[n].join(`, `)}return t}return e}return S(e)}})),T=e((()=>{fe(),me(),he(),_e(),ye(),xe(),C(),we()})),E,D=e((()=>{E=e=>typeof e==`function`?e():e})),O,k=e((()=>{O=(e,t,n,r,i)=>({name:t,namespace:e,traits:n,input:r,output:i})})),Te,A,Ee=e((()=>{T(),k(),Te=e=>(t,n)=>async r=>{let{response:i}=await t(r),{operationSchema:a}=v(n),[,o,s,c,l,u]=a??[];try{return{response:i,output:await e.protocol.deserializeResponse(O(o,s,c,l,u),{...e,...n},i)}}catch(e){if(Object.defineProperty(e,"$response",{value:i,enumerable:!1,writable:!1,configurable:!1}),!(`$metadata`in e)){let t=`Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.`;try{e.message+=`
2
+ Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.`}catch{!n.logger||n.logger?.constructor?.name===`NoOpLogger`?console.warn(t):n.logger?.warn?.(t)}e.$responseBodyText!==void 0&&e.$response&&(e.$response.body=e.$responseBodyText);try{if(b.isInstance(i)){let{headers:t={},statusCode:n}=i,r=Object.entries(t);e.$metadata={httpStatusCode:n,requestId:A(/^x-[\w-]+-request-?id$/,r),extendedRequestId:A(/^x-[\w-]+-id-2$/,r),cfId:A(/^x-[\w-]+-cf-id$/,r)}}}catch{}}throw e}},A=(e,t)=>(t.find(([t])=>t.match(e))||[void 0,void 0])[1]})),De,Oe=e((()=>{T(),k(),De=e=>(t,n)=>async r=>{let{operationSchema:i}=v(n),[,a,o,s,c,l]=i??[],u=n.endpointV2?async()=>w(n.endpointV2):e.endpoint,d=await e.protocol.serializeRequest(O(a,o,s,c,l),r.input,{...e,...n,endpoint:u});return t({...r,request:d})}}));function ke(e){return{applyToStack:t=>{t.add(De(e),je),t.add(Te(e),Ae),e.protocol.setSerdeContext(e)}}}var Ae,je,Me=e((()=>{Ee(),Oe(),Ae={name:`deserializerMiddleware`,step:`deserialize`,tags:[`DESERIALIZER`],override:!0},je={name:`serializerMiddleware`,step:`serialize`,tags:[`SERIALIZER`],override:!0}}));function j(e){if(typeof e==`object`)return e;if(e|=0,M[e])return M[e];let t={},n=0;for(let r of[`httpLabel`,`idempotent`,`idempotencyToken`,`sensitive`,`httpPayload`,`httpResponseCode`,`httpQueryParams`])(e>>n++&1)==1&&(t[r]=1);return M[e]=t}var M,Ne=e((()=>{M=[]}));function N(e,t){return e instanceof L?Object.assign(e,{memberName:t,_isMemberSchema:!0}):new L(e,t)}var Pe,P,F,I,L,R,Fe,Ie=e((()=>{D(),Ne(),t(),P={it:Symbol.for(`@smithy/nor-struct-it`),ns:Symbol.for(`@smithy/ns`)},F=[],I={},Pe=Symbol.hasInstance,L=class e{constructor(t,r){n(this,`ref`,void 0),n(this,`memberName`,void 0),n(this,`symbol`,e.symbol),n(this,`name`,void 0),n(this,`schema`,void 0),n(this,`_isMemberSchema`,void 0),n(this,`traits`,void 0),n(this,`memberTraits`,void 0),n(this,`normalizedTraits`,void 0),this.ref=t,this.memberName=r;let i=[],a=t,o=t;for(this._isMemberSchema=!1;R(a);)i.push(a[1]),a=a[0],o=E(a),this._isMemberSchema=!0;if(i.length>0){this.memberTraits={};for(let e=i.length-1;e>=0;--e){let t=i[e];Object.assign(this.memberTraits,j(t))}}else this.memberTraits=0;if(o instanceof e){let e=this.memberTraits;Object.assign(this,o),this.memberTraits=Object.assign({},e,o.getMemberTraits(),this.getMemberTraits()),this.normalizedTraits=void 0,this.memberName=r??o.memberName;return}if(this.schema=E(o),Fe(this.schema)?(this.name=`${this.schema[1]}#${this.schema[2]}`,this.traits=this.schema[3]):(this.name=this.memberName??String(o),this.traits=0),this._isMemberSchema&&!r)throw Error(`@smithy/core/schema - NormalizedSchema member init ${this.getName(!0)} missing member name.`)}static[Pe](e){let t=this.prototype.isPrototypeOf(e);return!t&&typeof e==`object`&&e?e.symbol===this.symbol:t}static of(t){let n=typeof t==`function`||typeof t==`object`&&!!t;if(typeof t==`number`){if(F[t])return F[t]}else if(typeof t==`string`){if(I[t])return I[t]}else if(n&&t[P.ns])return t[P.ns];let r=E(t);if(r instanceof e)return r;if(R(r)){let[n,i]=r;if(n instanceof e)return Object.assign(n.getMergedTraits(),j(i)),n;throw Error(`@smithy/core/schema - may not init unwrapped member schema=${JSON.stringify(t,null,2)}.`)}let i=new e(r);return n?t[P.ns]=i:typeof r==`string`?I[r]=i:typeof r==`number`?F[r]=i:i}getSchema(){let e=this.schema;return Array.isArray(e)&&e[0]===0?e[4]:e}getName(e=!1){let{name:t}=this;return!e&&t&&t.includes(`#`)?t.split(`#`)[1]:t||void 0}getMemberName(){return this.memberName}isMemberSchema(){return this._isMemberSchema}isListSchema(){let e=this.getSchema();return typeof e==`number`?e>=64&&e<128:e[0]===1}isMapSchema(){let e=this.getSchema();return typeof e==`number`?e>=128&&e<=255:e[0]===2}isStructSchema(){let e=this.getSchema();if(typeof e!=`object`)return!1;let t=e[0];return t===3||t===-3||t===4}isUnionSchema(){let e=this.getSchema();return typeof e==`object`&&e[0]===4}isBlobSchema(){let e=this.getSchema();return e===21||e===42}isTimestampSchema(){let e=this.getSchema();return typeof e==`number`&&e>=4&&e<=7}isUnitSchema(){return this.getSchema()===`unit`}isDocumentSchema(){return this.getSchema()===15}isStringSchema(){return this.getSchema()===0}isBooleanSchema(){return this.getSchema()===2}isNumericSchema(){return this.getSchema()===1}isBigIntegerSchema(){return this.getSchema()===17}isBigDecimalSchema(){return this.getSchema()===19}isStreaming(){let{streaming:e}=this.getMergedTraits();return!!e||this.getSchema()===42}isIdempotencyToken(){return!!this.getMergedTraits().idempotencyToken}getMergedTraits(){return this.normalizedTraits??(this.normalizedTraits={...this.getOwnTraits(),...this.getMemberTraits()})}getMemberTraits(){return j(this.memberTraits)}getOwnTraits(){return j(this.traits)}getKeySchema(){let[e,t]=[this.isDocumentSchema(),this.isMapSchema()];if(!e&&!t)throw Error(`@smithy/core/schema - cannot get key for non-map: ${this.getName(!0)}`);let n=this.getSchema();return N([e?15:n[4]??0,0],`key`)}getValueSchema(){let e=this.getSchema(),[t,n,r]=[this.isDocumentSchema(),this.isMapSchema(),this.isListSchema()],i=typeof e==`number`?63&e:e&&typeof e==`object`&&(n||r)?e[3+e[0]]:t?15:void 0;if(i!=null)return N([i,0],n?`value`:`member`);throw Error(`@smithy/core/schema - ${this.getName(!0)} has no value member.`)}getMemberSchema(e){let t=this.getSchema();if(this.isStructSchema()&&t[4].includes(e)){let n=t[4].indexOf(e),r=t[5][n];return N(R(r)?r:[r,0],e)}if(this.isDocumentSchema())return N([15,0],e);throw Error(`@smithy/core/schema - ${this.getName(!0)} has no member=${e}.`)}getMemberSchemas(){let e={};try{for(let[t,n]of this.structIterator())e[t]=n}catch{}return e}getEventStreamMember(){if(this.isStructSchema()){for(let[e,t]of this.structIterator())if(t.isStreaming()&&t.isStructSchema())return e}return``}*structIterator(){if(this.isUnitSchema())return;if(!this.isStructSchema())throw Error(`@smithy/core/schema - cannot iterate non-struct schema.`);let e=this.getSchema(),t=e[4].length,n=e[P.it];if(n&&t===n.length){yield*n;return}n=Array(t);for(let r=0;r<t;++r){let t=e[4][r],i=N([e[5][r],0],t);yield n[r]=[t,i]}e[P.it]=n}},n(L,`symbol`,Symbol.for(`@smithy/nor`)),R=e=>Array.isArray(e)&&e.length===2,Fe=e=>Array.isArray(e)&&e.length>=5})),z,Le=e((()=>{t(),z=class e{constructor(e,t=new Map,r=new Map){n(this,`namespace`,void 0),n(this,`schemas`,void 0),n(this,`exceptions`,void 0),this.namespace=e,this.schemas=t,this.exceptions=r}static for(t){return e.registries.has(t)||e.registries.set(t,new e(t)),e.registries.get(t)}copyFrom(e){let{schemas:t,exceptions:n}=this;for(let[n,r]of e.schemas)t.has(n)||t.set(n,r);for(let[t,r]of e.exceptions)n.has(t)||n.set(t,r)}register(t,n){let r=this.normalizeShapeId(t);for(let t of[this,e.for(r.split(`#`)[0])])t.schemas.set(r,n)}getSchema(e){let t=this.normalizeShapeId(e);if(!this.schemas.has(t)){if(!e.includes(`#`)){let t=`#`+e,n=[];for(let[e,r]of this.schemas.entries())e.endsWith(t)&&n.push(r);if(n.length===1)return n[0]}throw Error(`@smithy/core/schema - schema not found for ${t}`)}return this.schemas.get(t)}registerError(t,n){let r=t,i=r[1];for(let t of[this,e.for(i)])t.schemas.set(i+`#`+r[2],r),t.exceptions.set(r,n)}getErrorCtor(t){let n=t;return this.exceptions.has(n)?this.exceptions.get(n):e.for(n[1]).exceptions.get(n)}getBaseException(){for(let e of this.exceptions.keys())if(Array.isArray(e)){let[,t,n]=e,r=t+`#`+n;if(r.startsWith(`smithy.ts.sdk.synthetic.`)&&r.endsWith(`ServiceException`))return e}}find(e){for(let t of this.schemas.values())if(e(t))return t}clear(){this.schemas.clear(),this.exceptions.clear()}normalizeShapeId(e){return e.includes(`#`)?e:this.namespace+`#`+e}},n(z,`registries`,new Map)})),B=e((()=>{D(),Me(),k(),Ie(),Ne(),Le()})),V,H=e((()=>{m(),V=async(e=new Uint8Array,t)=>{if(e instanceof Uint8Array)return ee.mutate(e);if(!e)return ee.mutate(new Uint8Array);let n=t.streamCollector(e);return ee.mutate(await n)}}));function U(e){return encodeURIComponent(e).replace(/[!'()*]/g,function(e){return`%`+e.charCodeAt(0).toString(16).toUpperCase()})}var W=e((()=>{})),G,K=e((()=>{t(),G=class{constructor(){n(this,`serdeContext`,void 0)}setSerdeContext(e){this.serdeContext=e}}})),q,J=e((()=>{B(),T(),K(),t(),q=class extends G{constructor(e){super(),n(this,`options`,void 0),n(this,`compositeErrorRegistry`,void 0),this.options=e,this.compositeErrorRegistry=z.for(e.defaultNamespace);for(let t of e.errorTypeRegistries??[])this.compositeErrorRegistry.copyFrom(t)}getRequestType(){return y}getResponseType(){return b}setSerdeContext(e){this.serdeContext=e,this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e),this.getPayloadCodec()&&this.getPayloadCodec().setSerdeContext(e)}updateServiceEndpoint(e,t){if(`url`in t){e.protocol=t.url.protocol,e.hostname=t.url.hostname,e.port=t.url.port?Number(t.url.port):void 0,e.path=t.url.pathname,e.fragment=t.url.hash||void 0,e.username=t.url.username||void 0,e.password=t.url.password||void 0,e.query||(e.query={});for(let[n,r]of t.url.searchParams.entries())e.query[n]=r;if(t.headers)for(let n in t.headers)e.headers[n]=t.headers[n].join(`, `);return e}else{if(e.protocol=t.protocol,e.hostname=t.hostname,e.port=t.port?Number(t.port):void 0,e.path=t.path,e.query={...t.query},t.headers)for(let n in t.headers)e.headers[n]=t.headers[n];return e}}setHostPrefix(e,t,n){if(this.serdeContext?.disableHostPrefix)return;let r=L.of(t.input),i=j(t.traits??{});if(i.endpoint){let t=i.endpoint?.[0];if(typeof t==`string`){for(let[e,i]of r.structIterator()){if(!i.getMergedTraits().hostLabel)continue;let r=n[e];if(typeof r!=`string`)throw Error(`@smithy/core/schema - ${e} in input must be a string as hostLabel.`);t=t.replace(`{${e}}`,r)}if(e.hostname=t+e.hostname,!ve(e.hostname))throw Error(`[${e.hostname}] is not a valid hostname.`)}}}deserializeMetadata(e){return{httpStatusCode:e.statusCode,requestId:e.headers[`x-amzn-requestid`]??e.headers[`x-amzn-request-id`]??e.headers[`x-amz-request-id`],extendedRequestId:e.headers[`x-amz-id-2`],cfId:e.headers[`x-amz-cf-id`]}}async serializeEventStream({eventStream:e,requestSchema:t,initialRequest:n}){return(await this.loadEventStreamCapability()).serializeEventStream({eventStream:e,requestSchema:t,initialRequest:n})}async deserializeEventStream({response:e,responseSchema:t,initialResponseContainer:n}){return(await this.loadEventStreamCapability()).deserializeEventStream({response:e,responseSchema:t,initialResponseContainer:n})}async loadEventStreamCapability(){let{EventStreamSerde:e,eventStreamSerdeProvider:t}=await import(`./event-streams-C0Zy0Uqv.js`);return new e({marshaller:this.resolveEventStreamMarshaller(t),serializer:this.serializer,deserializer:this.deserializer,serdeContext:this.serdeContext,defaultContentType:this.getDefaultContentType()})}resolveEventStreamMarshaller(e){let t=this.serdeContext;return t.eventStreamMarshaller?t.eventStreamMarshaller:e(this.serdeContext)}getDefaultContentType(){throw Error(`@smithy/core/protocols - ${this.constructor.name} getDefaultContentType() implementation missing.`)}async deserializeHttpMessage(e,t,n,r,i){return[]}getEventStreamMarshaller(){let e=this.serdeContext;if(!e.eventStreamMarshaller)throw Error(`@smithy/core - HttpProtocol: eventStreamMarshaller missing in serdeContext.`);return e.eventStreamMarshaller}}})),Re,ze=e((()=>{B(),m(),T(),J(),H(),W(),Re=class extends q{async serializeRequest(e,t,n){let r=t&&typeof t==`object`?t:{},i=this.serializer,a={},o={},s=await n.endpoint(),c=L.of(e?.input),l=[],u=[],d=!1,f,p=new y({protocol:``,hostname:``,port:void 0,path:``,fragment:void 0,query:a,headers:o,body:void 0});if(s){this.updateServiceEndpoint(p,s),this.setHostPrefix(p,e,r);let t=j(e.traits);if(t.http){p.method=t.http[0];let[e,n]=t.http[1].split(`?`);p.path==`/`?p.path=e:p.path+=e;let r=new URLSearchParams(n??``);for(let[e,t]of r)a[e]=t}}for(let[e,t]of c.structIterator()){let n=t.getMergedTraits()??{},s=r[e];if(s==null&&!t.isIdempotencyToken()){if(n.httpLabel&&(p.path.includes(`{${e}+}`)||p.path.includes(`{${e}}`)))throw Error(`No value provided for input HTTP label: ${e}.`);continue}if(n.httpPayload)t.isStreaming()?t.isStructSchema()?r[e]&&(f=await this.serializeEventStream({eventStream:r[e],requestSchema:c})):f=s:(i.write(t,s),f=i.flush());else if(n.httpLabel){i.write(t,s);let n=i.flush();p.path.includes(`{${e}+}`)?p.path=p.path.replace(`{${e}+}`,n.split(`/`).map(U).join(`/`)):p.path.includes(`{${e}}`)&&(p.path=p.path.replace(`{${e}}`,U(n)))}else if(n.httpHeader)i.write(t,s),o[n.httpHeader.toLowerCase()]=String(i.flush());else if(typeof n.httpPrefixHeaders==`string`)for(let e in s){let r=s[e],a=n.httpPrefixHeaders+e;i.write([t.getValueSchema(),{httpHeader:a}],r),o[a.toLowerCase()]=i.flush()}else n.httpQuery||n.httpQueryParams?this.serializeQuery(t,s,a):(d=!0,l.push(e),u.push(t))}if(d&&r){let[e,t]=(c.getName(!0)??`#Unknown`).split(`#`),n=c.getSchema()[6],a=[3,e,t,c.getMergedTraits(),l,u,void 0];n?a[6]=n:a.pop(),i.write(a,r),f=i.flush()}return p.headers=o,p.query=a,p.body=f,p}serializeQuery(e,t,n){let r=this.serializer,i=e.getMergedTraits();if(i.httpQueryParams){for(let r in t)if(!(r in n)){let a=t[r],o=e.getValueSchema();Object.assign(o.getMergedTraits(),{...i,httpQuery:r,httpQueryParams:void 0}),this.serializeQuery(o,a,n)}return}if(e.isListSchema()){let a=!!e.getMergedTraits().sparse,o=[];for(let n of t){r.write([e.getValueSchema(),i],n);let t=r.flush();(a||t!==void 0)&&o.push(t)}n[i.httpQuery]=o}else r.write([e,i],t),n[i.httpQuery]=r.flush()}async deserializeResponse(e,t,n){let r=this.deserializer,i=L.of(e.output),a={};if(n.statusCode>=300){let i=await V(n.body,t);throw i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n)),Error(`@smithy/core/protocols - HTTP Protocol error handler failed to throw.`)}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=await this.deserializeHttpMessage(i,t,n,a);if(o.length){let e=await V(n.body,t);if(e.byteLength>0){let t=await r.read(i,e);for(let e of o)t[e]!=null&&(a[e]=t[e])}}else o.discardResponseBody&&await V(n.body,t);return a.$metadata=this.deserializeMetadata(n),a}async deserializeHttpMessage(e,t,n,r,i){let a;a=r instanceof Set?i:r;let o=!0,s=this.deserializer,c=L.of(e),l=[];for(let[e,r]of c.structIterator()){let i=r.getMemberTraits();if(i.httpPayload){if(o=!1,r.isStreaming())r.isStructSchema()?a[e]=await this.deserializeEventStream({response:n,responseSchema:c}):a[e]=p(n.body);else if(n.body){let i=await V(n.body,t);i.byteLength>0&&(a[e]=await s.read(r,i))}}else if(i.httpHeader){let t=String(i.httpHeader).toLowerCase(),o=n.headers[t];if(o!=null)if(r.isListSchema()){let n=r.getValueSchema();n.getMergedTraits().httpHeader=t;let i;i=n.isTimestampSchema()&&n.getSchema()===4?ne(o,`,`,2):re(o);let c=[];for(let e of i)c.push(await s.read(n,e.trim()));a[e]=c}else a[e]=await s.read(r,o)}else if(i.httpPrefixHeaders!==void 0){a[e]={};for(let t in n.headers)if(t.startsWith(i.httpPrefixHeaders)){let o=n.headers[t],c=r.getValueSchema();c.getMergedTraits().httpHeader=t,a[e][t.slice(i.httpPrefixHeaders.length)]=await s.read(c,o)}}else i.httpResponseCode?a[e]=n.statusCode:l.push(e)}return l.discardResponseBody=o,l}}})),Be,Ve=e((()=>{B(),T(),J(),H(),Be=class extends q{async serializeRequest(e,t,n){let r=this.serializer,i={},a={},o=await n.endpoint(),s=L.of(e?.input),c=s.getSchema(),l,u=t&&typeof t==`object`?t:{},d=new y({protocol:``,hostname:``,port:void 0,path:`/`,fragment:void 0,query:i,headers:a,body:void 0});if(o&&(this.updateServiceEndpoint(d,o),this.setHostPrefix(d,e,u)),u){let e=s.getEventStreamMember();if(e){if(u[e]){let t={};for(let[n,i]of s.structIterator())n!==e&&u[n]&&(r.write(i,u[n]),t[n]=r.flush());l=await this.serializeEventStream({eventStream:u[e],requestSchema:s,initialRequest:t})}}else r.write(c,u),l=r.flush()}return d.headers=Object.assign(d.headers,a),d.query=i,d.body=l,d.method=`POST`,d}async deserializeResponse(e,t,n){let r=this.deserializer,i=L.of(e.output),a={};if(n.statusCode>=300){let i=await V(n.body,t);throw i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n)),Error(`@smithy/core/protocols - RPC Protocol error handler failed to throw.`)}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=i.getEventStreamMember();if(o)a[o]=await this.deserializeEventStream({response:n,responseSchema:i,initialResponseContainer:a});else{let e=await V(n.body,t);e.byteLength>0&&Object.assign(a,await r.read(i,e))}return a.$metadata=this.deserializeMetadata(n),a}}}));function Y(e,t){if(t.timestampFormat.useTrait&&e.isTimestampSchema()&&(e.getSchema()===5||e.getSchema()===6||e.getSchema()===7))return e.getSchema();let{httpLabel:n,httpPrefixHeaders:r,httpHeader:i,httpQuery:a}=e.getMergedTraits();return(t.httpBindings?typeof r==`string`||i?6:a||n?5:void 0:void 0)??t.timestampFormat.default}var X=e((()=>{})),Z,Q=e((()=>{B(),m(),K(),X(),t(),Z=class extends G{constructor(e){super(),n(this,`settings`,void 0),this.settings=e}read(e,t){let n=L.of(e);if(n.isListSchema())return re(t).map(e=>this.read(n.getValueSchema(),e));if(n.isBlobSchema())return(this.serdeContext?.base64Decoder??s)(t);if(n.isTimestampSchema())switch(Y(n,this.settings)){case 5:return a(t);case 6:return te(t);case 7:return u(t);default:return console.warn(`Missing timestamp format, parsing value with Date constructor:`,t),new Date(t)}if(n.isStringSchema()){let e=n.getMergedTraits().mediaType,r=t;if(e)return n.getMergedTraits().httpHeader&&(r=this.base64ToUtf8(r)),(e===`application/json`||e.endsWith(`+json`))&&(r=l.from(r)),r}return n.isNumericSchema()?Number(t):n.isBigIntegerSchema()?BigInt(t):n.isBigDecimalSchema()?new d(t,`bigDecimal`):n.isBooleanSchema()?String(t).toLowerCase()===`true`:t}base64ToUtf8(e){return(this.serdeContext?.utf8Encoder??c)((this.serdeContext?.base64Decoder??s)(e))}}})),He,Ue=e((()=>{B(),m(),K(),Q(),t(),He=class extends G{constructor(e,t){super(),n(this,`codecDeserializer`,void 0),n(this,`stringDeserializer`,void 0),this.codecDeserializer=e,this.stringDeserializer=new Z(t)}setSerdeContext(e){this.stringDeserializer.setSerdeContext(e),this.codecDeserializer.setSerdeContext(e),this.serdeContext=e}read(e,t){let n=L.of(e),r=n.getMergedTraits(),a=this.serdeContext?.utf8Encoder??c;if(r.httpHeader||r.httpResponseCode)return this.stringDeserializer.read(n,a(t));if(r.httpPayload){if(n.isBlobSchema()){let e=this.serdeContext?.utf8Decoder??i;return typeof t==`string`?e(t):t}else if(n.isStringSchema())return`byteLength`in t?a(t):t}return this.codecDeserializer.read(n,t)}}})),We,Ge=e((()=>{B(),m(),K(),X(),t(),We=class extends G{constructor(e){super(),n(this,`settings`,void 0),n(this,`stringBuffer`,``),this.settings=e}write(e,t){let n=L.of(e);switch(typeof t){case`object`:if(t===null){this.stringBuffer=`null`;return}if(n.isTimestampSchema()){if(!(t instanceof Date))throw Error(`@smithy/core/protocols - received non-Date value ${t} when schema expected Date in ${n.getName(!0)}`);switch(Y(n,this.settings)){case 5:this.stringBuffer=t.toISOString().replace(`.000Z`,`Z`);break;case 6:this.stringBuffer=r(t);break;case 7:this.stringBuffer=String(t.getTime()/1e3);break;default:console.warn(`Missing timestamp format, using epoch seconds`,t),this.stringBuffer=String(t.getTime()/1e3)}return}if(n.isBlobSchema()&&`byteLength`in t){this.stringBuffer=(this.serdeContext?.base64Encoder??ie)(t);return}if(n.isListSchema()&&Array.isArray(t)){let e=``;for(let r of t){this.write([n.getValueSchema(),n.getMergedTraits()],r);let t=this.flush(),i=n.getValueSchema().isTimestampSchema()?t:o(t);e!==``&&(e+=`, `),e+=i}this.stringBuffer=e;return}this.stringBuffer=JSON.stringify(t,null,2);break;case`string`:let e=n.getMergedTraits().mediaType,i=t;if(e&&((e===`application/json`||e.endsWith(`+json`))&&(i=l.from(i)),n.getMergedTraits().httpHeader)){this.stringBuffer=(this.serdeContext?.base64Encoder??ie)(i.toString());return}this.stringBuffer=t;break;default:n.isIdempotencyToken()?this.stringBuffer=f():this.stringBuffer=String(t)}}flush(){let e=this.stringBuffer;return this.stringBuffer=``,e}}})),Ke,qe=e((()=>{B(),Ge(),t(),Ke=class{constructor(e,t,r=new We(t)){n(this,`codecSerializer`,void 0),n(this,`stringSerializer`,void 0),n(this,`buffer`,void 0),this.codecSerializer=e,this.stringSerializer=r}setSerdeContext(e){this.codecSerializer.setSerdeContext(e),this.stringSerializer.setSerdeContext(e)}write(e,t){let n=L.of(e),r=n.getMergedTraits();if(r.httpHeader||r.httpLabel||r.httpQuery){this.stringSerializer.write(n,t),this.buffer=this.stringSerializer.flush();return}return this.codecSerializer.write(n,t)}flush(){if(this.buffer!==void 0){let e=this.buffer;return this.buffer=void 0,e}return this.codecSerializer.flush()}}})),Je,Ye,Xe=e((()=>{Je=e=>({setHttpHandler(t){e.httpHandler=t},httpHandler(){return e.httpHandler},updateHttpClientConfig(t,n){e.httpHandler?.updateHttpClientConfig(t,n)},httpHandlerConfigs(){return e.httpHandler.httpHandlerConfigs()}}),Ye=e=>({httpHandler:e.httpHandler()})}));function Ze(e){return t=>async n=>{let r=n.request;if(y.isInstance(r)){let{body:t,headers:n}=r;if(t&&Object.keys(n).map(e=>e.toLowerCase()).indexOf(Qe)===-1)try{let n=e(t);r.headers={...r.headers,[Qe]:String(n)}}catch{}}return t({...n,request:r})}}var Qe,$e,et,tt=e((()=>{T(),Qe=`content-length`,$e={step:`build`,tags:[`SET_CONTENT_LENGTH`,`CONTENT_LENGTH`],name:`contentLengthMiddleware`,override:!0},et=e=>({applyToStack:t=>{t.add(Ze(e.bodyLengthChecker),$e)}})})),$,nt,rt=e((()=>{$=e=>encodeURIComponent(e).replace(/[!'()*]/g,nt),nt=e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`}));function it(e){let t=[];for(let n of Object.keys(e).sort()){let r=e[n];if(n=$(n),Array.isArray(r))for(let e=0,i=r.length;e<i;e++)t.push(`${n}=${$(r[e])}`);else{let e=n;(r||typeof r==`string`)&&(e+=`=${$(r)}`),t.push(e)}}return t.join(`&`)}var at=e((()=>{rt()})),ot=e((()=>{H(),W(),ze(),J(),Ve(),T(),Q(),Ue(),qe(),Ge(),X(),K(),de(),Xe(),tt(),rt(),at()}));export{ue as $,L as A,S as B,U as C,B as D,H as E,D as F,b as G,be as H,T as I,me as J,he as K,we as L,ke as M,Me as N,z as O,E as P,_ as Q,w as R,ze as S,V as T,_e as U,xe as V,x as W,fe as X,v as Y,de as Z,Y as _,rt as a,ae as at,Ve as b,Je as c,Ke as d,ce as et,qe as f,Q as g,Z as h,$ as i,h as it,Ie as j,Le as k,Xe as l,Ue as m,it as n,g as nt,et as o,He as p,y as q,at as r,oe as rt,tt as s,ot as t,le as tt,Ye as u,X as v,W as w,Re as x,Be as y,C as z};