Skip to content

Commit ada1fc9

Browse files
committed
fix typos
1 parent 85c7805 commit ada1fc9

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

Examples/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ This directory contains example code for Lambda functions.
3636

3737
- **[Streaming](Streaming/README.md)**: create a Lambda function exposed as an URL. The Lambda function streams its response over time. (requires [AWS SAM](https://aws.amazon.com/serverless/sam/)).
3838

39-
- **[StreamingFromEvent](StreamingFromEvent/README.md)**: a Lambda function that combines JSON input decoding with response streaming capabilities, demonstrating the new streaming codable interface (requires [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)).
39+
- **[StreamingFromEvent](StreamingFromEvent/README.md)**: a Lambda function that combines JSON input decoding with response streaming capabilities, demonstrating the new streaming codable interface (requires [AWS SAM](https://aws.amazon.com/serverless/sam/) or the [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)).
4040

4141
- **[Testing](Testing/README.md)**: a test suite for Lambda functions.
4242

Examples/StreamingFromEvent/README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Where:
3636
- `message`: The message content to repeat
3737
- `delayMs`: Optional delay between messages in milliseconds (defaults to 500ms)
3838

39-
The response is streamed through the `LambdaResponseStreamWriter`, which is passed as an argument in the `handle` function. The code calls the `write(_:)` function of the `LambdaResponseStreamWriter` with partial data repeatedly written before finally closing the response stream by calling `finish()`. Developers can also choose to return the entire output and not stream the response by calling `writeAndFinish(_:)`.
39+
The response is streamed through the `LambdaResponseStreamWriter`, which is passed as an argument in the `handle` function. The code calls the `write(_:)` function of the `LambdaResponseStreamWriter` with partial data written repeatedly before finally closing the response stream by calling `finish()`. Developers can also choose to return the entire output and not stream the response by calling `writeAndFinish(_:)`.
4040

4141
An error is thrown if `finish()` is called multiple times or if it is called after having called `writeAndFinish(_:)`.
4242

@@ -111,7 +111,7 @@ The `--architectures` flag is only required when you build the binary on an Appl
111111

112112
Be sure to set `AWS_ACCOUNT_ID` with your actual AWS account ID (for example: 012345678901).
113113

114-
### Step2: Give permission to invoke that function through an URL
114+
### Step 2: Give permission to invoke that function through a URL
115115

116116
Anyone with a valid signature from your AWS account will have permission to invoke the function through its URL.
117117

@@ -124,7 +124,7 @@ aws lambda add-permission \
124124
--statement-id allowURL
125125
```
126126

127-
### Step3: Create the URL
127+
### Step 3: Create the URL
128128

129129
This creates [a URL with IAM authentication](https://docs.aws.amazon.com/lambda/latest/dg/urls-auth.html). Only calls with a valid signature will be authorized.
130130

@@ -134,7 +134,7 @@ aws lambda create-function-url-config \
134134
--auth-type AWS_IAM \
135135
--invoke-mode RESPONSE_STREAM
136136
```
137-
This calls return various information, including the URL to invoke your function.
137+
This call returns various information, including the URL to invoke your function.
138138

139139
```json
140140
{
@@ -251,7 +251,8 @@ Value https://gaudpin2zjqizfujfnqxstnv6u0czrfu.lambda-url.us-east-
251251
Once the function is deployed, you can invoke it with `curl`, similarly to what you did when deploying with the AWS CLI.
252252

253253
```bash
254-
curl -X POST -d @events/sample-request.json" \
254+
curl -X POST \
255+
--data '{"count": 3, "message": "Hello World!", "delayMs": 1000}' \
255256
--user "$ACCESS_KEY":"$SECRET_KEY" \
256257
--aws-sigv4 "aws:amz:${REGION}:lambda" \
257258
-H "x-amz-security-token: $AWS_SESSION_TOKEN" \

0 commit comments

Comments
 (0)