@go-to-k/cdkd 0.50.2 → 0.50.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js CHANGED
@@ -22204,23 +22204,14 @@ var ApiGatewayProvider = class _ApiGatewayProvider {
22204
22204
  new GetAuthorizerCommand({ restApiId, authorizerId: physicalId })
22205
22205
  );
22206
22206
  const result = { RestApiId: restApiId };
22207
- if (resp.name !== void 0)
22208
- result["Name"] = resp.name;
22207
+ result["Name"] = resp.name ?? "";
22209
22208
  if (resp.type !== void 0)
22210
22209
  result["Type"] = resp.type;
22211
- if (resp.providerARNs !== void 0 && resp.providerARNs.length > 0) {
22212
- result["ProviderARNs"] = [...resp.providerARNs];
22213
- }
22214
- if (resp.authorizerUri !== void 0)
22215
- result["AuthorizerUri"] = resp.authorizerUri;
22216
- if (resp.authorizerCredentials !== void 0) {
22217
- result["AuthorizerCredentials"] = resp.authorizerCredentials;
22218
- }
22219
- if (resp.identitySource !== void 0)
22220
- result["IdentitySource"] = resp.identitySource;
22221
- if (resp.identityValidationExpression !== void 0) {
22222
- result["IdentityValidationExpression"] = resp.identityValidationExpression;
22223
- }
22210
+ result["ProviderARNs"] = resp.providerARNs ? [...resp.providerARNs] : [];
22211
+ result["AuthorizerUri"] = resp.authorizerUri ?? "";
22212
+ result["AuthorizerCredentials"] = resp.authorizerCredentials ?? "";
22213
+ result["IdentitySource"] = resp.identitySource ?? "";
22214
+ result["IdentityValidationExpression"] = resp.identityValidationExpression ?? "";
22224
22215
  if (resp.authorizerResultTtlInSeconds !== void 0) {
22225
22216
  result["AuthorizerResultTtlInSeconds"] = resp.authorizerResultTtlInSeconds;
22226
22217
  }
@@ -22240,8 +22231,7 @@ var ApiGatewayProvider = class _ApiGatewayProvider {
22240
22231
  new GetResourceCommand3({ restApiId, resourceId: physicalId })
22241
22232
  );
22242
22233
  const result = { RestApiId: restApiId };
22243
- if (resp.parentId !== void 0)
22244
- result["ParentId"] = resp.parentId;
22234
+ result["ParentId"] = resp.parentId ?? "";
22245
22235
  if (resp.pathPart !== void 0)
22246
22236
  result["PathPart"] = resp.pathPart;
22247
22237
  return result;
@@ -22260,9 +22250,7 @@ var ApiGatewayProvider = class _ApiGatewayProvider {
22260
22250
  new GetDeploymentCommand({ restApiId, deploymentId: physicalId })
22261
22251
  );
22262
22252
  const result = { RestApiId: restApiId };
22263
- if (resp.description !== void 0 && resp.description !== "") {
22264
- result["Description"] = resp.description;
22265
- }
22253
+ result["Description"] = resp.description ?? "";
22266
22254
  return result;
22267
22255
  } catch (err) {
22268
22256
  if (err instanceof NotFoundException3)
@@ -22281,11 +22269,8 @@ var ApiGatewayProvider = class _ApiGatewayProvider {
22281
22269
  const result = { RestApiId: restApiId };
22282
22270
  if (resp.stageName !== void 0)
22283
22271
  result["StageName"] = resp.stageName;
22284
- if (resp.deploymentId !== void 0)
22285
- result["DeploymentId"] = resp.deploymentId;
22286
- if (resp.description !== void 0 && resp.description !== "") {
22287
- result["Description"] = resp.description;
22288
- }
22272
+ result["DeploymentId"] = resp.deploymentId ?? "";
22273
+ result["Description"] = resp.description ?? "";
22289
22274
  return result;
22290
22275
  } catch (err) {
22291
22276
  if (err instanceof NotFoundException3)
@@ -22297,9 +22282,7 @@ var ApiGatewayProvider = class _ApiGatewayProvider {
22297
22282
  try {
22298
22283
  const resp = await this.apiGatewayClient.send(new GetAccountCommand({}));
22299
22284
  const result = {};
22300
- if (resp.cloudwatchRoleArn !== void 0) {
22301
- result["CloudWatchRoleArn"] = resp.cloudwatchRoleArn;
22302
- }
22285
+ result["CloudWatchRoleArn"] = resp.cloudwatchRoleArn ?? "";
22303
22286
  return result;
22304
22287
  } catch (err) {
22305
22288
  if (err instanceof NotFoundException3)
@@ -22326,12 +22309,9 @@ var ApiGatewayProvider = class _ApiGatewayProvider {
22326
22309
  if (resp.authorizationType !== void 0) {
22327
22310
  result["AuthorizationType"] = resp.authorizationType;
22328
22311
  }
22329
- if (resp.authorizerId !== void 0)
22330
- result["AuthorizerId"] = resp.authorizerId;
22331
- if (resp.methodIntegration)
22332
- result["Integration"] = resp.methodIntegration;
22333
- if (resp.methodResponses)
22334
- result["MethodResponses"] = resp.methodResponses;
22312
+ result["AuthorizerId"] = resp.authorizerId ?? "";
22313
+ result["Integration"] = resp.methodIntegration ?? {};
22314
+ result["MethodResponses"] = resp.methodResponses ?? {};
22335
22315
  return result;
22336
22316
  } catch (err) {
22337
22317
  if (err instanceof NotFoundException3)
@@ -22961,15 +22941,11 @@ var ApiGatewayV2Provider = class {
22961
22941
  try {
22962
22942
  const resp = await this.getClient().send(new GetApiCommand({ ApiId: physicalId }));
22963
22943
  const result = {};
22964
- if (resp.Name !== void 0)
22965
- result["Name"] = resp.Name;
22944
+ result["Name"] = resp.Name ?? "";
22966
22945
  if (resp.ProtocolType !== void 0)
22967
22946
  result["ProtocolType"] = resp.ProtocolType;
22968
- if (resp.Description !== void 0 && resp.Description !== "") {
22969
- result["Description"] = resp.Description;
22970
- }
22971
- if (resp.CorsConfiguration)
22972
- result["CorsConfiguration"] = resp.CorsConfiguration;
22947
+ result["Description"] = resp.Description ?? "";
22948
+ result["CorsConfiguration"] = resp.CorsConfiguration ?? {};
22973
22949
  const tags = normalizeAwsTagsToCfn(resp.Tags);
22974
22950
  result["Tags"] = tags;
22975
22951
  return result;
@@ -22990,11 +22966,8 @@ var ApiGatewayV2Provider = class {
22990
22966
  const result = { ApiId: apiId };
22991
22967
  if (resp.StageName !== void 0)
22992
22968
  result["StageName"] = resp.StageName;
22993
- if (resp.AutoDeploy !== void 0)
22994
- result["AutoDeploy"] = resp.AutoDeploy;
22995
- if (resp.Description !== void 0 && resp.Description !== "") {
22996
- result["Description"] = resp.Description;
22997
- }
22969
+ result["AutoDeploy"] = resp.AutoDeploy ?? false;
22970
+ result["Description"] = resp.Description ?? "";
22998
22971
  return result;
22999
22972
  } catch (err) {
23000
22973
  if (err instanceof NotFoundException4)
@@ -23013,13 +22986,9 @@ var ApiGatewayV2Provider = class {
23013
22986
  const result = { ApiId: apiId };
23014
22987
  if (resp.IntegrationType !== void 0)
23015
22988
  result["IntegrationType"] = resp.IntegrationType;
23016
- if (resp.IntegrationUri !== void 0)
23017
- result["IntegrationUri"] = resp.IntegrationUri;
23018
- if (resp.IntegrationMethod !== void 0)
23019
- result["IntegrationMethod"] = resp.IntegrationMethod;
23020
- if (resp.PayloadFormatVersion !== void 0) {
23021
- result["PayloadFormatVersion"] = resp.PayloadFormatVersion;
23022
- }
22989
+ result["IntegrationUri"] = resp.IntegrationUri ?? "";
22990
+ result["IntegrationMethod"] = resp.IntegrationMethod ?? "";
22991
+ result["PayloadFormatVersion"] = resp.PayloadFormatVersion ?? "";
23023
22992
  return result;
23024
22993
  } catch (err) {
23025
22994
  if (err instanceof NotFoundException4)
@@ -23038,12 +23007,9 @@ var ApiGatewayV2Provider = class {
23038
23007
  const result = { ApiId: apiId };
23039
23008
  if (resp.RouteKey !== void 0)
23040
23009
  result["RouteKey"] = resp.RouteKey;
23041
- if (resp.Target !== void 0)
23042
- result["Target"] = resp.Target;
23043
- if (resp.AuthorizationType !== void 0)
23044
- result["AuthorizationType"] = resp.AuthorizationType;
23045
- if (resp.AuthorizerId !== void 0)
23046
- result["AuthorizerId"] = resp.AuthorizerId;
23010
+ result["Target"] = resp.Target ?? "";
23011
+ result["AuthorizationType"] = resp.AuthorizationType ?? "";
23012
+ result["AuthorizerId"] = resp.AuthorizerId ?? "";
23047
23013
  return result;
23048
23014
  } catch (err) {
23049
23015
  if (err instanceof NotFoundException4)
@@ -23062,18 +23028,11 @@ var ApiGatewayV2Provider = class {
23062
23028
  const result = { ApiId: apiId };
23063
23029
  if (resp.AuthorizerType !== void 0)
23064
23030
  result["AuthorizerType"] = resp.AuthorizerType;
23065
- if (resp.Name !== void 0)
23066
- result["Name"] = resp.Name;
23067
- if (resp.IdentitySource !== void 0 && resp.IdentitySource.length > 0) {
23068
- result["IdentitySource"] = [...resp.IdentitySource];
23069
- }
23070
- if (resp.JwtConfiguration)
23071
- result["JwtConfiguration"] = resp.JwtConfiguration;
23072
- if (resp.AuthorizerUri !== void 0)
23073
- result["AuthorizerUri"] = resp.AuthorizerUri;
23074
- if (resp.AuthorizerPayloadFormatVersion !== void 0) {
23075
- result["AuthorizerPayloadFormatVersion"] = resp.AuthorizerPayloadFormatVersion;
23076
- }
23031
+ result["Name"] = resp.Name ?? "";
23032
+ result["IdentitySource"] = resp.IdentitySource ? [...resp.IdentitySource] : [];
23033
+ result["JwtConfiguration"] = resp.JwtConfiguration ?? {};
23034
+ result["AuthorizerUri"] = resp.AuthorizerUri ?? "";
23035
+ result["AuthorizerPayloadFormatVersion"] = resp.AuthorizerPayloadFormatVersion ?? "";
23077
23036
  return result;
23078
23037
  } catch (err) {
23079
23038
  if (err instanceof NotFoundException4)
@@ -30839,21 +30798,19 @@ var AppSyncProvider = class {
30839
30798
  if (api.authenticationType !== void 0) {
30840
30799
  result["AuthenticationType"] = api.authenticationType;
30841
30800
  }
30842
- if (api.xrayEnabled !== void 0)
30843
- result["XrayEnabled"] = api.xrayEnabled;
30844
- if (api.logConfig) {
30801
+ result["XrayEnabled"] = api.xrayEnabled ?? false;
30802
+ {
30845
30803
  const log = {};
30846
- if (api.logConfig.cloudWatchLogsRoleArn !== void 0) {
30804
+ if (api.logConfig?.cloudWatchLogsRoleArn !== void 0) {
30847
30805
  log["CloudWatchLogsRoleArn"] = api.logConfig.cloudWatchLogsRoleArn;
30848
30806
  }
30849
- if (api.logConfig.fieldLogLevel !== void 0) {
30807
+ if (api.logConfig?.fieldLogLevel !== void 0) {
30850
30808
  log["FieldLogLevel"] = api.logConfig.fieldLogLevel;
30851
30809
  }
30852
- if (api.logConfig.excludeVerboseContent !== void 0) {
30810
+ if (api.logConfig?.excludeVerboseContent !== void 0) {
30853
30811
  log["ExcludeVerboseContent"] = api.logConfig.excludeVerboseContent;
30854
30812
  }
30855
- if (Object.keys(log).length > 0)
30856
- result["LogConfig"] = log;
30813
+ result["LogConfig"] = log;
30857
30814
  }
30858
30815
  const tags = normalizeAwsTagsToCfn(api.tags);
30859
30816
  result["Tags"] = tags;
@@ -30879,11 +30836,8 @@ var AppSyncProvider = class {
30879
30836
  result["Name"] = ds.name;
30880
30837
  if (ds.type !== void 0)
30881
30838
  result["Type"] = ds.type;
30882
- if (ds.description !== void 0 && ds.description !== "") {
30883
- result["Description"] = ds.description;
30884
- }
30885
- if (ds.serviceRoleArn !== void 0)
30886
- result["ServiceRoleArn"] = ds.serviceRoleArn;
30839
+ result["Description"] = ds.description ?? "";
30840
+ result["ServiceRoleArn"] = ds.serviceRoleArn ?? "";
30887
30841
  if (ds.dynamodbConfig) {
30888
30842
  const dynamo = {};
30889
30843
  if (ds.dynamodbConfig.tableName !== void 0)
@@ -30929,31 +30883,24 @@ var AppSyncProvider = class {
30929
30883
  result["TypeName"] = resolver.typeName;
30930
30884
  if (resolver.fieldName !== void 0)
30931
30885
  result["FieldName"] = resolver.fieldName;
30932
- if (resolver.dataSourceName !== void 0)
30933
- result["DataSourceName"] = resolver.dataSourceName;
30934
- if (resolver.requestMappingTemplate !== void 0) {
30935
- result["RequestMappingTemplate"] = resolver.requestMappingTemplate;
30936
- }
30937
- if (resolver.responseMappingTemplate !== void 0) {
30938
- result["ResponseMappingTemplate"] = resolver.responseMappingTemplate;
30939
- }
30886
+ result["DataSourceName"] = resolver.dataSourceName ?? "";
30887
+ result["RequestMappingTemplate"] = resolver.requestMappingTemplate ?? "";
30888
+ result["ResponseMappingTemplate"] = resolver.responseMappingTemplate ?? "";
30940
30889
  if (resolver.kind !== void 0)
30941
30890
  result["Kind"] = resolver.kind;
30942
- if (resolver.pipelineConfig?.functions && resolver.pipelineConfig.functions.length > 0) {
30943
- result["PipelineConfig"] = { Functions: [...resolver.pipelineConfig.functions] };
30944
- }
30945
- if (resolver.runtime) {
30891
+ result["PipelineConfig"] = {
30892
+ Functions: resolver.pipelineConfig?.functions ? [...resolver.pipelineConfig.functions] : []
30893
+ };
30894
+ {
30946
30895
  const runtime = {};
30947
- if (resolver.runtime.name !== void 0)
30896
+ if (resolver.runtime?.name !== void 0)
30948
30897
  runtime["Name"] = resolver.runtime.name;
30949
- if (resolver.runtime.runtimeVersion !== void 0) {
30898
+ if (resolver.runtime?.runtimeVersion !== void 0) {
30950
30899
  runtime["RuntimeVersion"] = resolver.runtime.runtimeVersion;
30951
30900
  }
30952
- if (Object.keys(runtime).length > 0)
30953
- result["Runtime"] = runtime;
30901
+ result["Runtime"] = runtime;
30954
30902
  }
30955
- if (resolver.code !== void 0)
30956
- result["Code"] = resolver.code;
30903
+ result["Code"] = resolver.code ?? "";
30957
30904
  return result;
30958
30905
  }
30959
30906
  async readApiKey(physicalId) {
@@ -30975,9 +30922,7 @@ var AppSyncProvider = class {
30975
30922
  for (const key of resp.apiKeys ?? []) {
30976
30923
  if (key.id === apiKeyId) {
30977
30924
  const result = { ApiId: apiId };
30978
- if (key.description !== void 0 && key.description !== "") {
30979
- result["Description"] = key.description;
30980
- }
30925
+ result["Description"] = key.description ?? "";
30981
30926
  if (key.expires !== void 0)
30982
30927
  result["Expires"] = key.expires;
30983
30928
  return result;
@@ -42659,7 +42604,7 @@ function reorderArgs(argv) {
42659
42604
  }
42660
42605
  async function main() {
42661
42606
  const program = new Command14();
42662
- program.name("cdkd").description("CDK Direct - Deploy AWS CDK apps directly via SDK/Cloud Control API").version("0.50.2");
42607
+ program.name("cdkd").description("CDK Direct - Deploy AWS CDK apps directly via SDK/Cloud Control API").version("0.50.3");
42663
42608
  program.addCommand(createBootstrapCommand());
42664
42609
  program.addCommand(createSynthCommand());
42665
42610
  program.addCommand(createListCommand());