Overview
The AWS ECS node for n8n allows you to interact with the Amazon Elastic Container Service (ECS) API. Specifically, the "Describe Tasks" operation retrieves detailed information about one or more specified ECS tasks within a cluster. This is useful for monitoring task status, debugging issues, or gathering metadata about running or stopped tasks.
Common scenarios:
- Monitoring the state and details of specific ECS tasks.
- Debugging failed or problematic tasks by retrieving their latest status and reason fields.
- Integrating ECS task information into automated workflows for reporting or alerting.
Example use cases:
- After launching tasks via another automation, use this node to fetch their current status and health.
- Periodically poll ECS tasks to check for completion or errors and trigger downstream actions.
Properties
| Name | Type | Meaning |
|---|---|---|
| Cluster | String | The short name or full Amazon Resource Name (ARN) of the ECS cluster where your tasks are running. If not specified, the default cluster is assumed. |
| Tasks | Collection | A list of up to 100 task IDs or full ARN entries. Each entry should contain a "Task ID", which is the identifier of the ECS task to describe. |
| Include | Collection | A list specifying additional information to include in the response. Each entry contains an "Include" string. Possible values typically include "TAGS" to include resource tags, but may vary per AWS documentation. |
Output
The output will be a JSON object mirroring the structure returned by the AWS ECS describeTasks API. The main fields include:
{
"tasks": [
{
// Detailed information about each ECS task, such as:
"taskArn": "...",
"clusterArn": "...",
"lastStatus": "...",
"desiredStatus": "...",
"containers": [ /* ... */ ],
"tags": [ /* ... */ ],
// ...other ECS task properties
}
],
"failures": [
{
"arn": "...",
"reason": "..."
}
// ...if any tasks could not be described
]
}
- tasks: Array of objects, each describing a requested ECS task.
- failures: Array of objects indicating any tasks that could not be found or described, with reasons.
Dependencies
- AWS Account: You must have valid AWS credentials (Access Key ID, Secret Access Key, and Region) configured in n8n.
- n8n AWS Credentials: The node requires an AWS credential set up in n8n under the name
aws. - External Service: Requires access to the AWS ECS API.
Troubleshooting
Common Issues:
- Invalid Credentials: If your AWS credentials are incorrect or lack permissions for ECS, the node will fail with an authentication or authorization error.
- Task Not Found: If you provide invalid or non-existent task IDs/ARNs, the output's
failuresarray will indicate which tasks could not be described and why. - Cluster Not Specified: If the cluster is omitted and you do not have a default cluster, the request may fail or return no results.
Error Messages:
Operation "..." not supported!: This occurs if an unsupported operation is selected; ensure "Describe Tasks" is chosen.- AWS SDK errors: Any errors from AWS (e.g., "AccessDeniedException", "ClusterNotFoundException") will be passed through. Check your input parameters and AWS permissions.
How to resolve:
- Double-check your AWS credentials and permissions.
- Ensure the provided cluster and task IDs/ARNs exist and are correct.
- Review the
failuresfield in the output for specific issues with individual tasks.