Logging Amazon Snowball Edge API calls with Amazon CloudTrail
The Amazon Snowball or Snowball Edge service integrates with Amazon CloudTrail, a service that provides a record of actions taken by a user, role, or service. CloudTrail captures all API calls for Amazon Snowball Edge service. The calls captured include calls from the Amazon Snowball Family console and code calls to the Amazon Snowball Family Job Management API. If you create a trail, you can enable continuous delivery of CloudTrail events to an Amazon S3 bucket, including events for Amazon Snowball Family API calls. 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 collected by CloudTrail, you can determine the request made with Amazon Snowball Family API, the IP address of the request made, who made the request, when it was made, and additional details.
To learn more about CloudTrail, see the Amazon CloudTrail User Guide.
Amazon Snowball Edge information in CloudTrail
CloudTrail is enabled on your Amazon Web Services account when you create the account. When activity occurs in Amazon Snowball Edge, that activity is recorded in a CloudTrail event along with other Amazon service events in Event history. You can view, search, and download recent events in your Amazon Web Services account. For more information, see Viewing Events with CloudTrail Event History in the Amazon CloudTrail User Guide.
For an ongoing record of events in your Amazon Web Services account, including events for Amazon Snowball Edge, 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 Amazon Regions. The trail logs events from all Amazon Web Services Regions in the Amazon partition and delivers the log files to the Amazon S3 bucket that you specify. Additionally, you can configure other Amazon services to further analyze and act upon the event data collected in CloudTrail logs. For more information, see the following topics in the Amazon CloudTrail User Guide:
All job management actions are documented in the Amazon Snowball API Reference and are logged by CloudTrail with the following exceptions:
-
The CreateAddress operation is not logged to protect customer sensitive information.
-
All read-only API calls (for API operations beginning with the prefix of
Get
,Describe
, orList
) don't record response elements.
Every event or log entry contains information about who generated the request. The identity information helps you determine the following:
-
Whether the request was made with root or Amazon 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 Amazon service.
For more information, see the CloudTrail userIdentity Element in the Amazon CloudTrail User Guide.
Understanding log file entries for Amazon Snowball Edge
A trail is a configuration that enables delivery of events as log files to an Amazon S3 bucket that you specify. CloudTrail log files contain one or more log entries. An event represents a single request from any source and includes information about the requested action, the date and time of the action, request parameters, and so on. CloudTrail log files aren't an ordered stack trace of the public API calls, so they don't appear in any specific order.
The following example shows a CloudTrail log entry that demonstrates the DescribeJob operation.
{"Records": [ { "eventVersion": "1.05", "userIdentity": { "type": "Root", "principalId": "111122223333", "arn": "arn:aws:iam::111122223333:root", "accountId": "111122223333", "accessKeyId": "AKIAIOSFODNN7EXAMPLE", "sessionContext": {"attributes": { "mfaAuthenticated": "false", "creationDate": "2019-01-22T21:58:38Z" }}, "invokedBy": "signin.amazonaws.com" }, "eventTime": "2019-01-22T22:02:21Z", "eventSource": "snowball.amazonaws.com", "eventName": "DescribeJob", "awsRegion": "eu-west-1", "sourceIPAddress": "192.0.2.0", "userAgent": "signin.amazonaws.com", "requestParameters": {"jobId": "JIDa1b2c3d4-0123-abcd-1234-0123456789ab"}, "responseElements": null, "requestID": "12345678-abcd-1234-abcd-ab0123456789", "eventID": "33c7ff7c-3efa-4d81-801e-7489fe6fff62", "eventType": "AwsApiCall", "recipientAccountId": "444455556666" } ]}