---
# System prepended metadata

title: Описание работ для archway

---

# Описание работ по индексеру для archway 

## wasm module state tables

```sql=
CREATE TABLE contracts
(
    address       TEXT                        NOT NULL UNIQUE PRIMARY KEY,
    code_id       BIGINT                      NOT NULL,
    creator       TEXT                        NOT NULL DEFAULT '',
    admin         TEXT                        NOT NULL DEFAULT '',
    label         TEXT                        NOT NULL DEFAULT '',
    creation_time TEXT                        NOT NULL DEFAULT '',
    tx            BIGINT                      NOT NULL DEFAULT 0,
    gas           BIGINT                      NOT NULL DEFAULT 0,
    fees          BIGINT                      NOT NULL DEFAULT 0,
    height        BIGINT                      NOT NULL
);
```

## wasm module history tables

1. Store Code msg
2. Instantiate Contract (2) msg
3. Contract execute msg
4. Migrate Contract msg
5. Update Admin msg
6. Clear Admin msg
7. Update Instantiate Config msg
8. Update Params msg
9. Sudo Contract msg
10. Pin Codes msg
11. Unpin Codes msg
12. Store And Instantiate Contract msg
13. Remove Code Upload Params Addresses msg
14. Add Code Upload Params Addresses msg
15. wasm params
16. And so on. WIll based on module availability, 

## TODO in the next stage
Dinamical tables initializating for detailed contracts data parsing by contract code from contract msg bytes

## archway module history tables

1. Msg Set Contract Metadata
2. Msg Withdraw Rewards
3. Msg Withdraw Rewards Response
4. Msg Set Flat Fee
