| Copyright | (c) 2013-2023 Brendan Hay |
|---|---|
| License | Mozilla Public License, v. 2.0. |
| Maintainer | Brendan Hay |
| Stability | auto-generated |
| Portability | non-portable (GHC extensions) |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Amazonka.SQS.DeleteMessageBatch
Description
Deletes up to ten messages from the specified queue. This is a batch
version of DeleteMessage. The result of the action on each
message is reported individually in the response.
Because the batch request can result in a combination of successful and
unsuccessful actions, you should check for batch errors even when the
call returns an HTTP status code of 200.
Some actions take lists of parameters. These lists are specified using
the param.n notation. Values of n are integers starting from 1. For
example, a parameter list with two elements looks like this:
&AttributeName.1=first
&AttributeName.2=second
Synopsis
- data DeleteMessageBatch = DeleteMessageBatch' {}
- newDeleteMessageBatch :: Text -> DeleteMessageBatch
- deleteMessageBatch_queueUrl :: Lens' DeleteMessageBatch Text
- deleteMessageBatch_entries :: Lens' DeleteMessageBatch [DeleteMessageBatchRequestEntry]
- data DeleteMessageBatchResponse = DeleteMessageBatchResponse' {}
- newDeleteMessageBatchResponse :: Int -> DeleteMessageBatchResponse
- deleteMessageBatchResponse_httpStatus :: Lens' DeleteMessageBatchResponse Int
- deleteMessageBatchResponse_successful :: Lens' DeleteMessageBatchResponse [DeleteMessageBatchResultEntry]
- deleteMessageBatchResponse_failed :: Lens' DeleteMessageBatchResponse [BatchResultErrorEntry]
Creating a Request
data DeleteMessageBatch Source #
See: newDeleteMessageBatch smart constructor.
Constructors
| DeleteMessageBatch' | |
Fields
| |
Instances
newDeleteMessageBatch Source #
Arguments
| :: Text | |
| -> DeleteMessageBatch |
Create a value of DeleteMessageBatch with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:queueUrl:DeleteMessageBatch', deleteMessageBatch_queueUrl - The URL of the Amazon SQS queue from which messages are deleted.
Queue URLs and names are case-sensitive.
$sel:entries:DeleteMessageBatch', deleteMessageBatch_entries - A list of receipt handles for the messages to be deleted.
Request Lenses
deleteMessageBatch_queueUrl :: Lens' DeleteMessageBatch Text Source #
The URL of the Amazon SQS queue from which messages are deleted.
Queue URLs and names are case-sensitive.
deleteMessageBatch_entries :: Lens' DeleteMessageBatch [DeleteMessageBatchRequestEntry] Source #
A list of receipt handles for the messages to be deleted.
Destructuring the Response
data DeleteMessageBatchResponse Source #
For each message in the batch, the response contains a
DeleteMessageBatchResultEntry tag if the message is deleted or a
BatchResultErrorEntry tag if the message can't be deleted.
See: newDeleteMessageBatchResponse smart constructor.
Constructors
| DeleteMessageBatchResponse' | |
Fields
| |
Instances
newDeleteMessageBatchResponse Source #
Create a value of DeleteMessageBatchResponse with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:httpStatus:DeleteMessageBatchResponse', deleteMessageBatchResponse_httpStatus - The response's http status code.
$sel:successful:DeleteMessageBatchResponse', deleteMessageBatchResponse_successful - A list of DeleteMessageBatchResultEntry items.
$sel:failed:DeleteMessageBatchResponse', deleteMessageBatchResponse_failed - A list of BatchResultErrorEntry items.
Response Lenses
deleteMessageBatchResponse_httpStatus :: Lens' DeleteMessageBatchResponse Int Source #
The response's http status code.
deleteMessageBatchResponse_successful :: Lens' DeleteMessageBatchResponse [DeleteMessageBatchResultEntry] Source #
A list of DeleteMessageBatchResultEntry items.
deleteMessageBatchResponse_failed :: Lens' DeleteMessageBatchResponse [BatchResultErrorEntry] Source #
A list of BatchResultErrorEntry items.