id
stringlengths
8
78
source
stringclasses
743 values
chunk_id
int64
1
5.05k
text
stringlengths
593
49.7k
amazon-lookout-for-equipment-ug-045
amazon-lookout-for-equipment-ug.pdf
45
about AWS KMS keys across AWS accounts. Lookout for Equipment started tracking changes for its AWS managed policies. April 08, 2021 Lookout for Equipment started tracking changes Troubleshooting Amazon Lookout for Equipment identity and access Use the following information to help you diagnose and fix common issues that you might encounter when working with Amazon Lookout for Equipment and IAM. Topics • I am not authorized to perform an action in Lookout for Equipment • I am not authorized to perform iam:PassRole • I want to allow people outside of my AWS account to access my Lookout for Equipment resources I am not authorized to perform an action in Lookout for Equipment If you receive an error that you're not authorized to perform an action, your policies must be updated to allow you to perform the action. Troubleshooting 126 Amazon Lookout for Equipment User Guide The following example error occurs when the mateojackson IAM user tries to use the console to view details about a fictional my-example-widget resource but doesn't have the fictional lookoutequipment:GetWidget permissions. User: arn:aws:iam::123456789012:user/mateojackson is not authorized to perform: lookoutequipment:GetWidget on resource: my-example-widget In this case, the policy for the mateojackson user must be updated to allow access to the my- example-widget resource by using the lookoutequipment:GetWidget action. If you need help, contact your AWS administrator. Your administrator is the person who provided you with your sign-in credentials. I am not authorized to perform iam:PassRole If you receive an error that you're not authorized to perform the iam:PassRole action, your policies must be updated to allow you to pass a role to Amazon Lookout for Equipment. Some AWS services allow you to pass an existing role to that service instead of creating a new service role or service-linked role. To do this, you must have permissions to pass the role to the service. The following example error occurs when an IAM user named marymajor tries to use the console to perform an action in Amazon Lookout for Equipment. However, the action requires the service to have permissions that are granted by a service role. Mary does not have permissions to pass the role to the service. User: arn:aws:iam::123456789012:user/marymajor is not authorized to perform: iam:PassRole In this case, Mary's policies must be updated to allow her to perform the iam:PassRole action. If you need help, contact your AWS administrator. Your administrator is the person who provided you with your sign-in credentials. I want to allow people outside of my AWS account to access my Lookout for Equipment resources You can create a role that users in other accounts or people outside of your organization can use to access your resources. You can specify who is trusted to assume the role. For services that support Troubleshooting 127 Amazon Lookout for Equipment User Guide resource-based policies or access control lists (ACLs), you can use those policies to grant people access to your resources. To learn more, consult the following: • To learn whether Amazon Lookout for Equipment supports these features, see AWS Identity and Access Management for Amazon Lookout for Equipment. • To learn how to provide access to your resources across AWS accounts that you own, see Providing access to an IAM user in another AWS account that you own in the IAM User Guide. • To learn how to provide access to your resources to third-party AWS accounts, see Providing access to AWS accounts owned by third parties in the IAM User Guide. • To learn how to provide access through identity federation, see Providing access to externally authenticated users (identity federation) in the IAM User Guide. • To learn the difference between using roles and resource-based policies for cross-account access, see Cross account resource access in IAM in the IAM User Guide. Amazon Lookout for Equipment and interface VPC endpoints (AWS PrivateLink) You can establish a private connection between your VPC and Amazon Lookout for Equipment by creating an interface VPC endpoint. Interface endpoints are powered by AWS PrivateLink, a technology that you can use to privately access Lookout for Equipment APIs without an internet gateway, network address translation (NAT) device, VPN connection, or AWS Direct Connect connection. Instances in your VPC don't need public IP addresses to communicate with Lookout for Equipment APIs. Traffic between your VPC and Lookout for Equipment does not leave the Amazon network. Each interface endpoint is represented by one or more Elastic Network Interfaces in your subnets. For more information, see Interface VPC endpoints (AWS PrivateLink) in the Amazon VPC User Guide. Considerations for Lookout for Equipment VPC endpoints Before you set up an interface VPC endpoint for Lookout for Equipment, ensure that you review Interface endpoint properties and limitations in the Amazon VPC User Guide. VPC endpoints (AWS PrivateLink) 128 Amazon Lookout for Equipment User Guide Lookout for Equipment supports
amazon-lookout-for-equipment-ug-046
amazon-lookout-for-equipment-ug.pdf
46
to communicate with Lookout for Equipment APIs. Traffic between your VPC and Lookout for Equipment does not leave the Amazon network. Each interface endpoint is represented by one or more Elastic Network Interfaces in your subnets. For more information, see Interface VPC endpoints (AWS PrivateLink) in the Amazon VPC User Guide. Considerations for Lookout for Equipment VPC endpoints Before you set up an interface VPC endpoint for Lookout for Equipment, ensure that you review Interface endpoint properties and limitations in the Amazon VPC User Guide. VPC endpoints (AWS PrivateLink) 128 Amazon Lookout for Equipment User Guide Lookout for Equipment supports making calls to all of its API actions from your VPC. Creating an interface VPC endpoint for Lookout for Equipment You can create a VPC endpoint for the Lookout for Equipment service using either the Amazon VPC console or the AWS Command Line Interface (AWS CLI). For more information, see Creating an interface endpoint in the Amazon VPC User Guide. Create a VPC endpoint for Lookout for Equipment using the following service name: • com.amazonaws.region.lookoutequipment If you enable private DNS for the endpoint, you can make API requests to Lookout for Equipment using its default DNS name for the Region, for example, lookoutequipment.us- east-1.amazonaws.com. For more information, see Accessing a service through an interface endpoint in the Amazon VPC User Guide. Creating a VPC endpoint policy for Lookout for Equipment You can attach an endpoint policy to your VPC endpoint that controls access to Lookout for Equipment. The policy specifies the following information: • The principal that can perform actions. • The actions that can be performed. • The resources on which actions can be performed. For more information, see Controlling access to services with VPC endpoints in the Amazon VPC User Guide. Example: VPC endpoint policy for Lookout for Equipment actions The following is an example of an endpoint policy for Lookout for Equipment. When attached to an endpoint, this policy grants access to the listed Lookout for Equipment actions for all principals on all resources. { "Statement":[ Creating an interface VPC endpoint for Lookout for Equipment 129 User Guide Amazon Lookout for Equipment { "Principal":"*", "Effect":"Allow", "Action":[ "lookoutequipment:ListDatasets", "lookoutequipment:CreateDataset", "lookoutequipment:DescribeDataset", "lookoutequipment:DeleteDataset", "lookoutequipment:StartDataIngestionJob", "lookoutequipment:DescribeDataIngestionJob", "lookoutequipment:ListDataIngestionJobs", "lookoutequipment:CreateModel", "lookoutequipment:DescribeModel", "lookoutequipment:ListModels", "lookoutequipment:DeleteModel", "lookoutequipment:CreateInferenceScheduler", "lookoutequipment:StartInferenceScheduler", "lookoutequipment:StopInferenceScheduler", "lookoutequipment:UpdateInferenceScheduler", "lookoutequipment:DescribeInferenceScheduler", "lookoutequipment:ListInferenceSchedulers", "lookoutequipment:DeleteInferenceScheduler", "lookoutequipment:ListInferenceExecutions" ], "Resource":"*" } ] } Compliance validation for Amazon Lookout for Equipment Third-party auditors assess the security and compliance of Amazon Lookout for Equipment as part of multiple AWS compliance programs. Amazon Lookout for Equipment is a data compliant service. For a list of AWS services in scope of specific compliance programs, see AWS Services in Scope by Compliance Program. For general information, see AWS Compliance Programs. You can download third-party audit reports using AWS Artifact. For more information, see Downloading Reports in AWS Artifact. Your compliance responsibility when using Amazon Lookout for Equipment is determined by the sensitivity of your data, your company's compliance objectives, and applicable laws and regulations. AWS provides the following resources to help with compliance: Compliance validation 130 Amazon Lookout for Equipment User Guide • Security and Compliance Quick Start Guides – These deployment guides discuss architectural considerations and provide steps for deploying security- and compliance-focused baseline environments on AWS. • Architecting for HIPAA Security and Compliance Whitepaper – This whitepaper describes how companies can use AWS to create HIPAA-compliant applications. • AWS Compliance Resources – This collection of workbooks and guides might apply to your industry and location. • Evaluating Resources with Rules in the AWS Config Developer Guide– The AWS Config service assesses how well your resource configurations comply with internal practices, industry guidelines, and regulations. • Security Hub – This AWS service provides a comprehensive view of your security state within AWS that helps you check your compliance with security industry standards and best practices. Resilience in Amazon Lookout for Equipment The AWS global infrastructure is built around AWS Regions and Availability Zones. AWS Regions provide multiple physically separated and isolated Availability Zones, which are connected with low-latency, high-throughput, and highly redundant networking. With Availability Zones, you can design and operate applications and databases that automatically fail over between zones without interruption. Availability Zones are more highly available, fault tolerant, and scalable than traditional single or multiple data center infrastructures. For more information about AWS Regions and Availability Zones, see AWS Global Infrastructure. Infrastructure security in Amazon Lookout for Equipment As a managed service, Amazon Lookout for Equipment is protected by the AWS global network security procedures that are described in the Amazon Web Services: Overview of Security Processes whitepaper. You use published AWS API calls to access Amazon Lookout for Equipment through the network. Clients must support Transport Layer Security (TLS) 1.2 or later. Clients must also support cipher suites with perfect forward secrecy (PFS) such as Ephemeral Diffie-Hellman (DHE) or Elliptic Curve
amazon-lookout-for-equipment-ug-047
amazon-lookout-for-equipment-ug.pdf
47
single or multiple data center infrastructures. For more information about AWS Regions and Availability Zones, see AWS Global Infrastructure. Infrastructure security in Amazon Lookout for Equipment As a managed service, Amazon Lookout for Equipment is protected by the AWS global network security procedures that are described in the Amazon Web Services: Overview of Security Processes whitepaper. You use published AWS API calls to access Amazon Lookout for Equipment through the network. Clients must support Transport Layer Security (TLS) 1.2 or later. Clients must also support cipher suites with perfect forward secrecy (PFS) such as Ephemeral Diffie-Hellman (DHE) or Elliptic Curve Ephemeral Diffie-Hellman (ECDHE). Most modern systems such as Java 7 and later support these modes. Resilience 131 Amazon Lookout for Equipment User Guide Requests must be signed by using an access key ID and a secret access key that is associated with an IAM principal. If you don't have an access key and a secret access key, you can use the AWS Security Token Service to generate temporary security credentials to sign requests. Infrastructure security in Amazon Lookout for Equipment 132 Amazon Lookout for Equipment User Guide Monitoring Amazon Lookout for Equipment Monitoring is an important part of maintaining the reliability, availability, and performance of Lookout for Equipment and your other AWS solutions. AWS provides the following monitoring tools to watch Lookout for Equipment, report when something is wrong, and take automatic actions when appropriate: • Amazon CloudWatch monitors your AWS resources and the applications you run on AWS in real time. You can collect and track metrics, create customized dashboards, and set alarms that notify you or take actions when a specified metric reaches a threshold that you specify. For example, you can have CloudWatch track CPU usage or other metrics of your Amazon EC2 instances and automatically launch new instances when needed. For more information, see the Amazon CloudWatch User Guide. • Amazon CloudWatch Logs enables you to monitor, store, and access your log files from Amazon EC2 instances, CloudTrail, and other sources. CloudWatch Logs can monitor information in the log files and notify you when certain thresholds are met. You can also archive your log data in highly durable storage. For more information, see the Amazon CloudWatch Logs User Guide. • AWS CloudTrail captures API calls and related events made by or on behalf of your AWS account and delivers the log files to an Amazon S3 bucket that you specify. You can identify which users and accounts called AWS, the source IP address from which the calls were made, and when the calls occurred. For more information, see the AWS CloudTrail User Guide. Amazon EventBridge is a serverless event bus service that makes it easy to connect your applications with data from a variety of sources. EventBridge delivers a stream of real-time data from your own applications, Software-as-a-Service (SaaS) applications, and AWS services and routes that data to targets such as Lambda. This enables you to monitor events that happen in services, and build event-driven architectures. For more information, see the Amazon EventBridge User Guide. Monitoring Lookout for Equipment with Amazon CloudWatch You can monitor Lookout for Equipment using CloudWatch, which collects raw data and processes it into readable, near real-time metrics. These statistics are kept for 15 months, so that you can access historical information and gain a better perspective on how your web application or service is performing. You can also set alarms that watch for certain thresholds, and send notifications or Monitoring with CloudWatch 133 Amazon Lookout for Equipment User Guide take actions when those thresholds are met. For more information, see the Amazon CloudWatch User Guide. The Lookout for Equipment service reports the following metrics in the AWS/lookoutequipment namespace. Metric Description Inference Succeeded If the value is 1, the inference succeeded. If the value is 0, the inference failed. ModelName: The name of the model. InferenceSchedulerName: Name of the inference scheduler InferenceFailed If the value is 1, the inference failed. If the value is 0, the inference succeeded. ModelName: The name of the model. InferenceSchedulerName: Name of the inference scheduler Inference InvalidInput If the value is 1, you've provided an invalid value for the inference. ModelName: The name of the model. InferenceSchedulerName: Name of the inference scheduler The following dimensions are supported for the Lookout for Equipment metrics. ModelName The name of the ML model that you've trained to monitor your equipment. InferenceScheduler Name The inference scheduler schedules the times when your model monitors your equipment. Monitoring with CloudWatch 134 Amazon Lookout for Equipment User Guide Creating Amazon Lookout for Equipment resources with AWS CloudFormation Amazon Lookout for Equipment is integrated with AWS CloudFormation, a service that helps you to model and set up your AWS resources so that you can spend less time creating and managing your Lookout for Equipment resources
amazon-lookout-for-equipment-ug-048
amazon-lookout-for-equipment-ug.pdf
48
Name of the inference scheduler The following dimensions are supported for the Lookout for Equipment metrics. ModelName The name of the ML model that you've trained to monitor your equipment. InferenceScheduler Name The inference scheduler schedules the times when your model monitors your equipment. Monitoring with CloudWatch 134 Amazon Lookout for Equipment User Guide Creating Amazon Lookout for Equipment resources with AWS CloudFormation Amazon Lookout for Equipment is integrated with AWS CloudFormation, a service that helps you to model and set up your AWS resources so that you can spend less time creating and managing your Lookout for Equipment resources and infrastructure. You create a template that describes all the AWS resources that you want (such as Amazon S3 buckets), and AWS CloudFormation provisions and configures those resources for you. When you use AWS CloudFormation, you can reuse your template to set up your Lookout for Equipment resources consistently and repeatedly. Describe your resources once, and then provision the same resources over and over in multiple AWS accounts and Regions. Lookout for Equipment and AWS CloudFormation templates To provision and configure resources for Lookout for Equipment and related services, you must understand AWS CloudFormation templates. Templates are formatted text files in JSON or YAML. These templates describe the resources that you want to provision in your AWS CloudFormation stacks. If you're unfamiliar with JSON or YAML, you can use AWS CloudFormation Designer to help you get started with AWS CloudFormation templates. For more information, see What is AWS CloudFormation Designer? in the AWS CloudFormation User Guide. Lookout for Equipment supports creating Amazon S3 buckets in AWS CloudFormation. For more information, including examples of JSON and YAML templates for Amazon S3 buckets, see the Lookout For Equipment resource type reference in the AWS CloudFormation User Guide. Learn more about AWS CloudFormation To learn more about AWS CloudFormation, see the following resources: • AWS CloudFormation • AWS CloudFormation User Guide • AWS CloudFormation API Reference • AWS CloudFormation Command Line Interface User Guide Lookout for Equipment and AWS CloudFormation templates 135 Amazon Lookout for Equipment User Guide Python SDK examples Creating a schema from multiple .csv files Note If you use the console to ingest your data, Lookout for Equipment can detect your schema for you, according to the way you organize your files. If you've uploaded multiple .csv files, with each sensor having its own .csv file, you would use the following schema to create a dataset from those files. In the following schema, Components refers to a collection of identifiers for the .csv files of your sensors. The ComponentName is the portion of a prefix of an Amazon S3 object key that identifies a .csv file. For example, "ComponentName": "Sensor2" could acccess s3://amzn-s3-demo- bucket/AssetName/Sensor2/Sensor2.csv. You define a Columns object for each ComponentName that you define in the schema. The Name fields in the Columns object must match the columns in your .csv files. Within each Columns object, the Name fields that reference the columns containing the timestamp data must have the Type field specified as DATETIME. The Name fields that reference your sensor data must have a Type of DOUBLE. You can use the following example code with the AWS SDK for Python (Boto3) to create a dataset. import boto3 import json import pprint from botocore.config import Config config = Config( region_name = Region, #Choose a valid AWS Region signature_version = 'v4' ) Creating a schema from multiple .csv files 136 Amazon Lookout for Equipment User Guide lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) dataset_schema = { "Components": [ { "ComponentName": "Sensor1", "Columns": [ { "Name": "Timestamp", "Type": "DATETIME" }, { "Name": "Sensor1", "Type": "DOUBLE" } ] }, { "ComponentName": "Sensor2", "Columns": [ { "Name": "Timestamp", "Type": "DATETIME" }, { "Name": "Sensor2", "Type": "DOUBLE" } ] }, { "ComponentName": "Sensor3", "Columns": [ { "Name": "Timestamp", "Type": "DATETIME" }, { "Name": "Sensor3", "Type": "DOUBLE" } ] }, Creating a schema from multiple .csv files 137 User Guide Amazon Lookout for Equipment { "ComponentName": "Sensor4", "Columns": [ { "Name": "Timestamp", "Type": "DATETIME" }, { "Name": "Sensor4", "Type": "DOUBLE" } ] } ] } Creating a schema from a single .csv file Note If you use the console to ingest your data, Lookout for Equipment can detect your schema for you, according to the way you organize your files. If you've uploaded one .csv file containing all of the sensor data for the asset, you would use the schema in the code below to create a dataset from that file. The ComponentName is the portion of the prefix of the Amazon S3 object key that identifies the .csv file containing the sensor data for your asset. When you specify the value of ComponentName as AssetName, you access s3://amzn-s3-demo- bucket/FacilityName/AssetName/AssetName.csv. You enter the columns of your dataset in the Columns object. The name of each column in
amazon-lookout-for-equipment-ug-049
amazon-lookout-for-equipment-ug.pdf
49
detect your schema for you, according to the way you organize your files. If you've uploaded one .csv file containing all of the sensor data for the asset, you would use the schema in the code below to create a dataset from that file. The ComponentName is the portion of the prefix of the Amazon S3 object key that identifies the .csv file containing the sensor data for your asset. When you specify the value of ComponentName as AssetName, you access s3://amzn-s3-demo- bucket/FacilityName/AssetName/AssetName.csv. You enter the columns of your dataset in the Columns object. The name of each column in your .csv file must match the Name in the schema. For the column containing the time stamp data, you must specify the value of Type as DATETIME in the schema. For the columns containing data from sensors, you must specify the value of Type as DOUBLE. You can use the following example code with the AWS SDK for Python (Boto3) to create a dataset. Creating a schema from a single .csv file 138 Amazon Lookout for Equipment User Guide import boto3 import json import pprint from botocore.config import Config config = Config( region_name = 'Region', # Choose a valid AWS Region signature_version = 'v4' ) lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) dataset_schema = { "Components": [ { "ComponentName": "AssetName", "Columns": [ { "Name": "Timestamp", "Type": "DATETIME" }, { "Name": "Sensor1", "Type": "DOUBLE" }, { "Name": "Sensor2", "Type": "DOUBLE" }, { "Name": "Sensor3", "Type": "DOUBLE" }, { "Name": "Sensor4", "Type": "DOUBLE" }, ] } ] } Creating a schema from a single .csv file 139 Amazon Lookout for Equipment User Guide dataset_name = "dataset-name" data_schema = { 'InlineDataSchema': json.dumps(dataset_schema), } create_dataset_response = lookoutequipment.create_dataset(DatasetName=dataset_name, DatasetSchema=data_schema) pp = pprint.PrettyPrinter(depth=4) pp.pprint(create_dataset_response) Adding a dataset to your project Note You can also add a dataset to your project using the console. Use the following AWS SDK for Python (Boto3) example code to tell Lookout for Equipment to ingest your dataset. import boto3 import time from botocore.config import Config config = Config( region_name = 'Region' #Choose a valid AWS Region signature_version = 'v4' ) lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) INGESTION_DATA_SOURCE_BUCKET = 'amzn-s3-demo-bucket' # If you're ingesting multiple .csv files of your sensor data, use the following Amazon S3 path: s3://amzn-s3-demo-bucket/AssetName/. If you're ingesting a single .csv Adding a dataset to your project 140 Amazon Lookout for Equipment User Guide file of your asset data, use the following Amazon S3 path: s3://amzn-s3-demo-bucket/ FacilityName/. INGESTION_DATA_SOURCE_PREFIX = 'my_data/sensor_readings/' # The ROLE_ARN and DATASET_NAME values that are used in this script have been defined in the previous SDK for Python example code for creating a dataset. data_ingestion_role_arn = ROLE_ARN dataset_name = DATASET_NAME ingestion_input_config = dict() ingestion_input_config['S3InputConfiguration'] = dict( [ ('Bucket', INGESTION_DATA_SOURCE_BUCKET), ('Prefix', INGESTION_DATA_SOURCE_PREFIX) ] ) # Start data ingestion start_data_ingestion_job_response = lookoutequipment.start_data_ingestion_job( DatasetName=dataset_name, RoleArn=data_ingestion_role_arn, IngestionInputConfiguration=ingestion_input_config) data_ingestion_job_id = start_data_ingestion_job_response['JobId'] data_ingestion_status = start_data_ingestion_job_response['Status'] print(f'=====Data Ingestion job is started. Job ID: {data_ingestion_job_id}=====\n') # Wait until completes print("=====Polling Data Ingestion Status=====\n") print("Data Ingestion Status: " + data_ingestion_status) while data_ingestion_status == 'IN_PROGRESS': time.sleep(30) describe_data_ingestion_job_response = lookoutequipment.describe_data_ingestion_job(JobId=data_ingestion_job_id) data_ingestion_status = describe_data_ingestion_job_response['Status'] print("Data Ingestion Status: " + data_ingestion_status) print("\n=====End of Polling Data Ingestion Status=====") Adding a dataset to your project 141 Amazon Lookout for Equipment Viewing a model User Guide Note You can also view and evaluate a model in the console. Use the following example AWS SDK for Python (Boto3) code to list the models that you've trained, to query a model's metadata, and to delete a model that you no longer want to use. If you've used label data when you created a dataset, you can also use this code to see how well the model performed. To run this code successfully, you must use the SDK for Python code in Training your model before you run the code shown here. import boto3 import json import pprint import time from datetime import datetime from botocore.config import Config config = Config(region_name = 'Region') lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) # List models MODEL_NAME_PREFIX = None DATASET_NAME_FOR_LIST_MODELS = None list_models_request = {} if MODEL_NAME_PREFIX is not None: list_models_request["ModelNameBeginsWith"] = MODEL_NAME_PREFIX if DATASET_NAME_FOR_LIST_MODELS is not None: list_models_request["DatasetNameBeginsWith"] = DATASET_NAME_PREFIX pp = pprint.PrettyPrinter(depth=5) print("=====Model Summaries=====\n") has_more_records = True Viewing a model 142 Amazon Lookout for Equipment while has_more_records: User Guide list_models_response = lookoutequipment.list_models(**list_models_request) if "NextToken" in list_models_response: list_models_request["NextToken"] = list_models_response["NextToken"] else: has_more_records = False model_summaries = list_models_response["ModelSummaries"] for model_summary in model_summaries: pp.pprint(model_summary) print("\n=====End of Model Summaries=====") # Query the metadata for a model MODEL_NAME_TO_QUERY = MODEL_NAME describe_model_response = lookoutequipment.describe_model(ModelName=MODEL_NAME_TO_QUERY) print(f'Model Status: {describe_model_response["Status"]}') if "FailedReason" in describe_model_response: print(f'Model FailedReason: {describe_model_response["FailedReason"]}') print("\n\n=====DescribeModel Response=====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(describe_model_response) print("\n=====End of DescribeModel Response=====") # Get evaluation metrics for a model MODEL_NAME_TO_DOWNLOAD_EVALUATION_METRICS = MODEL_NAME describe_model_response = lookoutequipment.describe_model(ModelName=MODEL_NAME_TO_DOWNLOAD_EVALUATION_METRICS) if 'ModelMetrics' in describe_model_response: model_metrics = json.loads(describe_model_response['ModelMetrics']) print("===== Model Metrics =====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(model_metrics) print("\n=====End of Model Metrics=====\n") else: print('Model metrics is only available if evaluation data is provided during training.') #
amazon-lookout-for-equipment-ug-050
amazon-lookout-for-equipment-ug.pdf
50
in list_models_response: list_models_request["NextToken"] = list_models_response["NextToken"] else: has_more_records = False model_summaries = list_models_response["ModelSummaries"] for model_summary in model_summaries: pp.pprint(model_summary) print("\n=====End of Model Summaries=====") # Query the metadata for a model MODEL_NAME_TO_QUERY = MODEL_NAME describe_model_response = lookoutequipment.describe_model(ModelName=MODEL_NAME_TO_QUERY) print(f'Model Status: {describe_model_response["Status"]}') if "FailedReason" in describe_model_response: print(f'Model FailedReason: {describe_model_response["FailedReason"]}') print("\n\n=====DescribeModel Response=====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(describe_model_response) print("\n=====End of DescribeModel Response=====") # Get evaluation metrics for a model MODEL_NAME_TO_DOWNLOAD_EVALUATION_METRICS = MODEL_NAME describe_model_response = lookoutequipment.describe_model(ModelName=MODEL_NAME_TO_DOWNLOAD_EVALUATION_METRICS) if 'ModelMetrics' in describe_model_response: model_metrics = json.loads(describe_model_response['ModelMetrics']) print("===== Model Metrics =====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(model_metrics) print("\n=====End of Model Metrics=====\n") else: print('Model metrics is only available if evaluation data is provided during training.') # Delete a model MODEL_NAME_TO_DELETE = MODEL_NAME Viewing a model 143 Amazon Lookout for Equipment User Guide model_name_to_delete = MODEL_NAME_TO_DELETE delete_model_response = lookoutequipment.delete_model( ModelName=model_name_to_delete ) print("=====DeleteModel Response=====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(delete_model_response) print("\n=====End of DeleteModel Response=====\n") Managing your datasets Note You can also manage your datasets in the console. Use the following AWS SDK for Python (Boto3) example code to manage your datasets. It will show you how to list all your datasets, get information about a dataset, and delete a dataset. You must have the modules installed from code examples that showed you how to create a dataset to successfully use the following code. To run the following code, you must first run the example code in either Creating a schema from a single .csv file or Creating a schema from multiple .csv files . import boto3 import json import pprint from botocore.config import Config config = Config( region_name = 'Region' # Choose a valid AWS Region ) lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) Managing your datasets 144 Amazon Lookout for Equipment User Guide # Specify a value for the prefixes that your dataset uses to list the DATASET_NAME_PREFIX = "dataset-name" kargs = {"MaxResults": 50} if DATASET_NAME_PREFIX is not None: kargs["DatasetNameBeginsWith"] = DATASET_NAME_PREFIX has_more_records = True pp = pprint.PrettyPrinter(depth=4) print("=====Dataset Summaries=====\n") while has_more_records: list_datasets_response = lookoutequipment.list_datasets(**kargs) if "NextToken" in list_datasets_response: kargs["NextToken"] = list_datasets_response["NextToken"] else: has_more_records = False # print datasets dataset_summaries = list_datasets_response["DatasetSummaries"] for dataset_summary in dataset_summaries: pp.pprint(dataset_summary) print("\n=====End of Dataset Summaries=====") # The following code queries a dataset dataset_name_to_query = "example-dataset-1" # Change this to dataset name that you want to query describe_dataset_response = lookoutequipment.describe_dataset( DatasetName=dataset_name_to_query ) print("=====Dataset Query Response=====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(describe_dataset_response) print("\n=====End of Response=====\n") print("=====Schema of Dataset =====\n") pp.pprint(json.loads(describe_dataset_response["Schema"])) print("\n=====End of Schema of Dataset=====\n") # The following code deletes a dataset dataset_name_to_delete = "example-dataset-1" # Change this to dataset name that you want to delete delete_dataset_response = lookoutequipment.delete_dataset( DatasetName=dataset_name_to_delete Managing your datasets 145 Amazon Lookout for Equipment ) print("=====Dataset Delete Response=====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(delete_dataset_response) print("\n=====End of Response=====\n") User Guide Labeling your data The following example code uses the AWS SDK for Python (Boto3) to provide labels for your model. import boto3 import json import pprint import time from datetime import datetime from botocore.config import Config config = Config(region_name = 'Region') lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) LABEL_GROUP_NAME = "[Replace it with your label group name]" create_label_group_request = { "LabelGroupName": LABEL_GROUP_NAME, "FaultCodes": ["[Your Fault Code1]", "[Your Fault Code2]"] } # CREATE A LABEL GROUP create_label_group_response = lookoutequipment_client.create_label_group(**create_label_group_request) pp = pprint.PrettyPrinter(depth=4) print("=====Create Label Group Response=====\n") pp.pprint(create_label_group_response) print("\n=====End of Response=====") Labeling your data 146 Amazon Lookout for Equipment # CREATE A LABEL User Guide # You can create more labels as anomalies are identified before and after creating a model. create_label_request = { "LabelGroupName": LABEL_GROUP_NAME, "Rating": "ANOMALY", # ANOMALY, NORMAL or NEUTRAL "StartTime": datetime(2022, 1, 1, 0, 0, 0), "EndTime": datetime(2022, 1, 1, 1, 0, 0), "FaultCode": "[Your Fault Code1]", # Must be defined in label group fault codes. Optional. "Equipment": "[replace with your equipment identifier]", # Optional "Notes": "[replace with your notes]", # Optional } create_label_response = lookoutequipment_client.create_label(**create_label_request) print("=====Create Label Response=====\n") pp.pprint(create_label_response) print("\n=====End of Response=====") Managing your labels You can use code like the following example code to manage your labels. import boto3 import json import pprint import time from datetime import datetime from botocore.config import Config config = Config(region_name = 'Region') lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) LABEL_GROUP_NAME = "[Replace it with your label group name]" # LIST LABEL GROUPS list_label_groups_request = {} Managing your labels 147 Amazon Lookout for Equipment list_label_groups_response = lookoutequipment_client.list_label_groups(**list_label_groups_request) pp = pprint.PrettyPrinter(depth=4) print("=====List Label Groups Response=====\n") pp.pprint(list_label_groups_response) print("\n=====End of Response=====") User Guide # DESCRIBE A LABEL GROUP describe_label_group_request = {"LabelGroupName": LABEL_GROUP_NAME} describe_label_group_response = lookoutequipment_client.describe_label_group(**describe_label_group_request) print("=====Describe Label Group Response=====\n") pp.pprint(describe_label_group_response) print("\n=====End of Response=====") # UPDATE A LABEL GROUP update_label_group_request = {"LabelGroupName": LABEL_GROUP_NAME, "FaultCodes": ["[Your Fault Code1]", "[Your Fault Code3]"]} update_label_group_response = lookoutequipment_client.update_label_group(**update_label_group_request) print("=====Update Label Group Response=====\n") pp.pprint(update_label_group_response) print("\n=====End of Response=====") # LIST LABELS list_labels = { "LabelGroupName": LABEL_GROUP_NAME, } list_labels_response = lookoutequipment_client.list_labels(**list_labels) print("=====Create Label Response=====\n") pp.pprint(list_labels_response) print("\n=====End of Response=====") # DESCRIBE A LABEL describe_label_request = { "LabelGroupName": LABEL_GROUP_NAME, "LabelId": "[Replace with Label Id]", } Managing your labels 148 Amazon Lookout for Equipment describe_label_response = lookoutequipment_client.describe_label(**describe_label_request) print("=====Describe Label Response=====\n") pp.pprint(describe_label_response) print("\n=====End of Response=====") User Guide # DELETE A LABEL delete_label_request
amazon-lookout-for-equipment-ug-051
amazon-lookout-for-equipment-ug.pdf
51
= {"LabelGroupName": LABEL_GROUP_NAME} describe_label_group_response = lookoutequipment_client.describe_label_group(**describe_label_group_request) print("=====Describe Label Group Response=====\n") pp.pprint(describe_label_group_response) print("\n=====End of Response=====") # UPDATE A LABEL GROUP update_label_group_request = {"LabelGroupName": LABEL_GROUP_NAME, "FaultCodes": ["[Your Fault Code1]", "[Your Fault Code3]"]} update_label_group_response = lookoutequipment_client.update_label_group(**update_label_group_request) print("=====Update Label Group Response=====\n") pp.pprint(update_label_group_response) print("\n=====End of Response=====") # LIST LABELS list_labels = { "LabelGroupName": LABEL_GROUP_NAME, } list_labels_response = lookoutequipment_client.list_labels(**list_labels) print("=====Create Label Response=====\n") pp.pprint(list_labels_response) print("\n=====End of Response=====") # DESCRIBE A LABEL describe_label_request = { "LabelGroupName": LABEL_GROUP_NAME, "LabelId": "[Replace with Label Id]", } Managing your labels 148 Amazon Lookout for Equipment describe_label_response = lookoutequipment_client.describe_label(**describe_label_request) print("=====Describe Label Response=====\n") pp.pprint(describe_label_response) print("\n=====End of Response=====") User Guide # DELETE A LABEL delete_label_request = { "LabelGroupName": LABEL_GROUP_NAME, "LabelId": "[Replace with Label Id]", } delete_label_response = lookoutequipment_client.delete_label(**delete_label_request) print("=====Delete Label Response=====\n") pp.pprint(delete_label_response) print("\n=====End of Response=====") # DELETE A LABEL GROUP delete_label_group_request = { "LabelGroupName": LABEL_GROUP_NAME } delete_label_group_response = lookoutequipment_client.delete_label_group(**delete_label_group_request) print("=====Delete Label Group Response=====\n") pp.pprint(delete_label_group_response) print("\n=====End of Response=====") Training a model Note You can also train a model with the console. The following example code uses the AWS SDK for Python (Boto3) to train a model. Training a model 149 Amazon Lookout for Equipment User Guide import boto3 import json import pprint import time from datetime import datetime from botocore.config import Config config = Config(region_name = 'Region') lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) MODEL_NAME = 'model-name' # You can choose a sampling rate for your data. The valid values are "PT1S", "PT5S", "PT10S", "PT15S", "PT30S", "PT1M", "PT5M", "PT10M", "PT15M", "PT30M", "PT1H". S - second, M - minute, H - hour TARGET_SAMPLING_RATE = 'sampling-rate' # If you have label data in label group (See Labeling APIs example) LABEL_GROUP_NAME = 'your-label-group' # If you have label data in S3, specify the following variables LABEL_DATA_SOURCE_BUCKET = 'amzn-s3-demo-source-bucket' LABEL_DATA_SOURCE_PREFIX = 'label-data-source-prefix/' # This must end with "/" if you provide a prefix # The following are example training and evaluation start times. datetime(2018, 8, 13, 0, 0, 0) generates 2018-08-13 00:00:00 TRAINING_DATA_START_TIME = datetime(2016, 11, 1, 0, 0, 0) TRAINING_DATA_END_TIME = datetime(2017, 12, 31, 0, 0, 0) EVALUATION_DATA_START_TIME = datetime(2018, 1, 1, 0, 0, 0) EVALUATION_DATA_END_TIME = datetime(2018, 8, 13, 0, 0, 0) # To configure off-time detection, use the format # OFF_CONDITION = '{component}\\{sensor} < {target}' # In the following example, Asset X will be considered to be in the off state if the latest value # received by Sensor 1 is less than 10. OFF_CONDITION = 'AssetX\\Sensor1 < 10.0' ######################################################## Training a model 150 Amazon Lookout for Equipment User Guide # construct request for create_model ######################################################## model_name = MODEL_NAME DATA_SCHEMA_FOR_MODEL = None # You can use a schema similar to dataset here. The sensors used here should be subset of what is present in dataset create_model_request = { 'ModelName': model_name, 'DatasetName': DATASET_NAME, } if DATA_SCHEMA_FOR_MODEL is not None: data_schema_for_model = { 'InlineDataSchema': DATA_SCHEMA_FOR_MODEL, } create_model_request['DatasetSchema'] = data_schema_for_model if TARGET_SAMPLING_RATE is not None: data_preprocessing_config = { 'TargetSamplingRate': TARGET_SAMPLING_RATE } create_model_request['DataPreProcessingConfiguration'] = data_preprocessing_config if LABEL_GROUP_NAME is not None: labels_input_config = dict() labels_input_config['LabelGroupName'] = LABEL_GROUP_NAME create_model_request['LabelsInputConfiguration'] = labels_input_config elif LABEL_DATA_SOURCE_BUCKET is not None: labels_input_config = dict() labels_input_config['S3InputConfiguration'] = dict( [ ('Bucket', LABEL_DATA_SOURCE_BUCKET), ('Prefix', LABEL_DATA_SOURCE_PREFIX) ] ) create_model_request['LabelsInputConfiguration'] = labels_input_config # We need to set role_arn to access label data create_model_request['RoleArn'] = ROLE_ARN if TRAINING_DATA_START_TIME is not None or TRAINING_DATA_END_TIME is not None: create_model_request['TrainingDataStartTime'] = TRAINING_DATA_START_TIME create_model_request['TrainingDataEndTime'] = TRAINING_DATA_END_TIME Training a model 151 Amazon Lookout for Equipment User Guide if EVALUATION_DATA_START_TIME is not None or EVALUATION_DATA_END_TIME is not None: create_model_request['EvaluationDataStartTime'] = EVALUATION_DATA_START_TIME create_model_request['EvaluationDataEndTime'] = EVALUATION_DATA_END_TIME if OFF_CONDITION is not None: create_model_request['OffCondition'] = OFF_CONDITION ######################################################## # Create_model ######################################################## create_model_response = lookoutequipment.create_model(**create_model_request) ######################################################## # Wait until complete ######################################################## model_status = create_model_response['Status'] print("=====Polling Model Status=====\n") print("Model Status: " + model_status) while model_status == 'IN_PROGRESS': time.sleep(30) describe_model_response = lookoutequipment.describe_model(ModelName=model_name) model_status = describe_model_response['Status'] print("Model Status: " + model_status) print("\n=====End of Polling Model Status=====") Schedule inference Note You can also schedule inference with the console. The following example code uses the AWS SDK for Python (Boto3) to schedule an inference for your asset. import boto3 import json import pprint Schedule inference 152 Amazon Lookout for Equipment import time from datetime import datetime from botocore.config import Config config = Config(region_name = 'Region') User Guide lookoutequipment = boto3.client(service_name="lookoutequipment", config=config) # Specify a name for the inference scheduler INFERENCE_SCHEDULER_NAME = 'inference-scheduler-name' MODEL_NAME_FOR_CREATING_INFERENCE_SCHEDULER = 'model-name' # You must specify values for the following variables to successfully schedule an inference. # DATA_UPLOAD_FREQUENCY – The frequency that the data from the asset uploads to the Amazon S3 data containing the inference data. The valid values are PT5M, PT10M, PT30M, and PT1H # INFERENCE_DATA_SOURCE_BUCKET – The S3 bucket that stores the inference data coming from your asset. # INFERENCE_DATA_SOURCE_PREFIX – The S3 prefix that helps you access the inference data coming from your asset. # INFERENCE_DATA_OUTPUT_BUCKET – The S3 bucket that stores the results of the inference. # INFERENCE_DATA_OUTPUT_PREFIX – The S3 prefix that helps you access the results of the inference. # ROLE_ARN_FOR_INFERENCE – The IAM
amazon-lookout-for-equipment-ug-052
amazon-lookout-for-equipment-ug.pdf
52
to successfully schedule an inference. # DATA_UPLOAD_FREQUENCY – The frequency that the data from the asset uploads to the Amazon S3 data containing the inference data. The valid values are PT5M, PT10M, PT30M, and PT1H # INFERENCE_DATA_SOURCE_BUCKET – The S3 bucket that stores the inference data coming from your asset. # INFERENCE_DATA_SOURCE_PREFIX – The S3 prefix that helps you access the inference data coming from your asset. # INFERENCE_DATA_OUTPUT_BUCKET – The S3 bucket that stores the results of the inference. # INFERENCE_DATA_OUTPUT_PREFIX – The S3 prefix that helps you access the results of the inference. # ROLE_ARN_FOR_INFERENCE – The IAM role that gives Amazon Lookout for Equipment read permissions for Amazon S3. # You can specify values for the following optional variables. # DATA_DELAY_OFFSET_IN_MINUTES – The number of minutes to account for a delay in uploading the data to Amazon S3 from your data pipeline. # INPUT_TIMEZONE_OFFSET – The default timezone for running inference is in UTC. You can offset the default timezone in increments of 30 minutes. This offset only applies to the file name. If you choose to use the offset, you must have the timestamps for the sensor in UTC as well. The valid values include +00:00, +00:30, -01:00, ... +11:30, +12:00, -00:00, -00:30, -01:00, ... -11:30, -12:00. # TIMESTAMP_FORMAT – You can specify how the model outputs the timestamp in the results of the inference. The valid values are EPOCH, yyyy-MM-dd-HH-mm-ss or yyyyMMddHHmmss. # COMPONENT_TIMESTAMP_DELIMITER – Specifies the character used to separate entries in the input data. Default delimiter is - (hyphen). The valid values are -, _ or . DATA_DELAY_OFFSET_IN_MINUTES = None INPUT_TIMEZONE_OFFSET = None Schedule inference 153 Amazon Lookout for Equipment User Guide COMPONENT_TIMESTAMP_DELIMITER = None TIMESTAMP_FORMAT = None # Create an inference scheduler. scheduler_name = INFERENCE_SCHEDULER_NAME model_name = MODEL_NAME_FOR_CREATING_INFERENCE_SCHEDULER INFERENCE_DATA_SOURCE_BUCKET = 'amzn-s3-demo-source-bucket' INFERENCE_DATA_SOURCE_PREFIX = 'data-source-prefix' INFERENCE_DATA_OUTPUT_BUCKET = 'amzn-s3-demo-destination-bucket' INFERENCE_DATA_OUTPUT_PREFIX = 'data-output-prefix' ROLE_ARN_FOR_INFERENCE = ROLE_ARN DATA_UPLOAD_FREQUENCY = 'data-upload-frequency' create_inference_scheduler_request = { 'ModelName': model_name, 'InferenceSchedulerName': scheduler_name, 'DataUploadFrequency': DATA_UPLOAD_FREQUENCY, 'RoleArn': ROLE_ARN_FOR_INFERENCE, } if DATA_DELAY_OFFSET_IN_MINUTES is not None: create_inference_scheduler_request['DataDelayOffsetInMinutes'] = DATA_DELAY_OFFSET_IN_MINUTES # Set up data input configuration. inference_input_config = dict() inference_input_config['S3InputConfiguration'] = dict( [ ('Bucket', INFERENCE_DATA_SOURCE_BUCKET), ('Prefix', INFERENCE_DATA_SOURCE_PREFIX) ] ) if INPUT_TIMEZONE_OFFSET is not None: inference_input_config['InputTimeZoneOffset'] = INPUT_TIMEZONE_OFFSET if COMPONENT_TIMESTAMP_DELIMITER is not None or TIMESTAMP_FORMAT is not None: inference_input_name_configuration = dict() if COMPONENT_TIMESTAMP_DELIMITER is not None: Schedule inference 154 Amazon Lookout for Equipment User Guide inference_input_name_configuration['ComponentTimestampDelimiter'] = COMPONENT_TIMESTAMP_DELIMITER if TIMESTAMP_FORMAT is not None: inference_input_name_configuration['TimestampFormat'] = TIMESTAMP_FORMAT inference_input_config['InferenceInputNameConfiguration'] = inference_input_name_configuration create_inference_scheduler_request['DataInputConfiguration'] = inference_input_config # Set up output configuration. inference_output_configuration = dict() inference_output_configuration['S3OutputConfiguration'] = dict( [ ('Bucket', INFERENCE_DATA_OUTPUT_BUCKET), ('Prefix', INFERENCE_DATA_OUTPUT_PREFIX) ] ) create_inference_scheduler_request['DataOutputConfiguration'] = inference_output_configuration ######################################################## # Invoke create_inference_scheduler ######################################################## create_scheduler_response = lookoutequipment.create_inference_scheduler(**create_inference_scheduler_request) print("\n\n=====CreateInferenceScheduler Response=====\n") pp = pprint.PrettyPrinter(depth=5) pp.pprint(create_scheduler_response) print("\n=====End of CreateInferenceScheduler Response=====") ######################################################## # Wait until RUNNING ######################################################## scheduler_status = create_scheduler_response['Status'] print("=====Polling Inference Scheduler Status=====\n") print("Model Status: " + scheduler_status) while scheduler_status == 'PENDING': time.sleep(5) describe_scheduler_response = lookoutequipment.describe_inference_scheduler(InferenceSchedulerName=INFERENCE_SCHEDULER_NAME) scheduler_status = describe_scheduler_response['Status'] print("Scheduler Status: " + scheduler_status) print("\n=====End of Polling Inference Scheduler Status=====") Schedule inference 155 Amazon Lookout for Equipment User Guide Schedule inference 156 Amazon Lookout for Equipment User Guide API Reference This section contains the API Reference documentation. Actions The following actions are supported: • CreateDataset • CreateInferenceScheduler • CreateLabel • CreateLabelGroup • CreateModel • CreateRetrainingScheduler • DeleteDataset • DeleteInferenceScheduler • DeleteLabel • DeleteLabelGroup • DeleteModel • DeleteResourcePolicy • DeleteRetrainingScheduler • DescribeDataIngestionJob • DescribeDataset • DescribeInferenceScheduler • DescribeLabel • DescribeLabelGroup • DescribeModel • DescribeModelVersion • DescribeResourcePolicy • DescribeRetrainingScheduler • ImportDataset Actions 157 User Guide Amazon Lookout for Equipment • ImportModelVersion • ListDataIngestionJobs • ListDatasets • ListInferenceEvents • ListInferenceExecutions • ListInferenceSchedulers • ListLabelGroups • ListLabels • ListModels • ListModelVersions • ListRetrainingSchedulers • ListSensorStatistics • ListTagsForResource • PutResourcePolicy • StartDataIngestionJob • StartInferenceScheduler • StartRetrainingScheduler • StopInferenceScheduler • StopRetrainingScheduler • TagResource • UntagResource • UpdateActiveModelVersion • UpdateInferenceScheduler • UpdateLabelGroup • UpdateModel • UpdateRetrainingScheduler Actions 158 Amazon Lookout for Equipment CreateDataset User Guide Creates a container for a collection of data being ingested for analysis. The dataset contains the metadata describing where the data is and what the data actually looks like. For example, it contains the location of the data source, the data schema, and other information. A dataset also contains any tags associated with the ingested data. Request Syntax { "ClientToken": "string", "DatasetName": "string", "DatasetSchema": { "InlineDataSchema": "string" }, "ServerSideKmsKeyId": "string", "Tags": [ { "Key": "string", "Value": "string" } ] } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes DatasetName The name of the dataset being created. CreateDataset 159 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes DatasetSchema A JSON description of the data
amazon-lookout-for-equipment-ug-053
amazon-lookout-for-equipment-ug.pdf
53
"ServerSideKmsKeyId": "string", "Tags": [ { "Key": "string", "Value": "string" } ] } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes DatasetName The name of the dataset being created. CreateDataset 159 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes DatasetSchema A JSON description of the data that is in each time series dataset, including names, column names, and data types. Type: DatasetSchema object Required: No ServerSideKmsKeyId Provides the identifier of the AWS KMS key used to encrypt dataset data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No Tags Any tags associated with the ingested data described in the dataset. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. Required: No Response Syntax { "DatasetArn": "string", CreateDataset 160 User Guide Amazon Lookout for Equipment "DatasetName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. DatasetArn The Amazon Resource Name (ARN) of the dataset being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DatasetName The name of the dataset being created. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Status Indicates the status of the CreateDataset operation. Type: String Valid Values: CREATED | INGESTION_IN_PROGRESS | ACTIVE | IMPORT_IN_PROGRESS Errors AccessDeniedException The request could not be completed because you do not have access to the resource. CreateDataset 161 Amazon Lookout for Equipment HTTP Status Code: 400 ConflictException User Guide The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 CreateDataset 162 Amazon Lookout for Equipment • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide CreateDataset 163 Amazon Lookout for Equipment User Guide CreateInferenceScheduler Creates a scheduled inference. Scheduling an inference is setting up a continuous real-time inference plan to analyze new measurement data. When setting up the schedule, you provide an S3 bucket location for the input data, assign it a delimiter between separate entries in the data, set an offset delay if desired, and set the frequency of inferencing. You must also provide an S3 bucket location for the output data. Request Syntax { "ClientToken": "string", "DataDelayOffsetInMinutes": number, "DataInputConfiguration": { "InferenceInputNameConfiguration": { "ComponentTimestampDelimiter": "string", "TimestampFormat": "string" }, "InputTimeZoneOffset": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataUploadFrequency": "string", "InferenceSchedulerName": "string", "ModelName": "string", "RoleArn": "string", "ServerSideKmsKeyId": "string", "Tags": [ { "Key": "string", "Value": "string" } ] CreateInferenceScheduler 164 Amazon Lookout for Equipment } Request Parameters The request accepts the following data in JSON format. ClientToken User Guide A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes DataDelayOffsetInMinutes The interval (in minutes) of planned delay at the start of each inference segment. For example, if inference is set to run every ten minutes, the delay is set to five minutes and the time is 09:08. The inference scheduler will wake up at the configured interval (which, without a delay configured, would be 09:10) plus the additional five minute delay time (so 09:15) to check your Amazon S3 bucket. The delay provides a buffer for you to upload data at the same frequency, so that you don't have to stop and restart the scheduler when uploading new data. For more information, see Understanding the inference process. Type: Long
amazon-lookout-for-equipment-ug-054
amazon-lookout-for-equipment-ug.pdf
54
start of each inference segment. For example, if inference is set to run every ten minutes, the delay is set to five minutes and the time is 09:08. The inference scheduler will wake up at the configured interval (which, without a delay configured, would be 09:10) plus the additional five minute delay time (so 09:15) to check your Amazon S3 bucket. The delay provides a buffer for you to upload data at the same frequency, so that you don't have to stop and restart the scheduler when uploading new data. For more information, see Understanding the inference process. Type: Long Valid Range: Minimum value of 0. Maximum value of 60. Required: No DataInputConfiguration Specifies configuration information for the input data for the inference scheduler, including delimiter, format, and dataset location. Type: InferenceInputConfiguration object Required: Yes CreateInferenceScheduler 165 Amazon Lookout for Equipment DataOutputConfiguration User Guide Specifies configuration information for the output results for the inference scheduler, including the S3 location for the output. Type: InferenceOutputConfiguration object Required: Yes DataUploadFrequency How often data is uploaded to the source Amazon S3 bucket for the input data. The value chosen is the length of time between data uploads. For instance, if you select 5 minutes, Amazon Lookout for Equipment will upload the real-time data to the source bucket once every 5 minutes. This frequency also determines how often Amazon Lookout for Equipment runs inference on your data. For more information, see Understanding the inference process. Type: String Valid Values: PT5M | PT10M | PT15M | PT30M | PT1H Required: Yes InferenceSchedulerName The name of the inference scheduler being created. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes ModelName The name of the previously trained machine learning model being used to create the inference scheduler. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. CreateInferenceScheduler 166 Amazon Lookout for Equipment User Guide Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source being used for the inference. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Required: Yes ServerSideKmsKeyId Provides the identifier of the AWS KMS key used to encrypt inference scheduler data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No Tags Any tags associated with the inference scheduler. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. Required: No Response Syntax { "InferenceSchedulerArn": "string", CreateInferenceScheduler 167 Amazon Lookout for Equipment User Guide "InferenceSchedulerName": "string", "ModelQuality": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference scheduler being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ InferenceSchedulerName The name of inference scheduler being created. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ ModelQuality Provides a quality assessment for a model that uses labels. If Lookout for Equipment determines that the model quality is poor based on training metrics, the value is POOR_QUALITY_DETECTED. Otherwise, the value is QUALITY_THRESHOLD_MET. If the model is unlabeled, the model quality can't be assessed and the value of ModelQuality is CANNOT_DETERMINE_QUALITY. In this situation, you can get a model quality assessment by adding labels to the input dataset and retraining the model. For information about using labels with your models, see Understanding labeling. CreateInferenceScheduler 168 Amazon Lookout for Equipment User Guide For information about improving the quality of a model, see Best practices with Amazon Lookout for Equipment. Type: String Valid Values: QUALITY_THRESHOLD_MET | CANNOT_DETERMINE_QUALITY | POOR_QUALITY_DETECTED Status Indicates the status of the CreateInferenceScheduler operation. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. CreateInferenceScheduler 169 Amazon Lookout for Equipment HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about
amazon-lookout-for-equipment-ug-055
amazon-lookout-for-equipment-ug.pdf
55
Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. CreateInferenceScheduler 169 Amazon Lookout for Equipment HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 CreateInferenceScheduler 170 User Guide Amazon Lookout for Equipment CreateLabel Creates a label for an event. Request Syntax { "ClientToken": "string", "EndTime": number, "Equipment": "string", "FaultCode": "string", "LabelGroupName": "string", "Notes": "string", "Rating": "string", "StartTime": number } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request to create a label. If you do not set the client request token, Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes EndTime The end time of the labeled event. Type: Timestamp Required: Yes Equipment Indicates that a label pertains to a particular piece of equipment. CreateLabel 171 Amazon Lookout for Equipment User Guide Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: [\P{M}\p{M}]{1,200} Required: No FaultCode Provides additional information about the label. The fault code must be defined in the FaultCodes attribute of the label group. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 100. Pattern: [\P{M}\p{M}]{1,100} Required: No LabelGroupName The name of a group of labels. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Notes Metadata providing additional information about the label. CreateLabel 172 Amazon Lookout for Equipment User Guide Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 2560. Pattern: [\P{M}\p{M}]{1,2560} Required: No Rating Indicates whether a labeled event represents an anomaly. Type: String Valid Values: ANOMALY | NO_ANOMALY | NEUTRAL Required: Yes StartTime The start time of the labeled event. Type: Timestamp Required: Yes Response Syntax { "LabelId": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. LabelId The ID of the label that you have created. CreateLabel 173 Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 CreateLabel 174 Amazon Lookout for Equipment ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 CreateLabel 175 User Guide Amazon Lookout for Equipment CreateLabelGroup Creates a group of labels. Request Syntax { "ClientToken": "string", "FaultCodes": [ "string" ],
amazon-lookout-for-equipment-ug-056
amazon-lookout-for-equipment-ug.pdf
56
Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 CreateLabel 175 User Guide Amazon Lookout for Equipment CreateLabelGroup Creates a group of labels. Request Syntax { "ClientToken": "string", "FaultCodes": [ "string" ], "LabelGroupName": "string", "Tags": [ { "Key": "string", "Value": "string" } ] } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request to create a label group. If you do not set the client request token, Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes FaultCodes The acceptable fault codes (indicating the type of anomaly associated with the label) that can be used with this label group. Data in this field will be retained for service usage. Follow best practices for the security of your data. CreateLabelGroup 176 Amazon Lookout for Equipment Type: Array of strings User Guide Array Members: Minimum number of 0 items. Maximum number of 50 items. Length Constraints: Minimum length of 1. Maximum length of 100. Pattern: [\P{M}\p{M}]{1,100} Required: No LabelGroupName Names a group of labels. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Tags Tags that provide metadata about the label group you are creating. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. Required: No Response Syntax { "LabelGroupArn": "string", "LabelGroupName": "string" CreateLabelGroup 177 Amazon Lookout for Equipment } Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. LabelGroupArn The Amazon Resource Name (ARN) of the label group that you have created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:label- group\/.+ LabelGroupName The name of the label group that you have created. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 CreateLabelGroup 178 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 CreateLabelGroup 179 Amazon Lookout for Equipment User Guide CreateLabelGroup 180 Amazon Lookout for Equipment CreateModel Creates a machine learning model for data inference. User Guide A machine-learning (ML) model is a mathematical model that finds patterns in your data. In Amazon Lookout for Equipment, the model learns the patterns of normal behavior and detects abnormal behavior that could be potential equipment failure (or maintenance events). The models are made by analyzing normal data and abnormalities in machine behavior that have already occurred. Your model is trained using a portion of the data from your dataset and uses that data to learn patterns of normal behavior and abnormal patterns that lead to equipment failure. Another portion of the data is used to evaluate the model's accuracy. Request Syntax { "ClientToken": "string", "DataPreProcessingConfiguration": { "TargetSamplingRate": "string" }, "DatasetName": "string", "DatasetSchema": { "InlineDataSchema": "string" }, "EvaluationDataEndTime": number, "EvaluationDataStartTime": number, "LabelsInputConfiguration": { "LabelGroupName": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" }
amazon-lookout-for-equipment-ug-057
amazon-lookout-for-equipment-ug.pdf
57
could be potential equipment failure (or maintenance events). The models are made by analyzing normal data and abnormalities in machine behavior that have already occurred. Your model is trained using a portion of the data from your dataset and uses that data to learn patterns of normal behavior and abnormal patterns that lead to equipment failure. Another portion of the data is used to evaluate the model's accuracy. Request Syntax { "ClientToken": "string", "DataPreProcessingConfiguration": { "TargetSamplingRate": "string" }, "DatasetName": "string", "DatasetSchema": { "InlineDataSchema": "string" }, "EvaluationDataEndTime": number, "EvaluationDataStartTime": number, "LabelsInputConfiguration": { "LabelGroupName": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelDiagnosticsOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelName": "string", CreateModel 181 Amazon Lookout for Equipment User Guide "OffCondition": "string", "RoleArn": "string", "ServerSideKmsKeyId": "string", "Tags": [ { "Key": "string", "Value": "string" } ], "TrainingDataEndTime": number, "TrainingDataStartTime": number } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes DataPreProcessingConfiguration The configuration is the TargetSamplingRate, which is the sampling rate of the data after post processing by Amazon Lookout for Equipment. For example, if you provide data that has been collected at a 1 second level and you want the system to resample the data at a 1 minute rate before training, the TargetSamplingRate is 1 minute. When providing a value for the TargetSamplingRate, you must attach the prefix "PT" to the rate you want. The value for a 1 second rate is therefore PT1S, the value for a 15 minute rate is PT15M, and the value for a 1 hour rate is PT1H Type: DataPreProcessingConfiguration object CreateModel 182 Amazon Lookout for Equipment Required: No DatasetName User Guide The name of the dataset for the machine learning model being created. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes DatasetSchema The data schema for the machine learning model being created. Type: DatasetSchema object Required: No EvaluationDataEndTime Indicates the time reference in the dataset that should be used to end the subset of evaluation data for the machine learning model. Type: Timestamp Required: No EvaluationDataStartTime Indicates the time reference in the dataset that should be used to begin the subset of evaluation data for the machine learning model. Type: Timestamp Required: No LabelsInputConfiguration The input configuration for the labels being used for the machine learning model that's being created. Type: LabelsInputConfiguration object CreateModel 183 Amazon Lookout for Equipment Required: No ModelDiagnosticsOutputConfiguration User Guide The Amazon S3 location where you want Amazon Lookout for Equipment to save the pointwise model diagnostics. You must also specify the RoleArn request parameter. Type: ModelDiagnosticsOutputConfiguration object Required: No ModelName The name for the machine learning model to be created. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes OffCondition Indicates that the asset associated with this sensor has been shut off. As long as this condition is met, Lookout for Equipment will not use data from this asset for training, evaluation, or inference. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Required: No RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source being used to create the machine learning model. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Required: No CreateModel 184 Amazon Lookout for Equipment ServerSideKmsKeyId User Guide Provides the identifier of the AWS KMS key used to encrypt model data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No Tags Any tags associated with the machine learning model being created. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. Required: No TrainingDataEndTime Indicates the time reference in the dataset that should be used to end the subset of training data for the machine learning model. Type: Timestamp Required: No TrainingDataStartTime Indicates the time reference in the dataset that should be used to begin the subset of training data for the machine learning model. Type: Timestamp Required: No Response Syntax { CreateModel 185 User Guide Amazon Lookout for Equipment "ModelArn": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ModelArn The Amazon Resource Name (ARN) of the model being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Status Indicates the status of the CreateModel operation. Type: String Valid Values: IN_PROGRESS | SUCCESS
amazon-lookout-for-equipment-ug-058
amazon-lookout-for-equipment-ug.pdf
58
used to begin the subset of training data for the machine learning model. Type: Timestamp Required: No Response Syntax { CreateModel 185 User Guide Amazon Lookout for Equipment "ModelArn": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ModelArn The Amazon Resource Name (ARN) of the model being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Status Indicates the status of the CreateModel operation. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 CreateModel 186 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 CreateModel 187 Amazon Lookout for Equipment • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide CreateModel 188 Amazon Lookout for Equipment User Guide CreateRetrainingScheduler Creates a retraining scheduler on the specified model. Request Syntax { "ClientToken": "string", "LookbackWindow": "string", "ModelName": "string", "PromoteMode": "string", "RetrainingFrequency": "string", "RetrainingStartDate": number } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes LookbackWindow The number of past days of data that will be used for retraining. Type: String Pattern: ^P180D$|^P360D$|^P540D$|^P720D$ Required: Yes ModelName The name of the model to add the retraining scheduler to. CreateRetrainingScheduler 189 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes PromoteMode Indicates how the service will use new models. In MANAGED mode, new models will automatically be used for inference if they have better performance than the current model. In MANUAL mode, the new models will not be used until they are manually activated. Type: String Valid Values: MANAGED | MANUAL Required: No RetrainingFrequency This parameter uses the ISO 8601 standard to set the frequency at which you want retraining to occur in terms of Years, Months, and/or Days (note: other parameters like Time are not currently supported). The minimum value is 30 days (P30D) and the maximum value is 1 year (P1Y). For example, the following values are valid: • P3M15D – Every 3 months and 15 days • P2M – Every 2 months • P150D – Every 150 days Type: String Length Constraints: Minimum length of 1. Maximum length of 10. Pattern: ^P(\dY)?(\d{1,2}M)?(\d{1,3}D)?$ Required: Yes RetrainingStartDate The start date for the retraining scheduler. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp CreateRetrainingScheduler 190 User Guide Amazon Lookout for Equipment Required: No Response Syntax { "ModelArn": "string", "ModelName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ModelArn The ARN of the model that you added the retraining scheduler to. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the model that you added the retraining scheduler to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED CreateRetrainingScheduler 191 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource.
amazon-lookout-for-equipment-ug-059
amazon-lookout-for-equipment-ug.pdf
59
Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the model that you added the retraining scheduler to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED CreateRetrainingScheduler 191 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: CreateRetrainingScheduler 192 User Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 CreateRetrainingScheduler 193 Amazon Lookout for Equipment DeleteDataset User Guide Deletes a dataset and associated artifacts. The operation will check to see if any inference scheduler or data ingestion job is currently using the dataset, and if there isn't, the dataset, its metadata, and any associated data stored in S3 will be deleted. This does not affect any models that used this dataset for training and evaluation, but does prevent it from being used in the future. Request Syntax { "DatasetName": "string" } Request Parameters The request accepts the following data in JSON format. DatasetName The name of the dataset to be deleted. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 DeleteDataset 194 Amazon Lookout for Equipment ConflictException User Guide The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 DeleteDataset 195 Amazon Lookout for Equipment • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide DeleteDataset 196 Amazon Lookout for Equipment User Guide DeleteInferenceScheduler Deletes an inference scheduler that has been set up. Prior inference results will not be deleted. Request Syntax { "InferenceSchedulerName": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerName The name of the inference scheduler to be deleted. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. DeleteInferenceScheduler 197 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling.
amazon-lookout-for-equipment-ug-060
amazon-lookout-for-equipment-ug.pdf
60
Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. DeleteInferenceScheduler 197 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python DeleteInferenceScheduler 198 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide DeleteInferenceScheduler 199 User Guide Amazon Lookout for Equipment DeleteLabel Deletes a label. Request Syntax { "LabelGroupName": "string", "LabelId": "string" } Request Parameters The request accepts the following data in JSON format. LabelGroupName The name of the label group that contains the label that you want to delete. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes LabelId The ID of the label that you want to delete. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. DeleteLabel 200 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: DeleteLabel 201 User Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DeleteLabel 202 User Guide Amazon Lookout for Equipment DeleteLabelGroup Deletes a group of labels. Request Syntax { "LabelGroupName": "string" } Request Parameters The request accepts the following data in JSON format. LabelGroupName The name of the label group that you want to delete. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. DeleteLabelGroup 203 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS
amazon-lookout-for-equipment-ug-061
amazon-lookout-for-equipment-ug.pdf
61
the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python DeleteLabelGroup 204 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide DeleteLabelGroup 205 Amazon Lookout for Equipment DeleteModel User Guide Deletes a machine learning model currently available for Amazon Lookout for Equipment. This will prevent it from being used with an inference scheduler, even one that is already set up. Request Syntax { "ModelName": "string" } Request Parameters The request accepts the following data in JSON format. ModelName The name of the machine learning model to be deleted. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. DeleteModel 206 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python DeleteModel 207 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide DeleteModel 208 Amazon Lookout for Equipment DeleteResourcePolicy Deletes the resource policy attached to the resource. User Guide Request Syntax { "ResourceArn": "string" } Request Parameters The request accepts the following data in JSON format. ResourceArn The Amazon Resource Name (ARN) of the resource for which the resource policy should be deleted. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:.+ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. DeleteResourcePolicy 209 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python DeleteResourcePolicy 210 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide DeleteResourcePolicy 211 Amazon Lookout for Equipment User Guide DeleteRetrainingScheduler Deletes a retraining scheduler from a model. The retraining scheduler must be in the STOPPED status. Request Syntax { "ModelName": "string" } Request
amazon-lookout-for-equipment-ug-062
amazon-lookout-for-equipment-ug.pdf
62
AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python DeleteResourcePolicy 210 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide DeleteResourcePolicy 211 Amazon Lookout for Equipment User Guide DeleteRetrainingScheduler Deletes a retraining scheduler from a model. The retraining scheduler must be in the STOPPED status. Request Syntax { "ModelName": "string" } Request Parameters The request accepts the following data in JSON format. ModelName The name of the model whose retraining scheduler you want to delete. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. DeleteRetrainingScheduler 212 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python DeleteRetrainingScheduler 213 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide DeleteRetrainingScheduler 214 Amazon Lookout for Equipment User Guide DescribeDataIngestionJob Provides information on a specific data ingestion job such as creation time, dataset ARN, and status. Request Syntax { "JobId": "string" } Request Parameters The request accepts the following data in JSON format. JobId The job ID of the data ingestion job. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Required: Yes Response Syntax { "CreatedAt": number, "DataEndTime": number, "DataQualitySummary": { "DuplicateTimestamps": { "TotalNumberOfDuplicateTimestamps": number }, "InsufficientSensorData": { "MissingCompleteSensorData": { "AffectedSensorCount": number }, "SensorsWithShortDateRange": { "AffectedSensorCount": number DescribeDataIngestionJob 215 User Guide Amazon Lookout for Equipment } }, "InvalidSensorData": { "AffectedSensorCount": number, "TotalNumberOfInvalidValues": number }, "MissingSensorData": { "AffectedSensorCount": number, "TotalNumberOfMissingValues": number }, "UnsupportedTimestamps": { "TotalNumberOfUnsupportedTimestamps": number } }, "DatasetArn": "string", "DataStartTime": number, "FailedReason": "string", "IngestedDataSize": number, "IngestedFilesSummary": { "DiscardedFiles": [ { "Bucket": "string", "Key": "string" } ], "IngestedNumberOfFiles": number, "TotalNumberOfFiles": number }, "IngestionInputConfiguration": { "S3InputConfiguration": { "Bucket": "string", "KeyPattern": "string", "Prefix": "string" } }, "JobId": "string", "RoleArn": "string", "SourceDatasetArn": "string", "Status": "string", "StatusDetail": "string" } DescribeDataIngestionJob 216 Amazon Lookout for Equipment Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CreatedAt The time at which the data ingestion job was created. Type: Timestamp DataEndTime Indicates the latest timestamp corresponding to data that was successfully ingested during this specific ingestion job. Type: Timestamp DataQualitySummary Gives statistics about a completed ingestion job. These statistics primarily relate to quantifying incorrect data such as MissingCompleteSensorData, MissingSensorData, UnsupportedDateFormats, InsufficientSensorData, and DuplicateTimeStamps. Type: DataQualitySummary object DatasetArn The Amazon Resource Name (ARN) of the dataset being used in the data ingestion job. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DataStartTime Indicates the earliest timestamp corresponding to data that was successfully ingested during this specific ingestion job. Type: Timestamp DescribeDataIngestionJob 217 Amazon Lookout for Equipment FailedReason User Guide Specifies the reason for failure when a data ingestion job has failed. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} IngestedDataSize Indicates the size of the ingested dataset. Type: Long Valid Range: Minimum value of 0. IngestedFilesSummary Gives statistics about how many files have been ingested, and which files have not been ingested, for a particular ingestion job. Type: IngestedFilesSummary object IngestionInputConfiguration Specifies the S3 location configuration for the data input for the data ingestion job. Type: IngestionInputConfiguration object JobId Indicates the job ID of the data ingestion job. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} RoleArn The Amazon Resource Name (ARN) of an
amazon-lookout-for-equipment-ug-063
amazon-lookout-for-equipment-ug.pdf
63
String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} IngestedDataSize Indicates the size of the ingested dataset. Type: Long Valid Range: Minimum value of 0. IngestedFilesSummary Gives statistics about how many files have been ingested, and which files have not been ingested, for a particular ingestion job. Type: IngestedFilesSummary object IngestionInputConfiguration Specifies the S3 location configuration for the data input for the data ingestion job. Type: IngestionInputConfiguration object JobId Indicates the job ID of the data ingestion job. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} RoleArn The Amazon Resource Name (ARN) of an IAM role with permission to access the data source being ingested. Type: String DescribeDataIngestionJob 218 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ SourceDatasetArn The Amazon Resource Name (ARN) of the source dataset from which the data used for the data ingestion job was imported from. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ Status Indicates the status of the DataIngestionJob operation. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS StatusDetail Provides details about status of the ingestion job that is currently in progress. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. DescribeDataIngestionJob 219 Amazon Lookout for Equipment HTTP Status Code: 500 ResourceNotFoundException User Guide The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeDataIngestionJob 220 Amazon Lookout for Equipment DescribeDataset User Guide Provides a JSON description of the data in each time series dataset, including names, column names, and data types. Request Syntax { "DatasetName": "string" } Request Parameters The request accepts the following data in JSON format. DatasetName The name of the dataset to be described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "CreatedAt": number, "DataEndTime": number, "DataQualitySummary": { "DuplicateTimestamps": { "TotalNumberOfDuplicateTimestamps": number }, "InsufficientSensorData": { "MissingCompleteSensorData": { "AffectedSensorCount": number }, "SensorsWithShortDateRange": { "AffectedSensorCount": number DescribeDataset 221 User Guide Amazon Lookout for Equipment } }, "InvalidSensorData": { "AffectedSensorCount": number, "TotalNumberOfInvalidValues": number }, "MissingSensorData": { "AffectedSensorCount": number, "TotalNumberOfMissingValues": number }, "UnsupportedTimestamps": { "TotalNumberOfUnsupportedTimestamps": number } }, "DatasetArn": "string", "DatasetName": "string", "DataStartTime": number, "IngestedFilesSummary": { "DiscardedFiles": [ { "Bucket": "string", "Key": "string" } ], "IngestedNumberOfFiles": number, "TotalNumberOfFiles": number }, "IngestionInputConfiguration": { "S3InputConfiguration": { "Bucket": "string", "KeyPattern": "string", "Prefix": "string" } }, "LastUpdatedAt": number, "RoleArn": "string", "Schema": "string", "ServerSideKmsKeyId": "string", "SourceDatasetArn": "string", "Status": "string" } DescribeDataset 222 Amazon Lookout for Equipment Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CreatedAt Specifies the time the dataset was created in Lookout for Equipment. Type: Timestamp DataEndTime Indicates the latest timestamp corresponding to data that was successfully ingested during the most recent ingestion of this particular dataset. Type: Timestamp DataQualitySummary Gives statistics associated with the given dataset for the latest successful associated ingestion job id. These statistics primarily relate to quantifying incorrect data such as MissingCompleteSensorData, MissingSensorData, UnsupportedDateFormats, InsufficientSensorData, and DuplicateTimeStamps. Type: DataQualitySummary object DatasetArn The Amazon Resource Name (ARN) of the dataset being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DatasetName The name of the dataset being described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. DescribeDataset 223 Amazon Lookout for Equipment User Guide Pattern: ^[0-9a-zA-Z_-]{1,200}$ DataStartTime Indicates the earliest timestamp corresponding to data that was successfully ingested during the most recent ingestion of this particular dataset. Type: Timestamp IngestedFilesSummary IngestedFilesSummary associated with the given dataset for the latest successful associated ingestion job id. Type: IngestedFilesSummary object IngestionInputConfiguration Specifies the S3 location configuration for the data input for the data ingestion job. Type: IngestionInputConfiguration object LastUpdatedAt Specifies the time the dataset was last updated,
amazon-lookout-for-equipment-ug-064
amazon-lookout-for-equipment-ug.pdf
64
arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DatasetName The name of the dataset being described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. DescribeDataset 223 Amazon Lookout for Equipment User Guide Pattern: ^[0-9a-zA-Z_-]{1,200}$ DataStartTime Indicates the earliest timestamp corresponding to data that was successfully ingested during the most recent ingestion of this particular dataset. Type: Timestamp IngestedFilesSummary IngestedFilesSummary associated with the given dataset for the latest successful associated ingestion job id. Type: IngestedFilesSummary object IngestionInputConfiguration Specifies the S3 location configuration for the data input for the data ingestion job. Type: IngestionInputConfiguration object LastUpdatedAt Specifies the time the dataset was last updated, if it was. Type: Timestamp RoleArn The Amazon Resource Name (ARN) of the IAM role that you are using for this the data ingestion job. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Schema A JSON description of the data that is in each time series dataset, including names, column names, and data types. Type: String Length Constraints: Minimum length of 1. Maximum length of 1000000. DescribeDataset 224 Amazon Lookout for Equipment ServerSideKmsKeyId User Guide Provides the identifier of the AWS KMS key used to encrypt dataset data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 1024. Pattern: arn:aws[a-z\-]*:kms:[a-z0-9\-]*:\d{12}:[\w\-\/]+ SourceDatasetArn The Amazon Resource Name (ARN) of the source dataset from which the current data being described was imported from. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ Status Indicates the status of the dataset. Type: String Valid Values: CREATED | INGESTION_IN_PROGRESS | ACTIVE | IMPORT_IN_PROGRESS Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 DescribeDataset 225 Amazon Lookout for Equipment ResourceNotFoundException User Guide The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeDataset 226 Amazon Lookout for Equipment User Guide DescribeInferenceScheduler Specifies information about the inference scheduler being used, including name, model, status, and associated metadata Request Syntax { "InferenceSchedulerName": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerName The name of the inference scheduler being described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "CreatedAt": number, "DataDelayOffsetInMinutes": number, "DataInputConfiguration": { "InferenceInputNameConfiguration": { "ComponentTimestampDelimiter": "string", "TimestampFormat": "string" }, "InputTimeZoneOffset": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } DescribeInferenceScheduler 227 User Guide Amazon Lookout for Equipment }, "DataOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataUploadFrequency": "string", "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string", "LatestInferenceResult": "string", "ModelArn": "string", "ModelName": "string", "RoleArn": "string", "ServerSideKmsKeyId": "string", "Status": "string", "UpdatedAt": number } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CreatedAt Specifies the time at which the inference scheduler was created. Type: Timestamp DataDelayOffsetInMinutes A period of time (in minutes) by which inference on the data is delayed after the data starts. For instance, if you select an offset delay time of five minutes, inference will not begin on the data until the first data measurement after the five minute mark. For example, if five minutes is selected, the inference scheduler will wake up at the configured frequency with the additional five minute delay time to check the customer S3 bucket. The customer can upload data at the same frequency and they don't need to stop and restart the scheduler when uploading new data. Type: Long DescribeInferenceScheduler 228 Amazon Lookout for Equipment User Guide Valid Range: Minimum value of 0. Maximum value of 60. DataInputConfiguration Specifies configuration information for the input data for the inference scheduler, including delimiter, format, and dataset location. Type: InferenceInputConfiguration object DataOutputConfiguration Specifies information for the output results for the inference scheduler, including the output S3 location. Type: InferenceOutputConfiguration object DataUploadFrequency Specifies how often data is uploaded to the source S3 bucket for the input data. This value is the length
amazon-lookout-for-equipment-ug-065
amazon-lookout-for-equipment-ug.pdf
65
data at the same frequency and they don't need to stop and restart the scheduler when uploading new data. Type: Long DescribeInferenceScheduler 228 Amazon Lookout for Equipment User Guide Valid Range: Minimum value of 0. Maximum value of 60. DataInputConfiguration Specifies configuration information for the input data for the inference scheduler, including delimiter, format, and dataset location. Type: InferenceInputConfiguration object DataOutputConfiguration Specifies information for the output results for the inference scheduler, including the output S3 location. Type: InferenceOutputConfiguration object DataUploadFrequency Specifies how often data is uploaded to the source S3 bucket for the input data. This value is the length of time between data uploads. For instance, if you select 5 minutes, Amazon Lookout for Equipment will upload the real-time data to the source bucket once every 5 minutes. This frequency also determines how often Amazon Lookout for Equipment starts a scheduled inference on your data. In this example, it starts once every 5 minutes. Type: String Valid Values: PT5M | PT10M | PT15M | PT30M | PT1H InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference scheduler being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ InferenceSchedulerName The name of the inference scheduler being described. Type: String DescribeInferenceScheduler 229 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ LatestInferenceResult Indicates whether the latest execution for the inference scheduler was Anomalous (anomalous events found) or Normal (no anomalous events found). Type: String Valid Values: ANOMALOUS | NORMAL ModelArn The Amazon Resource Name (ARN) of the machine learning model of the inference scheduler being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the machine learning model of the inference scheduler being described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source for the inference scheduler being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ DescribeInferenceScheduler 230 Amazon Lookout for Equipment ServerSideKmsKeyId User Guide Provides the identifier of the AWS KMS key used to encrypt inference scheduler data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 1024. Pattern: arn:aws[a-z\-]*:kms:[a-z0-9\-]*:\d{12}:[\w\-\/]+ Status Indicates the status of the inference scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED UpdatedAt Specifies the time at which the inference scheduler was last updated, if it was. Type: Timestamp Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 DescribeInferenceScheduler 231 Amazon Lookout for Equipment ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeInferenceScheduler 232 User Guide Amazon Lookout for Equipment DescribeLabel Returns the name of the label. Request Syntax { "LabelGroupName": "string", "LabelId": "string" } Request Parameters The request accepts the following data in JSON format. LabelGroupName Returns the name of the group containing the label. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes LabelId Returns the ID of the label. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Required: Yes Response Syntax { "CreatedAt": number, DescribeLabel 233 Amazon Lookout for Equipment User Guide "EndTime": number, "Equipment": "string", "FaultCode": "string", "LabelGroupArn": "string", "LabelGroupName": "string", "LabelId": "string", "Notes": "string", "Rating": "string", "StartTime": number } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CreatedAt The time at which the label was created. Type: Timestamp EndTime The end time of the requested label. Type: Timestamp Equipment Indicates that a label pertains to a particular piece of equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: [\P{M}\p{M}]{1,200} FaultCode Indicates the type of anomaly associated with
amazon-lookout-for-equipment-ug-066
amazon-lookout-for-equipment-ug.pdf
66
"EndTime": number, "Equipment": "string", "FaultCode": "string", "LabelGroupArn": "string", "LabelGroupName": "string", "LabelId": "string", "Notes": "string", "Rating": "string", "StartTime": number } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CreatedAt The time at which the label was created. Type: Timestamp EndTime The end time of the requested label. Type: Timestamp Equipment Indicates that a label pertains to a particular piece of equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: [\P{M}\p{M}]{1,200} FaultCode Indicates the type of anomaly associated with the label. Data in this field will be retained for service usage. Follow best practices for the security of your data. DescribeLabel 234 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 100. Pattern: [\P{M}\p{M}]{1,100} LabelGroupArn The Amazon Resource Name (ARN) of the requested label group. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:label- group\/.+ LabelGroupName The name of the requested label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ LabelId The ID of the requested label. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Notes Metadata providing additional information about the label. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 2560. DescribeLabel 235 Amazon Lookout for Equipment User Guide Pattern: [\P{M}\p{M}]{1,2560} Rating Indicates whether a labeled event represents an anomaly. Type: String Valid Values: ANOMALY | NO_ANOMALY | NEUTRAL StartTime The start time of the requested label. Type: Timestamp Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. DescribeLabel 236 Amazon Lookout for Equipment HTTP Status Code: 400 See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeLabel 237 User Guide Amazon Lookout for Equipment DescribeLabelGroup Returns information about the label group. Request Syntax { "LabelGroupName": "string" } Request Parameters The request accepts the following data in JSON format. LabelGroupName Returns the name of the label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "CreatedAt": number, "FaultCodes": [ "string" ], "LabelGroupArn": "string", "LabelGroupName": "string", "UpdatedAt": number } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. DescribeLabelGroup 238 Amazon Lookout for Equipment CreatedAt The time at which the label group was created. Type: Timestamp FaultCodes User Guide Codes indicating the type of anomaly associated with the labels in the lagbel group. Type: Array of strings Array Members: Minimum number of 0 items. Maximum number of 50 items. Length Constraints: Minimum length of 1. Maximum length of 100. Pattern: [\P{M}\p{M}]{1,100} LabelGroupArn The Amazon Resource Name (ARN) of the label group. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:label- group\/.+ LabelGroupName The name of the label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ UpdatedAt The time at which the label group was updated. Type: Timestamp DescribeLabelGroup 239 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in
amazon-lookout-for-equipment-ug-067
amazon-lookout-for-equipment-ug.pdf
67
because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 DescribeLabelGroup 240 Amazon Lookout for Equipment • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide DescribeLabelGroup 241 Amazon Lookout for Equipment DescribeModel User Guide Provides a JSON containing the overall information about a specific machine learning model, including model name and ARN, dataset, training and evaluation information, status, and so on. Request Syntax { "ModelName": "string" } Request Parameters The request accepts the following data in JSON format. ModelName The name of the machine learning model to be described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "AccumulatedInferenceDataEndTime": number, "AccumulatedInferenceDataStartTime": number, "ActiveModelVersion": number, "ActiveModelVersionArn": "string", "CreatedAt": number, "DataPreProcessingConfiguration": { "TargetSamplingRate": "string" }, "DatasetArn": "string", "DatasetName": "string", "EvaluationDataEndTime": number, "EvaluationDataStartTime": number, DescribeModel 242 Amazon Lookout for Equipment User Guide "FailedReason": "string", "ImportJobEndTime": number, "ImportJobStartTime": number, "LabelsInputConfiguration": { "LabelGroupName": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "LastUpdatedTime": number, "LatestScheduledRetrainingAvailableDataInDays": number, "LatestScheduledRetrainingFailedReason": "string", "LatestScheduledRetrainingModelVersion": number, "LatestScheduledRetrainingStartTime": number, "LatestScheduledRetrainingStatus": "string", "ModelArn": "string", "ModelDiagnosticsOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelMetrics": "string", "ModelName": "string", "ModelQuality": "string", "ModelVersionActivatedAt": number, "NextScheduledRetrainingStartDate": number, "OffCondition": "string", "PreviousActiveModelVersion": number, "PreviousActiveModelVersionArn": "string", "PreviousModelVersionActivatedAt": number, "PriorModelMetrics": "string", "RetrainingSchedulerStatus": "string", "RoleArn": "string", "Schema": "string", "ServerSideKmsKeyId": "string", "SourceModelVersionArn": "string", "Status": "string", "TrainingDataEndTime": number, "TrainingDataStartTime": number, "TrainingExecutionEndTime": number, "TrainingExecutionStartTime": number DescribeModel 243 User Guide Amazon Lookout for Equipment } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. AccumulatedInferenceDataEndTime Indicates the end time of the inference data that has been accumulated. Type: Timestamp AccumulatedInferenceDataStartTime Indicates the start time of the inference data that has been accumulated. Type: Timestamp ActiveModelVersion The name of the model version used by the inference schedular when running a scheduled inference execution. Type: Long Valid Range: Minimum value of 1. ActiveModelVersionArn The Amazon Resource Name (ARN) of the model version used by the inference scheduler when running a scheduled inference execution. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ CreatedAt Indicates the time and date at which the machine learning model was created. DescribeModel 244 Amazon Lookout for Equipment Type: Timestamp DataPreProcessingConfiguration User Guide The configuration is the TargetSamplingRate, which is the sampling rate of the data after post processing by Amazon Lookout for Equipment. For example, if you provide data that has been collected at a 1 second level and you want the system to resample the data at a 1 minute rate before training, the TargetSamplingRate is 1 minute. When providing a value for the TargetSamplingRate, you must attach the prefix "PT" to the rate you want. The value for a 1 second rate is therefore PT1S, the value for a 15 minute rate is PT15M, and the value for a 1 hour rate is PT1H Type: DataPreProcessingConfiguration object DatasetArn The Amazon Resouce Name (ARN) of the dataset used to create the machine learning model being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DatasetName The name of the dataset being used by the machine learning being described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ EvaluationDataEndTime Indicates the time reference in the dataset that was used to end the subset of evaluation data for the machine learning model. Type: Timestamp DescribeModel 245 Amazon Lookout for Equipment EvaluationDataStartTime User Guide Indicates the time reference in the dataset that was used to begin the subset of evaluation data for the machine learning model. Type: Timestamp FailedReason If the training of the machine learning model failed, this indicates the reason for that failure. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} ImportJobEndTime The date and time when the import job was completed. This field appears if the active model version was imported.
amazon-lookout-for-equipment-ug-068
amazon-lookout-for-equipment-ug.pdf
68
used to end the subset of evaluation data for the machine learning model. Type: Timestamp DescribeModel 245 Amazon Lookout for Equipment EvaluationDataStartTime User Guide Indicates the time reference in the dataset that was used to begin the subset of evaluation data for the machine learning model. Type: Timestamp FailedReason If the training of the machine learning model failed, this indicates the reason for that failure. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} ImportJobEndTime The date and time when the import job was completed. This field appears if the active model version was imported. Type: Timestamp ImportJobStartTime The date and time when the import job was started. This field appears if the active model version was imported. Type: Timestamp LabelsInputConfiguration Specifies configuration information about the labels input, including its S3 location. Type: LabelsInputConfiguration object LastUpdatedTime Indicates the last time the machine learning model was updated. The type of update is not specified. Type: Timestamp LatestScheduledRetrainingAvailableDataInDays Indicates the number of days of data used in the most recent scheduled retraining run. DescribeModel 246 Amazon Lookout for Equipment Type: Integer LatestScheduledRetrainingFailedReason User Guide If the model version was generated by retraining and the training failed, this indicates the reason for that failure. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} LatestScheduledRetrainingModelVersion Indicates the most recent model version that was generated by retraining. Type: Long Valid Range: Minimum value of 1. LatestScheduledRetrainingStartTime Indicates the start time of the most recent scheduled retraining run. Type: Timestamp LatestScheduledRetrainingStatus Indicates the status of the most recent scheduled retraining run. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED ModelArn The Amazon Resource Name (ARN) of the machine learning model being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ DescribeModel 247 Amazon Lookout for Equipment User Guide ModelDiagnosticsOutputConfiguration Configuration information for the model's pointwise model diagnostics. Type: ModelDiagnosticsOutputConfiguration object ModelMetrics The Model Metrics show an aggregated summary of the model's performance within the evaluation time range. This is the JSON content of the metrics created when evaluating the model. Type: String Length Constraints: Minimum length of 1. Maximum length of 50000. ModelName The name of the machine learning model being described. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ ModelQuality Provides a quality assessment for a model that uses labels. If Lookout for Equipment determines that the model quality is poor based on training metrics, the value is POOR_QUALITY_DETECTED. Otherwise, the value is QUALITY_THRESHOLD_MET. If the model is unlabeled, the model quality can't be assessed and the value of ModelQuality is CANNOT_DETERMINE_QUALITY. In this situation, you can get a model quality assessment by adding labels to the input dataset and retraining the model. For information about using labels with your models, see Understanding labeling. For information about improving the quality of a model, see Best practices with Amazon Lookout for Equipment. Type: String Valid Values: QUALITY_THRESHOLD_MET | CANNOT_DETERMINE_QUALITY | POOR_QUALITY_DETECTED DescribeModel 248 Amazon Lookout for Equipment ModelVersionActivatedAt The date the active model version was activated. Type: Timestamp NextScheduledRetrainingStartDate User Guide Indicates the date and time that the next scheduled retraining run will start on. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp OffCondition Indicates that the asset associated with this sensor has been shut off. As long as this condition is met, Lookout for Equipment will not use data from this asset for training, evaluation, or inference. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. PreviousActiveModelVersion The model version that was set as the active model version prior to the current active model version. Type: Long Valid Range: Minimum value of 1. PreviousActiveModelVersionArn The ARN of the model version that was set as the active model version prior to the current active model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ PreviousModelVersionActivatedAt The date and time when the previous active model version was activated. DescribeModel 249 Amazon Lookout for Equipment Type: Timestamp PriorModelMetrics User Guide If the model version was retrained, this field shows a summary of the performance of the prior model on the new training range. You can use the information in this JSON-formatted object to compare the new model version and the prior model version. Type: String Length Constraints: Minimum length of 1. Maximum length of 50000. RetrainingSchedulerStatus Indicates the status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source for the machine learning model being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Schema A
amazon-lookout-for-equipment-ug-069
amazon-lookout-for-equipment-ug.pdf
69
performance of the prior model on the new training range. You can use the information in this JSON-formatted object to compare the new model version and the prior model version. Type: String Length Constraints: Minimum length of 1. Maximum length of 50000. RetrainingSchedulerStatus Indicates the status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source for the machine learning model being described. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Schema A JSON description of the data that is in each time series dataset, including names, column names, and data types. Type: String Length Constraints: Minimum length of 1. Maximum length of 1000000. ServerSideKmsKeyId Provides the identifier of the AWS KMS key used to encrypt model data by Amazon Lookout for Equipment. Type: String DescribeModel 250 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 1. Maximum length of 1024. Pattern: arn:aws[a-z\-]*:kms:[a-z0-9\-]*:\d{12}:[\w\-\/]+ SourceModelVersionArn The Amazon Resource Name (ARN) of the source model version. This field appears if the active model version was imported. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Status Specifies the current status of the model being described. Status describes the status of the most recent action of the model. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS TrainingDataEndTime Indicates the time reference in the dataset that was used to end the subset of training data for the machine learning model. Type: Timestamp TrainingDataStartTime Indicates the time reference in the dataset that was used to begin the subset of training data for the machine learning model. Type: Timestamp TrainingExecutionEndTime Indicates the time at which the training of the machine learning model was completed. Type: Timestamp DescribeModel 251 Amazon Lookout for Equipment TrainingExecutionStartTime User Guide Indicates the time at which the training of the machine learning model began. Type: Timestamp Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: DescribeModel 252 User Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeModel 253 Amazon Lookout for Equipment DescribeModelVersion User Guide Retrieves information about a specific machine learning model version. Request Syntax { "ModelName": "string", "ModelVersion": number } Request Parameters The request accepts the following data in JSON format. ModelName The name of the machine learning model that this version belongs to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes ModelVersion The version of the machine learning model. Type: Long Valid Range: Minimum value of 1. Required: Yes Response Syntax { "AutoPromotionResult": "string", "AutoPromotionResultReason": "string", "CreatedAt": number, "DataPreProcessingConfiguration": { DescribeModelVersion 254 Amazon Lookout for Equipment User Guide "TargetSamplingRate": "string" }, "DatasetArn": "string", "DatasetName": "string", "EvaluationDataEndTime": number, "EvaluationDataStartTime": number, "FailedReason": "string", "ImportedDataSizeInBytes": number, "ImportJobEndTime": number, "ImportJobStartTime": number, "LabelsInputConfiguration": { "LabelGroupName": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "LastUpdatedTime": number, "ModelArn": "string", "ModelDiagnosticsOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelDiagnosticsResultsObject": { "Bucket": "string", "Key": "string" }, "ModelMetrics": "string", "ModelName": "string", "ModelQuality": "string", "ModelVersion": number, "ModelVersionArn": "string", "OffCondition": "string", "PriorModelMetrics": "string", "RetrainingAvailableDataInDays": number, "RoleArn": "string", "Schema": "string", "ServerSideKmsKeyId": "string", "SourceModelVersionArn": "string", "SourceType": "string", "Status": "string", DescribeModelVersion 255 Amazon Lookout for Equipment User Guide "TrainingDataEndTime": number, "TrainingDataStartTime": number, "TrainingExecutionEndTime": number, "TrainingExecutionStartTime": number } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. AutoPromotionResult Indicates whether the model version was promoted to be the active version after retraining or if there was an error with or cancellation of the retraining. Type: String Valid Values: MODEL_PROMOTED | MODEL_NOT_PROMOTED | RETRAINING_INTERNAL_ERROR | RETRAINING_CUSTOMER_ERROR | RETRAINING_CANCELLED AutoPromotionResultReason Indicates the reason for the AutoPromotionResult. For example, a model might not be promoted if its performance was worse
amazon-lookout-for-equipment-ug-070
amazon-lookout-for-equipment-ug.pdf
70
Lookout for Equipment User Guide "TrainingDataEndTime": number, "TrainingDataStartTime": number, "TrainingExecutionEndTime": number, "TrainingExecutionStartTime": number } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. AutoPromotionResult Indicates whether the model version was promoted to be the active version after retraining or if there was an error with or cancellation of the retraining. Type: String Valid Values: MODEL_PROMOTED | MODEL_NOT_PROMOTED | RETRAINING_INTERNAL_ERROR | RETRAINING_CUSTOMER_ERROR | RETRAINING_CANCELLED AutoPromotionResultReason Indicates the reason for the AutoPromotionResult. For example, a model might not be promoted if its performance was worse than the active version, if there was an error during training, or if the retraining scheduler was using MANUAL promote mode. The model will be promoted in MANAGED promote mode if the performance is better than the previous model. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. CreatedAt Indicates the time and date at which the machine learning model version was created. Type: Timestamp DataPreProcessingConfiguration The configuration is the TargetSamplingRate, which is the sampling rate of the data after post processing by Amazon Lookout for Equipment. For example, if you provide data that has DescribeModelVersion 256 Amazon Lookout for Equipment User Guide been collected at a 1 second level and you want the system to resample the data at a 1 minute rate before training, the TargetSamplingRate is 1 minute. When providing a value for the TargetSamplingRate, you must attach the prefix "PT" to the rate you want. The value for a 1 second rate is therefore PT1S, the value for a 15 minute rate is PT15M, and the value for a 1 hour rate is PT1H Type: DataPreProcessingConfiguration object DatasetArn The Amazon Resource Name (ARN) of the dataset used to train the model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DatasetName The name of the dataset used to train the model version. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ EvaluationDataEndTime The date on which the data in the evaluation set began being gathered. If you imported the version, this is the date that the evaluation set data in the source version finished being gathered. Type: Timestamp EvaluationDataStartTime The date on which the data in the evaluation set began being gathered. If you imported the version, this is the date that the evaluation set data in the source version began being gathered. Type: Timestamp DescribeModelVersion 257 Amazon Lookout for Equipment FailedReason User Guide The failure message if the training of the model version failed. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} ImportedDataSizeInBytes The size in bytes of the imported data. This field appears if the model version was imported. Type: Long Valid Range: Minimum value of 0. ImportJobEndTime The date and time when the import job completed. This field appears if the model version was imported. Type: Timestamp ImportJobStartTime The date and time when the import job began. This field appears if the model version was imported. Type: Timestamp LabelsInputConfiguration Contains the configuration information for the S3 location being used to hold label data. Type: LabelsInputConfiguration object LastUpdatedTime Indicates the last time the machine learning model version was updated. Type: Timestamp ModelArn The Amazon Resource Name (ARN) of the parent machine learning model that this version belong to. DescribeModelVersion 258 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelDiagnosticsOutputConfiguration The Amazon S3 location where Amazon Lookout for Equipment saves the pointwise model diagnostics for the model version. Type: ModelDiagnosticsOutputConfiguration object ModelDiagnosticsResultsObject Contains the Amazon S3 object path where Amazon Lookout for Equipment writes the model diagnostics results for the model version. The format is User_Provided_Prefix/ Model_Name/Model_Version/model_diagnostics_results.json.gz. User_Provided_Prefix is the prefix that you specify in the ModelDiagnosticsOutputConfiguration request parameter to the CreateModel or UpdateModel operations. Type: S3Object object ModelMetrics Shows an aggregated summary, in JSON format, of the model's performance within the evaluation time range. These metrics are created when evaluating the model. Type: String Length Constraints: Minimum length of 1. Maximum length of 50000. ModelName The name of the machine learning model that this version belongs to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ DescribeModelVersion 259 Amazon Lookout for Equipment ModelQuality User Guide Provides a quality assessment for a model that uses labels. If Lookout for Equipment determines that the model quality is poor based on training metrics, the value is POOR_QUALITY_DETECTED. Otherwise, the value is QUALITY_THRESHOLD_MET. If the model is unlabeled, the model quality can't be assessed and the value of ModelQuality is CANNOT_DETERMINE_QUALITY. In this situation, you can get a model quality assessment by adding labels to the input dataset and
amazon-lookout-for-equipment-ug-071
amazon-lookout-for-equipment-ug.pdf
71
learning model that this version belongs to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ DescribeModelVersion 259 Amazon Lookout for Equipment ModelQuality User Guide Provides a quality assessment for a model that uses labels. If Lookout for Equipment determines that the model quality is poor based on training metrics, the value is POOR_QUALITY_DETECTED. Otherwise, the value is QUALITY_THRESHOLD_MET. If the model is unlabeled, the model quality can't be assessed and the value of ModelQuality is CANNOT_DETERMINE_QUALITY. In this situation, you can get a model quality assessment by adding labels to the input dataset and retraining the model. For information about using labels with your models, see Understanding labeling. For information about improving the quality of a model, see Best practices with Amazon Lookout for Equipment. Type: String Valid Values: QUALITY_THRESHOLD_MET | CANNOT_DETERMINE_QUALITY | POOR_QUALITY_DETECTED ModelVersion The version of the machine learning model. Type: Long Valid Range: Minimum value of 1. ModelVersionArn The Amazon Resource Name (ARN) of the model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ OffCondition Indicates that the asset associated with this sensor has been shut off. As long as this condition is met, Lookout for Equipment will not use data from this asset for training, evaluation, or inference. DescribeModelVersion 260 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 2048. PriorModelMetrics If the model version was retrained, this field shows a summary of the performance of the prior model on the new training range. You can use the information in this JSON-formatted object to compare the new model version and the prior model version. Type: String Length Constraints: Minimum length of 1. Maximum length of 50000. RetrainingAvailableDataInDays Indicates the number of days of data used in the most recent scheduled retraining run. Type: Integer RoleArn The Amazon Resource Name (ARN) of the role that was used to train the model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Schema The schema of the data used to train the model version. Type: String Length Constraints: Minimum length of 1. Maximum length of 1000000. ServerSideKmsKeyId The identifier of the AWS KMS key key used to encrypt model version data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 1024. DescribeModelVersion 261 Amazon Lookout for Equipment User Guide Pattern: arn:aws[a-z\-]*:kms:[a-z0-9\-]*:\d{12}:[\w\-\/]+ SourceModelVersionArn If model version was imported, then this field is the arn of the source model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ SourceType Indicates whether this model version was created by training or by importing. Type: String Valid Values: TRAINING | RETRAINING | IMPORT Status The current status of the model version. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED TrainingDataEndTime The date on which the training data finished being gathered. If you imported the version, this is the date that the training data in the source version finished being gathered. Type: Timestamp TrainingDataStartTime The date on which the training data began being gathered. If you imported the version, this is the date that the training data in the source version began being gathered. Type: Timestamp TrainingExecutionEndTime The time when the training of the version completed. DescribeModelVersion 262 User Guide Amazon Lookout for Equipment Type: Timestamp TrainingExecutionStartTime The time when the training of the version began. Type: Timestamp Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: DescribeModelVersion 263 User Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeModelVersion 264 Amazon Lookout for Equipment User Guide DescribeResourcePolicy Provides the details of a resource policy attached to a resource. Request Syntax { "ResourceArn": "string" } Request Parameters The request accepts the following data in JSON format. ResourceArn The Amazon
amazon-lookout-for-equipment-ug-072
amazon-lookout-for-equipment-ug.pdf
72
Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeModelVersion 264 Amazon Lookout for Equipment User Guide DescribeResourcePolicy Provides the details of a resource policy attached to a resource. Request Syntax { "ResourceArn": "string" } Request Parameters The request accepts the following data in JSON format. ResourceArn The Amazon Resource Name (ARN) of the resource that is associated with the resource policy. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:.+ Required: Yes Response Syntax { "CreationTime": number, "LastModifiedTime": number, "PolicyRevisionId": "string", "ResourcePolicy": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. DescribeResourcePolicy 265 User Guide Amazon Lookout for Equipment CreationTime The time when the resource policy was created. Type: Timestamp LastModifiedTime The time when the resource policy was last modified. Type: Timestamp PolicyRevisionId A unique identifier for a revision of the resource policy. Type: String Length Constraints: Maximum length of 50. Pattern: [0-9A-Fa-f]+ ResourcePolicy The resource policy in a JSON-formatted string. Type: String Length Constraints: Minimum length of 1. Maximum length of 20000. Pattern: [\u0009\u000A\u000D\u0020-\u00FF]+ Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 DescribeResourcePolicy 266 Amazon Lookout for Equipment ResourceNotFoundException User Guide The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeResourcePolicy 267 Amazon Lookout for Equipment User Guide DescribeRetrainingScheduler Provides a description of the retraining scheduler, including information such as the model name and retraining parameters. Request Syntax { "ModelName": "string" } Request Parameters The request accepts the following data in JSON format. ModelName The name of the model that the retraining scheduler is attached to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "CreatedAt": number, "LookbackWindow": "string", "ModelArn": "string", "ModelName": "string", "PromoteMode": "string", "RetrainingFrequency": "string", "RetrainingStartDate": number, "Status": "string", "UpdatedAt": number } DescribeRetrainingScheduler 268 Amazon Lookout for Equipment Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CreatedAt Indicates the time and date at which the retraining scheduler was created. Type: Timestamp LookbackWindow The number of past days of data used for retraining. Type: String Pattern: ^P180D$|^P360D$|^P540D$|^P720D$ ModelArn The ARN of the model that the retraining scheduler is attached to. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the model that the retraining scheduler is attached to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ PromoteMode Indicates how the service uses new models. In MANAGED mode, new models are used for inference if they have better performance than the current model. In MANUAL mode, the new models are not used until they are manually activated. DescribeRetrainingScheduler 269 Amazon Lookout for Equipment Type: String Valid Values: MANAGED | MANUAL RetrainingFrequency User Guide The frequency at which the model retraining is set. This follows the ISO 8601 guidelines. Type: String Length Constraints: Minimum length of 1. Maximum length of 10. Pattern: ^P(\dY)?(\d{1,2}M)?(\d{1,3}D)?$ RetrainingStartDate The start date for the retraining scheduler. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED UpdatedAt Indicates the time and date at which the retraining scheduler was updated. Type: Timestamp Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the
amazon-lookout-for-equipment-ug-073
amazon-lookout-for-equipment-ug.pdf
73
follows the ISO 8601 guidelines. Type: String Length Constraints: Minimum length of 1. Maximum length of 10. Pattern: ^P(\dY)?(\d{1,2}M)?(\d{1,3}D)?$ RetrainingStartDate The start date for the retraining scheduler. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED UpdatedAt Indicates the time and date at which the retraining scheduler was updated. Type: Timestamp Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. DescribeRetrainingScheduler 270 Amazon Lookout for Equipment HTTP Status Code: 500 ResourceNotFoundException User Guide The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 DescribeRetrainingScheduler 271 User Guide Amazon Lookout for Equipment ImportDataset Imports a dataset. Request Syntax { "ClientToken": "string", "DatasetName": "string", "ServerSideKmsKeyId": "string", "SourceDatasetArn": "string", "Tags": [ { "Key": "string", "Value": "string" } ] } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes DatasetName The name of the machine learning dataset to be created. If the dataset already exists, Amazon Lookout for Equipment overwrites the existing dataset. If you don't specify this field, it is filled with the name of the source dataset. Type: String ImportDataset 272 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No ServerSideKmsKeyId Provides the identifier of the AWS KMS key key used to encrypt model data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No SourceDatasetArn The Amazon Resource Name (ARN) of the dataset to import. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ Required: Yes Tags Any tags associated with the dataset to be created. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. Required: No Response Syntax { ImportDataset 273 Amazon Lookout for Equipment User Guide "DatasetArn": "string", "DatasetName": "string", "JobId": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. DatasetArn The Amazon Resource Name (ARN) of the dataset that was imported. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ DatasetName The name of the created machine learning dataset. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ JobId A unique identifier for the job of importing the dataset. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Status The status of the ImportDataset operation. ImportDataset 274 Amazon Lookout for Equipment Type: String User Guide Valid Values: CREATED | INGESTION_IN_PROGRESS | ACTIVE | IMPORT_IN_PROGRESS Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. ImportDataset 275 Amazon Lookout for Equipment HTTP Status Code: 400 See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface
amazon-lookout-for-equipment-ug-074
amazon-lookout-for-equipment-ug.pdf
74
ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. ImportDataset 275 Amazon Lookout for Equipment HTTP Status Code: 400 See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ImportDataset 276 User Guide Amazon Lookout for Equipment ImportModelVersion Imports a model that has been trained successfully. Request Syntax { "ClientToken": "string", "DatasetName": "string", "InferenceDataImportStrategy": "string", "LabelsInputConfiguration": { "LabelGroupName": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelName": "string", "RoleArn": "string", "ServerSideKmsKeyId": "string", "SourceModelVersionArn": "string", "Tags": [ { "Key": "string", "Value": "string" } ] } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} ImportModelVersion 277 Amazon Lookout for Equipment Required: Yes DatasetName User Guide The name of the dataset for the machine learning model being imported. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes InferenceDataImportStrategy Indicates how to import the accumulated inference data when a model version is imported. The possible values are as follows: • NO_IMPORT – Don't import the data. • ADD_WHEN_EMPTY – Only import the data from the source model if there is no existing data in the target model. • OVERWRITE – Import the data from the source model and overwrite the existing data in the target model. Type: String Valid Values: NO_IMPORT | ADD_WHEN_EMPTY | OVERWRITE Required: No LabelsInputConfiguration Contains the configuration information for the S3 location being used to hold label data. Type: LabelsInputConfiguration object Required: No ModelName The name for the machine learning model to be created. If the model already exists, Amazon Lookout for Equipment creates a new version. If you do not specify this field, it is filled with the name of the source model. ImportModelVersion 278 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source being used to create the machine learning model. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Required: No ServerSideKmsKeyId Provides the identifier of the AWS KMS key key used to encrypt model data by Amazon Lookout for Equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No SourceModelVersionArn The Amazon Resource Name (ARN) of the model version to import. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Required: Yes ImportModelVersion 279 Amazon Lookout for Equipment Tags User Guide The tags associated with the machine learning model to be created. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. Required: No Response Syntax { "ModelArn": "string", "ModelName": "string", "ModelVersion": number, "ModelVersionArn": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ModelArn The Amazon Resource Name (ARN) of the model being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name for the machine learning model. Type: String ImportModelVersion 280 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ ModelVersion The version of the model being created. Type: Long Valid Range: Minimum value of 1. ModelVersionArn The Amazon Resource Name (ARN) of the model version being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Status The status of the ImportModelVersion operation. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP
amazon-lookout-for-equipment-ug-075
amazon-lookout-for-equipment-ug.pdf
75
the model being created. Type: Long Valid Range: Minimum value of 1. ModelVersionArn The Amazon Resource Name (ARN) of the model version being created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Status The status of the ImportModelVersion operation. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 ImportModelVersion 281 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 ImportModelVersion 282 Amazon Lookout for Equipment • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide ImportModelVersion 283 Amazon Lookout for Equipment ListDataIngestionJobs User Guide Provides a list of all data ingestion jobs, including dataset name and ARN, S3 location of the input data, status, and so on. Request Syntax { "DatasetName": "string", "MaxResults": number, "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. DatasetName The name of the dataset being used for the data ingestion job. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of data ingestion jobs to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of data ingestion jobs. ListDataIngestionJobs 284 User Guide Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Status Indicates the status of the data ingestion job. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS Required: No Response Syntax { "DataIngestionJobSummaries": [ { "DatasetArn": "string", "DatasetName": "string", "IngestionInputConfiguration": { "S3InputConfiguration": { "Bucket": "string", "KeyPattern": "string", "Prefix": "string" } }, "JobId": "string", "Status": "string" } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. ListDataIngestionJobs 285 Amazon Lookout for Equipment User Guide The following data is returned in JSON format by the service. DataIngestionJobSummaries Specifies information about the specific data ingestion job, including dataset name and status. Type: Array of DataIngestionJobSummary objects NextToken An opaque pagination token indicating where to continue the listing of data ingestion jobs. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 ListDataIngestionJobs 286 Amazon Lookout for Equipment See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListDataIngestionJobs 287 Amazon Lookout for Equipment ListDatasets User Guide Lists all datasets currently available in your account, filtering on the dataset name. Request Syntax { "DatasetNameBeginsWith": "string", "MaxResults": number, "NextToken": "string" } Request Parameters The request accepts the following data in JSON format. DatasetNameBeginsWith The beginning of the name of the datasets to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of datasets to list. Type: Integer Valid Range: Minimum
amazon-lookout-for-equipment-ug-076
amazon-lookout-for-equipment-ug.pdf
76
SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListDataIngestionJobs 287 Amazon Lookout for Equipment ListDatasets User Guide Lists all datasets currently available in your account, filtering on the dataset name. Request Syntax { "DatasetNameBeginsWith": "string", "MaxResults": number, "NextToken": "string" } Request Parameters The request accepts the following data in JSON format. DatasetNameBeginsWith The beginning of the name of the datasets to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of datasets to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of datasets. Type: String ListDatasets 288 Amazon Lookout for Equipment User Guide Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Response Syntax { "DatasetSummaries": [ { "CreatedAt": number, "DatasetArn": "string", "DatasetName": "string", "Status": "string" } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. DatasetSummaries Provides information about the specified dataset, including creation time, dataset ARN, and status. Type: Array of DatasetSummary objects NextToken An opaque pagination token indicating where to continue the listing of datasets. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} ListDatasets 289 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python ListDatasets 290 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide ListDatasets 291 Amazon Lookout for Equipment ListInferenceEvents User Guide Lists all inference events that have been found for the specified inference scheduler. Request Syntax { "InferenceSchedulerName": "string", "IntervalEndTime": number, "IntervalStartTime": number, "MaxResults": number, "NextToken": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerName The name of the inference scheduler for the inference events listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes IntervalEndTime Returns all the inference events with an end start time equal to or greater than less than the end time given. Type: Timestamp Required: Yes IntervalStartTime Lookout for Equipment will return all the inference events with an end time equal to or greater than the start time given. Type: Timestamp ListInferenceEvents 292 User Guide Amazon Lookout for Equipment Required: Yes MaxResults Specifies the maximum number of inference events to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of inference events. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Response Syntax { "InferenceEventSummaries": [ { "Diagnostics": "string", "EventDurationInSeconds": number, "EventEndTime": number, "EventStartTime": number, "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string" } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. ListInferenceEvents 293 Amazon Lookout for Equipment User Guide The following data is returned in JSON format by the service. InferenceEventSummaries Provides an array of information about the individual inference events returned from the ListInferenceEvents operation, including scheduler used, event start time, event end time, diagnostics, and so on. Type: Array of InferenceEventSummary objects NextToken An opaque pagination token indicating where to continue the listing of inference executions. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ListInferenceEvents 294 Amazon Lookout for Equipment ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized.
amazon-lookout-for-equipment-ug-077
amazon-lookout-for-equipment-ug.pdf
77
The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ListInferenceEvents 294 Amazon Lookout for Equipment ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListInferenceEvents 295 Amazon Lookout for Equipment User Guide ListInferenceExecutions Lists all inference executions that have been performed by the specified inference scheduler. Request Syntax { "DataEndTimeBefore": number, "DataStartTimeAfter": number, "InferenceSchedulerName": "string", "MaxResults": number, "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. DataEndTimeBefore The time reference in the inferenced dataset before which Amazon Lookout for Equipment stopped the inference execution. Type: Timestamp Required: No DataStartTimeAfter The time reference in the inferenced dataset after which Amazon Lookout for Equipment started the inference execution. Type: Timestamp Required: No InferenceSchedulerName The name of the inference scheduler for the inference execution listed. Type: String ListInferenceExecutions 296 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes MaxResults Specifies the maximum number of inference executions to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of inference executions. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Status The status of the inference execution. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED Required: No Response Syntax { "InferenceExecutionSummaries": [ ListInferenceExecutions 297 User Guide Amazon Lookout for Equipment { "CustomerResultObject": { "Bucket": "string", "Key": "string" }, "DataEndTime": number, "DataInputConfiguration": { "InferenceInputNameConfiguration": { "ComponentTimestampDelimiter": "string", "TimestampFormat": "string" }, "InputTimeZoneOffset": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataStartTime": number, "FailedReason": "string", "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string", "ModelArn": "string", "ModelName": "string", "ModelVersion": number, "ModelVersionArn": "string", "ScheduledStartTime": number, "Status": "string" } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ListInferenceExecutions 298 Amazon Lookout for Equipment InferenceExecutionSummaries User Guide Provides an array of information about the individual inference executions returned from the ListInferenceExecutions operation, including model used, inference scheduler, data configuration, and so on. Note If you don't supply the InferenceSchedulerName request parameter, or if you supply the name of an inference scheduler that doesn't exist, ListInferenceExecutions returns an empty array in InferenceExecutionSummaries. Type: Array of InferenceExecutionSummary objects NextToken An opaque pagination token indicating where to continue the listing of inference executions. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. ListInferenceExecutions 299 Amazon Lookout for Equipment HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListInferenceExecutions 300 Amazon Lookout for Equipment User Guide ListInferenceSchedulers Retrieves a list of all inference schedulers currently available for your account. Request Syntax { "InferenceSchedulerNameBeginsWith": "string", "MaxResults": number, "ModelName": "string", "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerNameBeginsWith The
amazon-lookout-for-equipment-ug-078
amazon-lookout-for-equipment-ug.pdf
78
Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListInferenceExecutions 300 Amazon Lookout for Equipment User Guide ListInferenceSchedulers Retrieves a list of all inference schedulers currently available for your account. Request Syntax { "InferenceSchedulerNameBeginsWith": "string", "MaxResults": number, "ModelName": "string", "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerNameBeginsWith The beginning of the name of the inference schedulers to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of inference schedulers to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No ModelName The name of the machine learning model used by the inference scheduler to be listed. ListInferenceSchedulers 301 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No NextToken An opaque pagination token indicating where to continue the listing of inference schedulers. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Status Specifies the current status of the inference schedulers. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Required: No Response Syntax { "InferenceSchedulerSummaries": [ { "DataDelayOffsetInMinutes": number, "DataUploadFrequency": "string", "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string", "LatestInferenceResult": "string", "ModelArn": "string", "ModelName": "string", "Status": "string" } ListInferenceSchedulers 302 Amazon Lookout for Equipment ], "NextToken": "string" } Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. InferenceSchedulerSummaries Provides information about the specified inference scheduler, including data upload frequency, model name and ARN, and status. Type: Array of InferenceSchedulerSummary objects NextToken An opaque pagination token indicating where to continue the listing of inference schedulers. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. ListInferenceSchedulers 303 Amazon Lookout for Equipment HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListInferenceSchedulers 304 User Guide Amazon Lookout for Equipment ListLabelGroups Returns a list of the label groups. Request Syntax { "LabelGroupNameBeginsWith": "string", "MaxResults": number, "NextToken": "string" } Request Parameters The request accepts the following data in JSON format. LabelGroupNameBeginsWith The beginning of the name of the label groups to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of label groups to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of label groups. Type: String ListLabelGroups 305 Amazon Lookout for Equipment User Guide Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Response Syntax { "LabelGroupSummaries": [ { "CreatedAt": number, "LabelGroupArn": "string", "LabelGroupName": "string", "UpdatedAt": number } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. LabelGroupSummaries A summary of the label groups. Type: Array of LabelGroupSummary objects NextToken An opaque pagination token indicating where to continue the listing of label groups. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} ListLabelGroups 306 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also
amazon-lookout-for-equipment-ug-079
amazon-lookout-for-equipment-ug.pdf
79
label groups. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} ListLabelGroups 306 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python ListLabelGroups 307 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide ListLabelGroups 308 User Guide Amazon Lookout for Equipment ListLabels Provides a list of labels. Request Syntax { "Equipment": "string", "FaultCode": "string", "IntervalEndTime": number, "IntervalStartTime": number, "LabelGroupName": "string", "MaxResults": number, "NextToken": "string" } Request Parameters The request accepts the following data in JSON format. Equipment Lists the labels that pertain to a particular piece of equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: [\P{M}\p{M}]{1,200} Required: No FaultCode Returns labels with a particular fault code. Type: String Length Constraints: Minimum length of 1. Maximum length of 100. Pattern: [\P{M}\p{M}]{1,100} Required: No ListLabels 309 Amazon Lookout for Equipment IntervalEndTime User Guide Returns all labels with a start time earlier than the end time given. Type: Timestamp Required: No IntervalStartTime Returns all the labels with a end time equal to or later than the start time given. Type: Timestamp Required: No LabelGroupName Returns the name of the label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes MaxResults Specifies the maximum number of labels to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of label groups. Type: String Length Constraints: Maximum length of 8192. ListLabels 310 Amazon Lookout for Equipment User Guide Pattern: \p{ASCII}{0,8192} Required: No Response Syntax { "LabelSummaries": [ { "CreatedAt": number, "EndTime": number, "Equipment": "string", "FaultCode": "string", "LabelGroupArn": "string", "LabelGroupName": "string", "LabelId": "string", "Rating": "string", "StartTime": number } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. LabelSummaries A summary of the items in the label group. Note If you don't supply the LabelGroupName request parameter, or if you supply the name of a label group that doesn't exist, ListLabels returns an empty array in LabelSummaries. Type: Array of LabelSummary objects ListLabels 311 Amazon Lookout for Equipment NextToken User Guide An opaque pagination token indicating where to continue the listing of datasets. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface ListLabels 312 User Guide Amazon Lookout for Equipment • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListLabels 313 Amazon Lookout for Equipment ListModels User Guide Generates a list of all models in the account, including model name and ARN, dataset, and status. Request Syntax { "DatasetNameBeginsWith": "string", "MaxResults": number, "ModelNameBeginsWith": "string", "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. DatasetNameBeginsWith The beginning of the name of the dataset of the machine learning models to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of machine learning models to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of
amazon-lookout-for-equipment-ug-080
amazon-lookout-for-equipment-ug.pdf
80
ListModels User Guide Generates a list of all models in the account, including model name and ARN, dataset, and status. Request Syntax { "DatasetNameBeginsWith": "string", "MaxResults": number, "ModelNameBeginsWith": "string", "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. DatasetNameBeginsWith The beginning of the name of the dataset of the machine learning models to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No MaxResults Specifies the maximum number of machine learning models to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No ModelNameBeginsWith The beginning of the name of the machine learning models being listed. ListModels 314 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No NextToken An opaque pagination token indicating where to continue the listing of machine learning models. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Status The status of the machine learning model. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS Required: No Response Syntax { "ModelSummaries": [ { "ActiveModelVersion": number, "ActiveModelVersionArn": "string", "CreatedAt": number, "DatasetArn": "string", "DatasetName": "string", "LatestScheduledRetrainingModelVersion": number, ListModels 315 Amazon Lookout for Equipment User Guide "LatestScheduledRetrainingStartTime": number, "LatestScheduledRetrainingStatus": "string", "ModelArn": "string", "ModelDiagnosticsOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelName": "string", "ModelQuality": "string", "NextScheduledRetrainingStartDate": number, "RetrainingSchedulerStatus": "string", "Status": "string" } ], "NextToken": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ModelSummaries Provides information on the specified model, including created time, model and dataset ARNs, and status. Type: Array of ModelSummary objects NextToken An opaque pagination token indicating where to continue the listing of machine learning models. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} ListModels 316 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python ListModels 317 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide ListModels 318 Amazon Lookout for Equipment ListModelVersions User Guide Generates a list of all model versions for a given model, including the model version, model version ARN, and status. To list a subset of versions, use the MaxModelVersion and MinModelVersion fields. Request Syntax { "CreatedAtEndTime": number, "CreatedAtStartTime": number, "MaxModelVersion": number, "MaxResults": number, "MinModelVersion": number, "ModelName": "string", "NextToken": "string", "SourceType": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. CreatedAtEndTime Filter results to return all the model versions created before this time. Type: Timestamp Required: No CreatedAtStartTime Filter results to return all the model versions created after this time. Type: Timestamp Required: No MaxModelVersion Specifies the highest version of the model to return in the list. ListModelVersions 319 User Guide Amazon Lookout for Equipment Type: Long Valid Range: Minimum value of 1. Required: No MaxResults Specifies the maximum number of machine learning model versions to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No MinModelVersion Specifies the lowest version of the model to return in the list. Type: Long Valid Range: Minimum value of 1. Required: No ModelName Then name of the machine learning model for which the model versions are to be listed. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes NextToken If the total number of results exceeds the limit that the response can display, the response returns an opaque pagination token indicating where to continue the listing of machine learning model versions. Use this token in the NextToken field in the request to list the next page of results. ListModelVersions 320 User Guide Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No SourceType Filter the results based on the way the model version was generated. Type: String Valid Values: TRAINING | RETRAINING | IMPORT
amazon-lookout-for-equipment-ug-081
amazon-lookout-for-equipment-ug.pdf
81
Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes NextToken If the total number of results exceeds the limit that the response can display, the response returns an opaque pagination token indicating where to continue the listing of machine learning model versions. Use this token in the NextToken field in the request to list the next page of results. ListModelVersions 320 User Guide Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No SourceType Filter the results based on the way the model version was generated. Type: String Valid Values: TRAINING | RETRAINING | IMPORT Required: No Status Filter the results based on the current status of the model version. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED Required: No Response Syntax { "ModelVersionSummaries": [ { "CreatedAt": number, "ModelArn": "string", "ModelName": "string", "ModelQuality": "string", "ModelVersion": number, "ModelVersionArn": "string", "SourceType": "string", "Status": "string" } ], ListModelVersions 321 Amazon Lookout for Equipment "NextToken": "string" } Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ModelVersionSummaries Provides information on the specified model version, including the created time, model and dataset ARNs, and status. Note If you don't supply the ModelName request parameter, or if you supply the name of a model that doesn't exist, ListModelVersions returns an empty array in ModelVersionSummaries. Type: Array of ModelVersionSummary objects NextToken If the total number of results exceeds the limit that the response can display, the response returns an opaque pagination token indicating where to continue the listing of machine learning model versions. Use this token in the NextToken field in the request to list the next page of results. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Errors AccessDeniedException The request could not be completed because you do not have access to the resource. ListModelVersions 322 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python ListModelVersions 323 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide ListModelVersions 324 Amazon Lookout for Equipment User Guide ListRetrainingSchedulers Lists all retraining schedulers in your account, filtering by model name prefix and status. Request Syntax { "MaxResults": number, "ModelNameBeginsWith": "string", "NextToken": "string", "Status": "string" } Request Parameters The request accepts the following data in JSON format. MaxResults Specifies the maximum number of retraining schedulers to list. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No ModelNameBeginsWith Specify this field to only list retraining schedulers whose machine learning models begin with the value you specify. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No NextToken If the number of results exceeds the maximum, a pagination token is returned. Use the token in the request to show the next page of retraining schedulers. ListRetrainingSchedulers 325 Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Status User Guide Specify this field to only list retraining schedulers whose status matches the value you specify. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Required: No Response Syntax { "NextToken": "string", "RetrainingSchedulerSummaries": [ { "LookbackWindow": "string", "ModelArn": "string", "ModelName": "string", "RetrainingFrequency": "string", "RetrainingStartDate": number, "Status": "string" } ] } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. NextToken If the number of results exceeds the maximum, this pagination token is returned. Use this token in the request to show the next page of retraining schedulers. ListRetrainingSchedulers 326 Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} RetrainingSchedulerSummaries User Guide Provides information on the specified retraining scheduler, including the model name, model ARN, status, and start date. Type: Array of RetrainingSchedulerSummary objects Errors AccessDeniedException The request could not be completed because you
amazon-lookout-for-equipment-ug-082
amazon-lookout-for-equipment-ug.pdf
82
is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. NextToken If the number of results exceeds the maximum, this pagination token is returned. Use this token in the request to show the next page of retraining schedulers. ListRetrainingSchedulers 326 Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} RetrainingSchedulerSummaries User Guide Provides information on the specified retraining scheduler, including the model name, model ARN, status, and start date. Type: Array of RetrainingSchedulerSummary objects Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: ListRetrainingSchedulers 327 User Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListRetrainingSchedulers 328 Amazon Lookout for Equipment ListSensorStatistics User Guide Lists statistics about the data collected for each of the sensors that have been successfully ingested in the particular dataset. Can also be used to retreive Sensor Statistics for a previous ingestion job. Request Syntax { "DatasetName": "string", "IngestionJobId": "string", "MaxResults": number, "NextToken": "string" } Request Parameters The request accepts the following data in JSON format. DatasetName The name of the dataset associated with the list of Sensor Statistics. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes IngestionJobId The ingestion job id associated with the list of Sensor Statistics. To get sensor statistics for a particular ingestion job id, both dataset name and ingestion job id must be submitted as inputs. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Required: No ListSensorStatistics 329 Amazon Lookout for Equipment MaxResults User Guide Specifies the maximum number of sensors for which to retrieve statistics. Type: Integer Valid Range: Minimum value of 1. Maximum value of 500. Required: No NextToken An opaque pagination token indicating where to continue the listing of sensor statistics. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} Required: No Response Syntax { "NextToken": "string", "SensorStatisticsSummaries": [ { "CategoricalValues": { "NumberOfCategory": number, "Status": "string" }, "ComponentName": "string", "DataEndTime": number, "DataExists": boolean, "DataStartTime": number, "DuplicateTimestamps": { "Count": number, "Percentage": number }, "InvalidDateEntries": { "Count": number, "Percentage": number }, "InvalidValues": { ListSensorStatistics 330 Amazon Lookout for Equipment User Guide "Count": number, "Percentage": number }, "LargeTimestampGaps": { "MaxTimestampGapInDays": number, "NumberOfLargeTimestampGaps": number, "Status": "string" }, "MissingValues": { "Count": number, "Percentage": number }, "MonotonicValues": { "Monotonicity": "string", "Status": "string" }, "MultipleOperatingModes": { "Status": "string" }, "SensorName": "string" } ] } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. NextToken An opaque pagination token indicating where to continue the listing of sensor statistics. Type: String Length Constraints: Maximum length of 8192. Pattern: \p{ASCII}{0,8192} SensorStatisticsSummaries Provides ingestion-based statistics regarding the specified sensor with respect to various validation types, such as whether data exists, the number and percentage of missing values, and the number and percentage of duplicate timestamps. ListSensorStatistics 331 Amazon Lookout for Equipment User Guide Type: Array of SensorStatisticsSummary objects Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ ListSensorStatistics 332 Amazon Lookout for Equipment • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 •
amazon-lookout-for-equipment-ug-083
amazon-lookout-for-equipment-ug.pdf
83
throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ ListSensorStatistics 332 Amazon Lookout for Equipment • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide ListSensorStatistics 333 Amazon Lookout for Equipment ListTagsForResource Lists all the tags for a specified resource, including key and value. User Guide Request Syntax { "ResourceArn": "string" } Request Parameters The request accepts the following data in JSON format. ResourceArn The Amazon Resource Name (ARN) of the resource (such as the dataset or model) that is the focus of the ListTagsForResource operation. Type: String Length Constraints: Minimum length of 1. Maximum length of 1011. Required: Yes Response Syntax { "Tags": [ { "Key": "string", "Value": "string" } ] } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. ListTagsForResource 334 Amazon Lookout for Equipment Tags Any tags associated with the resource. Type: Array of Tag objects User Guide Array Members: Minimum number of 0 items. Maximum number of 200 items. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: ListTagsForResource 335 User Guide Amazon Lookout for Equipment • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 ListTagsForResource 336 Amazon Lookout for Equipment PutResourcePolicy Creates a resource control policy for a given resource. User Guide Request Syntax { "ClientToken": "string", "PolicyRevisionId": "string", "ResourceArn": "string", "ResourcePolicy": "string" } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes PolicyRevisionId A unique identifier for a revision of the resource policy. Type: String Length Constraints: Maximum length of 50. Pattern: [0-9A-Fa-f]+ Required: No ResourceArn The Amazon Resource Name (ARN) of the resource for which the policy is being created. PutResourcePolicy 337 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:.+ Required: Yes ResourcePolicy The JSON-formatted resource policy to create. Type: String Length Constraints: Minimum length of 1. Maximum length of 20000. Pattern: [\u0009\u000A\u000D\u0020-\u00FF]+ Required: Yes Response Syntax { "PolicyRevisionId": "string", "ResourceArn": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. PolicyRevisionId A unique identifier for a revision of the resource policy. Type: String Length Constraints: Maximum length of 50. Pattern: [0-9A-Fa-f]+ PutResourcePolicy 338 Amazon Lookout for Equipment ResourceArn User Guide The Amazon Resource Name (ARN) of the resource for which the policy was created. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:.+ Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. PutResourcePolicy 339 Amazon
amazon-lookout-for-equipment-ug-084
amazon-lookout-for-equipment-ug.pdf
84
not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. PutResourcePolicy 339 Amazon Lookout for Equipment HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 PutResourcePolicy 340 Amazon Lookout for Equipment StartDataIngestionJob User Guide Starts a data ingestion job. Amazon Lookout for Equipment returns the job status. Request Syntax { "ClientToken": "string", "DatasetName": "string", "IngestionInputConfiguration": { "S3InputConfiguration": { "Bucket": "string", "KeyPattern": "string", "Prefix": "string" } }, "RoleArn": "string" } Request Parameters The request accepts the following data in JSON format. ClientToken A unique identifier for the request. If you do not set the client request token, Amazon Lookout for Equipment generates one. Type: String Length Constraints: Minimum length of 1. Maximum length of 256. Pattern: \p{ASCII}{1,256} Required: Yes DatasetName The name of the dataset being used by the data ingestion job. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. StartDataIngestionJob 341 Amazon Lookout for Equipment User Guide Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes IngestionInputConfiguration Specifies information for the input data for the data ingestion job, including dataset S3 location. Type: IngestionInputConfiguration object Required: Yes RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source for the data ingestion job. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Required: Yes Response Syntax { "JobId": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. JobId Indicates the job ID of the data ingestion job. StartDataIngestionJob 342 Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Status User Guide Indicates the status of the StartDataIngestionJob operation. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 StartDataIngestionJob 343 Amazon Lookout for Equipment ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException User Guide The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 StartDataIngestionJob 344 Amazon Lookout for Equipment User Guide StartInferenceScheduler Starts an inference scheduler. Request Syntax { "InferenceSchedulerName": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerName The name of the inference scheduler to be started. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string", "ModelArn": "string", "ModelName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. StartInferenceScheduler 345 Amazon Lookout for Equipment User Guide The following data is returned in JSON format by the service. InferenceSchedulerArn The Amazon Resource Name (ARN)
amazon-lookout-for-equipment-ug-085
amazon-lookout-for-equipment-ug.pdf
85
an inference scheduler. Request Syntax { "InferenceSchedulerName": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerName The name of the inference scheduler to be started. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string", "ModelArn": "string", "ModelName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. StartInferenceScheduler 345 Amazon Lookout for Equipment User Guide The following data is returned in JSON format by the service. InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference scheduler being started. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ InferenceSchedulerName The name of the inference scheduler being started. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ ModelArn The Amazon Resource Name (ARN) of the machine learning model being used by the inference scheduler. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the machine learning model being used by the inference scheduler. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ StartInferenceScheduler 346 Amazon Lookout for Equipment Status User Guide Indicates the status of the inference scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. StartInferenceScheduler 347 Amazon Lookout for Equipment HTTP Status Code: 400 See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 StartInferenceScheduler 348 Amazon Lookout for Equipment User Guide StartRetrainingScheduler Starts a retraining scheduler. Request Syntax { "ModelName": "string" } Request Parameters The request accepts the following data in JSON format. ModelName The name of the model whose retraining scheduler you want to start. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "ModelArn": "string", "ModelName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. StartRetrainingScheduler 349 Amazon Lookout for Equipment ModelArn User Guide The ARN of the model whose retraining scheduler is being started. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the model whose retraining scheduler is being started. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 StartRetrainingScheduler 350 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3
amazon-lookout-for-equipment-ug-086
amazon-lookout-for-equipment-ug.pdf
86
The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 StartRetrainingScheduler 351 Amazon Lookout for Equipment User Guide StartRetrainingScheduler 352 Amazon Lookout for Equipment User Guide StopInferenceScheduler Stops an inference scheduler. Request Syntax { "InferenceSchedulerName": "string" } Request Parameters The request accepts the following data in JSON format. InferenceSchedulerName The name of the inference scheduler to be stopped. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "InferenceSchedulerArn": "string", "InferenceSchedulerName": "string", "ModelArn": "string", "ModelName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. StopInferenceScheduler 353 Amazon Lookout for Equipment User Guide The following data is returned in JSON format by the service. InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference schedule being stopped. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ InferenceSchedulerName The name of the inference scheduler being stopped. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ ModelArn The Amazon Resource Name (ARN) of the machine learning model used by the inference scheduler being stopped. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the machine learning model used by the inference scheduler being stopped. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ StopInferenceScheduler 354 Amazon Lookout for Equipment Status User Guide Indicates the status of the inference scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. StopInferenceScheduler 355 Amazon Lookout for Equipment HTTP Status Code: 400 See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 StopInferenceScheduler 356 Amazon Lookout for Equipment User Guide StopRetrainingScheduler Stops a retraining scheduler. Request Syntax { "ModelName": "string" } Request Parameters The request accepts the following data in JSON format. ModelName The name of the model whose retraining scheduler you want to stop. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes Response Syntax { "ModelArn": "string", "ModelName": "string", "Status": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. StopRetrainingScheduler 357 Amazon Lookout for Equipment ModelArn User Guide The ARN of the model whose retraining scheduler is being stopped. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ ModelName The name of the model whose retraining scheduler is being stopped. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 StopRetrainingScheduler 358 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of
amazon-lookout-for-equipment-ug-087
amazon-lookout-for-equipment-ug.pdf
87
model whose retraining scheduler is being stopped. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 StopRetrainingScheduler 358 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 StopRetrainingScheduler 359 Amazon Lookout for Equipment User Guide StopRetrainingScheduler 360 Amazon Lookout for Equipment TagResource User Guide Associates a given tag to a resource in your account. A tag is a key-value pair which can be added to an Amazon Lookout for Equipment resource as metadata. Tags can be used for organizing your resources as well as helping you to search and filter by tag. Multiple tags can be added to a resource, either when you create it, or later. Up to 50 tags can be associated with each resource. Request Syntax { "ResourceArn": "string", "Tags": [ { "Key": "string", "Value": "string" } ] } Request Parameters The request accepts the following data in JSON format. ResourceArn The Amazon Resource Name (ARN) of the specific resource to which the tag should be associated. Type: String Length Constraints: Minimum length of 1. Maximum length of 1011. Required: Yes Tags The tag or tags to be associated with a specific resource. Both the tag key and value are specified. Type: Array of Tag objects Array Members: Minimum number of 0 items. Maximum number of 200 items. TagResource 361 Amazon Lookout for Equipment Required: Yes Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ServiceQuotaExceededException Resource limitations have been exceeded. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 TagResource 362 Amazon Lookout for Equipment See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 TagResource 363 Amazon Lookout for Equipment UntagResource User Guide Removes a specific tag from a given resource. The tag is specified by its key. Request Syntax { "ResourceArn": "string", "TagKeys": [ "string" ] } Request Parameters The request accepts the following data in JSON format. ResourceArn The Amazon Resource Name (ARN) of the resource to which the tag is currently associated. Type: String Length Constraints: Minimum length of 1. Maximum length of 1011. Required: Yes TagKeys Specifies the key of the tag to be removed from a specified resource. Type: Array of strings Array Members: Minimum number of 0 items. Maximum number of 200 items. Length Constraints: Minimum length of 1. Maximum length of 128. Pattern: ^(?!aws:)[a-zA-Z+-=._:/]+$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. UntagResource 364 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be
amazon-lookout-for-equipment-ug-088
amazon-lookout-for-equipment-ug.pdf
88
to which the tag is currently associated. Type: String Length Constraints: Minimum length of 1. Maximum length of 1011. Required: Yes TagKeys Specifies the key of the tag to be removed from a specified resource. Type: Array of strings Array Members: Minimum number of 0 items. Maximum number of 200 items. Length Constraints: Minimum length of 1. Maximum length of 128. Pattern: ^(?!aws:)[a-zA-Z+-=._:/]+$ Required: Yes Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. UntagResource 364 Amazon Lookout for Equipment Errors AccessDeniedException User Guide The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 UntagResource 365 Amazon Lookout for Equipment • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 User Guide UntagResource 366 Amazon Lookout for Equipment User Guide UpdateActiveModelVersion Sets the active model version for a given machine learning model. Request Syntax { "ModelName": "string", "ModelVersion": number } Request Parameters The request accepts the following data in JSON format. ModelName The name of the machine learning model for which the active model version is being set. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes ModelVersion The version of the machine learning model for which the active model version is being set. Type: Long Valid Range: Minimum value of 1. Required: Yes Response Syntax { "CurrentActiveVersion": number, "CurrentActiveVersionArn": "string", UpdateActiveModelVersion 367 Amazon Lookout for Equipment User Guide "ModelArn": "string", "ModelName": "string", "PreviousActiveVersion": number, "PreviousActiveVersionArn": "string" } Response Elements If the action is successful, the service sends back an HTTP 200 response. The following data is returned in JSON format by the service. CurrentActiveVersion The version that is currently active of the machine learning model for which the active model version was set. Type: Long Valid Range: Minimum value of 1. CurrentActiveVersionArn The Amazon Resource Name (ARN) of the machine learning model version that is the current active model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ ModelArn The Amazon Resource Name (ARN) of the machine learning model for which the active model version was set. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ UpdateActiveModelVersion 368 Amazon Lookout for Equipment ModelName User Guide The name of the machine learning model for which the active model version was set. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ PreviousActiveVersion The previous version that was active of the machine learning model for which the active model version was set. Type: Long Valid Range: Minimum value of 1. PreviousActiveVersionArn The Amazon Resource Name (ARN) of the machine learning model version that was the previous active model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. UpdateActiveModelVersion 369 Amazon Lookout for Equipment HTTP Status Code: 400 InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 •
amazon-lookout-for-equipment-ug-089
amazon-lookout-for-equipment-ug.pdf
89
ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python UpdateActiveModelVersion 370 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide UpdateActiveModelVersion 371 Amazon Lookout for Equipment User Guide UpdateInferenceScheduler Updates an inference scheduler. Request Syntax { "DataDelayOffsetInMinutes": number, "DataInputConfiguration": { "InferenceInputNameConfiguration": { "ComponentTimestampDelimiter": "string", "TimestampFormat": "string" }, "InputTimeZoneOffset": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "DataUploadFrequency": "string", "InferenceSchedulerName": "string", "RoleArn": "string" } Request Parameters The request accepts the following data in JSON format. DataDelayOffsetInMinutes A period of time (in minutes) by which inference on the data is delayed after the data starts. For instance, if you select an offset delay time of five minutes, inference will not begin on the data until the first data measurement after the five minute mark. For example, if five minutes is selected, the inference scheduler will wake up at the configured frequency with the additional five minute delay time to check the customer S3 bucket. The customer can upload data at the UpdateInferenceScheduler 372 Amazon Lookout for Equipment User Guide same frequency and they don't need to stop and restart the scheduler when uploading new data. Type: Long Valid Range: Minimum value of 0. Maximum value of 60. Required: No DataInputConfiguration Specifies information for the input data for the inference scheduler, including delimiter, format, and dataset location. Type: InferenceInputConfiguration object Required: No DataOutputConfiguration Specifies information for the output results from the inference scheduler, including the output S3 location. Type: InferenceOutputConfiguration object Required: No DataUploadFrequency How often data is uploaded to the source S3 bucket for the input data. The value chosen is the length of time between data uploads. For instance, if you select 5 minutes, Amazon Lookout for Equipment will upload the real-time data to the source bucket once every 5 minutes. This frequency also determines how often Amazon Lookout for Equipment starts a scheduled inference on your data. In this example, it starts once every 5 minutes. Type: String Valid Values: PT5M | PT10M | PT15M | PT30M | PT1H Required: No InferenceSchedulerName The name of the inference scheduler to be updated. UpdateInferenceScheduler 373 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes RoleArn The Amazon Resource Name (ARN) of a role with permission to access the data source for the inference scheduler. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Required: No Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 UpdateInferenceScheduler 374 Amazon Lookout for Equipment ResourceNotFoundException User Guide The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 UpdateInferenceScheduler 375 User Guide Amazon Lookout for Equipment UpdateLabelGroup Updates the label group. Request Syntax { "FaultCodes": [ "string" ], "LabelGroupName": "string" } Request Parameters The request accepts the following data in JSON format. FaultCodes Updates the code indicating the type of anomaly associated with the label. Data in this field will be retained
amazon-lookout-for-equipment-ug-090
amazon-lookout-for-equipment-ug.pdf
90
.NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 UpdateInferenceScheduler 375 User Guide Amazon Lookout for Equipment UpdateLabelGroup Updates the label group. Request Syntax { "FaultCodes": [ "string" ], "LabelGroupName": "string" } Request Parameters The request accepts the following data in JSON format. FaultCodes Updates the code indicating the type of anomaly associated with the label. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: Array of strings Array Members: Minimum number of 0 items. Maximum number of 50 items. Length Constraints: Minimum length of 1. Maximum length of 100. Pattern: [\P{M}\p{M}]{1,100} Required: No LabelGroupName The name of the label group to be updated. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ UpdateLabelGroup 376 Amazon Lookout for Equipment Required: Yes Response Elements User Guide If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 UpdateLabelGroup 377 Amazon Lookout for Equipment See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 UpdateLabelGroup 378 User Guide Amazon Lookout for Equipment UpdateModel Updates a model in the account. Request Syntax { "LabelsInputConfiguration": { "LabelGroupName": "string", "S3InputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelDiagnosticsOutputConfiguration": { "KmsKeyId": "string", "S3OutputConfiguration": { "Bucket": "string", "Prefix": "string" } }, "ModelName": "string", "RoleArn": "string" } Request Parameters The request accepts the following data in JSON format. LabelsInputConfiguration Contains the configuration information for the S3 location being used to hold label data. Type: LabelsInputConfiguration object Required: No ModelDiagnosticsOutputConfiguration The Amazon S3 location where you want Amazon Lookout for Equipment to save the pointwise model diagnostics for the model. You must also specify the RoleArn request parameter. Type: ModelDiagnosticsOutputConfiguration object UpdateModel 379 User Guide Amazon Lookout for Equipment Required: No ModelName The name of the model to update. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes RoleArn The ARN of the model to update. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:iam::[0-9]{12}:role/.+ Required: No Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. HTTP Status Code: 400 ConflictException The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 UpdateModel 380 Amazon Lookout for Equipment InternalServerException User Guide Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 UpdateModel 381 Amazon Lookout for Equipment User Guide UpdateModel 382
amazon-lookout-for-equipment-ug-091
amazon-lookout-for-equipment-ug.pdf
91
Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 UpdateModel 381 Amazon Lookout for Equipment User Guide UpdateModel 382 Amazon Lookout for Equipment User Guide UpdateRetrainingScheduler Updates a retraining scheduler. Request Syntax { "LookbackWindow": "string", "ModelName": "string", "PromoteMode": "string", "RetrainingFrequency": "string", "RetrainingStartDate": number } Request Parameters The request accepts the following data in JSON format. LookbackWindow The number of past days of data that will be used for retraining. Type: String Pattern: ^P180D$|^P360D$|^P540D$|^P720D$ Required: No ModelName The name of the model whose retraining scheduler you want to update. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: Yes PromoteMode Indicates how the service will use new models. In MANAGED mode, new models will automatically be used for inference if they have better performance than the current model. In MANUAL mode, the new models will not be used until they are manually activated. UpdateRetrainingScheduler 383 Amazon Lookout for Equipment Type: String Valid Values: MANAGED | MANUAL Required: No RetrainingFrequency User Guide This parameter uses the ISO 8601 standard to set the frequency at which you want retraining to occur in terms of Years, Months, and/or Days (note: other parameters like Time are not currently supported). The minimum value is 30 days (P30D) and the maximum value is 1 year (P1Y). For example, the following values are valid: • P3M15D – Every 3 months and 15 days • P2M – Every 2 months • P150D – Every 150 days Type: String Length Constraints: Minimum length of 1. Maximum length of 10. Pattern: ^P(\dY)?(\d{1,2}M)?(\d{1,3}D)?$ Required: No RetrainingStartDate The start date for the retraining scheduler. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp Required: No Response Elements If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body. Errors AccessDeniedException The request could not be completed because you do not have access to the resource. UpdateRetrainingScheduler 384 Amazon Lookout for Equipment HTTP Status Code: 400 ConflictException User Guide The request could not be completed due to a conflict with the current state of the target resource. HTTP Status Code: 400 InternalServerException Processing of the request has failed because of an unknown error, exception or failure. HTTP Status Code: 500 ResourceNotFoundException The resource requested could not be found. Verify the resource ID and retry your request. HTTP Status Code: 400 ThrottlingException The request was denied due to request throttling. HTTP Status Code: 400 ValidationException The input fails to satisfy constraints specified by Amazon Lookout for Equipment or a related AWS service that's being utilized. HTTP Status Code: 400 See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS Command Line Interface • AWS SDK for .NET • AWS SDK for C++ • AWS SDK for Go v2 • AWS SDK for Java V2 UpdateRetrainingScheduler 385 User Guide Amazon Lookout for Equipment • AWS SDK for JavaScript V3 • AWS SDK for Kotlin • AWS SDK for PHP V3 • AWS SDK for Python • AWS SDK for Ruby V3 Data Types The following data types are supported: • CategoricalValues • CountPercent • DataIngestionJobSummary • DataPreProcessingConfiguration • DataQualitySummary • DatasetSchema • DatasetSummary • DuplicateTimestamps • InferenceEventSummary • InferenceExecutionSummary • InferenceInputConfiguration • InferenceInputNameConfiguration • InferenceOutputConfiguration • InferenceS3InputConfiguration • InferenceS3OutputConfiguration • InferenceSchedulerSummary • IngestedFilesSummary • IngestionInputConfiguration • IngestionS3InputConfiguration • InsufficientSensorData • InvalidSensorData Data Types 386 User Guide Amazon Lookout for Equipment • LabelGroupSummary • LabelsInputConfiguration • LabelsS3InputConfiguration • LabelSummary • LargeTimestampGaps • MissingCompleteSensorData • MissingSensorData • ModelDiagnosticsOutputConfiguration • ModelDiagnosticsS3OutputConfiguration • ModelSummary • ModelVersionSummary • MonotonicValues • MultipleOperatingModes • RetrainingSchedulerSummary • S3Object • SensorStatisticsSummary • SensorsWithShortDateRange • Tag • UnsupportedTimestamps Data Types 387 Amazon Lookout for Equipment CategoricalValues Entity that comprises information on categorical values in data. User Guide Contents Status Indicates whether there is a potential data issue related to categorical values. Type: String Valid Values: POTENTIAL_ISSUE_DETECTED | NO_ISSUE_DETECTED Required: Yes NumberOfCategory Indicates the number of categories in the data. Type: Integer Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 CategoricalValues 388 Amazon Lookout for Equipment CountPercent Entity that comprises information of count and percentage. User
amazon-lookout-for-equipment-ug-092
amazon-lookout-for-equipment-ug.pdf
92
CategoricalValues Entity that comprises information on categorical values in data. User Guide Contents Status Indicates whether there is a potential data issue related to categorical values. Type: String Valid Values: POTENTIAL_ISSUE_DETECTED | NO_ISSUE_DETECTED Required: Yes NumberOfCategory Indicates the number of categories in the data. Type: Integer Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 CategoricalValues 388 Amazon Lookout for Equipment CountPercent Entity that comprises information of count and percentage. User Guide Contents Count Indicates the count of occurences of the given statistic. Type: Integer Required: Yes Percentage Indicates the percentage of occurances of the given statistic. Type: Float Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 CountPercent 389 Amazon Lookout for Equipment User Guide DataIngestionJobSummary Provides information about a specified data ingestion job, including dataset information, data ingestion configuration, and status. Contents DatasetArn The Amazon Resource Name (ARN) of the dataset used in the data ingestion job. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ Required: No DatasetName The name of the dataset used for the data ingestion job. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No IngestionInputConfiguration Specifies information for the input data for the data inference job, including data Amazon S3 location parameters. Type: IngestionInputConfiguration object Required: No JobId Indicates the job ID of the data ingestion job. DataIngestionJobSummary 390 User Guide Amazon Lookout for Equipment Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Required: No Status Indicates the status of the data ingestion job. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 DataIngestionJobSummary 391 Amazon Lookout for Equipment User Guide DataPreProcessingConfiguration The configuration is the TargetSamplingRate, which is the sampling rate of the data after post processing by Amazon Lookout for Equipment. For example, if you provide data that has been collected at a 1 second level and you want the system to resample the data at a 1 minute rate before training, the TargetSamplingRate is 1 minute. When providing a value for the TargetSamplingRate, you must attach the prefix "PT" to the rate you want. The value for a 1 second rate is therefore PT1S, the value for a 15 minute rate is PT15M, and the value for a 1 hour rate is PT1H Contents TargetSamplingRate The sampling rate of the data after post processing by Amazon Lookout for Equipment. For example, if you provide data that has been collected at a 1 second level and you want the system to resample the data at a 1 minute rate before training, the TargetSamplingRate is 1 minute. When providing a value for the TargetSamplingRate, you must attach the prefix "PT" to the rate you want. The value for a 1 second rate is therefore PT1S, the value for a 15 minute rate is PT15M, and the value for a 1 hour rate is PT1H Type: String Valid Values: PT1S | PT5S | PT10S | PT15S | PT30S | PT1M | PT5M | PT10M | PT15M | PT30M | PT1H Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 DataPreProcessingConfiguration 392 Amazon Lookout for Equipment User Guide DataPreProcessingConfiguration 393 Amazon Lookout for Equipment DataQualitySummary User Guide DataQualitySummary gives aggregated statistics over all the sensors about a completed ingestion job. It primarily gives more information about statistics over different incorrect data like MissingCompleteSensorData, MissingSensorData, UnsupportedDateFormats, InsufficientSensorData, DuplicateTimeStamps. Contents DuplicateTimestamps Parameter that gives information about duplicate timestamps in the input data. Type: DuplicateTimestamps object Required: Yes InsufficientSensorData Parameter that gives information about insufficient data for sensors in the dataset. This includes information about those sensors that have complete data missing and those with a short date range. Type: InsufficientSensorData object Required: Yes InvalidSensorData Parameter that gives information about data that is invalid over all the sensors in the input data. Type: InvalidSensorData object Required: Yes MissingSensorData Parameter that gives information about data that is missing over all the sensors in the input data. Type: MissingSensorData object Required: Yes DataQualitySummary 394 Amazon Lookout for Equipment UnsupportedTimestamps User Guide Parameter that gives information about unsupported
amazon-lookout-for-equipment-ug-093
amazon-lookout-for-equipment-ug.pdf
93
object Required: Yes InsufficientSensorData Parameter that gives information about insufficient data for sensors in the dataset. This includes information about those sensors that have complete data missing and those with a short date range. Type: InsufficientSensorData object Required: Yes InvalidSensorData Parameter that gives information about data that is invalid over all the sensors in the input data. Type: InvalidSensorData object Required: Yes MissingSensorData Parameter that gives information about data that is missing over all the sensors in the input data. Type: MissingSensorData object Required: Yes DataQualitySummary 394 Amazon Lookout for Equipment UnsupportedTimestamps User Guide Parameter that gives information about unsupported timestamps in the input data. Type: UnsupportedTimestamps object Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 DataQualitySummary 395 Amazon Lookout for Equipment DatasetSchema User Guide Provides information about the data schema used with the given dataset. Contents InlineDataSchema The data schema used within the given dataset. Type: String Length Constraints: Minimum length of 1. Maximum length of 1000000. Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 DatasetSchema 396 Amazon Lookout for Equipment DatasetSummary User Guide Contains information about the specific data set, including name, ARN, and status. Contents CreatedAt The time at which the dataset was created in Amazon Lookout for Equipment. Type: Timestamp Required: No DatasetArn The Amazon Resource Name (ARN) of the specified dataset. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ Required: No DatasetName The name of the dataset. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No Status Indicates the status of the dataset. Type: String DatasetSummary 397 Amazon Lookout for Equipment User Guide Valid Values: CREATED | INGESTION_IN_PROGRESS | ACTIVE | IMPORT_IN_PROGRESS Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 DatasetSummary 398 Amazon Lookout for Equipment DuplicateTimestamps User Guide Entity that comprises information abount duplicate timestamps in the dataset. Contents TotalNumberOfDuplicateTimestamps Indicates the total number of duplicate timestamps. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 DuplicateTimestamps 399 Amazon Lookout for Equipment User Guide InferenceEventSummary Contains information about the specific inference event, including start and end time, diagnostics information, event duration and so on. Contents Diagnostics An array which specifies the names and values of all sensors contributing to an inference event. Type: String Length Constraints: Minimum length of 1. Maximum length of 50000. Required: No EventDurationInSeconds Indicates the size of an inference event in seconds. Type: Long Valid Range: Minimum value of 0. Required: No EventEndTime Indicates the ending time of an inference event. Type: Timestamp Required: No EventStartTime Indicates the starting time of an inference event. Type: Timestamp Required: No InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference scheduler being used for the inference event. InferenceEventSummary 400 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ Required: No InferenceSchedulerName The name of the inference scheduler being used for the inference events. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceEventSummary 401 Amazon Lookout for Equipment User Guide InferenceExecutionSummary Contains information about the specific inference execution, including input and output data configuration, inference scheduling information, status, and so on. Contents CustomerResultObject The S3 object that the inference execution results were uploaded to. Type: S3Object object Required: No DataEndTime Indicates the time reference in the dataset at which the inference execution stopped. Type: Timestamp Required: No DataInputConfiguration Specifies configuration information for the input data for the inference scheduler, including delimiter, format, and dataset location. Type: InferenceInputConfiguration object Required: No DataOutputConfiguration Specifies configuration information for the output results from for the inference execution, including the output Amazon S3 location. Type: InferenceOutputConfiguration object Required: No DataStartTime Indicates the time reference in the dataset at which the inference execution began. Type: Timestamp InferenceExecutionSummary 402 User Guide Amazon Lookout for Equipment Required: No FailedReason Specifies the
amazon-lookout-for-equipment-ug-094
amazon-lookout-for-equipment-ug.pdf
94
to. Type: S3Object object Required: No DataEndTime Indicates the time reference in the dataset at which the inference execution stopped. Type: Timestamp Required: No DataInputConfiguration Specifies configuration information for the input data for the inference scheduler, including delimiter, format, and dataset location. Type: InferenceInputConfiguration object Required: No DataOutputConfiguration Specifies configuration information for the output results from for the inference execution, including the output Amazon S3 location. Type: InferenceOutputConfiguration object Required: No DataStartTime Indicates the time reference in the dataset at which the inference execution began. Type: Timestamp InferenceExecutionSummary 402 User Guide Amazon Lookout for Equipment Required: No FailedReason Specifies the reason for failure when an inference execution has failed. Type: String Length Constraints: Minimum length of 1. Maximum length of 5000. Pattern: [\P{M}\p{M}]{1,5000} Required: No InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference scheduler being used for the inference execution. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ Required: No InferenceSchedulerName The name of the inference scheduler being used for the inference execution. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No ModelArn The Amazon Resource Name (ARN) of the machine learning model used for the inference execution. Type: String InferenceExecutionSummary 403 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Required: No ModelName The name of the machine learning model being used for the inference execution. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No ModelVersion The model version used for the inference execution. Type: Long Valid Range: Minimum value of 1. Required: No ModelVersionArn The Amazon Resource Number (ARN) of the model version used for the inference execution. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Required: No ScheduledStartTime Indicates the start time at which the inference scheduler began the specific inference execution. InferenceExecutionSummary 404 User Guide Amazon Lookout for Equipment Type: Timestamp Required: No Status Indicates the status of the inference execution. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceExecutionSummary 405 Amazon Lookout for Equipment User Guide InferenceInputConfiguration Specifies configuration information for the input data for the inference, including Amazon S3 location of input data.. Contents InferenceInputNameConfiguration Specifies configuration information for the input data for the inference, including timestamp format and delimiter. Type: InferenceInputNameConfiguration object Required: No InputTimeZoneOffset Indicates the difference between your time zone and Coordinated Universal Time (UTC). Type: String Pattern: ^(\+|\-)[0-9]{2}\:[0-9]{2}$ Required: No S3InputConfiguration Specifies configuration information for the input data for the inference, including Amazon S3 location of input data. Type: InferenceS3InputConfiguration object Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 InferenceInputConfiguration 406 Amazon Lookout for Equipment • AWS SDK for Ruby V3 User Guide InferenceInputConfiguration 407 Amazon Lookout for Equipment User Guide InferenceInputNameConfiguration Specifies configuration information for the input data for the inference, including timestamp format and delimiter. Contents ComponentTimestampDelimiter Indicates the delimiter character used between items in the data. Type: String Length Constraints: Minimum length of 0. Maximum length of 1. Pattern: ^(\-|\_|\s)?$ Required: No TimestampFormat The format of the timestamp, whether Epoch time, or standard, with or without hyphens (-). Type: String Pattern: ^EPOCH|yyyy-MM-dd-HH-mm-ss|yyyyMMddHHmmss$ Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceInputNameConfiguration 408 Amazon Lookout for Equipment User Guide InferenceOutputConfiguration Specifies configuration information for the output results from for the inference, including KMS key ID and output S3 location. Contents S3OutputConfiguration Specifies configuration information for the output results from for the inference, output S3 location. Type: InferenceS3OutputConfiguration object Required: Yes KmsKeyId The ID number for the AWS KMS key key used to encrypt the inference output. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceOutputConfiguration 409 Amazon Lookout for Equipment User Guide InferenceS3InputConfiguration Specifies configuration information for the input data for the inference, including input data S3 location. Contents Bucket The bucket containing the input dataset for the inference. Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern:
amazon-lookout-for-equipment-ug-095
amazon-lookout-for-equipment-ug.pdf
95
Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceOutputConfiguration 409 Amazon Lookout for Equipment User Guide InferenceS3InputConfiguration Specifies configuration information for the input data for the inference, including input data S3 location. Contents Bucket The bucket containing the input dataset for the inference. Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern: ^[a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]$ Required: Yes Prefix The prefix for the S3 bucket used for the input data for the inference. Type: String Length Constraints: Minimum length of 0. Maximum length of 1024. Pattern: (^$)|([\u0009\u000A\u000D\u0020-\u00FF]{1,1023}/$) Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceS3InputConfiguration 410 Amazon Lookout for Equipment User Guide InferenceS3OutputConfiguration Specifies configuration information for the output results from the inference, including output S3 location. Contents Bucket The bucket containing the output results from the inference Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern: ^[a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]$ Required: Yes Prefix The prefix for the S3 bucket used for the output results from the inference. Type: String Length Constraints: Minimum length of 0. Maximum length of 1024. Pattern: (^$)|([\u0009\u000A\u000D\u0020-\u00FF]{1,1023}/$) Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceS3OutputConfiguration 411 Amazon Lookout for Equipment User Guide InferenceSchedulerSummary Contains information about the specific inference scheduler, including data delay offset, model name and ARN, status, and so on. Contents DataDelayOffsetInMinutes A period of time (in minutes) by which inference on the data is delayed after the data starts. For instance, if an offset delay time of five minutes was selected, inference will not begin on the data until the first data measurement after the five minute mark. For example, if five minutes is selected, the inference scheduler will wake up at the configured frequency with the additional five minute delay time to check the customer S3 bucket. The customer can upload data at the same frequency and they don't need to stop and restart the scheduler when uploading new data. Type: Long Valid Range: Minimum value of 0. Maximum value of 60. Required: No DataUploadFrequency How often data is uploaded to the source S3 bucket for the input data. This value is the length of time between data uploads. For instance, if you select 5 minutes, Amazon Lookout for Equipment will upload the real-time data to the source bucket once every 5 minutes. This frequency also determines how often Amazon Lookout for Equipment starts a scheduled inference on your data. In this example, it starts once every 5 minutes. Type: String Valid Values: PT5M | PT10M | PT15M | PT30M | PT1H Required: No InferenceSchedulerArn The Amazon Resource Name (ARN) of the inference scheduler. Type: String InferenceSchedulerSummary 412 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9] {12}:inference-scheduler\/.+ Required: No InferenceSchedulerName The name of the inference scheduler. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No LatestInferenceResult Indicates whether the latest execution for the inference scheduler was Anomalous (anomalous events found) or Normal (no anomalous events found). Type: String Valid Values: ANOMALOUS | NORMAL Required: No ModelArn The Amazon Resource Name (ARN) of the machine learning model used by the inference scheduler. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Required: No ModelName The name of the machine learning model used for the inference scheduler. InferenceSchedulerSummary 413 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No Status Indicates the status of the inference scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceSchedulerSummary 414 Amazon Lookout for Equipment IngestedFilesSummary User Guide Gives statistics about how many files have been ingested, and which files have not been ingested, for a particular ingestion job. Contents IngestedNumberOfFiles Indicates the number of files that were successfully ingested. Type: Integer Required: Yes TotalNumberOfFiles Indicates the total number of files that were submitted for ingestion. Type: Integer Required: Yes DiscardedFiles Indicates the
amazon-lookout-for-equipment-ug-096
amazon-lookout-for-equipment-ug.pdf
96
See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InferenceSchedulerSummary 414 Amazon Lookout for Equipment IngestedFilesSummary User Guide Gives statistics about how many files have been ingested, and which files have not been ingested, for a particular ingestion job. Contents IngestedNumberOfFiles Indicates the number of files that were successfully ingested. Type: Integer Required: Yes TotalNumberOfFiles Indicates the total number of files that were submitted for ingestion. Type: Integer Required: Yes DiscardedFiles Indicates the number of files that were discarded. A file could be discarded because its format is invalid (for example, a jpg or pdf) or not readable. Type: Array of S3Object objects Array Members: Minimum number of 0 items. Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 IngestedFilesSummary 415 Amazon Lookout for Equipment User Guide IngestedFilesSummary 416 Amazon Lookout for Equipment User Guide IngestionInputConfiguration Specifies configuration information for the input data for the data ingestion job, including input data S3 location. Contents S3InputConfiguration The location information for the S3 bucket used for input data for the data ingestion. Type: IngestionS3InputConfiguration object Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 IngestionInputConfiguration 417 Amazon Lookout for Equipment User Guide IngestionS3InputConfiguration Specifies S3 configuration information for the input data for the data ingestion job. Contents Bucket The name of the S3 bucket used for the input data for the data ingestion. Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern: ^[a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]$ Required: Yes KeyPattern The pattern for matching the Amazon S3 files that will be used for ingestion. If the schema was created previously without any KeyPattern, then the default KeyPattern {prefix}/ {component_name}/* is used to download files from Amazon S3 according to the schema. This field is required when ingestion is being done for the first time. Valid Values: {prefix}/{component_name}_* | {prefix}/{component_name}/* | {prefix}/ {component_name}[DELIMITER]* (Allowed delimiters : space, dot, underscore, hyphen) Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Required: No Prefix The prefix for the S3 location being used for the input data for the data ingestion. Type: String Length Constraints: Minimum length of 0. Maximum length of 1024. Pattern: (^$)|([\u0009\u000A\u000D\u0020-\u00FF]{1,1023}/$) IngestionS3InputConfiguration 418 Amazon Lookout for Equipment Required: No See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 IngestionS3InputConfiguration 419 Amazon Lookout for Equipment InsufficientSensorData User Guide Entity that comprises aggregated information on sensors having insufficient data. Contents MissingCompleteSensorData Parameter that describes the total number of sensors that have data completely missing for it. Type: MissingCompleteSensorData object Required: Yes SensorsWithShortDateRange Parameter that describes the total number of sensors that have a short date range of less than 14 days of data overall. Type: SensorsWithShortDateRange object Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InsufficientSensorData 420 Amazon Lookout for Equipment InvalidSensorData User Guide Entity that comprises aggregated information on sensors having insufficient data. Contents AffectedSensorCount Indicates the number of sensors that have at least some invalid values. Type: Integer Required: Yes TotalNumberOfInvalidValues Indicates the total number of invalid values across all the sensors. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 InvalidSensorData 421 User Guide Amazon Lookout for Equipment LabelGroupSummary Contains information about the label group. Contents CreatedAt The time at which the label group was created. Type: Timestamp Required: No LabelGroupArn The Amazon Resource Name (ARN) of the label group. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:label- group\/.+ Required: No LabelGroupName The name of the label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No UpdatedAt The time at which the label group was updated. Type: Timestamp LabelGroupSummary 422 Amazon Lookout for Equipment Required: No See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS
amazon-lookout-for-equipment-ug-097
amazon-lookout-for-equipment-ug.pdf
97
group was created. Type: Timestamp Required: No LabelGroupArn The Amazon Resource Name (ARN) of the label group. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:label- group\/.+ Required: No LabelGroupName The name of the label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No UpdatedAt The time at which the label group was updated. Type: Timestamp LabelGroupSummary 422 Amazon Lookout for Equipment Required: No See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 LabelGroupSummary 423 Amazon Lookout for Equipment User Guide LabelsInputConfiguration Contains the configuration information for the S3 location being used to hold label data. Contents LabelGroupName The name of the label group to be used for label data. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No S3InputConfiguration Contains location information for the S3 location being used for label data. Type: LabelsS3InputConfiguration object Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 LabelsInputConfiguration 424 Amazon Lookout for Equipment User Guide LabelsS3InputConfiguration The location information (prefix and bucket name) for the s3 location being used for label data. Contents Bucket The name of the S3 bucket holding the label data. Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern: ^[a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]$ Required: Yes Prefix The prefix for the S3 bucket used for the label data. Type: String Length Constraints: Minimum length of 0. Maximum length of 1024. Pattern: (^$)|([\u0009\u000A\u000D\u0020-\u00FF]{1,1023}/$) Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 LabelsS3InputConfiguration 425 User Guide Amazon Lookout for Equipment LabelSummary Information about the label. Contents CreatedAt The time at which the label was created. Type: Timestamp Required: No EndTime The timestamp indicating the end of the label. Type: Timestamp Required: No Equipment Indicates that a label pertains to a particular piece of equipment. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: [\P{M}\p{M}]{1,200} Required: No FaultCode Indicates the type of anomaly associated with the label. Data in this field will be retained for service usage. Follow best practices for the security of your data. Type: String Length Constraints: Minimum length of 1. Maximum length of 100. LabelSummary 426 Amazon Lookout for Equipment User Guide Pattern: [\P{M}\p{M}]{1,100} Required: No LabelGroupArn The Amazon Resource Name (ARN) of the label group. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:label- group\/.+ Required: No LabelGroupName The name of the label group. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No LabelId The ID of the label. Type: String Length Constraints: Maximum length of 32. Pattern: [A-Fa-f0-9]{0,32} Required: No Rating Indicates whether a labeled event represents an anomaly. Type: String LabelSummary 427 Amazon Lookout for Equipment User Guide Valid Values: ANOMALY | NO_ANOMALY | NEUTRAL Required: No StartTime The timestamp indicating the start of the label. Type: Timestamp Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 LabelSummary 428 Amazon Lookout for Equipment LargeTimestampGaps User Guide Entity that comprises information on large gaps between consecutive timestamps in data. Contents Status Indicates whether there is a potential data issue related to large gaps in timestamps. Type: String Valid Values: POTENTIAL_ISSUE_DETECTED | NO_ISSUE_DETECTED Required: Yes MaxTimestampGapInDays Indicates the size of the largest timestamp gap, in days. Type: Integer Required: No NumberOfLargeTimestampGaps Indicates the number of large timestamp gaps, if there are any. Type: Integer Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 LargeTimestampGaps 429 Amazon Lookout for Equipment User Guide MissingCompleteSensorData Entity that comprises information on sensors that have sensor data completely missing. Contents AffectedSensorCount Indicates the number of sensors that have data missing completely. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 MissingCompleteSensorData 430 Amazon Lookout for Equipment MissingSensorData User Guide
amazon-lookout-for-equipment-ug-098
amazon-lookout-for-equipment-ug.pdf
98
following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 LargeTimestampGaps 429 Amazon Lookout for Equipment User Guide MissingCompleteSensorData Entity that comprises information on sensors that have sensor data completely missing. Contents AffectedSensorCount Indicates the number of sensors that have data missing completely. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 MissingCompleteSensorData 430 Amazon Lookout for Equipment MissingSensorData User Guide Entity that comprises aggregated information on sensors having missing data. Contents AffectedSensorCount Indicates the number of sensors that have atleast some data missing. Type: Integer Required: Yes TotalNumberOfMissingValues Indicates the total number of missing values across all the sensors. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 MissingSensorData 431 Amazon Lookout for Equipment User Guide ModelDiagnosticsOutputConfiguration Output configuration information for the pointwise model diagnostics for an Amazon Lookout for Equipment model. Contents S3OutputConfiguration The Amazon S3 location for the pointwise model diagnostics. Type: ModelDiagnosticsS3OutputConfiguration object Required: Yes KmsKeyId The AWS Key Management Service (KMS) key identifier to encrypt the pointwise model diagnostics files. Type: String Length Constraints: Minimum length of 1. Maximum length of 2048. Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$ Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 ModelDiagnosticsOutputConfiguration 432 Amazon Lookout for Equipment User Guide ModelDiagnosticsS3OutputConfiguration The Amazon S3 location for the pointwise model diagnostics for an Amazon Lookout for Equipment model. Contents Bucket The name of the Amazon S3 bucket where the pointwise model diagnostics are located. You must be the owner of the Amazon S3 bucket. Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern: ^[a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]$ Required: Yes Prefix The Amazon S3 prefix for the location of the pointwise model diagnostics. The prefix specifies the folder and evaluation result file name. (bucket). When you call CreateModel or UpdateModel, specify the path within the bucket that you want Lookout for Equipment to save the model to. During training, Lookout for Equipment creates the model evaluation model as a compressed JSON file with the name model_diagnostics_results.json.gz. When you call DescribeModel or DescribeModelVersion, prefix contains the file path and filename of the model evaluation file. Type: String Length Constraints: Minimum length of 0. Maximum length of 1024. Pattern: (^$)|([\u0009\u000A\u000D\u0020-\u00FF]{1,1023}/$) Required: No ModelDiagnosticsS3OutputConfiguration 433 Amazon Lookout for Equipment See Also User Guide For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 ModelDiagnosticsS3OutputConfiguration 434 Amazon Lookout for Equipment ModelSummary User Guide Provides information about the specified machine learning model, including dataset and model names and ARNs, as well as status. Contents ActiveModelVersion The model version that the inference scheduler uses to run an inference execution. Type: Long Valid Range: Minimum value of 1. Required: No ActiveModelVersionArn The Amazon Resource Name (ARN) of the model version that is set as active. The active model version is the model version that the inference scheduler uses to run an inference execution. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Required: No CreatedAt The time at which the specific model was created. Type: Timestamp Required: No DatasetArn The Amazon Resource Name (ARN) of the dataset used to create the model. Type: String ModelSummary 435 Amazon Lookout for Equipment User Guide Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:dataset \/[0-9a-zA-Z_-]{1,200}\/.+ Required: No DatasetName The name of the dataset being used for the machine learning model. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No LatestScheduledRetrainingModelVersion Indicates the most recent model version that was generated by retraining. Type: Long Valid Range: Minimum value of 1. Required: No LatestScheduledRetrainingStartTime Indicates the start time of the most recent scheduled retraining run. Type: Timestamp Required: No LatestScheduledRetrainingStatus Indicates the status of the most recent scheduled retraining run. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED Required: No ModelSummary 436 Amazon Lookout for Equipment ModelArn User Guide The Amazon Resource Name (ARN) of the machine learning model. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Required: No ModelDiagnosticsOutputConfiguration Output configuration information for the pointwise model diagnostics for an Amazon Lookout for Equipment model. Type:
amazon-lookout-for-equipment-ug-099
amazon-lookout-for-equipment-ug.pdf
99
value of 1. Required: No LatestScheduledRetrainingStartTime Indicates the start time of the most recent scheduled retraining run. Type: Timestamp Required: No LatestScheduledRetrainingStatus Indicates the status of the most recent scheduled retraining run. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED Required: No ModelSummary 436 Amazon Lookout for Equipment ModelArn User Guide The Amazon Resource Name (ARN) of the machine learning model. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Required: No ModelDiagnosticsOutputConfiguration Output configuration information for the pointwise model diagnostics for an Amazon Lookout for Equipment model. Type: ModelDiagnosticsOutputConfiguration object Required: No ModelName The name of the machine learning model. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No ModelQuality Provides a quality assessment for a model that uses labels. If Lookout for Equipment determines that the model quality is poor based on training metrics, the value is POOR_QUALITY_DETECTED. Otherwise, the value is QUALITY_THRESHOLD_MET. If the model is unlabeled, the model quality can't be assessed and the value of ModelQuality is CANNOT_DETERMINE_QUALITY. In this situation, you can get a model quality assessment by adding labels to the input dataset and retraining the model. For information about using labels with your models, see Understanding labeling. ModelSummary 437 Amazon Lookout for Equipment User Guide For information about improving the quality of a model, see Best practices with Amazon Lookout for Equipment. Type: String Valid Values: QUALITY_THRESHOLD_MET | CANNOT_DETERMINE_QUALITY | POOR_QUALITY_DETECTED Required: No NextScheduledRetrainingStartDate Indicates the date that the next scheduled retraining run will start on. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp Required: No RetrainingSchedulerStatus Indicates the status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Required: No Status Indicates the status of the machine learning model. Type: String Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: ModelSummary 438 Amazon Lookout for Equipment • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 User Guide ModelSummary 439 User Guide Amazon Lookout for Equipment ModelVersionSummary Contains information about the specific model version. Contents CreatedAt The time when this model version was created. Type: Timestamp Required: No ModelArn The Amazon Resource Name (ARN) of the model that this model version is a version of. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Required: No ModelName The name of the model that this model version is a version of. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No ModelQuality Provides a quality assessment for a model that uses labels. If Lookout for Equipment determines that the model quality is poor based on training metrics, the value is POOR_QUALITY_DETECTED. Otherwise, the value is QUALITY_THRESHOLD_MET. ModelVersionSummary 440 Amazon Lookout for Equipment User Guide If the model is unlabeled, the model quality can't be assessed and the value of ModelQuality is CANNOT_DETERMINE_QUALITY. In this situation, you can get a model quality assessment by adding labels to the input dataset and retraining the model. For information about improving the quality of a model, see Best practices with Amazon Lookout for Equipment. Type: String Valid Values: QUALITY_THRESHOLD_MET | CANNOT_DETERMINE_QUALITY | POOR_QUALITY_DETECTED Required: No ModelVersion The version of the model. Type: Long Valid Range: Minimum value of 1. Required: No ModelVersionArn The Amazon Resource Name (ARN) of the model version. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: ^arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/[0-9a-zA-Z_-]{1,200}\/.+\/model-version\/[0-9]{1,}$ Required: No SourceType Indicates how this model version was generated. Type: String Valid Values: TRAINING | RETRAINING | IMPORT ModelVersionSummary 441 Amazon Lookout for Equipment Required: No Status The current status of the model version. Type: String User Guide Valid Values: IN_PROGRESS | SUCCESS | FAILED | IMPORT_IN_PROGRESS | CANCELED Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 ModelVersionSummary 442 Amazon Lookout for Equipment MonotonicValues User Guide Entity that comprises information on monotonic values in the data. Contents Status Indicates whether there is a potential data issue related to having monotonic values. Type: String Valid Values: POTENTIAL_ISSUE_DETECTED | NO_ISSUE_DETECTED Required: Yes Monotonicity Indicates the monotonicity of values. Can be INCREASING, DECREASING, or STATIC. Type: String Valid Values: DECREASING | INCREASING | STATIC Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby
amazon-lookout-for-equipment-ug-100
amazon-lookout-for-equipment-ug.pdf
100
442 Amazon Lookout for Equipment MonotonicValues User Guide Entity that comprises information on monotonic values in the data. Contents Status Indicates whether there is a potential data issue related to having monotonic values. Type: String Valid Values: POTENTIAL_ISSUE_DETECTED | NO_ISSUE_DETECTED Required: Yes Monotonicity Indicates the monotonicity of values. Can be INCREASING, DECREASING, or STATIC. Type: String Valid Values: DECREASING | INCREASING | STATIC Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 MonotonicValues 443 Amazon Lookout for Equipment User Guide MultipleOperatingModes Entity that comprises information on operating modes in data. Contents Status Indicates whether there is a potential data issue related to having multiple operating modes. Type: String Valid Values: POTENTIAL_ISSUE_DETECTED | NO_ISSUE_DETECTED Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 MultipleOperatingModes 444 Amazon Lookout for Equipment User Guide RetrainingSchedulerSummary Provides information about the specified retraining scheduler, including model name, status, start date, frequency, and lookback window. Contents LookbackWindow The number of past days of data used for retraining. Type: String Pattern: ^P180D$|^P360D$|^P540D$|^P720D$ Required: No ModelArn The ARN of the model that the retraining scheduler is attached to. Type: String Length Constraints: Minimum length of 20. Maximum length of 2048. Pattern: arn:aws(-[^:]+)?:lookoutequipment:[a-zA-Z0-9\-]*:[0-9]{12}:model \/.+ Required: No ModelName The name of the model that the retraining scheduler is attached to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z_-]{1,200}$ Required: No RetrainingFrequency The frequency at which the model retraining is set. This follows the ISO 8601 guidelines. RetrainingSchedulerSummary 445 Amazon Lookout for Equipment Type: String User Guide Length Constraints: Minimum length of 1. Maximum length of 10. Pattern: ^P(\dY)?(\d{1,2}M)?(\d{1,3}D)?$ Required: No RetrainingStartDate The start date for the retraining scheduler. Lookout for Equipment truncates the time you provide to the nearest UTC day. Type: Timestamp Required: No Status The status of the retraining scheduler. Type: String Valid Values: PENDING | RUNNING | STOPPING | STOPPED Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 RetrainingSchedulerSummary 446 User Guide Amazon Lookout for Equipment S3Object Contains information about an S3 bucket. Contents Bucket The name of the specific S3 bucket. Type: String Length Constraints: Minimum length of 3. Maximum length of 63. Pattern: ^[a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]$ Required: Yes Key The AWS Key Management Service (AWS KMS key) key being used to encrypt the S3 object. Without this key, data in the bucket is not accessible. Type: String Length Constraints: Minimum length of 1. Maximum length of 1024. Pattern: [\P{M}\p{M}]{1,1024}[^/]$ Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 S3Object 447 Amazon Lookout for Equipment User Guide SensorStatisticsSummary Summary of ingestion statistics like whether data exists, number of missing values, number of invalid values and so on related to the particular sensor. Contents CategoricalValues Parameter that describes potential risk about whether data associated with the sensor is categorical. Type: CategoricalValues object Required: No ComponentName Name of the component to which the particular sensor belongs for which the statistics belong to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z._\-]{1,200}$ Required: No DataEndTime Indicates the time reference to indicate the end of valid data associated with the sensor that the statistics belong to. Type: Timestamp Required: No DataExists Parameter that indicates whether data exists for the sensor that the statistics belong to. Type: Boolean Required: No SensorStatisticsSummary 448 Amazon Lookout for Equipment DataStartTime User Guide Indicates the time reference to indicate the beginning of valid data associated with the sensor that the statistics belong to. Type: Timestamp Required: No DuplicateTimestamps Parameter that describes the total number of duplicate timestamp records associated with the sensor that the statistics belong to. Type: CountPercent object Required: No InvalidDateEntries Parameter that describes the total number of invalid date entries associated with the sensor that the statistics belong to. Type: CountPercent object Required: No InvalidValues Parameter that describes the total number of, and percentage of, values that are invalid for the sensor that the statistics belong to. Type: CountPercent object Required: No LargeTimestampGaps Parameter that describes potential risk about whether data associated with the sensor contains one or more large gaps between consecutive timestamps. Type: LargeTimestampGaps object Required: No SensorStatisticsSummary 449 Amazon Lookout for Equipment MissingValues User
amazon-lookout-for-equipment-ug-101
amazon-lookout-for-equipment-ug.pdf
101
the sensor that the statistics belong to. Type: CountPercent object Required: No InvalidDateEntries Parameter that describes the total number of invalid date entries associated with the sensor that the statistics belong to. Type: CountPercent object Required: No InvalidValues Parameter that describes the total number of, and percentage of, values that are invalid for the sensor that the statistics belong to. Type: CountPercent object Required: No LargeTimestampGaps Parameter that describes potential risk about whether data associated with the sensor contains one or more large gaps between consecutive timestamps. Type: LargeTimestampGaps object Required: No SensorStatisticsSummary 449 Amazon Lookout for Equipment MissingValues User Guide Parameter that describes the total number of, and percentage of, values that are missing for the sensor that the statistics belong to. Type: CountPercent object Required: No MonotonicValues Parameter that describes potential risk about whether data associated with the sensor is mostly monotonic. Type: MonotonicValues object Required: No MultipleOperatingModes Parameter that describes potential risk about whether data associated with the sensor has more than one operating mode. Type: MultipleOperatingModes object Required: No SensorName Name of the sensor that the statistics belong to. Type: String Length Constraints: Minimum length of 1. Maximum length of 200. Pattern: ^[0-9a-zA-Z:#$.\-_]{1,200}$ Required: No See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: SensorStatisticsSummary 450 Amazon Lookout for Equipment • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 User Guide SensorStatisticsSummary 451 Amazon Lookout for Equipment User Guide SensorsWithShortDateRange Entity that comprises information on sensors that have shorter date range. Contents AffectedSensorCount Indicates the number of sensors that have less than 14 days of data. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 SensorsWithShortDateRange 452 Amazon Lookout for Equipment User Guide Tag A tag is a key-value pair that can be added to a resource as metadata. Contents Key The key for the specified tag. Type: String Length Constraints: Minimum length of 1. Maximum length of 128. Pattern: ^(?!aws:)[a-zA-Z+-=._:/]+$ Required: Yes Value The value for the specified tag. Type: String Length Constraints: Minimum length of 0. Maximum length of 256. Pattern: [\s\w+-=\.:/@]* Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 Tag 453 Amazon Lookout for Equipment User Guide UnsupportedTimestamps Entity that comprises information abount unsupported timestamps in the dataset. Contents TotalNumberOfUnsupportedTimestamps Indicates the total number of unsupported timestamps across the ingested data. Type: Integer Required: Yes See Also For more information about using this API in one of the language-specific AWS SDKs, see the following: • AWS SDK for C++ • AWS SDK for Java V2 • AWS SDK for Ruby V3 Common Errors This section lists the errors common to the API actions of all AWS services. For errors specific to an API action for this service, see the topic for that API action. AccessDeniedException You do not have sufficient access to perform this action. HTTP Status Code: 400 IncompleteSignature The request signature does not conform to AWS standards. HTTP Status Code: 400 UnsupportedTimestamps 454 Amazon Lookout for Equipment InternalFailure User Guide The request processing has failed because of an unknown error, exception or failure. HTTP Status Code: 500 InvalidAction The action or operation requested is invalid. Verify that the action is typed correctly. HTTP Status Code: 400 InvalidClientTokenId The X.509 certificate or AWS access key ID provided does not exist in our records. HTTP Status Code: 403 NotAuthorized You do not have permission to perform this action. HTTP Status Code: 400 OptInRequired The AWS access key ID needs a subscription for the service. HTTP Status Code: 403 RequestExpired The request reached the service more than 15 minutes after the date stamp on the request or more than 15 minutes after the request expiration date (such as for pre-signed URLs), or the date stamp on the request is more than 15 minutes in the future. HTTP Status Code: 400 ServiceUnavailable The request has failed due to a temporary failure of the server. HTTP Status Code: 503 ThrottlingException The request was denied due to request throttling. Common Errors 455 Amazon Lookout for Equipment HTTP Status Code: 400 ValidationError The input fails to satisfy the constraints specified by an AWS service. HTTP Status Code: 400 Common Parameters User Guide The following list contains the parameters that all actions use for signing Signature Version 4 requests with a query string. Any action-specific parameters are listed in the topic for that action. For more information about Signature Version
amazon-lookout-for-equipment-ug-102
amazon-lookout-for-equipment-ug.pdf
102
future. HTTP Status Code: 400 ServiceUnavailable The request has failed due to a temporary failure of the server. HTTP Status Code: 503 ThrottlingException The request was denied due to request throttling. Common Errors 455 Amazon Lookout for Equipment HTTP Status Code: 400 ValidationError The input fails to satisfy the constraints specified by an AWS service. HTTP Status Code: 400 Common Parameters User Guide The following list contains the parameters that all actions use for signing Signature Version 4 requests with a query string. Any action-specific parameters are listed in the topic for that action. For more information about Signature Version 4, see Signing AWS API requests in the IAM User Guide. Action The action to be performed. Type: string Required: Yes Version The API version that the request is written for, expressed in the format YYYY-MM-DD. Type: string Required: Yes X-Amz-Algorithm The hash algorithm that you used to create the request signature. Condition: Specify this parameter when you include authentication information in a query string instead of in the HTTP authorization header. Type: string Valid Values: AWS4-HMAC-SHA256 Required: Conditional Common Parameters 456 Amazon Lookout for Equipment X-Amz-Credential User Guide The credential scope value, which is a string that includes your access key, the date, the region you are targeting, the service you are requesting, and a termination string ("aws4_request"). The value is expressed in the following format: access_key/YYYYMMDD/region/service/ aws4_request. For more information, see Create a signed AWS API request in the IAM User Guide. Condition: Specify this parameter when you include authentication information in a query string instead of in the HTTP authorization header. Type: string Required: Conditional X-Amz-Date The date that is used to create the signature. The format must be ISO 8601 basic format (YYYYMMDD'T'HHMMSS'Z'). For example, the following date time is a valid X-Amz-Date value: 20120325T120000Z. Condition: X-Amz-Date is optional for all requests; it can be used to override the date used for signing requests. If the Date header is specified in the ISO 8601 basic format, X-Amz-Date is not required. When X-Amz-Date is used, it always overrides the value of the Date header. For more information, see Elements of an AWS API request signature in the IAM User Guide. Type: string Required: Conditional X-Amz-Security-Token The temporary security token that was obtained through a call to AWS Security Token Service (AWS STS). For a list of services that support temporary security credentials from AWS STS, see AWS services that work with IAM in the IAM User Guide. Condition: If you're using temporary security credentials from AWS STS, you must include the security token. Type: string Required: Conditional Common Parameters 457 Amazon Lookout for Equipment X-Amz-Signature User Guide Specifies the hex-encoded signature that was calculated from the string to sign and the derived signing key. Condition: Specify this parameter when you include authentication information in a query string instead of in the HTTP authorization header. Type: string Required: Conditional X-Amz-SignedHeaders Specifies all the HTTP headers that were included as part of the canonical request. For more information about specifying signed headers, see Create a signed AWS API request in the IAM User Guide. Condition: Specify this parameter when you include authentication information in a query string instead of in the HTTP authorization header. Type: string Required: Conditional Common Parameters 458 Amazon Lookout for Equipment User Guide Document history for the Amazon Lookout for Equipment User Guide The following table describes the documentation for this release of Lookout for Equipment. • API version: latest • Latest documentation update: October 17th, 2024 Change Description Date Amazon Lookout for Equipment is no longer open Amazon Lookout for Equipment is no longer to new customers. open to new customers. For October 17th, 2024 capabilities similar to Amazon Lookout for Equipment, see our blog post. Amazon Lookout for Equipment will no longer Amazon Lookout for Equipment will no longer be open to new customers be open to new customers starting October 17, 2024. starting October 17, 2024. September 17th, 2024 Bulk import resources. If you would like to use service, sign up prior to that date. Existing customers can continue to use the service as normal. For capabilities similar to Amazon Lookout for Equipment, see our blog post. You can now bulk import Amazon Lookout for Equipment resources from a source AWS account to a target AWS account. March 8th, 2024 459 Amazon Lookout for Equipment User Guide Change Description Date Model quality. Getting pointwise model diagnostics for a model. Importing and versioning. You can now get a quality assessment for an Amazon Lookout for Equipment model. You can now get pointwise model diagnostics for an Amazon Lookout for Equipment model. You can work with multiple versions of your model, and you can import versions from other accounts. February 21st, 2024 February 14, 2024 July 28, 2023 AmazonLookoutEquip mentReadOnlyAccess – Lookout for Equipment
amazon-lookout-for-equipment-ug-103
amazon-lookout-for-equipment-ug.pdf
103
Amazon Lookout for Equipment resources from a source AWS account to a target AWS account. March 8th, 2024 459 Amazon Lookout for Equipment User Guide Change Description Date Model quality. Getting pointwise model diagnostics for a model. Importing and versioning. You can now get a quality assessment for an Amazon Lookout for Equipment model. You can now get pointwise model diagnostics for an Amazon Lookout for Equipment model. You can work with multiple versions of your model, and you can import versions from other accounts. February 21st, 2024 February 14, 2024 July 28, 2023 AmazonLookoutEquip mentReadOnlyAccess – Lookout for Equipment modified the policy to allow Update to an existing policy all Describe actions and all November 4, 2022 List actions. AmazonLookoutEquip mentReadOnlyAccess – Lookout for Equipment modified the policy so as to Update to an existing policy allow all list and describe October 26, 2022 Schema detection Ingestion validation APIs. You no longer have to define a schema for your dataset in JSON. Lookout for Equipment will do it for you. When you ingest a dataset, Lookout for Equipment helps you determine which sensors should be used in the building of your model. April 22, 2022 April 22, 2022 460 Amazon Lookout for Equipment User Guide Change Description Date Update to grant retirement policy Removed the retire grant from the managed policy November 19, 2021 as the service will be using retiring grant principal to retire the grants. You dont need to provide the retire grant permissions in the managed policy. This version supports the generally available release of Amazon Lookout for Equipment. This version supports the preview release of Amazon Lookout for Equipment. April 8, 2021 December 1, 2020 General availability New guide and service 461
amazon-managed-blockchain-ethereum-dev-001
amazon-managed-blockchain-ethereum-dev.pdf
1
Ethereum Developer Guide Amazon Managed Blockchain (AMB) Copyright © 2025 Amazon Web Services, Inc. and/or its affiliates. All rights reserved. Amazon Managed Blockchain (AMB) Ethereum Developer Guide Amazon Managed Blockchain (AMB): Ethereum Developer Guide Copyright © 2025 Amazon Web Services, Inc. and/or its affiliates. All rights reserved. Amazon's trademarks and trade dress may not be used in connection with any product or service that is not Amazon's, in any manner that is likely to cause confusion among customers, or in any manner that disparages or discredits Amazon. All other trademarks not owned by Amazon are the property of their respective owners, who may or may not be affiliated with, connected to, or sponsored by Amazon. Amazon Managed Blockchain (AMB) Table of Contents Ethereum Developer Guide What is Amazon Managed Blockchain (AMB) Access Ethereum .................................................... 1 Key concepts .................................................................................................................................... 3 Considerations and limitations for Amazon Managed Blockchain (AMB) Access Ethereum ........... 4 Setting up ........................................................................................................................................ 7 Sign up for AWS ........................................................................................................................................... 7 Create an IAM user with appropriate permissions ................................................................................ 7 Install and configure the AWS Command Line Interface ..................................................................... 8 Getting started ................................................................................................................................ 9 Create an IAM policy ................................................................................................................................... 9 Create a node ............................................................................................................................................. 11 Create an Accessor token ......................................................................................................................... 13 Make JSON-RPC calls ................................................................................................................................ 14 Working with nodes ...................................................................................................................... 15 Creating a node .......................................................................................................................................... 15 Viewing node details ................................................................................................................................. 17 Deleting a node .......................................................................................................................................... 20 Using token based access ............................................................................................................. 22 Creating an Accessor token for token based access ........................................................................... 23 Viewing an Accessor token details ......................................................................................................... 24 Deleting an Accessor token ...................................................................................................................... 25 JSON-RPC and API ......................................................................................................................... 27 Supported JSON-RPC methods ............................................................................................................... 27 Examples using the JSON-RPC API ................................................................................................... 44 Supported Consensus API methods ....................................................................................................... 58 Examples making Consensus API calls ............................................................................................. 62 Security .......................................................................................................................................... 71 Data Protection ........................................................................................................................................... 71 Encryption in transit ............................................................................................................................ 71 Authentication and access control ......................................................................................................... 72 Identity and Access Management ..................................................................................................... 72 Tagging resources ........................................................................................................................ 101 Create and add tags for AMB Access Ethereum resources .............................................................. 101 Tag naming and usage conventions .................................................................................................... 102 Working with tags ................................................................................................................................... 102 iii Amazon Managed Blockchain (AMB) Ethereum Developer Guide CloudTrail logs ............................................................................................................................. 104 Managed Blockchain information in CloudTrail ................................................................................ 104 Understanding log file entries .............................................................................................................. 105 Using CloudTrail to track Ethereum calls ........................................................................................... 106 Document history ........................................................................................................................ 109 iv Amazon Managed Blockchain (AMB) Ethereum Developer Guide What is Amazon Managed Blockchain (AMB) Access Ethereum Amazon Managed Blockchain (AMB) Access provides you with public blockchain nodes for Ethereum and Bitcoin, and you can also create private blockchain networks with the Hyperledger Fabric framework. Choose from various methods to engage with public blockchains, including fully managed, single-tenant (dedicated), and serverless multi-tenant API operations to public blockchain nodes. For use cases where access controls are important, you can choose from fully managed private blockchain networks. Standardized API operations give you instant scalability on a fully managed, resilient infrastructure, so you can build blockchain applications. AMB Access gives you two distinct types of blockchain infrastructure services: multi-tenant blockchain network access API operations and dedicated blockchain nodes and networks. With dedicated blockchain infrastructure, you can create and use public Ethereum blockchain nodes and private Hyperledger Fabric blockchain networks for your own use. Multi-tenant, API-based offerings, however, such as AMB Access Bitcoin, are composed of a fleet of Bitcoin nodes behind an API layer where the underlying blockchain node infrastructure is shared among customers. Ethereum is a decentralized and programmable blockchain network on which users around the world can transact, collaborate, and build applications. The Ethereum virtual machine (EVM) helps developers create powerful and composable decentralized applications (dApps) in the form of smart contracts. Use Amazon Managed Blockchain (AMB) Access Ethereum to build Ethereum dApps on Mainnet and select testnets with Ethereum full nodes using the go-ethereum (Geth) execution client and the Lighthouse consensus client. You can use your dedicated (single- tenant) Ethereum node(s) to invoke the Ethereum JSON-RPC APIs for both the Execution and Consensus layers to build and test smart contracts, perform fungible or non-fungible token (NFT) transactions, or query data from the Ethereum blockchain. Important Ethereum Mainnet has merged with the Beacon chain's proof-of-stake system. Ethereum nodes on Amazon Managed Blockchain (AMB) support this change and require no further action on your part. For more information on using the Consensus API to query the Beacon chain, see Supported Consensus API methods. For more information on the merge, see The Merge topic on the Ethereum website. 1 Amazon Managed Blockchain (AMB) Ethereum Developer Guide This guide covers the how to create and manage Ethereum blockchain resources using Amazon Managed Blockchain (AMB) Access Ethereum. For information about working with AMB Access Hyperledger Fabric, see Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide. 2 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Key concepts: Amazon Managed Blockchain (AMB) Access Ethereum Note This guide assumes that you're familiar with the concepts that are
amazon-managed-blockchain-ethereum-dev-002
amazon-managed-blockchain-ethereum-dev.pdf
2
the Consensus API to query the Beacon chain, see Supported Consensus API methods. For more information on the merge, see The Merge topic on the Ethereum website. 1 Amazon Managed Blockchain (AMB) Ethereum Developer Guide This guide covers the how to create and manage Ethereum blockchain resources using Amazon Managed Blockchain (AMB) Access Ethereum. For information about working with AMB Access Hyperledger Fabric, see Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide. 2 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Key concepts: Amazon Managed Blockchain (AMB) Access Ethereum Note This guide assumes that you're familiar with the concepts that are essential to Ethereum. These concepts include nodes, dapps, transactions, gas, Ether, and others. Before you deploy a node using AMB Access Ethereum and develop dapps, we recommend that you review the Ethereum Development Documentation and Mastering Ethereum. You can use Amazon Managed Blockchain (AMB) Access Ethereum to quickly provision Ethereum nodes and join them to the public Ethereum mainnet or popular public testnets. Ethereum nodes on a network collectively store an Ethereum blockchain state, verify transactions, and participate in consensus to change a blockchain state. You can use an Ethereum node to develop and use decentralized applications (dapps) that interact with an Ethereum blockchain. The "backend" of a dapp is a smart contract that runs in a decentralized way across all the nodes that are joined to an Ethereum network. Anyone that joined to the network can develop and deploy a smart contract that adds functionality. The "frontend" of a dapp can use Ethereum API operations and libraries, specifically the JSON- RPC API or the Consensus API, to interact with the Ethereum network. You can use these APIs to communicate with Ethereum node in Amazon Managed Blockchain (AMB). These APIs allow the dapp to read data and write transactions. You can use the JSON-RPC API to query the smart contract data and submit transactions to an Ethereum node on the AMB Access. You can use the Consensus API to query the Beacon chain and its configuration. You can also use Consensus API to get the health of nodes on the Mainnet. With Ethereum APIs in AMB Access, your "frontend" dapp can use an HTTP or WebSocket (JSON- RPC API only) connection to make API calls. Only users in the AWS account that owns the node can make API calls. Calls over HTTP and WebSocket connections are authenticated by using the Signature Version 4 signing process. 3 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Important • Amazon Managed Blockchain (AMB) helps you provision Ethereum nodes. You are responsible for creating, maintaining, and using of your Ethereum Accounts. You are also responsible for the contents of your Ethereum Accounts. This includes, but is not limited to, Ether (ETH) and smart contracts. AWS is not responsible for any of your smart contracts tested, compiled, deployed or called using Ethereum nodes in Amazon Managed Blockchain (AMB). • For historic data that requires archival nodes, use Amazon Managed Blockchain (AMB) Query. For more information, see the AMB Query Developer Guide. Considerations and limitations for Amazon Managed Blockchain (AMB) Access Ethereum When you use Amazon Managed Blockchain (AMB) Access Ethereum to host a node on an Ethereum network, consider the following. • Supported networks Ethereum has a public mainnet and several public testnets used for development, testing, and proof of concept. AMB Access supports the following public networks. • Mainnet – The proof-of-stake network of the primary public Ethereum blockchain. Transactions on Mainnet have actual value (that is, they incur real costs) and are recorded on the distributed ledger. This network supports the JSON-RPC and Consensus API operations. • Networks no longer supported AMB Access Ethereum no longer supports the following public networks. Private networks aren't supported. • Ropsten – A public proof-of-stake read-only testnet. Ether on this network has no real monetary value. You can't provision new nodes on Ropsten as of February 28th, 2023. The Ethereum foundation ceased support of Ropsten on December 31st, 2022.. • Rinkeby – A public proof-of-authority read-only testnet for Go Ethereum (Geth) clients. Ether on this network has no real monetary value. You can't provision new nodes on Rinkeby as of August 10th, 2023. The Ethereum foundation ceased support of Rinkeby on May 31st, 2023. Considerations and limitations for Amazon Managed Blockchain (AMB) Access Ethereum 4 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • Görli (Goerli) – A public cross-client, proof-of-stake network. Ether on this network has no real monetary value. In line with the April 17, 2024 sunsetting of the Goerli testnet communicated by the Ethereum Foundation, AMB Access Ethereum ended support of the Goerli testnet on April 1, 2024. We recommend using the Sepolia or Holesky testnets for your testing workload. • Compatibility with popular third-party programming libraries AMB Access Ethereum is compatible with popular programming libraries,
amazon-managed-blockchain-ethereum-dev-003
amazon-managed-blockchain-ethereum-dev.pdf
3
of Rinkeby on May 31st, 2023. Considerations and limitations for Amazon Managed Blockchain (AMB) Access Ethereum 4 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • Görli (Goerli) – A public cross-client, proof-of-stake network. Ether on this network has no real monetary value. In line with the April 17, 2024 sunsetting of the Goerli testnet communicated by the Ethereum Foundation, AMB Access Ethereum ended support of the Goerli testnet on April 1, 2024. We recommend using the Sepolia or Holesky testnets for your testing workload. • Compatibility with popular third-party programming libraries AMB Access Ethereum is compatible with popular programming libraries, such as ethers.js allowing developers to interact with the Polygon blockchain using familiar tools to integrate easily with their existing implementations or develop new applications quickly. • Staking not supported Ethereum nodes that are created using AMB Access don't support staking. • Different endpoints for WebSockets and HTTP AMB Access Ethereum supports the Ethereum API over HTTP and WebSocket (JSON-RPC API only). Each Ethereum node in AMB Access hosts different endpoints for HTTP and WebSocket connections. • JSON-RPC batch requests aren't supported Ethereum nodes that are created using AMB Access don't support JSON-RPC batch requests. • Payload quotas for API calls WebSocket calls have a 512 KB payload quota. Some calls might exceed this quota and cause a "message response is too large" error. For this reason, we recommend you use HTTP for these requests instead of WebSocket connections. If your HTTP response is larger than 5.9 MB, you will get an error. To correct this, you must set both compression headers as Accept: application/gzip and Accept-Encoding: gzip. The compressed response your client then receives contains the following headers: Content-Type: application/json and Content- Encoding: gzip. • Signature Version 4 signing of API calls Ethereum API calls to an Ethereum node in Amazon Managed Blockchain (AMB) can be authenticated by using the Signature Version 4 (SigV4) signing process. This means that only authorized IAM principals in the AWS account that created the node can interact with it using the Ethereum APIs. AWS credentials (an access key ID and secret access key) must be provided with the call. Considerations and limitations for Amazon Managed Blockchain (AMB) Access Ethereum 5 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Important Never embed client credentials in user-facing applications. To expose an Ethereum node in AMB Access to anonymous users visiting from trusted web domains, you can set up a separate endpoint in Amazon API Gateway backed by a Lambda function that forwards requests to your node that uses the proper IAM credentials. • Support for Token Based Access You can use Accessor tokens to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens that you create as a query parameter with the call. Important • If you prioritize security and auditability over convenience, use the SigV4 signing process instead. • You can access the Ethereum APIs using Signature Version 4 (SigV4) and token based access. However, if you choose to use token based access, then any security benefits that are provided by using SigV4 are negated. • Never embed Accessor tokens in user-facing applications. • Only raw transactions are supported AMB Access only supports the use of the eth_sendRawTransaction method to submit transactions that update the Ethereum blockchain state. Before transactions can be sent, you must create and sign transactions using Ethereum private keys outside AMB Access. In other words, you can't use AMB Access as an Ethereum wallet. You must generate and store Ethereum transactions and private keys externally. • Node limit per account AMB Access supports a maximum of 50 Ethereum nodes for each account. Considerations and limitations for Amazon Managed Blockchain (AMB) Access Ethereum 6 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Setting up for AMB Access Ethereum Sign up for AWS When you sign up for Amazon Web Services (AWS), your AWS account is automatically signed up for all AWS services, including Amazon Managed Blockchain (AMB). You're charged only for the services that you use. With AMB Access Ethereum, you pay for the node, the storage that you use, and the number of requests between the node and the network. If you have an AWS account already, go to the next step. If you don't have an AWS account, use the following procedure to create one. To create an AWS account 1. Open https://portal.aws.amazon.com/billing/signup. 2. Follow the online instructions. Part of the sign-up procedure involves receiving a phone call and entering a verification code on the phone keypad. When you sign up for an AWS account, an AWS account root user is created. The root user has access to all AWS services and resources in the account. As a security
amazon-managed-blockchain-ethereum-dev-004
amazon-managed-blockchain-ethereum-dev.pdf
4
the number of requests between the node and the network. If you have an AWS account already, go to the next step. If you don't have an AWS account, use the following procedure to create one. To create an AWS account 1. Open https://portal.aws.amazon.com/billing/signup. 2. Follow the online instructions. Part of the sign-up procedure involves receiving a phone call and entering a verification code on the phone keypad. When you sign up for an AWS account, an AWS account root user is created. The root user has access to all AWS services and resources in the account. As a security best practice, assign administrative access to a user, and use only the root user to perform tasks that require root user access. Create an IAM user with appropriate permissions To create and work with Ethereum resources in Amazon Managed Blockchain (AMB), you need an AWS Identity and Access Management (IAM) principal (user or group) with permissions that allow necessary AMB Access actions on those resources. Example actions include creating or deleting nodes. An IAM principal is also required to make AMB Access API requests. Ethereum API calls to an Ethereum node in Amazon Managed Blockchain (AMB) can be authenticated by using the Signature Version 4 (SigV4) signing process. This means that only authorized IAM principals in the AWS Sign up for AWS 7 Amazon Managed Blockchain (AMB) Ethereum Developer Guide account that created the node can interact with it using the Ethereum APIs. AWS credentials (an access key ID and secret access key) must be provided with the call. You can also use Accessor tokens to make JSON-RPC calls to the Ethereum network as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens you create and add as a parameter with your requests. However, you still need IAM access to get permissions to create Accessor tokens using the AWS Management Console, AWS CLI, and SDK. For information about how to create an IAM user, see Creating an IAM user in your AWS account. For more information about how to attach a permissions policy to a user, see Changing permissions for an IAM user. For an example of a permissions policy that you can use to give a user permission to work with AMB Access Ethereum resources, see Performing all available actions for AMB Access Ethereum. Install and configure the AWS Command Line Interface If you have not already done so, install the latest AWS Command Line Interface (AWS CLI) to work with AWS resources from a terminal. For more information, see Installing or updating the latest version of the AWS CLI. Note For CLI access, you need an access key ID and a secret access key. Use temporary credentials instead of long-term access keys when possible. Temporary credentials include an access key ID, a secret access key, and a security token that indicates when the credentials expire. For more information, see Using temporary credentials with AWS resources in the IAM User Guide. Install and configure the AWS Command Line Interface 8 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Getting started with Amazon Managed Blockchain (AMB) Access Ethereum The step-by-step tutorials in this section will show you how to perform the following tasks using Amazon Managed Blockchain (AMB) Access Ethereum. Each task builds on the previous one, ending in making JSON-RPC calls to your Ethereum node. Topics • Create an IAM policy to access the Ethereum network • Create a node using the AWS Management Console • Create an Accessor token using the AWS Management Console • Find your HTTP or Websocket endpoints and make JSON-RPC calls Create an IAM policy to access the Ethereum network In order to access the Ethereum Mainnet to make JSON-RPC and Consensus API calls, you must have user credentials (AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY) that have the appropriate IAM permissions for Amazon Managed Blockchain (AMB) Access Ethereum. This example shows how you grant users AWS account access in the us-east-1 Region so that they can do the following: • List all Ethereum networks • Create and list nodes on all those networks • Get and delete nodes in AWS account 111122223333 • Get and delete accessors in AWS account 555555555555 • Create WebSocket connections, and send HTTP requests to an Ethereum node Note • If you want to grant access across all Regions, replace us-east-1 with *. • You must specify the AWS account ID of the node and accessor resources in the policy that you want to enforce. Create an IAM policy 9 Amazon Managed Blockchain (AMB) Ethereum Developer Guide { "Version": "2012-10-17", "Statement": [ { "Sid": "WorkWithEthereumNetworks", "Effect": "Allow", "Action": [ "managedblockchain:ListNetworks", "managedblockchain:GetNetwork" ], "Resource": [ "arn:aws:managedblockchain:us-east-1::networks/n-ethereum-mainnet" ] }, { "Sid": "CreateAndListEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:CreateNode", "managedblockchain:ListNodes" ], "Resource": [ "arn:aws:managedblockchain:us-east-1::networks/*"
amazon-managed-blockchain-ethereum-dev-005
amazon-managed-blockchain-ethereum-dev.pdf
5
delete accessors in AWS account 555555555555 • Create WebSocket connections, and send HTTP requests to an Ethereum node Note • If you want to grant access across all Regions, replace us-east-1 with *. • You must specify the AWS account ID of the node and accessor resources in the policy that you want to enforce. Create an IAM policy 9 Amazon Managed Blockchain (AMB) Ethereum Developer Guide { "Version": "2012-10-17", "Statement": [ { "Sid": "WorkWithEthereumNetworks", "Effect": "Allow", "Action": [ "managedblockchain:ListNetworks", "managedblockchain:GetNetwork" ], "Resource": [ "arn:aws:managedblockchain:us-east-1::networks/n-ethereum-mainnet" ] }, { "Sid": "CreateAndListEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:CreateNode", "managedblockchain:ListNodes" ], "Resource": [ "arn:aws:managedblockchain:us-east-1::networks/*" ] }, { "Sid": "ManageEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:GetNode", "managedblockchain:DeleteNode" ], "Resource": [ "arn:aws:managedblockchain:us-east-1:111122223333:nodes/*" ] }, { "Sid": "GetAndDeleteAccessors", "Effect": "Allow", "Action": [ "managedblockchain:GetAccessor", Create an IAM policy 10 Amazon Managed Blockchain (AMB) Ethereum Developer Guide "managedblockchain:DeleteAccessor" ], "Resource": [ "arn:aws:managedblockchain:us-east-1:555555555555:accessors/*" ] }, { "Sid": "CreateAndListAccessors", "Effect": "Allow", "Action": [ "managedblockchain:CreateAccessor", "managedblockchain:ListAccessors" ], "Resource": [ "*" ] }, { "Sid": "WorkWithEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:POST", "managedblockchain:GET", "managedblockchain:Invoke" ], "Resource": [ "arn:aws:managedblockchain:us-east-1:111122223333:*" ] } ] } After you create the policy, attach that policy to your IAM user’s role for it to take effect. For more information, see Creating a Role and assigning to an IAM user. Create a node using the AWS Management Console You must create an Ethereum node to make requests to the Ethereum network. The following example shows you how to create a node using the AWS Management Console To create an Ethereum node, you must consider and select the following characteristics: Create a node 11 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • Blockchain network – Amazon Managed Blockchain (AMB) supports the following public Ethereum networks: Mainnet – The proof-of-stake network of the primary public Ethereum blockchain. Transactions on Mainnet have actual value (that is, they incur real costs) and are recorded on the distributed ledger. This network supports the JSON-RPC and Consensus API operations. • Blockchain instance type – This determines the computational and memory capacity allocated to this node for the blockchain workload. If you anticipate a more demanding workload for each node, you can choose more CPU and RAM. For example, your nodes might need to process a higher rate of transactions. Different instance types are subject to different pricing. Note For optimal performance and minimal degradation, we recommend the bc.t3.xlarge (or larger) instance size. • Ethereum node type – The only node type that is currently supported is Full node (Geth). The node uses the Geth execution client and the Lighthouse consensus client. For more information about node types, see Node Types in the Ethereum developer documentation. For more information on Execution clients such as Geth, see Execution clients in the Ethereum developer documentation. For more information on Consensus clients such as Lighthouse, see Consensus clients in the Ethereum developer documentation. • Availability Zone – You can select the Availability Zone to launch the Ethereum node in. You can distribute nodes across different Availability Zones. This way, you can design your blockchain application for resiliency. For more information, see Regions and Availability Zones in the Amazon EC2 User Guide. 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. Choose Networks from the Access header in the left navigation. 3. Choose the Dedicated networks tab and select Ethereum Mainnet as your network to the details page. 4. Choose Create node. 5. In the Create node page, choose the Blockchain instance type suitable for your application. If your nodes need to process a higher rate of transactions more efficiently, choose an instance type with more CPU and RAM. 6. Choose the Ethereum node type, choose Full node (Geth). Create a node 12 Amazon Managed Blockchain (AMB) Ethereum Developer Guide 7. Choose the Availability zone such as us-east-1. 8. Optional, choose Add new tag in the Tags section. 9. Choose Create node. Note Amazon Managed Blockchain (AMB) Access Ethereum provisions and configures the node for you. The length of this process is not instantaneous depends on many variables. After you create the node, the Node details page in the AWS Management Console displays the endpoints that you can use to make Ethereum API calls from code on a client. There are separate endpoints for HTTP connections and WebSocket connections. For more information about sending API calls to an Ethereum node in Amazon Managed Blockchain (AMB) to interact with smart contracts, see Using Ethereum APIs with Amazon Managed Blockchain (AMB). Create an Accessor token using the AWS Management Console You can use Accessor tokens to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens that you create as a query parameter with the call. Important • If you prioritize security and auditability
amazon-managed-blockchain-ethereum-dev-006
amazon-managed-blockchain-ethereum-dev.pdf
6
for HTTP connections and WebSocket connections. For more information about sending API calls to an Ethereum node in Amazon Managed Blockchain (AMB) to interact with smart contracts, see Using Ethereum APIs with Amazon Managed Blockchain (AMB). Create an Accessor token using the AWS Management Console You can use Accessor tokens to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens that you create as a query parameter with the call. Important • If you prioritize security and auditability over convenience, use the SigV4 signing process instead. • You can access the Ethereum APIs using Signature Version 4 (SigV4) and token based access. However, if you choose to use token based access, then any security benefits that are provided by using SigV4 are negated. • Never embed Accessor tokens in user-facing applications. The following example shows how to create an Accessor token on the AWS Management Console and use it to make Ethereum API calls on any Ethereum node in your AWS account. <result> Create an Accessor token 13 Amazon Managed Blockchain (AMB) Ethereum Developer Guide AMB Access then provisions and configures the token for you. The length of this process depends on many variables. </result> 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. Choose Token accessors. 3. Choose Create accessor. 4. Choose a valid Ethereum blockchain Network. 5. Optional, add Tags for your Accessor. 6. Choose Create accessor to create a new Accessor token. Find your HTTP or Websocket endpoints and make JSON-RPC calls In the console, the Token accessors page displays a list of all the Accessor tokens that you can use to make Ethereum API calls to nodes in your AWS account from code on a client. There are separate endpoints for HTTP connections and WebSocket connections. These endpoints will be formatted as follows: • HTTPS — https://your-node-id-lowercase.t.ethereum.managedblockchain.us- east-1.amazonaws.com/?billingtoken=your-billing-token • Websocket — wss://your-node-id- lowercase.wss.t.ethereum.managedblockchain.us-east-1.amazonaws.com/? billingtoken=your-billing-token After you have completed all the steps in this chapter, you have set up your IAM permissions, created your Ethereum node and Accessor tokens, and have your relevant endpoints. You can proceed to the Using token based access to make JSON-RPC API calls to an Ethereum node topic and run those examples. Make JSON-RPC calls 14 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Working with Ethereum nodes using AMB Access You can use AMB Access Ethereum to create nodes and join them to Ethereum public networks. A node is a computer that connects to a blockchain network. A blockchain network consists of multiple parties (or peers) that are connected to each other in a decentralized way. When you use AMB Access Ethereum, you pay for the nodes, the storage that you use, and the requests that are made between the nodes and the network. Creating a node When you create an Ethereum node, you select the network that the node joins and the configuration details such as the instance type and the Ethereum node type. When you create an Ethereum node in Amazon Managed Blockchain (AMB), a full Geth node on the selected Ethereum network is created. The IAM principal (user or group) that you use must have permissions to create nodes and view node information. For more information, see Performing all available actions for AMB Access Ethereum. To create an Ethereum node, you must consider and select the following characteristics: • Blockchain network – Amazon Managed Blockchain (AMB) supports the following public Ethereum networks: Mainnet – The proof-of-stake network of the primary public Ethereum blockchain. Transactions on Mainnet have actual value (that is, they incur real costs) and are recorded on the distributed ledger. This network supports the JSON-RPC and Consensus API operations. • Blockchain instance type – This determines the computational and memory capacity allocated to this node for the blockchain workload. If you anticipate a more demanding workload for each node, you can choose more CPU and RAM. For example, your nodes might need to process a higher rate of transactions. Different instance types are subject to different pricing. Note For optimal performance and minimal degradation, we recommend the bc.t3.xlarge (or larger) instance size. • Ethereum node type – The only node type that is currently supported is Full node (Geth). The node uses the Geth execution client and the Lighthouse consensus client. For more information Creating a node 15 Amazon Managed Blockchain (AMB) Ethereum Developer Guide about node types, see Node Types in the Ethereum developer documentation. For more information on Execution clients such as Geth, see Execution clients in the Ethereum developer documentation. For more information on Consensus clients such as Lighthouse, see Consensus clients in the Ethereum developer documentation. • Availability Zone – You can select the Availability Zone to launch the Ethereum node
amazon-managed-blockchain-ethereum-dev-007
amazon-managed-blockchain-ethereum-dev.pdf
7
type – The only node type that is currently supported is Full node (Geth). The node uses the Geth execution client and the Lighthouse consensus client. For more information Creating a node 15 Amazon Managed Blockchain (AMB) Ethereum Developer Guide about node types, see Node Types in the Ethereum developer documentation. For more information on Execution clients such as Geth, see Execution clients in the Ethereum developer documentation. For more information on Consensus clients such as Lighthouse, see Consensus clients in the Ethereum developer documentation. • Availability Zone – You can select the Availability Zone to launch the Ethereum node in. You can distribute nodes across different Availability Zones. This way, you can design your blockchain application for resiliency. For more information, see Regions and Availability Zones in the Amazon EC2 User Guide. To create an Ethereum node using the AWS Management Console 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. Choose Networks from the Access header in the left navigation. 3. Choose the Dedicated networks tab and select Ethereum Mainnet as your network to the details page. 4. Choose Create node. 5. In the Create node page, choose the Blockchain instance type suitable for your application. If your nodes need to process a higher rate of transactions more efficiently, choose an instance type with more CPU and RAM. 6. Choose the Ethereum node type, choose Full node (Geth). 7. Choose the Availability zone such as us-east-1. 8. Optional, choose Add new tag in the Tags section. 9. Choose Create node. Note Amazon Managed Blockchain (AMB) Access Ethereum provisions and configures the node for you. The length of this process is not instantaneous depends on many variables. To create an Ethereum node using the AWS CLI The following example shows how to use the create-node command. Replace the value of -- network-id, InstanceType, and AvailabilityZone as appropriate. Creating a node 16 Amazon Managed Blockchain (AMB) Ethereum Developer Guide aws managedblockchain create-node \ --node-configuration '{"InstanceType":"bc.t3.xlarge","AvailabilityZone":"us- east-1a"}' \ --network-id n-ethereum-mainnet Ethereum public networks have the following network IDs: • n-ethereum-mainnet The command returns the node ID, as shown in the following snippet. { "NodeId": "nd-RG3GM4U7HFFHHHGJHHU7UNPCLU" } After you create the node, the Node details page in the AWS Management Console displays the endpoints that you can use to make Ethereum API calls from code on a client. There are separate endpoints for HTTP connections and WebSocket connections. For more information about sending API calls to an Ethereum node in Amazon Managed Blockchain (AMB) to interact with smart contracts, see Using Ethereum APIs with Amazon Managed Blockchain (AMB). Viewing node details After you create a node, you can view administrative properties for each node that your AWS account owns. For example, you can view the endpoints to use for Ethereum API calls on HTTP and WebSocket (JSON-RPC API only) connections, the node status, and important performance metrics for the node. The IAM principal (user or group) that you use must have permissions to list and get node information. For more information, see Identity-based policy examples. Information such as the AMB Access instance type, Availability Zone, and creation date, is available for the node. The following properties are also available: • Status • Creating AMB Access is provisioning and configuring the AMB Access instance for the node. The amount of time that it takes to create a node depends on many factors. Nodes on testnets typically take a few minutes to create. Nodes on mainnet might take an hour or longer to create. Viewing node details 17 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • Available The node is running and available on the network. • Unhealthy AMB Access detected a problem and is automatically replacing the blockchain instance that the node runs on. Nodes in an unhealthy state typically return to an available state in approximately five minutes. • Failed The node has an issue that caused AMB Access to add it to the deny list on the network. This usually indicates that the node reached its memory or storage capacity. As a first step, we recommend that you delete the instance and provision an instance type with more capability. • Create Failed The node couldn't be created with the AMB Access instance type and the Availability Zone specified. We recommend trying another availability zone, a different instance type, or both. • Deleting The node is being deleted. • Deleted The node is now deleted. For possible reasons, see the previous item. • Endpoints Endpoints are used to make Ethereum API calls to the node. When AMB Access creates the node, it assigns unique endpoints. Nodes support connections over HTTP and WebSockets (JSON-RPC API only). You use a different endpoint for each connection. For more information, see Using Ethereum APIs with Amazon Managed Blockchain (AMB). To view Ethereum node information using the
amazon-managed-blockchain-ethereum-dev-008
amazon-managed-blockchain-ethereum-dev.pdf
8
instance type and the Availability Zone specified. We recommend trying another availability zone, a different instance type, or both. • Deleting The node is being deleted. • Deleted The node is now deleted. For possible reasons, see the previous item. • Endpoints Endpoints are used to make Ethereum API calls to the node. When AMB Access creates the node, it assigns unique endpoints. Nodes support connections over HTTP and WebSockets (JSON-RPC API only). You use a different endpoint for each connection. For more information, see Using Ethereum APIs with Amazon Managed Blockchain (AMB). To view Ethereum node information using the AWS Management Console 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. If the console doesn't open to the Networks list, choose Networks from the navigation pane. 3. Choose the Name of the Ethereum network that the node belongs to from the list. 4. On the network details page, under Nodes, choose the Node ID. Viewing node details 18 Amazon Managed Blockchain (AMB) Ethereum Developer Guide 5. The following example shows how the node details page displays key properties and metrics for the node. To view Ethereum node information using the AWS CLI The following example shows how to use the get-node command to view Ethereum node information. Replace the value of --network-id and --node-id as appropriate. aws managedblockchain get-node \ --network-id n-ethereum-mainnet \ --node-id nd-RG3GM4U7HFFHHHGJHHU7UNPCLU The command returns the following output that includes the node's HttpEndpoint, WebSocketEndpoint, and other key properties. Viewing node details 19 Amazon Managed Blockchain (AMB) Ethereum Developer Guide { "Node": { "NetworkId": "n-ethereum-mainnet", "Id": "nd-RG3GM4U7HFFHHHGJHHU7UNPCLU", "InstanceType": "bc.t3.xlarge", "AvailabilityZone": "us-east-1a", "FrameworkAttributes": { "Ethereum": { "HttpEndpoint": "nd- rg3gm4u7hffhhhgjhhu7unpclu.ethereum.managedblockchain.us-east-1.amazonaws.com", "WebSocketEndpoint": "nd- rg3gm4u7hffhhhgjhhu7unpclu.wss.ethereum.managedblockchain.us-east-1.amazonaws.com" } }, "Status": "CREATING", "CreationDate": "2021-06-25T20:10:18.555000+00:00", "Tags": {}, "Arn": "arn:aws:managedblockchain:us-east-1:111122223333:nodes/nd- RG3GM4U7HFFHHHGJHHU7UNPCLU" } } Deleting a node When you delete an Ethereum node from AMB Access, all resources that are stored on that node are immediately deleted. The IAM principal (user or group) that you use must have permissions to delete nodes. For more information, see Performing all available actions for AMB Access Ethereum. To delete an Ethereum node using the AWS Management Console 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. If the console doesn't open to the Networks list, choose Networks from the navigation pane. 3. Choose the Name of the Ethereum network that the node belongs to from the list. 4. On the network details page, under Nodes, select the Node ID, and then choose Delete. To delete an Ethereum node using the AWS CLI Use the delete-node command to delete an Ethereum node. Replace the value of --network- id and --node-id as appropriate. Deleting a node 20 Amazon Managed Blockchain (AMB) Ethereum Developer Guide aws managedblockchain delete-node \ --network-id n-ethereum-mainnet \ --node-id nd-RG3GM4U7HFFHHHGJHHU7UNPCLU Deleting a node 21 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Using token based access to make Ethereum API calls to Ethereum nodes in Amazon Managed Blockchain (AMB) You can use Accessor tokens to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens that you create as a query parameter with the call. Important • If you prioritize security and auditability over convenience, use the SigV4 signing process instead. • You can access the Ethereum APIs using Signature Version 4 (SigV4) and token based access. However, if you choose to use token based access, then any security benefits that are provided by using SigV4 are negated. • Never embed Accessor tokens in user-facing applications. In the console, the Token accessors page displays a list of all the Accessor tokens that you can use to make Ethereum API calls to nodes in your AWS account from code on a client. There are separate endpoints for HTTP connections and WebSocket connections. To learn more about how to make Ethereum API calls using token based access with your Accessor tokens, see: • Using token based access to make JSON-RPC API calls to an Ethereum node. • Using token based access to make Consensus API calls to an Ethereum node. You can create and manage Accessor tokens using the AWS Management Console. You can also create and manage Accessor tokens using the following API operations: CreateAccessor, GetAccessor, ListAccessors, and DeleteAccessor. A BILLING_TOKEN is a property of the Accessor. This BillingToken property is used to track your Accessor and for billing Ethereum API requests made to Ethereum nodes in your AWS account. All API actions related to creating and managing Accessor tokens are also available through the AWS CLI and SDKs. 22 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Creating an Accessor token for token based access You can create an Accessor token and use it to make Ethereum API calls on any Ethereum node in your AWS account. Create an Accessor
amazon-managed-blockchain-ethereum-dev-009
amazon-managed-blockchain-ethereum-dev.pdf
9
the following API operations: CreateAccessor, GetAccessor, ListAccessors, and DeleteAccessor. A BILLING_TOKEN is a property of the Accessor. This BillingToken property is used to track your Accessor and for billing Ethereum API requests made to Ethereum nodes in your AWS account. All API actions related to creating and managing Accessor tokens are also available through the AWS CLI and SDKs. 22 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Creating an Accessor token for token based access You can create an Accessor token and use it to make Ethereum API calls on any Ethereum node in your AWS account. Create an Accessor token to access an Ethereum node using the AWS Management Console <result> AMB Access then provisions and configures the token for you. The length of this process depends on many variables. </result> 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. Choose Token accessors. 3. Choose Create accessor. 4. Choose a valid Ethereum blockchain Network. 5. Optional, add Tags for your Accessor. 6. Choose Create accessor to create a new Accessor token. Create an Accessor token to access an Ethereum node using the AWS CLI aws managedblockchain create-accessor --accessor-type BILLING_TOKEN --network-type ETHEREUM_MAINNET The previous command returns the AccessorId along with the BillingToken, as shown in the following example. { "AccessorId": "ac-NGQ6QNKXLNEBXD3UI6XFDIL3VA", "NetworkType": "ETHEREUM_MAINNET", "BillingToken": "jZlP8OUI-PcQSKINyX9euJJDC5-IcW9e-nm1NyKH3n" } The key element in the response is the BillingToken. You can use this property to make Ethereum API calls to your Ethereum nodes. Creating an Accessor token for token based access 23 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Note You can use BillingToken to make Ethereum API calls to all the nodes owned by the AWS account that created the Accessor token. Viewing an Accessor token details You can view the properties for each Accessor token that your AWS account owns. For example, you can view the Accessor ID or the Amazon Resource Name (ARN) of the Accessor. You can also view the status, the type, the creation date, and the BILLING_TOKEN. To view an Accessor token's information using the AWS Management Console <result> The token details page pops up. From this page, you can view the properties of the token including endpoints to use for Ethereum API calls on HTTP and WebSocket (JSON-RPC API only) connections, the status, and the unique identifier for the token. </result> 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. In the navigation pane, choose Token accessors. 3. Choose the Accessor ID of the token from the list. To view an Accessor token's information using the AWS CLI Run the following command to view the details of an Accessor token. Replace values of -- accessor-id with your Accessor ID. aws managedblockchain get-accessor --accessor-id ac-NGQ6QNKXLNEBXD3UI6XFDIL3VA The BillingToken and other key properties are returned as shown in the following example. { "Accessor": { "Id": "ac-NGQ6QNKXLNEBXD3UI6XFDIL3VA", Viewing an Accessor token details 24 Amazon Managed Blockchain (AMB) Ethereum Developer Guide "Type": "BILLING_TOKEN", "BillingToken": "jZlP8OUI-PcQSKINyX9euJJDC5-IcW9e-nm1NyKH3n", "Status": "AVAILABLE", "NetworkType": "ETHEREUM_MAINNET", "CreationDate": "2022-01-04T23:09:47.750Z", "Arn": "arn:aws:managedblockchain:us-east-1:251534485660:accessors/ac- NGQ6QNKXLNEBXD3UI6XFDIL3VA" } } Deleting an Accessor token When you delete an Accessor token, the token changes from the AVAILABLE to the PENDING_DELETION status. You can't use an Accessor token with the PENDING_DELETION status for WebSocket requests and HTTP requests. Note WebSocket connections that were initiated while the Accessor token was in AVAILABLE status might remain open for up to 2 hours after they expire. An Accessor token with the PENDING_DELETION status eventually becomes unavailable through GetAccessor calls. Within 48 hours, it also disappears from ListAccessor results. To delete an Accessor token using the AWS Management Console <result> You're returned to the Tokens accessors page with your deleted Accessor token. The page displays the PENDING_DELETION status. </result> 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. 3. In the navigation pane, choose Token accessors. Select the Accessor token that you want from the list. 4. Choose Delete. 5. Confirm your choice. Deleting an Accessor token 25 Amazon Managed Blockchain (AMB) Ethereum Developer Guide To delete an Accessor token using the AWS CLI The following example shows how to delete a token. Use the delete-accessor command to delete a token. Set the value of --accessor-id with your Accessor ID. Deleting an Accessor token using the AWS CLI aws managedblockchain delete-accessor --accessor-id ac-NGQ6QNKXLNEBXD3UI6XFDIL3VA If this command runs successfully, no messages are returned. Deleting an Accessor token 26 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Using Ethereum APIs with Amazon Managed Blockchain (AMB) Amazon Managed Blockchain (AMB) provides API operations for creating and managing token accessors, nodes, and networks for AMB Access Ethereum. For more information, see the AMB Access API Reference Guide . The following section provides a list and reference of the Ethereum (JSON-RPC and Consensus) API methods that Amazon Managed Blockchain (AMB) supports. It also includes code examples that implement API calls from clients using either HTTP or WebSocket (JSON-RPC
amazon-managed-blockchain-ethereum-dev-010
amazon-managed-blockchain-ethereum-dev.pdf
10
ac-NGQ6QNKXLNEBXD3UI6XFDIL3VA If this command runs successfully, no messages are returned. Deleting an Accessor token 26 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Using Ethereum APIs with Amazon Managed Blockchain (AMB) Amazon Managed Blockchain (AMB) provides API operations for creating and managing token accessors, nodes, and networks for AMB Access Ethereum. For more information, see the AMB Access API Reference Guide . The following section provides a list and reference of the Ethereum (JSON-RPC and Consensus) API methods that Amazon Managed Blockchain (AMB) supports. It also includes code examples that implement API calls from clients using either HTTP or WebSocket (JSON-RPC API only) connections. You use the Ethereum API from a client to query smart contract data and submit transactions to an Ethereum node on Amazon Managed Blockchain (AMB). You use the Ethereum Consensus API from a client to query the Beacon chain, its configuration, and the node health. For more information, see Viewing node details. Execution and consensus client support The Ethereum Merge transitioned the Ethereum blockchain to a proof-of-stake consensus, and it resulted in a new modular design for Ethereum. After the Merge, the original Ethereum stack forked into two distinct layers: the execution layer and the consensus layer. There are many different client implementations for both of these layers; however, Amazon Managed Blockchain (AMB) provides a fully managed Ethereum node that uses the GoEthereum (Geth) execution client and the Lighthouse consensus client. Topics • Supported JSON-RPC methods • Supported Consensus API methods Supported JSON-RPC methods Amazon Managed Blockchain (AMB) Access Ethereum supports the following Ethereum JSON-RPC API methods. Each supported API call has a brief description of its utility. Unique considerations for using the JSON-RPC method with an Ethereum node in Amazon Managed Blockchain (AMB) are indicated where applicable. Supported JSON-RPC methods 27 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Note • Ethereum API calls to an Ethereum node in Amazon Managed Blockchain (AMB) can be authenticated by using the Signature Version 4 (SigV4) signing process. This means that only authorized IAM principals in the AWS account that created the node can interact with it using the Ethereum APIs. AWS credentials (an access key ID and secret access key) must be provided with the call. • Token based access can also be used to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. If you prioritize security and auditability over convenience, use the SigV4 signing process instead. However, if you use token based access to make Ethereum APIs calls, any security benefits that are provided by using the SigV4 signing process is negated. • JSON-RPC batch requests aren't supported on Amazon Managed Blockchain (AMB) Access Ethereum. • WebSocket calls have a 512 KB payload quota. Some calls might exceed this quota and cause a "message response is too large" error. For this reason, we recommend you use HTTP for these requests instead of WebSocket connections. • If your HTTP response is larger than 5.9 MB, you will get an error. To correct this, you must set both compression headers as Accept: application/gzip and Accept- Encoding: gzip. The compressed response your client then receives contains the following headers: Content-Type: application/json and Content-Encoding: gzip. • For historic data that requires archival nodes, use Amazon Managed Blockchain (AMB) Query. For more information, see the AMB Query Developer Guide. Topics • Making JSON-RPC API calls to an Ethereum node in Amazon Managed Blockchain (AMB) The block identifier parameter Some methods have an extra block identifier parameter. The following options are possible values for this parameter: • A hexadecimal string value that represents an integer block number. Supported JSON-RPC methods 28 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • "earliest" – String for the genesis block. • "latest" – String for the latest mined block. • "pending" – String for the pending state transactions. Method debug_traceBlock debug_traceBlockByHash debug_traceBlockByNumber debug_traceCall Description Considerations Returns the full stack trace of Only data for the most recent all the invoked 128 blocks is opcodes for all supported. the transacti Archival data is not supported. ons that were included in the block provided as a parameter in RLP format. Returns the full stack trace of Only data for the most recent all the transacti 128 blocks is ons that were supported. included in a Archival data is specified block not supported. by its hash. Returns the full stack trace of all the transacti ons that were included in the specified block number. Only data for the most recent 128 blocks is supported. Archival data is not supported. Returns the full stack trace Only data for the most recent after running 128 blocks is Supported JSON-RPC methods 29 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method Description Considerations debug_traceTransaction eth_blockNumber eth_call supported. Archival data is not supported. an
amazon-managed-blockchain-ethereum-dev-011
amazon-managed-blockchain-ethereum-dev.pdf
11
for the most recent all the transacti 128 blocks is ons that were supported. included in a Archival data is specified block not supported. by its hash. Returns the full stack trace of all the transacti ons that were included in the specified block number. Only data for the most recent 128 blocks is supported. Archival data is not supported. Returns the full stack trace Only data for the most recent after running 128 blocks is Supported JSON-RPC methods 29 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method Description Considerations debug_traceTransaction eth_blockNumber eth_call supported. Archival data is not supported. an eth_call within the context of the given block execution. The method is also used to simulate the outcomes of transactions and supports custom tracers. Attempts to return all traces for a given transaction. Returns the number of the most recent block. Immediate ly runs a new eth_call consumes 0 message call gas, but has a without creating a transaction on the blockchain. gas parameter for messages that require it. Only data for the most recent 128 blocks is supported. Archival data is not supported. Supported JSON-RPC methods 30 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_chainId Description Considerations Returns an integer value for the currently configured Chain Id value that's introduce d in EIP-155. Returns None if no Chain Id is available. Supported JSON-RPC methods 31 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_createAccessList eth_estimateGas Description Considerations An accessLis t can be used to unstuck contracts that became inaccessi ble due to gas cost increases. This method creates an EIP2930 type accessList based on a given Transaction . The accessLis t contains all the storage slots and addresses read and written by the transacti on, except for the sender account and the precompil es. This method uses the same transacti on call object and blockNumb erOrTag object as eth_call. Estimates and returns the gas that's required for a transaction without adding the transaction to the blockchai n. Supported JSON-RPC methods 32 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_feeHistory eth_gasPrice eth_getBalance eth_getBlockByHash eth_getBlockByNumber eth_getBlockTransactionCountByHash Description Considerations Returns a collection of historical gas information. Returns the current price per gas in Wei. Returns the balance of an account for the specified Only data for the most recent 128 blocks is supported. account address Archival data is not supported. and block identifier. Returns information about the block specified using the block hash. Returns information about the block specified using the block number. Returns the number of transactions in the block specified using the block hash. Supported JSON-RPC methods 33 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method Description Considerations eth_getBlockTransactionCountByNumber eth_getCode eth_getFilterChanges Returns the number of transactions in the block specified using the block number. Returns the code at the specified Only data for the most recent account address 128 blocks is and block identifier. supported. Archival data is not supported. Polls the specified filter Filters are ephemeral. If ID, retuning an AMB Access array of logs needs to that occurred manage or since the last maintain node poll. instances for availability and performance, and an instance is replaced, filters might be deleted. We recommend that you write your application code to handle the occasiona l deletion of filters. Supported JSON-RPC methods 34 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_getFilterLogs Description Considerations Returns an array of all logs for Filters are ephemeral. If the specified AMB Access filter ID. needs to manage or maintain node instances for availability and performance, and an instance is replaced, filters might be deleted. We recommend that you write your application code to handle the occasiona l deletion of filters. Supported JSON-RPC methods 35 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_getLogs Description Considerations Returns an array of all logs for a Filters are ephemeral. If specified filter AMB Access needs to manage or maintain node instances for availability and performance, and an instance is replaced, filters might be deleted. We recommend that you write your application code to handle the occasiona l deletion of filters. object. Experimental – Returns the account and storage values of the specified account, including the Merkle proof. eth_getProof Supported JSON-RPC methods 36 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_getStorageAt Description Considerations Returns the value of the Only data for the most recent specified storage 128 blocks is position for supported. the specified Archival data is account address not supported. eth_getTransactionByBlockHashAndIndex eth_getTransactionByBlockNumberAndIndex eth_getTransactionByHash and block identifier. Returns information about a transacti on using the specified block hash and transaction index position. Returns information about a transacti on using the specified block number and transaction index position. Returns information about the transaction with the specified transaction hash. Supported JSON-RPC methods 37 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method Description Considerations eth_getTransactionCount eth_getTransactionReceipt eth_getUncleByBlockHashAndIndex eth_getUncleByBlockNumberAndIndex
amazon-managed-blockchain-ethereum-dev-012
amazon-managed-blockchain-ethereum-dev.pdf
12
(AMB) Ethereum Developer Guide Method eth_getStorageAt Description Considerations Returns the value of the Only data for the most recent specified storage 128 blocks is position for supported. the specified Archival data is account address not supported. eth_getTransactionByBlockHashAndIndex eth_getTransactionByBlockNumberAndIndex eth_getTransactionByHash and block identifier. Returns information about a transacti on using the specified block hash and transaction index position. Returns information about a transacti on using the specified block number and transaction index position. Returns information about the transaction with the specified transaction hash. Supported JSON-RPC methods 37 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method Description Considerations eth_getTransactionCount eth_getTransactionReceipt eth_getUncleByBlockHashAndIndex eth_getUncleByBlockNumberAndIndex Returns the number of transactions sent from the specified address and block identifier. Returns the receipt of the transacti on using the specified transaction hash. Returns information about the uncle block specified using the block hash and uncle index position. Returns information about the uncle block specified using the block number and uncle index position. Supported JSON-RPC methods 38 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method Description Considerations eth_getUncleCountByBlockHash eth_getUncleCountByBlockNumber eth_getWork eth_maxPriorityFeePerGas Returns the number of counts in the uncle specified using the uncle hash. Returns the number of counts in the uncle specified using the uncle number. Returns the hash of the current block, the seedHash, and the boundary condition (also called the "target") to be met. Returns the fee per gas that's an estimate of how much you can pay as a priority fee, or "tip," to get a transaction included in the current block. Generally you use the value that's returned from this method to set the maxFeePer Gas in the subsequent transaction that you're submittin g. Supported JSON-RPC methods 39 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_newBlockFilter eth_newFilter eth_newPendingTransactionFilter Description Considerations Creates a filter in the node to notify when a new block arrives. Use eth_getFi lterChang es to check for state changes. Creates a filter object with the specified filter options (such as from block, to block, contract address, or topics). Creates a filter in the node to notify when new pending transactions arrive. Use <code>eth _getFilte rChanges< /code> to check for state changes. Supported JSON-RPC methods 40 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_protocolVersion eth_sendRawTransaction eth_subscribe Description Considerations Returns the current Ethereum protocol version. Creates a new message call transaction AMB Access supports raw transactions or a contract only. You must creation for create and sign signed transacti transactions ons. before sending them. For more information, see How to create raw transactions in Ethereum. Experimental for publicati Available only when using on subscript WebSocket ion – Creates a connections. subscription for Subscriptions specified events are coupled to and returns a each connectio subscription ID. n. When the connection closes, the subscription is removed. Supported JSON-RPC methods 41 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method eth_syncing eth_uninstallFilter eth_unsubscribe net_listening net_peerCount net_version Description Considerations Returns an object with sync status data or false when not syncing. Uninstalls the filter with the specified filter ID. Experimental for publicati on subscript ion – Cancels the subscript ion with the specified subscription ID. Returns true if the client is actively listening for network connections. Returns the number of peers currently connected to the client. Returns the current network ID. Supported JSON-RPC methods 42 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method txpool_inspect txpool_status web3_clientVersion web3_sha3 Description Considerations Lists a textual summary of all the transacti ons that are currently pending inclusion in the next blocks, and those that are queued (being scheduled for future execution only). Provides a count of all transacti ons currently pending inclusion in the next blocks, and those that are queued (being scheduled for future execution only). Returns the current client version. Returns Keccak-256 (not the standardized SHA3-256) of the given data. Supported JSON-RPC methods 43 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Making JSON-RPC API calls to an Ethereum node in Amazon Managed Blockchain (AMB) The following examples demonstrate ways to make Ethereum JSON-RPC API calls to an Ethereum node in Amazon Managed Blockchain (AMB). Topics • Using Signature Version 4 to make JSON-RPC API calls to an Ethereum node • Using token based access to make JSON-RPC API calls to an Ethereum node Using Signature Version 4 to make JSON-RPC API calls to an Ethereum node The following sections demonstrate ways to make JSON-RPC API calls to an Ethereum node on Amazon Managed Blockchain (AMB) using the Signature Version 4 signing process. Important The Signature Version 4 signing process requires the credentials that are associated with an AWS account. Some examples in this section export these sensitive credentials to the shell environment of the client. Only use these examples on a client that run in a trusted context. Do not use these examples in an untrusted context, such as in a web browser or mobile app. Never
amazon-managed-blockchain-ethereum-dev-013
amazon-managed-blockchain-ethereum-dev.pdf
13
to make JSON-RPC API calls to an Ethereum node The following sections demonstrate ways to make JSON-RPC API calls to an Ethereum node on Amazon Managed Blockchain (AMB) using the Signature Version 4 signing process. Important The Signature Version 4 signing process requires the credentials that are associated with an AWS account. Some examples in this section export these sensitive credentials to the shell environment of the client. Only use these examples on a client that run in a trusted context. Do not use these examples in an untrusted context, such as in a web browser or mobile app. Never embed client credentials in user-facing applications. To expose an Ethereum node in AMB Access to anonymous users visiting from trusted web domains, you can set up a separate endpoint in Amazon API Gateway that's backed by a Lambda function that forwards requests to your node using the proper IAM credentials. Topics • Endpoint format for making JSON-RPC API calls over WebSocket and HTTP connections using Signature Version 4 • Using web3.js to make JSON-RPC API calls • Making JSON-RPC API call using AWS SDK for JavaScript with a WebSocket connection to an Ethereum node in Amazon Managed Blockchain (AMB) • Making JSON-RPC API calls using awscurl over HTTP Examples using the JSON-RPC API 44 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Endpoint format for making JSON-RPC API calls over WebSocket and HTTP connections using Signature Version 4 Example An Ethereum node created using AMB Access Ethereum hosts one endpoint for WebSocket connections and another for HTTP connections. These endpoints conform to the following patterns. Note The node ID is case sensitive and must be lowercase where indicated, or a signature mismatch error occurs. WebSocket endpoint format wss://your-node-id-lowercase.wss.ethereum.managedblockchain.us-east-1.amazonaws.com/ For example: wss:// nd-6eaj5va43jggnpxouzp7y47e4y.wss.ethereum.managedblockchain.us- east-1.amazonaws.com/ HTTP endpoint format https://your-node-id-lowercase.ethereum.managedblockchain.us-east-1.amazonaws.com/ For example, https:// nd-6eaj5va43jggnpxouzp7y47e4y.ethereum.managedblockchain.us- east-1.amazonaws.com/ Using web3.js to make JSON-RPC API calls Web3.js is a popular collection of JavaScript libraries available using the Node package manager (npm). You can run the following examples to send a JSON-RPC API call to Ethereum using a Javascript file for Node.js. The examples demonstrate an HTTP connection and a WebSocket connection to an Ethereum node. Examples using the JSON-RPC API 45 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Both HTTP and WebSocket connection types rely on a local connection provider library to open the Signature Version 4 authenticated connection to the Ethereum node. You install the provider for the connection locally by copying the source code to a file on your client. Then, reference the library files in the script that makes the Ethereum API call. Prerequisites Example Running the example scripts requires the following prerequisites. Prerequisites for both HTTP and WebSocket connections are included. 1. You must have node version manager (nvm) and Node.js installed on your machine. If you use an Amazon EC2 instance as your Ethereum client, see Tutorial: Setting Up Node.js on an Amazon EC2 Instance for more information. 2. Type node --version and verify that you are using Node version 14 or later. If necessary, you can use the nvm install 14 command followed by the nvm use 14 command to install version 14. 3. The environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY must contain the credentials that are associated with the same AWS account that created the node. The environment variables AMB_HTTP_ENDPOINT and AMB_WS_ENDPOINT must contain your Ethereum node's HTTP and WebSocket endpoints respectively. Export these variables as strings on your client using the following commands. Replace the values with appropriate values from your IAM user account. export AWS_ACCESS_KEY_ID="AKIAIOSFODNN7EXAMPLE" export AWS_SECRET_ACCESS_KEY="wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY" export AMB_HTTP_ENDPOINT="https:// nd-6eaj5va43jggnpxouzp7y47e4y.ethereum.managedblockchain.us-east-1.amazonaws.com/" export AMB_WS_ENDPOINT="wss:// nd-6eaj5va43jggnpxouzp7y47e4y.wss.ethereum.managedblockchain.us- east-1.amazonaws.com/" Examples using the JSON-RPC API 46 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Example To make an Ethereum API call using web3.js over HTTP to your Ethereum node in the AMB Access 1. This example script uses the ECMAScript (ES) module. Therefore, add the "type": "module" line to your package.json file. The example package.json snippet that follows shows the contents required to successfully run this example. { "type": "module", "dependencies": { "@aws-crypto/sha256-js": "^4.0.0", "@aws-sdk/credential-providers": "^3.352.0", "@aws-sdk/fetch-http-handler": "^3.353.0", "@aws-sdk/protocol-http": "^3.347.0", "@aws-sdk/signature-v4": "^3.347.0", "@aws-sdk/types": "^3.347.0", "web3": "^1.10.0", "xhr2": "^0.2.1" } } 2. Use node package manager (npm) to install the requisite dependencies. npm install 3. Copy the contents of the example that follows, and then use your preferred text editor to save it to a file that's named awsHttpSigV4-v2.js on your client machine in the same directory where you run your script. Contents of awsHttpSigV4-v2.js ///////////////////////////////////////////////////// // Authored by Rafia Tapia // Senior Blockchain Solutions Architect, AWS // licensed under GNU Lesser General Public License // https://github.com/ethereum/web3.js ///////////////////////////////////////////////////// import HttpProvider from 'web3-providers-http'; import XHR2 from 'xhr2'; import { fromEnv} from '@aws-sdk/credential-providers'; Examples using the JSON-RPC API 47 Amazon Managed Blockchain (AMB) Ethereum Developer Guide import sigv4 from '@aws-sdk/signature-v4'; import http from '@aws-sdk/protocol-http'; import crypto from "@aws-crypto/sha256-js"; export default
amazon-managed-blockchain-ethereum-dev-014
amazon-managed-blockchain-ethereum-dev.pdf
14
of the example that follows, and then use your preferred text editor to save it to a file that's named awsHttpSigV4-v2.js on your client machine in the same directory where you run your script. Contents of awsHttpSigV4-v2.js ///////////////////////////////////////////////////// // Authored by Rafia Tapia // Senior Blockchain Solutions Architect, AWS // licensed under GNU Lesser General Public License // https://github.com/ethereum/web3.js ///////////////////////////////////////////////////// import HttpProvider from 'web3-providers-http'; import XHR2 from 'xhr2'; import { fromEnv} from '@aws-sdk/credential-providers'; Examples using the JSON-RPC API 47 Amazon Managed Blockchain (AMB) Ethereum Developer Guide import sigv4 from '@aws-sdk/signature-v4'; import http from '@aws-sdk/protocol-http'; import crypto from "@aws-crypto/sha256-js"; export default class AWSHttpSigV4_v2Provider extends HttpProvider { constructor(connectionStr) { super(connectionStr); } send(payload, callback) { const self = this; /* ******************** XHR2 *************************** */ const request = new XHR2(); // eslint-disable-line request.timeout = self.timeout; request.open('POST', self.host, true); request.setRequestHeader('Content-Type', 'application/json'); request.onreadystatechange = () => { if (request.readyState === 4 && request.timeout !== 1) { let result = request.responseText; // eslint-disable-line let error = null; // eslint-disable-line try { result = JSON.parse(result); } catch (jsonError) { let message; if (!!result && !!result.error && !!result.error.message) { message = `[aws-ethjs-provider-http] ${result.error.message}`; } else { message = `[aws-ethjs-provider-http] Invalid JSON RPC response from host provider ${self.host}: ` + `${JSON.stringify(result, null, 2)}`; } error = new Error(message); } self.connected = true; callback(error, result); } }; request.ontimeout = () => { self.connected = false; callback(`[aws-ethjs-provider-http] CONNECTION TIMEOUT: http request timeout after ${self.timeout} ` + `ms. (i.e. your connect has timed out for whatever reason, check your provider).`, null); }; /* ******************** END XHR2 *************************** */ const strPayload = JSON.stringify(payload); Examples using the JSON-RPC API 48 Amazon Managed Blockchain (AMB) Ethereum Developer Guide const region = process.env.AWS_DEFAULT_REGION || 'us-east-1'; try { const urlparser=new URL(self.host) let signerV4 = new sigv4.SignatureV4({ credentials: fromEnv(), region: region, service: "managedblockchain", sha256: crypto.Sha256 }); let requestOptions={ protocol:urlparser.protocol, hostname:urlparser.hostname, method: 'POST', body:strPayload, headers:{'host':urlparser.host}, path:urlparser.pathname } const newReq = new http.HttpRequest(requestOptions); signerV4.sign(newReq,{signingDate:new Date(),}).then(signedHttpRequest => { request.setRequestHeader('authorization', signedHttpRequest.headers['authorization']); request.setRequestHeader('x-amz-date', signedHttpRequest.headers['x-amz- date']); request.setRequestHeader('x-amz-content-sha256', signedHttpRequest.headers['x-amz-content-sha256']); request.send(strPayload); }).catch(sigError => { console.log(sigError); }); } catch (error) { callback(`[aws-ethjs-provider-http] CONNECTION ERROR: Couldn't connect to node '${self.host}': ` + `${JSON.stringify(error, null, 2)}`, null); } } } 4. Copy the contents of the following example, and then use your preferred text editor to save it to a file that's named web3-example-http.js in the same directory where you saved the provider from the previous step. The example script runs the getNodeInfo Ethereum method. You can modify the script to include other methods and their parameters. Contents of web3-example-http.js import AWSHttpSigV4_v2Provider from './awsHttpSigV4-v2.js'; const endpoint = process.env.AMB_HTTP_ENDPOINT const web3 = new Web3(new AWSHttpSigV4_v2Provider(endpoint)); Examples using the JSON-RPC API 49 Amazon Managed Blockchain (AMB) Ethereum Developer Guide web3.eth.getNodeInfo().then(console.log); 5. Run the script to call the Ethereum API method over HTTP on your Ethereum node. node web3-example-http.js The output is similar to the following. Geth/v1.9.24-stable-cc05b050/linux-amd64/go1.15.5 To make an Ethereum API call using web3.js over WebSocket to your Ethereum node in the AMB Access 1. The following example package.json snippet that follows shows the dependencies required to successfully run the example. "@aws-sdk/credential-providers": "^3.352.0", "@aws-sdk/fetch-http-handler": "^3.353.0", "@aws-sdk/protocol-http": "^3.347.0", "@aws-sdk/signature-v4": "^3.347.0", "@aws-sdk/types": "^3.347.0", "web3": "^1.10.0", "websocket": "^1.0.34"1*" 2. Use node package manager (npm) to install the requisite dependencies. npm install 3. Copy the contents of the example that follows, and then use a text editor of your choosing to save it to a file that's named web3-example-ws.js in the same directory on your client where you run your script. Contents of web3-example-ws.js // Authored by Rafia Tapia // Senior Blockchain Solutions Architect, AWS // licensed under GNU Lesser General Public License // https://github.com/ethereum/web3.js ///////////////////////////////////////////////////// Examples using the JSON-RPC API 50 Amazon Managed Blockchain (AMB) Ethereum Developer Guide import Web3 from 'web3'; import WebsocketProvider from 'web3-providers-ws'; import { fromEnv } from '@aws-sdk/credential-providers'; import sigv4 from '@aws-sdk/signature-v4'; import http from '@aws-sdk/protocol-http'; import crypto from "@aws-crypto/sha256-js"; const endpoint = process.env.AMB_WS_ENDPOINT const region = process.env.AWS_DEFAULT_REGION || 'us-east-1'; const urlparser = new URL(endpoint); let signerV4 = new sigv4.SignatureV4({ credentials: fromEnv(), region: region, service: "managedblockchain", sha256: crypto.Sha256 }); let reqOptions = { protocol: "HTTPS", hostname: urlparser.hostname, method: 'GET', body: "", headers: { 'host': urlparser.host }, path: urlparser.pathname }; const newReq = new http.HttpRequest(reqOptions); signerV4.sign(newReq, { signingDate: new Date(), }).then(signedHttpRequest => { const options = { headers: { 'Authorization': signedHttpRequest.headers['authorization'], "X-Amz-Date": signedHttpRequest.headers['x-amz-date'], "X-Amz-Content-Sha256": signedHttpRequest.headers['x-amz-content- sha256'], 'host':signedHttpRequest.headers['host'] } }; const web3 = new Web3(new WebsocketProvider(endpoint, options)); web3.eth.getNodeInfo().then(console.log).then(() => { web3.currentProvider.connection.close(); }); }).catch(sigError => { console.log(sigError); }) 4. Run the script to call the Ethereum API method over WebSocket on your Ethereum node. Examples using the JSON-RPC API 51 Amazon Managed Blockchain (AMB) Ethereum Developer Guide node web3-example-ws.js The output is similar to following. Geth/v1.9.24-stable-cc05b050/linux-amd64/go1.15.5 Making JSON-RPC API call using AWS SDK for JavaScript with a WebSocket connection to an Ethereum node in Amazon Managed Blockchain (AMB) The following example uses a JavaScript file for Node.js to open a WebSocket connection to the
amazon-managed-blockchain-ethereum-dev-015
amazon-managed-blockchain-ethereum-dev.pdf
15
signedHttpRequest.headers['x-amz-date'], "X-Amz-Content-Sha256": signedHttpRequest.headers['x-amz-content- sha256'], 'host':signedHttpRequest.headers['host'] } }; const web3 = new Web3(new WebsocketProvider(endpoint, options)); web3.eth.getNodeInfo().then(console.log).then(() => { web3.currentProvider.connection.close(); }); }).catch(sigError => { console.log(sigError); }) 4. Run the script to call the Ethereum API method over WebSocket on your Ethereum node. Examples using the JSON-RPC API 51 Amazon Managed Blockchain (AMB) Ethereum Developer Guide node web3-example-ws.js The output is similar to following. Geth/v1.9.24-stable-cc05b050/linux-amd64/go1.15.5 Making JSON-RPC API call using AWS SDK for JavaScript with a WebSocket connection to an Ethereum node in Amazon Managed Blockchain (AMB) The following example uses a JavaScript file for Node.js to open a WebSocket connection to the Ethereum node endpoint in AMB Access and sends an Ethereum JSON-RPC API call. Running the example script requires the following: • Node.js is installed on your machine. If you are using an Amazon EC2 instance, see Tutorial: Setting Up Node.js on an Amazon EC2 Instance. • The following example package.json snippet that follows shows the dependencies required to successfully run the example. "@aws-sdk/credential-providers": "^3.352.0", "@aws-sdk/fetch-http-handler": "^3.353.0", "@aws-sdk/protocol-http": "^3.347.0", "@aws-sdk/signature-v4": "^3.347.0", "@aws-sdk/types": "^3.347.0", "web3": "^1.10.0", "websocket-client": "^1.0.0", "ws": "^8.14.2" • Use node package manager (npm) to install the requisite dependencies. Example To make an Ethereum API call over WebSocket to your Ethereum node on AMB Access 1. Copy the contents of the following script and save it to a file on your machine (for example, ws-ethereum-example.js). The example calls the Ethereum JSON-RPC method eth_subscribe along with the newHeads parameter. You can replace this method and its parameters with any method that's listed in Supported JSON-RPC methods. Examples using the JSON-RPC API 52 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Contents of ws-ethereum-example.js // Authored by Rafia Tapia // Senior Blockchain Solutions Architect, AWS // licensed under GNU Lesser General Public License // https://github.com/ethereum/web3.js ///////////////////////////////////////////////////// import Web3 from 'web3'; import { fromEnv } from '@aws-sdk/credential-providers'; import sigv4 from '@aws-sdk/signature-v4'; import http from '@aws-sdk/protocol-http'; import crypto from "@aws-crypto/sha256-js"; import WebSocket from 'ws'; const endpoint = process.env.AMB_WS_ENDPOINT const region = process.env.AWS_DEFAULT_REGION || 'us-east-1'; const urlparser = new URL(endpoint); let signerV4 = new sigv4.SignatureV4({ credentials: fromEnv(), region: region, service: "managedblockchain", sha256: crypto.Sha256 }); let reqOptions = { protocol: "HTTPS", hostname: urlparser.hostname, method: 'GET', body: "", headers: { 'host': urlparser.host }, path: urlparser.pathname }; const newReq = new http.HttpRequest(reqOptions); signerV4.sign(newReq, { signingDate: new Date(), }).then(signedHttpRequest => { let payload = { jsonrpc: '2.0', method: 'eth_subscribe', params: ["newHeads"], id: 67 } const ws = new WebSocket(endpoint, { headers: signedHttpRequest.headers }); ws.onopen = async () => { ws.send(JSON.stringify(payload)); console.log('Sent request'); } ws.onerror = (error) => { Examples using the JSON-RPC API 53 Amazon Managed Blockchain (AMB) Ethereum Developer Guide console.error(`WebSocket error: ${error.message}`) } ws.onmessage = (e) => { console.log(e.data) } }).catch(sigError => { console.log(sigError); }) 2. Run the following command to call the Ethereum API method over WebSocket on your Ethereum node. node ws-ethereum-example.js The eth_subscribe method with the newHeads parameter generates a notification each time a new header is appended to the chain. Output is similar to the following example. The WebSocket connection remains open and additional notifications appear until you cancel the command. sent request {"id":67,"jsonrpc":"2.0","result":"0xabcd123456789efg0h123ijk45l6m7n8"} Making JSON-RPC API calls using awscurl over HTTP Example The example that follows uses awscurl, which sends a signed HTTP request based on the current credentials you have set for the AWS CLI. If you construct your own HTTP requests, see Signing AWS requests with Signature Version 4 in the AWS General Reference. Replace your-node-id-lowercase with the ID of a node in your account (for example, nd-6eaj5va43jggnpxouzp7y47e4y). The example calls the web3_clientVersion method, which takes an empty parameter block. You can replace this method and its parameters with any method that's listed in Supported JSON-RPC methods. awscurl --service managedblockchain \ -X POST -d '{"jsonrpc": "2.0", "method": "web3_clientVersion", "params": [], "id": 67}' \ https://your-node-id-lowercase.ethereum.managedblockchain.us-east-1.amazonaws.com Examples using the JSON-RPC API 54 Amazon Managed Blockchain (AMB) Ethereum Developer Guide The command returns output similar to the following. {"jsonrpc":"2.0","id":67,"result":"Geth/v1.9.22-stable-c71a7e26/linux-amd64/go1.15.5"} Using token based access to make JSON-RPC API calls to an Ethereum node You can use Accessor tokens to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens that you create as a query parameter with the call. For more information on creating and managing Accessor tokens, see the topic on Using token based access. Important • If you prioritize security and auditability over convenience, use the SigV4 signing process instead. • You can access the Ethereum APIs using Signature Version 4 (SigV4) and token based access. However, if you choose to use token based access, then any security benefits that are provided by using SigV4 are negated. • Never embed Accessor tokens in user-facing applications. The following examples demonstrate ways to make Ethereum JSON-RPC API calls to an Ethereum node on Amazon
amazon-managed-blockchain-ethereum-dev-016
amazon-managed-blockchain-ethereum-dev.pdf
16
query parameter with the call. For more information on creating and managing Accessor tokens, see the topic on Using token based access. Important • If you prioritize security and auditability over convenience, use the SigV4 signing process instead. • You can access the Ethereum APIs using Signature Version 4 (SigV4) and token based access. However, if you choose to use token based access, then any security benefits that are provided by using SigV4 are negated. • Never embed Accessor tokens in user-facing applications. The following examples demonstrate ways to make Ethereum JSON-RPC API calls to an Ethereum node on Amazon Managed Blockchain (AMB) using token based access. Topics • Endpoint format for WebSocket and HTTP connections using token based access • Using wscat to connect and JSON-RPC API calls to your Ethereum node over WebSocket connection using token based access • Using awscurl to make JSON-RPC API calls to your Ethereum node over HTTP using token based access Endpoint format for WebSocket and HTTP connections using token based access Example Each Ethereum node hosts one endpoint for WebSocket connections and another for HTTP connections. For token based access, these endpoints conform to the following patterns: Examples using the JSON-RPC API 55 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Note The node ID is case sensitive and must be lowercase where indicated, or a signature mismatch error occurs. WebSocket endpoint format wss://your-node-id-lowercase.wss.t.ethereum.managedblockchain.us-east-1.amazonaws.com? billingtoken=your-billing-token For example, nd-6eaj5va43jggnpxouzp7y47e4y.wss.t.ethereum.managedblockchain.us- east-1.amazonaws.com?billingtoken=n-MWY63ZJZU5HGNCMBQER7IN6OIU HTTP endpoint format https://your-node-id-lowercase.t.ethereum.managedblockchain.us-east-1.amazonaws.com? billingtoken=your-billing-token For example, https:// nd-6eaj5va43jggnpxouzp7y47e4y.t.ethereum.managedblockchain.us- east-1.amazonaws.com?billingtoken=n-MWY63ZJZU5HGNCMBQER7IN6OIU Using wscat to connect and JSON-RPC API calls to your Ethereum node over WebSocket connection using token based access Example This section describes how you can use a third party utility, wscat, to connect to your node using a token. After installing wscat, use the following command to open a WebSocket connection to your ethereum node. wscat --connect wss://your-node-id.wss.t.ethereum.managedblockchain.us- east-1.amazonaws.com?billingtoken=your-billing-token This opens an active WebSocket connection to your node as shown in the following example response: Examples using the JSON-RPC API 56 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Connected (press CTRL+C to quit) > JSON-RPC calls can now be executed as follows, {"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id": 1} A reply should arrive back with the same id. > {"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id": 1} < {"jsonrpc":"2.0","id":1,"result":"0x9798e5 For subscriptions, calls can be executed in the following format, > {"jsonrpc":"2.0","method":"eth_subscribe","params":["newHeads"],"id": 1} < {"id":1,"jsonrpc":"2.0","result":"0x4742411a16a232389a5877d4184e57b9"} You should continuously get subscription messages that correspond to new blocks roughly every 15 seconds. To stop the messages, unsubscribe by using the subscription ID from the initial response. > {"jsonrpc":"2.0","method":"eth_unsubscribe","params": ["0x4742411a16a232389a5877d4184e57b9"],"id": 1} < {"id":1,"jsonrpc":"2.0","result":true} Using awscurl to make JSON-RPC API calls to your Ethereum node over HTTP using token based access Example The following example uses awscurl, which sends a signed HTTP request based on the credentials that you set for the AWS CLI. awscurl -X POST -d '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id": 1}' 'https://your-node-id.t.ethereum.managedblockchain.us-east-1.amazonaws.com? billingtoken=your-billing-token' Example Reply (Contents may differ): Examples using the JSON-RPC API 57 Amazon Managed Blockchain (AMB) Ethereum Developer Guide {"jsonrpc":"2.0","id":1,"result":"0x9798d2"} Supported Consensus API methods Amazon Managed Blockchain (AMB) Access Ethereum supports the following Ethereum Consensus API methods. Each supported API has a brief description of its utility. Unique considerations for using the Consensus method with an Ethereum node in Amazon Managed Blockchain (AMB) are indicated where applicable. Note • The Consensus API doesn't support WebSocket connections. • Any methods that aren't listed are not supported. • Ethereum API calls to an Ethereum node in Amazon Managed Blockchain (AMB) can be authenticated by using the Signature Version 4 (SigV4) signing process. This means that only authorized IAM principals in the AWS account that created the node can interact with it using the Ethereum APIs. AWS credentials (an access key ID and secret access key) must be provided with the call. • Token based access can also be used to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. If you prioritize security and auditability over convenience, use the SigV4 signing process instead. However, if you use token based access to make Ethereum APIs calls, any security benefits that are provided by using the SigV4 signing process is negated. Topics • Making Consensus API calls to an Ethereum node in Amazon Managed Blockchain (AMB) State related APIs are supported only for the following states: • /eth/v1/beacon/states/head • /eth/v1/beacon/states/finalized • /eth/v1/beacon/states/justified • /eth/v1/beacon/states/genesis Supported Consensus API methods 58 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method /eth/v1/beacon/genesis /eth/v1/beacon/states/{state_id}/root /eth/v1/beacon/states/{state_id}/fork /eth/v1/beacon/states/{state_id}/finality_che ckpoints /eth/v1/beacon/states/{state_id}/committees /eth/v1/beacon/headers Description Returns the details of the chain's genesis block. Calculates the HashTreeRoot for the state with a given state_id. If the state_id is root, the same value will be returned. Gets the fork object for the requested state_id. Returns the finality checkpoints for a state with a given state_id. In case finality is not yet achieved, the checkpoint returns epoch 0 and ZERO_HASH as root. Returns the
amazon-managed-blockchain-ethereum-dev-017
amazon-managed-blockchain-ethereum-dev.pdf
17
only for the following states: • /eth/v1/beacon/states/head • /eth/v1/beacon/states/finalized • /eth/v1/beacon/states/justified • /eth/v1/beacon/states/genesis Supported Consensus API methods 58 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method /eth/v1/beacon/genesis /eth/v1/beacon/states/{state_id}/root /eth/v1/beacon/states/{state_id}/fork /eth/v1/beacon/states/{state_id}/finality_che ckpoints /eth/v1/beacon/states/{state_id}/committees /eth/v1/beacon/headers Description Returns the details of the chain's genesis block. Calculates the HashTreeRoot for the state with a given state_id. If the state_id is root, the same value will be returned. Gets the fork object for the requested state_id. Returns the finality checkpoints for a state with a given state_id. In case finality is not yet achieved, the checkpoint returns epoch 0 and ZERO_HASH as root. Returns the committees for a given state_id. Returns the block headers matching a given query. Supported Consensus API methods 59 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method /eth/v1/beacon/headers/headers/{block_id} /eth/v2/beacon/blocks/{block_id} /eth/v1/beacon/blocks/{block_id}/root /eth/v1/beacon/blocks/{block_id}/attestations /eth/v1/config/fork_schedule /eth/v1/config/spec /eth/v1/config/deposit_contract /eth/v2/debug/beacon/heads Description Returns the block header for a given block_id. Returns the block details for a given block_id. Returns the hashTreeRoot of a BeaconBlock/Beacon BlockHeader for a given block_id. Returns the attestati ons of a block using its block_id. Returns all the forks; past, present, and future, of which this node is aware. Returns the configura tion specification used for this node. Returns the Eth1 deposit contract address and chain ID. Returns all the possible chain heads (leaves of the fork choice tree). Supported Consensus API methods 60 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Method /eth/v1/node/identity /eth/v1/node/peers /eth/v1/node/peers/{peer_id} /eth/v1/node/peer_count /eth/v1/node/version /eth/v1/node/syncing /eth/v1/node/health Description Returns data about the node's network presence. Returns data about the node's network peers. Returns data about a peer given the peer_id. Returns the number of known peers. Requests the Beacon node identify information about its implementation in a format similar to a HTTP User-Agent field. Requests the Beacon node to describe if it's currently syncing, and if it's, what block it's up to. Returns the Beacon node's health status in HTTP status codes. This is useful information for load balancers. Supported Consensus API methods 61 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Making Consensus API calls to an Ethereum node in Amazon Managed Blockchain (AMB) The following examples demonstrate ways to make Ethereum Consensus API calls to an Ethereum node in Amazon Managed Blockchain (AMB). Topics • Using Consensus API calls signed using Signature Version 4 to an Ethereum node • Using token based access to make Consensus API calls to an Ethereum node Using Consensus API calls signed using Signature Version 4 to an Ethereum node The following sections demonstrate ways to make Consensus API calls to an Ethereum node on Amazon Managed Blockchain (AMB) using the Signature Version 4 signing process. Important The Signature Version 4 signing process requires the credentials that are associated with an AWS account. Some examples in this section export these sensitive credentials to the shell environment of the client. Only use these examples on a client that run in a trusted context. Do not use these examples in an untrusted context, such as in a web browser or mobile app. Never embed client credentials in user-facing applications. To expose an Ethereum node in AMB Access to anonymous users visiting from trusted web domains, you can set up a separate endpoint in Amazon API Gateway that are backed by a Lambda function that forwards requests to your node using the proper IAM credentials. Topics • Endpoint format for making Consensus API calls over HTTP • Making Consensus API calls using AWS SDK for JavaScript over HTTP • Using awscurl to make Consensus API calls over HTTP Endpoint format for making Consensus API calls over HTTP An Ethereum node that's created using AMB Access Ethereum hosts one endpoint for HTTP connections. This endpoint conforms to the following patterns. Examples making Consensus API calls 62 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Note The node ID is case sensitive and must be lowercase where indicated, or a signature mismatch error occurs. HTTP endpoint format https://your-node-id-lowercase.ethereum.managedblockchain.us- east-1.amazonaws.com/<followed by HTTP path of the Consensus API> For example: https://nd-6eaj5va43jggnpxouzp7y47e4y.ethereum.managedblockchain.us- east-1.amazonaws.com/eth/v1/beacon/genesis Making Consensus API calls using AWS SDK for JavaScript over HTTP The following example uses a JavaScript file for Node.js to make Consensus API calls by sending HTTP requests to the Ethereum node endpoint in Amazon Managed Blockchain (AMB). Running the example script requires the following: • Node.js is installed on your machine. If you use an Amazon EC2 instance, see Tutorial: Setting Up Node.js on an Amazon EC2 Instance. • The Node package manager (npm) is used to install the AWS SDK for JavaScript. The script uses classes from these packages. npm install aws-sdk • The environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY must contain the credentials that are associated with the same account that created the node. Otherwise, the alternative is that the ~/.aws/credentials file is populated. Example — Make a Consensus API call using AWS SDK for JavaScript with an
amazon-managed-blockchain-ethereum-dev-018
amazon-managed-blockchain-ethereum-dev.pdf
18
example script requires the following: • Node.js is installed on your machine. If you use an Amazon EC2 instance, see Tutorial: Setting Up Node.js on an Amazon EC2 Instance. • The Node package manager (npm) is used to install the AWS SDK for JavaScript. The script uses classes from these packages. npm install aws-sdk • The environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY must contain the credentials that are associated with the same account that created the node. Otherwise, the alternative is that the ~/.aws/credentials file is populated. Example — Make a Consensus API call using AWS SDK for JavaScript with an HTTP connection to an Ethereum node in Amazon Managed Blockchain (AMB) 1. Copy the contents of the script that follows and save it to a file on your machine (for example, consensus-ethereum-example.js). Examples making Consensus API calls 63 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Contents of consensus-ethereum-example.js const AWS = require('aws-sdk'); const REGION = process.env.AWS_DEFAULT_REGION || 'us-east-1'; async function signedManagedBlockchainRequest(endpoint, credentials, host) { const awsRequest = new AWS.HttpRequest(new AWS.Endpoint(endpoint), REGION); awsRequest.method = 'GET'; awsRequest.headers['host'] = host; const signer = new AWS.Signers.V4(awsRequest, 'managedblockchain'); signer.addAuthorization(credentials, new Date()); return awsRequest } /** * Sends Consensus API requests to AMB Ethereum node. * @param {*} nodeId - Node ID * @param {*} consensusApi - Consensus API to invoke, such as "/eth/v1/beacon/ genesis". * @param {*} credentials - AWS credentials. * @returns A promise with invocation result. */ async function sendRequest(nodeId, consensusApi, credentials) { const host = `${nodeId}.ethereum.managedblockchain.${REGION}.amazonaws.com` const endpoint = `https://${host}${consensusApi}`; request = await signedManagedBlockchainRequest(endpoint, credentials, host) const client = new AWS.HttpClient(); return await new Promise((resolve, reject) => { client.handleRequest(request, null, response => { let data = [] response.on('data', chunk => { data.push(chunk); }); response.on('end', () => { var responseBody = Buffer.concat(data); resolve(responseBody.toString('utf8')) }); }) }); } const nodeId = process.env.NODE_ID; Examples making Consensus API calls 64 Amazon Managed Blockchain (AMB) Ethereum Developer Guide new AWS.CredentialProviderChain() .resolvePromise() .then(credentials => sendRequest(nodeId, '/eth/v1/beacon/states/finalized/ root', credentials)) .then(console.log) .catch(err => console.error('ERROR: ' + err)) 2. Run the script to call the Consensus API method over HTTP on your Ethereum node. NODE_ID=nd-6eaj5va43jggnpxouzp7y47e4y AWS_DEFAULT_REGION=us-east-1 node consensus- ethereum-example.js Using awscurl to make Consensus API calls over HTTP The following example uses awscurl, which sends a signed HTTP request based on the credentials that you set for the AWS CLI. If you make your own HTTP requests, see Signing AWS requests with Signature Version 4 in the AWS General Reference. This example calls the /eth/v1/beacon/genesis method, which takes an empty parameter block. You can replace this method and its parameters with any method listed in Supported Consensus API methods. Replace your-node-id-lowercase with the ID of a node in your account (for example, nd-6eaj5va43jggnpxouzp7y47e4y). awscurl --service managedblockchain \ -X GET 'https://your-node-id-lowercase.ethereum.managedblockchain.us- east-1.amazonaws.com/eth/v1/beacon/genesis' The command returns output similar to the following. {"data": {"genesis_time":"1606824023","genesis_validators_root":"0x4b363db94e286120d76eb905340fdd4e54bfe9f06bf33ff6cf5ad27f511bfe95","genesis_fork_version":"0x00000000"}} Using token based access to make Consensus API calls to an Ethereum node You can use Accessor tokens to make Ethereum API calls to an Ethereum node as a convenient alternative to the Signature Version 4 (SigV4) signing process. You must provide a BILLING_TOKEN from one of the Accessor tokens that you create as a query parameter with the call. For more information on creating and managing Accessor tokens, see the topic on Using token based access. Examples making Consensus API calls 65 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Important • If you prioritize security and auditability over convenience, use the SigV4 signing process instead. • You can access the Ethereum APIs using Signature Version 4 (SigV4) and token based access. However, if you choose to use token based access, then any security benefits that are provided by using SigV4 are negated. • Never embed Accessor tokens in user-facing applications. The following examples demonstrate ways to make Ethereum Consensus API calls to an Ethereum node on Amazon Managed Blockchain (AMB) using token based access. Topics • Endpoint format for making Consensus API calls over HTTP using token based access • Making Consensus API calls using AWS SDK for JavaScript over HTTP using token based access • Using awscurl to make Consensus API calls over HTTP using token based access Endpoint format for making Consensus API calls over HTTP using token based access An Ethereum node that's created using AMB Access Ethereum hosts one endpoint for HTTP connections. This endpoint conforms to the following patterns. Note The node ID is case sensitive and must be lowercase where indicated, or a signature mismatch error occurs. HTTP endpoint format https://your-node-id-lowercase.t.ethereum.managedblockchain.us- east-1.amazonaws.com/<followed by HTTP path of the Consensus API>?billingtoken=your- billing-token For example: https://nd-6eaj5va43jggnpxouzp7y47e4y.t.ethereum.managedblockchain.us- Examples making Consensus API calls 66 Amazon Managed Blockchain (AMB) Ethereum Developer Guide east-1.amazonaws.com/eth/v1/beacon/genesis?billingtoken=n- MWY63ZJZU5HGNCMBQER7IN6OIU Making Consensus API calls using AWS SDK for JavaScript over HTTP using token based access The following example uses a JavaScript file for Node.js to make Consensus API calls using token based access by sending
amazon-managed-blockchain-ethereum-dev-019
amazon-managed-blockchain-ethereum-dev.pdf
19
Access Ethereum hosts one endpoint for HTTP connections. This endpoint conforms to the following patterns. Note The node ID is case sensitive and must be lowercase where indicated, or a signature mismatch error occurs. HTTP endpoint format https://your-node-id-lowercase.t.ethereum.managedblockchain.us- east-1.amazonaws.com/<followed by HTTP path of the Consensus API>?billingtoken=your- billing-token For example: https://nd-6eaj5va43jggnpxouzp7y47e4y.t.ethereum.managedblockchain.us- Examples making Consensus API calls 66 Amazon Managed Blockchain (AMB) Ethereum Developer Guide east-1.amazonaws.com/eth/v1/beacon/genesis?billingtoken=n- MWY63ZJZU5HGNCMBQER7IN6OIU Making Consensus API calls using AWS SDK for JavaScript over HTTP using token based access The following example uses a JavaScript file for Node.js to make Consensus API calls using token based access by sending HTTP requests to the Ethereum node endpoint in Amazon Managed Blockchain (AMB). Running the example script requires the following: • Node.js is installed on your machine. If you use an Amazon EC2 instance, see Tutorial: Setting Up Node.js on an Amazon EC2 Instance. • The Node package manager (npm) is used to install the AWS SDK for JavaScript. The script uses classes from these packages. npm install aws-sdk • The environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY must contain the credentials that are associated with the same account that created the node. Otherwise, the alternative is that the ~/.aws/credentials file is populated. Example — Make a Consensus API call using AWS SDK for JavaScript with an HTTP connection using token based access to an Ethereum node in Amazon Managed Blockchain (AMB) 1. Copy the contents of the script that follows and save it to a file on your machine (for example, consensus-ethereum-example.js). Contents of consensus-ethereum-example.js const AWS = require('aws-sdk'); const REGION = process.env.AWS_DEFAULT_REGION || 'us-east-1'; function getManagedBlockchainClient(){ const endpoint = `https://managedblockchain.${REGION}.amazonaws.com`; const client = new AWS.ManagedBlockchain(); client.setEndpoint(endpoint); return client; } Examples making Consensus API calls 67 Amazon Managed Blockchain (AMB) Ethereum Developer Guide async function getAccessTokenFromManagedBlockChain() { const client = getManagedBlockchainClient(); const accessorType = { AccessorType : "BILLING_TOKEN"}; const networkType = { NetworkType : "ETHEREUM_MAINNET"}; const tokenResponse = await new Promise((resolve, reject) => { client.createAccessor( accessorType, networkType, (err, data) => { if (err) { console.error(err); reject(err.message); } else { resolve(data); } }); }); return tokenResponse; } async function deleteAccessTokenFromManagedBlockChain(accessorId) { const client = getManagedBlockchainClient(); const id = { AccessorId : accessorId }; const tokenResponse = await new Promise((resolve, reject) => { client.deleteAccessor( id, (err, data) => { if (err) { console.error(err); reject(err.message); } else resolve(data); }); }); } function getManagedBlockchainRequest(endpoint, host) { const awsRequest = new AWS.HttpRequest(new AWS.Endpoint(endpoint), REGION); awsRequest.method = "GET"; awsRequest.headers['host'] = host; awsRequest.headers['Content-Type'] = 'application/json' return awsRequest } /** * Sends Consensus API requests to AMB Ethereum node. Examples making Consensus API calls 68 Amazon Managed Blockchain (AMB) Ethereum Developer Guide * @param {*} nodeId - Node ID * @param {*} consensusApi - Consensus API to invoke, such as "/eth/v1/beacon/ genesis". * @param {*} credentials - AWS credentials. * @returns A promise with invocation result. */ async function sendRequest(nodeId, consensusApi) { const token = await getAccessTokenFromManagedBlockChain(); const host = `${nodeId}.t.ethereum.managedblockchain.${REGION}.amazonaws.com`; const endpoint = `https://${host}${consensusApi}?billingtoken= ${token.BillingToken}`; request = getManagedBlockchainRequest(endpoint, host) const client = new AWS.HttpClient(); const promise = await new Promise((resolve, reject) => { client.handleRequest(request, null, response => { let data = [] response.on('data', chunk => { data.push(chunk); }); response.on('end', () => { var responseBody = Buffer.concat(data); resolve(responseBody.toString('utf8')) }); }) }); deleteAccessTokenFromManagedBlockChain(token.AccessorId); return promise; } const nodeId = process.env.NODE_ID; new AWS.CredentialProviderChain() .resolvePromise() .then(() => sendRequest(nodeId, '/eth/v1/beacon/states/finalized/root')) .then(console.log) .catch(err => console.error('ERROR: ' + err)) 2. Run the script to call the Consensus API method over HTTP on your Ethereum node. NODE_ID=nd-6eaj5va43jggnpxouzp7y47e4y AWS_DEFAULT_REGION=us-east-1 node consensus- ethereum-example.js Examples making Consensus API calls 69 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Using awscurl to make Consensus API calls over HTTP using token based access The following example uses awscurl, which sends a signed HTTP request based on the credentials that you set for the AWS CLI. This example calls the /eth/v1/beacon/genesis method, which takes an empty parameter block. You can replace this method and its parameters with any method listed in Supported Consensus API methods. Replace your-node-id-lowercase with the ID of a node in your account (for example, nd-6eaj5va43jggnpxouzp7y47e4y). awscurl --service managedblockchain \ -X GET 'https://your-node-id-lowercase.t.ethereum.managedblockchain.us- east-1.amazonaws.com/eth/v1/beacon/genesis?billingtoken=your-billing-token' The command returns output similar to the following. {"data":{"root":"0x71ef3f7c2470a7564af6eb8232855b602401cc9acdfc02c9fdf699e643cf8ba4"}} Examples making Consensus API calls 70 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Amazon Managed Blockchain (AMB) Access Ethereum Security To provide data protection, authentication, and access control, Amazon Managed Blockchain (AMB) benefits from AWS features and the features of the open-source framework running in AMB Access. This chapter covers security information specific to AMB Access Ethereum. For security information specific to AMB Access Hyperledger Fabric, see AMB Access Hyperledger Fabric Security in the Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide. Topics • Data protection for Amazon Managed Blockchain (AMB) Access Ethereum • Authentication and access control for Amazon Managed Blockchain (AMB) Access Ethereum Data protection for Amazon Managed Blockchain (AMB) Access Ethereum Data encryption helps prevent
amazon-managed-blockchain-ethereum-dev-020
amazon-managed-blockchain-ethereum-dev.pdf
20
Ethereum Security To provide data protection, authentication, and access control, Amazon Managed Blockchain (AMB) benefits from AWS features and the features of the open-source framework running in AMB Access. This chapter covers security information specific to AMB Access Ethereum. For security information specific to AMB Access Hyperledger Fabric, see AMB Access Hyperledger Fabric Security in the Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide. Topics • Data protection for Amazon Managed Blockchain (AMB) Access Ethereum • Authentication and access control for Amazon Managed Blockchain (AMB) Access Ethereum Data protection for Amazon Managed Blockchain (AMB) Access Ethereum Data encryption helps prevent unauthorized users from reading data from a blockchain network and the associated data storage systems. This includes data that might be intercepted as it travels the network, known as data in transit. Encryption in transit By default, AMB Access uses an HTTPS/TLS connection to encrypt all the data that's transmitted from a client computer that runs the AWS CLI to AWS service endpoints. You don't need to do anything to enable the use of HTTPS/TLS. It's always enabled unless you explicitly disable it for an individual AWS CLI command by using the --no-verify-ssl command line option. Data Protection 71 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Authentication and access control for Amazon Managed Blockchain (AMB) Access Ethereum IAM permissions policies are associated with AWS users in your account and determine who has access to what. Permissions policies specify the actions that each user can perform using AMB Access and other AWS services. Before you configure IAM permissions, see Identity and Access Management for Amazon Managed Blockchain (AMB) Access Ethereum. We also recommend What is IAM? and IAM JSON Policy Reference in the IAM User Guide. Identity and Access Management for Amazon Managed Blockchain (AMB) Access Ethereum AWS Identity and Access Management (IAM) is an AWS service that helps an administrator securely control access to AWS resources. IAM administrators control who can be authenticated (signed in) and authorized (have permissions) to use AMB Access Ethereum resources. IAM is an AWS service that you can use with no additional charge. Topics • Audience • Authenticating with identities • Managing access using policies • How Amazon Managed Blockchain (AMB) Access Ethereum works with IAM • Troubleshooting Amazon Managed Blockchain (AMB) Access Ethereum identity and access • Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum • Using Service-Linked Roles for AMB Access Audience How you use AWS Identity and Access Management (IAM) differs, depending on the work that you do in AMB Access Ethereum. Service user – If you use the AMB Access Ethereum service to do your job, then your administrator provides you with the credentials and permissions that you need. As you use more AMB Access Authentication and access control 72 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Ethereum features to do your work, you might need additional permissions. Understanding how access is managed can help you request the right permissions from your administrator. If you cannot access a feature in AMB Access Ethereum, see Troubleshooting Amazon Managed Blockchain (AMB) Access Ethereum identity and access. Service administrator – If you're in charge of AMB Access Ethereum resources at your company, you probably have full access to AMB Access Ethereum. It's your job to determine which AMB Access Ethereum features and resources your service users should access. You must then submit requests to your IAM administrator to change the permissions of your service users. Review the information on this page to understand the basic concepts of IAM. To learn more about how your company can use IAM with AMB Access Ethereum, see How Amazon Managed Blockchain (AMB) Access Ethereum works with IAM. IAM administrator – If you're an IAM administrator, you might want to learn details about how you can write policies to manage access to AMB Access Ethereum. To view example AMB Access Ethereum identity-based policies that you can use in IAM, see Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum. Authenticating with identities Authentication is how you sign in to AWS using your identity credentials. You must be authenticated (signed in to AWS) as the AWS account root user, as an IAM user, or by assuming an IAM role. You can sign in to AWS as a federated identity by using credentials provided through an identity source. AWS IAM Identity Center (IAM Identity Center) users, your company's single sign-on authentication, and your Google or Facebook credentials are examples of federated identities. When you sign in as a federated identity, your administrator previously set up identity federation using IAM roles. When you access AWS by using federation, you are indirectly assuming a role. Depending on the type of user you are, you can sign in to the AWS Management Console or the AWS access portal. For more information
amazon-managed-blockchain-ethereum-dev-021
amazon-managed-blockchain-ethereum-dev.pdf
21
IAM role. You can sign in to AWS as a federated identity by using credentials provided through an identity source. AWS IAM Identity Center (IAM Identity Center) users, your company's single sign-on authentication, and your Google or Facebook credentials are examples of federated identities. When you sign in as a federated identity, your administrator previously set up identity federation using IAM roles. When you access AWS by using federation, you are indirectly assuming a role. Depending on the type of user you are, you can sign in to the AWS Management Console or the AWS access portal. For more information about signing in to AWS, see How to sign in to your AWS account in the AWS Sign-In User Guide. If you access AWS programmatically, AWS provides a software development kit (SDK) and a command line interface (CLI) to cryptographically sign your requests by using your credentials. If you don't use AWS tools, you must sign requests yourself. For more information about using the recommended method to sign requests yourself, see AWS Signature Version 4 for API requests in the IAM User Guide. Identity and Access Management 73 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Regardless of the authentication method that you use, you might be required to provide additional security information. For example, AWS recommends that you use multi-factor authentication (MFA) to increase the security of your account. To learn more, see Multi-factor authentication in the AWS IAM Identity Center User Guide and AWS Multi-factor authentication in IAM in the IAM User Guide. AWS account root user When you create an AWS account, you begin with one sign-in identity that has complete access to all AWS services and resources in the account. This identity is called the AWS account root user and is accessed by signing in with the email address and password that you used to create the account. We strongly recommend that you don't use the root user for your everyday tasks. Safeguard your root user credentials and use them to perform the tasks that only the root user can perform. For the complete list of tasks that require you to sign in as the root user, see Tasks that require root user credentials in the IAM User Guide. Federated identity As a best practice, require human users, including users that require administrator access, to use federation with an identity provider to access AWS services by using temporary credentials. A federated identity is a user from your enterprise user directory, a web identity provider, the AWS Directory Service, the Identity Center directory, or any user that accesses AWS services by using credentials provided through an identity source. When federated identities access AWS accounts, they assume roles, and the roles provide temporary credentials. For centralized access management, we recommend that you use AWS IAM Identity Center. You can create users and groups in IAM Identity Center, or you can connect and synchronize to a set of users and groups in your own identity source for use across all your AWS accounts and applications. For information about IAM Identity Center, see What is IAM Identity Center? in the AWS IAM Identity Center User Guide. IAM users and groups An IAM user is an identity within your AWS account that has specific permissions for a single person or application. Where possible, we recommend relying on temporary credentials instead of creating IAM users who have long-term credentials such as passwords and access keys. However, if you have specific use cases that require long-term credentials with IAM users, we recommend that you rotate access keys. For more information, see Rotate access keys regularly for use cases that require long- term credentials in the IAM User Guide. Identity and Access Management 74 Amazon Managed Blockchain (AMB) Ethereum Developer Guide An IAM group is an identity that specifies a collection of IAM users. You can't sign in as a group. You can use groups to specify permissions for multiple users at a time. Groups make permissions easier to manage for large sets of users. For example, you could have a group named IAMAdmins and give that group permissions to administer IAM resources. Users are different from roles. A user is uniquely associated with one person or application, but a role is intended to be assumable by anyone who needs it. Users have permanent long-term credentials, but roles provide temporary credentials. To learn more, see Use cases for IAM users in the IAM User Guide. IAM roles An IAM role is an identity within your AWS account that has specific permissions. It is similar to an IAM user, but is not associated with a specific person. To temporarily assume an IAM role in the AWS Management Console, you can switch from a user to an IAM role (console). You can assume a role by calling
amazon-managed-blockchain-ethereum-dev-022
amazon-managed-blockchain-ethereum-dev.pdf
22
person or application, but a role is intended to be assumable by anyone who needs it. Users have permanent long-term credentials, but roles provide temporary credentials. To learn more, see Use cases for IAM users in the IAM User Guide. IAM roles An IAM role is an identity within your AWS account that has specific permissions. It is similar to an IAM user, but is not associated with a specific person. To temporarily assume an IAM role in the AWS Management Console, you can switch from a user to an IAM role (console). You can assume a role by calling an AWS CLI or AWS API operation or by using a custom URL. For more information about methods for using roles, see Methods to assume a role in the IAM User Guide. IAM roles with temporary credentials are useful in the following situations: • Federated user access – To assign permissions to a federated identity, you create a role and define permissions for the role. When a federated identity authenticates, the identity is associated with the role and is granted the permissions that are defined by the role. For information about roles for federation, see Create a role for a third-party identity provider (federation) in the IAM User Guide. If you use IAM Identity Center, you configure a permission set. To control what your identities can access after they authenticate, IAM Identity Center correlates the permission set to a role in IAM. For information about permissions sets, see Permission sets in the AWS IAM Identity Center User Guide. • Temporary IAM user permissions – An IAM user or role can assume an IAM role to temporarily take on different permissions for a specific task. • Cross-account access – You can use an IAM role to allow someone (a trusted principal) in a different account to access resources in your account. Roles are the primary way to grant cross- account access. However, with some AWS services, you can attach a policy directly to a resource (instead of using a role as a proxy). To learn the difference between roles and resource-based policies for cross-account access, see Cross account resource access in IAM in the IAM User Guide. • Cross-service access – Some AWS services use features in other AWS services. For example, when you make a call in a service, it's common for that service to run applications in Amazon EC2 or Identity and Access Management 75 Amazon Managed Blockchain (AMB) Ethereum Developer Guide store objects in Amazon S3. A service might do this using the calling principal's permissions, using a service role, or using a service-linked role. • Forward access sessions (FAS) – When you use an IAM user or role to perform actions in AWS, you are considered a principal. When you use some services, you might perform an action that then initiates another action in a different service. FAS uses the permissions of the principal calling an AWS service, combined with the requesting AWS service to make requests to downstream services. FAS requests are only made when a service receives a request that requires interactions with other AWS services or resources to complete. In this case, you must have permissions to perform both actions. For policy details when making FAS requests, see Forward access sessions. • Service role – A service role is an IAM role that a service assumes to perform actions on your behalf. An IAM administrator can create, modify, and delete a service role from within IAM. For more information, see Create a role to delegate permissions to an AWS service in the IAM User Guide. • Service-linked role – A service-linked role is a type of service role that is linked to an AWS service. The service can assume the role to perform an action on your behalf. Service-linked roles appear in your AWS account and are owned by the service. An IAM administrator can view, but not edit the permissions for service-linked roles. • Applications running on Amazon EC2 – You can use an IAM role to manage temporary credentials for applications that are running on an EC2 instance and making AWS CLI or AWS API requests. This is preferable to storing access keys within the EC2 instance. To assign an AWS role to an EC2 instance and make it available to all of its applications, you create an instance profile that is attached to the instance. An instance profile contains the role and enables programs that are running on the EC2 instance to get temporary credentials. For more information, see Use an IAM role to grant permissions to applications running on Amazon EC2 instances in the IAM User Guide. Managing access using policies You control access in AWS by creating policies and attaching them to AWS identities or resources. A policy is
amazon-managed-blockchain-ethereum-dev-023
amazon-managed-blockchain-ethereum-dev.pdf
23
keys within the EC2 instance. To assign an AWS role to an EC2 instance and make it available to all of its applications, you create an instance profile that is attached to the instance. An instance profile contains the role and enables programs that are running on the EC2 instance to get temporary credentials. For more information, see Use an IAM role to grant permissions to applications running on Amazon EC2 instances in the IAM User Guide. Managing access using policies You control access in AWS by creating policies and attaching them to AWS identities or resources. A policy is an object in AWS that, when associated with an identity or resource, defines their permissions. AWS evaluates these policies when a principal (user, root user, or role session) makes a request. Permissions in the policies determine whether the request is allowed or denied. Most policies are stored in AWS as JSON documents. For more information about the structure and contents of JSON policy documents, see Overview of JSON policies in the IAM User Guide. Identity and Access Management 76 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. By default, users and roles have no permissions. To grant users permission to perform actions on the resources that they need, an IAM administrator can create IAM policies. The administrator can then add the IAM policies to roles, and users can assume the roles. IAM policies define permissions for an action regardless of the method that you use to perform the operation. For example, suppose that you have a policy that allows the iam:GetRole action. A user with that policy can get role information from the AWS Management Console, the AWS CLI, or the AWS API. Identity-based policies Identity-based policies are JSON permissions policy documents that you can attach to an identity, such as an IAM user, group of users, or role. These policies control what actions users and roles can perform, on which resources, and under what conditions. To learn how to create an identity-based policy, see Define custom IAM permissions with customer managed policies in the IAM User Guide. Identity-based policies can be further categorized as inline policies or managed policies. Inline policies are embedded directly into a single user, group, or role. Managed policies are standalone policies that you can attach to multiple users, groups, and roles in your AWS account. Managed policies include AWS managed policies and customer managed policies. To learn how to choose between a managed policy or an inline policy, see Choose between managed policies and inline policies in the IAM User Guide. Resource-based policies Resource-based policies are JSON policy documents that you attach to a resource. Examples of resource-based policies are IAM role trust policies and Amazon S3 bucket policies. In services that support resource-based policies, service administrators can use them to control access to a specific resource. For the resource where the policy is attached, the policy defines what actions a specified principal can perform on that resource and under what conditions. You must specify a principal in a resource-based policy. Principals can include accounts, users, roles, federated users, or AWS services. Resource-based policies are inline policies that are located in that service. You can't use AWS managed policies from IAM in a resource-based policy. Identity and Access Management 77 Amazon Managed Blockchain (AMB) Access control lists (ACLs) Ethereum Developer Guide Access control lists (ACLs) control which principals (account members, users, or roles) have permissions to access a resource. ACLs are similar to resource-based policies, although they do not use the JSON policy document format. Amazon S3, AWS WAF, and Amazon VPC are examples of services that support ACLs. To learn more about ACLs, see Access control list (ACL) overview in the Amazon Simple Storage Service Developer Guide. Other policy types AWS supports additional, less-common policy types. These policy types can set the maximum permissions granted to you by the more common policy types. • Permissions boundaries – A permissions boundary is an advanced feature in which you set the maximum permissions that an identity-based policy can grant to an IAM entity (IAM user or role). You can set a permissions boundary for an entity. The resulting permissions are the intersection of an entity's identity-based policies and its permissions boundaries. Resource-based policies that specify the user or role in the Principal field are not limited by the permissions boundary. An explicit deny in any of these policies overrides the allow. For more information about permissions boundaries, see Permissions boundaries for IAM entities in the IAM User Guide. • Service control policies (SCPs) – SCPs are JSON policies that specify the maximum permissions for an organization or organizational unit
amazon-managed-blockchain-ethereum-dev-024
amazon-managed-blockchain-ethereum-dev.pdf
24
to an IAM entity (IAM user or role). You can set a permissions boundary for an entity. The resulting permissions are the intersection of an entity's identity-based policies and its permissions boundaries. Resource-based policies that specify the user or role in the Principal field are not limited by the permissions boundary. An explicit deny in any of these policies overrides the allow. For more information about permissions boundaries, see Permissions boundaries for IAM entities in the IAM User Guide. • Service control policies (SCPs) – SCPs are JSON policies that specify the maximum permissions for an organization or organizational unit (OU) in AWS Organizations. AWS Organizations is a service for grouping and centrally managing multiple AWS accounts that your business owns. If you enable all features in an organization, then you can apply service control policies (SCPs) to any or all of your accounts. The SCP limits permissions for entities in member accounts, including each AWS account root user. For more information about Organizations and SCPs, see Service control policies in the AWS Organizations User Guide. • Resource control policies (RCPs) – RCPs are JSON policies that you can use to set the maximum available permissions for resources in your accounts without updating the IAM policies attached to each resource that you own. The RCP limits permissions for resources in member accounts and can impact the effective permissions for identities, including the AWS account root user, regardless of whether they belong to your organization. For more information about Organizations and RCPs, including a list of AWS services that support RCPs, see Resource control policies (RCPs) in the AWS Organizations User Guide. • Session policies – Session policies are advanced policies that you pass as a parameter when you programmatically create a temporary session for a role or federated user. The resulting session's Identity and Access Management 78 Amazon Managed Blockchain (AMB) Ethereum Developer Guide permissions are the intersection of the user or role's identity-based policies and the session policies. Permissions can also come from a resource-based policy. An explicit deny in any of these policies overrides the allow. For more information, see Session policies in the IAM User Guide. Multiple policy types When multiple types of policies apply to a request, the resulting permissions are more complicated to understand. To learn how AWS determines whether to allow a request when multiple policy types are involved, see Policy evaluation logic in the IAM User Guide. How Amazon Managed Blockchain (AMB) Access Ethereum works with IAM Before you use IAM to manage access to AMB Access Ethereum, learn what IAM features are available to use with AMB Access Ethereum. IAM features you can use with Amazon Managed Blockchain (AMB) Access Ethereum IAM feature AMB Access Ethereum support Identity-based policies Resource-based policies Policy actions Policy resources Policy condition keys (service-specific) ACLs ABAC (tags in policies) Temporary credentials Principal permissions Service roles Service-linked roles Yes No Yes Yes No No Yes Yes Yes Yes Yes Identity and Access Management 79 Amazon Managed Blockchain (AMB) Ethereum Developer Guide To get a high-level view of how AMB Access Ethereum and other AWS services work with most IAM features, see AWS services that work with IAM in the IAM User Guide. Important Ethereum API calls to an Ethereum node in Amazon Managed Blockchain (AMB) can be authenticated by using the Signature Version 4 (SigV4) signing process. This means that only authorized IAM principals in the AWS account that created the node can interact with it using the Ethereum APIs. AWS credentials (an access key ID and secret access key) must be provided with the call. Identity-based policies for AMB Access Ethereum Supports identity-based policies: Yes Identity-based policies are JSON permissions policy documents that you can attach to an identity, such as an IAM user, group of users, or role. These policies control what actions users and roles can perform, on which resources, and under what conditions. To learn how to create an identity-based policy, see Define custom IAM permissions with customer managed policies in the IAM User Guide. With IAM identity-based policies, you can specify allowed or denied actions and resources as well as the conditions under which actions are allowed or denied. You can't specify the principal in an identity-based policy because it applies to the user or role to which it is attached. To learn about all of the elements that you can use in a JSON policy, see IAM JSON policy elements reference in the IAM User Guide. Identity-based policy examples for AMB Access Ethereum To view examples of AMB Access Ethereum identity-based policies, see Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum. Resource-based policies within AMB Access Ethereum Supports resource-based policies: No Resource-based policies are JSON policy documents that you attach to a resource. Examples of resource-based policies are IAM role
amazon-managed-blockchain-ethereum-dev-025
amazon-managed-blockchain-ethereum-dev.pdf
25
principal in an identity-based policy because it applies to the user or role to which it is attached. To learn about all of the elements that you can use in a JSON policy, see IAM JSON policy elements reference in the IAM User Guide. Identity-based policy examples for AMB Access Ethereum To view examples of AMB Access Ethereum identity-based policies, see Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum. Resource-based policies within AMB Access Ethereum Supports resource-based policies: No Resource-based policies are JSON policy documents that you attach to a resource. Examples of resource-based policies are IAM role trust policies and Amazon S3 bucket policies. In services that support resource-based policies, service administrators can use them to control access to a specific Identity and Access Management 80 Amazon Managed Blockchain (AMB) Ethereum Developer Guide resource. For the resource where the policy is attached, the policy defines what actions a specified principal can perform on that resource and under what conditions. You must specify a principal in a resource-based policy. Principals can include accounts, users, roles, federated users, or AWS services. To enable cross-account access, you can specify an entire account or IAM entities in another account as the principal in a resource-based policy. Adding a cross-account principal to a resource- based policy is only half of establishing the trust relationship. When the principal and the resource are in different AWS accounts, an IAM administrator in the trusted account must also grant the principal entity (user or role) permission to access the resource. They grant permission by attaching an identity-based policy to the entity. However, if a resource-based policy grants access to a principal in the same account, no additional identity-based policy is required. For more information, see Cross account resource access in IAM in the IAM User Guide. Policy actions for AMB Access Ethereum Supports policy actions: Yes Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. The Action element of a JSON policy describes the actions that you can use to allow or deny access in a policy. Policy actions usually have the same name as the associated AWS API operation. There are some exceptions, such as permission-only actions that don't have a matching API operation. There are also some operations that require multiple actions in a policy. These additional actions are called dependent actions. Include actions in a policy to grant permissions to perform the associated operation. To see a list of AMB Access Ethereum actions, see Actions defined by Amazon Managed Blockchain (AMB) Access Ethereum in the Service Authorization Reference. Policy actions in AMB Access Ethereum use the following prefix before the action: managedblockchain: For example, to grant someone permission to create a node with the AMB Access CreateNode API operation, you include the managedblockchain:CreateNode action in their policy. Policy Identity and Access Management 81 Amazon Managed Blockchain (AMB) Ethereum Developer Guide statements must include either an Action or NotAction element. AMB Access Ethereum defines its own set of actions that describe tasks that you can perform with this service. To specify multiple actions in a single statement, separate them with commas. "Action": [ "managedblockchain::action1", "managedblockchain::action2" ] You can specify multiple actions using wildcards (*). For example, to specify all actions that begin with the word Describe, include the following action: "Action": "managedblockchain::List*" To view examples of AMB Access Ethereum identity-based policies, see Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum. Policy resources for AMB Access Ethereum Supports policy resources: Yes Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. The Resource JSON policy element specifies the object or objects to which the action applies. Statements must include either a Resource or a NotResource element. As a best practice, specify a resource using its Amazon Resource Name (ARN). You can do this for actions that support a specific resource type, known as resource-level permissions. For actions that don't support resource-level permissions, such as listing operations, use a wildcard (*) to indicate that the statement applies to all resources. "Resource": "*" AMB Access resource types that can be used in IAM permissions policy statements for resources on Ethereum networks include the following: • network Identity and Access Management 82 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • node • accessor Nodes and accessors are associated with your account. Networks are associated with Ethereum public networks and are not associated with AWS Regions. For example an Ethereum public network resource on AMB Access has one of the following ARNs. arn:aws:managedblockchain:::networks/n-ethereum-mainnet To see a list of AMB Access Ethereum resource types and their ARNs, see Resources defined by Amazon Managed
amazon-managed-blockchain-ethereum-dev-026
amazon-managed-blockchain-ethereum-dev.pdf
26
resources. "Resource": "*" AMB Access resource types that can be used in IAM permissions policy statements for resources on Ethereum networks include the following: • network Identity and Access Management 82 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • node • accessor Nodes and accessors are associated with your account. Networks are associated with Ethereum public networks and are not associated with AWS Regions. For example an Ethereum public network resource on AMB Access has one of the following ARNs. arn:aws:managedblockchain:::networks/n-ethereum-mainnet To see a list of AMB Access Ethereum resource types and their ARNs, see Resources defined by Amazon Managed Blockchain (AMB) Access Ethereum in the Service Authorization Reference. To learn with which actions you can specify the ARN of each resource, see Actions defined by Amazon Managed Blockchain (AMB) Access Ethereum. To view examples of AMB Access Ethereum identity-based policies, see Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum. Policy condition keys for AMB Access Ethereum Supports service-specific policy condition keys: No Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. The Condition element (or Condition block) lets you specify conditions in which a statement is in effect. The Condition element is optional. You can create conditional expressions that use condition operators, such as equals or less than, to match the condition in the policy with values in the request. If you specify multiple Condition elements in a statement, or multiple keys in a single Condition element, AWS evaluates them using a logical AND operation. If you specify multiple values for a single condition key, AWS evaluates the condition using a logical OR operation. All of the conditions must be met before the statement's permissions are granted. You can also use placeholder variables when you specify conditions. For example, you can grant an IAM user permission to access a resource only if it is tagged with their IAM user name. For more information, see IAM policy elements: variables and tags in the IAM User Guide. Identity and Access Management 83 Amazon Managed Blockchain (AMB) Ethereum Developer Guide AWS supports global condition keys and service-specific condition keys. To see all AWS global condition keys, see AWS global condition context keys in the IAM User Guide. Note AMB Access Ethereum does not provide any service-specific condition keys, but it does support using some AWS global condition keys. To see a list of the AWS global condition keys supported, see Condition keys for Amazon Managed Blockchain (AMB) Access Ethereum in the Service Authorization Reference. To learn with which actions and resources you can use a condition key, see Actions defined by Amazon Managed Blockchain (AMB) Access Ethereum. To view examples of AMB Access Ethereum identity-based policies, see Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum. ACLs in AMB Access Ethereum Supports ACLs: No Access control lists (ACLs) control which principals (account members, users, or roles) have permissions to access a resource. ACLs are similar to resource-based policies, although they do not use the JSON policy document format. ABAC with AMB Access Ethereum Supports ABAC (tags in policies): Yes Attribute-based access control (ABAC) is an authorization strategy that defines permissions based on attributes. In AWS, these attributes are called tags. You can attach tags to IAM entities (users or roles) and to many AWS resources. Tagging entities and resources is the first step of ABAC. Then you design ABAC policies to allow operations when the principal's tag matches the tag on the resource that they are trying to access. ABAC is helpful in environments that are growing rapidly and helps with situations where policy management becomes cumbersome. To control access based on tags, you provide tag information in the condition element of a policy using the aws:ResourceTag/key-name, aws:RequestTag/key-name, or aws:TagKeys condition keys. Identity and Access Management 84 Amazon Managed Blockchain (AMB) Ethereum Developer Guide If a service supports all three condition keys for every resource type, then the value is Yes for the service. If a service supports all three condition keys for only some resource types, then the value is Partial. For more information about ABAC, see Define permissions with ABAC authorization in the IAM User Guide. To view a tutorial with steps for setting up ABAC, see Use attribute-based access control (ABAC) in the IAM User Guide. To control access based on tags, you provide tag information in the condition element of a policy using the managedblockchain::ResourceTag/key-name, aws:RequestTag/key-name, or aws:TagKeys condition keys. For more information about tagging AMB Access Ethereum resources, see Tagging Amazon Managed Blockchain (AMB) resources. To view example identity-based policies for allowing or denying access to resources and actions based on tags, see Controlling access using tags. Using temporary credentials with AMB Access Ethereum Supports temporary
amazon-managed-blockchain-ethereum-dev-027
amazon-managed-blockchain-ethereum-dev.pdf
27
ABAC authorization in the IAM User Guide. To view a tutorial with steps for setting up ABAC, see Use attribute-based access control (ABAC) in the IAM User Guide. To control access based on tags, you provide tag information in the condition element of a policy using the managedblockchain::ResourceTag/key-name, aws:RequestTag/key-name, or aws:TagKeys condition keys. For more information about tagging AMB Access Ethereum resources, see Tagging Amazon Managed Blockchain (AMB) resources. To view example identity-based policies for allowing or denying access to resources and actions based on tags, see Controlling access using tags. Using temporary credentials with AMB Access Ethereum Supports temporary credentials: Yes Some AWS services don't work when you sign in using temporary credentials. For additional information, including which AWS services work with temporary credentials, see AWS services that work with IAM in the IAM User Guide. You are using temporary credentials if you sign in to the AWS Management Console using any method except a user name and password. For example, when you access AWS using your company's single sign-on (SSO) link, that process automatically creates temporary credentials. You also automatically create temporary credentials when you sign in to the console as a user and then switch roles. For more information about switching roles, see Switch from a user to an IAM role (console) in the IAM User Guide. You can manually create temporary credentials using the AWS CLI or AWS API. You can then use those temporary credentials to access AWS. AWS recommends that you dynamically generate temporary credentials instead of using long-term access keys. For more information, see Temporary security credentials in IAM. Cross-service principal permissions for AMB Access Ethereum Supports forward access sessions (FAS): Yes When you use an IAM user or role to perform actions in AWS, you are considered a principal. When you use some services, you might perform an action that then initiates another action in a Identity and Access Management 85 Amazon Managed Blockchain (AMB) Ethereum Developer Guide different service. FAS uses the permissions of the principal calling an AWS service, combined with the requesting AWS service to make requests to downstream services. FAS requests are only made when a service receives a request that requires interactions with other AWS services or resources to complete. In this case, you must have permissions to perform both actions. For policy details when making FAS requests, see Forward access sessions. Service roles for AMB Access Ethereum Supports service roles: Yes A service role is an IAM role that a service assumes to perform actions on your behalf. An IAM administrator can create, modify, and delete a service role from within IAM. For more information, see Create a role to delegate permissions to an AWS service in the IAM User Guide. Warning Changing the permissions for a service role might break AMB Access Ethereum functionality. Edit service roles only when AMB Access Ethereum provides guidance to do so. Service-linked roles for AMB Access Ethereum Supports service-linked roles: Yes A service-linked role is a type of service role that is linked to an AWS service. The service can assume the role to perform an action on your behalf. Service-linked roles appear in your AWS account and are owned by the service. An IAM administrator can view, but not edit the permissions for service-linked roles. For details about creating or managing service-linked roles, see AWS services that work with IAM. Find a service in the table that includes a Yes in the Service-linked role column. Choose the Yes link to view the service-linked role documentation for that service. Troubleshooting Amazon Managed Blockchain (AMB) Access Ethereum identity and access Use the following information to help you diagnose and fix common issues that you might encounter when working with AMB Access Ethereum and IAM. Identity and Access Management 86 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Topics • I am not authorized to perform an action in AMB Access Ethereum • I am not authorized to perform iam:PassRole • I want to allow people outside of my AWS account to access my AMB Access Ethereum resources I am not authorized to perform an action in AMB Access Ethereum If you receive an error that you're not authorized to perform an action, your policies must be updated to allow you to perform the action. The following example error occurs when the mateojackson IAM user tries to use the console to view details about a fictional my-example-widget resource but doesn't have the fictional managedblockchain::GetWidget permissions. User: arn:aws:iam::123456789012:user/mateojackson is not authorized to perform: managedblockchain::GetWidget on resource: my-example-widget In this case, the policy for the mateojackson user must be updated to allow access to the my- example-widget resource by using the managedblockchain::GetWidget action. If you need help, contact your AWS administrator. Your administrator is the person who provided you with your sign-in credentials. I
amazon-managed-blockchain-ethereum-dev-028
amazon-managed-blockchain-ethereum-dev.pdf
28
action, your policies must be updated to allow you to perform the action. The following example error occurs when the mateojackson IAM user tries to use the console to view details about a fictional my-example-widget resource but doesn't have the fictional managedblockchain::GetWidget permissions. User: arn:aws:iam::123456789012:user/mateojackson is not authorized to perform: managedblockchain::GetWidget on resource: my-example-widget In this case, the policy for the mateojackson user must be updated to allow access to the my- example-widget resource by using the managedblockchain::GetWidget action. If you need help, contact your AWS administrator. Your administrator is the person who provided you with your sign-in credentials. I am not authorized to perform iam:PassRole If you receive an error that you're not authorized to perform the iam:PassRole action, your policies must be updated to allow you to pass a role to AMB Access Ethereum. Some AWS services allow you to pass an existing role to that service instead of creating a new service role or service-linked role. To do this, you must have permissions to pass the role to the service. The following example error occurs when an IAM user named marymajor tries to use the console to perform an action in AMB Access Ethereum. However, the action requires the service to have permissions that are granted by a service role. Mary does not have permissions to pass the role to the service. User: arn:aws:iam::123456789012:user/marymajor is not authorized to perform: iam:PassRole Identity and Access Management 87 Amazon Managed Blockchain (AMB) Ethereum Developer Guide In this case, Mary's policies must be updated to allow her to perform the iam:PassRole action. If you need help, contact your AWS administrator. Your administrator is the person who provided you with your sign-in credentials. I want to allow people outside of my AWS account to access my AMB Access Ethereum resources You can create a role that users in other accounts or people outside of your organization can use to access your resources. You can specify who is trusted to assume the role. For services that support resource-based policies or access control lists (ACLs), you can use those policies to grant people access to your resources. To learn more, consult the following: • To learn whether AMB Access Ethereum supports these features, see How Amazon Managed Blockchain (AMB) Access Ethereum works with IAM. • To learn how to provide access to your resources across AWS accounts that you own, see Providing access to an IAM user in another AWS account that you own in the IAM User Guide. • To learn how to provide access to your resources to third-party AWS accounts, see Providing access to AWS accounts owned by third parties in the IAM User Guide. • To learn how to provide access through identity federation, see Providing access to externally authenticated users (identity federation) in the IAM User Guide. • To learn the difference between using roles and resource-based policies for cross-account access, see Cross account resource access in IAM in the IAM User Guide. Identity-based policy examples for Amazon Managed Blockchain (AMB) Access Ethereum By default, users and roles don't have permission to create or modify AMB Access Ethereum resources. They also can't perform tasks by using the AWS Management Console, AWS Command Line Interface (AWS CLI), or AWS API. To grant users permission to perform actions on the resources that they need, an IAM administrator can create IAM policies. The administrator can then add the IAM policies to roles, and users can assume the roles. To learn how to create an IAM identity-based policy by using these example JSON policy documents, see Create IAM policies (console) in the IAM User Guide. Identity and Access Management 88 Amazon Managed Blockchain (AMB) Ethereum Developer Guide For details about actions and resource types defined by AMB Access Ethereum, including the format of the ARNs for each of the resource types, see Actions, resources, and condition keys for Amazon Managed Blockchain (AMB) Access Ethereum in the Service Authorization Reference. Topics • Policy best practices • Using the AMB Access Ethereum console • Allow users to view their own permissions • Performing all available actions for AMB Access Ethereum • Controlling access using tags Policy best practices Identity-based policies determine whether someone can create, access, or delete AMB Access Ethereum resources in your account. These actions can incur costs for your AWS account. When you create or edit identity-based policies, follow these guidelines and recommendations: • Get started with AWS managed policies and move toward least-privilege permissions – To get started granting permissions to your users and workloads, use the AWS managed policies that grant permissions for many common use cases. They are available in your AWS account. We recommend that you reduce permissions further by defining AWS customer managed policies that are specific to your use cases. For more information, see AWS managed
amazon-managed-blockchain-ethereum-dev-029
amazon-managed-blockchain-ethereum-dev.pdf
29
access, or delete AMB Access Ethereum resources in your account. These actions can incur costs for your AWS account. When you create or edit identity-based policies, follow these guidelines and recommendations: • Get started with AWS managed policies and move toward least-privilege permissions – To get started granting permissions to your users and workloads, use the AWS managed policies that grant permissions for many common use cases. They are available in your AWS account. We recommend that you reduce permissions further by defining AWS customer managed policies that are specific to your use cases. For more information, see AWS managed policies or AWS managed policies for job functions in the IAM User Guide. • Apply least-privilege permissions – When you set permissions with IAM policies, grant only the permissions required to perform a task. You do this by defining the actions that can be taken on specific resources under specific conditions, also known as least-privilege permissions. For more information about using IAM to apply permissions, see Policies and permissions in IAM in the IAM User Guide. • Use conditions in IAM policies to further restrict access – You can add a condition to your policies to limit access to actions and resources. For example, you can write a policy condition to specify that all requests must be sent using SSL. You can also use conditions to grant access to service actions if they are used through a specific AWS service, such as AWS CloudFormation. For more information, see IAM JSON policy elements: Condition in the IAM User Guide. • Use IAM Access Analyzer to validate your IAM policies to ensure secure and functional permissions – IAM Access Analyzer validates new and existing policies so that the policies Identity and Access Management 89 Amazon Managed Blockchain (AMB) Ethereum Developer Guide adhere to the IAM policy language (JSON) and IAM best practices. IAM Access Analyzer provides more than 100 policy checks and actionable recommendations to help you author secure and functional policies. For more information, see Validate policies with IAM Access Analyzer in the IAM User Guide. • Require multi-factor authentication (MFA) – If you have a scenario that requires IAM users or a root user in your AWS account, turn on MFA for additional security. To require MFA when API operations are called, add MFA conditions to your policies. For more information, see Secure API access with MFA in the IAM User Guide. For more information about best practices in IAM, see Security best practices in IAM in the IAM User Guide. Using the AMB Access Ethereum console To access the Amazon Managed Blockchain (AMB) Access Ethereum console, you must have a minimum set of permissions. These permissions must allow you to list and view details about the AMB Access Ethereum resources in your AWS account. If you create an identity-based policy that is more restrictive than the minimum required permissions, the console won't function as intended for entities (users or roles) with that policy. You don't need to allow minimum console permissions for users that are making calls only to the AWS CLI or the AWS API. Instead, allow access to only the actions that match the API operation that they're trying to perform. To ensure that users and roles can still use the AMB Access Ethereum console, also attach the AMB Access Ethereum ConsoleAccess or ReadOnly AWS managed policy to the entities. For more information, see Adding permissions to a user in the IAM User Guide. AmazonManagedBlockchainConsoleFullAccess Allow users to view their own permissions This example shows how you might create a policy that allows IAM users to view the inline and managed policies that are attached to their user identity. This policy includes permissions to complete this action on the console or programmatically using the AWS CLI or AWS API. { "Version": "2012-10-17", Identity and Access Management 90 Ethereum Developer Guide Amazon Managed Blockchain (AMB) "Statement": [ { "Sid": "ViewOwnUserInfo", "Effect": "Allow", "Action": [ "iam:GetUserPolicy", "iam:ListGroupsForUser", "iam:ListAttachedUserPolicies", "iam:ListUserPolicies", "iam:GetUser" ], "Resource": ["arn:aws:iam::*:user/${aws:username}"] }, { "Sid": "NavigateInConsole", "Effect": "Allow", "Action": [ "iam:GetGroupPolicy", "iam:GetPolicyVersion", "iam:GetPolicy", "iam:ListAttachedGroupPolicies", "iam:ListGroupPolicies", "iam:ListPolicyVersions", "iam:ListPolicies", "iam:ListUsers" ], "Resource": "*" } ] } Performing all available actions for AMB Access Ethereum This example shows how you grant users AWS account access in the us-east-1 Region so that they can do the following: • List all Ethereum networks • Create and list nodes on all those networks • Get and delete nodes in AWS account 111122223333 • Get and delete accessors in AWS account 555555555555 • Create WebSocket connections, and send HTTP requests to an Ethereum node Identity and Access Management 91 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Note • If you want to grant access across all Regions, replace us-east-1 with *. • You must specify the AWS account ID of the node and accessor resources
amazon-managed-blockchain-ethereum-dev-030
amazon-managed-blockchain-ethereum-dev.pdf
30
users AWS account access in the us-east-1 Region so that they can do the following: • List all Ethereum networks • Create and list nodes on all those networks • Get and delete nodes in AWS account 111122223333 • Get and delete accessors in AWS account 555555555555 • Create WebSocket connections, and send HTTP requests to an Ethereum node Identity and Access Management 91 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Note • If you want to grant access across all Regions, replace us-east-1 with *. • You must specify the AWS account ID of the node and accessor resources in the policy that you want to enforce. { "Version": "2012-10-17", "Statement": [ { "Sid": "WorkWithEthereumNetworks", "Effect": "Allow", "Action": [ "managedblockchain:ListNetworks", "managedblockchain:GetNetwork" ], "Resource": [ "arn:aws:managedblockchain:us-east-1::networks/n-ethereum-mainnet" ] }, { "Sid": "CreateAndListEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:CreateNode", "managedblockchain:ListNodes" ], "Resource": [ "arn:aws:managedblockchain:us-east-1::networks/*" ] }, { "Sid": "ManageEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:GetNode", "managedblockchain:DeleteNode" ], Identity and Access Management 92 Amazon Managed Blockchain (AMB) "Resource": [ Ethereum Developer Guide "arn:aws:managedblockchain:us-east-1:111122223333:nodes/*" ] }, { "Sid": "GetAndDeleteAccessors", "Effect": "Allow", "Action": [ "managedblockchain:GetAccessor", "managedblockchain:DeleteAccessor" ], "Resource": [ "arn:aws:managedblockchain:us-east-1:555555555555:accessors/*" ] }, { "Sid": "CreateAndListAccessors", "Effect": "Allow", "Action": [ "managedblockchain:CreateAccessor", "managedblockchain:ListAccessors" ], "Resource": [ "*" ] }, { "Sid": "WorkWithEthereumNodes", "Effect": "Allow", "Action": [ "managedblockchain:POST", "managedblockchain:GET", "managedblockchain:Invoke" ], "Resource": [ "arn:aws:managedblockchain:us-east-1:111122223333:*" ] } ] } Identity and Access Management 93 Amazon Managed Blockchain (AMB) Controlling access using tags Ethereum Developer Guide The following example policies demonstrate how you can use tags to limit access to AMB Access Ethereum resources and actions performed on those resources. Note This topic includes examples of policy statements with a Deny effect. These policies assume that other policies with Allow effect for those actions exist with broader applicability. The Deny policy statement is being used to restrict that otherwise overly-permissive allow statement. Example – Deny access to networks with a specific tag key The following identity-based policy statement denies the IAM principal the ability to retrieve or view network information if the network has a tag with the tag key of restricted. { "Version": "2012-10-17", "Statement": [ { "Sid": "DenyTaggedNetworkAccess", "Effect": "Deny", "Action": [ "managedblockchain:GetNetwork" ], "Resource": [ "*" ], "Condition": { "StringLike": { "aws:ResourceTag/restricted": [ "*" ] } } } ] } Identity and Access Management 94 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Example – Deny node creation on networks that have a specific tag and value The following identity-based policy statement denies the IAM principal the ability to create a node on an Ethereum public network tagged in the AWS account with the tag key of department and the value accounting. { "Version": "2012-10-17", "Statement": [ { "Sid": "DenyCreateNodeForNetworkWithTag", "Effect": "Deny", "Action": [ "managedblockchain:CreateNode" ], "Resource": [ "*" ], "Condition": { "StringEquals": { "aws:ResourceTag/department": [ "accounting" ] } } } ] } Example – Require a specific tag key and value to be added when a node is created The following identity-based policy statements allow an IAM principal to create a node for the AWS account 111122223333 only if a key with the tag key of department and a value of accounting is added during creation. { "Version": "2012-10-17", "Statement": [ { "Sid": "RequireTagForCreateNode", "Effect": "Allow", "Action": [ Identity and Access Management 95 Amazon Managed Blockchain (AMB) Ethereum Developer Guide "managedblockchain:CreateNode" ], "Resource": [ "*" ], "Condition": { "StringEquals": { "aws:RequestTag/department": [ "accounting" ] } } }, { "Sid": "AllowTaggingNodes", "Effect": "Allow", "Action": [ "managedblockchain:TagResource" ], "Resource": [ "arn:aws:managedblockchain:us-east-1:111122223333:nodes/*" ] } ] } Example – Deny listing nodes for networks that have a specific tag key and value The following identity-based policy statement denies the IAM principal the ability to list nodes on an Ethereum public network tagged in the AWS account with the tag key of department and the value accounting. { "Version": "2012-10-17", "Statement": [ { "Sid": "DenyListNodesForNetworkWithTag", "Effect": "Deny", "Action": [ "managedblockchain:ListNodes" ], "Resource": [ "*" Identity and Access Management 96 Ethereum Developer Guide Amazon Managed Blockchain (AMB) ], "Condition": { "StringEquals": { "aws:ResourceTag/department": [ "accounting" ] } } } ] } Example – Deny retrieving and viewing node information for nodes with a specific tag key and value The following identity-based policy statement denies the IAM principal the ability to view node information for nodes that have a tag with the tag key of department and the value accounting. { "Version": "2012-10-17", "Statement": [ { "Sid": "DenyGetNodeWithNodeTag", "Effect": "Deny", "Action": [ "managedblockchain:GetNode" ], "Resource": [ "*" ], "Condition": { "StringEquals": { "aws:ResourceTag/department": [ "accounting" ] } } } ] } Identity and Access Management 97 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Using Service-Linked Roles for AMB Access Amazon Managed Blockchain (AMB) uses AWS Identity and Access Management (IAM) service- linked roles. A service-linked role is a unique type of IAM role that is linked directly to AMB Access. Service-linked roles are predefined by AMB
amazon-managed-blockchain-ethereum-dev-031
amazon-managed-blockchain-ethereum-dev.pdf
31
that have a tag with the tag key of department and the value accounting. { "Version": "2012-10-17", "Statement": [ { "Sid": "DenyGetNodeWithNodeTag", "Effect": "Deny", "Action": [ "managedblockchain:GetNode" ], "Resource": [ "*" ], "Condition": { "StringEquals": { "aws:ResourceTag/department": [ "accounting" ] } } } ] } Identity and Access Management 97 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Using Service-Linked Roles for AMB Access Amazon Managed Blockchain (AMB) uses AWS Identity and Access Management (IAM) service- linked roles. A service-linked role is a unique type of IAM role that is linked directly to AMB Access. Service-linked roles are predefined by AMB Access and include all the permissions that the service requires to call other AWS services on your behalf. A service-linked role can make setting up AMB Access easier because you don’t have to manually add the necessary permissions. AMB Access defines the permissions of its service-linked roles, and, unless defined otherwise, only AMB Access can assume its roles. The defined permissions include the trust policy and the permissions policy. The permissions policy cannot be attached to any other IAM entity. You can delete a service-linked role only after first deleting its related resources. This protects your AMB Access resources because you can't inadvertently remove permission to access the resources. For information about other services that support service-linked roles, see AWS Services That Work with IAM and look for the services that have Yes in the Service-Linked Role column. Choose a Yes with a link to view the service-linked role documentation for that service. Service-Linked Role Permissions for AMB Access AMB Access uses the service-linked role named AWSServiceRoleForAmazonManagedBlockchain. This role enables access to AWS Services and Resources used or managed by Amazon Managed Blockchain. The AWSServiceRoleForAmazonManagedBlockchain service-linked role trusts the following services to assume the role: • managedblockchain.amazonaws.com The role permissions policy allows AMB Access to complete actions on the specified resources shown in the following example policy. { "Version": "2012-10-17", "Statement": [ { "Action": [ "logs:CreateLogGroup" Identity and Access Management 98 Amazon Managed Blockchain (AMB) ], Ethereum Developer Guide "Effect": "Allow", "Resource": "arn:aws:logs:*:*:log-group:/aws/managedblockchain/*" }, { "Effect": "Allow", "Action": [ "logs:CreateLogStream", "logs:PutLogEvents", "logs:DescribeLogStreams" ], "Resource": [ "arn:aws:logs:*:*:log-group:/aws/managedblockchain/*:log-stream:*" ] } ] } You must configure permissions to allow an IAM entity (such as a user, group, or role) to create, edit, or delete a service-linked role. For more information, see Service-Linked Role Permissions in the IAM User Guide. Creating a Service-Linked Role for AMB Access You don't need to manually create a service-linked role. When you create a network, a member, or a peer node, AMB Access creates the service-linked role for you. It doesn't matter if you use the AWS Management Console, the AWS CLI, or the AWS API. The IAM entity performing the action must have permissions to create the service-linked role. After the role is created in your account, AMB Access can use it for all networks and members. If you delete this service-linked role, and then need to create it again, you can use the same process to recreate the role in your account. When you create a network, member, or node, AMB Access creates the service-linked role for you again. Editing a Service-Linked Role for AMB Access AMB Access does not allow you to edit the AWSServiceRoleForAmazonManagedBlockchain service- linked role. After you create a service-linked role, you cannot change the name of the role because various entities might reference the role. However, you can edit the description of the role using IAM. For more information, see Editing a Service-Linked Role in the IAM User Guide. Identity and Access Management 99 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Deleting a Service-Linked Role for AMB Access If you no longer need to use a feature or service that requires a service-linked role, we recommend that you delete that role. That way you don’t have an unused entity that is not actively monitored or maintained. However, you must clean up the resources for your service-linked role before you can manually delete it. Note If the AMB Access service is using the role when you try to delete the resources, then the deletion might fail. If that happens, wait for a few minutes and try the operation again. To manually delete the service-linked role Use the IAM console, the AWS CLI, or the AWS API to delete the AWSServiceRoleForAmazonManagedBlockchain service-linked role. For more information, see Deleting a Service-Linked Role in the IAM User Guide. Supported Regions for AMB Access Service-Linked Roles AMB Access supports using service-linked roles in all of the Regions where the service is available. For more information, see AWS Regions and Endpoints. Identity and Access Management 100 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Tagging Amazon Managed Blockchain (AMB) resources A tag is a custom attribute label that you assign or that AWS assigns to an AWS resource.
amazon-managed-blockchain-ethereum-dev-032
amazon-managed-blockchain-ethereum-dev.pdf
32
the service-linked role Use the IAM console, the AWS CLI, or the AWS API to delete the AWSServiceRoleForAmazonManagedBlockchain service-linked role. For more information, see Deleting a Service-Linked Role in the IAM User Guide. Supported Regions for AMB Access Service-Linked Roles AMB Access supports using service-linked roles in all of the Regions where the service is available. For more information, see AWS Regions and Endpoints. Identity and Access Management 100 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Tagging Amazon Managed Blockchain (AMB) resources A tag is a custom attribute label that you assign or that AWS assigns to an AWS resource. Each tag has two parts: • A tag key, such as CostCenter, Environment, or Project. Tag keys are case-sensitive. • An optional field known as a tag value, such as 111122223333 or Production. Omitting the tag value is the same as using an empty string. Like tag keys, tag values are case-sensitive. Tags help you do the following: • Identify and organize your AWS resources. Many AWS services support tagging, so you can assign the same tag to resources from different services to indicate that the resources are related. For example, you could assign the same tag to an Amazon Managed Blockchain (AMB) node and an EC2 instance that you use as a client for the AMB Access framework. • Track your AWS costs. You activate these tags on the AWS Billing and Cost Management dashboard. AWS uses the tags to categorize your costs and deliver a monthly cost allocation report to you. For more information, see Using cost allocation tags in the AWS Billing User Guide. • Control access to your AWS resources with AWS Identity and Access Management (IAM). For information, see Controlling access using tags in this developer guide and Control access using IAM tags in the IAM User Guide. For more information about tags, see the Tagging Best Practices guide. The following sections provide more information about tags for AMB Access. Create and add tags for AMB Access Ethereum resources You can tag the following resources: • Networks • Nodes Tags that you create for Ethereum public networks are scoped only to the account in which you create them. Other AWSaccounts participating on the network cannot access the tags. Create and add tags for AMB Access Ethereum resources 101 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Tag naming and usage conventions The following basic naming and usage conventions apply to tags used with AMB Access resources: • Each resource can have a maximum of 50 tags. • For each resource, each tag key must be unique, and each tag key can have only one value. • The maximum tag key length is 128 Unicode characters in UTF-8. • The maximum tag value length is 256 Unicode characters in UTF-8. • Allowed characters are letters, numbers, spaces representable in UTF-8, and the following characters: . : + = @ _ / - (hyphen). • Tag keys and values are case-sensitive. As a best practice, decide on a strategy for capitalizing tags, and consistently implement that strategy across all resource types. For example, decide whether to use Costcenter, costcenter, or CostCenter, and use the same convention for all tags. Avoid using similar tags with inconsistent case treatment. • The aws: prefix is reserved for AWS use. You can't edit or delete a tag's key or value when the tag has a tag key with the aws: prefix. Tags with this prefix do not count against your limit of tags per resource. Working with tags You can use the AMB Access console, the AWS CLI, or the AMB Access API to add, edit, or delete tag keys and tag values. You can assign tags when you create a resource, or you can apply tags after the resource is created. For more information about AMB Access API actions for tagging, see the following topics in the Amazon Managed Blockchain (AMB) API Reference: • ListTagsForResource • TagResource • UntagResource Using the AMB Access console, you can add a tag to an Ethereum node when you create it or when viewing node details. You can remove a tag when viewing node details. For more information, see Working with Ethereum nodes using AMB Access. Tag naming and usage conventions 102 Amazon Managed Blockchain (AMB) Ethereum Developer Guide AMB Access allows you to tag public Ethereum networks after you create a node on the network using AMB Access. To add or remove a tag for an Ethereum network using the AWS Management Console 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. If the console doesn't open to the Networks list, choose Networks from the navigation pane. 3. Choose the network from the list. 4. Under Tags, choose Edit tags, and then do one of the following: • To add a tag, choose Add
amazon-managed-blockchain-ethereum-dev-033
amazon-managed-blockchain-ethereum-dev.pdf
33
Access. Tag naming and usage conventions 102 Amazon Managed Blockchain (AMB) Ethereum Developer Guide AMB Access allows you to tag public Ethereum networks after you create a node on the network using AMB Access. To add or remove a tag for an Ethereum network using the AWS Management Console 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. If the console doesn't open to the Networks list, choose Networks from the navigation pane. 3. Choose the network from the list. 4. Under Tags, choose Edit tags, and then do one of the following: • To add a tag, choose Add new tag, enter a Key and optional Value, and then choose Save. • To remove a tag, choose Remove next to the Tag you want to remove, and then choose Save. To add or remove a tag for a node 1. Open the AMB Access console at https://console.aws.amazon.com/managedblockchain/. 2. Choose Networks and then choose an Ethereum network from the list. 3. Under Nodes, choose a Node ID from the list. 4. Choose Tags, choose Edit tags, and then do one of the following: • To add a tag, choose Add new tag, enter a Key and optional Value, and then choose Save. • To remove a tag, choose Remove next to the Tag you want to remove, and then choose Save. Working with tags 103 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Logging Amazon Managed Blockchain API calls using AWS CloudTrail Amazon Managed Blockchain is integrated with AWS CloudTrail, a service that provides a record of actions taken by a user, role, or an AWS service in Managed Blockchain. CloudTrail captures all API calls for Managed Blockchain as events. The calls captured include calls from the Managed Blockchain console and code calls to the Managed Blockchain API operations. If you create a trail, you can enable continuous delivery of CloudTrail events to an Amazon S3 bucket, including events for Managed Blockchain. If you don't configure a trail, you can still view the most recent events in the CloudTrail console in Event history. Using the information that's collected by CloudTrail, you can determine the request that was made to Managed Blockchain, the IP address that the request was made from, who made the request, when it was made, and other additional details. To learn more about CloudTrail, see the AWS CloudTrail User Guide. Managed Blockchain information in CloudTrail CloudTrail is enabled on your AWS account when you create the account. When activity occurs in Managed Blockchain, that activity is recorded in a CloudTrail event along with other AWS service events in Event history. You can view, search, and download recent events in your AWS account. For more information, see Viewing events with CloudTrail Event history. For an ongoing record of events in your AWS account, including events for Managed Blockchain, create a trail. A trail enables CloudTrail to deliver log files to an Amazon S3 bucket. By default, when you create a trail in the console, the trail applies to all AWS Regions that Amazon Managed Blockchain is available in. The trail logs events from all the Regions in the AWS partition and delivers the log files to the S3 bucket that you specify. Additionally, you can configure other AWS services to further analyze and act on the event data that's collected in CloudTrail logs. For more information, see the following: • Creating a trail • CloudTrail supported services and integrations • Configuring Amazon SNS notifications for CloudTrail Managed Blockchain information in CloudTrail 104 Amazon Managed Blockchain (AMB) Ethereum Developer Guide • Receiving CloudTrail log files from multiple Regions and Receiving CloudTrail log files from multiple accounts All your Managed Blockchain actions are logged as management events by CloudTrail and are documented in the Amazon Managed Blockchain API Reference. For example, calls to the CreateNode, GetNode and DeleteNetwork actions generate entries in the CloudTrail log files. Every event or log entry contains information about who generated the request. You can use the identity information to determine the following: • Whether the request was made with root or AWS Identity and Access Management (IAM) user credentials. • Whether the request was made with temporary security credentials for a role or federated user. • Whether the request was made by another AWS service. For more information, see the CloudTrail userIdentity element. Understanding Managed Blockchain log file entries A trail is a configuration that enables delivery of events as log files to an S3 bucket that you specify. Managed Blockchain supports logging management events. For more information, see Logging management events for trails in the AWS CloudTrail User Guide. Managed Blockchain also supports logging data events for Ethereum API calls over HTTP or WebSockets (JSON-RPC API only) connections. For more information, see Using CloudTrail to track Ethereum calls. CloudTrail log files contain one or
amazon-managed-blockchain-ethereum-dev-034
amazon-managed-blockchain-ethereum-dev.pdf
34
• Whether the request was made by another AWS service. For more information, see the CloudTrail userIdentity element. Understanding Managed Blockchain log file entries A trail is a configuration that enables delivery of events as log files to an S3 bucket that you specify. Managed Blockchain supports logging management events. For more information, see Logging management events for trails in the AWS CloudTrail User Guide. Managed Blockchain also supports logging data events for Ethereum API calls over HTTP or WebSockets (JSON-RPC API only) connections. For more information, see Using CloudTrail to track Ethereum calls. CloudTrail log files contain one or more log entries. An event represents a single request from any source. It includes information about the requested action, the date and time of the action, and request parameters. CloudTrail log files aren't an ordered stack trace of the public API calls. This way, they don't appear in any specific order. Example – Management event log entry The following example shows a CloudTrail management event log entry that demonstrates the GetNode action. { "eventVersion": "1.05", Understanding log file entries 105 Amazon Managed Blockchain (AMB) "userIdentity": { Ethereum Developer Guide "type": "AssumedRole", "principalId": "ABCD1EF23G4EXAMPLE56:carlossalazar", "arn": "arn:aws:sts::111122223333:assumed-role/Admin/carlossalazar", "accountId": "111122223333", "accessKeyId": "AKIAIOSFODNN7EXAMPLE", "webIdFederationData": {}, "attributes": { "mfaAuthenticated": "false", "creationDate": "2020-12-10T05:36:38Z" } } }, "eventTime": "2020-12-10T05:50:48Z", "eventSource": "managedblockchain.amazonaws.com", "eventName": "GetNode", "awsRegion": "us-east-1", "sourceIPAddress": "198.51.100.1", "userAgent": "aws-cli/2.0.7 Python/3.7.3 Linux/5.4.58-37.125.amzn2int.x86_64 botocore/2.0.0dev11", "requestParameters": { "networkId": "n-ethereum-mainnet", "nodeId": "nd-6EAJ5VA43JGGNPXOUZP7Y47E4Y" }, "responseElements": null, "requestID": "1e2xa3m4-56p7-8l9e-0ex1-23456a78m90p", "eventID": "ex12345a-m678-901p-23e4-567ex8a9mple", "readOnly": true, "eventType": "AwsApiCall", "recipientAccountId": "111122223333" } Using CloudTrail to track Ethereum calls You can track Ethereum API as data events using CloudTrail. By default, when you create a trail, data events aren't logged. To record Ethereum API calls as CloudTrail data events, you must explicitly add the supported resources or resource types that you want to collect activity to a trail for. Amazon Managed Blockchain supports adding data events using the AWS CLI. For more information, see Log events by using advanced selectors in the AWS CloudTrail User Guide. To log data events for a trail, run the put-event-selectors command after you create the trail. Use the --advanced-event-selectors option to specify the data events to log. The following Using CloudTrail to track Ethereum calls 106 Amazon Managed Blockchain (AMB) Ethereum Developer Guide example demonstrates a put-event-selectors command that logs all Ethereum API calls for a trail that's named my-ethereum-trail in the us-east-1 Region. aws cloudtrail put-event-selectors \ --region us-east-1 \ --trail-name my-ethereum-trail \ --advanced-event-selectors '[{ "Name": "MyDataEventSelectorForEtherumJsonRpcCalls", "FieldSelectors": [ { "Field": "eventCategory", "Equals": ["Data"] }, { "Field": "resources.type", "Equals": ["AWS::ManagedBlockchain::Node"] } ]}]' Example Data event log entry for an Ethereum JSON-RPC API call The following example demonstrates a CloudTrail data event log entry for an Ethereum JSON-RPC API all, web3_clientVersion, from a client to a node in Amazon Managed Blockchain. { "eventVersion": "1.05", "userIdentity": { "type": "AssumedRole", "principalId": "ABCD1EF23G4EXAMPLE56:carlossalazar", "arn": "arn:aws:sts::111122223333:assumed-role/Admin/carlossalazar", "accountId": "111122223333", "accessKeyId": "AKIAIOSFODNN7EXAMPLE", "webIdFederationData": {}, "attributes": { "mfaAuthenticated": "false", "creationDate": "2020-12-11T16:51:12Z" } } }, "eventTime": "2020-12-11T19:56:36Z", "eventSource": "managedblockchain.amazonaws.com", "eventName": "web3_clientVersion", "awsRegion": "us-east-1", "sourceIPAddress": "198.51.100.1", "userAgent": "python-requests/2.23.0", "requestParameters": { "id": 67, "jsonrpc": "2.0", "method": "web3_clientVersion", "params": [] Using CloudTrail to track Ethereum calls 107 Amazon Managed Blockchain (AMB) Ethereum Developer Guide }, "responseElements": { "result": "Geth/v1.9.24-stable-cc05b050/linux-amd64/go1.15.5", "id": 67, "jsonrpc": "2.0" }, "requestID": "1e2xa3m4-56p7-8l9e-0ex1-23456a78m90p", "eventID": "ex12345a-m678-901p-23e4-567ex8a9mple", "readOnly": false, "eventType": "AwsApiCall", "recipientAccountId": "111122223333" } Using CloudTrail to track Ethereum calls 108 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Document history The following table describes important additions to the Amazon Managed Blockchain (AMB) Access Ethereum Developer Guide. Change Description Date Added a getting started topic April 17, 2024 This topic shows you how to perform tasks using AMB Access Ethereum. Each task builds on the previous one, ending in making JSON-RPC calls to your Ethereum node. Ending support for the Goerli network AMB Access Ethereum ended support of the Goerli March 27, 2024 testnet on April 1, 2024. The Ethereum foundation sunset Goerli on April 17, 2024. No new nodes provisioned on the Rinkeby network . You can't provision new nodes on Rinkeby as of August 19, 2023 August 10th, 2023. The Ethereum foundation ceased support of Rinkeby on May 31st, 2023. Updated terminology to change Amazon Managed Blockchain to Amazon Managed Blockchain (AMB) Access Ethereum. Updated terminology to change Amazon Managed Blockchain to Amazon August 10, 2023 July 27, 2023 Amazon Managed Blockchain (AMB) Access Amazon Managed Blockchain (AMB) Access 109 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Token based access (GA) Managed Blockchain (AMB) Access. The Accessor tokens feature is in general availability. This is a convenient alternative to the Signature Version 4 signing process. February 28, 2023 No new nodes provisioned on the Ropsten network . You can't provision new nodes on Ropsten as of February 28, 2023 Token based access (preview) The Merge February 28th, 2023. The Ethereum foundation ceased support of Ropsten on December 31st, 2022. Use Accessor
amazon-managed-blockchain-ethereum-dev-035
amazon-managed-blockchain-ethereum-dev.pdf
35
to Amazon August 10, 2023 July 27, 2023 Amazon Managed Blockchain (AMB) Access Amazon Managed Blockchain (AMB) Access 109 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Token based access (GA) Managed Blockchain (AMB) Access. The Accessor tokens feature is in general availability. This is a convenient alternative to the Signature Version 4 signing process. February 28, 2023 No new nodes provisioned on the Ropsten network . You can't provision new nodes on Ropsten as of February 28, 2023 Token based access (preview) The Merge February 28th, 2023. The Ethereum foundation ceased support of Ropsten on December 31st, 2022. Use Accessor tokens as a convenient alternative to the Signature Version 4 signing process. This feature is in preview release and is subject to change. Mainnet has merged with the Beacon chain's proof-of-stake system. Ethereum nodes on Amazon Managed Blockchai n (AMB) support this change and require no further action on your part. October 21, 2022 September 15, 2022 Goerli support for the Consensus API for the Beacon chain Goerli now supports Consensus APIs for the Beacon chain. Mainnet support for the Consensus API for the Beacon chain Mainnet now supports Consensus APIs for the Beacon chain. August 11, 2022 July 27, 2022 110 Amazon Managed Blockchain (AMB) Ethereum Developer Guide Consensus API for the Beacon chain Release of the Consensus API for the Beacon chain on the June 8, 2022 Ropsten testnet. Görli (Goerli) Release of the Görli (Goerli) testnet. May 2, 2022 Initial Release Initial release. December 15, 2020 111
amazon-managed-blockchain-hyperledger-fabric-dev-001
amazon-managed-blockchain-hyperledger-fabric-dev.pdf
1
Hyperledger Fabric Developer Guide Amazon Managed Blockchain (AMB) Copyright © 2025 Amazon Web Services, Inc. and/or its affiliates. All rights reserved. Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Amazon Managed Blockchain (AMB): Hyperledger Fabric Developer Guide Copyright © 2025 Amazon Web Services, Inc. and/or its affiliates. All rights reserved. Amazon's trademarks and trade dress may not be used in connection with any product or service that is not Amazon's, in any manner that is likely to cause confusion among customers, or in any manner that disparages or discredits Amazon. All other trademarks not owned by Amazon are the property of their respective owners, who may or may not be affiliated with, connected to, or sponsored by Amazon. Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Table of Contents What Is Amazon Managed Blockchain (AMB) Hyperledger Fabric ................................................ 1 How to Get Started with AMB Access Hyperledger Fabric .................................................................. 1 Key Concepts .................................................................................................................................... 3 Networks and Editions ................................................................................................................................ 3 Networks, Proposals, and Members ......................................................................................................... 6 Peer Nodes ..................................................................................................................................................... 6 Connecting to Resources ............................................................................................................................ 7 Getting Started ................................................................................................................................ 9 Prerequisites and Considerations .............................................................................................................. 9 An AWS account .................................................................................................................................... 10 A Linux Client (EC2 Instance) ............................................................................................................. 10 A VPC ....................................................................................................................................................... 11 Permissions to Create an Interface VPC Endpoint ......................................................................... 11 EC2 Security Groups That Allow Communication on Required Ports ......................................... 11 Additional Considerations ................................................................................................................... 13 Step 1: Create the Network and First Member .................................................................................... 13 Step 2: Create an Endpoint ..................................................................................................................... 16 Step 3: Create a Peer Node ..................................................................................................................... 17 Step 4: Set Up a Client ............................................................................................................................. 18 4.1: Install Packages ............................................................................................................................. 19 4.2: Set Up the Fabric CA Client ........................................................................................................ 22 4.3: Clone Samples ............................................................................................................................... 24 4.4: Start the Hyperledger Fabric CLI ............................................................................................... 24 Step 5: Enroll the Member Admin ......................................................................................................... 26 5.1: Create the Certificate File ........................................................................................................... 26 5.2 Enroll the Admin ............................................................................................................................ 27 5.3: Copy Certificates ........................................................................................................................... 29 Step 6: Create a Channel ......................................................................................................................... 29 6.1: Create configtx .............................................................................................................................. 30 6.2: Set an Environment Variable for the Orderer ......................................................................... 35 6.3: Create the Channel ....................................................................................................................... 36 6.4: Join Peer to Channel .................................................................................................................... 36 Step 7: Run Chaincode .............................................................................................................................. 36 7.1: Install Vendor Dependencies ...................................................................................................... 37 iii Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide 7.2: Create Chaincode Package .......................................................................................................... 37 7.3: Install Package .............................................................................................................................. 37 7.4: Verify Package ............................................................................................................................... 37 7.5: Approve Chaincode ....................................................................................................................... 38 7.6: Check Commit Readiness ............................................................................................................ 38 7.7: Commit Chaincode ....................................................................................................................... 38 7.8: Verify Chaincode ........................................................................................................................... 38 7.9: Initialize Chaincode ...................................................................................................................... 39 7.10: Query Chaincode ........................................................................................................................ 39 7.11: Invoke Chaincode ........................................................................................................................ 39 Step 8: Invite a Member and Create a Multi-Member Channel ........................................................ 40 8.1: Create an Invitation Proposal ..................................................................................................... 41 8.2: Vote Yes on the Proposal ............................................................................................................ 42 8.3: Create the New Member ............................................................................................................. 42 8.4: Share Artifacts ............................................................................................................................... 44 8.5: Create Artifacts for the MSP ...................................................................................................... 45 8.6: Create configtx .............................................................................................................................. 46 8.7 Create the Channel ........................................................................................................................ 52 8.8: Get the Genesis Block .................................................................................................................. 52 8.9: Join Peer Nodes to the Channel ................................................................................................ 53 8.10: Install Chaincode ........................................................................................................................ 53 8.11: Query Chaincode ........................................................................................................................ 54 8.12: Invoke Chaincode ........................................................................................................................ 54 Create a Network ........................................................................................................................... 56 Create a Hyperledger Fabric Network ................................................................................................... 56 Delete a Network ........................................................................................................................... 59 Invite or Remove Members ........................................................................................................... 60 Create an Invitation Proposal .................................................................................................................. 60 Create a Removal Proposal ...................................................................................................................... 62 Delete a Member in Your AWS Account ................................................................................................ 63 Accept an Invitation and Create a Member ................................................................................. 64 Work with Invitations ................................................................................................................................ 65 Create a Member ........................................................................................................................................ 66 Create an Interface VPC Endpoint ................................................................................................ 69 Work with Peer Nodes .................................................................................................................. 71 Create a Peer Node .................................................................................................................................... 72 iv Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide View Peer Node Properties ...................................................................................................................... 73 Use Peer Node Metrics .............................................................................................................................. 75 Viewing Peer Node Metrics ................................................................................................................. 77 Work with Proposals ..................................................................................................................... 79 ....................................................................................................................................................................... 79 View Proposals ............................................................................................................................................ 82 Vote on a Proposal .................................................................................................................................... 84 Create an Invitation Proposal .................................................................................................................. 85 Create a Removal Proposal ...................................................................................................................... 86 Automating with CloudWatch Events .................................................................................................... 87 Example AMB Access Events .............................................................................................................. 88 Work with Hyperledger Fabric ...................................................................................................... 90 Create an Admin ........................................................................................................................................ 90 Registering an Admin ........................................................................................................................... 92 Enrolling an Admin ............................................................................................................................... 92 Copying the Admin Certificate ........................................................................................................... 93 Work with Channels .................................................................................................................................. 93 Create a Channel .................................................................................................................................. 94 Add an Anchor Peer to a Channel ....................................................................................................... 106 Prerequisites and Assumptions ........................................................................................................ 106 Adding a Peer as an Anchor Peer ................................................................................................... 107 Develop Chaincode .................................................................................................................................. 110 Considerations and Limitations When Developing Chaincode for AMB Access ...................... 110 Private Data Collections .................................................................................................................... 112 Develop Java Chaincode ................................................................................................................... 113 API Reference ............................................................................................................................... 125 Security ........................................................................................................................................ 126 Data Protection ........................................................................................................................................ 126 Data Encryption .................................................................................................................................. 127 Encryption at Rest .............................................................................................................................. 127 Encryption in Transit .......................................................................................................................... 136 Authentication and Access Control ...................................................................................................... 136 Identity and Access Management ................................................................................................... 137 Configuring Security Groups ................................................................................................................. 175 Tagging resources ........................................................................................................................ 180 Create and add tags for AMB Access Hyperledger Fabric resources .............................................. 180 v
amazon-managed-blockchain-hyperledger-fabric-dev-002
amazon-managed-blockchain-hyperledger-fabric-dev.pdf
2
....................................................................................................... 106 Prerequisites and Assumptions ........................................................................................................ 106 Adding a Peer as an Anchor Peer ................................................................................................... 107 Develop Chaincode .................................................................................................................................. 110 Considerations and Limitations When Developing Chaincode for AMB Access ...................... 110 Private Data Collections .................................................................................................................... 112 Develop Java Chaincode ................................................................................................................... 113 API Reference ............................................................................................................................... 125 Security ........................................................................................................................................ 126 Data Protection ........................................................................................................................................ 126 Data Encryption .................................................................................................................................. 127 Encryption at Rest .............................................................................................................................. 127 Encryption in Transit .......................................................................................................................... 136 Authentication and Access Control ...................................................................................................... 136 Identity and Access Management ................................................................................................... 137 Configuring Security Groups ................................................................................................................. 175 Tagging resources ........................................................................................................................ 180 Create and add tags for AMB Access Hyperledger Fabric resources .............................................. 180 v Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Tag naming and usage conventions .................................................................................................... 181 Working with tags ................................................................................................................................... 181 Add or remove tags ........................................................................................................................... 182 Monitoring ................................................................................................................................... 185 Considerations and Limitations ............................................................................................................ 186 Enabling and Disabling Logs ................................................................................................................. 186 Enabling and Disabling Peer Node and Chaincode Logs ............................................................ 186 Enabling and Disabling CA Logs ..................................................................................................... 187 Working with Logged Events in the AMB Access Console ............................................................... 187 Searching (Filtering) Logged Events ............................................................................................... 188 Downloading Logged Events ........................................................................................................... 188 Viewing Different Chaincode Logs .................................................................................................. 189 Identifying Logs in CloudWatch Logs .................................................................................................. 190 CloudTrail logs ............................................................................................................................. 191 Managed Blockchain information in CloudTrail ................................................................................ 191 Understanding Managed Blockchain log file entries ........................................................................ 192 Document History ........................................................................................................................ 194 AWS Glossary ............................................................................................................................... 197 vi Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide What Is Amazon Managed Blockchain (AMB) Hyperledger Fabric? Amazon Managed Blockchain (AMB) Access provides you with public blockchain nodes for Ethereum and Bitcoin, and you can also create private blockchain networks with the Hyperledger Fabric framework. Choose from various methods to engage with public blockchains, including fully managed, single-tenant (dedicated), and serverless multi-tenant API operations to public blockchain nodes. For use cases where access controls are important, you can choose from fully managed private blockchain networks. Standardized API operations give you instant scalability on a fully managed, resilient infrastructure, so you can build blockchain applications. AMB Access gives you two distinct types of blockchain infrastructure services: multi-tenant blockchain network access API operations and dedicated blockchain nodes and networks. With dedicated blockchain infrastructure, you can create and use public Ethereum blockchain nodes and private Hyperledger Fabric blockchain networks for your own use. Multi-tenant, API-based offerings, however, such as AMB Access Bitcoin, are composed of a fleet of Bitcoin nodes behind an API layer where the underlying blockchain node infrastructure is shared among customers. You can deploy a private, permissioned blockchain with the Hyperledger Fabric framework in minutes without complex configuration tasks. Once your network is created, you can launch one or more blockchain peer nodes for high availability using the AWS Management Console. Whether your use case demands a large consortium of members to join the network or you simply wish to create a development network within your organization, AMB simplifies the process. You can invite other organizations to join your blockchain network through their AWS accounts, or you can create additional members (organizations) in your AWS account to build a simulated network for testing. This guide covers the fundamentals of creating and working with a Hyperledger Fabric blockchain network using AMB Access. For information about working with AMB Access Ethereum, see Amazon Managed Blockchain (AMB) Access Ethereum Developer Guide. How to Get Started with AMB Access Hyperledger Fabric We recommend the following resources to get started with Hyperledger Fabric networks and chaincode on AMB Access: • Key Concepts: Amazon Managed Blockchain (AMB) Networks, Members, and Peer Nodes How to Get Started with AMB Access Hyperledger Fabric 1 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide This overview helps you understand the fundamental building blocks of a Hyperledger Fabric network on AMB Access. It also tells you how to identify and communicate with network resources. • Get Started Creating a Hyperledger Fabric Blockchain Network Using Amazon Managed Blockchain (AMB) Use this tutorial to create your first Hyperledger Fabric network, set up a Hyperledger Fabric client on EC2, and use the open-source Hyperledger Fabric peer CLI to query and update the ledger. You then invite another member to the network. The member can be from a different AWS account, or you can invite a new member in your own account to simulate a multi-account network. The new member then queries and updates the ledger. • Hyperledger Fabric Documentation (v2.2) The open-source documentation for Hyperledger Fabric is a starting point for key concepts and the architecture of the Hyperledger Fabric blockchain network that you build using AMB Access. As you develop your blockchain application, you can reference this document for key tasks and code samples. Use the documentation version that corresponds to the version of Hyperledger Fabric that you use. How to Get Started with AMB Access Hyperledger Fabric 2 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Key Concepts: Amazon Managed Blockchain (AMB) Networks,
amazon-managed-blockchain-hyperledger-fabric-dev-003
amazon-managed-blockchain-hyperledger-fabric-dev.pdf
3
network. The new member then queries and updates the ledger. • Hyperledger Fabric Documentation (v2.2) The open-source documentation for Hyperledger Fabric is a starting point for key concepts and the architecture of the Hyperledger Fabric blockchain network that you build using AMB Access. As you develop your blockchain application, you can reference this document for key tasks and code samples. Use the documentation version that corresponds to the version of Hyperledger Fabric that you use. How to Get Started with AMB Access Hyperledger Fabric 2 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Key Concepts: Amazon Managed Blockchain (AMB) Networks, Members, and Peer Nodes A blockchain network is a peer-to-peer network running a decentralized blockchain framework. A Hyperledger Fabric network on Amazon Managed Blockchain (AMB) includes one or more members. Members are unique identities in the network. For example, a member might be an organization in a consortium of banks. A single AWS account might have multiple members. Each member runs one or more Hyperledger Fabric peer nodes. The peer nodes run chaincode, endorse transactions, and store a local copy of ledger. Amazon Managed Blockchain (AMB) creates and manages these components for each member in a network. AMB Access also creates components that all network members share, such as the Hyperledger Fabric ordering service and the general networking configuration. Note What we call members in a Hyperledger Fabric network on AMB Access is very similar to what Hyperledger Fabric calls organizations. AMB Access Hyperledger Fabric Networks and Editions When creating a Hyperledger Fabric network, the creator chooses the framework version and the edition of Amazon Managed Blockchain (AMB) to use. The edition determines the capacity and capabilities of the network as a whole. The creator also must create the first network member. Additional members are added through a proposal and voting process. There is no charge for the network itself, but each member pays an hourly rate (billed per second) for their network membership. Charges vary depending on the edition of the network. Each member also pays for peer nodes, peer node storage, and the amount of data that the member writes to the network. For more information about available editions and their attributes, see Amazon Managed Blockchain (AMB) Pricing. For more information about the number of networks that each AWS account can create and join, see Amazon Managed Blockchain (AMB) Limits in the AWS General Reference. A Hyperledger Fabric network on AMB Access remains active as long as there are members. The network is deleted only when the last member deletes itself from the network. No member or AWS Networks and Editions 3 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide account, even the creator's AWS account, can delete the network until they are the last member and delete themselves. The following diagram shows the basic components of a Hyperledger Fabric blockchain running on AMB Access. Networks and Editions 4 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Networks and Editions 5 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Inviting and Removing Members An AWS account initially creates a Hyperledger Fabric network on AMB Access, but the network is not owned by that AWS account or any other AWS account. The network is decentralized, so changes to the network are made by consensus. To make changes to the network, members make proposals that all other members in the network vote on. For another AWS account to join the network, for example, an existing member creates a proposal to invite the account. Other members then vote Yes or No on the proposal. If the proposal is approved, an invitation is sent to the AWS account. The account then accepts the invitation and creates a member to join the network. A similar proposal process is required to remove a member in a different AWS account. A principal in an AWS account with sufficient permissions can remove a member that the account owns at any time by deleting that member directly, without submitting a proposal. The network creator also defines a voting policy for the network during creation. The voting policy determines the basic rules for all proposal voting on the network. The voting policy includes the percentage of votes required to pass the proposal, and the duration before the vote expires. Peer Nodes When a member joins the network, one of the first things they must do is create at least one peer node in the membership. Blockchain networks contain a distributed, cryptographically secure ledger that maintains the history of transactions in the network that is immutable—it can't be changed after-the fact. Each peer node also holds the global state of the network for the channels in which they participate. The global state is updated with each new transaction. When a new peer node in a channel comes online, it
amazon-managed-blockchain-hyperledger-fabric-dev-004
amazon-managed-blockchain-hyperledger-fabric-dev.pdf
4
to pass the proposal, and the duration before the vote expires. Peer Nodes When a member joins the network, one of the first things they must do is create at least one peer node in the membership. Blockchain networks contain a distributed, cryptographically secure ledger that maintains the history of transactions in the network that is immutable—it can't be changed after-the fact. Each peer node also holds the global state of the network for the channels in which they participate. The global state is updated with each new transaction. When a new peer node in a channel comes online, it fetches the global state and ledger from other peers. Even if there are no other peer nodes on a network, as long as a member exists, ledger data can be restored to a new peer node. Peer nodes also interact to create and endorse the transactions that are proposed on the network to update the ledger. The members define the rules in the endorsement process based on their business logic. In this way, every member can conduct transactions as allowed by the business logic and independently verify the transaction history without a centralized authority. Networks, Proposals, and Members 6 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Note Limit transactions to less than 4 MB. Transactions greater than 4 MB result in an error. To configure Hyperledger Fabric applications on peer nodes and to interact with other network resources, members use a client configured with open-source Hyperledger Fabric tools such as a CLI or SDK. The applications and tools that you choose and your client setup depend on your preferred development environment. For example, in the Getting Started tutorial, you configure an Amazon EC2 instance in a VPC with open-source Hyperledger Fabric CLI tools. Identifying AMB Access Resources and Connecting from a Client Because a Hyperledger Fabric blockchain network is decentralized, members must interact with each other's peer nodes and network-wide resources to make transactions, endorse transactions, verify members, and so on. When a network is created, AMB Access gives the network a unique ID. Similarly, when an AWS account creates a member on the network and peer nodes, AMB Access gives unique IDs to those resources. Each network resource has a unique, addressable endpoint that AMB Access creates from these IDs. Other members of the network, Hyperledger Fabric chaincode, and other tools use these endpoints to identify and interact with resources on the network. Resource endpoints for a Hyperledger Fabric network on AMB Access are in the following format: ResourceID.MemberID.NetworkID.managedblockchain.AWSRegion.amazonaws.com:PortNumber For example, to refer to a peer node with ID nd-6EAJ5VA43JGGNPXOUZP7Y47E4Y, owned by a member with ID m-K46ICRRXJRCGRNNS4ES4XUUS5A, in a Hyperledger Fabric network with ID n- MWY63ZJZU5HGNCMBQER7IN6OIU, you use the following peer node endpoint: nd-6EAJ5VA43JGGNPXOUZP7Y47E4Y.m-K46ICRRXJRCGRNNS4ES4XUUS5A.n- MWY63ZJZU5HGNCMBQER7IN6OIU.managedblockchain.us-east-1.amazonaws.com:30003 The port that you use with an endpoint depends on the Hyperledger Fabric service that you are calling and your unique network setup. AWSRegion is the Region you are using. For a list of supported Regions, see Amazon Managed Blockchain (AMB) Endpoints and Quotas in the Amazon Web Services General Reference. Connecting to Resources 7 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Within the Hyperledger Fabric network, access and authorization for each resource is governed by processes defined in the chaincode and network configurations such as Hyperledger Fabric channels. Outside the confines of the network—that is, from member's client applications and tools—AMB Access uses AWS PrivateLink to ensure that only network members can access required resources. In this way, each member has a private connection from a client in their VPC to the Hyperledger Fabric network on AMB Access. The interface VPC endpoint uses private DNS, so you must have a VPC in your account that is enabled for Private DNS. For more information, see Create an Interface VPC Endpoint for Amazon Managed Blockchain (AMB) Hyperledger Fabric. Connecting to Resources 8 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Get Started Creating a Hyperledger Fabric Blockchain Network Using Amazon Managed Blockchain (AMB) This tutorial guides you through creating your first Hyperledger Fabric network using Amazon Managed Blockchain (AMB). It shows you how to set up the network and create a member in your AWS account, set up chaincode and a channel, and then invite members from other AWS accounts to join a channel. Instructions for invitees are also provided. Steps • Prerequisites and Considerations • Step 1: Create the Network and First Member • Step 2: Create and Configure the Interface VPC Endpoint • Step 3: Create a Peer Node in Your Membership • Step 4: Create an Amazon EC2 Instance and Set Up the Hyperledger Fabric Client • Step 5: Enroll an Administrative User • Step 6: Create a Hyperledger Fabric Channel • Step 7: Install and Run Chaincode • Step 8: Invite Another AWS Account to be a Member and
amazon-managed-blockchain-hyperledger-fabric-dev-005
amazon-managed-blockchain-hyperledger-fabric-dev.pdf
5
then invite members from other AWS accounts to join a channel. Instructions for invitees are also provided. Steps • Prerequisites and Considerations • Step 1: Create the Network and First Member • Step 2: Create and Configure the Interface VPC Endpoint • Step 3: Create a Peer Node in Your Membership • Step 4: Create an Amazon EC2 Instance and Set Up the Hyperledger Fabric Client • Step 5: Enroll an Administrative User • Step 6: Create a Hyperledger Fabric Channel • Step 7: Install and Run Chaincode • Step 8: Invite Another AWS Account to be a Member and Create a Multi-Member Channel Prerequisites and Considerations To complete this tutorial, you must have the resources listed in this section. Unless specifically stated otherwise, the requirements apply to both network creators and invited members. Topics • An AWS account • A Linux Client (EC2 Instance) • A VPC • Permissions to Create an Interface VPC Endpoint • EC2 Security Groups That Allow Communication on Required Ports • Additional Considerations Prerequisites and Considerations 9 Amazon Managed Blockchain (AMB) An AWS account Hyperledger Fabric Developer Guide Before you use AMB Access for the first time, you must sign up for an Amazon Web Services (AWS) account. If you do not have an AWS account, complete the following steps to create one. To sign up for an AWS account 1. Open https://portal.aws.amazon.com/billing/signup. 2. Follow the online instructions. Part of the sign-up procedure involves receiving a phone call and entering a verification code on the phone keypad. When you sign up for an AWS account, an AWS account root user is created. The root user has access to all AWS services and resources in the account. As a security best practice, assign administrative access to a user, and use only the root user to perform tasks that require root user access. A Linux Client (EC2 Instance) You must have a Linux computer with access to resources in the VPC to serve as your Hyperledger Fabric client. This computer must have version 1.16.149 or later of the AWS CLI installed. Earlier versions of the AWS CLI do not have the managedblockchain command. We recommend that you use the latest version of the AWS CLI available. For information about updating the AWS CLI, see Update the AWS CLI version 2 on Linux in the AWS Command Line Interface User Guide. We recommend creating an Amazon Elastic Compute Cloud (Amazon EC2) instance in the same VPC and AWS Region as the VPC endpoint for the Hyperledger Fabric network on AMB Access. This is the setup that the tutorial uses. For instructions to set up a Hyperledger Fabric client using this configuration, see Step 4: Create an Amazon EC2 Instance and Set Up the Hyperledger Fabric Client. An AWS CloudFormation template to create a Hyperledger Fabric client is available in the amazon- managed-blockchain-client-templates repository on Github. For more information, see the readme.md in that repository. For more information about using AWS CloudFormation, see Getting Started in the AWS CloudFormation User Guide. An AWS account 10 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide A VPC You must have a VPC with an IPv4 CIDR block, and the enableDnsHostnames and enableDnsSupport options must be set to true. If you will connect to the Hyperledger Fabric client using SSH, the VPC must have an internet gateway, and the security group configuration associated with the Hyperledger Framework client must allow inbound SSH access from your SSH client. • For more information about creating a suitable network, see Getting Started with IPv4 for Amazon VPC tutorial in the Amazon VPC User Guide. • For information about using SSH to connect to an Amazon EC2 Instance, see Connecting to Your Linux Instance Using SSH in the Amazon EC2 User Guide. • For instructions about how to verify if DNS options are enabled, see Using DNS with Your VPC in the Amazon VPC User Guide. Permissions to Create an Interface VPC Endpoint The IAM principal (user) identity that you are using must have sufficient IAM permissions to create an interface VPC endpoint in your AWS account. For more information, see Controlling Access - Creating and Managing VPC Endpoints in the Amazon VPC User Guide. EC2 Security Groups That Allow Communication on Required Ports The EC2 security groups associated with the Hyperledger Fabric client Amazon EC2 instance and the Interface VPC Endpoint that you create during this tutorial must have rules that allow traffic between them for required Hyperledger Fabric services. EC2 security groups are restrictive by default, so you need to create security group rules that allow required access. In addition, a security group associated with the Hyperledger Fabric client Amazon EC2 instance must have an inbound rule that allows SSH traffic (Port 22) from trusted SSH clients. For the purposes of simplicity in
amazon-managed-blockchain-hyperledger-fabric-dev-006
amazon-managed-blockchain-hyperledger-fabric-dev.pdf
6
EC2 Security Groups That Allow Communication on Required Ports The EC2 security groups associated with the Hyperledger Fabric client Amazon EC2 instance and the Interface VPC Endpoint that you create during this tutorial must have rules that allow traffic between them for required Hyperledger Fabric services. EC2 security groups are restrictive by default, so you need to create security group rules that allow required access. In addition, a security group associated with the Hyperledger Fabric client Amazon EC2 instance must have an inbound rule that allows SSH traffic (Port 22) from trusted SSH clients. For the purposes of simplicity in this tutorial, we recommend that you create an EC2 security group that you associate only with the Hyperledger Fabric client Amazon EC2 instance and the Interface VPC Endpoint. Then create an inbound rule that allows all traffic from within the security group. In addition, create another security group to associate with the Hyperledger Fabric client Amazon EC2 instance that allows inbound SSH traffic from trusted clients. A VPC 11 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Important This security group configuration is recommended for this tutorial only. Carefully consider security group settings for your desired security posture. For information about the minimum required rules, see Configuring Security Groups for Amazon Managed Blockchain (AMB) Hyperledger Fabric. To create a security group that allows traffic between the Hyperledger Fabric client and the interface VPC endpoint for use in this tutorial 1. Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/. 2. Choose Security groups in the navigation pane, and then choose Create security group. 3. Enter a Security group name and Description for the security group that helps you find it. For example, HFClientAndEndpoint. 4. Make sure that the VPC you select is the default VPC for your account. This is the VPC in which Hyperledger Fabric network resources and the interface VPC endpoint are created. 5. Choose Create. 6. Select the security group that you just created from the list, choose Inbound, and then choose Edit. 7. Under Type, select All traffic from the list. 8. Under Source, leave Custom selected, and then begin typing the name or ID of this same security group—for example, HFClientAndEndpoint—and then select the security group so that its ID appears under Source. 9. Choose Save. You reference this security group later in this tutorial in Step 2: Create and Configure the Interface VPC Endpoint and Step 4: Create an Amazon EC2 Instance and Set Up the Hyperledger Fabric Client. To create a security group for the Hyperledger Fabric client that allows inbound SSH connections from the computer that you are working with 1. Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/. 2. Choose Security groups in the navigation pane, and then choose Create security group. EC2 Security Groups That Allow Communication on Required Ports 12 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide 3. Enter a Security group name and Description for the security group that helps you find it. For example, HFClientSSH. 4. Make sure that the VPC you select is the same VPC that you will select for the interface VPC endpoint. 5. Choose Inbound, and then choose Add rule. 6. Under Type, select SSH from the list. 7. Under Source, select My IP. This adds the detected IP address of your current computer. Optionally, you can create additional rules for SSH connections from additional IP addresses or sources if required. 8. Choose Create. You will reference this security group later in this tutorial in Step 4: Create an Amazon EC2 Instance and Set Up the Hyperledger Fabric Client. Additional Considerations • All commands in the tutorial assume that you are using an Amazon EC2 instance with an Amazon Linux AMI. Unless noted otherwise, instructions also assume that you are running commands in the default home directory (/home/ec2-user). If you have a different configuration, modify instructions to fit your home directory as necessary. • Hyperledger Fabric 2.2 requires that a channel ID contain only lowercase ASCII alphanumeric characters, dots (.), and dashes (-). It must start with a letter, and must be fewer than 250 characters. Step 1: Create the Network and First Member When you create the network, you specify the following parameters along with basic information such as names and descriptions: • The open-source framework and version. This tutorial uses Hyperledger Fabric version 2.2. • The voting policy for proposals on the network. For more information, see Work with Proposals for a Hyperledger Fabric Network on Amazon Managed Blockchain (AMB). • The first member of the network, including the administrative user and administrative password that are used to authenticate to the member's certificate authority (CA). Additional Considerations 13 Amazon Managed Blockchain (AMB) Hyperledger Fabric Developer Guide Important Each member that is created accrues charges according to the membership rate for the network. For