Changes the visibility timeout for a message to the value you provide in the VisibilityTimeout parameter. This action can be used in one of several ways described in Visibility Timeout.
![]() | Important |
|---|---|
Unlike with a queue, when you change the visibility timeout for a specific message, that timeout value is applied immediately but is not saved in memory for that message. If after receiving a message, if for some reason you don't delete the message and the message is received again, the visibility timeout for the message when it is received again is the overall value for the queue and not the value you previously set with the |
The following table lists the special request parameters the action uses (in addition to the common request parameters listed in Common Request Parameters).
| Name | Description | Required |
|---|---|---|
| The message ID of the message whose visibility timeout you want to change. Type: String | Yes |
| The new value for the message's visibility timeout (in seconds). Type: Integer from 0 to 86400 (maximum 24 hours). | Yes |
The response contains no special elements besides the common elements listed in The Structure of a Response.
The action returns no errors besides the common errors listed in Common Errors.
The following example Query request changes the visibility timeout for a message to 60 seconds.
http://queue.amazon.com/A29E9VSPHGOG23/queue2 ?Action=ChangeMessageVisibility &MessageId=17VXQHSGX0SG4ZEPPK7R%7C0QE42ST4KW7RK9HSY074%7C0Z4AN912X0H2EP8BV6XJ &VisibilityTimeout=60 &Version=2007-05-01 &AWSAccessKeyId=0GS7553JW74RRM612K02EXAMPLE &Expires=2007-05-12T12:00:00Z &Signature=Dqlp3Sd6ljTUA9Uf6SGtEExwUQEXAMPLE=