@aws-sdk/client-iot
Version:
AWS SDK for JavaScript Iot Client for Node.js, Browser and React Native
623 lines (622 loc) • 18.7 kB
JavaScript
import { SENSITIVE_STRING } from "@smithy/smithy-client";
import { IoTServiceException as __BaseException } from "./IoTServiceException";
export const AbortAction = {
CANCEL: "CANCEL",
};
export const JobExecutionFailureType = {
ALL: "ALL",
FAILED: "FAILED",
REJECTED: "REJECTED",
TIMED_OUT: "TIMED_OUT",
};
export class InternalFailureException extends __BaseException {
constructor(opts) {
super({
name: "InternalFailureException",
$fault: "server",
...opts,
});
this.name = "InternalFailureException";
this.$fault = "server";
Object.setPrototypeOf(this, InternalFailureException.prototype);
}
}
export class InvalidRequestException extends __BaseException {
constructor(opts) {
super({
name: "InvalidRequestException",
$fault: "client",
...opts,
});
this.name = "InvalidRequestException";
this.$fault = "client";
Object.setPrototypeOf(this, InvalidRequestException.prototype);
}
}
export class ResourceNotFoundException extends __BaseException {
constructor(opts) {
super({
name: "ResourceNotFoundException",
$fault: "client",
...opts,
});
this.name = "ResourceNotFoundException";
this.$fault = "client";
Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
}
}
export class ServiceUnavailableException extends __BaseException {
constructor(opts) {
super({
name: "ServiceUnavailableException",
$fault: "server",
...opts,
});
this.name = "ServiceUnavailableException";
this.$fault = "server";
Object.setPrototypeOf(this, ServiceUnavailableException.prototype);
}
}
export class ThrottlingException extends __BaseException {
constructor(opts) {
super({
name: "ThrottlingException",
$fault: "client",
...opts,
});
this.name = "ThrottlingException";
this.$fault = "client";
Object.setPrototypeOf(this, ThrottlingException.prototype);
}
}
export class TransferAlreadyCompletedException extends __BaseException {
constructor(opts) {
super({
name: "TransferAlreadyCompletedException",
$fault: "client",
...opts,
});
this.name = "TransferAlreadyCompletedException";
this.$fault = "client";
Object.setPrototypeOf(this, TransferAlreadyCompletedException.prototype);
}
}
export class UnauthorizedException extends __BaseException {
constructor(opts) {
super({
name: "UnauthorizedException",
$fault: "client",
...opts,
});
this.name = "UnauthorizedException";
this.$fault = "client";
Object.setPrototypeOf(this, UnauthorizedException.prototype);
}
}
export const DynamoKeyType = {
NUMBER: "NUMBER",
STRING: "STRING",
};
export var AssetPropertyVariant;
(function (AssetPropertyVariant) {
AssetPropertyVariant.visit = (value, visitor) => {
if (value.stringValue !== undefined)
return visitor.stringValue(value.stringValue);
if (value.integerValue !== undefined)
return visitor.integerValue(value.integerValue);
if (value.doubleValue !== undefined)
return visitor.doubleValue(value.doubleValue);
if (value.booleanValue !== undefined)
return visitor.booleanValue(value.booleanValue);
return visitor._(value.$unknown[0], value.$unknown[1]);
};
})(AssetPropertyVariant || (AssetPropertyVariant = {}));
export const CannedAccessControlList = {
AuthenticatedRead: "authenticated-read",
AwsExecRead: "aws-exec-read",
BucketOwnerFullControl: "bucket-owner-full-control",
BucketOwnerRead: "bucket-owner-read",
LogDeliveryWrite: "log-delivery-write",
Private: "private",
PublicRead: "public-read",
PublicReadWrite: "public-read-write",
};
export const MessageFormat = {
JSON: "JSON",
RAW: "RAW",
};
export const ActionType = {
CONNECT: "CONNECT",
PUBLISH: "PUBLISH",
RECEIVE: "RECEIVE",
SUBSCRIBE: "SUBSCRIBE",
};
export const ComparisonOperator = {
GREATER_THAN: "greater-than",
GREATER_THAN_EQUALS: "greater-than-equals",
IN_CIDR_SET: "in-cidr-set",
IN_PORT_SET: "in-port-set",
IN_SET: "in-set",
LESS_THAN: "less-than",
LESS_THAN_EQUALS: "less-than-equals",
NOT_IN_CIDR_SET: "not-in-cidr-set",
NOT_IN_PORT_SET: "not-in-port-set",
NOT_IN_SET: "not-in-set",
};
export const ConfidenceLevel = {
HIGH: "HIGH",
LOW: "LOW",
MEDIUM: "MEDIUM",
};
export const DimensionValueOperator = {
IN: "IN",
NOT_IN: "NOT_IN",
};
export const VerificationState = {
BENIGN_POSITIVE: "BENIGN_POSITIVE",
FALSE_POSITIVE: "FALSE_POSITIVE",
TRUE_POSITIVE: "TRUE_POSITIVE",
UNKNOWN: "UNKNOWN",
};
export const AggregationTypeName = {
CARDINALITY: "Cardinality",
PERCENTILES: "Percentiles",
STATISTICS: "Statistics",
};
export const AlertTargetType = {
SNS: "SNS",
};
export class LimitExceededException extends __BaseException {
constructor(opts) {
super({
name: "LimitExceededException",
$fault: "client",
...opts,
});
this.name = "LimitExceededException";
this.$fault = "client";
Object.setPrototypeOf(this, LimitExceededException.prototype);
}
}
export class VersionConflictException extends __BaseException {
constructor(opts) {
super({
name: "VersionConflictException",
$fault: "client",
...opts,
});
this.name = "VersionConflictException";
this.$fault = "client";
Object.setPrototypeOf(this, VersionConflictException.prototype);
}
}
export const AuditCheckRunStatus = {
CANCELED: "CANCELED",
COMPLETED_COMPLIANT: "COMPLETED_COMPLIANT",
COMPLETED_NON_COMPLIANT: "COMPLETED_NON_COMPLIANT",
FAILED: "FAILED",
IN_PROGRESS: "IN_PROGRESS",
WAITING_FOR_DATA_COLLECTION: "WAITING_FOR_DATA_COLLECTION",
};
export const ResourceType = {
ACCOUNT_SETTINGS: "ACCOUNT_SETTINGS",
CA_CERTIFICATE: "CA_CERTIFICATE",
CLIENT_ID: "CLIENT_ID",
COGNITO_IDENTITY_POOL: "COGNITO_IDENTITY_POOL",
DEVICE_CERTIFICATE: "DEVICE_CERTIFICATE",
IAM_ROLE: "IAM_ROLE",
IOT_POLICY: "IOT_POLICY",
ISSUER_CERTIFICATE: "ISSUER_CERTIFICATE",
ROLE_ALIAS: "ROLE_ALIAS",
};
export const AuditFindingSeverity = {
CRITICAL: "CRITICAL",
HIGH: "HIGH",
LOW: "LOW",
MEDIUM: "MEDIUM",
};
export const AuditFrequency = {
BIWEEKLY: "BIWEEKLY",
DAILY: "DAILY",
MONTHLY: "MONTHLY",
WEEKLY: "WEEKLY",
};
export const AuditMitigationActionsExecutionStatus = {
CANCELED: "CANCELED",
COMPLETED: "COMPLETED",
FAILED: "FAILED",
IN_PROGRESS: "IN_PROGRESS",
PENDING: "PENDING",
SKIPPED: "SKIPPED",
};
export const AuditMitigationActionsTaskStatus = {
CANCELED: "CANCELED",
COMPLETED: "COMPLETED",
FAILED: "FAILED",
IN_PROGRESS: "IN_PROGRESS",
};
export const AuditNotificationType = {
SNS: "SNS",
};
export const AuditTaskStatus = {
CANCELED: "CANCELED",
COMPLETED: "COMPLETED",
FAILED: "FAILED",
IN_PROGRESS: "IN_PROGRESS",
};
export const AuditTaskType = {
ON_DEMAND_AUDIT_TASK: "ON_DEMAND_AUDIT_TASK",
SCHEDULED_AUDIT_TASK: "SCHEDULED_AUDIT_TASK",
};
export const AuthDecision = {
ALLOWED: "ALLOWED",
EXPLICIT_DENY: "EXPLICIT_DENY",
IMPLICIT_DENY: "IMPLICIT_DENY",
};
export const AuthorizerStatus = {
ACTIVE: "ACTIVE",
INACTIVE: "INACTIVE",
};
export const AutoRegistrationStatus = {
DISABLE: "DISABLE",
ENABLE: "ENABLE",
};
export class InvalidStateTransitionException extends __BaseException {
constructor(opts) {
super({
name: "InvalidStateTransitionException",
$fault: "client",
...opts,
});
this.name = "InvalidStateTransitionException";
this.$fault = "client";
Object.setPrototypeOf(this, InvalidStateTransitionException.prototype);
}
}
export class ConflictingResourceUpdateException extends __BaseException {
constructor(opts) {
super({
name: "ConflictingResourceUpdateException",
$fault: "client",
...opts,
});
this.name = "ConflictingResourceUpdateException";
this.$fault = "client";
Object.setPrototypeOf(this, ConflictingResourceUpdateException.prototype);
}
}
export class InternalException extends __BaseException {
constructor(opts) {
super({
name: "InternalException",
$fault: "server",
...opts,
});
this.name = "InternalException";
this.$fault = "server";
Object.setPrototypeOf(this, InternalException.prototype);
}
}
export class ResourceAlreadyExistsException extends __BaseException {
constructor(opts) {
super({
name: "ResourceAlreadyExistsException",
$fault: "client",
...opts,
});
this.name = "ResourceAlreadyExistsException";
this.$fault = "client";
Object.setPrototypeOf(this, ResourceAlreadyExistsException.prototype);
this.resourceId = opts.resourceId;
this.resourceArn = opts.resourceArn;
}
}
export const CertificateProviderOperation = {
CreateCertificateFromCsr: "CreateCertificateFromCsr",
};
export const CustomMetricType = {
IP_ADDRESS_LIST: "ip-address-list",
NUMBER: "number",
NUMBER_LIST: "number-list",
STRING_LIST: "string-list",
};
export const DimensionType = {
TOPIC_FILTER: "TOPIC_FILTER",
};
export class CertificateValidationException extends __BaseException {
constructor(opts) {
super({
name: "CertificateValidationException",
$fault: "client",
...opts,
});
this.name = "CertificateValidationException";
this.$fault = "client";
Object.setPrototypeOf(this, CertificateValidationException.prototype);
}
}
export const ServiceType = {
CREDENTIAL_PROVIDER: "CREDENTIAL_PROVIDER",
DATA: "DATA",
JOBS: "JOBS",
};
export class InvalidQueryException extends __BaseException {
constructor(opts) {
super({
name: "InvalidQueryException",
$fault: "client",
...opts,
});
this.name = "InvalidQueryException";
this.$fault = "client";
Object.setPrototypeOf(this, InvalidQueryException.prototype);
}
}
export const FleetMetricUnit = {
Bits: "Bits",
BitsSecond: "Bits/Second",
Bytes: "Bytes",
BytesSecond: "Bytes/Second",
Count: "Count",
CountSecond: "Count/Second",
Gigabits: "Gigabits",
GigabitsSecond: "Gigabits/Second",
Gigabytes: "Gigabytes",
GigabytesSecond: "Gigabytes/Second",
Kilobits: "Kilobits",
KilobitsSecond: "Kilobits/Second",
Kilobytes: "Kilobytes",
KilobytesSecond: "Kilobytes/Second",
Megabits: "Megabits",
MegabitsSecond: "Megabits/Second",
Megabytes: "Megabytes",
MegabytesSecond: "Megabytes/Second",
Microseconds: "Microseconds",
Milliseconds: "Milliseconds",
None: "None",
Percent: "Percent",
Seconds: "Seconds",
Terabits: "Terabits",
TerabitsSecond: "Terabits/Second",
Terabytes: "Terabytes",
TerabytesSecond: "Terabytes/Second",
};
export class IndexNotReadyException extends __BaseException {
constructor(opts) {
super({
name: "IndexNotReadyException",
$fault: "client",
...opts,
});
this.name = "IndexNotReadyException";
this.$fault = "client";
Object.setPrototypeOf(this, IndexNotReadyException.prototype);
}
}
export class InvalidAggregationException extends __BaseException {
constructor(opts) {
super({
name: "InvalidAggregationException",
$fault: "client",
...opts,
});
this.name = "InvalidAggregationException";
this.$fault = "client";
Object.setPrototypeOf(this, InvalidAggregationException.prototype);
}
}
export const RetryableFailureType = {
ALL: "ALL",
FAILED: "FAILED",
TIMED_OUT: "TIMED_OUT",
};
export const JobEndBehavior = {
CANCEL: "CANCEL",
FORCE_CANCEL: "FORCE_CANCEL",
STOP_ROLLOUT: "STOP_ROLLOUT",
};
export const TargetSelection = {
CONTINUOUS: "CONTINUOUS",
SNAPSHOT: "SNAPSHOT",
};
export class ConflictException extends __BaseException {
constructor(opts) {
super({
name: "ConflictException",
$fault: "client",
...opts,
});
this.name = "ConflictException";
this.$fault = "client";
Object.setPrototypeOf(this, ConflictException.prototype);
this.resourceId = opts.resourceId;
}
}
export const LogLevel = {
DEBUG: "DEBUG",
DISABLED: "DISABLED",
ERROR: "ERROR",
INFO: "INFO",
WARN: "WARN",
};
export const PolicyTemplateName = {
BLANK_POLICY: "BLANK_POLICY",
};
export const CACertificateUpdateAction = {
DEACTIVATE: "DEACTIVATE",
};
export const DeviceCertificateUpdateAction = {
DEACTIVATE: "DEACTIVATE",
};
export const AwsJobAbortCriteriaAbortAction = {
CANCEL: "CANCEL",
};
export const AwsJobAbortCriteriaFailureType = {
ALL: "ALL",
FAILED: "FAILED",
REJECTED: "REJECTED",
TIMED_OUT: "TIMED_OUT",
};
export const Protocol = {
HTTP: "HTTP",
MQTT: "MQTT",
};
export const OTAUpdateStatus = {
CREATE_COMPLETE: "CREATE_COMPLETE",
CREATE_FAILED: "CREATE_FAILED",
CREATE_IN_PROGRESS: "CREATE_IN_PROGRESS",
CREATE_PENDING: "CREATE_PENDING",
DELETE_FAILED: "DELETE_FAILED",
DELETE_IN_PROGRESS: "DELETE_IN_PROGRESS",
};
export class InternalServerException extends __BaseException {
constructor(opts) {
super({
name: "InternalServerException",
$fault: "server",
...opts,
});
this.name = "InternalServerException";
this.$fault = "server";
Object.setPrototypeOf(this, InternalServerException.prototype);
}
}
export class ServiceQuotaExceededException extends __BaseException {
constructor(opts) {
super({
name: "ServiceQuotaExceededException",
$fault: "client",
...opts,
});
this.name = "ServiceQuotaExceededException";
this.$fault = "client";
Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype);
}
}
export class ValidationException extends __BaseException {
constructor(opts) {
super({
name: "ValidationException",
$fault: "client",
...opts,
});
this.name = "ValidationException";
this.$fault = "client";
Object.setPrototypeOf(this, ValidationException.prototype);
}
}
export const PackageVersionStatus = {
DEPRECATED: "DEPRECATED",
DRAFT: "DRAFT",
PUBLISHED: "PUBLISHED",
};
export class MalformedPolicyException extends __BaseException {
constructor(opts) {
super({
name: "MalformedPolicyException",
$fault: "client",
...opts,
});
this.name = "MalformedPolicyException";
this.$fault = "client";
Object.setPrototypeOf(this, MalformedPolicyException.prototype);
}
}
export class VersionsLimitExceededException extends __BaseException {
constructor(opts) {
super({
name: "VersionsLimitExceededException",
$fault: "client",
...opts,
});
this.name = "VersionsLimitExceededException";
this.$fault = "client";
Object.setPrototypeOf(this, VersionsLimitExceededException.prototype);
}
}
export const TemplateType = {
FLEET_PROVISIONING: "FLEET_PROVISIONING",
JITP: "JITP",
};
export const DayOfWeek = {
FRI: "FRI",
MON: "MON",
SAT: "SAT",
SUN: "SUN",
THU: "THU",
TUE: "TUE",
WED: "WED",
};
export class SqlParseException extends __BaseException {
constructor(opts) {
super({
name: "SqlParseException",
$fault: "client",
...opts,
});
this.name = "SqlParseException";
this.$fault = "client";
Object.setPrototypeOf(this, SqlParseException.prototype);
}
}
export const TopicRuleDestinationStatus = {
DELETING: "DELETING",
DISABLED: "DISABLED",
ENABLED: "ENABLED",
ERROR: "ERROR",
IN_PROGRESS: "IN_PROGRESS",
};
export class DeleteConflictException extends __BaseException {
constructor(opts) {
super({
name: "DeleteConflictException",
$fault: "client",
...opts,
});
this.name = "DeleteConflictException";
this.$fault = "client";
Object.setPrototypeOf(this, DeleteConflictException.prototype);
}
}
export class CertificateStateException extends __BaseException {
constructor(opts) {
super({
name: "CertificateStateException",
$fault: "client",
...opts,
});
this.name = "CertificateStateException";
this.$fault = "client";
Object.setPrototypeOf(this, CertificateStateException.prototype);
}
}
export const KeyPairFilterSensitiveLog = (obj) => ({
...obj,
...(obj.PrivateKey && { PrivateKey: SENSITIVE_STRING }),
});
export const CreateKeysAndCertificateResponseFilterSensitiveLog = (obj) => ({
...obj,
...(obj.keyPair && { keyPair: KeyPairFilterSensitiveLog(obj.keyPair) }),
});
export const CreatePackageRequestFilterSensitiveLog = (obj) => ({
...obj,
...(obj.description && { description: SENSITIVE_STRING }),
});
export const CreatePackageResponseFilterSensitiveLog = (obj) => ({
...obj,
...(obj.description && { description: SENSITIVE_STRING }),
});
export const CreatePackageVersionRequestFilterSensitiveLog = (obj) => ({
...obj,
...(obj.description && { description: SENSITIVE_STRING }),
...(obj.attributes && { attributes: SENSITIVE_STRING }),
});
export const CreatePackageVersionResponseFilterSensitiveLog = (obj) => ({
...obj,
...(obj.description && { description: SENSITIVE_STRING }),
...(obj.attributes && { attributes: SENSITIVE_STRING }),
});
export const CreateProvisioningClaimResponseFilterSensitiveLog = (obj) => ({
...obj,
...(obj.keyPair && { keyPair: KeyPairFilterSensitiveLog(obj.keyPair) }),
});