| Line 1: |
Line 1: |
| − | <pre class="header-style"> | + | <pre class="header-style">The Call Ended trigger fires when a standard phone call ends. This allows you to automate actions after phone calls complete, such as logging call times, restoring volume settings, or sending follow-up messages.</pre> |
| − | This trigger will fire when a standard phone call is ended.
| |
| − | </pre> | |
| | | | |
| | + | ''' Options ''' |
| | | | |
| − | '''Magic Text'''<br/> | + | * '''Select Contacts''' - Trigger when calls with specific contacts end |
| − | When this trigger is used, you can access magic text via the [...] button where available.<br/>[https://macrodroidforum.com/wiki/index.php/Magic_text#Call_.28Active.2C_Ended.2C_Incoming.2C_Missed.2C_Outgoing.29 magic text]
| + | ** Choose from your contacts list |
| | + | ** Includes special options: Any Contact, Non Contact, Unknown Caller |
| | + | ** Option to exclude selected contacts instead of including them |
| | + | * '''Select Groups''' - Trigger when calls with contacts from specific groups end |
| | + | ** Choose one or more contact groups (e.g., Favorites, Family, Work) |
| | + | * '''Specify Number''' - Trigger when a call with a specific phone number ends |
| | + | ** Enter a phone number or partial number match |
| | + | ** Supports wildcards for partial matching |
| | + | ** Option to exclude the specified number |
| | + | ** Supports regex pattern matching |
| | + | ** Magic text can be used for dynamic numbers |
| | + | * '''Any Number''' - Trigger when any call ends regardless of the number |
| | | | |
| − | '''Configuration Options''' | + | ''' Special Contact Types ''' |
| | | | |
| − | * Select Contact(s) | + | When selecting contacts, the following special options are available: |
| | + | * '''Any Contact''' - Triggers when calls from contacts end |
| | + | * '''Non Contact''' - Triggers when calls from non-contact numbers end |
| | + | * '''Unknown Caller''' - Triggers when calls from private/hidden numbers end |
| | | | |
| − | '''''Any Contact''''' | + | ''' Magic Text ''' |
| − | - A call with any number that is in your contacts has ended.
| |
| | | | |
| − | '''''Non Contact'''''
| + | When this trigger fires, the following value are available via magic text for use in subsequent actions. |
| − | - A call with any number that is not your contacts has ended.
| |
| | | | |
| − | '''''Unknown Caller'''''
| + | * {call_number} |
| − | - A call with an unknown number (e.g. private number) has ended.
| + | * {call_name} |
| | + | * {call_groups} |
| | | | |
| − | * Select Group(s)
| + | ''' Examples ''' |
| | | | |
| − | You can select to trigger based on a contact group (e.g. Favourites/Friends etc.). The trigger will fire when a call with any contact from within the chosen group has ended.
| + | ''Example 1: Restore Volume After Call'' |
| | + | <pre class="trigger-style">Triggers |
| | | | |
| − | * Select Number
| + | Call Ended (Any Number)</pre> |
| | + | <pre class="action-style">Actions |
| | | | |
| − | You can specify a specific number to match against (or partial match).
| + | Volume Change: Ring to 100% |
| | + | Volume Change: Media to 50%</pre> |
| | | | |
| − | * Any Number
| + | ''Example 2: Log Business Call Duration'' |
| | + | <pre class="trigger-style">Triggers |
| | | | |
| − | When selecting this option the trigger will fire when any call is ended (regardless of number).
| + | Call Ended (Group: Work)</pre> |
| | + | <pre class="action-style">Actions |
| | + | |
| | + | Write to File: Work call ended at [date_time] - [last_call_duration]</pre> |
| | + | |
| | + | ''' Notes ''' |
| | + | |
| | + | * This trigger fires when any call ends, whether incoming or outgoing |
| | + | * The trigger monitors phone state changes to detect when calls end |
| | + | * Both the outgoing call number and incoming call number are tracked |
| | + | * Triggers for both answered calls that end and rejected/declined calls |
| | + | |
| | + | ''' Permissions Required ''' |
| | + | |
| | + | * '''Read Phone State''' - Required to monitor call state (always required) |
| | + | * '''Read Contacts''' - Required for contact-based filtering (when using contacts) |
| | + | * '''Read Call Log''' - Required for call information access (when using contacts) |
| | + | |
| | + | ''' See Also ''' |
| | + | |
| | + | * [[Trigger:_Call_Active|Call Active Trigger]] |
| | + | * [[Trigger:_Call_Incoming|Call Incoming Trigger]] |
| | + | * [[Trigger:_Call_Missed|Call Missed Trigger]] |