# Message Deleted

> Triggers when a message is deleted.

- ID: `message_delete`
- Type: Event trigger
- Category: [Messages](https://inventor.bot/docs/reference/triggers/messages.md)

> Message content and Author ID are available if Message Cache is enabled in branch settings.

**Outputs**

| Name | Description | Value |
| --- | --- | --- |
| `message_id` | The ID of the deleted message | e.g. `"123456789012345678"` |
| `channel_id` | The ID of the channel where the message was deleted | e.g. `"123456789012345678"` |
| `server_id` | The ID of the server where the message was deleted | e.g. `"123456789012345678"` |
| `previous_content` | Content of the deleted message if available | e.g. `"This is a message"` |
| `author_id` | The ID of the user who sent the deleted message | e.g. `"123456789012345678"` |
| `message_cache_hit` | Whether the previous message content was retrieved from cache | e.g. `"true"` |

**Example**

```go
var trigger = message_delete()

func main() {
	send_text_message(Args{
		channel_id:      trigger.channel_id,
		message_content: "Message ID: " + trigger.message_id,
	})
}
```