@shumai-one/shumai-transcode 0.4.9 → 0.5.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shumai-one/shumai-transcode",
3
- "version": "0.4.9",
3
+ "version": "0.5.1",
4
4
  "description": "Media transcoding worker for the shumai media workspace",
5
5
  "type": "module",
6
6
  "bin": {
@@ -24,15 +24,16 @@
24
24
  "@temporalio/workflow": "1.23.0",
25
25
  "pdfkit": "0.20.1",
26
26
  "prisma": "7.10.0",
27
- "zod": "4.5.4"
27
+ "zod": "4.5.4",
28
+ "exiftool-vendored": "38.1.0"
28
29
  },
29
30
  "optionalDependencies": {
30
- "@shumai-one/shumai-transcode-darwin-arm64": "0.4.9",
31
- "@shumai-one/shumai-transcode-darwin-x64": "0.4.9",
32
- "@shumai-one/shumai-transcode-linux-arm64": "0.4.9",
33
- "@shumai-one/shumai-transcode-linux-x64": "0.4.9",
34
- "@shumai-one/shumai-transcode-win32-arm64": "0.4.9",
35
- "@shumai-one/shumai-transcode-win32-x64": "0.4.9"
31
+ "@shumai-one/shumai-transcode-darwin-arm64": "0.5.1",
32
+ "@shumai-one/shumai-transcode-darwin-x64": "0.5.1",
33
+ "@shumai-one/shumai-transcode-linux-arm64": "0.5.1",
34
+ "@shumai-one/shumai-transcode-linux-x64": "0.5.1",
35
+ "@shumai-one/shumai-transcode-win32-arm64": "0.5.1",
36
+ "@shumai-one/shumai-transcode-win32-x64": "0.5.1"
36
37
  },
37
38
  "repository": {
38
39
  "type": "git",
@@ -0,0 +1,16 @@
1
+ -- Migrate videoStrategy 'all' / 'full' to 'multi'
2
+ UPDATE "teams"
3
+ SET "settings" = jsonb_set("settings", '{transcode,videoStrategy}', '"multi"')
4
+ WHERE "settings"->'transcode'->>'videoStrategy' IN ('all', 'full');
5
+
6
+ -- Normalize legacy videoStrategy values 'single' / 'disable' to 'best_match'
7
+ UPDATE "teams"
8
+ SET "settings" = jsonb_set("settings", '{transcode,videoStrategy}', '"best_match"')
9
+ WHERE "settings"->'transcode'->>'videoStrategy' IN ('single', 'disable');
10
+
11
+ -- Backfill default videoResolutions where transcode settings exist without videoResolutions
12
+ UPDATE "teams"
13
+ SET "settings" = jsonb_set("settings", '{transcode,videoResolutions}', '["480p", "720p", "1080p", "1440p", "2160p"]'::jsonb)
14
+ WHERE "settings" IS NOT NULL
15
+ AND jsonb_typeof("settings"->'transcode') = 'object'
16
+ AND NOT ("settings"->'transcode' ? 'videoResolutions');
@@ -0,0 +1,2 @@
1
+ -- AlterEnum
2
+ ALTER TYPE "AssetStatus" ADD VALUE 'failed';
@@ -40,6 +40,7 @@ enum AssetStatus {
40
40
  uploaded
41
41
  processing
42
42
  processed
43
+ failed
43
44
  trashed
44
45
  pending_purge
45
46
  }
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{i,s,e,r,a,o,n,l,c,t,B,g,d}from"./shumai-transcode-app.js";var{awsEndpointFunctions:ie,emitWarningIfUnsupportedVersion:ae,createDefaultUserAgentProvider:ce,NODE_APP_ID_CONFIG_OPTIONS:ue,getAwsRegionExtensionConfiguration:de,resolveAwsRegionExtensionConfiguration:le,resolveUserAgentConfig:pe,resolveHostHeaderConfig:he,getUserAgentPlugin:ge,getHostHeaderPlugin:me,getLoggerPlugin:_e,getRecursionDetectionPlugin:Se}=t(),{NoAuthSigner:fe,getHttpAuthSchemeEndpointRuleSetPlugin:Ee,DefaultIdentityProviderConfig:Pe,getHttpSigningPlugin:ve}=c(),{normalizeProvider:W,getSmithyContext:Re,ServiceException:Ce,NoOpLogger:xe,emitWarningIfUnsupportedVersion:Ie,loadConfigsForDefaultMode:Ae,getDefaultExtensionConfiguration:ye,resolveDefaultRuntimeConfig:Oe,Client:Te,makeBuilder:De,createAggregatedClient:Ne}=s(),{Command:fs}=s();var{resolveDefaultsModeConfig:we,loadConfig:E,NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS:ke,NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS:be,NODE_REGION_CONFIG_OPTIONS:Fe,NODE_REGION_CONFIG_FILE_OPTIONS:$e,resolveRegionConfig:qe}=e(),{BinaryDecisionDiagram:He,EndpointCache:Ue,decideEndpoint:Ge,customEndpointFunctions:Me,resolveEndpointConfig:ze,getEndpointPlugin:je}=r(),{parseUrl:Le,getHttpHandlerExtensionConfiguration:Ke,resolveHttpHandlerRuntimeConfig:Ve,getContentLengthPlugin:Be}=n(),{DEFAULT_RETRY_MODE:We,NODE_RETRY_MODE_CONFIG_OPTIONS:Qe,NODE_MAX_ATTEMPT_CONFIG_OPTIONS:Ye,resolveRetryConfig:Je,getRetryPlugin:Xe}=l(),{TypeRegistry:Q,getSchemaSerdePlugin:Ze}=i(),{resolveAwsSdkSigV4Config:et,AwsSdkSigV4Signer:tt,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:st}=g(),{toUtf8:ot,fromUtf8:nt,toBase64:rt,fromBase64:it,calculateBodyLength:at}=a(),{streamCollector:ct,NodeHttpHandler:ut}=d(),{AwsRestJsonProtocol:dt}=B(),{Sha256:lt}=o(),pt=async(u,p,h)=>({operation:Re(p).operation,region:await W(u.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function ht(u){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"awsssoportal",region:u.region},propertiesExtractor:(p,h)=>({signingProperties:{config:p,context:h}})}}function gt(u){return{schemeId:"smithy.api#noAuth"}}var mt=(u)=>{let p=[];switch(u.operation){case"GetRoleCredentials":{p.push(gt());break}default:p.push(ht(u))}return p},_t=(u)=>{let p=et(u);return Object.assign(p,{authSchemePreference:W(u.authSchemePreference??[])})},St=(u)=>Object.assign(u,{useDualstackEndpoint:u.useDualstackEndpoint??!1,useFipsEndpoint:u.useFipsEndpoint??!1,defaultSigningName:"awsssoportal"}),ft={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},Et="3.997.43",Pt={version:Et},C="ref",P=-1,A=!0,z="isSet",Y="PartitionResult",y="booleanEquals",k="getAttr",j={[C]:"Endpoint"},b={[C]:Y},R={},L=[{[C]:"Region"}],K={conditions:[[z,[j]],[z,L],["aws.partition",L,Y],[y,[{[C]:"UseFIPS"},A]],[y,[{[C]:"UseDualStack"},A]],[y,[{fn:k,argv:[b,"supportsDualStack"]},A]],[y,[{fn:k,argv:[b,"supportsFIPS"]},A]],["stringEquals",[{fn:k,argv:[b,"name"]},"aws-us-gov"]]],results:[[P],[P,"Invalid Configuration: FIPS and custom endpoint are not supported"],[P,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[j,R],["https://portal.sso-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",R],[P,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://portal.sso.{Region}.amazonaws.com",R],["https://portal.sso-fips.{Region}.{PartitionResult#dnsSuffix}",R],[P,"FIPS is enabled but this partition does not support FIPS"],["https://portal.sso.{Region}.{PartitionResult#dualStackDnsSuffix}",R],[P,"DualStack is enabled but this partition does not support DualStack"],["https://portal.sso.{Region}.{PartitionResult#dnsSuffix}",R],[P,"Invalid Configuration: Missing Region"]]},vt=2,_=1e8,Rt=new Int32Array([-1,1,-1,0,13,3,1,4,_+12,2,5,_+12,3,8,6,4,7,_+11,5,_+9,_+10,4,11,9,6,10,_+8,7,_+6,_+7,5,12,_+5,6,_+4,_+5,3,_+1,14,4,_+2,_+3]),Ct=He.from(Rt,vt,K.conditions,K.results),xt=new Ue({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),It=(u,p={})=>xt.get(u,()=>Ge(Ct,{endpointParams:u,logger:p.logger}));Me.aws=ie;class v extends Ce{constructor(u){super(u);Object.setPrototypeOf(this,v.prototype)}}class F extends v{name="InvalidRequestException";$fault="client";constructor(u){super({name:"InvalidRequestException",$fault:"client",...u});Object.setPrototypeOf(this,F.prototype)}}class q extends v{name="ResourceNotFoundException";$fault="client";constructor(u){super({name:"ResourceNotFoundException",$fault:"client",...u});Object.setPrototypeOf(this,q.prototype)}}class H extends v{name="TooManyRequestsException";$fault="client";constructor(u){super({name:"TooManyRequestsException",$fault:"client",...u});Object.setPrototypeOf(this,H.prototype)}}class U extends v{name="UnauthorizedException";$fault="client";constructor(u){super({name:"UnauthorizedException",$fault:"client",...u});Object.setPrototypeOf(this,U.prototype)}}var At="AccessTokenType",yt="GetRoleCredentials",Ot="GetRoleCredentialsRequest",Tt="GetRoleCredentialsResponse",Dt="InvalidRequestException",Nt="RoleCredentials",wt="ResourceNotFoundException",kt="SecretAccessKeyType",bt="SessionTokenType",Ft="TooManyRequestsException",$t="UnauthorizedException",qt="accountId",Ht="accessKeyId",Ut="accessToken",Gt="account_id",O="client",T="error",Mt="expiration",zt="http",D="httpError",jt="httpHeader",V="httpQuery",N="message",Lt="roleCredentials",Kt="roleName",Vt="role_name",J="smithy.ts.sdk.synthetic.com.amazonaws.sso",Bt="secretAccessKey",Wt="sessionToken",Qt="x-amz-sso_bearer_token",S="com.amazonaws.sso",X=Q.for(J),Yt=[-3,J,"SSOServiceException",0,[],[]];X.registerError(Yt,v);var x=Q.for(S),Jt=[-3,S,Dt,{[T]:O,[D]:400},[N],[0]];x.registerError(Jt,F);var Xt=[-3,S,wt,{[T]:O,[D]:404},[N],[0]];x.registerError(Xt,q);var Zt=[-3,S,Ft,{[T]:O,[D]:429},[N],[0]];x.registerError(Zt,H);var es=[-3,S,$t,{[T]:O,[D]:401},[N],[0]];x.registerError(es,U);var ts=[X,x],ss=[0,S,At,8,0],os=[0,S,kt,8,0],ns=[0,S,bt,8,0],rs=[3,S,Ot,0,[Kt,qt,Ut],[[0,{[V]:Vt}],[0,{[V]:Gt}],[()=>ss,{[jt]:Qt}]],3],is=[3,S,Tt,0,[Lt],[[()=>as,0]]],as=[3,S,Nt,0,[Ht,Bt,Wt,Mt],[0,[()=>os,0],[()=>ns,0],1]],cs=[9,S,yt,{[zt]:["GET","/federation/credentials",200]},()=>rs,()=>is],us=(u)=>({apiVersion:"2019-06-10",base64Decoder:u?.base64Decoder??it,base64Encoder:u?.base64Encoder??rt,disableHostPrefix:u?.disableHostPrefix??!1,endpointProvider:u?.endpointProvider??It,extensions:u?.extensions??[],httpAuthSchemeProvider:u?.httpAuthSchemeProvider??mt,httpAuthSchemes:u?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(p)=>p.getIdentityProvider("aws.auth#sigv4"),signer:new tt},{schemeId:"smithy.api#noAuth",identityProvider:(p)=>p.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new fe}],logger:u?.logger??new xe,protocol:u?.protocol??dt,protocolSettings:u?.protocolSettings??{defaultNamespace:"com.amazonaws.sso",errorTypeRegistries:ts,version:"2019-06-10",serviceTarget:"SWBPortalService"},serviceId:u?.serviceId??"SSO",sha256:u?.sha256??lt,urlParser:u?.urlParser??Le,utf8Decoder:u?.utf8Decoder??nt,utf8Encoder:u?.utf8Encoder??ot}),ds=(u)=>{Ie(process.version);let p=we(u),h=()=>p().then(Ae),f=us(u);ae(process.version);let m={profile:u?.profile,logger:f.logger};return{...f,...u,runtime:"node",defaultsMode:p,authSchemePreference:u?.authSchemePreference??E(st,m),bodyLengthChecker:u?.bodyLengthChecker??at,defaultUserAgentProvider:u?.defaultUserAgentProvider??ce({serviceId:f.serviceId,clientVersion:Pt.version}),maxAttempts:u?.maxAttempts??E(Ye,u),region:u?.region??E(Fe,{...$e,...m}),requestHandler:ut.create(u?.requestHandler??h),retryMode:u?.retryMode??E({...Qe,default:async()=>(await h()).retryMode||We},u),streamCollector:u?.streamCollector??ct,useDualstackEndpoint:u?.useDualstackEndpoint??E(be,m),useFipsEndpoint:u?.useFipsEndpoint??E(ke,m),userAgentAppId:u?.userAgentAppId??E(ue,m)}},ls=(u)=>{let{httpAuthSchemes:p,httpAuthSchemeProvider:h,credentials:f}=u;return{setHttpAuthScheme(m){let I=p.findIndex((w)=>w.schemeId===m.schemeId);if(I===-1)p.push(m);else p.splice(I,1,m)},httpAuthSchemes(){return p},setHttpAuthSchemeProvider(m){h=m},httpAuthSchemeProvider(){return h},setCredentials(m){f=m},credentials(){return f}}},ps=(u)=>({httpAuthSchemes:u.httpAuthSchemes(),httpAuthSchemeProvider:u.httpAuthSchemeProvider(),credentials:u.credentials()}),hs=(u,p)=>{let h=Object.assign(de(u),ye(u),Ke(u),ls(u));return p.forEach((f)=>f.configure(h)),Object.assign(u,le(h),Oe(h),Ve(h),ps(h))};class G extends Te{config;constructor(...[u]){let p=ds(u||{});super(p);this.initConfig=p;let h=St(p),f=pe(h),m=Je(f),I=qe(m),w=he(I),se=ze(w),oe=_t(se),ne=hs(oe,u?.extensions||[]);this.config=ne,this.middlewareStack.use(Ze(this.config)),this.middlewareStack.use(ge(this.config)),this.middlewareStack.use(Xe(this.config)),this.middlewareStack.use(Be(this.config)),this.middlewareStack.use(me(this.config)),this.middlewareStack.use(_e(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Ee(this.config,{httpAuthSchemeParametersProvider:pt,identityProviderConfigProvider:async(re)=>new Pe({"aws.auth#sigv4":re.credentials})})),this.middlewareStack.use(ve(this.config))}destroy(){super.destroy()}}var gs=De(ft,"SWBPortalService","SSOClient",je),ms={},_s=(u,p,h,f)=>[];class M extends gs(ms,_s,"GetRoleCredentials",cs){}var Ss={GetRoleCredentialsCommand:M};class Z extends G{}Ne(Ss,Z);var ee=M;var te=G;export{ee as GetRoleCredentialsCommand,te as SSOClient};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{i,s,e,r,a,o,n,l,c,t,B,g,d}from"./shumai-transcode-app.js";var{awsEndpointFunctions:De,emitWarningIfUnsupportedVersion:ke,createDefaultUserAgentProvider:$e,NODE_APP_ID_CONFIG_OPTIONS:we,getAwsRegionExtensionConfiguration:Ne,resolveAwsRegionExtensionConfiguration:be,resolveUserAgentConfig:Ue,resolveHostHeaderConfig:Fe,getUserAgentPlugin:qe,getHostHeaderPlugin:He,getLoggerPlugin:Me,getRecursionDetectionPlugin:Ge}=t(),{NoAuthSigner:je,getHttpAuthSchemeEndpointRuleSetPlugin:Ke,DefaultIdentityProviderConfig:Ve,getHttpSigningPlugin:ze}=c(),{normalizeProvider:te,getSmithyContext:Le,ServiceException:Be,NoOpLogger:We,emitWarningIfUnsupportedVersion:Ye,loadConfigsForDefaultMode:Je,getDefaultExtensionConfiguration:Xe,resolveDefaultRuntimeConfig:Qe,Client:re,makeBuilder:Ze,createAggregatedClient:et}=s(),{Command:tt}=s();var Vr=tt,zr=re;var{resolveDefaultsModeConfig:rt,loadConfig:A,NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS:ot,NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS:nt,NODE_REGION_CONFIG_OPTIONS:st,NODE_REGION_CONFIG_FILE_OPTIONS:it,resolveRegionConfig:ct}=e(),{BinaryDecisionDiagram:at,EndpointCache:pt,decideEndpoint:dt,customEndpointFunctions:ut,resolveEndpointConfig:lt,getEndpointPlugin:ht}=r(),{parseUrl:_t,getHttpHandlerExtensionConfiguration:gt,resolveHttpHandlerRuntimeConfig:Et,getContentLengthPlugin:mt}=n(),{DEFAULT_RETRY_MODE:xt,NODE_RETRY_MODE_CONFIG_OPTIONS:ft,NODE_MAX_ATTEMPT_CONFIG_OPTIONS:St,resolveRetryConfig:vt,getRetryPlugin:Pt}=l(),{TypeRegistry:oe,getSchemaSerdePlugin:It}=i(),{resolveAwsSdkSigV4Config:Ct,AwsSdkSigV4Signer:At,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:yt}=g(),{toUtf8:Tt,fromUtf8:Ot,toBase64:Rt,fromBase64:Dt,calculateBodyLength:kt}=a(),{streamCollector:$t,NodeHttpHandler:wt}=d(),{AwsRestJsonProtocol:Nt}=B(),{Sha256:bt}=o(),Ut=async(p,u,E)=>({operation:Le(u).operation,region:await te(p.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function Ft(p){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sso-oauth",region:p.region},propertiesExtractor:(u,E)=>({signingProperties:{config:u,context:E}})}}function qt(p){return{schemeId:"smithy.api#noAuth"}}var Ht=(p)=>{let u=[];switch(p.operation){case"CreateToken":{u.push(qt());break}default:u.push(Ft(p))}return u},Mt=(p)=>{let u=Ct(p);return Object.assign(u,{authSchemePreference:te(p.authSchemePreference??[])})},Gt=(p)=>Object.assign(p,{useDualstackEndpoint:p.useDualstackEndpoint??!1,useFipsEndpoint:p.useFipsEndpoint??!1,defaultSigningName:"sso-oauth"}),jt={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},Kt="3.997.43",Vt={version:Kt},O="ref",y=-1,D=!0,X="isSet",ne="PartitionResult",k="booleanEquals",z="getAttr",Q={[O]:"Endpoint"},L={[O]:ne},T={},Z=[{[O]:"Region"}],ee={conditions:[[X,[Q]],[X,Z],["aws.partition",Z,ne],[k,[{[O]:"UseFIPS"},D]],[k,[{[O]:"UseDualStack"},D]],[k,[{fn:z,argv:[L,"supportsDualStack"]},D]],[k,[{fn:z,argv:[L,"supportsFIPS"]},D]],["stringEquals",[{fn:z,argv:[L,"name"]},"aws-us-gov"]]],results:[[y],[y,"Invalid Configuration: FIPS and custom endpoint are not supported"],[y,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[Q,T],["https://oidc-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",T],[y,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://oidc.{Region}.amazonaws.com",T],["https://oidc-fips.{Region}.{PartitionResult#dnsSuffix}",T],[y,"FIPS is enabled but this partition does not support FIPS"],["https://oidc.{Region}.{PartitionResult#dualStackDnsSuffix}",T],[y,"DualStack is enabled but this partition does not support DualStack"],["https://oidc.{Region}.{PartitionResult#dnsSuffix}",T],[y,"Invalid Configuration: Missing Region"]]},zt=2,f=1e8,Lt=new Int32Array([-1,1,-1,0,13,3,1,4,f+12,2,5,f+12,3,8,6,4,7,f+11,5,f+9,f+10,4,11,9,6,10,f+8,7,f+6,f+7,5,12,f+5,6,f+4,f+5,3,f+1,14,4,f+2,f+3]),Bt=at.from(Lt,zt,ee.conditions,ee.results),Wt=new pt({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),Yt=(p,u={})=>Wt.get(p,()=>dt(Bt,{endpointParams:p,logger:u.logger}));ut.aws=De;class x extends Be{constructor(p){super(p);Object.setPrototypeOf(this,x.prototype)}}class w extends x{name="AccessDeniedException";$fault="client";error;reason;error_description;constructor(p){super({name:"AccessDeniedException",$fault:"client",...p});Object.setPrototypeOf(this,w.prototype),this.error=p.error,this.reason=p.reason,this.error_description=p.error_description}}class N extends x{name="AuthorizationPendingException";$fault="client";error;error_description;constructor(p){super({name:"AuthorizationPendingException",$fault:"client",...p});Object.setPrototypeOf(this,N.prototype),this.error=p.error,this.error_description=p.error_description}}class b extends x{name="ExpiredTokenException";$fault="client";error;error_description;constructor(p){super({name:"ExpiredTokenException",$fault:"client",...p});Object.setPrototypeOf(this,b.prototype),this.error=p.error,this.error_description=p.error_description}}class U extends x{name="InternalServerException";$fault="server";error;error_description;constructor(p){super({name:"InternalServerException",$fault:"server",...p});Object.setPrototypeOf(this,U.prototype),this.error=p.error,this.error_description=p.error_description}}class F extends x{name="InvalidClientException";$fault="client";error;error_description;constructor(p){super({name:"InvalidClientException",$fault:"client",...p});Object.setPrototypeOf(this,F.prototype),this.error=p.error,this.error_description=p.error_description}}class q extends x{name="InvalidGrantException";$fault="client";error;error_description;constructor(p){super({name:"InvalidGrantException",$fault:"client",...p});Object.setPrototypeOf(this,q.prototype),this.error=p.error,this.error_description=p.error_description}}class H extends x{name="InvalidRequestException";$fault="client";error;reason;error_description;constructor(p){super({name:"InvalidRequestException",$fault:"client",...p});Object.setPrototypeOf(this,H.prototype),this.error=p.error,this.reason=p.reason,this.error_description=p.error_description}}class M extends x{name="InvalidScopeException";$fault="client";error;error_description;constructor(p){super({name:"InvalidScopeException",$fault:"client",...p});Object.setPrototypeOf(this,M.prototype),this.error=p.error,this.error_description=p.error_description}}class G extends x{name="SlowDownException";$fault="client";error;error_description;constructor(p){super({name:"SlowDownException",$fault:"client",...p});Object.setPrototypeOf(this,G.prototype),this.error=p.error,this.error_description=p.error_description}}class j extends x{name="UnauthorizedClientException";$fault="client";error;error_description;constructor(p){super({name:"UnauthorizedClientException",$fault:"client",...p});Object.setPrototypeOf(this,j.prototype),this.error=p.error,this.error_description=p.error_description}}class K extends x{name="UnsupportedGrantTypeException";$fault="client";error;error_description;constructor(p){super({name:"UnsupportedGrantTypeException",$fault:"client",...p});Object.setPrototypeOf(this,K.prototype),this.error=p.error,this.error_description=p.error_description}}var Jt="AccessDeniedException",Xt="AuthorizationPendingException",Qt="AccessToken",Zt="ClientSecret",er="CreateToken",tr="CreateTokenRequest",rr="CreateTokenResponse",or="CodeVerifier",nr="ExpiredTokenException",sr="InvalidClientException",ir="InvalidGrantException",cr="InvalidRequestException",ar="InternalServerException",pr="InvalidScopeException",dr="IdToken",ur="RefreshToken",lr="SlowDownException",hr="UnauthorizedClientException",_r="UnsupportedGrantTypeException",gr="accessToken",C="client",Er="clientId",mr="clientSecret",xr="codeVerifier",fr="code",Sr="deviceCode",h="error",vr="expiresIn",P="error_description",Pr="grantType",Ir="http",I="httpError",Cr="idToken",se="reason",ie="refreshToken",Ar="redirectUri",ce="smithy.ts.sdk.synthetic.com.amazonaws.ssooidc",yr="scope",Tr="server",Or="tokenType",_="com.amazonaws.ssooidc",ae=oe.for(ce),pe=[-3,ce,"SSOOIDCServiceException",0,[],[]];ae.registerError(pe,x);var S=oe.for(_),de=[-3,_,Jt,{[h]:C,[I]:400},[h,se,P],[0,0,0]];S.registerError(de,w);var ue=[-3,_,Xt,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(ue,N);var le=[-3,_,nr,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(le,b);var he=[-3,_,ar,{[h]:Tr,[I]:500},[h,P],[0,0]];S.registerError(he,U);var _e=[-3,_,sr,{[h]:C,[I]:401},[h,P],[0,0]];S.registerError(_e,F);var ge=[-3,_,ir,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(ge,q);var Ee=[-3,_,cr,{[h]:C,[I]:400},[h,se,P],[0,0,0]];S.registerError(Ee,H);var me=[-3,_,pr,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(me,M);var xe=[-3,_,lr,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(xe,G);var fe=[-3,_,hr,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(fe,j);var Se=[-3,_,_r,{[h]:C,[I]:400},[h,P],[0,0]];S.registerError(Se,K);var ve=[ae,S],Rr=[0,_,Qt,8,0],Dr=[0,_,Zt,8,0],kr=[0,_,or,8,0],$r=[0,_,dr,8,0],Pe=[0,_,ur,8,0],Ie=[3,_,tr,0,[Er,mr,Pr,Sr,fr,ie,yr,Ar,xr],[0,[()=>Dr,0],0,0,0,[()=>Pe,0],64,0,[()=>kr,0]],3],Ce=[3,_,rr,0,[gr,Or,vr,ie,Cr],[[()=>Rr,0],0,1,[()=>Pe,0],[()=>$r,0]]],Ae=[9,_,er,{[Ir]:["POST","/token",200]},()=>Ie,()=>Ce],wr=(p)=>({apiVersion:"2019-06-10",base64Decoder:p?.base64Decoder??Dt,base64Encoder:p?.base64Encoder??Rt,disableHostPrefix:p?.disableHostPrefix??!1,endpointProvider:p?.endpointProvider??Yt,extensions:p?.extensions??[],httpAuthSchemeProvider:p?.httpAuthSchemeProvider??Ht,httpAuthSchemes:p?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(u)=>u.getIdentityProvider("aws.auth#sigv4"),signer:new At},{schemeId:"smithy.api#noAuth",identityProvider:(u)=>u.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new je}],logger:p?.logger??new We,protocol:p?.protocol??Nt,protocolSettings:p?.protocolSettings??{defaultNamespace:"com.amazonaws.ssooidc",errorTypeRegistries:ve,version:"2019-06-10",serviceTarget:"AWSSSOOIDCService"},serviceId:p?.serviceId??"SSO OIDC",sha256:p?.sha256??bt,urlParser:p?.urlParser??_t,utf8Decoder:p?.utf8Decoder??Ot,utf8Encoder:p?.utf8Encoder??Tt}),Nr=(p)=>{Ye(process.version);let u=rt(p),E=()=>u().then(Je),v=wr(p);ke(process.version);let m={profile:p?.profile,logger:v.logger};return{...v,...p,runtime:"node",defaultsMode:u,authSchemePreference:p?.authSchemePreference??A(yt,m),bodyLengthChecker:p?.bodyLengthChecker??kt,defaultUserAgentProvider:p?.defaultUserAgentProvider??$e({serviceId:v.serviceId,clientVersion:Vt.version}),maxAttempts:p?.maxAttempts??A(St,p),region:p?.region??A(st,{...it,...m}),requestHandler:wt.create(p?.requestHandler??E),retryMode:p?.retryMode??A({...ft,default:async()=>(await E()).retryMode||xt},p),streamCollector:p?.streamCollector??$t,useDualstackEndpoint:p?.useDualstackEndpoint??A(nt,m),useFipsEndpoint:p?.useFipsEndpoint??A(ot,m),userAgentAppId:p?.userAgentAppId??A(we,m)}},br=(p)=>{let{httpAuthSchemes:u,httpAuthSchemeProvider:E,credentials:v}=p;return{setHttpAuthScheme(m){let R=u.findIndex((V)=>V.schemeId===m.schemeId);if(R===-1)u.push(m);else u.splice(R,1,m)},httpAuthSchemes(){return u},setHttpAuthSchemeProvider(m){E=m},httpAuthSchemeProvider(){return E},setCredentials(m){v=m},credentials(){return v}}},Ur=(p)=>({httpAuthSchemes:p.httpAuthSchemes(),httpAuthSchemeProvider:p.httpAuthSchemeProvider(),credentials:p.credentials()}),Fr=(p,u)=>{let E=Object.assign(Ne(p),Xe(p),gt(p),br(p));return u.forEach((v)=>v.configure(E)),Object.assign(p,be(E),Qe(E),Et(E),Ur(E))};class W extends re{config;constructor(...[p]){let u=Nr(p||{});super(u);this.initConfig=u;let E=Gt(u),v=Ue(E),m=vt(v),R=ct(m),V=Fe(R),ye=lt(V),Te=Mt(ye),Oe=Fr(Te,p?.extensions||[]);this.config=Oe,this.middlewareStack.use(It(this.config)),this.middlewareStack.use(qe(this.config)),this.middlewareStack.use(Pt(this.config)),this.middlewareStack.use(mt(this.config)),this.middlewareStack.use(He(this.config)),this.middlewareStack.use(Me(this.config)),this.middlewareStack.use(Ge(this.config)),this.middlewareStack.use(Ke(this.config,{httpAuthSchemeParametersProvider:Ut,identityProviderConfigProvider:async(Re)=>new Ve({"aws.auth#sigv4":Re.credentials})})),this.middlewareStack.use(ze(this.config))}destroy(){super.destroy()}}var qr=Ze(jt,"AWSSSOOIDCService","SSOOIDCClient",ht),Hr={},Mr=(p,u,E,v)=>[];class Y extends qr(Hr,Mr,"CreateToken",Ae){}var Gr={CreateTokenCommand:Y};class J extends W{}et(Gr,J);var jr={KMS_ACCESS_DENIED:"KMS_AccessDeniedException"},Kr={KMS_DISABLED_KEY:"KMS_DisabledException",KMS_INVALID_KEY_USAGE:"KMS_InvalidKeyUsageException",KMS_INVALID_STATE:"KMS_InvalidStateException",KMS_KEY_NOT_FOUND:"KMS_NotFoundException"};var Lr=w,Br=de,Wr=jr,Yr=N,Jr=ue,Xr=Ae,Qr=Y,Zr=Ie,eo=Ce,to=b,ro=le,oo=U,no=he,so=F,io=_e,co=q,ao=ge,po=H,uo=Ee,lo=Kr,ho=M,_o=me,go=J,Eo=W,mo=x,xo=pe,fo=G,So=xe,vo=j,Po=fe,Io=K,Co=Se,Ao=ve;export{Vr as $Command,zr as __Client,Lr as AccessDeniedException,Br as AccessDeniedException$,Wr as AccessDeniedExceptionReason,Yr as AuthorizationPendingException,Jr as AuthorizationPendingException$,Xr as CreateToken$,Qr as CreateTokenCommand,Zr as CreateTokenRequest$,eo as CreateTokenResponse$,to as ExpiredTokenException,ro as ExpiredTokenException$,oo as InternalServerException,no as InternalServerException$,so as InvalidClientException,io as InvalidClientException$,co as InvalidGrantException,ao as InvalidGrantException$,po as InvalidRequestException,uo as InvalidRequestException$,lo as InvalidRequestExceptionReason,ho as InvalidScopeException,_o as InvalidScopeException$,go as SSOOIDC,Eo as SSOOIDCClient,mo as SSOOIDCServiceException,xo as SSOOIDCServiceException$,fo as SlowDownException,So as SlowDownException$,vo as UnauthorizedClientException,Po as UnauthorizedClientException$,Io as UnsupportedGrantTypeException,Co as UnsupportedGrantTypeException$,Ao as errorTypeRegistries};
File without changes