AWS SDK for .NET Documentation
ReceiveMessageRequest Class
AmazonAmazon.SQS.ModelReceiveMessageRequest Did this page help you?   Yes   No    Tell us about it...

Retrieves one or more messages from the specified queue, including the message body and message ID of each message. Messages returned by this action stay in the queue until you delete them. However, once a message is returned to a ReceiveMessage request, it is not returned on subsequent ReceiveMessage requests for the duration of the VisibilityTimeout. If you do not specify a VisibilityTimeout in the request, the overall visibility timeout for the queue is used for the returned messages.

If a message is available in the queue, the call will return immediately. Otherwise, it will wait up to WaitTimeSeconds for a message to arrive. If you do not specify WaitTimeSeconds in the request, the queue attribute by the same name is used to determine how long to wait.

You could ask for additional information about each message through the attributes. Attributes that can be requested are [SenderId, ApproximateFirstReceiveTimestamp, ApproximateReceiveCount, SentTimestamp].

Declaration Syntax
public class ReceiveMessageRequest : SQSRequest
All MembersConstructorsMethodsProperties

Initializes a new instance of the ReceiveMessageRequest class

Gets and sets the AttributeName property. The attribute you want to get. Valid values: All | SenderId | SentTimestamp | ApproximateReceiveCount | ApproximateFirstReceiveTimestamp

Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Serves as a hash function for a particular type.
(Inherited from Object.)
Gets the type of the current instance.
(Inherited from Object.)
Checks if AttributeName property is set

Checks if MaxNumberOfMessages property is set

Checks if MessageAttributeName property is set

Checks if QueueUrl property is set

Checks if VisibilityTimeout property is set

Checks if WaitTimeSeconds property is set

Gets and sets the MaxNumberOfMessages property. Maximum number of messages to return. SQS never returns more messages than this value but might return fewer. Not necessarily all the messages in the queue are returned (for more information, see the preceding note about machine sampling). Values can be from 1 to 10. Default is 1.

Gets and sets the MessageAttributeName property. The message attributes you want to get.

Gets and sets the QueueUrl property. The URL associated with the Amazon SQS queue.

Returns a string that represents the current object.
(Inherited from Object.)
Gets and sets the VisibilityTimeout property. The duration (in seconds) that the received messages are hidden from subsequent retrieve requests after being retrieved by a ReceiveMessage request.

Gets and sets the WaitTimeSeconds property. The number of seconds to wait for messages in the queue.

WithAttributeName(array<String>[]()[][]) Obsolete.
Sets the AttributeName property

WithMaxNumberOfMessages(Decimal) Obsolete.
Sets the MaxNumberOfMessages property

WithMessageAttributeName(array<String>[]()[][]) Obsolete.
Sets the MessageAttributeName property

WithQueueUrl(String) Obsolete.
Sets the QueueUrl property

WithVisibilityTimeout(Decimal) Obsolete.
Sets the VisibilityTimeout property

WithWaitTimeSeconds(Int32) Obsolete.
Sets the WaitTimeSeconds property

Inheritance Hierarchy

Assembly: AWSSDK (Module: AWSSDK) Version: (