Skip to main content

Events

Events are emitted on the execution of messages and are used to notify the client of the result of the transaction.

EventAccountRegistered

Emitted when a new abstract account is successfully registered.

message EventAccountRegistered {
string creator = 1;
uint64 code_id = 2;
string contract_addr = 3;
}

1. Attributes

  • creator: The address that registered the account
  • code_id: The CosmWasm code ID of the proxy contract instantiated
  • contract_addr: The address of the newly created abstract account contract

1. Example

{
"type": "d.abstractaccount.v1.EventAccountRegistered",
"attributes": [
{
"key": "creator",
"value": "dchain1..."
},
{
"key": "code_id",
"value": "1"
},
{
"key": "contract_addr",
"value": "dchain14hj2tavq8fpesdwxxcu44rty3hh90vhujrvcmstl4zr3txmfvw9s0phg4d"
}
]
}

EventUpdatedActor

Emitted when an actor address is updated by the module authority.

message EventUpdatedActor {
string actor = 1;
string contract_addr = 2;
}

2. Attributes

  • actor: The actor role identifier (e.g., "validator", "operator")
  • contract_addr: The new contract address associated with this actor role

2. Example

{
"type": "d.abstractaccount.v1.EventUpdatedActor",
"attributes": [
{
"key": "actor",
"value": "validator"
},
{
"key": "contract_addr",
"value": "dchain1..."
}
]
}

EventUpdatedAuthenticator

Emitted when an authenticator address is updated by the module authority.

message EventUpdatedAuthenticator {
string authenticator = 1;
string contract_addr = 2;
}

3. Attributes

  • authenticator: The authenticator role identifier
  • contract_addr: The new contract address associated with this authenticator role

3. Example

{
"type": "d.abstractaccount.v1.EventUpdatedAuthenticator",
"attributes": [
{
"key": "authenticator",
"value": "default"
},
{
"key": "contract_addr",
"value": "dchain1..."
}
]
}

EventUpdatedSupportedProxies

Emitted when the set of supported proxy code IDs is updated by the module authority.

message EventUpdatedSupportedProxies {
repeated uint64 code_ids = 1;
}

4. Attributes

  • code_ids: The complete list of supported proxy code IDs after the update

4. Example

{
"type": "d.abstractaccount.v1.EventUpdatedSupportedProxies",
"attributes": [
{
"key": "code_ids",
"value": "[1, 2, 3]"
}
]
}

EventUpdatedParams

Emitted when the module parameters are updated by the module authority.

message EventUpdatedParams {
Params params = 1;
}

5. Attributes

  • params: The complete set of updated module parameters

5. Example

{
"type": "d.abstractaccount.v1.EventUpdatedParams",
"attributes": [
{
"key": "params",
"value": "{...}"
}
]
}

Event Monitoring

You can monitor these events in real-time using the following command:

# Subscribe to new blocks and filter for abstractaccount events
d q block --height=<height> | jq '.result.events[] | select(.type | startswith("d.abstractaccount"))'

Or query events from past transactions:

# Query account registration events
d q txs --events 'd.abstractaccount.v1.EventAccountRegistered.creator=dchain1...'

# Query actor update events
d q txs --events 'd.abstractaccount.v1.EventUpdatedActor.actor=validator'