Get torrents
Use this action to get the current torrents in Transmission. You can filter the result by torrent state, and the action returns the matching torrents as response data you can use in a template.
Using this action from the user interface
If you prefer building automations and scripts visually, Home Assistant walks you through this action step by step. You pick what to target, tweak a few options, and save. No YAML knowledge required.
To get torrents from an automation or a script:
- Go to Settings > Automations & scenes.
- Open an existing automation or script, or select Create automation > Create new automation.
- If you’re setting up a new automation, add a trigger in the When section. Scripts don’t need a trigger. They run when something else calls them.
- In the Then do section, select Add action.
- From the search box, search for and select Transmission: Get torrents.
- Select your Transmission entry and choose a Torrent filter.
- In the Response variable field, enter a name to store the data in, such as
torrents. - Select Save.```
This action does not support targets. In the UI, you select the Transmission integration through the Transmission entry field instead of choosing an area, device, entity, or label.
Options in the UI
Using this action in YAML
If you work directly in YAML, or you want to know exactly what Home Assistant does under the hood, this section has the technical reference. It lists the field names you use in YAML, their types, and which ones are required.
In YAML, refer to this action as transmission.get_torrents. A basic example looks like this:
action: transmission.get_torrents
data:
entry_id: YOUR_TRANSMISSION_ENTRY_ID
torrent_filter: all
response_variable: torrents
Options in YAML
Response data
The action returns a mapping keyed by the name of each torrent. Store it in a response variable (for example, torrents) so you can use it in later steps.
-
id: The ID of the torrent. -
name: The name of the torrent. -
status: The current status of the torrent. -
percent_done: How much of the torrent has completed, as a percentage. -
ratio: The share ratio of the torrent. -
eta: The estimated time remaining, or empty when not available. -
added_date: When the torrent was added, in ISO 8601 format. -
done_date: When the torrent finished, in ISO 8601 format, or empty when not finished. -
download_dir: The download directory of the torrent. -
labels: The list of labels assigned to the torrent.
Still stuck?
The Home Assistant community is quick to help: join Discord for real-time chat, post on the community forum with the action you’re calling and what you expected to happen, or share on our subreddit /r/homeassistant.
AI assistants like ChatGPT or Claude can also explain actions or suggest the right one when you describe what you want in plain language.
Related actions
These actions work well alongside this one:
-
Add torrent: Adds a new torrent to download in Transmission.
-
Start torrent: Starts a torrent in Transmission.
-
Stop torrent: Stops a torrent in Transmission.