Overview
QueueCast connects Unreal Engine 4.27 and 5.8 to Amazon Simple Queue Service (SQS) and Amazon Simple Notification Service (SNS). Use queues for reports, telemetry, match results and jobs for your backend, listen to a queue for server events, publish notifications to topics and register players' devices for mobile push. Requests run on background worker threads with automatic retries; every result arrives back on the game thread.
- Send Message / Send Message Batch: string attributes, delays, FIFO group and deduplication ids; batches of any size, 10 per request, per-entry results.
- Receive Messages: long polling, visibility timeout, attributes and receive count.
- Listen To Queue: a listener that keeps long-polling until stopped and fires On Message for every message, with optional auto-delete and back-off on errors.
- Delete Message, Delete Message Batch, Change Message Visibility, Get Queue Url (cached), Get Queue Attributes.
- SNS Publish to a topic, a single device (platform endpoint) or a phone number (SMS).
- Register Push Device: Firebase Cloud Messaging / APNs tokens to SNS platform endpoints, kept up to date automatically.
- Subscribe, Unsubscribe, Set Push Endpoint Enabled.
- Amazon Cognito identity pools for guests and signed-in players; static keys and the default AWS chain for development and servers.
Requirements
| Requirement | Details |
|---|---|
| Unreal Engine | 4.27 and 5.8 |
| Platforms | Win64, Linux and Android |
| Modules | QueueCast (Runtime), QueueCastSdk (prebuilt AWS SDK for C++ 1.11.916 in Source/ThirdParty) |
| Dependencies | No other plugins. On Linux and Android the SDK uses the engine's libcurl, OpenSSL and certificate store. |
| AWS | An AWS account. SQS, SNS (including SMS and mobile push) and Cognito usage is billed by AWS. |
Installation
- Install QueueCast from Fab into your engine, or copy the
QueueCastfolder into your project'sPluginsfolder. - Enable QueueCast in Edit > Plugins and restart the editor.
- Open Project Settings > Plugins > QueueCast and set Region, Identity Pool Id and, if you like, a Default Queue and Default Topic Arn.
- C++ only: add
PublicDependencyModuleNames.Add("QueueCast");to yourBuild.cs.
Setting up AWS
- In the SQS console create your queues (Standard, or FIFO with a
.fifoname for strict ordering). Use a common prefix such asmygame-. - For notifications create SNS topics. For mobile push create a platform application (Firebase Cloud Messaging or APNs) and note its ARN.
- In Amazon Cognito create an identity pool. Enable guest access if players may use queues before signing in, and add your identity providers.
- Edit the IAM role the pool gives to players so it may call only the actions QueueCast uses, and only on your game's resources. Leave out every statement you do not need:
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "SendReports",
"Effect": "Allow",
"Action": ["sqs:GetQueueUrl", "sqs:SendMessage", "sqs:GetQueueAttributes"],
"Resource": "arn:aws:sqs:us-east-1:123456789012:mygame-reports"
},
{
"Sid": "ReadOwnInbox",
"Effect": "Allow",
"Action": ["sqs:GetQueueUrl", "sqs:ReceiveMessage", "sqs:DeleteMessage", "sqs:ChangeMessageVisibility"],
"Resource": "arn:aws:sqs:us-east-1:123456789012:mygame-events"
},
{
"Sid": "PublishToGameTopic",
"Effect": "Allow",
"Action": "sns:Publish",
"Resource": "arn:aws:sns:us-east-1:123456789012:mygame-player-events"
},
{
"Sid": "RegisterPushDevice",
"Effect": "Allow",
"Action": "sns:CreatePlatformEndpoint",
"Resource": "arn:aws:sns:us-east-1:123456789012:app/GCM/MyGame"
},
{
"Sid": "ManageOwnEndpoint",
"Effect": "Allow",
"Action": ["sns:GetEndpointAttributes", "sns:SetEndpointAttributes"],
"Resource": "arn:aws:sns:us-east-1:123456789012:endpoint/GCM/MyGame/*"
},
{
"Sid": "PushTopicSubscribe",
"Effect": "Allow",
"Action": "sns:Subscribe",
"Resource": "arn:aws:sns:us-east-1:123456789012:mygame-news",
"Condition": { "StringEquals": { "sns:Protocol": "application" } }
},
{
"Sid": "PushTopicUnsubscribe",
"Effect": "Allow",
"Action": "sns:Unsubscribe",
"Resource": "arn:aws:sns:us-east-1:123456789012:mygame-news"
}
]
}
Batch nodes need the same actions as their single versions (sqs:SendMessage, sqs:DeleteMessage). sqs:GetQueueUrl is not needed when you pass queue URLs or set Queue Url Prefix. Queues and topics encrypted with a customer managed KMS key also need kms:GenerateDataKey and kms:Decrypt on that key.
sqs:SendMessage only on queues your backend reads, and sqs:ReceiveMessage / sqs:DeleteMessage only on queues whose content every player may see and remove. Never allow sns:Publish on "*": that includes SMS to any phone number at your cost. Keep sns:Subscribe limited to the application protocol so players cannot subscribe e-mail addresses or web hooks.DefaultGame.ini and in packaged games. Use them only for development and dedicated servers; players should always use the identity pool. Shipping builds refuse settings keys unless Allow Static Keys In Shipping is enabled.Quick start
Send a message
- Add Send Message. Queue
mygame-reports(a name or a full URL), Body{"type":"bug","text":"..."}. - On Success returns the Message Id; On Failure carries Error > Code and Message.
Listen to a queue
- On Begin Play add Listen To Queue with Queue
mygame-eventsand Auto Delete on. Promote the return value to a variable. - From On Message read Message > Body. If the queue is subscribed to an SNS topic, use Unwrap SNS Notification first.
- Call Stop Listening on the variable when you no longer need messages. The listener also stops by itself when its world is torn down (end of play, level change).
Push notifications
- Get the device's push token (for example the Firebase Cloud Messaging token from your push plugin).
- Call Register Push Device with the token and, as Custom User Data, your player id. Save the returned endpoint ARN and pass it as Existing Endpoint Arn on the next start.
- Your backend publishes to the endpoint or to a topic the endpoint is subscribed to (Subscribe with Protocol
application).
SQS nodes
All latent nodes run in the background, can be stopped with Cancel on their return value and fire exactly one final pin on the game thread. Queue takes a queue name or URL; empty = the settings' Default Queue.
| Node | Inputs | Outputs | Description |
|---|---|---|---|
| Send Message | Queue, Body, Delay Seconds, Attributes, Message Group Id, Deduplication Id | On Success / On Failure (Result, Error) | Sends one message (up to 256 KB). Attributes are sent as String attributes; entries with an empty name or value are skipped. FIFO queues need a Message Group Id and, without content-based deduplication, a Deduplication Id. |
| Send Message Batch | Queue, Entries | On Completed (Results, Failed Count) | Sends every entry, 10 per request. Results are in the order of Entries; one entry can fail while the others are sent (Error Code, Sender Fault per entry). |
| Receive Messages | Queue, Max Messages (1-10), Wait Seconds, Visibility Timeout | On Success / On Failure (Messages, Error) | One receive with long polling: waits up to Wait Seconds (0-20, -1 = settings) for messages. An empty array is a normal result. Received messages are hidden for the visibility timeout: delete them once handled, otherwise they come back. |
| Delete Message | Queue, Receipt Handle | On Success / On Failure (Error) | Removes a handled message. Pass the message's Queue Url and Receipt Handle. |
| Delete Message Batch | Queue, Receipt Handles | On Completed (Results, Failed Count) | Removes many messages, 10 per request; results in the order of Receipt Handles. |
| Change Message Visibility | Queue, Receipt Handle, Visibility Timeout | On Success / On Failure (Error) | Hides a received message for the given seconds from now (0-43200). 0 gives it back to the queue at once; a larger value buys time for long work. |
| Get Queue Url | Queue Name | On Success / On Failure (Value = URL, Error) | Looks up a queue URL. Every node does this for you on first use of a name and caches the result. |
| Get Queue Attributes | Queue | On Success / On Failure (Info, Error) | Approximate waiting / in-flight / delayed counts, visibility timeout, FIFO flag, ARN and every other attribute by name. |
Listen To Queue
Listen To Queue (Queue, Auto Delete, Max Messages, Wait Seconds, Visibility Timeout) keeps long-polling one queue in the background until it is stopped. Pins:
| Pin / function | Description |
|---|---|
| On Message (Message) | Fires on the game thread for every received message, one after another. The next receive starts after all messages of the previous one were delivered. |
| Auto Delete | On: each delivered message is deleted after its On Message ran. Off: delete messages yourself with Delete Message, or they come back after the visibility timeout. |
| On Error (Error) | Fires for every failed receive. Network errors and throttling are retried after a pause that doubles from 1 second up to Listener Max Backoff Seconds. |
| On Stopped (Error) | Fires when the listener stops by itself because of an error that will not go away by retrying (no permission, unknown queue, missing settings). |
| Stop Listening | Stops the listener (same as Cancel). No pin fires afterwards. Messages received but not delivered yet return to the queue after their visibility timeout. |
| Is Finished | True once the listener stopped. |
SNS nodes
| Node | Inputs | Outputs | Description |
|---|---|---|---|
| SNS Publish | Target, Message, Subject, Attributes, Message Group Id, Deduplication Id, Json Message Structure | On Success / On Failure (Result, Error) | Target is a topic ARN, a platform endpoint ARN (push to one device) or a phone number in E.164 format such as +15551234567 (SMS); empty = the settings' Default Topic Arn. With Json Message Structure the Message is a JSON object with one text per protocol, for example {"default":"Hi","GCM":"{\"notification\":{\"title\":\"Hi\"}}"}. |
| Register Push Device | Device Token, Custom User Data, Existing Endpoint Arn, Platform Application Arn | On Success / On Failure (Value = endpoint ARN, Error) | Creates or repairs the platform endpoint of a push token. See Mobile push. |
| Subscribe | Topic Arn, Endpoint, Attributes, Protocol | On Success / On Failure (Value = subscription ARN, Error) | Subscribes an endpoint to a topic. Protocol application for platform endpoints (default), or sqs, email, sms, lambda, https. Attributes such as FilterPolicy = {"region":["eu"]} or RawMessageDelivery = true. |
| Unsubscribe | Subscription Arn | On Success / On Failure (Error) | Removes a subscription. |
| Set Push Endpoint Enabled | Endpoint Arn, Enabled | On Success / On Failure (Error) | Turns push delivery to one device on or off, for example from your options menu. |
Mobile push
Register Push Device follows the token management flow AWS recommends:
- Without an Existing Endpoint Arn it creates the endpoint. When SNS answers that the token already exists with other attributes, the existing endpoint is reused and updated.
- It then reads the endpoint. A deleted endpoint is created again; a different token, a disabled endpoint or changed Custom User Data are updated (Enabled = true).
- On Success returns the endpoint ARN. Save it (for example in a save game) and pass it back next time so each device keeps one endpoint.
Getting the token itself is platform specific (Firebase Cloud Messaging on Android). QueueCast does not show notifications on the device; that is the job of the operating system and your push setup.
Functions
| Node | Description |
|---|---|
| Unwrap SNS Notification | For a queue subscribed to a topic without raw message delivery: returns the original Message, Subject, Topic Arn and Attributes of the SNS envelope in a message Body. Returns false (Message = Body) for other bodies. |
| Resolve Identity | Latent: fetches the Cognito identity and credentials now, for example right after login. Value = the identity id. |
| Set Region | Switches the AWS region for every following request. |
| Set Credential Mode | Overrides the credential mode from the settings at runtime. |
| Set Login Token | Signs the player in to the identity pool with a provider token (Cognito user pool, Google, Apple, Facebook, OpenID). |
| Clear Login Tokens | Forgets all login tokens and the cached identity; the player becomes a guest. |
| Set Static Credentials | Uses the given keys from now on (Static Keys mode), for example temporary keys handed out by your backend. |
| Get Identity Id | The player's Cognito identity id; empty until credentials were resolved once. |
| Make User Pool Provider Name | Builds the login key of a Cognito user pool: cognito-idp.<region>.amazonaws.com/<pool id>. |
| Is Configured | Returns false and a reason when the settings are incomplete. |
| Cancel | On a latent node's return value: none of its pins fire any more (on a listener: stops it). |
| Is Finished | On a latent node's return value: true after it finished or was cancelled. |
Credentials
| Mode | Use for | How |
|---|---|---|
| Cognito Identity Pool | Game clients | Guests get unauthenticated credentials; after Set Login Token the player gets the authenticated role. Credentials refresh automatically before they expire. |
| Static Keys | Development, dedicated servers, keys from your backend | Settings keys or Set Static Credentials (with an optional session token). |
| Default Credential Chain | Servers and tools | Environment variables, the ~/.aws profile, ECS and EC2 instance roles. |
Give the authenticated role more than the guest role, for example only signed-in players may register push devices.
C++ API
// Build.cs: PublicDependencyModuleNames.Add("QueueCast");
#include "QueueCastLibrary.h"
TMap<FString, FString> Attributes;
Attributes.Add(TEXT("type"), TEXT("bug"));
UQueueCastLibrary::SendToQueueNative(TEXT("mygame-reports"), TEXT("{\"text\":\"...\"}"), Attributes,
FQueueCastNativeDelegate::CreateLambda([](const FQueueCastSendResult& Result, const FQueueCastError& Error)
{
// runs on the game thread; Error.Code is empty on success
}));
UQueueCastLibrary::PublishNative(TEXT("arn:aws:sns:us-east-1:123456789012:mygame-player-events"),
TEXT("Level complete"), FString(), FQueueCastNativeDelegate());
The latent node classes (UQueueCastListenAction and the others) can also be created from C++ through their static factory functions; bind the dynamic delegates, then call Activate().
Types
| Type | Kind | Members |
|---|---|---|
| FQueueCastMessage | Struct | Message Id, Body, Receipt Handle, Attributes, System Attributes, Receive Count, Sent Time, Message Group Id, Queue Url |
| FQueueCastSendResult | Struct | Message Id, Sequence Number |
| FQueueCastBatchEntry | Struct | Body, Delay Seconds, Attributes, Message Group Id, Deduplication Id |
| FQueueCastBatchResult | Struct | Index, Success, Message Id, Sequence Number, Error Code, Error Message, Sender Fault |
| FQueueCastQueueInfo | Struct | Queue Url, Queue Arn, Approximate Messages, Approximate Messages In Flight, Approximate Messages Delayed, Visibility Timeout, Fifo, Attributes |
| FQueueCastError | Struct | Code, Message, Http Status, Retryable |
| EQueueCastCredentialMode | Enum | Cognito Identity Pool, Static Keys, Default Credential Chain |
Settings
Project Settings > Plugins > QueueCast (saved to DefaultGame.ini). Changes apply to the next request.
| Setting | Default | Description |
|---|---|---|
| Region | us-east-1 | Region of your queues, topics and identity pool. |
| Credential Mode | Cognito Identity Pool | Cognito Identity Pool, Static Keys or Default Credential Chain. |
| Identity Pool Id | (empty) | For example us-east-1:01234567-89ab-cdef-0123-456789abcdef. |
| Allow Guest Access | On | Unauthenticated identities before Set Login Token. The pool must allow guest access too. |
| Access Key Id / Secret Access Key | (empty) | Static Keys mode. Saved in DefaultGame.ini - development and servers only. |
| Allow Static Keys In Shipping | Off | Static keys from the settings are refused in Shipping builds unless enabled (dedicated servers). |
| Endpoint Override | (empty) | Custom endpoint such as a local emulator (http://localhost:4566). |
| Request Timeout Ms / Connect Timeout Ms | 30000 / 5000 | Time limits per request. Long polls are kept at least 5 seconds shorter than the request timeout. |
| Max Retries | 3 | Automatic retries with exponential back-off for throttling and transient errors. |
| Worker Threads | 4 | Background threads that run requests (each running listener uses one). |
| Verify SSL | On | Only disable for a local emulator. |
| Log Sdk Warnings | On | Forwards SDK warnings and errors to LogQueueCast. |
| Default Queue | (empty) | Queue name or URL used when a node leaves Queue empty. |
| Queue Url Prefix | (empty) | For example https://sqs.us-east-1.amazonaws.com/123456789012/ - names become URLs without a Get Queue Url request. |
| Queue Owner Account Id | (empty) | Account that owns the queues when it is not the account of the credentials. |
| Default Wait Seconds | 10 | Long-poll time (0-20) when a receive node or listener leaves Wait Seconds at -1. |
| Default Visibility Timeout | 0 | Visibility timeout when a node leaves it at -1; 0 = the queue's own setting. |
| Listener Max Backoff Seconds | 30 | Longest pause between listener retries after errors. |
| Default Topic Arn | (empty) | Topic used when SNS Publish or Subscribe leaves the topic empty. |
| Platform Application Arn | (empty) | Platform application used when Register Push Device leaves it empty. |
Troubleshooting
| Error code | Cause and fix |
|---|---|
NotConfigured | Set the Identity Pool Id in Project Settings > Plugins > QueueCast, or the Default Queue / Default Topic Arn / Platform Application Arn the node relies on. |
NotAuthorizedException | Guest access is off on the identity pool, or a login token expired. Enable guest access or call Set Login Token with a fresh token. |
AccessDenied / AuthorizationError | The identity pool role does not allow the SQS or SNS action on that resource. Update the role policy (see Setting up AWS). |
QueueDoesNotExist | Wrong queue name, region, Queue Url Prefix or Queue Owner Account Id. |
InvalidParameterValue | Usually a FIFO queue without Message Group Id, a Delay Seconds on a FIFO queue, or a body or batch over 256 KB. |
InvalidTarget | SNS Publish Target is neither an ARN nor a phone number starting with +. |
EndpointDisabled | The push service rejected the device token. Call Register Push Device again with a fresh token. |
Unavailable | The SDK library could not be loaded or the engine is shutting down. Check the Output Log for LogQueueCast errors. |
| Messages arrive twice | Standard queues deliver at least once, and a message comes back when it was not deleted within its visibility timeout. Make handlers idempotent, delete messages, or use a FIFO queue. |
Credits
© 2026 Alpha XP — alphaxp.net · Support: support@alphaxp.net. Includes the AWS SDK for C++ and the AWS Common Runtime (Apache License 2.0). For Unreal Engine 4.27 and 5.8.