File Explorer

/var/runtime/node_modules/@aws-sdk/client-rbin/dist-cjs

This explorer reads the filesystem of the server it runs on, so /workspace/user isn't present here. Browsing and the terminal still work against this server's own disk from /.

2 dirs
3 files
index.js38.8 KB · 1017 lines
"use strict";var __defProp = Object.defineProperty;var __getOwnPropDesc = Object.getOwnPropertyDescriptor;var __getOwnPropNames = Object.getOwnPropertyNames;var __hasOwnProp = Object.prototype.hasOwnProperty;var __name = (target, value) => __defProp(target, "name", { value, configurable: true });var __export = (target, all) => {  for (var name in all)    __defProp(target, name, { get: all[name], enumerable: true });};var __copyProps = (to, from, except, desc) => {  if (from && typeof from === "object" || typeof from === "function") {    for (let key of __getOwnPropNames(from))      if (!__hasOwnProp.call(to, key) && key !== except)        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });  }  return to;};var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); // src/index.tsvar index_exports = {};__export(index_exports, {  ConflictException: () => ConflictException,  ConflictExceptionReason: () => ConflictExceptionReason,  CreateRuleCommand: () => CreateRuleCommand,  DeleteRuleCommand: () => DeleteRuleCommand,  GetRuleCommand: () => GetRuleCommand,  InternalServerException: () => InternalServerException,  ListRulesCommand: () => ListRulesCommand,  ListTagsForResourceCommand: () => ListTagsForResourceCommand,  LockRuleCommand: () => LockRuleCommand,  LockState: () => LockState,  Rbin: () => Rbin,  RbinClient: () => RbinClient,  RbinServiceException: () => RbinServiceException,  ResourceNotFoundException: () => ResourceNotFoundException,  ResourceNotFoundExceptionReason: () => ResourceNotFoundExceptionReason,  ResourceType: () => ResourceType,  RetentionPeriodUnit: () => RetentionPeriodUnit,  RuleStatus: () => RuleStatus,  ServiceQuotaExceededException: () => ServiceQuotaExceededException,  ServiceQuotaExceededExceptionReason: () => ServiceQuotaExceededExceptionReason,  TagResourceCommand: () => TagResourceCommand,  UnlockDelayUnit: () => UnlockDelayUnit,  UnlockRuleCommand: () => UnlockRuleCommand,  UntagResourceCommand: () => UntagResourceCommand,  UpdateRuleCommand: () => UpdateRuleCommand,  ValidationException: () => ValidationException,  ValidationExceptionReason: () => ValidationExceptionReason,  __Client: () => import_smithy_client.Client,  paginateListRules: () => paginateListRules});module.exports = __toCommonJS(index_exports); // src/RbinClient.tsvar import_middleware_host_header = require("@aws-sdk/middleware-host-header");var import_middleware_logger = require("@aws-sdk/middleware-logger");var import_middleware_recursion_detection = require("@aws-sdk/middleware-recursion-detection");var import_middleware_user_agent = require("@aws-sdk/middleware-user-agent");var import_config_resolver = require("@smithy/config-resolver");var import_core = require("@smithy/core");var import_middleware_content_length = require("@smithy/middleware-content-length");var import_middleware_endpoint = require("@smithy/middleware-endpoint");var import_middleware_retry = require("@smithy/middleware-retry"); var import_httpAuthSchemeProvider = require("./auth/httpAuthSchemeProvider"); // src/endpoint/EndpointParameters.tsvar resolveClientEndpointParameters = /* @__PURE__ */ __name((options) => {  return Object.assign(options, {    useDualstackEndpoint: options.useDualstackEndpoint ?? false,    useFipsEndpoint: options.useFipsEndpoint ?? false,    defaultSigningName: "rbin"  });}, "resolveClientEndpointParameters");var commonParams = {  UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },  Endpoint: { type: "builtInParams", name: "endpoint" },  Region: { type: "builtInParams", name: "region" },  UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }}; // src/RbinClient.tsvar import_runtimeConfig = require("././runtimeConfig"); // src/runtimeExtensions.tsvar import_region_config_resolver = require("@aws-sdk/region-config-resolver");var import_protocol_http = require("@smithy/protocol-http");var import_smithy_client = require("@smithy/smithy-client"); // src/auth/httpAuthExtensionConfiguration.tsvar getHttpAuthExtensionConfiguration = /* @__PURE__ */ __name((runtimeConfig) => {  const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;  let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;  let _credentials = runtimeConfig.credentials;  return {    setHttpAuthScheme(httpAuthScheme) {      const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);      if (index === -1) {        _httpAuthSchemes.push(httpAuthScheme);      } else {        _httpAuthSchemes.splice(index, 1, httpAuthScheme);      }    },    httpAuthSchemes() {      return _httpAuthSchemes;    },    setHttpAuthSchemeProvider(httpAuthSchemeProvider) {      _httpAuthSchemeProvider = httpAuthSchemeProvider;    },    httpAuthSchemeProvider() {      return _httpAuthSchemeProvider;    },    setCredentials(credentials) {      _credentials = credentials;    },    credentials() {      return _credentials;    }  };}, "getHttpAuthExtensionConfiguration");var resolveHttpAuthRuntimeConfig = /* @__PURE__ */ __name((config) => {  return {    httpAuthSchemes: config.httpAuthSchemes(),    httpAuthSchemeProvider: config.httpAuthSchemeProvider(),    credentials: config.credentials()  };}, "resolveHttpAuthRuntimeConfig"); // src/runtimeExtensions.tsvar resolveRuntimeExtensions = /* @__PURE__ */ __name((runtimeConfig, extensions) => {  const extensionConfiguration = Object.assign(    (0, import_region_config_resolver.getAwsRegionExtensionConfiguration)(runtimeConfig),    (0, import_smithy_client.getDefaultExtensionConfiguration)(runtimeConfig),    (0, import_protocol_http.getHttpHandlerExtensionConfiguration)(runtimeConfig),    getHttpAuthExtensionConfiguration(runtimeConfig)  );  extensions.forEach((extension) => extension.configure(extensionConfiguration));  return Object.assign(    runtimeConfig,    (0, import_region_config_resolver.resolveAwsRegionExtensionConfiguration)(extensionConfiguration),    (0, import_smithy_client.resolveDefaultRuntimeConfig)(extensionConfiguration),    (0, import_protocol_http.resolveHttpHandlerRuntimeConfig)(extensionConfiguration),    resolveHttpAuthRuntimeConfig(extensionConfiguration)  );}, "resolveRuntimeExtensions"); // src/RbinClient.tsvar RbinClient = class extends import_smithy_client.Client {  static {    __name(this, "RbinClient");  }  /**   * The resolved configuration of RbinClient class. This is resolved and normalized from the {@link RbinClientConfig | constructor configuration interface}.   */  config;  constructor(...[configuration]) {    const _config_0 = (0, import_runtimeConfig.getRuntimeConfig)(configuration || {});    super(_config_0);    this.initConfig = _config_0;    const _config_1 = resolveClientEndpointParameters(_config_0);    const _config_2 = (0, import_middleware_user_agent.resolveUserAgentConfig)(_config_1);    const _config_3 = (0, import_middleware_retry.resolveRetryConfig)(_config_2);    const _config_4 = (0, import_config_resolver.resolveRegionConfig)(_config_3);    const _config_5 = (0, import_middleware_host_header.resolveHostHeaderConfig)(_config_4);    const _config_6 = (0, import_middleware_endpoint.resolveEndpointConfig)(_config_5);    const _config_7 = (0, import_httpAuthSchemeProvider.resolveHttpAuthSchemeConfig)(_config_6);    const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);    this.config = _config_8;    this.middlewareStack.use((0, import_middleware_user_agent.getUserAgentPlugin)(this.config));    this.middlewareStack.use((0, import_middleware_retry.getRetryPlugin)(this.config));    this.middlewareStack.use((0, import_middleware_content_length.getContentLengthPlugin)(this.config));    this.middlewareStack.use((0, import_middleware_host_header.getHostHeaderPlugin)(this.config));    this.middlewareStack.use((0, import_middleware_logger.getLoggerPlugin)(this.config));    this.middlewareStack.use((0, import_middleware_recursion_detection.getRecursionDetectionPlugin)(this.config));    this.middlewareStack.use(      (0, import_core.getHttpAuthSchemeEndpointRuleSetPlugin)(this.config, {        httpAuthSchemeParametersProvider: import_httpAuthSchemeProvider.defaultRbinHttpAuthSchemeParametersProvider,        identityProviderConfigProvider: /* @__PURE__ */ __name(async (config) => new import_core.DefaultIdentityProviderConfig({          "aws.auth#sigv4": config.credentials        }), "identityProviderConfigProvider")      })    );    this.middlewareStack.use((0, import_core.getHttpSigningPlugin)(this.config));  }  /**   * Destroy underlying resources, like sockets. It's usually not necessary to do this.   * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.   * Otherwise, sockets might stay open for quite a long time before the server terminates them.   */  destroy() {    super.destroy();  }}; // src/Rbin.ts  // src/commands/CreateRuleCommand.ts var import_middleware_serde = require("@smithy/middleware-serde");  // src/protocols/Aws_restJson1.tsvar import_core2 = require("@aws-sdk/core");   // src/models/RbinServiceException.ts var RbinServiceException = class _RbinServiceException extends import_smithy_client.ServiceException {  static {    __name(this, "RbinServiceException");  }  /**   * @internal   */  constructor(options) {    super(options);    Object.setPrototypeOf(this, _RbinServiceException.prototype);  }}; // src/models/models_0.tsvar UnlockDelayUnit = {  DAYS: "DAYS"};var ResourceType = {  EBS_SNAPSHOT: "EBS_SNAPSHOT",  EC2_IMAGE: "EC2_IMAGE"};var RetentionPeriodUnit = {  DAYS: "DAYS"};var LockState = {  LOCKED: "locked",  PENDING_UNLOCK: "pending_unlock",  UNLOCKED: "unlocked"};var RuleStatus = {  AVAILABLE: "available",  PENDING: "pending"};var InternalServerException = class _InternalServerException extends RbinServiceException {  static {    __name(this, "InternalServerException");  }  name = "InternalServerException";  $fault = "server";  Message;  /**   * @internal   */  constructor(opts) {    super({      name: "InternalServerException",      $fault: "server",      ...opts    });    Object.setPrototypeOf(this, _InternalServerException.prototype);    this.Message = opts.Message;  }};var ServiceQuotaExceededExceptionReason = {  SERVICE_QUOTA_EXCEEDED: "SERVICE_QUOTA_EXCEEDED"};var ServiceQuotaExceededException = class _ServiceQuotaExceededException extends RbinServiceException {  static {    __name(this, "ServiceQuotaExceededException");  }  name = "ServiceQuotaExceededException";  $fault = "client";  Message;  /**   * <p>The reason for the exception.</p>   * @public   */  Reason;  /**   * @internal   */  constructor(opts) {    super({      name: "ServiceQuotaExceededException",      $fault: "client",      ...opts    });    Object.setPrototypeOf(this, _ServiceQuotaExceededException.prototype);    this.Message = opts.Message;    this.Reason = opts.Reason;  }};var ValidationExceptionReason = {  INVALID_PAGE_TOKEN: "INVALID_PAGE_TOKEN",  INVALID_PARAMETER_VALUE: "INVALID_PARAMETER_VALUE"};var ValidationException = class _ValidationException extends RbinServiceException {  static {    __name(this, "ValidationException");  }  name = "ValidationException";  $fault = "client";  Message;  /**   * <p>The reason for the exception.</p>   * @public   */  Reason;  /**   * @internal   */  constructor(opts) {    super({      name: "ValidationException",      $fault: "client",      ...opts    });    Object.setPrototypeOf(this, _ValidationException.prototype);    this.Message = opts.Message;    this.Reason = opts.Reason;  }};var ConflictExceptionReason = {  INVALID_RULE_STATE: "INVALID_RULE_STATE"};var ConflictException = class _ConflictException extends RbinServiceException {  static {    __name(this, "ConflictException");  }  name = "ConflictException";  $fault = "client";  Message;  /**   * <p>The reason for the exception.</p>   * @public   */  Reason;  /**   * @internal   */  constructor(opts) {    super({      name: "ConflictException",      $fault: "client",      ...opts    });    Object.setPrototypeOf(this, _ConflictException.prototype);    this.Message = opts.Message;    this.Reason = opts.Reason;  }};var ResourceNotFoundExceptionReason = {  RULE_NOT_FOUND: "RULE_NOT_FOUND"};var ResourceNotFoundException = class _ResourceNotFoundException extends RbinServiceException {  static {    __name(this, "ResourceNotFoundException");  }  name = "ResourceNotFoundException";  $fault = "client";  Message;  /**   * <p>The reason for the exception.</p>   * @public   */  Reason;  /**   * @internal   */  constructor(opts) {    super({      name: "ResourceNotFoundException",      $fault: "client",      ...opts    });    Object.setPrototypeOf(this, _ResourceNotFoundException.prototype);    this.Message = opts.Message;    this.Reason = opts.Reason;  }}; // src/protocols/Aws_restJson1.tsvar se_CreateRuleCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {    "content-type": "application/json"  };  b.bp("/rules");  let body;  body = JSON.stringify(    (0, import_smithy_client.take)(input, {      Description: [],      ExcludeResourceTags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "ExcludeResourceTags"),      LockConfiguration: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "LockConfiguration"),      ResourceTags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "ResourceTags"),      ResourceType: [],      RetentionPeriod: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "RetentionPeriod"),      Tags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "Tags")    })  );  b.m("POST").h(headers).b(body);  return b.build();}, "se_CreateRuleCommand");var se_DeleteRuleCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {};  b.bp("/rules/{Identifier}");  b.p("Identifier", () => input.Identifier, "{Identifier}", false);  let body;  b.m("DELETE").h(headers).b(body);  return b.build();}, "se_DeleteRuleCommand");var se_GetRuleCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {};  b.bp("/rules/{Identifier}");  b.p("Identifier", () => input.Identifier, "{Identifier}", false);  let body;  b.m("GET").h(headers).b(body);  return b.build();}, "se_GetRuleCommand");var se_ListRulesCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {    "content-type": "application/json"  };  b.bp("/list-rules");  let body;  body = JSON.stringify(    (0, import_smithy_client.take)(input, {      ExcludeResourceTags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "ExcludeResourceTags"),      LockState: [],      MaxResults: [],      NextToken: [],      ResourceTags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "ResourceTags"),      ResourceType: []    })  );  b.m("POST").h(headers).b(body);  return b.build();}, "se_ListRulesCommand");var se_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {};  b.bp("/tags/{ResourceArn}");  b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);  let body;  b.m("GET").h(headers).b(body);  return b.build();}, "se_ListTagsForResourceCommand");var se_LockRuleCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {    "content-type": "application/json"  };  b.bp("/rules/{Identifier}/lock");  b.p("Identifier", () => input.Identifier, "{Identifier}", false);  let body;  body = JSON.stringify(    (0, import_smithy_client.take)(input, {      LockConfiguration: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "LockConfiguration")    })  );  b.m("PATCH").h(headers).b(body);  return b.build();}, "se_LockRuleCommand");var se_TagResourceCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {    "content-type": "application/json"  };  b.bp("/tags/{ResourceArn}");  b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);  let body;  body = JSON.stringify(    (0, import_smithy_client.take)(input, {      Tags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "Tags")    })  );  b.m("POST").h(headers).b(body);  return b.build();}, "se_TagResourceCommand");var se_UnlockRuleCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {};  b.bp("/rules/{Identifier}/unlock");  b.p("Identifier", () => input.Identifier, "{Identifier}", false);  let body;  b.m("PATCH").h(headers).b(body);  return b.build();}, "se_UnlockRuleCommand");var se_UntagResourceCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {};  b.bp("/tags/{ResourceArn}");  b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);  const query = (0, import_smithy_client.map)({    [_tK]: [(0, import_smithy_client.expectNonNull)(input.TagKeys, `TagKeys`) != null, () => input[_TK] || []]  });  let body;  b.m("DELETE").h(headers).q(query).b(body);  return b.build();}, "se_UntagResourceCommand");var se_UpdateRuleCommand = /* @__PURE__ */ __name(async (input, context) => {  const b = (0, import_core.requestBuilder)(input, context);  const headers = {    "content-type": "application/json"  };  b.bp("/rules/{Identifier}");  b.p("Identifier", () => input.Identifier, "{Identifier}", false);  let body;  body = JSON.stringify(    (0, import_smithy_client.take)(input, {      Description: [],      ExcludeResourceTags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "ExcludeResourceTags"),      ResourceTags: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "ResourceTags"),      ResourceType: [],      RetentionPeriod: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "RetentionPeriod")    })  );  b.m("PATCH").h(headers).b(body);  return b.build();}, "se_UpdateRuleCommand");var de_CreateRuleCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 201 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    Description: import_smithy_client.expectString,    ExcludeResourceTags: import_smithy_client._json,    Identifier: import_smithy_client.expectString,    LockConfiguration: import_smithy_client._json,    LockState: import_smithy_client.expectString,    ResourceTags: import_smithy_client._json,    ResourceType: import_smithy_client.expectString,    RetentionPeriod: import_smithy_client._json,    RuleArn: import_smithy_client.expectString,    Status: import_smithy_client.expectString,    Tags: import_smithy_client._json  });  Object.assign(contents, doc);  return contents;}, "de_CreateRuleCommand");var de_DeleteRuleCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 204 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  await (0, import_smithy_client.collectBody)(output.body, context);  return contents;}, "de_DeleteRuleCommand");var de_GetRuleCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 200 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    Description: import_smithy_client.expectString,    ExcludeResourceTags: import_smithy_client._json,    Identifier: import_smithy_client.expectString,    LockConfiguration: import_smithy_client._json,    LockEndTime: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseEpochTimestamp)((0, import_smithy_client.expectNumber)(_))), "LockEndTime"),    LockState: import_smithy_client.expectString,    ResourceTags: import_smithy_client._json,    ResourceType: import_smithy_client.expectString,    RetentionPeriod: import_smithy_client._json,    RuleArn: import_smithy_client.expectString,    Status: import_smithy_client.expectString  });  Object.assign(contents, doc);  return contents;}, "de_GetRuleCommand");var de_ListRulesCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 200 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    NextToken: import_smithy_client.expectString,    Rules: import_smithy_client._json  });  Object.assign(contents, doc);  return contents;}, "de_ListRulesCommand");var de_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 200 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    Tags: import_smithy_client._json  });  Object.assign(contents, doc);  return contents;}, "de_ListTagsForResourceCommand");var de_LockRuleCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 200 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    Description: import_smithy_client.expectString,    ExcludeResourceTags: import_smithy_client._json,    Identifier: import_smithy_client.expectString,    LockConfiguration: import_smithy_client._json,    LockState: import_smithy_client.expectString,    ResourceTags: import_smithy_client._json,    ResourceType: import_smithy_client.expectString,    RetentionPeriod: import_smithy_client._json,    RuleArn: import_smithy_client.expectString,    Status: import_smithy_client.expectString  });  Object.assign(contents, doc);  return contents;}, "de_LockRuleCommand");var de_TagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 201 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  await (0, import_smithy_client.collectBody)(output.body, context);  return contents;}, "de_TagResourceCommand");var de_UnlockRuleCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 200 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    Description: import_smithy_client.expectString,    ExcludeResourceTags: import_smithy_client._json,    Identifier: import_smithy_client.expectString,    LockConfiguration: import_smithy_client._json,    LockEndTime: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseEpochTimestamp)((0, import_smithy_client.expectNumber)(_))), "LockEndTime"),    LockState: import_smithy_client.expectString,    ResourceTags: import_smithy_client._json,    ResourceType: import_smithy_client.expectString,    RetentionPeriod: import_smithy_client._json,    RuleArn: import_smithy_client.expectString,    Status: import_smithy_client.expectString  });  Object.assign(contents, doc);  return contents;}, "de_UnlockRuleCommand");var de_UntagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 204 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  await (0, import_smithy_client.collectBody)(output.body, context);  return contents;}, "de_UntagResourceCommand");var de_UpdateRuleCommand = /* @__PURE__ */ __name(async (output, context) => {  if (output.statusCode !== 200 && output.statusCode >= 300) {    return de_CommandError(output, context);  }  const contents = (0, import_smithy_client.map)({    $metadata: deserializeMetadata(output)  });  const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");  const doc = (0, import_smithy_client.take)(data, {    Description: import_smithy_client.expectString,    ExcludeResourceTags: import_smithy_client._json,    Identifier: import_smithy_client.expectString,    LockEndTime: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseEpochTimestamp)((0, import_smithy_client.expectNumber)(_))), "LockEndTime"),    LockState: import_smithy_client.expectString,    ResourceTags: import_smithy_client._json,    ResourceType: import_smithy_client.expectString,    RetentionPeriod: import_smithy_client._json,    RuleArn: import_smithy_client.expectString,    Status: import_smithy_client.expectString  });  Object.assign(contents, doc);  return contents;}, "de_UpdateRuleCommand");var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {  const parsedOutput = {    ...output,    body: await (0, import_core2.parseJsonErrorBody)(output.body, context)  };  const errorCode = (0, import_core2.loadRestJsonErrorCode)(output, parsedOutput.body);  switch (errorCode) {    case "InternalServerException":    case "com.amazonaws.rbin#InternalServerException":      throw await de_InternalServerExceptionRes(parsedOutput, context);    case "ServiceQuotaExceededException":    case "com.amazonaws.rbin#ServiceQuotaExceededException":      throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);    case "ValidationException":    case "com.amazonaws.rbin#ValidationException":      throw await de_ValidationExceptionRes(parsedOutput, context);    case "ConflictException":    case "com.amazonaws.rbin#ConflictException":      throw await de_ConflictExceptionRes(parsedOutput, context);    case "ResourceNotFoundException":    case "com.amazonaws.rbin#ResourceNotFoundException":      throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);    default:      const parsedBody = parsedOutput.body;      return throwDefaultError({        output,        parsedBody,        errorCode      });  }}, "de_CommandError");var throwDefaultError = (0, import_smithy_client.withBaseException)(RbinServiceException);var de_ConflictExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {  const contents = (0, import_smithy_client.map)({});  const data = parsedOutput.body;  const doc = (0, import_smithy_client.take)(data, {    Message: import_smithy_client.expectString,    Reason: import_smithy_client.expectString  });  Object.assign(contents, doc);  const exception = new ConflictException({    $metadata: deserializeMetadata(parsedOutput),    ...contents  });  return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);}, "de_ConflictExceptionRes");var de_InternalServerExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {  const contents = (0, import_smithy_client.map)({});  const data = parsedOutput.body;  const doc = (0, import_smithy_client.take)(data, {    Message: import_smithy_client.expectString  });  Object.assign(contents, doc);  const exception = new InternalServerException({    $metadata: deserializeMetadata(parsedOutput),    ...contents  });  return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);}, "de_InternalServerExceptionRes");var de_ResourceNotFoundExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {  const contents = (0, import_smithy_client.map)({});  const data = parsedOutput.body;  const doc = (0, import_smithy_client.take)(data, {    Message: import_smithy_client.expectString,    Reason: import_smithy_client.expectString  });  Object.assign(contents, doc);  const exception = new ResourceNotFoundException({    $metadata: deserializeMetadata(parsedOutput),    ...contents  });  return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);}, "de_ResourceNotFoundExceptionRes");var de_ServiceQuotaExceededExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {  const contents = (0, import_smithy_client.map)({});  const data = parsedOutput.body;  const doc = (0, import_smithy_client.take)(data, {    Message: import_smithy_client.expectString,    Reason: import_smithy_client.expectString  });  Object.assign(contents, doc);  const exception = new ServiceQuotaExceededException({    $metadata: deserializeMetadata(parsedOutput),    ...contents  });  return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);}, "de_ServiceQuotaExceededExceptionRes");var de_ValidationExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {  const contents = (0, import_smithy_client.map)({});  const data = parsedOutput.body;  const doc = (0, import_smithy_client.take)(data, {    Message: import_smithy_client.expectString,    Reason: import_smithy_client.expectString  });  Object.assign(contents, doc);  const exception = new ValidationException({    $metadata: deserializeMetadata(parsedOutput),    ...contents  });  return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);}, "de_ValidationExceptionRes");var deserializeMetadata = /* @__PURE__ */ __name((output) => ({  httpStatusCode: output.statusCode,  requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],  extendedRequestId: output.headers["x-amz-id-2"],  cfId: output.headers["x-amz-cf-id"]}), "deserializeMetadata");var _TK = "TagKeys";var _tK = "tagKeys"; // src/commands/CreateRuleCommand.tsvar CreateRuleCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "CreateRule", {}).n("RbinClient", "CreateRuleCommand").f(void 0, void 0).ser(se_CreateRuleCommand).de(de_CreateRuleCommand).build() {  static {    __name(this, "CreateRuleCommand");  }}; // src/commands/DeleteRuleCommand.ts   var DeleteRuleCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "DeleteRule", {}).n("RbinClient", "DeleteRuleCommand").f(void 0, void 0).ser(se_DeleteRuleCommand).de(de_DeleteRuleCommand).build() {  static {    __name(this, "DeleteRuleCommand");  }}; // src/commands/GetRuleCommand.ts   var GetRuleCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "GetRule", {}).n("RbinClient", "GetRuleCommand").f(void 0, void 0).ser(se_GetRuleCommand).de(de_GetRuleCommand).build() {  static {    __name(this, "GetRuleCommand");  }}; // src/commands/ListRulesCommand.ts   var ListRulesCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "ListRules", {}).n("RbinClient", "ListRulesCommand").f(void 0, void 0).ser(se_ListRulesCommand).de(de_ListRulesCommand).build() {  static {    __name(this, "ListRulesCommand");  }}; // src/commands/ListTagsForResourceCommand.ts   var ListTagsForResourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "ListTagsForResource", {}).n("RbinClient", "ListTagsForResourceCommand").f(void 0, void 0).ser(se_ListTagsForResourceCommand).de(de_ListTagsForResourceCommand).build() {  static {    __name(this, "ListTagsForResourceCommand");  }}; // src/commands/LockRuleCommand.ts   var LockRuleCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "LockRule", {}).n("RbinClient", "LockRuleCommand").f(void 0, void 0).ser(se_LockRuleCommand).de(de_LockRuleCommand).build() {  static {    __name(this, "LockRuleCommand");  }}; // src/commands/TagResourceCommand.ts   var TagResourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "TagResource", {}).n("RbinClient", "TagResourceCommand").f(void 0, void 0).ser(se_TagResourceCommand).de(de_TagResourceCommand).build() {  static {    __name(this, "TagResourceCommand");  }}; // src/commands/UnlockRuleCommand.ts   var UnlockRuleCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "UnlockRule", {}).n("RbinClient", "UnlockRuleCommand").f(void 0, void 0).ser(se_UnlockRuleCommand).de(de_UnlockRuleCommand).build() {  static {    __name(this, "UnlockRuleCommand");  }}; // src/commands/UntagResourceCommand.ts   var UntagResourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "UntagResource", {}).n("RbinClient", "UntagResourceCommand").f(void 0, void 0).ser(se_UntagResourceCommand).de(de_UntagResourceCommand).build() {  static {    __name(this, "UntagResourceCommand");  }}; // src/commands/UpdateRuleCommand.ts   var UpdateRuleCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {  return [    (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),    (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())  ];}).s("AmazonRecycleBin", "UpdateRule", {}).n("RbinClient", "UpdateRuleCommand").f(void 0, void 0).ser(se_UpdateRuleCommand).de(de_UpdateRuleCommand).build() {  static {    __name(this, "UpdateRuleCommand");  }}; // src/Rbin.tsvar commands = {  CreateRuleCommand,  DeleteRuleCommand,  GetRuleCommand,  ListRulesCommand,  ListTagsForResourceCommand,  LockRuleCommand,  TagResourceCommand,  UnlockRuleCommand,  UntagResourceCommand,  UpdateRuleCommand};var Rbin = class extends RbinClient {  static {    __name(this, "Rbin");  }};(0, import_smithy_client.createAggregatedClient)(commands, Rbin); // src/pagination/ListRulesPaginator.ts var paginateListRules = (0, import_core.createPaginator)(RbinClient, ListRulesCommand, "NextToken", "NextToken", "MaxResults");// Annotate the CommonJS export names for ESM import in node: 0 && (module.exports = {  RbinServiceException,  __Client,  RbinClient,  Rbin,  $Command,  CreateRuleCommand,  DeleteRuleCommand,  GetRuleCommand,  ListRulesCommand,  ListTagsForResourceCommand,  LockRuleCommand,  TagResourceCommand,  UnlockRuleCommand,  UntagResourceCommand,  UpdateRuleCommand,  paginateListRules,  UnlockDelayUnit,  ResourceType,  RetentionPeriodUnit,  LockState,  RuleStatus,  InternalServerException,  ServiceQuotaExceededExceptionReason,  ServiceQuotaExceededException,  ValidationExceptionReason,  ValidationException,  ConflictExceptionReason,  ConflictException,  ResourceNotFoundExceptionReason,  ResourceNotFoundException});