Skip to content

Commit 9c91745

Browse files
committed
fix typos in the readme
1 parent 0e9b045 commit 9c91745

File tree

2 files changed

+12
-16
lines changed

2 files changed

+12
-16
lines changed

Examples/S3_AWSSDK/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
# API Gateway
1+
# List Amazon S3 Buckets with the AWS SDK for Swift
22

33
This is a simple example of an AWS Lambda function that uses the [AWS SDK for Swift](https://github.com/awslabs/aws-sdk-swift) to read data from Amazon S3.
44

55
## Code
66

7-
The Lambda function reads all bucket names from your AWS account and return them as a String.
7+
The Lambda function reads all bucket names from your AWS account and returns them as a String.
88

99
The code creates a `LambdaRuntime` struct. In it's simplest form, the initializer takes a function as argument. The function is the handler that will be invoked when the API Gateway receives an HTTP request.
1010

@@ -17,7 +17,7 @@ The function must return a `APIGatewayV2Response`.
1717
`APIGatewayV2Request` and `APIGatewayV2Response` are defined in the [Swift AWS Lambda Events](https://github.com/swift-server/swift-aws-lambda-events) library.
1818

1919
The handler creates an S3 client and `ListBucketsInput` object. It passes the input object to the client and receives an output response.
20-
It then extract the list of bucket names from the output to create a `\n` separated list of names, as a `String`
20+
It then extracts the list of bucket names from the output and creates a `\n`-separated list of names, as a `String`
2121

2222
## Build & Package
2323

@@ -77,9 +77,10 @@ This should print text similar to
7777
```bash
7878
my_bucket_1
7979
my_bucket_2
80+
...
8081
```
8182

82-
## Undeploy
83+
## Delete the infrastructure
8384

8485
When done testing, you can delete the infrastructure with this command.
8586

Examples/S3_Soto/README.md

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,10 @@
1-
sam deploy \
2-
--resolve-s3 \
3-
--template-file template.yaml \
4-
--stack-name AWSSDKExample \
5-
--capabilities CAPABILITY_IAM
6-
7-
# API Gateway
1+
# List Amazon S3 Buckets with Soto
82

93
This is a simple example of an AWS Lambda function that uses the [Soto SDK for AWS](https://github.com/soto-project/soto) to read data from Amazon S3.
104

115
## Code
126

13-
The Lambda function reads all bucket names from your AWS account and return them as a String.
7+
The Lambda function reads all bucket names from your AWS account and returns them as a String.
148

159
The code creates a `LambdaRuntime` struct. In it's simplest form, the initializer takes a function as argument. The function is the handler that will be invoked when the API Gateway receives an HTTP request.
1610

@@ -22,12 +16,12 @@ The function must return a `APIGatewayV2Response`.
2216

2317
`APIGatewayV2Request` and `APIGatewayV2Response` are defined in the [Swift AWS Lambda Events](https://github.com/swift-server/swift-aws-lambda-events) library.
2418

25-
The handler creates AWS and S3 clients. It then calls `listBuckets()` on the S3 client and receives an output response.
26-
It then extract the list of bucket names from the output to create a `\n` separated list of names, as a `String`
19+
The handler creates two clients : an AWS client that manages the communication with AWS API and and the S3 client that expose the S3 API. Then, the handler calls `listBuckets()` on the S3 client and receives an output response.
20+
Finally, the handler extracts the list of bucket names from the output to create a `\n`-separated list of names, as a `String`.
2721

2822
## Build & Package
2923

30-
To build the package, type the following commands.
24+
To build the package, type the following command.
3125

3226
```bash
3327
swift build
@@ -83,9 +77,10 @@ This should print text similar to
8377
```bash
8478
my_bucket_1
8579
my_bucket_2
80+
...
8681
```
8782

88-
## Undeploy
83+
## Delete the infrastructure
8984

9085
When done testing, you can delete the infrastructure with this command.
9186

0 commit comments

Comments
 (0)