version: 2
models:
  - name: mars__ez_redbank_balance_changes
    description: Records of all balance change actions that occured within MARS red bank on osmosis
    columns:
      - name: BLOCK_ID
        description: "{{ doc('block_id') }}"
        tests:
          - dbt_expectations.expect_column_to_exist
      - name: BLOCK_TIMESTAMP
        description: "{{ doc('block_timestamp') }}"
        tests:
          - dbt_expectations.expect_column_to_exist
      - name: TX_ID
        description: "{{ doc('tx_id') }}"
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: TX_SUCCEEDED
        description: "{{ doc('tx_succeeded') }}"
        tests: 
         - dbt_expectations.expect_column_to_exist
      - name: MSG_GROUP
        description: "{{ doc('msg_group') }}"
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: MSG_SUB_GROUP
        description: "{{ doc('msg_sub_group') }}"
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: MSG_INDEX
        description: "{{ doc('msg_index') }}"
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: CONTRACT_NAME
        description: The name of the contract that was interacted with
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: ACTION
        description: The action that took place in the transaction. This always be balance_change.
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: USER
        description: The address that the balance change is relevant for
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: ASSET_INDEX
        description: The index of the asset
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: CURRENCY
        description: "{{ doc('currency') }}"
        tests: 
          - dbt_expectations.expect_column_to_exist
      - name: REWARDS_ACCRUED
        description: The amount of rewards that have accured
        tests: 
          - dbt_expectations.expect_column_to_exist
          - dbt_expectations.expect_column_values_to_be_in_type_list:
              column_type_list:
                - NUMBER
                - FLOAT
      