> ## Documentation Index
> Fetch the complete documentation index at: https://docs.formo.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Transaction event

> Reference for the transaction event, including status tracking for started, broadcasted, confirmed, reverted, and rejected wallet transactions with chain and hash data.

The `transaction` event is emitted whenever the user performs a transaction.
It includes the transaction status (started, broadcasted, confirmed, reverted, rejected), recipient address, data, value, transaction hash, chain ID, and wallet address.

## Properties

| Property           | Type   | Description                                                                                        |
| ------------------ | ------ | -------------------------------------------------------------------------------------------------- |
| `status`           | String | Transaction status: `started`, `broadcasted`, `confirmed`, `reverted`, or `rejected`               |
| `chain_id`         | Number | Chain ID of the network                                                                            |
| `data`             | String | Transaction calldata (hex-encoded)                                                                 |
| `to`               | String | Recipient address                                                                                  |
| `value`            | String | Transaction value (hex-encoded)                                                                    |
| `transaction_hash` | String | Transaction hash (available after broadcast)                                                       |
| `function_name`    | String | Decoded function name (if contract interaction)                                                    |
| `function_args`    | Object | Decoded function arguments (if contract interaction)                                               |
| `builder_codes`    | String | Comma-separated [builder codes](#builder-codes) extracted from the transaction calldata (ERC-8021) |

<Note>
  Each entry in `function_args` is also flattened into the event's top-level properties for easier querying. For example, `function_args: { foo: "bar" }` also adds `foo: "bar"` as a property.
</Note>

## Builder Codes

The Formo data platform automatically detects and extracts [ERC-8021](https://www.erc8021.com/) builder codes from transaction calldata. Builder codes are an onchain attribution standard that lets apps identify themselves in transactions.

When a transaction includes an ERC-8021 data suffix, Formo parses it and includes the `builder_codes` field in the transaction event. For example, a transaction with the builder code `"uniswap"` would include `"builder_codes": "uniswap"` in the event properties.

This works automatically - no additional configuration is needed. If your app appends builder codes to transactions, Formo will detect and attribute them.

## Sample Payload

Here's the payload of a typical call with most common fields removed:

```json theme={null}
{
    "type": "transaction",
    "properties": {
        "status": "broadcasted",
        "chain_id": 84532,
        "data": "0xa4136862000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000086173646661647366000000000000000000000000000000000000000000000000",
        "to": "0x76BB9C9758F62822Abaa652D49e52Ce85383FC26",
        "value": "0x1",
        "transaction_hash": "0x489daee9ded2bfcceb9f9c3edeaf695bd2c3acef0dfb7558e461b2aba59378ba",
        "function_name": "setText",
        "function_args": {
            "text": "asdfadsf"
        },
        "text": "asdfadsf",
        "builder_codes": "uniswap"
    }
}
```
