@stacksjs/buddy 0.66.0 → 0.68.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (296) hide show
  1. package/dist/add.d.ts +4 -0
  2. package/dist/build.d.ts +4 -0
  3. package/dist/changelog.d.ts +3 -0
  4. package/dist/chunk-06g79v9j.js +2 -0
  5. package/dist/chunk-08bm2xax.js +2 -0
  6. package/dist/chunk-0enrsn65.js +978 -0
  7. package/dist/chunk-0m218zhk.js +2 -0
  8. package/dist/chunk-0q0jn0kk.js +6 -0
  9. package/dist/chunk-0yyhz107.js +2 -0
  10. package/dist/chunk-11vhe2za.js +2 -0
  11. package/dist/chunk-13143jmy.js +3 -0
  12. package/dist/chunk-1agj4qty.js +2 -0
  13. package/dist/chunk-1c4yywmn.js +9 -0
  14. package/dist/chunk-1e2f0z80.js +2 -0
  15. package/dist/chunk-1v13dkfw.js +2 -0
  16. package/dist/chunk-20e0mpcw.js +9 -0
  17. package/dist/chunk-25nxsybw.js +2 -0
  18. package/dist/chunk-27ksm11g.js +2 -0
  19. package/dist/chunk-2mhj5ght.js +2 -0
  20. package/dist/chunk-2wrs9p57.js +1 -0
  21. package/dist/chunk-2yj4j69j.js +2 -0
  22. package/dist/chunk-2ymn50ck.js +2 -0
  23. package/dist/chunk-3vjfkr7v.js +978 -0
  24. package/dist/{chunk-3zx3yk1m.js → chunk-3wpw5xgd.js} +1 -4
  25. package/dist/chunk-3y0gapf6.js +2 -0
  26. package/dist/chunk-4rb5r88h.js +978 -0
  27. package/dist/chunk-4wb68jfr.js +2 -0
  28. package/dist/chunk-5ewcj9vd.js +2 -0
  29. package/dist/chunk-5fm9mfqs.js +2 -0
  30. package/dist/chunk-5jhkn5by.js +2 -0
  31. package/dist/chunk-5m9xts4v.js +2 -0
  32. package/dist/chunk-6sqy7049.js +2 -0
  33. package/dist/chunk-6yazdvb4.js +2 -0
  34. package/dist/chunk-746p83dw.js +2 -0
  35. package/dist/chunk-76g7tr80.js +2 -0
  36. package/dist/chunk-7fz1p8p3.js +10 -0
  37. package/dist/chunk-814adsn3.js +2 -0
  38. package/dist/chunk-831wk0b3.js +2 -0
  39. package/dist/chunk-833tanrb.js +2 -0
  40. package/dist/chunk-8cx90pvv.js +2 -0
  41. package/dist/chunk-8gx9at51.js +1 -0
  42. package/dist/chunk-91pnyybg.js +9 -0
  43. package/dist/chunk-99syj1p0.js +2 -0
  44. package/dist/chunk-9bxh78vd.js +5 -0
  45. package/dist/chunk-9jaqey2q.js +2 -0
  46. package/dist/chunk-9tyaew40.js +2 -0
  47. package/dist/chunk-9zcyq5gh.js +2 -0
  48. package/dist/chunk-a4g1e1n0.js +2 -0
  49. package/dist/chunk-a6g2jk1y.js +2 -0
  50. package/dist/chunk-aaqd43t5.js +2 -0
  51. package/dist/chunk-adswb3gq.js +2 -0
  52. package/dist/chunk-atnw2cq3.js +2 -0
  53. package/dist/chunk-avdharmq.js +2 -0
  54. package/dist/chunk-b13gbfg3.js +2 -0
  55. package/dist/chunk-b3wr7cpk.js +2 -0
  56. package/dist/chunk-bngyck4v.js +2 -0
  57. package/dist/chunk-brb5zthb.js +1 -0
  58. package/dist/chunk-bx2vf8g7.js +5 -0
  59. package/dist/chunk-c343n0yt.js +2 -0
  60. package/dist/chunk-cdwpqzrw.js +2 -0
  61. package/dist/chunk-cm7bwdk9.js +2 -0
  62. package/dist/chunk-cs5k02gt.js +1 -0
  63. package/dist/chunk-cv8f2v27.js +2 -0
  64. package/dist/chunk-d2dbhn2h.js +2 -0
  65. package/dist/chunk-d3awsfqm.js +9 -0
  66. package/dist/chunk-d9q17hb8.js +2 -0
  67. package/dist/chunk-dw62d69f.js +2 -0
  68. package/dist/chunk-e8p8v7ca.js +978 -0
  69. package/dist/chunk-ehhrhkwe.js +9 -0
  70. package/dist/chunk-enhf12a1.js +2 -0
  71. package/dist/chunk-f0ksrase.js +8 -0
  72. package/dist/chunk-f2d9w3nr.js +2 -0
  73. package/dist/chunk-f3y73e4b.js +6 -0
  74. package/dist/chunk-fe3xb8z9.js +2 -0
  75. package/dist/chunk-fg5gh4dn.js +2 -0
  76. package/dist/chunk-fh4rw8kr.js +5 -0
  77. package/dist/chunk-fxsv4p5c.js +8 -0
  78. package/dist/chunk-gg80s18j.js +2 -0
  79. package/dist/chunk-h5saw32v.js +2 -0
  80. package/dist/chunk-ha75r57f.js +8 -0
  81. package/dist/chunk-hgrs6wcy.js +2 -0
  82. package/dist/chunk-hrsat16n.js +8 -0
  83. package/dist/chunk-hxy5t7tm.js +10 -0
  84. package/dist/chunk-hzfqtj82.js +2 -0
  85. package/dist/chunk-j2n86dsz.js +2 -0
  86. package/dist/chunk-jg68fsnk.js +10 -0
  87. package/dist/chunk-jhvjhf1j.js +2 -0
  88. package/dist/chunk-jr4naxsv.js +2 -0
  89. package/dist/chunk-jtax0mpm.js +2 -0
  90. package/dist/chunk-k59kbbvm.js +2 -0
  91. package/dist/chunk-kanz993c.js +2 -0
  92. package/dist/chunk-kg9abatp.js +2 -0
  93. package/dist/chunk-kvghsjg7.js +5 -0
  94. package/dist/chunk-ky8p46ae.js +5 -0
  95. package/dist/chunk-kzm498bh.js +2 -0
  96. package/dist/chunk-m4gwjnfh.js +6 -0
  97. package/dist/chunk-msv6dcc2.js +2 -0
  98. package/dist/chunk-mxdajhb4.js +10 -0
  99. package/dist/chunk-mxzjn2gs.js +978 -0
  100. package/dist/chunk-n1bqkqk7.js +10 -0
  101. package/dist/chunk-njtyervf.js +1 -0
  102. package/dist/chunk-nx1598yr.js +2 -0
  103. package/dist/chunk-p18kqenr.js +1 -0
  104. package/dist/chunk-p23aswbf.js +2 -0
  105. package/dist/chunk-p55ntqj0.js +2 -0
  106. package/dist/chunk-p5va3trj.js +2 -0
  107. package/dist/chunk-p88bsqtc.js +10 -0
  108. package/dist/chunk-p9z7f8c8.js +2 -0
  109. package/dist/chunk-ppkzf21q.js +8 -0
  110. package/dist/chunk-prqq5zw2.js +2 -0
  111. package/dist/chunk-pv6hp18q.js +10 -0
  112. package/dist/chunk-q9ycfthp.js +2 -0
  113. package/dist/chunk-qhcx6dmf.js +2 -0
  114. package/dist/chunk-qma4ysd8.js +9 -0
  115. package/dist/chunk-qqp394c2.js +2 -0
  116. package/dist/chunk-ra5sfgg4.js +2 -0
  117. package/dist/chunk-rfd43z7p.js +5 -0
  118. package/dist/chunk-s2n3hw0a.js +2 -0
  119. package/dist/chunk-sm7vvfqf.js +2 -0
  120. package/dist/chunk-sqbdav33.js +2 -0
  121. package/dist/chunk-sy4d4hnx.js +2 -0
  122. package/dist/chunk-t0b356bb.js +978 -0
  123. package/dist/chunk-t9wdnzz4.js +6 -0
  124. package/dist/chunk-v25g7h01.js +2 -0
  125. package/dist/chunk-v7zy7xda.js +1 -0
  126. package/dist/chunk-vg4vfkzk.js +6 -0
  127. package/dist/chunk-vgcre8jy.js +2 -0
  128. package/dist/chunk-vqyngnj0.js +9 -0
  129. package/dist/chunk-w17d2rbd.js +6 -0
  130. package/dist/chunk-x22v9kvb.js +2 -0
  131. package/dist/chunk-xacjs4ar.js +6 -0
  132. package/dist/chunk-xmdbxa8w.js +1 -0
  133. package/dist/chunk-xy6hjazn.js +978 -0
  134. package/dist/chunk-y0m35t3m.js +2 -0
  135. package/dist/chunk-y1tre8v8.js +8 -0
  136. package/dist/chunk-y50mc7dt.js +2 -0
  137. package/dist/chunk-y93ke5m6.js +2 -0
  138. package/dist/chunk-yktee4wv.js +1 -0
  139. package/dist/chunk-yvmyw2r2.js +2 -0
  140. package/dist/chunk-z1h35hsa.js +2 -0
  141. package/dist/chunk-z6xydw90.js +2 -0
  142. package/dist/chunk-zak32nab.js +2 -0
  143. package/dist/clean.d.ts +3 -0
  144. package/dist/cli.d.ts +4 -1
  145. package/dist/cli.js +1 -4
  146. package/dist/cloud.d.ts +3 -0
  147. package/dist/commit.d.ts +3 -0
  148. package/dist/configure.d.ts +4 -0
  149. package/dist/create.d.ts +8 -0
  150. package/dist/custom-cli.d.ts +1 -1
  151. package/dist/deploy.d.ts +7 -0
  152. package/dist/{commands/dev.d.ts → dev.d.ts} +3 -1
  153. package/dist/dns.d.ts +18 -0
  154. package/dist/domains.d.ts +3 -0
  155. package/dist/fresh.d.ts +3 -0
  156. package/dist/generate.d.ts +3 -0
  157. package/dist/http.d.ts +6 -0
  158. package/dist/index.d.ts +1 -1
  159. package/dist/index.js +1 -4
  160. package/dist/install.d.ts +3 -0
  161. package/dist/key.d.ts +3 -0
  162. package/dist/lint.d.ts +3 -0
  163. package/dist/list.d.ts +3 -0
  164. package/dist/make.d.ts +1 -0
  165. package/dist/migrate.d.ts +3 -0
  166. package/dist/outdated.d.ts +3 -0
  167. package/dist/ports.d.ts +7 -0
  168. package/dist/prepublish.d.ts +3 -0
  169. package/dist/projects.d.ts +3 -0
  170. package/dist/release.d.ts +9 -0
  171. package/dist/route.d.ts +3 -0
  172. package/dist/saas.d.ts +3 -0
  173. package/dist/seed.d.ts +3 -0
  174. package/dist/setup.d.ts +8 -0
  175. package/dist/stacks +0 -0
  176. package/dist/test.d.ts +3 -0
  177. package/dist/tinker.d.ts +3 -0
  178. package/dist/types.d.ts +3 -0
  179. package/dist/upgrade.d.ts +4 -0
  180. package/dist/version.d.ts +3 -0
  181. package/package.json +48 -49
  182. package/dist/chunk-3cfvbq6w.js +0 -5
  183. package/dist/chunk-3cfvbq6w.js.map +0 -32
  184. package/dist/chunk-3v3h2zkp.js +0 -5
  185. package/dist/chunk-3v3h2zkp.js.map +0 -46
  186. package/dist/chunk-3zx3yk1m.js.map +0 -15
  187. package/dist/chunk-8a487snn.js +0 -5
  188. package/dist/chunk-8a487snn.js.map +0 -9
  189. package/dist/chunk-9kkf5maz.js +0 -5
  190. package/dist/chunk-9kkf5maz.js.map +0 -23
  191. package/dist/chunk-9qba8jdt.js +0 -12
  192. package/dist/chunk-9qba8jdt.js.map +0 -11
  193. package/dist/chunk-cvpb67bs.js +0 -5
  194. package/dist/chunk-cvpb67bs.js.map +0 -10
  195. package/dist/chunk-eqwfdbyk.js +0 -5
  196. package/dist/chunk-eqwfdbyk.js.map +0 -17
  197. package/dist/chunk-f41k7dpa.js +0 -5
  198. package/dist/chunk-f41k7dpa.js.map +0 -11
  199. package/dist/chunk-fx1zxxxa.js +0 -9
  200. package/dist/chunk-fx1zxxxa.js.map +0 -13
  201. package/dist/chunk-get5gzkc.js +0 -11
  202. package/dist/chunk-get5gzkc.js.map +0 -10
  203. package/dist/chunk-m43npkjw.js +0 -5
  204. package/dist/chunk-m43npkjw.js.map +0 -12
  205. package/dist/chunk-mrrgcavv.js +0 -831
  206. package/dist/chunk-mrrgcavv.js.map +0 -240
  207. package/dist/chunk-n5y0mrsg.js +0 -15
  208. package/dist/chunk-n5y0mrsg.js.map +0 -173
  209. package/dist/chunk-qebxvzqz.js +0 -5
  210. package/dist/chunk-qebxvzqz.js.map +0 -26
  211. package/dist/chunk-qj2v5psd.js +0 -5
  212. package/dist/chunk-qj2v5psd.js.map +0 -20
  213. package/dist/chunk-rh4brnzh.js +0 -5
  214. package/dist/chunk-rh4brnzh.js.map +0 -16
  215. package/dist/chunk-w2vwjv6k.js +0 -6
  216. package/dist/chunk-w2vwjv6k.js.map +0 -57
  217. package/dist/chunk-w81rbh65.js +0 -5
  218. package/dist/chunk-w81rbh65.js.map +0 -10
  219. package/dist/chunk-wayp5kn2.js +0 -5
  220. package/dist/chunk-wayp5kn2.js.map +0 -22
  221. package/dist/chunk-x5c5ngpb.js +0 -4
  222. package/dist/chunk-x5c5ngpb.js.map +0 -23
  223. package/dist/cli.js.map +0 -10
  224. package/dist/commands/add.d.ts +0 -2
  225. package/dist/commands/build.d.ts +0 -2
  226. package/dist/commands/changelog.d.ts +0 -2
  227. package/dist/commands/clean.d.ts +0 -2
  228. package/dist/commands/cloud.d.ts +0 -2
  229. package/dist/commands/commit.d.ts +0 -2
  230. package/dist/commands/configure.d.ts +0 -2
  231. package/dist/commands/create.d.ts +0 -2
  232. package/dist/commands/deploy.d.ts +0 -2
  233. package/dist/commands/dns.d.ts +0 -2
  234. package/dist/commands/domains.d.ts +0 -2
  235. package/dist/commands/fresh.d.ts +0 -2
  236. package/dist/commands/generate.d.ts +0 -2
  237. package/dist/commands/http.d.ts +0 -2
  238. package/dist/commands/index.d.ts +0 -33
  239. package/dist/commands/install.d.ts +0 -2
  240. package/dist/commands/key.d.ts +0 -2
  241. package/dist/commands/lint.d.ts +0 -2
  242. package/dist/commands/list.d.ts +0 -2
  243. package/dist/commands/make.d.ts +0 -2
  244. package/dist/commands/migrate.d.ts +0 -2
  245. package/dist/commands/outdated.d.ts +0 -2
  246. package/dist/commands/ports.d.ts +0 -2
  247. package/dist/commands/prepublish.d.ts +0 -2
  248. package/dist/commands/projects.d.ts +0 -2
  249. package/dist/commands/release.d.ts +0 -2
  250. package/dist/commands/route.d.ts +0 -2
  251. package/dist/commands/seed.d.ts +0 -2
  252. package/dist/commands/setup.d.ts +0 -4
  253. package/dist/commands/test.d.ts +0 -2
  254. package/dist/commands/tinker.d.ts +0 -2
  255. package/dist/commands/types.d.ts +0 -2
  256. package/dist/commands/upgrade.d.ts +0 -2
  257. package/dist/commands/version.d.ts +0 -2
  258. package/dist/index.js.map +0 -9
  259. package/src/cli.ts +0 -105
  260. package/src/commands/add.ts +0 -71
  261. package/src/commands/build.ts +0 -299
  262. package/src/commands/changelog.ts +0 -52
  263. package/src/commands/clean.ts +0 -46
  264. package/src/commands/cloud.ts +0 -553
  265. package/src/commands/commit.ts +0 -26
  266. package/src/commands/configure.ts +0 -84
  267. package/src/commands/create.ts +0 -143
  268. package/src/commands/deploy.ts +0 -194
  269. package/src/commands/dev.ts +0 -292
  270. package/src/commands/dns.ts +0 -86
  271. package/src/commands/domains.ts +0 -255
  272. package/src/commands/fresh.ts +0 -48
  273. package/src/commands/generate.ts +0 -202
  274. package/src/commands/http.ts +0 -57
  275. package/src/commands/index.ts +0 -33
  276. package/src/commands/install.ts +0 -30
  277. package/src/commands/key.ts +0 -36
  278. package/src/commands/lint.ts +0 -54
  279. package/src/commands/list.ts +0 -42
  280. package/src/commands/make.ts +0 -352
  281. package/src/commands/migrate.ts +0 -105
  282. package/src/commands/outdated.ts +0 -31
  283. package/src/commands/ports.ts +0 -188
  284. package/src/commands/prepublish.ts +0 -28
  285. package/src/commands/projects.ts +0 -54
  286. package/src/commands/release.ts +0 -47
  287. package/src/commands/route.ts +0 -39
  288. package/src/commands/seed.ts +0 -47
  289. package/src/commands/setup.ts +0 -145
  290. package/src/commands/test.ts +0 -214
  291. package/src/commands/tinker.ts +0 -42
  292. package/src/commands/types.ts +0 -35
  293. package/src/commands/upgrade.ts +0 -200
  294. package/src/commands/version.ts +0 -29
  295. package/src/custom-cli.ts +0 -35
  296. package/src/index.ts +0 -1
@@ -0,0 +1,9 @@
1
+ import{kb as $}from"./chunk-xmdbxa8w.js";import{tb as w,ub as z,vb as B}from"./chunk-jr4naxsv.js";import{Ab as J,Cb as Z,yb as x}from"./chunk-yktee4wv.js";import{Db as q}from"./chunk-yvmyw2r2.js";var k="AWS_EC2_METADATA_DISABLED",X=async(b)=>{let{ENV_CMDS_FULL_URI:j,ENV_CMDS_RELATIVE_URI:y,fromContainerMetadata:G,fromInstanceMetadata:K}=await import("./chunk-cdwpqzrw.js");if(process.env[y]||process.env[j]){b.logger?.debug("@aws-sdk/credential-provider-node - remoteProvider::fromHttp/fromContainerMetadata");let{fromHttp:Q}=await import("./chunk-xacjs4ar.js");return J(Q(b),G(b))}if(process.env[k])return async()=>{throw new x("EC2 Instance Metadata Service access disabled",{logger:b.logger})};return b.logger?.debug("@aws-sdk/credential-provider-node - remoteProvider::fromInstanceMetadata"),K(b)};var Y=!1,A=(b={})=>Z(J(async()=>{if(b.profile??process.env[$]){if(process.env[w]&&process.env[z]){if(!Y)(b.logger?.warn&&b.logger?.constructor?.name!=="NoOpLogger"?b.logger.warn:console.warn)(`@aws-sdk/credential-provider-node - defaultProvider::fromEnv WARNING:
2
+ Multiple credential sources detected:
3
+ Both AWS_PROFILE and the pair AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY static credentials are set.
4
+ This SDK will proceed with the AWS_PROFILE value.
5
+
6
+ However, a future version may change this behavior to prefer the ENV static credentials.
7
+ Please ensure that your environment only sets either the AWS_PROFILE or the
8
+ AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY pair.
9
+ `),Y=!0}throw new x("AWS_PROFILE is set, skipping fromEnv provider.",{logger:b.logger,tryNextLink:!0})}return b.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromEnv"),B(b)()},async()=>{b.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromSSO");let{ssoStartUrl:j,ssoAccountId:y,ssoRegion:G,ssoRoleName:K,ssoSession:Q}=b;if(!j&&!y&&!G&&!K&&!Q)throw new x("Skipping SSO provider in default chain (inputs do not include SSO fields).",{logger:b.logger});let{fromSSO:H}=await import("./chunk-11vhe2za.js");return H(b)()},async()=>{b.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromIni");let{fromIni:j}=await import("./chunk-y50mc7dt.js");return j(b)()},async()=>{b.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromProcess");let{fromProcess:j}=await import("./chunk-zak32nab.js");return j(b)()},async()=>{b.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromTokenFile");let{fromTokenFile:j}=await import("./chunk-sqbdav33.js");return j(b)()},async()=>{return b.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::remoteProvider"),(await X(b))()},async()=>{throw new x("Could not load credentials from any providers",{tryNextLink:!1,logger:b.logger})}),O,v),v=(b)=>b?.expiration!==void 0,O=(b)=>b?.expiration!==void 0&&b.expiration.getTime()-Date.now()<300000;export{A as L};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{L as Vh}from"./chunk-vqyngnj0.js";import{$ as gl,M as Q0,N as X0,O as Y0,P as Z0,Q as Bw,R as $h,S as y0,T as Ml,U as Wl,V as Nl,W as Tl,X as Gh,Y as F0,Z as Cl,_ as Ol,aa as xl,ba as $0,ca as V0,da as B,ea as E,fa as v0,ga as il,ha as cl,ia as U0,ja as el,ka as q0,la as tl,ma as h0,na as Rl,oa as al,pa as l0,qa as w0,ra as sl,sa as rl,ta as G0,ua as K0,va as B0}from"./chunk-p88bsqtc.js";import{wa as f,xa as jl}from"./chunk-p55ntqj0.js";import{$a as D0,Aa as R0,Ja as P0,Ka as Q,La as Sh,Ma as ww,Pa as a0,Ra as S,Sa as u,Ua as s0,Va as z0,Wa as A,Xa as r0,Ya as pl,Za as ol,_a as nh,ab as k0,db as Ll,hb as nl,ib as ul,ya as m0,za as J0}from"./chunk-ky8p46ae.js";import"./chunk-njtyervf.js";import"./chunk-avdharmq.js";import"./chunk-vgcre8jy.js";import{vb as EG}from"./chunk-y1tre8v8.js";import"./chunk-v7zy7xda.js";import{Cb as M}from"./chunk-p9z7f8c8.js";var O=M($h(),1);var Hl=M(Gh(),1),Ih=M(Bw(),1);var Sl=async(h,w,l)=>{return{operation:Ih.getSmithyContext(w).operation,region:await Ih.normalizeProvider(h.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()}};function Ew(h){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sts",region:h.region},propertiesExtractor:(w,l)=>({signingProperties:{config:w,context:l}})}}function dl(h){return{schemeId:"smithy.api#noAuth"}}var ml=(h)=>{let w=[];switch(h.operation){case"AssumeRoleWithSAML":{w.push(dl(h));break}case"AssumeRoleWithWebIdentity":{w.push(dl(h));break}default:w.push(Ew(h))}return w},Qw=(h)=>({...h,stsClientCtor:j}),Jl=(h)=>{let w=Qw(h);return{...Hl.resolveAwsSdkSigV4Config(w)}};var Dl=(h)=>{return{...h,useDualstackEndpoint:h.useDualstackEndpoint??!1,useFipsEndpoint:h.useFipsEndpoint??!1,useGlobalEndpoint:h.useGlobalEndpoint??!1,defaultSigningName:"sts"}},D={UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};var kl={name:"@aws-sdk/client-sts",description:"AWS SDK for JavaScript Sts Client for Node.js, Browser and React Native",version:"3.679.0",scripts:{build:"concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline client-sts","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"rimraf ./dist-types tsconfig.types.tsbuildinfo && tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo","extract:docs":"api-extractor run --local","generate:client":"node ../../scripts/generate-clients/single-service --solo sts",test:"vitest run","test:watch":"vitest watch"},main:"./dist-cjs/index.js",types:"./dist-types/index.d.ts",module:"./dist-es/index.js",sideEffects:!1,dependencies:{"@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/client-sso-oidc":"3.679.0","@aws-sdk/core":"3.679.0","@aws-sdk/credential-provider-node":"3.679.0","@aws-sdk/middleware-host-header":"3.679.0","@aws-sdk/middleware-logger":"3.679.0","@aws-sdk/middleware-recursion-detection":"3.679.0","@aws-sdk/middleware-user-agent":"3.679.0","@aws-sdk/region-config-resolver":"3.679.0","@aws-sdk/types":"3.679.0","@aws-sdk/util-endpoints":"3.679.0","@aws-sdk/util-user-agent-browser":"3.679.0","@aws-sdk/util-user-agent-node":"3.679.0","@smithy/config-resolver":"^3.0.9","@smithy/core":"^2.4.8","@smithy/fetch-http-handler":"^3.2.9","@smithy/hash-node":"^3.0.7","@smithy/invalid-dependency":"^3.0.7","@smithy/middleware-content-length":"^3.0.9","@smithy/middleware-endpoint":"^3.1.4","@smithy/middleware-retry":"^3.0.23","@smithy/middleware-serde":"^3.0.7","@smithy/middleware-stack":"^3.0.7","@smithy/node-config-provider":"^3.1.8","@smithy/node-http-handler":"^3.2.4","@smithy/protocol-http":"^4.1.4","@smithy/smithy-client":"^3.4.0","@smithy/types":"^3.5.0","@smithy/url-parser":"^3.0.7","@smithy/util-base64":"^3.0.0","@smithy/util-body-length-browser":"^3.0.0","@smithy/util-body-length-node":"^3.0.0","@smithy/util-defaults-mode-browser":"^3.0.23","@smithy/util-defaults-mode-node":"^3.0.23","@smithy/util-endpoints":"^2.1.3","@smithy/util-middleware":"^3.0.7","@smithy/util-retry":"^3.0.7","@smithy/util-utf8":"^3.0.0",tslib:"^2.6.2"},devDependencies:{"@tsconfig/node16":"16.1.3","@types/node":"^16.18.96",concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~4.9.5"},engines:{node:">=16.0.0"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["dist-*/**"],author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",browser:{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.browser"},"react-native":{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.native"},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-sts",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"clients/client-sts"}};var dh=M(Gh(),1);var I0=M($h(),1);var _l=M(Gh(),1),bl=M($h(),1);var Kl={["required"]:!1,["type"]:"String"},Fh={["required"]:!0,default:!1,["type"]:"Boolean"},$l={["ref"]:"Endpoint"},Bl={["fn"]:"isSet",["argv"]:[{["ref"]:"Region"}]},J={["ref"]:"Region"},El={["fn"]:"aws.partition",["argv"]:[J],assign:"PartitionResult"},Vl={["ref"]:"UseFIPS"},vl={["ref"]:"UseDualStack"},k={url:"https://sts.amazonaws.com",properties:{authSchemes:[{name:"sigv4",signingName:"sts",signingRegion:"us-east-1"}]},headers:{}},F={},Ql={conditions:[{["fn"]:"stringEquals",["argv"]:[J,"aws-global"]}],["endpoint"]:k,["type"]:"endpoint"},Ul={["fn"]:"booleanEquals",["argv"]:[Vl,!0]},Pl={["fn"]:"booleanEquals",["argv"]:[vl,!0]},Xl={["fn"]:"getAttr",["argv"]:[{["ref"]:"PartitionResult"},"supportsFIPS"]},ql={["ref"]:"PartitionResult"},Yl={["fn"]:"booleanEquals",["argv"]:[!0,{["fn"]:"getAttr",["argv"]:[ql,"supportsDualStack"]}]},Zl=[{["fn"]:"isSet",["argv"]:[$l]}],yl=[Ul],Fl=[Pl],Yw={version:"1.0",parameters:{Region:Kl,UseDualStack:Fh,UseFIPS:Fh,Endpoint:Kl,UseGlobalEndpoint:Fh},rules:[{conditions:[{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseGlobalEndpoint"},!0]},{["fn"]:"not",["argv"]:Zl},Bl,El,{["fn"]:"booleanEquals",["argv"]:[Vl,!1]},{["fn"]:"booleanEquals",["argv"]:[vl,!1]}],rules:[{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-northeast-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-south-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-southeast-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-southeast-2"]}],endpoint:k,["type"]:"endpoint"},Ql,{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ca-central-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-central-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-north-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-west-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-west-2"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-west-3"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"sa-east-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-east-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-east-2"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-west-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-west-2"]}],endpoint:k,["type"]:"endpoint"},{endpoint:{url:"https://sts.{Region}.{PartitionResult#dnsSuffix}",properties:{authSchemes:[{name:"sigv4",signingName:"sts",signingRegion:"{Region}"}]},headers:F},["type"]:"endpoint"}],["type"]:"tree"},{conditions:Zl,rules:[{conditions:yl,error:"Invalid Configuration: FIPS and custom endpoint are not supported",["type"]:"error"},{conditions:Fl,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",["type"]:"error"},{endpoint:{url:$l,properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{conditions:[Bl],rules:[{conditions:[El],rules:[{conditions:[Ul,Pl],rules:[{conditions:[{["fn"]:"booleanEquals",["argv"]:[!0,Xl]},Yl],rules:[{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",["type"]:"error"}],["type"]:"tree"},{conditions:yl,rules:[{conditions:[{["fn"]:"booleanEquals",["argv"]:[Xl,!0]}],rules:[{conditions:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[ql,"name"]},"aws-us-gov"]}],endpoint:{url:"https://sts.{Region}.amazonaws.com",properties:F,headers:F},["type"]:"endpoint"},{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{error:"FIPS is enabled but this partition does not support FIPS",["type"]:"error"}],["type"]:"tree"},{conditions:Fl,rules:[{conditions:[Yl],rules:[{endpoint:{url:"https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{error:"DualStack is enabled but this partition does not support DualStack",["type"]:"error"}],["type"]:"tree"},Ql,{endpoint:{url:"https://sts.{Region}.{PartitionResult#dnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{error:"Invalid Configuration: Missing Region",["type"]:"error"}]},zl=Yw;var Zw=new Ml({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS","UseGlobalEndpoint"]}),Al=(h,w={})=>{return Zw.get(h,()=>Nl(zl,{endpointParams:h,logger:w.logger}))};Wl.aws=Tl;var fl=(h)=>{return{apiVersion:"2011-06-15",base64Decoder:h?.base64Decoder??sl,base64Encoder:h?.base64Encoder??rl,disableHostPrefix:h?.disableHostPrefix??!1,endpointProvider:h?.endpointProvider??Al,extensions:h?.extensions??[],httpAuthSchemeProvider:h?.httpAuthSchemeProvider??ml,httpAuthSchemes:h?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(w)=>w.getIdentityProvider("aws.auth#sigv4"),signer:new _l.AwsSdkSigV4Signer},{schemeId:"smithy.api#noAuth",identityProvider:(w)=>w.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new bl.NoAuthSigner}],logger:h?.logger??new Ll,serviceId:h?.serviceId??"STS",urlParser:h?.urlParser??jl,utf8Decoder:h?.utf8Decoder??Rl,utf8Encoder:h?.utf8Encoder??al}};var d0=(h)=>{ol(process.version);let w=G0(h),l=()=>w().then(pl),G=fl(h);return dh.emitWarningIfUnsupportedVersion(process.version),{...G,...h,runtime:"node",defaultsMode:w,bodyLengthChecker:h?.bodyLengthChecker??w0,credentialDefaultProvider:h?.credentialDefaultProvider??Vh,defaultUserAgentProvider:h?.defaultUserAgentProvider??tl({serviceId:G.serviceId,clientVersion:kl.version}),httpAuthSchemes:h?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(I)=>I.getIdentityProvider("aws.auth#sigv4")||(async(H)=>await Vh(H?.__config||{})()),signer:new dh.AwsSdkSigV4Signer},{schemeId:"smithy.api#noAuth",identityProvider:(I)=>I.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new I0.NoAuthSigner}],maxAttempts:h?.maxAttempts??f(cl),region:h?.region??f(gl,xl),requestHandler:nl.create(h?.requestHandler??l),retryMode:h?.retryMode??f({...el,default:async()=>(await l()).retryMode||il}),sha256:h?.sha256??l0.bind(null,"sha256"),streamCollector:h?.streamCollector??ul,useDualstackEndpoint:h?.useDualstackEndpoint??f(Cl),useFipsEndpoint:h?.useFipsEndpoint??f(Ol),userAgentAppId:h?.userAgentAppId??f(h0)}};var H0=(h)=>{let{httpAuthSchemes:w,httpAuthSchemeProvider:l,credentials:G}=h;return{setHttpAuthScheme(I){let H=w.findIndex((d)=>d.schemeId===I.schemeId);if(H===-1)w.push(I);else w.splice(H,1,I)},httpAuthSchemes(){return w},setHttpAuthSchemeProvider(I){l=I},httpAuthSchemeProvider(){return l},setCredentials(I){G=I},credentials(){return G}}},S0=(h)=>{return{httpAuthSchemes:h.httpAuthSchemes(),httpAuthSchemeProvider:h.httpAuthSchemeProvider(),credentials:h.credentials()}};var Hh=(h)=>h,E0=(h,w)=>{let l={...Hh(K0(h)),...Hh(D0(h)),...Hh(m0(h)),...Hh(H0(h))};return w.forEach((G)=>G.configure(l)),{...h,...B0(l),...k0(l),...J0(l),...S0(l)}};class j extends P0{constructor(...[h]){let w=d0(h||{}),l=Dl(w),G=y0(l),I=U0(G),H=$0(I),d=Q0(H),X=v0(d),z=Jl(X),P=E0(z,h?.extensions||[]);super(P);this.config=P,this.middlewareStack.use(F0(this.config)),this.middlewareStack.use(q0(this.config)),this.middlewareStack.use(V0(this.config)),this.middlewareStack.use(X0(this.config)),this.middlewareStack.use(Y0(this.config)),this.middlewareStack.use(Z0(this.config)),this.middlewareStack.use(O.getHttpAuthSchemeEndpointRuleSetPlugin(this.config,{httpAuthSchemeParametersProvider:Sl,identityProviderConfigProvider:async(C)=>new O.DefaultIdentityProviderConfig({"aws.auth#sigv4":C.credentials})})),this.middlewareStack.use(O.getHttpSigningPlugin(this.config))}destroy(){super.destroy()}}class y extends z0{constructor(h){super(h);Object.setPrototypeOf(this,y.prototype)}}class mh extends y{constructor(h){super({name:"ExpiredTokenException",$fault:"client",...h});this.name="ExpiredTokenException",this.$fault="client",Object.setPrototypeOf(this,mh.prototype)}}class Jh extends y{constructor(h){super({name:"MalformedPolicyDocumentException",$fault:"client",...h});this.name="MalformedPolicyDocumentException",this.$fault="client",Object.setPrototypeOf(this,Jh.prototype)}}class Dh extends y{constructor(h){super({name:"PackedPolicyTooLargeException",$fault:"client",...h});this.name="PackedPolicyTooLargeException",this.$fault="client",Object.setPrototypeOf(this,Dh.prototype)}}class kh extends y{constructor(h){super({name:"RegionDisabledException",$fault:"client",...h});this.name="RegionDisabledException",this.$fault="client",Object.setPrototypeOf(this,kh.prototype)}}class Kh extends y{constructor(h){super({name:"IDPRejectedClaimException",$fault:"client",...h});this.name="IDPRejectedClaimException",this.$fault="client",Object.setPrototypeOf(this,Kh.prototype)}}class Bh extends y{constructor(h){super({name:"InvalidIdentityTokenException",$fault:"client",...h});this.name="InvalidIdentityTokenException",this.$fault="client",Object.setPrototypeOf(this,Bh.prototype)}}class Eh extends y{constructor(h){super({name:"IDPCommunicationErrorException",$fault:"client",...h});this.name="IDPCommunicationErrorException",this.$fault="client",Object.setPrototypeOf(this,Eh.prototype)}}class Qh extends y{constructor(h){super({name:"InvalidAuthorizationMessageException",$fault:"client",...h});this.name="InvalidAuthorizationMessageException",this.$fault="client",Object.setPrototypeOf(this,Qh.prototype)}}var n=(h)=>({...h,...h.SecretAccessKey&&{SecretAccessKey:Sh}}),M0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),W0=(h)=>({...h,...h.SAMLAssertion&&{SAMLAssertion:Sh}}),N0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),T0=(h)=>({...h,...h.WebIdentityToken&&{WebIdentityToken:Sh}}),A0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),j0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),L0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}});var q=M(Gh(),1);var _0=async(h,w)=>{let l=a,G;return G=b({...zw(h,w),[r]:IG,[_]:s}),R(w,l,"/",void 0,G)},b0=async(h,w)=>{let l=a,G;return G=b({...Mw(h,w),[r]:dG,[_]:s}),R(w,l,"/",void 0,G)},f0=async(h,w)=>{let l=a,G;return G=b({...Ww(h,w),[r]:HG,[_]:s}),R(w,l,"/",void 0,G)},C0=async(h,w)=>{let l=a,G;return G=b({...Nw(h,w),[r]:SG,[_]:s}),R(w,l,"/",void 0,G)},O0=async(h,w)=>{let l=a,G;return G=b({...Tw(h,w),[r]:mG,[_]:s}),R(w,l,"/",void 0,G)},g0=async(h,w)=>{let l=a,G;return G=b({...Aw(h,w),[r]:JG,[_]:s}),R(w,l,"/",void 0,G)},x0=async(h,w)=>{let l=a,G;return G=b({...jw(h,w),[r]:DG,[_]:s}),R(w,l,"/",void 0,G)},i0=async(h,w)=>{let l=a,G;return G=b({...Lw(h,w),[r]:kG,[_]:s}),R(w,l,"/",void 0,G)},c0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=bw(l.AssumeRoleResult,w),{$metadata:K(h),...G}},e0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=fw(l.AssumeRoleWithSAMLResult,w),{$metadata:K(h),...G}},p0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=Cw(l.AssumeRoleWithWebIdentityResult,w),{$metadata:K(h),...G}},o0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=Ow(l.DecodeAuthorizationMessageResult,w),{$metadata:K(h),...G}},n0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=iw(l.GetAccessKeyInfoResult,w),{$metadata:K(h),...G}},u0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=cw(l.GetCallerIdentityResult,w),{$metadata:K(h),...G}},t0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=ew(l.GetFederationTokenResult,w),{$metadata:K(h),...G}},hw=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=pw(l.GetSessionTokenResult,w),{$metadata:K(h),...G}},L=async(h,w)=>{let l={...h,body:await q.parseXmlErrorBody(h.body,w)},G=KG(h,l.body);switch(G){case"ExpiredTokenException":case"com.amazonaws.sts#ExpiredTokenException":throw await yw(l,w);case"MalformedPolicyDocument":case"com.amazonaws.sts#MalformedPolicyDocumentException":throw await Uw(l,w);case"PackedPolicyTooLarge":case"com.amazonaws.sts#PackedPolicyTooLargeException":throw await Pw(l,w);case"RegionDisabledException":case"com.amazonaws.sts#RegionDisabledException":throw await qw(l,w);case"IDPRejectedClaim":case"com.amazonaws.sts#IDPRejectedClaimException":throw await $w(l,w);case"InvalidIdentityToken":case"com.amazonaws.sts#InvalidIdentityTokenException":throw await vw(l,w);case"IDPCommunicationError":case"com.amazonaws.sts#IDPCommunicationErrorException":throw await Fw(l,w);case"InvalidAuthorizationMessageException":case"com.amazonaws.sts#InvalidAuthorizationMessageException":throw await Vw(l,w);default:let I=l.body;return GG({output:h,parsedBody:I.Error,errorCode:G})}},yw=async(h,w)=>{let l=h.body,G=gw(l.Error,w),I=new mh({$metadata:K(h),...G});return A(I,l)},Fw=async(h,w)=>{let l=h.body,G=ow(l.Error,w),I=new Eh({$metadata:K(h),...G});return A(I,l)},$w=async(h,w)=>{let l=h.body,G=nw(l.Error,w),I=new Kh({$metadata:K(h),...G});return A(I,l)},Vw=async(h,w)=>{let l=h.body,G=uw(l.Error,w),I=new Qh({$metadata:K(h),...G});return A(I,l)},vw=async(h,w)=>{let l=h.body,G=tw(l.Error,w),I=new Bh({$metadata:K(h),...G});return A(I,l)},Uw=async(h,w)=>{let l=h.body,G=hG(l.Error,w),I=new Jh({$metadata:K(h),...G});return A(I,l)},Pw=async(h,w)=>{let l=h.body,G=lG(l.Error,w),I=new Dh({$metadata:K(h),...G});return A(I,l)},qw=async(h,w)=>{let l=h.body,G=wG(l.Error,w),I=new kh({$metadata:K(h),...G});return A(I,l)},zw=(h,w)=>{let l={};if(h[T]!=null)l[T]=h[T];if(h[c]!=null)l[c]=h[c];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[$]!=null)l[$]=h[$];if(h[Z]!=null)l[Z]=h[Z];if(h[p]!=null){let G=lw(h[p],w);if(h[p]?.length===0)l.Tags=[];Object.entries(G).forEach(([I,H])=>{let d=`Tags.${I}`;l[d]=H})}if(h[ih]!=null){let G=_w(h[ih],w);if(h[ih]?.length===0)l.TransitiveTagKeys=[];Object.entries(G).forEach(([I,H])=>{let d=`TransitiveTagKeys.${I}`;l[d]=H})}if(h[zh]!=null)l[zh]=h[zh];if(h[e]!=null)l[e]=h[e];if(h[o]!=null)l[o]=h[o];if(h[U]!=null)l[U]=h[U];if(h[sh]!=null){let G=sw(h[sh],w);if(h[sh]?.length===0)l.ProvidedContexts=[];Object.entries(G).forEach(([I,H])=>{let d=`ProvidedContexts.${I}`;l[d]=H})}return l},Mw=(h,w)=>{let l={};if(h[T]!=null)l[T]=h[T];if(h[Rh]!=null)l[Rh]=h[Rh];if(h[Ch]!=null)l[Ch]=h[Ch];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[$]!=null)l[$]=h[$];if(h[Z]!=null)l[Z]=h[Z];return l},Ww=(h,w)=>{let l={};if(h[T]!=null)l[T]=h[T];if(h[c]!=null)l[c]=h[c];if(h[ph]!=null)l[ph]=h[ph];if(h[rh]!=null)l[rh]=h[rh];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[$]!=null)l[$]=h[$];if(h[Z]!=null)l[Z]=h[Z];return l},Nw=(h,w)=>{let l={};if(h[Mh]!=null)l[Mh]=h[Mh];return l},Tw=(h,w)=>{let l={};if(h[g]!=null)l[g]=h[g];return l},Aw=(h,w)=>{return{}},jw=(h,w)=>{let l={};if(h[jh]!=null)l[jh]=h[jh];if(h[$]!=null)l[$]=h[$];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[Z]!=null)l[Z]=h[Z];if(h[p]!=null){let G=lw(h[p],w);if(h[p]?.length===0)l.Tags=[];Object.entries(G).forEach(([I,H])=>{let d=`Tags.${I}`;l[d]=H})}return l},Lw=(h,w)=>{let l={};if(h[Z]!=null)l[Z]=h[Z];if(h[e]!=null)l[e]=h[e];if(h[o]!=null)l[o]=h[o];return l},Xh=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;let H=Rw(I,w);Object.entries(H).forEach(([d,X])=>{l[`member.${G}.${d}`]=X}),G++}return l},Rw=(h,w)=>{let l={};if(h[oh]!=null)l[oh]=h[oh];return l},aw=(h,w)=>{let l={};if(h[ah]!=null)l[ah]=h[ah];if(h[Uh]!=null)l[Uh]=h[Uh];return l},sw=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;let H=aw(I,w);Object.entries(H).forEach(([d,X])=>{l[`member.${G}.${d}`]=X}),G++}return l},rw=(h,w)=>{let l={};if(h[Ah]!=null)l[Ah]=h[Ah];if(h[eh]!=null)l[eh]=h[eh];return l},_w=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;l[`member.${G}`]=I,G++}return l},lw=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;let H=rw(I,w);Object.entries(H).forEach(([d,X])=>{l[`member.${G}.${d}`]=X}),G++}return l},uh=(h,w)=>{let l={};if(h[vh]!=null)l[vh]=S(h[vh]);if(h[N]!=null)l[N]=S(h[N]);return l},bw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[W]!=null)l[W]=uh(h[W],w);if(h[v]!=null)l[v]=u(h[v]);if(h[U]!=null)l[U]=S(h[U]);return l},fw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[W]!=null)l[W]=uh(h[W],w);if(h[v]!=null)l[v]=u(h[v]);if(h[bh]!=null)l[bh]=S(h[bh]);if(h[gh]!=null)l[gh]=S(h[gh]);if(h[Th]!=null)l[Th]=S(h[Th]);if(h[i]!=null)l[i]=S(h[i]);if(h[Lh]!=null)l[Lh]=S(h[Lh]);if(h[U]!=null)l[U]=S(h[U]);return l},Cw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[Oh]!=null)l[Oh]=S(h[Oh]);if(h[W]!=null)l[W]=uh(h[W],w);if(h[v]!=null)l[v]=u(h[v]);if(h[_h]!=null)l[_h]=S(h[_h]);if(h[i]!=null)l[i]=S(h[i]);if(h[U]!=null)l[U]=S(h[U]);return l},t=(h,w)=>{let l={};if(h[g]!=null)l[g]=S(h[g]);if(h[fh]!=null)l[fh]=S(h[fh]);if(h[xh]!=null)l[xh]=S(h[xh]);if(h[qh]!=null)l[qh]=a0(s0(h[qh]));return l},Ow=(h,w)=>{let l={};if(h[Ph]!=null)l[Ph]=S(h[Ph]);return l},gw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},xw=(h,w)=>{let l={};if(h[Nh]!=null)l[Nh]=S(h[Nh]);if(h[N]!=null)l[N]=S(h[N]);return l},iw=(h,w)=>{let l={};if(h[x]!=null)l[x]=S(h[x]);return l},cw=(h,w)=>{let l={};if(h[ch]!=null)l[ch]=S(h[ch]);if(h[x]!=null)l[x]=S(h[x]);if(h[N]!=null)l[N]=S(h[N]);return l},ew=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[Wh]!=null)l[Wh]=xw(h[Wh],w);if(h[v]!=null)l[v]=u(h[v]);return l},pw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);return l},ow=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},nw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},uw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},tw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},hG=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},lG=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},wG=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},K=(h)=>({httpStatusCode:h.statusCode,requestId:h.headers["x-amzn-requestid"]??h.headers["x-amzn-request-id"]??h.headers["x-amz-request-id"],extendedRequestId:h.headers["x-amz-id-2"],cfId:h.headers["x-amz-cf-id"]});var GG=r0(y),R=async(h,w,l,G,I)=>{let{hostname:H,protocol:d="https",port:X,path:z}=await h.endpoint(),P={protocol:d,hostname:H,port:X,method:"POST",path:z.endsWith("/")?z.slice(0,-1)+l:z+l,headers:w};if(G!==void 0)P.hostname=G;if(I!==void 0)P.body=I;return new R0(P)},a={"content-type":"application/x-www-form-urlencoded"},s="2011-06-15",r="Action",g="AccessKeyId",IG="AssumeRole",vh="AssumedRoleId",W="AssumedRoleUser",dG="AssumeRoleWithSAML",HG="AssumeRoleWithWebIdentity",x="Account",N="Arn",i="Audience",Y="Credentials",Uh="ContextAssertion",SG="DecodeAuthorizationMessage",Ph="DecodedMessage",Z="DurationSeconds",qh="Expiration",zh="ExternalId",Mh="EncodedMessage",Wh="FederatedUser",Nh="FederatedUserId",mG="GetAccessKeyInfo",JG="GetCallerIdentity",DG="GetFederationToken",kG="GetSessionToken",Th="Issuer",Ah="Key",jh="Name",Lh="NameQualifier",$="Policy",V="PolicyArns",Rh="PrincipalArn",ah="ProviderArn",sh="ProvidedContexts",rh="ProviderId",v="PackedPolicySize",_h="Provider",T="RoleArn",c="RoleSessionName",bh="Subject",fh="SecretAccessKey",Ch="SAMLAssertion",Oh="SubjectFromWebIdentityToken",U="SourceIdentity",e="SerialNumber",gh="SubjectType",xh="SessionToken",p="Tags",o="TokenCode",ih="TransitiveTagKeys",ch="UserId",_="Version",eh="Value",ph="WebIdentityToken",oh="arn",m="message",b=(h)=>Object.entries(h).map(([w,l])=>nh.extendedEncodeURIComponent(w)+"="+nh.extendedEncodeURIComponent(l)).join("&"),KG=(h,w)=>{if(w.Error?.Code!==void 0)return w.Error.Code;if(h.statusCode==404)return"NotFound"};class hh extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRole",{}).n("STSClient","AssumeRoleCommand").f(void 0,M0).ser(_0).de(c0).build(){}class th extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRoleWithSAML",{}).n("STSClient","AssumeRoleWithSAMLCommand").f(W0,N0).ser(b0).de(e0).build(){}class lh extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRoleWithWebIdentity",{}).n("STSClient","AssumeRoleWithWebIdentityCommand").f(T0,A0).ser(f0).de(p0).build(){}class hl extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","DecodeAuthorizationMessage",{}).n("STSClient","DecodeAuthorizationMessageCommand").f(void 0,void 0).ser(C0).de(o0).build(){}class ll extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetAccessKeyInfo",{}).n("STSClient","GetAccessKeyInfoCommand").f(void 0,void 0).ser(O0).de(n0).build(){}class wl extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetCallerIdentity",{}).n("STSClient","GetCallerIdentityCommand").f(void 0,void 0).ser(g0).de(u0).build(){}class Gl extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetFederationToken",{}).n("STSClient","GetFederationTokenCommand").f(void 0,j0).ser(x0).de(t0).build(){}class Il extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetSessionToken",{}).n("STSClient","GetSessionTokenCommand").f(void 0,L0).ser(i0).de(hw).build(){}var BG={AssumeRoleCommand:hh,AssumeRoleWithSAMLCommand:th,AssumeRoleWithWebIdentityCommand:lh,DecodeAuthorizationMessageCommand:hl,GetAccessKeyInfoCommand:ll,GetCallerIdentityCommand:wl,GetFederationTokenCommand:Gl,GetSessionTokenCommand:Il};class Gw extends j{}ww(BG,Gw);var Yh=M(EG(),1);var Iw="us-east-1",dw=(h)=>{if(typeof h?.Arn==="string"){let w=h.Arn.split(":");if(w.length>4&&w[4]!=="")return w[4]}return},Hw=async(h,w,l)=>{let G=typeof h==="function"?await h():h,I=typeof w==="function"?await w():w;return l?.debug?.("@aws-sdk/client-sts::resolveRegion","accepting first of:",`${G} (provider)`,`${I} (parent client)`,`${Iw} (STS default)`),G??I??Iw},Sw=(h,w)=>{let l,G;return async(I,H)=>{if(G=I,!l){let{logger:C=h?.parentClientConfig?.logger,region:Zh,requestHandler:wh=h?.parentClientConfig?.requestHandler,credentialProviderLogger:yh}=h,kw=await Hw(Zh,h?.parentClientConfig?.region,yh),Kw=!Jw(wh);l=new w({credentialDefaultProvider:()=>async()=>G,region:kw,requestHandler:Kw?wh:void 0,logger:C})}let{Credentials:d,AssumedRoleUser:X}=await l.send(new hh(H));if(!d||!d.AccessKeyId||!d.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRole call with role ${H.RoleArn}`);let z=dw(X),P={accessKeyId:d.AccessKeyId,secretAccessKey:d.SecretAccessKey,sessionToken:d.SessionToken,expiration:d.Expiration,...d.CredentialScope&&{credentialScope:d.CredentialScope},...z&&{accountId:z}};return Yh.setCredentialFeature(P,"CREDENTIALS_STS_ASSUME_ROLE","i"),P}},mw=(h,w)=>{let l;return async(G)=>{if(!l){let{logger:z=h?.parentClientConfig?.logger,region:P,requestHandler:C=h?.parentClientConfig?.requestHandler,credentialProviderLogger:Zh}=h,wh=await Hw(P,h?.parentClientConfig?.region,Zh),yh=!Jw(C);l=new w({region:wh,requestHandler:yh?C:void 0,logger:z})}let{Credentials:I,AssumedRoleUser:H}=await l.send(new lh(G));if(!I||!I.AccessKeyId||!I.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRoleWithWebIdentity call with role ${G.RoleArn}`);let d=dw(H),X={accessKeyId:I.AccessKeyId,secretAccessKey:I.SecretAccessKey,sessionToken:I.SessionToken,expiration:I.Expiration,...I.CredentialScope&&{credentialScope:I.CredentialScope},...d&&{accountId:d}};if(d)Yh.setCredentialFeature(X,"RESOLVED_ACCOUNT_ID","T");return Yh.setCredentialFeature(X,"CREDENTIALS_STS_ASSUME_ROLE_WEB_ID","k"),X}};var Jw=(h)=>{return h?.metadata?.handlerProtocol==="h2"};var Dw=(h,w)=>{if(!w)return h;else return class l extends h{constructor(G){super(G);for(let I of w)this.middlewareStack.use(I)}}},QG=(h={},w)=>Sw(h,Dw(j,w)),XG=(h={},w)=>mw(h,Dw(j,w)),b3=(h)=>(w)=>h({roleAssumer:QG(w),roleAssumerWithWebIdentity:XG(w),...w});export{XG as getDefaultRoleAssumerWithWebIdentity,QG as getDefaultRoleAssumer,b3 as decorateDefaultCredentialProvider,P0 as __Client,y as STSServiceException,j as STSClient,Gw as STS,kh as RegionDisabledException,Dh as PackedPolicyTooLargeException,Jh as MalformedPolicyDocumentException,Bh as InvalidIdentityTokenException,Qh as InvalidAuthorizationMessageException,Kh as IDPRejectedClaimException,Eh as IDPCommunicationErrorException,L0 as GetSessionTokenResponseFilterSensitiveLog,Il as GetSessionTokenCommand,j0 as GetFederationTokenResponseFilterSensitiveLog,Gl as GetFederationTokenCommand,wl as GetCallerIdentityCommand,ll as GetAccessKeyInfoCommand,mh as ExpiredTokenException,hl as DecodeAuthorizationMessageCommand,n as CredentialsFilterSensitiveLog,A0 as AssumeRoleWithWebIdentityResponseFilterSensitiveLog,T0 as AssumeRoleWithWebIdentityRequestFilterSensitiveLog,lh as AssumeRoleWithWebIdentityCommand,N0 as AssumeRoleWithSAMLResponseFilterSensitiveLog,W0 as AssumeRoleWithSAMLRequestFilterSensitiveLog,th as AssumeRoleWithSAMLCommand,M0 as AssumeRoleResponseFilterSensitiveLog,hh as AssumeRoleCommand,Q as $Command};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{L as Vh}from"./chunk-qma4ysd8.js";import{$ as gl,M as Q0,N as X0,O as Y0,P as Z0,Q as Bw,R as $h,S as y0,T as Ml,U as Wl,V as Nl,W as Tl,X as Gh,Y as F0,Z as Cl,_ as Ol,aa as xl,ba as $0,ca as V0,da as B,ea as E,fa as v0,ga as il,ha as cl,ia as U0,ja as el,ka as q0,la as tl,ma as h0,na as Rl,oa as al,pa as l0,qa as w0,ra as sl,sa as rl,ta as G0,ua as K0,va as B0}from"./chunk-7fz1p8p3.js";import{wa as f,xa as jl}from"./chunk-kzm498bh.js";import{$a as nh,Aa as R0,Ka as P0,La as Q,Ma as Sh,Na as ww,Qa as a0,Sa as S,Ta as u,Va as s0,Wa as z0,Xa as A,Ya as r0,Za as pl,_a as ol,ab as D0,bb as k0,eb as Ll,ib as nl,jb as ul,ya as m0,za as J0}from"./chunk-fh4rw8kr.js";import"./chunk-cs5k02gt.js";import"./chunk-2wrs9p57.js";import"./chunk-2mhj5ght.js";import{zb as EG}from"./chunk-ppkzf21q.js";import"./chunk-3wpw5xgd.js";import{Gb as M}from"./chunk-0m218zhk.js";var O=M($h(),1);var Hl=M(Gh(),1),Ih=M(Bw(),1);var Sl=async(h,w,l)=>{return{operation:Ih.getSmithyContext(w).operation,region:await Ih.normalizeProvider(h.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()}};function Ew(h){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sts",region:h.region},propertiesExtractor:(w,l)=>({signingProperties:{config:w,context:l}})}}function dl(h){return{schemeId:"smithy.api#noAuth"}}var ml=(h)=>{let w=[];switch(h.operation){case"AssumeRoleWithSAML":{w.push(dl(h));break}case"AssumeRoleWithWebIdentity":{w.push(dl(h));break}default:w.push(Ew(h))}return w},Qw=(h)=>({...h,stsClientCtor:j}),Jl=(h)=>{let w=Qw(h);return{...Hl.resolveAwsSdkSigV4Config(w)}};var Dl=(h)=>{return{...h,useDualstackEndpoint:h.useDualstackEndpoint??!1,useFipsEndpoint:h.useFipsEndpoint??!1,useGlobalEndpoint:h.useGlobalEndpoint??!1,defaultSigningName:"sts"}},D={UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};var kl={name:"@aws-sdk/client-sts",description:"AWS SDK for JavaScript Sts Client for Node.js, Browser and React Native",version:"3.679.0",scripts:{build:"concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline client-sts","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"rimraf ./dist-types tsconfig.types.tsbuildinfo && tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo","extract:docs":"api-extractor run --local","generate:client":"node ../../scripts/generate-clients/single-service --solo sts",test:"vitest run","test:watch":"vitest watch"},main:"./dist-cjs/index.js",types:"./dist-types/index.d.ts",module:"./dist-es/index.js",sideEffects:!1,dependencies:{"@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/client-sso-oidc":"3.679.0","@aws-sdk/core":"3.679.0","@aws-sdk/credential-provider-node":"3.679.0","@aws-sdk/middleware-host-header":"3.679.0","@aws-sdk/middleware-logger":"3.679.0","@aws-sdk/middleware-recursion-detection":"3.679.0","@aws-sdk/middleware-user-agent":"3.679.0","@aws-sdk/region-config-resolver":"3.679.0","@aws-sdk/types":"3.679.0","@aws-sdk/util-endpoints":"3.679.0","@aws-sdk/util-user-agent-browser":"3.679.0","@aws-sdk/util-user-agent-node":"3.679.0","@smithy/config-resolver":"^3.0.9","@smithy/core":"^2.4.8","@smithy/fetch-http-handler":"^3.2.9","@smithy/hash-node":"^3.0.7","@smithy/invalid-dependency":"^3.0.7","@smithy/middleware-content-length":"^3.0.9","@smithy/middleware-endpoint":"^3.1.4","@smithy/middleware-retry":"^3.0.23","@smithy/middleware-serde":"^3.0.7","@smithy/middleware-stack":"^3.0.7","@smithy/node-config-provider":"^3.1.8","@smithy/node-http-handler":"^3.2.4","@smithy/protocol-http":"^4.1.4","@smithy/smithy-client":"^3.4.0","@smithy/types":"^3.5.0","@smithy/url-parser":"^3.0.7","@smithy/util-base64":"^3.0.0","@smithy/util-body-length-browser":"^3.0.0","@smithy/util-body-length-node":"^3.0.0","@smithy/util-defaults-mode-browser":"^3.0.23","@smithy/util-defaults-mode-node":"^3.0.23","@smithy/util-endpoints":"^2.1.3","@smithy/util-middleware":"^3.0.7","@smithy/util-retry":"^3.0.7","@smithy/util-utf8":"^3.0.0",tslib:"^2.6.2"},devDependencies:{"@tsconfig/node16":"16.1.3","@types/node":"^16.18.96",concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~4.9.5"},engines:{node:">=16.0.0"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["dist-*/**"],author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",browser:{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.browser"},"react-native":{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.native"},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-sts",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"clients/client-sts"}};var dh=M(Gh(),1);var I0=M($h(),1);var _l=M(Gh(),1),bl=M($h(),1);var Kl={["required"]:!1,["type"]:"String"},Fh={["required"]:!0,default:!1,["type"]:"Boolean"},$l={["ref"]:"Endpoint"},Bl={["fn"]:"isSet",["argv"]:[{["ref"]:"Region"}]},J={["ref"]:"Region"},El={["fn"]:"aws.partition",["argv"]:[J],assign:"PartitionResult"},Vl={["ref"]:"UseFIPS"},vl={["ref"]:"UseDualStack"},k={url:"https://sts.amazonaws.com",properties:{authSchemes:[{name:"sigv4",signingName:"sts",signingRegion:"us-east-1"}]},headers:{}},F={},Ql={conditions:[{["fn"]:"stringEquals",["argv"]:[J,"aws-global"]}],["endpoint"]:k,["type"]:"endpoint"},Ul={["fn"]:"booleanEquals",["argv"]:[Vl,!0]},Pl={["fn"]:"booleanEquals",["argv"]:[vl,!0]},Xl={["fn"]:"getAttr",["argv"]:[{["ref"]:"PartitionResult"},"supportsFIPS"]},ql={["ref"]:"PartitionResult"},Yl={["fn"]:"booleanEquals",["argv"]:[!0,{["fn"]:"getAttr",["argv"]:[ql,"supportsDualStack"]}]},Zl=[{["fn"]:"isSet",["argv"]:[$l]}],yl=[Ul],Fl=[Pl],Yw={version:"1.0",parameters:{Region:Kl,UseDualStack:Fh,UseFIPS:Fh,Endpoint:Kl,UseGlobalEndpoint:Fh},rules:[{conditions:[{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseGlobalEndpoint"},!0]},{["fn"]:"not",["argv"]:Zl},Bl,El,{["fn"]:"booleanEquals",["argv"]:[Vl,!1]},{["fn"]:"booleanEquals",["argv"]:[vl,!1]}],rules:[{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-northeast-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-south-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-southeast-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ap-southeast-2"]}],endpoint:k,["type"]:"endpoint"},Ql,{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"ca-central-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-central-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-north-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-west-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-west-2"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"eu-west-3"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"sa-east-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-east-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-east-2"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-west-1"]}],endpoint:k,["type"]:"endpoint"},{conditions:[{["fn"]:"stringEquals",["argv"]:[J,"us-west-2"]}],endpoint:k,["type"]:"endpoint"},{endpoint:{url:"https://sts.{Region}.{PartitionResult#dnsSuffix}",properties:{authSchemes:[{name:"sigv4",signingName:"sts",signingRegion:"{Region}"}]},headers:F},["type"]:"endpoint"}],["type"]:"tree"},{conditions:Zl,rules:[{conditions:yl,error:"Invalid Configuration: FIPS and custom endpoint are not supported",["type"]:"error"},{conditions:Fl,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",["type"]:"error"},{endpoint:{url:$l,properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{conditions:[Bl],rules:[{conditions:[El],rules:[{conditions:[Ul,Pl],rules:[{conditions:[{["fn"]:"booleanEquals",["argv"]:[!0,Xl]},Yl],rules:[{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",["type"]:"error"}],["type"]:"tree"},{conditions:yl,rules:[{conditions:[{["fn"]:"booleanEquals",["argv"]:[Xl,!0]}],rules:[{conditions:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[ql,"name"]},"aws-us-gov"]}],endpoint:{url:"https://sts.{Region}.amazonaws.com",properties:F,headers:F},["type"]:"endpoint"},{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{error:"FIPS is enabled but this partition does not support FIPS",["type"]:"error"}],["type"]:"tree"},{conditions:Fl,rules:[{conditions:[Yl],rules:[{endpoint:{url:"https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"},{error:"DualStack is enabled but this partition does not support DualStack",["type"]:"error"}],["type"]:"tree"},Ql,{endpoint:{url:"https://sts.{Region}.{PartitionResult#dnsSuffix}",properties:F,headers:F},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{error:"Invalid Configuration: Missing Region",["type"]:"error"}]},zl=Yw;var Zw=new Ml({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS","UseGlobalEndpoint"]}),Al=(h,w={})=>{return Zw.get(h,()=>Nl(zl,{endpointParams:h,logger:w.logger}))};Wl.aws=Tl;var fl=(h)=>{return{apiVersion:"2011-06-15",base64Decoder:h?.base64Decoder??sl,base64Encoder:h?.base64Encoder??rl,disableHostPrefix:h?.disableHostPrefix??!1,endpointProvider:h?.endpointProvider??Al,extensions:h?.extensions??[],httpAuthSchemeProvider:h?.httpAuthSchemeProvider??ml,httpAuthSchemes:h?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(w)=>w.getIdentityProvider("aws.auth#sigv4"),signer:new _l.AwsSdkSigV4Signer},{schemeId:"smithy.api#noAuth",identityProvider:(w)=>w.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new bl.NoAuthSigner}],logger:h?.logger??new Ll,serviceId:h?.serviceId??"STS",urlParser:h?.urlParser??jl,utf8Decoder:h?.utf8Decoder??Rl,utf8Encoder:h?.utf8Encoder??al}};var d0=(h)=>{ol(process.version);let w=G0(h),l=()=>w().then(pl),G=fl(h);return dh.emitWarningIfUnsupportedVersion(process.version),{...G,...h,runtime:"node",defaultsMode:w,bodyLengthChecker:h?.bodyLengthChecker??w0,credentialDefaultProvider:h?.credentialDefaultProvider??Vh,defaultUserAgentProvider:h?.defaultUserAgentProvider??tl({serviceId:G.serviceId,clientVersion:kl.version}),httpAuthSchemes:h?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(I)=>I.getIdentityProvider("aws.auth#sigv4")||(async(H)=>await Vh(H?.__config||{})()),signer:new dh.AwsSdkSigV4Signer},{schemeId:"smithy.api#noAuth",identityProvider:(I)=>I.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new I0.NoAuthSigner}],maxAttempts:h?.maxAttempts??f(cl),region:h?.region??f(gl,xl),requestHandler:nl.create(h?.requestHandler??l),retryMode:h?.retryMode??f({...el,default:async()=>(await l()).retryMode||il}),sha256:h?.sha256??l0.bind(null,"sha256"),streamCollector:h?.streamCollector??ul,useDualstackEndpoint:h?.useDualstackEndpoint??f(Cl),useFipsEndpoint:h?.useFipsEndpoint??f(Ol),userAgentAppId:h?.userAgentAppId??f(h0)}};var H0=(h)=>{let{httpAuthSchemes:w,httpAuthSchemeProvider:l,credentials:G}=h;return{setHttpAuthScheme(I){let H=w.findIndex((d)=>d.schemeId===I.schemeId);if(H===-1)w.push(I);else w.splice(H,1,I)},httpAuthSchemes(){return w},setHttpAuthSchemeProvider(I){l=I},httpAuthSchemeProvider(){return l},setCredentials(I){G=I},credentials(){return G}}},S0=(h)=>{return{httpAuthSchemes:h.httpAuthSchemes(),httpAuthSchemeProvider:h.httpAuthSchemeProvider(),credentials:h.credentials()}};var Hh=(h)=>h,E0=(h,w)=>{let l={...Hh(K0(h)),...Hh(D0(h)),...Hh(m0(h)),...Hh(H0(h))};return w.forEach((G)=>G.configure(l)),{...h,...B0(l),...k0(l),...J0(l),...S0(l)}};class j extends P0{constructor(...[h]){let w=d0(h||{}),l=Dl(w),G=y0(l),I=U0(G),H=$0(I),d=Q0(H),X=v0(d),z=Jl(X),P=E0(z,h?.extensions||[]);super(P);this.config=P,this.middlewareStack.use(F0(this.config)),this.middlewareStack.use(q0(this.config)),this.middlewareStack.use(V0(this.config)),this.middlewareStack.use(X0(this.config)),this.middlewareStack.use(Y0(this.config)),this.middlewareStack.use(Z0(this.config)),this.middlewareStack.use(O.getHttpAuthSchemeEndpointRuleSetPlugin(this.config,{httpAuthSchemeParametersProvider:Sl,identityProviderConfigProvider:async(C)=>new O.DefaultIdentityProviderConfig({"aws.auth#sigv4":C.credentials})})),this.middlewareStack.use(O.getHttpSigningPlugin(this.config))}destroy(){super.destroy()}}class y extends z0{constructor(h){super(h);Object.setPrototypeOf(this,y.prototype)}}class mh extends y{constructor(h){super({name:"ExpiredTokenException",$fault:"client",...h});this.name="ExpiredTokenException",this.$fault="client",Object.setPrototypeOf(this,mh.prototype)}}class Jh extends y{constructor(h){super({name:"MalformedPolicyDocumentException",$fault:"client",...h});this.name="MalformedPolicyDocumentException",this.$fault="client",Object.setPrototypeOf(this,Jh.prototype)}}class Dh extends y{constructor(h){super({name:"PackedPolicyTooLargeException",$fault:"client",...h});this.name="PackedPolicyTooLargeException",this.$fault="client",Object.setPrototypeOf(this,Dh.prototype)}}class kh extends y{constructor(h){super({name:"RegionDisabledException",$fault:"client",...h});this.name="RegionDisabledException",this.$fault="client",Object.setPrototypeOf(this,kh.prototype)}}class Kh extends y{constructor(h){super({name:"IDPRejectedClaimException",$fault:"client",...h});this.name="IDPRejectedClaimException",this.$fault="client",Object.setPrototypeOf(this,Kh.prototype)}}class Bh extends y{constructor(h){super({name:"InvalidIdentityTokenException",$fault:"client",...h});this.name="InvalidIdentityTokenException",this.$fault="client",Object.setPrototypeOf(this,Bh.prototype)}}class Eh extends y{constructor(h){super({name:"IDPCommunicationErrorException",$fault:"client",...h});this.name="IDPCommunicationErrorException",this.$fault="client",Object.setPrototypeOf(this,Eh.prototype)}}class Qh extends y{constructor(h){super({name:"InvalidAuthorizationMessageException",$fault:"client",...h});this.name="InvalidAuthorizationMessageException",this.$fault="client",Object.setPrototypeOf(this,Qh.prototype)}}var n=(h)=>({...h,...h.SecretAccessKey&&{SecretAccessKey:Sh}}),M0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),W0=(h)=>({...h,...h.SAMLAssertion&&{SAMLAssertion:Sh}}),N0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),T0=(h)=>({...h,...h.WebIdentityToken&&{WebIdentityToken:Sh}}),A0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),j0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}}),L0=(h)=>({...h,...h.Credentials&&{Credentials:n(h.Credentials)}});var q=M(Gh(),1);var _0=async(h,w)=>{let l=a,G;return G=b({...zw(h,w),[r]:IG,[_]:s}),R(w,l,"/",void 0,G)},b0=async(h,w)=>{let l=a,G;return G=b({...Mw(h,w),[r]:dG,[_]:s}),R(w,l,"/",void 0,G)},f0=async(h,w)=>{let l=a,G;return G=b({...Ww(h,w),[r]:HG,[_]:s}),R(w,l,"/",void 0,G)},C0=async(h,w)=>{let l=a,G;return G=b({...Nw(h,w),[r]:SG,[_]:s}),R(w,l,"/",void 0,G)},O0=async(h,w)=>{let l=a,G;return G=b({...Tw(h,w),[r]:mG,[_]:s}),R(w,l,"/",void 0,G)},g0=async(h,w)=>{let l=a,G;return G=b({...Aw(h,w),[r]:JG,[_]:s}),R(w,l,"/",void 0,G)},x0=async(h,w)=>{let l=a,G;return G=b({...jw(h,w),[r]:DG,[_]:s}),R(w,l,"/",void 0,G)},i0=async(h,w)=>{let l=a,G;return G=b({...Lw(h,w),[r]:kG,[_]:s}),R(w,l,"/",void 0,G)},c0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=bw(l.AssumeRoleResult,w),{$metadata:K(h),...G}},e0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=fw(l.AssumeRoleWithSAMLResult,w),{$metadata:K(h),...G}},p0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=Cw(l.AssumeRoleWithWebIdentityResult,w),{$metadata:K(h),...G}},o0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=Ow(l.DecodeAuthorizationMessageResult,w),{$metadata:K(h),...G}},n0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=iw(l.GetAccessKeyInfoResult,w),{$metadata:K(h),...G}},u0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=cw(l.GetCallerIdentityResult,w),{$metadata:K(h),...G}},t0=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=ew(l.GetFederationTokenResult,w),{$metadata:K(h),...G}},hw=async(h,w)=>{if(h.statusCode>=300)return L(h,w);let l=await q.parseXmlBody(h.body,w),G={};return G=pw(l.GetSessionTokenResult,w),{$metadata:K(h),...G}},L=async(h,w)=>{let l={...h,body:await q.parseXmlErrorBody(h.body,w)},G=KG(h,l.body);switch(G){case"ExpiredTokenException":case"com.amazonaws.sts#ExpiredTokenException":throw await yw(l,w);case"MalformedPolicyDocument":case"com.amazonaws.sts#MalformedPolicyDocumentException":throw await Uw(l,w);case"PackedPolicyTooLarge":case"com.amazonaws.sts#PackedPolicyTooLargeException":throw await Pw(l,w);case"RegionDisabledException":case"com.amazonaws.sts#RegionDisabledException":throw await qw(l,w);case"IDPRejectedClaim":case"com.amazonaws.sts#IDPRejectedClaimException":throw await $w(l,w);case"InvalidIdentityToken":case"com.amazonaws.sts#InvalidIdentityTokenException":throw await vw(l,w);case"IDPCommunicationError":case"com.amazonaws.sts#IDPCommunicationErrorException":throw await Fw(l,w);case"InvalidAuthorizationMessageException":case"com.amazonaws.sts#InvalidAuthorizationMessageException":throw await Vw(l,w);default:let I=l.body;return GG({output:h,parsedBody:I.Error,errorCode:G})}},yw=async(h,w)=>{let l=h.body,G=gw(l.Error,w),I=new mh({$metadata:K(h),...G});return A(I,l)},Fw=async(h,w)=>{let l=h.body,G=ow(l.Error,w),I=new Eh({$metadata:K(h),...G});return A(I,l)},$w=async(h,w)=>{let l=h.body,G=nw(l.Error,w),I=new Kh({$metadata:K(h),...G});return A(I,l)},Vw=async(h,w)=>{let l=h.body,G=uw(l.Error,w),I=new Qh({$metadata:K(h),...G});return A(I,l)},vw=async(h,w)=>{let l=h.body,G=tw(l.Error,w),I=new Bh({$metadata:K(h),...G});return A(I,l)},Uw=async(h,w)=>{let l=h.body,G=hG(l.Error,w),I=new Jh({$metadata:K(h),...G});return A(I,l)},Pw=async(h,w)=>{let l=h.body,G=lG(l.Error,w),I=new Dh({$metadata:K(h),...G});return A(I,l)},qw=async(h,w)=>{let l=h.body,G=wG(l.Error,w),I=new kh({$metadata:K(h),...G});return A(I,l)},zw=(h,w)=>{let l={};if(h[T]!=null)l[T]=h[T];if(h[c]!=null)l[c]=h[c];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[$]!=null)l[$]=h[$];if(h[Z]!=null)l[Z]=h[Z];if(h[p]!=null){let G=lw(h[p],w);if(h[p]?.length===0)l.Tags=[];Object.entries(G).forEach(([I,H])=>{let d=`Tags.${I}`;l[d]=H})}if(h[ih]!=null){let G=_w(h[ih],w);if(h[ih]?.length===0)l.TransitiveTagKeys=[];Object.entries(G).forEach(([I,H])=>{let d=`TransitiveTagKeys.${I}`;l[d]=H})}if(h[zh]!=null)l[zh]=h[zh];if(h[e]!=null)l[e]=h[e];if(h[o]!=null)l[o]=h[o];if(h[U]!=null)l[U]=h[U];if(h[sh]!=null){let G=sw(h[sh],w);if(h[sh]?.length===0)l.ProvidedContexts=[];Object.entries(G).forEach(([I,H])=>{let d=`ProvidedContexts.${I}`;l[d]=H})}return l},Mw=(h,w)=>{let l={};if(h[T]!=null)l[T]=h[T];if(h[Rh]!=null)l[Rh]=h[Rh];if(h[Ch]!=null)l[Ch]=h[Ch];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[$]!=null)l[$]=h[$];if(h[Z]!=null)l[Z]=h[Z];return l},Ww=(h,w)=>{let l={};if(h[T]!=null)l[T]=h[T];if(h[c]!=null)l[c]=h[c];if(h[ph]!=null)l[ph]=h[ph];if(h[rh]!=null)l[rh]=h[rh];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[$]!=null)l[$]=h[$];if(h[Z]!=null)l[Z]=h[Z];return l},Nw=(h,w)=>{let l={};if(h[Mh]!=null)l[Mh]=h[Mh];return l},Tw=(h,w)=>{let l={};if(h[g]!=null)l[g]=h[g];return l},Aw=(h,w)=>{return{}},jw=(h,w)=>{let l={};if(h[jh]!=null)l[jh]=h[jh];if(h[$]!=null)l[$]=h[$];if(h[V]!=null){let G=Xh(h[V],w);if(h[V]?.length===0)l.PolicyArns=[];Object.entries(G).forEach(([I,H])=>{let d=`PolicyArns.${I}`;l[d]=H})}if(h[Z]!=null)l[Z]=h[Z];if(h[p]!=null){let G=lw(h[p],w);if(h[p]?.length===0)l.Tags=[];Object.entries(G).forEach(([I,H])=>{let d=`Tags.${I}`;l[d]=H})}return l},Lw=(h,w)=>{let l={};if(h[Z]!=null)l[Z]=h[Z];if(h[e]!=null)l[e]=h[e];if(h[o]!=null)l[o]=h[o];return l},Xh=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;let H=Rw(I,w);Object.entries(H).forEach(([d,X])=>{l[`member.${G}.${d}`]=X}),G++}return l},Rw=(h,w)=>{let l={};if(h[oh]!=null)l[oh]=h[oh];return l},aw=(h,w)=>{let l={};if(h[ah]!=null)l[ah]=h[ah];if(h[Uh]!=null)l[Uh]=h[Uh];return l},sw=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;let H=aw(I,w);Object.entries(H).forEach(([d,X])=>{l[`member.${G}.${d}`]=X}),G++}return l},rw=(h,w)=>{let l={};if(h[Ah]!=null)l[Ah]=h[Ah];if(h[eh]!=null)l[eh]=h[eh];return l},_w=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;l[`member.${G}`]=I,G++}return l},lw=(h,w)=>{let l={},G=1;for(let I of h){if(I===null)continue;let H=rw(I,w);Object.entries(H).forEach(([d,X])=>{l[`member.${G}.${d}`]=X}),G++}return l},uh=(h,w)=>{let l={};if(h[vh]!=null)l[vh]=S(h[vh]);if(h[N]!=null)l[N]=S(h[N]);return l},bw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[W]!=null)l[W]=uh(h[W],w);if(h[v]!=null)l[v]=u(h[v]);if(h[U]!=null)l[U]=S(h[U]);return l},fw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[W]!=null)l[W]=uh(h[W],w);if(h[v]!=null)l[v]=u(h[v]);if(h[bh]!=null)l[bh]=S(h[bh]);if(h[gh]!=null)l[gh]=S(h[gh]);if(h[Th]!=null)l[Th]=S(h[Th]);if(h[i]!=null)l[i]=S(h[i]);if(h[Lh]!=null)l[Lh]=S(h[Lh]);if(h[U]!=null)l[U]=S(h[U]);return l},Cw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[Oh]!=null)l[Oh]=S(h[Oh]);if(h[W]!=null)l[W]=uh(h[W],w);if(h[v]!=null)l[v]=u(h[v]);if(h[_h]!=null)l[_h]=S(h[_h]);if(h[i]!=null)l[i]=S(h[i]);if(h[U]!=null)l[U]=S(h[U]);return l},t=(h,w)=>{let l={};if(h[g]!=null)l[g]=S(h[g]);if(h[fh]!=null)l[fh]=S(h[fh]);if(h[xh]!=null)l[xh]=S(h[xh]);if(h[qh]!=null)l[qh]=a0(s0(h[qh]));return l},Ow=(h,w)=>{let l={};if(h[Ph]!=null)l[Ph]=S(h[Ph]);return l},gw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},xw=(h,w)=>{let l={};if(h[Nh]!=null)l[Nh]=S(h[Nh]);if(h[N]!=null)l[N]=S(h[N]);return l},iw=(h,w)=>{let l={};if(h[x]!=null)l[x]=S(h[x]);return l},cw=(h,w)=>{let l={};if(h[ch]!=null)l[ch]=S(h[ch]);if(h[x]!=null)l[x]=S(h[x]);if(h[N]!=null)l[N]=S(h[N]);return l},ew=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);if(h[Wh]!=null)l[Wh]=xw(h[Wh],w);if(h[v]!=null)l[v]=u(h[v]);return l},pw=(h,w)=>{let l={};if(h[Y]!=null)l[Y]=t(h[Y],w);return l},ow=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},nw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},uw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},tw=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},hG=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},lG=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},wG=(h,w)=>{let l={};if(h[m]!=null)l[m]=S(h[m]);return l},K=(h)=>({httpStatusCode:h.statusCode,requestId:h.headers["x-amzn-requestid"]??h.headers["x-amzn-request-id"]??h.headers["x-amz-request-id"],extendedRequestId:h.headers["x-amz-id-2"],cfId:h.headers["x-amz-cf-id"]});var GG=r0(y),R=async(h,w,l,G,I)=>{let{hostname:H,protocol:d="https",port:X,path:z}=await h.endpoint(),P={protocol:d,hostname:H,port:X,method:"POST",path:z.endsWith("/")?z.slice(0,-1)+l:z+l,headers:w};if(G!==void 0)P.hostname=G;if(I!==void 0)P.body=I;return new R0(P)},a={"content-type":"application/x-www-form-urlencoded"},s="2011-06-15",r="Action",g="AccessKeyId",IG="AssumeRole",vh="AssumedRoleId",W="AssumedRoleUser",dG="AssumeRoleWithSAML",HG="AssumeRoleWithWebIdentity",x="Account",N="Arn",i="Audience",Y="Credentials",Uh="ContextAssertion",SG="DecodeAuthorizationMessage",Ph="DecodedMessage",Z="DurationSeconds",qh="Expiration",zh="ExternalId",Mh="EncodedMessage",Wh="FederatedUser",Nh="FederatedUserId",mG="GetAccessKeyInfo",JG="GetCallerIdentity",DG="GetFederationToken",kG="GetSessionToken",Th="Issuer",Ah="Key",jh="Name",Lh="NameQualifier",$="Policy",V="PolicyArns",Rh="PrincipalArn",ah="ProviderArn",sh="ProvidedContexts",rh="ProviderId",v="PackedPolicySize",_h="Provider",T="RoleArn",c="RoleSessionName",bh="Subject",fh="SecretAccessKey",Ch="SAMLAssertion",Oh="SubjectFromWebIdentityToken",U="SourceIdentity",e="SerialNumber",gh="SubjectType",xh="SessionToken",p="Tags",o="TokenCode",ih="TransitiveTagKeys",ch="UserId",_="Version",eh="Value",ph="WebIdentityToken",oh="arn",m="message",b=(h)=>Object.entries(h).map(([w,l])=>nh.extendedEncodeURIComponent(w)+"="+nh.extendedEncodeURIComponent(l)).join("&"),KG=(h,w)=>{if(w.Error?.Code!==void 0)return w.Error.Code;if(h.statusCode==404)return"NotFound"};class hh extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRole",{}).n("STSClient","AssumeRoleCommand").f(void 0,M0).ser(_0).de(c0).build(){}class th extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRoleWithSAML",{}).n("STSClient","AssumeRoleWithSAMLCommand").f(W0,N0).ser(b0).de(e0).build(){}class lh extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRoleWithWebIdentity",{}).n("STSClient","AssumeRoleWithWebIdentityCommand").f(T0,A0).ser(f0).de(p0).build(){}class hl extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","DecodeAuthorizationMessage",{}).n("STSClient","DecodeAuthorizationMessageCommand").f(void 0,void 0).ser(C0).de(o0).build(){}class ll extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetAccessKeyInfo",{}).n("STSClient","GetAccessKeyInfoCommand").f(void 0,void 0).ser(O0).de(n0).build(){}class wl extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetCallerIdentity",{}).n("STSClient","GetCallerIdentityCommand").f(void 0,void 0).ser(g0).de(u0).build(){}class Gl extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetFederationToken",{}).n("STSClient","GetFederationTokenCommand").f(void 0,j0).ser(x0).de(t0).build(){}class Il extends Q.classBuilder().ep(D).m(function(h,w,l,G){return[B(l,this.serialize,this.deserialize),E(l,h.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","GetSessionToken",{}).n("STSClient","GetSessionTokenCommand").f(void 0,L0).ser(i0).de(hw).build(){}var BG={AssumeRoleCommand:hh,AssumeRoleWithSAMLCommand:th,AssumeRoleWithWebIdentityCommand:lh,DecodeAuthorizationMessageCommand:hl,GetAccessKeyInfoCommand:ll,GetCallerIdentityCommand:wl,GetFederationTokenCommand:Gl,GetSessionTokenCommand:Il};class Gw extends j{}ww(BG,Gw);var Yh=M(EG(),1);var Iw="us-east-1",dw=(h)=>{if(typeof h?.Arn==="string"){let w=h.Arn.split(":");if(w.length>4&&w[4]!=="")return w[4]}return},Hw=async(h,w,l)=>{let G=typeof h==="function"?await h():h,I=typeof w==="function"?await w():w;return l?.debug?.("@aws-sdk/client-sts::resolveRegion","accepting first of:",`${G} (provider)`,`${I} (parent client)`,`${Iw} (STS default)`),G??I??Iw},Sw=(h,w)=>{let l,G;return async(I,H)=>{if(G=I,!l){let{logger:C=h?.parentClientConfig?.logger,region:Zh,requestHandler:wh=h?.parentClientConfig?.requestHandler,credentialProviderLogger:yh}=h,kw=await Hw(Zh,h?.parentClientConfig?.region,yh),Kw=!Jw(wh);l=new w({credentialDefaultProvider:()=>async()=>G,region:kw,requestHandler:Kw?wh:void 0,logger:C})}let{Credentials:d,AssumedRoleUser:X}=await l.send(new hh(H));if(!d||!d.AccessKeyId||!d.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRole call with role ${H.RoleArn}`);let z=dw(X),P={accessKeyId:d.AccessKeyId,secretAccessKey:d.SecretAccessKey,sessionToken:d.SessionToken,expiration:d.Expiration,...d.CredentialScope&&{credentialScope:d.CredentialScope},...z&&{accountId:z}};return Yh.setCredentialFeature(P,"CREDENTIALS_STS_ASSUME_ROLE","i"),P}},mw=(h,w)=>{let l;return async(G)=>{if(!l){let{logger:z=h?.parentClientConfig?.logger,region:P,requestHandler:C=h?.parentClientConfig?.requestHandler,credentialProviderLogger:Zh}=h,wh=await Hw(P,h?.parentClientConfig?.region,Zh),yh=!Jw(C);l=new w({region:wh,requestHandler:yh?C:void 0,logger:z})}let{Credentials:I,AssumedRoleUser:H}=await l.send(new lh(G));if(!I||!I.AccessKeyId||!I.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRoleWithWebIdentity call with role ${G.RoleArn}`);let d=dw(H),X={accessKeyId:I.AccessKeyId,secretAccessKey:I.SecretAccessKey,sessionToken:I.SessionToken,expiration:I.Expiration,...I.CredentialScope&&{credentialScope:I.CredentialScope},...d&&{accountId:d}};if(d)Yh.setCredentialFeature(X,"RESOLVED_ACCOUNT_ID","T");return Yh.setCredentialFeature(X,"CREDENTIALS_STS_ASSUME_ROLE_WEB_ID","k"),X}};var Jw=(h)=>{return h?.metadata?.handlerProtocol==="h2"};var Dw=(h,w)=>{if(!w)return h;else return class l extends h{constructor(G){super(G);for(let I of w)this.middlewareStack.use(I)}}},QG=(h={},w)=>Sw(h,Dw(j,w)),XG=(h={},w)=>mw(h,Dw(j,w)),b3=(h)=>(w)=>h({roleAssumer:QG(w),roleAssumerWithWebIdentity:XG(w),...w});export{XG as getDefaultRoleAssumerWithWebIdentity,QG as getDefaultRoleAssumer,b3 as decorateDefaultCredentialProvider,P0 as __Client,y as STSServiceException,j as STSClient,Gw as STS,kh as RegionDisabledException,Dh as PackedPolicyTooLargeException,Jh as MalformedPolicyDocumentException,Bh as InvalidIdentityTokenException,Qh as InvalidAuthorizationMessageException,Kh as IDPRejectedClaimException,Eh as IDPCommunicationErrorException,L0 as GetSessionTokenResponseFilterSensitiveLog,Il as GetSessionTokenCommand,j0 as GetFederationTokenResponseFilterSensitiveLog,Gl as GetFederationTokenCommand,wl as GetCallerIdentityCommand,ll as GetAccessKeyInfoCommand,mh as ExpiredTokenException,hl as DecodeAuthorizationMessageCommand,n as CredentialsFilterSensitiveLog,A0 as AssumeRoleWithWebIdentityResponseFilterSensitiveLog,T0 as AssumeRoleWithWebIdentityRequestFilterSensitiveLog,lh as AssumeRoleWithWebIdentityCommand,N0 as AssumeRoleWithSAMLResponseFilterSensitiveLog,W0 as AssumeRoleWithSAMLRequestFilterSensitiveLog,th as AssumeRoleWithSAMLCommand,M0 as AssumeRoleResponseFilterSensitiveLog,hh as AssumeRoleCommand,Q as $Command};