Files
HomeAssistantVS/custom_components/amazon_order_status/purge_script_example.yaml
T
2026-07-09 13:30:12 -04:00

14 lines
546 B
YAML

# Copy this script into Home Assistant so the Purge order button works.
#
# Settings → Automations & scenes → Scripts → Add script → (paste in YAML mode)
#
# IMPORTANT: Use "data_template" so the order_id is read when you tap the button.
# Using "data" would pass the literal template string and the order would not be found.
#
purge_amazon_order:
alias: Purge Amazon order
sequence:
- service: amazon_order_status.purge_order
data_template:
order_id: "{{ states('input_text.amazon_order_purge_id') }}"