Skip to main content

Amazon SQS Connection

The Amazon SQS connection type enables automations to send messages to and receive messages from Amazon Simple Queue Service queues. It supports both Standard and FIFO queues across all AWS regions.

Connection Details

PropertyValue
Type IDAMAZON_SQS
CategoryMessaging and Event Systems
TestableYes

Friendly Example

What you enterExample
Connection nameSQS - Support Ticket Queue
Used forPosting new support requests into a queue and consuming processed results from a response queue
Main details to collectAWS access key, secret key, region, and queue URL
Best person to provide itAWS administrator or cloud platform engineer

After it is saved, workflow builders select SQS - Support Ticket Queue in a node instead of entering these details again.

Mandatory Fields

FieldWhat It MeansExample
accessKeyAWS IAM access key ID used to authenticate API requests. Encrypted at rest.AKIAIOSFODNN7EXAMPLE
secretKeyAWS IAM secret access key paired with the access key above. Encrypted at rest.wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
regionAWS region where the SQS queue is hosted. Must exactly match the region in the queue URL.us-east-1
queueUrlFull URL of the SQS queue. Shown on the queue's detail page in the AWS Console.https://sqs.us-east-1.amazonaws.com/123456789012/my-queue
Queue URL format

The queue URL always follows this pattern:

https://sqs.{region}.amazonaws.com/{account-id}/{queue-name}

For FIFO queues, the queue name ends in .fifo:

https://sqs.us-east-1.amazonaws.com/123456789012/my-queue.fifo

Copy the URL directly from the AWS Console to avoid typos in the account ID or region.

Advanced Fields

FieldWhat It MeansExample
visibilityTimeoutSeconds a received message is hidden from other consumers after being read. Set this to longer than your automation step takes to process the message.30
waitTimeSecondsSeconds the ReceiveMessage call waits for a message to arrive before returning empty (long polling). Values between 1 and 20 reduce empty responses and lower cost.20
endpointUrlCustom endpoint URL for use with AWS-compatible services or VPC endpoints. Leave blank to use the standard AWS endpoint.https://sqs.us-east-1.vpce.example.com
Use long polling to reduce cost

Setting waitTimeSeconds to 20 enables long polling. This reduces the number of empty ReceiveMessage responses and can significantly cut your SQS API costs compared to short polling (waitTimeSeconds = 0).

Standard vs. FIFO Queues

FeatureStandard QueueFIFO Queue
Delivery guaranteeAt-least-once (duplicates possible)Exactly-once within a 5-minute deduplication window
Message orderingBest-effortStrict first-in, first-out within a message group
ThroughputNearly unlimitedUp to 3,000 messages/second with batching
Queue name suffixNoneMust end in .fifo

Use FIFO queues when the automation depends on processing messages in order or when duplicate processing would cause data integrity issues.

Setup Instructions

  1. Create the SQS queue in the AWS Console. Navigate to Amazon SQS → Queues → Create queue. Choose Standard or FIFO based on your requirements. Note the queue URL from the queue detail page after creation.

  2. Create a dedicated IAM user for the automation. In the AWS Console, navigate to IAM → Users → Create user. Give the user a descriptive name (e.g., qinfinite-sqs-automation).

  3. Attach an IAM policy granting the minimum required permissions on the specific queue. The recommended inline policy is:

    {
    "Version": "2012-10-17",
    "Statement": [
    {
    "Effect": "Allow",
    "Action": [
    "sqs:SendMessage",
    "sqs:ReceiveMessage",
    "sqs:DeleteMessage",
    "sqs:GetQueueAttributes"
    ],
    "Resource": "arn:aws:sqs:{region}:{account-id}:{queue-name}"
    }
    ]
    }
  4. Generate access keys for the IAM user. In the IAM Console, open the user, go to Security credentials → Access keys → Create access key. Select the Application running outside AWS use case and copy both the access key ID and secret access key — the secret is shown only once.

  5. Create the connection in the Global Configurator. Enter the access key, secret key, region, and queue URL, then test the connection to confirm the credentials can reach the queue.

Limit IAM permissions to specific queues

Avoid attaching broad policies such as AmazonSQSFullAccess. Scope the Resource in the IAM policy to the specific queue ARN(s) the automation needs. This limits the blast radius if the credentials are ever compromised.

Troubleshooting

SymptomLikely Cause
InvalidClientTokenId or AuthFailureThe access key ID or secret key is wrong, has been deactivated, or belongs to a different AWS account — verify both values in the IAM Console
AccessDenied on SendMessage or ReceiveMessageThe IAM user's policy does not grant the required action on this queue — check the attached policies and queue resource policy
NonExistentQueue or 404The queue URL is incorrect or the queue was deleted — copy the URL directly from the AWS Console and verify the region matches
Connection test succeeds but messages are not receivedThe visibilityTimeout may be too short, causing messages to become visible again before processing completes — increase it to exceed the maximum expected processing time