-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* docs: document default events (#1081) * Add events docs * Update CHANGELOG.md * Update CHANGELOG.md
- Loading branch information
Showing
2 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
sidebar_position: 1 | ||
--- | ||
# Events | ||
|
||
:::note Synopsis | ||
`Event`s are objects that contain information about the execution of the application. They are mainly used by service providers like block explorers and wallet to track the execution of various messages and index transactions. | ||
::: | ||
|
||
## Default Events | ||
|
||
There are a few events that are automatically emitted for all messages, directly from `baseapp`. | ||
|
||
* `message.action`: The name of the message type. | ||
* `message.sender`: The address of the message signer. | ||
* `message.module`: The name of the module that emitted the message. | ||
|
||
:::tip | ||
The module name is assumed by `baseapp` to be the second element of the message route: `"cosmos.bank.v1beta1.MsgSend" -> "bank"`. | ||
In case a module does not follow the standard message path, (e.g. IBC), it is advised to keep emitting the module name event. | ||
`Baseapp` only emits that event if the module have not already done so. | ||
::: |