Junø
WebDiscordGithubTwitter
  • Juno
    • Intro
    • Home of CosmWasm
    • Contributors - Core Software
    • Brand Identity
    • Security Disclosures
    • Economic Overview
      • Disclaimer
      • Native Asset (JUNO)
      • Incentive structure
      • Supply API - Data
  • Developer Guides
    • CosmWasm Contracts
      • Compile a Contract
      • Deploy a Contract
      • Guide: How to Upload a Smart Contract on the Juno Chain
      • Use Cw-orchestrator to speed-up your development
      • Query A Contract
      • Send Tokens to a Contract
    • Miscellaneous
      • Conversions
      • Multi Message Transaction
      • Get & Decode Transactions
      • Get Token Prices
      • Get Account Transactions
      • IBC Transfer
      • State Export / Airdrop
    • Juno Modules
      • FeeShare
      • TokenFactory
    • API Endpoints
      • Cosmos
        • Tx
          • V1beta1
            • Simulate
            • Txs
              • Block
        • Params
          • V1beta1
            • Params
        • Bank
          • V1beta1
            • Balances
              • By denom
            • Denoms metadata
            • Params
            • Spendable balances
            • Supply
        • Upgrade
          • V1beta1
            • Applied plan
            • Current plan
            • Module versions
            • Upgraded consensus state
        • Auth
          • V1beta1
            • Accounts
            • Module accounts
            • Params
        • Staking
          • V1beta1
            • Delegations
            • Historical info
            • Params
            • Pool
            • Validators
              • Delegations
                • Unbonding delegation
              • Unbonding delegations
            • Delegators
              • Redelegations
              • Unbonding delegations
              • Validators
        • Evidence
          • V1beta1
            • Evidence
        • Mint
          • V1beta1
            • Annual provisions
            • Inflation
            • Params
        • Feegrant
          • V1beta1
            • Allowance
            • Allowances
            • Issued
        • Gov
          • V1beta1
            • Params
            • Proposals
              • Deposits
              • Tally
              • Votes
        • Distribution
          • V1beta1
            • Community pool
            • Params
            • Delegators
              • Rewards
              • Validators
              • Withdraw address
            • Validators
              • Commission
              • Outstanding rewards
              • Slashes
        • Slashing
          • V1beta1
            • Params
            • Signing infos
        • Authz
          • V1beta1
            • Grants
              • Grantee
              • Granter
        • Base
          • Tendermint
            • V1beta1
              • Blocks
                • Latest
              • Node info
              • Syncing
              • Validatorsets
                • Latest
          • Node
            • V1beta1
              • Config
      • Cosmwasm
        • Wasm
          • V1
            • Code
              • Contracts
            • Contract
              • History
              • Raw
              • Smart
              • State
            • Codes
              • Params
              • Pinned
            • Contracts
              • Creator
      • Juno
        • Feeshare
          • V1
            • Fee shares
            • Params
        • Tokenfactory
          • V1beta1
            • Denoms from creator
            • Params
            • Denoms
              • Authority metadata
      • Ibc
        • Apps
          • Router
            • V1
              • Params
      • API Specification
    • Local Interchain
      • Local Interchain Rust Example
    • Junod Local Dev Setup
    • Integrate Leap wallet
    • SubQuery Indexer
  • Governance
    • Before submitting a proposal
    • Submitting a Proposal (CLI)
      • Formatting Proposal Markdown
  • Command-Line Interface (CLI)
    • Introduction
    • Useful CLI Commands
    • Module Reference
      • bank
      • distribution
      • gov
      • keys
      • params
      • slashing
      • staking
      • status
      • tendermint
      • upgrade
      • wasm
  • Nodes & Validators
    • Junod Installation and setup
    • Setting up Cosmovisor
    • Mainnet Setup and Tooling
    • Joining Mainnet
      • Sync from Snapshot
      • Sync with state-sync
      • Mainnet Upgrades
    • Joining Testnet
    • Relaying
    • Juno Delegations Program
Powered by GitBook
On this page

Was this helpful?

  1. Developer Guides
  2. API Endpoints
  3. Cosmos
  4. Tx
  5. V1beta1

Txs

PreviousSimulateNextBlock

Last updated 2 years ago

Was this helpful?

GetTx fetches a tx by hash.

get
Path parameters
hashstringRequired

hash is the tx hash to query, encoded as a hex string.

Responses
200
A successful response.
application/json
default
An unexpected error response.
application/json
get
GET /cosmos/tx/v1beta1/txs/{hash} HTTP/1.1
Host: 
Accept: */*
{
  "tx": {
    "body": {
      "messages": [
        {
          "type_url": "text",
          "value": "Ynl0ZXM="
        }
      ],
      "memo": "text",
      "timeout_height": "text",
      "extension_options": [
        {
          "type_url": "text",
          "value": "Ynl0ZXM="
        }
      ],
      "non_critical_extension_options": [
        {
          "type_url": "text",
          "value": "Ynl0ZXM="
        }
      ]
    },
    "auth_info": {
      "signer_infos": [
        {
          "public_key": {
            "type_url": "text",
            "value": "Ynl0ZXM="
          },
          "mode_info": {
            "single": {
              "mode": "SIGN_MODE_UNSPECIFIED"
            },
            "multi": {
              "bitarray": {
                "extra_bits_stored": 1,
                "elems": "Ynl0ZXM="
              },
              "mode_infos": []
            }
          },
          "sequence": "text"
        }
      ],
      "fee": {
        "amount": [
          {
            "denom": "text",
            "amount": "text"
          }
        ],
        "gas_limit": "text",
        "payer": "text",
        "granter": "text"
      }
    },
    "signatures": [
      "Ynl0ZXM="
    ]
  },
  "tx_response": {
    "height": "text",
    "txhash": "text",
    "codespace": "text",
    "code": 1,
    "data": "text",
    "raw_log": "text",
    "logs": [
      {
        "msg_index": 1,
        "log": "text",
        "events": [
          {
            "type": "text",
            "attributes": [
              {
                "key": "text",
                "value": "text"
              }
            ]
          }
        ]
      }
    ],
    "info": "text",
    "gas_wanted": "text",
    "gas_used": "text",
    "tx": {
      "type_url": "text",
      "value": "Ynl0ZXM="
    },
    "timestamp": "text",
    "events": [
      {
        "type": "text",
        "attributes": [
          {
            "key": "Ynl0ZXM=",
            "value": "Ynl0ZXM=",
            "index": true
          }
        ]
      }
    ]
  }
}
  • GETGetTxsEvent fetches txs by event.
  • POSTBroadcastTx broadcast transaction.
  • GETGetTx fetches a tx by hash.

GetTxsEvent fetches txs by event.

get
Query parameters
eventsstring[]Optional

events is the list of transaction event type.

pagination.keystring · byteOptional

key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set.

pagination.offsetstring · uint64Optional

offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set.

pagination.limitstring · uint64Optional

limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app.

pagination.count_totalbooleanOptional

count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set.

pagination.reversebooleanOptional

reverse is set to true if results are to be returned in the descending order.

Since: cosmos-sdk 0.43

order_bystring · enumOptional
  • ORDER_BY_UNSPECIFIED: ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults to ASC in this case.
  • ORDER_BY_ASC: ORDER_BY_ASC defines ascending order
  • ORDER_BY_DESC: ORDER_BY_DESC defines descending order
Default: ORDER_BY_UNSPECIFIEDPossible values:
Responses
200
A successful response.
application/json
default
An unexpected error response.
application/json
get
GET /cosmos/tx/v1beta1/txs HTTP/1.1
Host: 
Accept: */*
{
  "txs": [
    {
      "body": {
        "messages": [
          {
            "type_url": "text",
            "value": "Ynl0ZXM="
          }
        ],
        "memo": "text",
        "timeout_height": "text",
        "extension_options": [
          {
            "type_url": "text",
            "value": "Ynl0ZXM="
          }
        ],
        "non_critical_extension_options": [
          {
            "type_url": "text",
            "value": "Ynl0ZXM="
          }
        ]
      },
      "auth_info": {
        "signer_infos": [
          {
            "public_key": {
              "type_url": "text",
              "value": "Ynl0ZXM="
            },
            "mode_info": {
              "single": {
                "mode": "SIGN_MODE_UNSPECIFIED"
              },
              "multi": {
                "bitarray": {
                  "extra_bits_stored": 1,
                  "elems": "Ynl0ZXM="
                },
                "mode_infos": []
              }
            },
            "sequence": "text"
          }
        ],
        "fee": {
          "amount": [
            {
              "denom": "text",
              "amount": "text"
            }
          ],
          "gas_limit": "text",
          "payer": "text",
          "granter": "text"
        }
      },
      "signatures": [
        "Ynl0ZXM="
      ]
    }
  ],
  "tx_responses": [
    {
      "height": "text",
      "txhash": "text",
      "codespace": "text",
      "code": 1,
      "data": "text",
      "raw_log": "text",
      "logs": [
        {
          "msg_index": 1,
          "log": "text",
          "events": [
            {
              "type": "text",
              "attributes": [
                {
                  "key": "text",
                  "value": "text"
                }
              ]
            }
          ]
        }
      ],
      "info": "text",
      "gas_wanted": "text",
      "gas_used": "text",
      "tx": {
        "type_url": "text",
        "value": "Ynl0ZXM="
      },
      "timestamp": "text",
      "events": [
        {
          "type": "text",
          "attributes": [
            {
              "key": "Ynl0ZXM=",
              "value": "Ynl0ZXM=",
              "index": true
            }
          ]
        }
      ]
    }
  ],
  "pagination": {
    "next_key": "Ynl0ZXM=",
    "total": "text"
  }
}

BroadcastTx broadcast transaction.

post
Body

BroadcastTxRequest is the request type for the Service.BroadcastTxRequest RPC method.

tx_bytesstring · byteOptional

tx_bytes is the raw transaction.

modestring · enumOptional

BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method.

  • BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering
  • BROADCAST_MODE_BLOCK: BROADCAST_MODE_BLOCK defines a tx broadcasting mode where the client waits for the tx to be committed in a block.
  • BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only.
  • BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately.
Default: BROADCAST_MODE_UNSPECIFIEDPossible values:
Responses
200
A successful response.
application/json
default
An unexpected error response.
application/json
post
POST /cosmos/tx/v1beta1/txs HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 59

{
  "tx_bytes": "Ynl0ZXM=",
  "mode": "BROADCAST_MODE_UNSPECIFIED"
}
{
  "tx_response": {
    "height": "text",
    "txhash": "text",
    "codespace": "text",
    "code": 1,
    "data": "text",
    "raw_log": "text",
    "logs": [
      {
        "msg_index": 1,
        "log": "text",
        "events": [
          {
            "type": "text",
            "attributes": [
              {
                "key": "text",
                "value": "text"
              }
            ]
          }
        ]
      }
    ],
    "info": "text",
    "gas_wanted": "text",
    "gas_used": "text",
    "tx": {
      "type_url": "text",
      "value": "Ynl0ZXM="
    },
    "timestamp": "text",
    "events": [
      {
        "type": "text",
        "attributes": [
          {
            "key": "Ynl0ZXM=",
            "value": "Ynl0ZXM=",
            "index": true
          }
        ]
      }
    ]
  }
}