> This is part 1 of 2 of the full documentation (pages 1–100 of 121).
> The content is paginated: fetch every part to see all of it.
> Next part: https://docs.kiiglobal.io/docs/llms-full.txt/1
> Page index: https://docs.kiiglobal.io/docs/llms.txt

> Agents can also search and read this documentation through its [MCP server](https://docs.kiiglobal.io/docs/~gitbook/mcp).

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
This site has an agentic ask interface you may use to query the documentation dynamically by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.kiiglobal.io/docs/index.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

---

# What is KiiChain?

KiiChain is an onchain FX layer for stablecoin and RWA. At the core is a hybrid centralized-decentralized exchange platform designed for 24/7 onchain FX trading for cross-border payments.

### What is Kii?

Kii is an onchain FX layer that connects global stablecoin liquidity such as USDT and USDC with locally denominated stablecoins and markets across emerging economies. Users, businesses or builders can use Kii by signing up for an account or connecting to APIs. Kii differs from other traditional platforms by its hybrid approach of sourcing liquidity and maintaining balances onchain exposed to local currencies. Kii supports cross-border payments, remittances, trade settlement, fiat swaps and payins/payouts via the pricing of local, non-dollar stablecoins and other tokenized real-world assets.

### Hybrid Matching Engine

At the core of Kii is a hybrid matching engine that is able to source onchain liquidity across any blockchain ecosystem while using centralized pricing to hedge and rebalance onchain positions. The result is an ultra-liquid layer that can operate 24/7 on certain pairs that only have liquidity during traditional business hours.

### Ramps

Kii has a full suite of on and off ramps enabling instant payins and payouts from its system. These ramps are both UI and API enabled with the ability to disperse directly or to third-party accounts. On and Off ramp functionality is available only where permitted by applicable law and, where required, is delivered through licensed issuers and distributors. Availability differs by jurisdiction, and certain jurisdictions — absent local licensing — are excluded.

### Sign up for an account

Use KiiChain by logging in or signing up [here](https://pay.kiichain.io/).

### Connect to APIs

Kii has developed a suite of APIs that embed all centralized and decentralized functionalities into a single set of APIs that any application can use. For more information on the APIs, visit:

* [Kii APIs](https://docs.kiiglobal.io/docs/kiichain-pay/introduction)

### KYC / AML

Kii operates only where permitted by applicable law and, where required, through locally licensed partners; availability differs by jurisdiction. Users must complete applicable KYC/AML requirements.

### Cosmos SDK

The Cosmos SDK is an open-source framework for building multi-asset public Proof-of-Stake (PoS) blockchains, like the Cosmos Hub. The goal of the Cosmos SDK is to allow developers to easily create custom blockchains from scratch that can natively interoperate with other blockchains. SDK-based blockchains are built out of composable modules, most of which are open-source and readily available for any developers to use. The Cosmos SDK is a capabilities-based system that allows developers to better reason about the security of interactions between modules. Learn more about Cosmos [here](https://docs.cosmos.network/).

### Comet BFT

Comet BFT (Byzantine Fault Tolerant) is the upgraded version of Tendermint Core, the Interchain's consensus mechanism that powers Cosmos SDK blockchain systems. Comet BFT has a modular architecture that separates the consensus engine from the application layer, allowing developers to build custom blockchain applications easily. It offers fast transaction finality and high throughput, making it ideal for applications that require quick and reliable performance. Learn more about Comet BFT [here](https://cometbft.com/).

### Proof-of-Stake

KiiChain is a Proof-of-Stake blockchain. PoS selects validators based on the number of tokens they hold and are willing to "stake" as collateral for servicing and securing the network. Delegators, or individual "stakers", can delegate their tokens to any specific validator that meets the requirements.

### EVM Module

The EVM module allows for mirrored EVM compatibility and for smart contracts to be deployed in Solidity to the network. This means it can run all existing Ethereum dApps and smart contracts without needing any changes. It achieves this with a high-performance Ethereum Virtual Machine (EVM) that is optimized for speed and reliability. Thanks to its modular, plugin-based design, it allows any host blockchain to execute Ethereum transactions and smart contracts.

### IBC

Inter-Blockchain Communication is a protocol that allows for cross chain communication and data transfers. It connects different blockchain networks to promote high levels of interoperability, scalability and communication. IBC can be implemented to any blockchain network as long as it conforms to its protocol guidelines. Currently, there are over 100 networks integrated into IBC. Read more about IBC [here](https://www.ibcprotocol.dev/).

### Kii RWA Protocol

The Kii RWA Protocol sets standardization of Real World Asset (RWA) tokenization through the T-REX (Token for Regulated EXchanges) protocol using CosmWasm smart contracts on KiiChain that are simultaneously mirrored to ERC tokens. The T-REX protocol is designed for compliant issuance and management of tokens on blockchain networks. Apart from token standards, the protocol defines onchain KYC, KYB and asset verification. The Kii RWA protocol on KiiChain is creating an interoperable unified liquidity layer for RWA tokens.


# KiiChain

A background on why we're relentlessly building every day.

### About Kii

A lot has transpired since Satoshi’s whitepaper announcing the arrival of Bitcoin in 2008 as Bitcoin has become the digital gold standard and is positioning itself as the reserve currency of the world. In 2013, Ethereum established itself as the leader in layer 1 infrastructure, initiating the cycle of growth among web3 businesses. Since then, over 1 million tokens have been publicly launched, each with their unique focus.

The growth of each project has a common theme within the technology: Communication. Blockchain infrastructure connects users in ways never before, eliminating a centralized counterparty needed to facilitate that connection, and instead proposes changes to the architecture enabling decentralization as the preferred means of communication. Even though this change has prompted user adoption globally, there remains gaps in the technology that adjust to specific market and cultural conditions in emerging economies.

In developing countries, the current transfer of value mechanisms that connect emerging economies to developed economies are overly centralized, slow and costly. It's determined to be why emerging economies in the last 25 years have yet to “emerge”. These transfer of value networks have failed to improve globalization and local commerce in an efficient way, connecting important economic counterparts in order to create uniformity in how they communicate.

Although economically a very large industry, emerging markets don't just thrive on remittances from users aboard. Their economies are normally derived from production locally. Whether its natural resources and commodities, exports of goods, imports for raw materials for production of those goods, the necessity for a dedicated, open-sourced, unified liquidity layer is clear given that the B2B market is 10x+ the size of consumer remittances with higher average volumes and transactions. Faster fiat settlements, safer FX solutions, and access to international credit terms are only a few of the current existing pain-points.

KiiChain is unwaveringly committed to delivering high-performance, interconnected, and ultra-secure blockchain solutions as a driver in economic development in emerging markets in an effort to improve communication and globalization. At the heart of our technological prowess is the CometBFT mechanism, a solution for problems that exist in the economy, particularly emerging economies and Latin America. However, more than just a blockchain, Kii Global has built an infrastructure ecosystem of solutions designed to unify blockchain liquidity and its participants, in an effort to directly solve some of the biggest economic challenges in the region.

<br>


# Vision of KiiChain

Our vision of what and why we are building relentlessly everyday.

### FX settlement layer for Stablecoins and tokenized Real-World Assets

KiiChain is a supercharged unified liquidity network for international trade, finance and payments – specifically built for emerging markets. It seamlessly melds with prevailing payment infrastructures, aiming to alleviate the exorbitant costs and reduce barriers in global economic transactions. Unlike other monolithic blockchain layers, KiiChain is purpose-built for emerging markets and “last mile” integrations into local economies, breathing life into previously liquidity-constrained sectors that cannot financially communicate with the rest of the world.

The blockchain rides on the back of the CometBFT consensus mechanism built with the Cosmos SDK - a testament to its decentralization and commitment to achieve lightning-fast finality and minuscule network fees. Primarily, its design suits the daily exigencies of emerging economies, taking into account the wealth imbalances that exist. KiiChain’s Comet consensus mechanism boasts supercar-fast validators that produce blocks in seconds, allowing for instantaneous cross-chain settlement times and a fee on the network less than one peso.

The Kii blueprint saw expansion within its product and app suite, incorporating custom onchain protocols and modules to allow any user, builder or business to connect directly to the network. KiiChains flagship native app, KIIEX, is a hybrid centralized-decentralized exchange specifically conceptualized for liquidity assimilations in RWA and payment settlement. KiiChain is amplified by a series of protocols and modules that provide interconnectivity between Ethereum, Solana, Cosmos and more – providing unified access to tradeable assets across ecosystems on one network.

The product suite provides institutional infrastructure and liquidity, connecting global players to local operators. KiiChain is EVM compatible and supports smart contracts in both Solidity and Rust. It’s a permissionless ecosystem for open finance, where web2 and web3 developers can build a wide variety of dApps and protocols.

<br>


# Use Cases

Use cases are economy-centric, real world models currently in use. Kii is developing technological solutions to solve the current problems within each niche.

### Stablecoin FX powerhouse

Traditional FX operations are hindered by TradeFi banking hours (often times 8am to 1pm local). Essentially, only 25% of the day, on business banking days, can businesses or users engage in FX operations. Users can engage in fast and affordable FX transactions on KiiChain with real-time settlement, where available. FX-related functionality is available only where permitted by applicable law and, where required, is delivered through locally licensed partners. Availability differs by jurisdiction, and certain jurisdictions are excluded.

### Unified Liquidity for Trading and Payments

Liquidity is often fragmented among several different blockchain ecosystems. This causes headaches for users who need to manage different balances and wallets among different ecosystems. Direct bridging from each network can be slow, costly and difficult for users who don’t understand web3 architecture. KiiChain partners with protocols to create an interoperable liquidity layer that can deliver seamless cross-chain experiences to users of all types.

### Tokenization of Commodities (RWA)

Commodities are among the most valuable and traded goods in the world with major reserves being mined and developed in emerging countries. Local companies can now tokenize their commodities and contracts, pricing them in Kii or a native asset to their project, and create instant liquidity on a global scale. RWA functionality is available only where permitted by applicable law and, where required, is delivered through licensed issuers and distributors. Availability differs by jurisdiction, and certain jurisdictions — absent local licensing — are excluded.

### Tokenization of Products (RWA)

Imported and exported goods are one of the major drivers of GDP within Latin America and emerging economies. Many multinational companies in the region struggle to process funds and manage liquidity reserves. These products can be tokenized and transacted on the blockchain for users to transact with these goods, and for companies to better manage their reserves. RWA functionality is available only where permitted by applicable law and, where required, is delivered through licensed issuers and distributors. Availability differs by jurisdiction, and certain jurisdictions — absent local licensing — are excluded.

### Tokenization of Real Estate (RWA)

Asset fractionalization and ownership is becoming more imperative than ever before in markets with wealth fragmentation, high inflation and high interest rates. Real estate and asset infrastructure fractionalization allows users to own assets that generally cannot be owned by these users in whole. By democratizing the ownership process, liquidity can extend to other markets and users who would not otherwise have access prior. RWA functionality is available only where permitted by applicable law and, where required, is delivered through licensed issuers and distributors. Availability differs by jurisdiction, and certain jurisdictions — absent local licensing — are excluded.

### Tokenization of Debt and Equities (RWA)

Regulated financial instruments such as equities, debt, and ETFs can be represented as tokens to broaden and fractionalize access where lawful. Tokenization of regulated financial instruments will occur only through licensed issuers and distributors, geo-restricted to jurisdictions where lawful, and will not be offered to residents of the Republic of Korea (or any relevant jurisdiction) absent local licensing.

### DeFi Lending and Borrowing for Open Credit System

Credit is a huge issue in developing countries with strict underwriting standards, toxic level interest rates and lack of available capital. DeFi lending will provide ways for users in developed countries to extend credit terms to participants in emerging markets.

### Payment Finance

Businesses and users in developing countries lack formal communication with payment processors abroad. Payment finance is a model that allows local businesses to bring their economic activity onchain and receive financing that supports their core businesses, primary payment services activities.

### Credit Finance

Emerging markets suffer from a multi-trillion dollar credit gap. When businesses can bring their economic activity onchain, they open themselves up to the world of lending and competitive interest rates. Businesses or users who could not previously receive credit from local institutions, can now communicate with lenders abroad. Credit financing functionality is available only where permitted by applicable law and, where required, is delivered through licensed issuers and distributors. Availability differs by jurisdiction, and certain jurisdictions — absent local licensing — are excluded.

### Spot and Forward Settlement

The B2B remittance market transacts over hundreds of billions USD annually. These importers and exporters either win or lose on spot or forward contract settlements. By each counterparty posting liquidity via a smart contract on the blockchain, users can hedge losses by sharing in any FX swings.


# Roadmap

Where we've been and where we're going.

## Executive Roadmap

KiiChain moves money between emerging-market currencies and the dollar economy: 24/7, on-chain, programmable, without correspondent banking. Three years of building are already live. Everything ahead sits on three pillars.

* Kii: On-chain FX. More currency corridors, more protocol rails. Live in Colombian pesos, Brazilian reais and Mexican pesos, with US dollars, Argentine pesos, yen and euro/sterling next.
* Yield Vaults: A way to put idle balances to work while they wait, in dollars or in local currency, without leaving Kii. Availability and returns vary by jurisdiction; no return is guaranteed.
* On-Chain Financial Services: US virtual accounts first, then everyday tools built on the same on-chain balance.

Together they move Kii from a place to settle an FX swap to a place to hold, earn on, move and receive money across borders.How to read this documentItems in this roadmap carry different levels of certainty. Each one is labelled:

* Live: in production today.
* Committed: dated, resourced and being built.
* Signed: partnership executed, not yet launched.
* Under assessment: being evaluated; no date attached.
* Exploratory: concept only; no commitment, no date.

**Status at a glance**

| What                                                                  | Status    | When     |
| --------------------------------------------------------------------- | --------- | -------- |
| Mainnet, Kii App, Atomic Quote Network, exchange listings and bridges | Live      | Now      |
| COP, BRL and MXN corridors                                            | Live      | Now      |
| Advanced fiat-pair FX swap page; Tron USDT (TRC-20) swap and bridge   | Committed | Sep 2026 |
| Network-wide CosmWasm on testnet; multistep pay orchestration         | Committed | Oct 2026 |
| First liquidity vaults and short-duration Treasury vaults             | Committed | Oct 2026 |
| USD and ARS corridors; US virtual accounts                            | Committed | Nov 2026 |
| JPY corridor                                                          | Committed | Dec 2026 |
| EUR / GBP corridors                                                   | Committed | Feb 2027 |
| CLP and PEN corridors                                                 | Committed | Q1 2027  |

|                                       |                  |            |
| ------------------------------------- | ---------------- | ---------- |
| US and Argentina on/off-ramp partners | Signed           | Pre-launch |
| Additional Asian corridors            | Under assessment | No date    |
| Debit cards; collateral-free credit   | Exploratory      | No date    |

**Where Kii stands today**\
\
$500m+ cumulative transaction volume, growing roughly 10% month over month · 350,000+ users · 200+ enterprise clients · $26M raised from institutional investors · $5.4B notional covered by signed tokenization agreements (contracted pipeline).Note on dates. Dates are targets based on current plans. “Committed” means planned, resourced and in build; it is not a guarantee of delivery. Every item depends on technical, commercial and licensing conditions in each market and may change.


# Part 1: Inception

KiiChain did not begin as a blockchain. It began as a payments business.\
\
The team behind Kii Global spent its first years operating an over-the-counter (OTC) trading and B2B payments desk in Latin America moving real money for real businesses, and running directly into the structural problems that define cross-border finance in emerging markets: shallow dollar liquidity, banking hours that don’t match a 24/7 economy, correspondent-banking chains that add days and fees to every transfer, and local currencies that the global FX system treats as peripheral. That operating experience is the reason KiiChain is designed the way it is. The chain was built to industrialize a payments business that already worked, not to find a use case for a chain that already existed.The problems of pre-existing infrastructure and Kii’s solutions to this can be further explained in these two articles:

* [Stablecoins are changing FX markets, but challenges remain](https://medium.com/cosmos-blockchain/stablecoins-are-changing-global-fx-markets-but-challenges-remain-f5d062bb6a15)
* [Why FX Needs Its Own Onchain Architecture - And How KiiChain Built It](https://x.com/KiiChainio/status/2058960870978253164)

What follows is the build history, year by year. The pattern is consistent: prove the flow off-chain, then move it on-chain by solving specific problems; ship infrastructure, then harden it with audits; grow the network, then decentralize it.

### 2023: From a trading desk to a platform

* Q1: KiiChain Devnet. The first development network went live, establishing the base architecture the team would iterate on for the next three years. This devnet laid the foundation for the core infrastructure on which all Kii services will ultimately be deployed.
* Q2: KIIEX build begins. The OTC operation was re-architected from a manual desk into scalable exchange technology. This is the origin of KIIEX, a CLOB conceived specifically for FX and payments rather than as a generic crypto spot venue.
* Q3: KIIEX Beta. The exchange launched in beta, testing trading and payments on the mainnet in a whitelist-only environment. During this period, the desk-plus-exchange operation processed over $50M in total volume and reached viability, a rare and important signal for infrastructure at this stage, because it proved demand and unit economics before any token existed ([kiiex.io](http://kiiex.io/)).
* Q4: Kii mobile wallet. A mobile wallet was developed for version 1 of the testnet, extending the platform from an institutional desk toward an end-user product ([App Store Reference](https://apps.apple.com/co/app/kii-mobile/id6474740411)).

### 2024: The chain takes shape

* Q1: KiiChain Testnet V1. The first full testnet launched, built on the Cosmos SDK with CometBFT consensus, the foundation that gives KiiChain fast, deterministic finality and native IBC interoperability ([kii Github](https://github.com/KiiChain/kii))
* Q2: KIIEX. KIIEX left beta and went live with multi-varied APIs, onboarding 50+ enterprise clients with access to a combined base of 200,000+ users. The platform crossed[$200M+](https://x.com/search?q=%24200M%2B\&src=cashtag_click)in cumulative trading volume and built out 30+ strategic partnerships across the region. We saw heavy traction with enterprises and individual users alike, because KIIEX has substantial advantages over traditional rails:

1. Full API-powered payins and payouts.
2. 24/7 settlement, with no banking-hour or weekend delays. Little to no need for FX clearance.
3. On-chain FX withdrawals in non-dollar stablecoins where clients can manage their own disbursements.
4. Third-party payment capabilities for licensed providers.
5. Direct settlement to popular banks and fintech apps with fast settlement.
6. A 24/7 OTC desk with live chat and support teams

* Q3: Testnet V2 (EVM). Testnet V2 introduced an EVM execution module, making the chain fully EVM-compatible and allowing Solidity contracts to deploy directly alongside CosmWasm, a deliberate choice to meet both Web2 and Web3 builders where they already are[(kii2 Github](https://github.com/KiiChain/kiichain2)).
* Q4: Testnet V3 (the product modules). V3 upgrades introduced the modules that define KiiChain as a product, not just a chain: a new EVM module, the RWA protocol and the Oracle module. This is the quarter KiiChain became an on-chain FX and real-world-asset platform in architecture, not just ambition ([kiichain Github](https://github.com/KiiChain/kiichain)and[Modules Documentation](https://docs.kiiglobal.io/docs/build-on-kiichain/modules))

### 2025 Incentivized testnet, upgrades, and the road to mainnet

* Q1: Incentivized testnet (Oro). The incentivized testnet launched with XP and Oro loyalty points and on-chain tasks, seeding a real community of validators, builders, and users ahead of mainnet (see blog:[Testnet Oro Blog](https://kiichain.medium.com/kiichain-testnet-oro-airdrop-join-the-builders-embedding-the-future-of-finance-c96d7dbc4665)).
* Q2: Interoperability and rewards. IBC, Wasm, and EVM upgrades landed together, alongside a utility rewards module broadening what could connect to the chain and how participants earn from it ([Modules Documentation](https://docs.kiiglobal.io/docs/build-on-kiichain/modules)).
* Q3: Stablecoin gas and the first audit. EVM gas-fee abstraction for stablecoins shipped, letting users pay network fees in stablecoins rather than needing to hold the native token first, a critical UX unlock for a payments network. The first security audit (Webisoft) began in the same quarter.
* Q4: Testnet final version launched. The Testnet with all functionalities was completed, moving the network into a production-grade, controlled environment ahead of public mainnet launch ([Final Testnet Github Repo](https://github.com/KiiChain/kiichain)).

### 2026 Public network, public token

* Q1: Hacken Audit. A second, independent audit (Hacken) was conducted on the private mainnet, layering defense-in-depth on top of the Webisoft work (<https://hacken.io/audits/kiichain/l1-kiiex-l1-audit-mar2026/>). The audit finished on March 16th, with the Hacken Dual Defences finishing on June 8th (<https://hackenproof.com/audit-programs/kiichain-l1-dualdefense-audit>).
* Q2:[The KiiChain App](https://pay.kiichain.io/)was launched in Beta as an evolution to KIIEX and developed its own hybrid centralized-decentralized infrastructure called an AQN ([Atomic Quote Network](https://x.com/KiiChainio/status/2058960870978253164)). As the network began expanding into new on-chain FX territories.
* Q3: Public sale, TGE, and mainnet. The public sale of KII opened on the Sonar by Echo platform (owned by Coinbase) with over 9,000 registrations. The sale was capped at $1m USD and sold out in three days.The sale was conducted through Sonar by Echo, a platform owned by Coinbase, under that platform's KYC, AML, and jurisdictional eligibility procedures, which screened and excluded participants in restricted jurisdictions
* On August 14th 2026, KII published its mainnet and had its public listing with the following partners: Bybit, Binance Alpha, OKX Wallet, Bitget, Kraken, KuCoin and MEXC. A partnership was also established with Hyperlane where official bridges were set up between KiiChain and Ethereum, BNB Chain, Base, Polygon and Mantle ([Hyperlane Bridges Documentation](https://docs.kiiglobal.io/docs/learn/getting-started/bridge)).

Where that leaves us today The[KiiChain App](https://pay.kiichain.io/)(Kii) launched in beta as the next step after KIIEX. It takes everything the exchange taught us about liquidity and settlement and rebuilds it around a system we built ourselves: the Atomic Quote Network (AQN). It's also the app driving our expansion into new on-chain FX territories.We built the AQN because FX isn't spot crypto trading, and the usual on-chain models don't fit it. An AMM loses too much to slippage and impermanent loss on the thin, volatile pairs typical of emerging-market currencies. An order book needs deep, always-on liquidity those pairs don't have. So the AQN borrows how traditional FX actually finds a price (RFQ, or request-for-quote) and settles it on-chain. It's TradFi's way of pricing, and Blockchain's way of paying.Three smart contracts make that happen, each with one job:

* Router finds the best price. It takes your order, compares the competing quotes, picks the best path (a direct local pair, or one routed through USDT/USDC if that's cheaper), and passes it on.
* Fulfillment handles the liquidity. It's the market-maker side, making sure the counter-currency is actually posted and handling the accounting, fees, and rewards for whoever fills the order.
* Settlement moves the money. It runs the swap in a single transaction, paying out both sides at once, with quote expiry and slippage checked at the moment it executes. This is the "atomic" part.

For more information on the App, visit the documentation here ([Intro to Kii App](https://docs.kiiglobal.io/docs/kiichain-pay/introduction)) and review API documentation here ([Kii APIs](https://docs.kiiglobal.io/docs/kiichain-pay/api-reference))Here's a snapshot of where Kii stands today, by the numbers:

* Over $600M in cumulative transaction volume across the platform, growing at roughly 10% month over month. About 90% of that volume comes from enterprise clients, through both a B2B model and a B2B2C model, with retail accounting for the remaining 10%. The main flows moving across Kii are remittances, import and export settlement, market-maker activity, and more. On the enterprise side, Kii runs a strong business development motion, onboarding both direct clients and channel partners, backed by a six-person regional business development and marketing team and a steady on-the-ground presence at industry conferences that builds brand awareness and traction. On the retail side, that reach extends through B2B2C distribution, a remittance service, and on-chain financial services.
* 350,000+ users, and an incentivized testnet (Oro) that drew over 366,000 participants.
* Over 200 enterprise clients.
* $26M raised from institutional investors, led by a $20M round from Nimbus Capital, alongside In On Capital, Super Cycle Capital, Kahuna Ventures, WTG Ventures, Access Ventures, and Latam Nodes.
* $5.4B in notional asset value covered by signed tokenization agreements. These represent contracted pipeline only; assets are not yet issued or held on-chain., and connectivity to 100+ blockchain ecosystems for unified liquidity routing.
* A working local-stablecoin flywheel: Executing 24/7 on-chain FX swaps, solving for limited banking hours, slow settlements and centralized rebalancing.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FLoNT8tASuatFzm3YHqOe%2FHP8RlmEWoAAkAmq.jpeg?alt=media&amp;token=7f7032c3-57b6-4045-b51a-b593378bcb8b" alt=""><figcaption></figcaption></figure>


# Part II: Pillar 1

The product roadmap is organized around three pillars we are building now, followed by future concepts the network enables. The strategy is consistent with how KiiChain was built: each pillar extends an asset or flow that is already live, rather than betting on a new one.The three near-term pillars are:(1) Kii expanding on-chain FX, territories, and protocol rails (2) Yield Vaults, (3) On-Chain Financial Services.

### Pillar 1: Evolution of the Kii

**Problem**. Emerging-market FX is fragmented and closed. Dollar liquidity is shallow, banking hours do not match a 24/7 economy, and correspondent-banking chains add days and fees to every transfer.

**Kii’s insight.** FX is not spot crypto. Automated market makers bleed value on thin, volatile pairs, and order books need depth these currencies do not have. So price the way FX actually prices, using request-for-quote, and settle the way blockchains settle: atomically, in one transaction.

**Product**. The Atomic Quote Network, and the currency corridors and protocol rails routed across it.

**Advantage**. 24/7 settlement with no banking-hour or weekend delay. Local-currency routing rather than a forced dollar leg. Network fees typically measured in cents, and no correspondent banking. Every corridor runs on local licensed providers, so it works end to end rather than only on-chain. And each new currency multiplies the tradable routes across everything already live, so the network compounds.

**Expanding FX and territories**

The core work here is turning a single-corridor network into a many-corridor one. Expansion has three tracks:

**New currency corridors**. Onboard additional local-currency stablecoins and fiat liquidity across Latin America first, then broaden to other emerging markets with the same structural profile shallow dollar liquidity and peripheral-currency classification. Each new stablecoin and fiat is a new pair against USDT/USDC and against every other local stablecoin already on the network, so the number of tradable routes grows faster than the number of currencies added.Live Today

* \[Live] COP (Colombia)
* \[Live] BRL (Brazil)
* \[Live] MXN (Mexico)

We started with Colombia, Brazil, and Mexico on purpose: together they gave us the hardest, most useful conditions to prove the model, and the right base to grow from. COP was the anchor. It's a non-deliverable currency, so it's genuinely hard to access, with more friction (FX hours only operate from 8am - 1pm) and barriers than most, which meant our service solved a real problem for users from day one. It also made for a healthier order book: COP net flows run opposite to Brazil and Mexico, so the three can be crossed against each other into a more natural, balanced book, and very few players have strong COP flow to begin with, which gave us a real edge. All three settle against the dollar, so rebalancing between USD and USDT stayed simple across the whole book. Additionally, all three have large remittance and import/export markets, so we could solve clear, painful business problems for a lot of people at scale.Proving the model in these three is what sets up the rollout into the larger markets that follow\.Rolling out

* \[Committed – Nov 2026] USD (United States) Brings U.S. liquidity and payments online, along with FX infrastructure between USD and other assets.
* \[Committed – Nov 2026] ARS (Argentina), starting with ARS/USDT liquidity and payments.
* \[Committed – Dec 2026] JPY (Japan)liquidity and payments. Additional Asian corridors are under assessment, subject to local licensing feasibility.
* \[Committed – Feb 2027] EUR / GBP (Europe) – liquidity and payments in both euros and pounds
* \[Committed – Q1 2027] More LatAm currencies – CLP (Chile) and PEN (Peru) live by Q1 2027

Licensed last-mile coverage. On/off-ramp and fiat settlement remain dependent on licensed, KYC-compliant operators in each market. Territory expansion therefore means signing and integrating regulated on/off-ramp partners jurisdiction by jurisdiction, so a corridor is genuinely usable end-to-end rather than only settleable on-chain.

* A licensed on/off-ramp partner is signed in each market at least 3 months before that corridor goes live, with integration completed and tested by launch. Additional partners are added within 3 - 6 months of launch to avoid single-provider dependency, and coverage in the next target jurisdiction begins within 3 months ahead of its own corridor date.

Every corridor Kii operates runs on local, licensed, regulated providers in that market rather than a single offshore intermediary. That's what lets each corridor settle end to end and stay compliant jurisdiction by jurisdiction. Specific partner names are confidential, but the profile of each is below\.Current partners include:

* \[Live] COP (Colombia): a licensed bank regulated and supervised by the national financial superintendent (Superintendencia Financiera), plus two local liquidity partners aiding in FX and disbursements.
* \[Live] BRL (Brazil): two licensed, regulated entities covering FX and payments.
* \[Live] MXN (Mexico): two licensed, regulated entities covering FX and payments.

Target markets, partnerships already secured:

* \[Signed] USD (United States): an MTL- and MSB-licensed entity (money transmitter and money services business) providing both virtual bank accounts and payments.
* \[Signed] ARS (Argentina): a licensed payment provider covering FX payments and virtual accounts.
* \[Under assessment] JPY (Japan), and EUR/GBP (Europe): local licensed and regulated providers currently being onboarded, to be confirmed.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FdCRciZp6WhZ24SHlZ8H3%2FHP7LVTMWsAA6BMF.jpeg?alt=media&amp;token=25b2f79a-65cd-4e33-8b93-32006a1b5fec" alt=""><figcaption></figcaption></figure>

Expanding the protocol railsAlongside currency reach, the network extends the protocols it natively supports, because the more chains and contract environments KiiChain speaks, the more liquidity and more builders it can bring onto its FX layer:Advanced on-chain FX swap page. Today's swap page works network by network: you pick a chain, then swap assets on it. The advanced page flips that around and puts the currency first. You choose the fiat pair you want, say COP to BRL or USD to MXN, enter an amount, and Kii handles the routing, network, and settlement underneath. It makes on-chain FX feel like a normal currency exchange: pick two currencies, see the rate, swap.

* \[Live]: Simple swap page for swapping assets on a selected network.
* \[Committed – Sep 2026]:Advanced fiat-pair swap page for direct on-chain FX

Full Tron protocol support. Tron carries one of the largest share of USDT in circulation and is the dominant dollar rail across emerging markets, where TRC-20 USDT is what people and businesses actually hold and move. Full Tron support connects that liquidity base directly into KiiChain’s FX layer, and will allow for cross-chain DEX swaps, FX swaps and more. The single biggest pool of the exact asset the network is built to route, turning the largest emerging-market dollar network into a first-class on-ramp for Kii FX corridors.

* \[Live] Deposits and withdrawals for OTC swaps.
* \[Committed – Sep 2026] Swap and bridge USDT TRC-20 integration on Kii with Tron-sourced USDT routable into every live FX corridor from day one.

CosmWasm protocol. Full CosmWasm support brings a mature, Rust-based smart-contract environment alongside the existing EVM layer. The RWA protocol already uses CosmWasm; extending it network-wide gives builders a second, high-assurance contract surface for vaults, compliance logic, and structured products, and lets KiiChain draw on the wider Cosmos developer base without giving up EVM compatibility. This also enables the support of other CosmWasm based networks.

* \[Committed – Oct 2026] Network-wide CosmWasm enablement on testnet with developer documentation updated for CosmWasm interoperability tooling released alongside.

Multistep pay provider. Today KiiChain Pay unifies on-ramp, off-ramp, FX swap, and DEX swap as routes; the multistep pay provider chains them into a single orchestrated payment. One instruction can move funds through several legs. For example, on-ramp in one currency, an FX swap, and off-ramp in another, settling atomically end-to-end so a payer states intent (“pay this beneficiary this amount in their currency”) and the network routes every intermediate step. This is what turns the settlement layer into a true payments product for businesses that don’t want to manage the individual hops.

* \[Committed – Oct 2026] Two-leg orchestration live, with full multi-leg settlement with automatic route selection deployed to only support networks and territories. The functions will be API available.


# Part II: Pillar 2

### Pillar 2: Yield vaults

**Problem**. A balance sitting still in an emerging market is a balance losing ground. The alternatives are a local bank account with poor rates, or dollar yield that is out of reach for most businesses and people there.

**Kii’s insight.** The money is already on Kii. Yield should be a property of that balance, not a separate product a user has to leave the network to find.

**Product**. Two vaults over assets Kii already handles: liquidity vaults routed into established on-chain lending and yield protocols, and FX and government-bond vaults holding tokenized sovereign debt.

**Value proposition.** The same balance used for FX and payments can be put to work while it waits, without leaving Kii and without giving up custody. Returns are variable and not guaranteed.

* Yield in local currency, not just dollars. A user can hold, and seek yield in, the currency they actually spend.
* Sequenced to live corridors: bond vaults follow the currencies Kii already settles, so yield lands where the payments already are.
* Non-custodial and compliant: deposits stay the user’s, and issuance runs inside the RWA protocol’s compliance rails.

**Availability**. Vaults are available only where permitted by law, and eligibility is checked before access. Any rate shown in this document is indicative and variable, not a quoted or guaranteed return.

**Liquidity yield vaults**

These vaults let anyone holding stablecoins on Kii, global (USDT, USDC) or local, put idle balances to work and earn yield without giving up custody of their funds. They run on non-custodial yield infrastructure: your deposit stays yours while it's routed into curated, risk-tiered strategies across established on-chain lending and yield protocols. Potential venues include leading lending markets such as Aave and Morpho, and yield protocols such as Pendle and Maple. APY can range from 2% to 6% on most vaults, and can change depending on a multitude of market factors. You pick the profile that fits you, from conservative to higher-yield, and you can see exactly where the return is coming from. It's all on-chain and transparent, with the risk of each strategy spelled out rather than buried.

* \[Committed – Oct 2026] First vaults live on USDT/USDC and the initial local-currency pairs, with a curated set of risk profiles at launch. More strategies, more supported assets, and full on-chain reporting of yield sources, utilization, and risk follow as the product matures.

FX and Government-bond (RWA) yield vaultsThe second type holds tokenized government bonds, starting with short-duration US Treasury exposure and extendable to local sovereign instruments, and passes the underlying yield through to depositors on-chain. This gives an emerging-market user or business a way to hold a dollar-denominated, yield-bearing, sovereign-backed asset directly from a stablecoin balance. Issuance stays within the RWA protocol's compliance rails (identity, eligibility, licensed issuance), so the product is institutional-grade rather than synthetic. The standout for emerging markets is the FX side: local-currency vaults let users hold a native fiat stablecoin and local Treasury exposure to earn yield in that same currency, typically anywhere from 6% to 14% APY. Current examples include a Colombian peso yield \~9%, a Brazilian real vault at roughly \~11%, and a Mexican peso vault at roughly \~5%, with rates varying by currency and market demand and always indicative rather than guaranteed. For a business or person in an emerging market, this turns a stablecoin balance into a productive account: the same funds you use for FX and payments on Kii can earn a competitive local-currency yield in between transactions.Note on rates. Rates referenced above are indicative and historical, vary with market conditions, and are neither quoted nor guaranteed. Vaults are not offered in jurisdictions where they are not permitted.

* \[Committed – Oct 2026] Licensed issuer agreements implemented by August 31st, 2026, with short-duration Treasury vaults live by October, 2026.

Why both. The two vault types serve two different demands from the same balance: FX vaults monetize network activity (variable yield, tied to volume), while bond vaults deliver reference-rate yield (steadier, tied to sovereign rates). Offering both lets a treasury split idle balances between “earn from the network” and “park in sovereign-backed yield” without leaving Kii.<br>

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FZxYZAtNmtRw6V7iToRdy%2FHP7Lc_BWwAAdOgr.jpeg?alt=media&amp;token=1182e8a9-d4ff-4f8e-a31d-11a545e5086c" alt=""><figcaption></figcaption></figure>


# Part II: Pillar 3

### **Pillar 3: On-Chain Financial Services**

**Problem**. In emerging markets, the hard part is not spending dollars. It is receiving and holding them.\
\
**Kii’s insight.** Bankable US account details on top of an on-chain balance solve the receiving problem; the rest of the stack already solves what happens next.\
\
**Product.** US virtual accounts first, then everyday financial tools built on the same balance.\
\
**Advantage.** Dollars arrive on rails counterparties already use and land on-chain, where they can be swapped into local currency (Pillar 1) or put to work (Pillar 2) immediately. Accounts are issued through regulated partners and it lets a user in supported territory receive and hold dollar.

The third pillar addresses the demand underneath everything else in emerging markets: access to a wider range of financial services. A US virtual account gives a KiiChain user their own US account details (an account and routing number) capable of receiving USD via standard rails (ACH/wire), with incoming dollars settling into their on-chain balance as stablecoins.How it fits the stack. Virtual accounts sit on top of KiiChain Pay’s existing on/off-ramp architecture and its licensed-operator model.

The account is issued through regulated banking partners; the on-chain leg is native KiiChain. This is a deliberately partnership-and-compliance-heavy product; it lives or dies on the banking relationships and KYC/AML program behind it, and is sequenced accordingly.

* \[Committed – Nov 2026] US Virtual accounts

Beyond virtual accounts, Pillar 3 puts everyday financial tools on top of the same on-chain balance, so the money a user holds on Kii can be spent, and eventually borrowed against, without leaving the network.The following are exploratory concepts under evaluation. They are not committed products, carry no delivery date, and will proceed only where the necessary licences, card-scheme approvals, and lending authorisations are obtained, directly or through licensed partners.

* \[Exploratory] Debit cards. On-chain stablecoin debit cards that spend straight from a user's Kii balance. There's no separate bank account or top-up in the middle: the card draws directly on the stablecoins the user already holds and works anywhere cards are accepted. It's the simplest bridge between an on-chain dollar and real life, whether that's buying groceries, paying a supplier, or pulling out cash.
* \[Exploratory] Credit cards. A collateral-free line of credit built for micro-lending, aimed straight at the credit gap that defines emerging markets. In most of these economies, the missing piece isn't payments; it's credit. Around 40% of formal small businesses in developing countries have financing needs that go unmet, a shortfall the IFC estimates at roughly $5.2 trillion, and well over a billion adults have no formal credit history at all. Without a score, a small loan to cover a slow month or buy inventory is simply out of reach, and people get pushed toward informal lenders at punishing rates.

Kii can close part of that gap using data the network already holds. Because a user's dollars arrive through their virtual account, move through FX, sit in vaults, and get repaid over time, Kii can build a genuine on-chain picture of how someone actually manages money and extend small, collateral-free lines of credit based on that behavior rather than a bureau score they'll never have. In practice, that's real microfinance: modest, unsecured credit that helps a family smooth a rough month or a small business buy stock or handle an emergency, repaid from the same inflows the network can already see. And because it needs no collateral, it reaches exactly the people traditional lending leaves out.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FfylWqiNDrZ2GOCY0U1uG%2FHP7Lkw1WkAEXZNi.jpeg?alt=media&amp;token=432bd4c1-05f0-4d3a-9ff7-3ad13a0ad0da" alt=""><figcaption></figcaption></figure>

### Regulatory status and jurisdictional availability

This document is distributed internationally and is intended to be read alongside the notice above.

* Nothing in this document is an offer to sell, a solicitation of an offer to buy, or an investment recommendation in any jurisdiction, including the Republic of Korea.
* Nothing here is a promise or indication of profit, return, or price appreciation of any digital asset, including KII.
* The listing or trading of KII on any exchange does not constitute approval, endorsement, or verification by any regulator or exchange. Listing decisions rest with the venues concerned.
* Products described are offered by KiiChain only where permitted, and where a licence is required they are provided by licensed third parties. Where local licensing is absent, the product is not offered in that jurisdiction.
* Statements about future corridors, dates, partnerships and authorisations are forward-looking. They reflect current intention, not commitment, and actual outcomes may differ.
* Traction figures, volumes, user counts and contracted pipeline are stated as at the date of this document and are unaudited unless otherwise noted.
* Marketing and distribution are subject to local law in each market. This document should be reviewed by local counsel before use in any specific jurisdiction.
* On/off-ramp and liquidity services are available only where permitted by applicable law and, where required, are delivered through licensed issuers and distributors. Availability differs by jurisdiction, and jurisdictions without local licensing are excluded.
* Yield vaults are non-custodial software interfaces to third-party protocols. They are not deposits, savings accounts or investment products, are not offered, guaranteed or insured by any bank or deposit-protection scheme, and no return is promised or fixed. Returns are variable, may be zero or negative, and principal may be lost.
* Tokenized government bonds are securities, issued solely by licensed third-party issuers under applicable securities law. KiiChain provides technical infrastructure only and does not issue, underwrite, distribute, custody or advise on these instruments. Access is restricted to eligible investors in permitted jurisdictions.
* Virtual accounts are issued and operated by licensed third-party banking and money-transmission partners. KiiChain is not a bank, deposit-taking institution or money transmitter and does not hold customer fiat. Balances are not insured by any deposit-protection scheme.


# Whitepaper

The latest version of the KiiChain Whitepaper.

{% file src="/files/H01c5Bf4P0dyCnXtV4WZ" %}


# Tokenomics


# KiiChain Tokenomics

Sound Finance for the Onchain Economy

In an industry increasingly defined by short-term incentives, aggressive unlocks, and misaligned capital structures, KiiChain’s tokenomics are designed around a different philosophy. Its tokenomics are not engineered to maximize early speculation or short-term price action, but to support long-term economic activity, real usage, and durable network effects.

The model combines traditional financial principles, discipline, alignment, and capital efficiency, with the transparency, programmability, and community participation enabled by Web3.

### A Foundation Built on Discipline, Not Hype <a href="#d0a2" id="d0a2"></a>

Many token economies struggle with the same structural challenges: excessive investor concentration, aggressive emissions, limited utility, and incentives that prioritize short-term activity over sustainable network growth. KiiChain takes a different approach.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FyfKxMPXXZOMGFuay4VjF%2FCommunity.webp?alt=media&amp;token=3a4b1003-6096-485f-b520-d761b6383e8e" alt=""><figcaption></figcaption></figure>

Its tokenomics are designed around four principles:

* **Long-term alignment:** Extended vesting schedules across key allocations.
* **Community participation:** More than 72% is allocated across Community and Foundation initiatives supporting ecosystem growth.
* **Real utility:** KII is designed to support activity across KiiChain’s financial infrastructure.

The objective is straightforward: allow network participation and real usage to grow alongside token distribution.

### Breaking Down the Allocations <a href="#id-7015" id="id-7015"></a>

KiiChain has a fixed maximum supply of 1,800,000,000 KII tokens.

Press enter or click to view image in full size

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2F7yuEXyk31vCmznIdrrLy%2Ftokenomics.webp?alt=media&amp;token=fdeb5d71-17bb-4fdd-8446-b81b52cd9102" alt=""><figcaption></figcaption></figure>

\
Investors — 14.15%

Investors who backed KII in private rounds hold 14.15% of total supply (254,700,000 KII). We made a deliberate choice to keep every one of these tokens locked at TGE.

Investor allocations sit behind a twelve-month cliff, then unlock across the next 24 months. The structure rewards early conviction and ties outside capital to the long horizon that building an open intelligence ecosystem demands.

#### Kii Global — 12.167% <a href="#a432" id="a432"></a>

A total of **219,000,000 KII** is allocated across the contributors responsible for building and supporting KiiChain:

* **Team:** 171,000,000 KII — 9.500%
* **Contractors:** 12,000,000 KII — 0.667%
* **Advisors:** 36,000,000 KII — 2.000%

The team allocation carries a **2-year cliff followed by a 2-year vesting period**, creating long-term alignment between the people building the infrastructure and the ecosystem they are building for. **Contractors and advisors follow a 1-year cliff followed by a 2-year vesting period**, further reinforcing long-term commitment and alignment across key contributors.

#### Community & Ecosystem — 73.68% <a href="#id-9d3f" id="id-9d3f"></a>

A total of 1,326,300,000 **KII (73.68%)** is allocated to Community and Foundation initiatives, representing the largest share of the KII supply. This allocation is designed to **support network participation, ecosystem growth, liquidity, and the long-term development and sustainability of KiiChain.**

The allocation is distributed across four key areas:

* **Airdrops:** 126,000,000 KII (7.000%)
* **Public sale:** 13,242,857 KII (0.736%)
* **Ecosystem & RnD:** 279,057,143 KII (15.503%)
* **Community Incentives & Validator Rewards:** 908,000,000 KII (50.444%)

Community and Ecosystem allocation follow a long-term activity-driven distribution model. Tokens are progressively deployed as the ecosystem grows, based on network participation, community program, liquidity needs, grants and strategic ecosystem development

* Airdrop

A total of 7% of the token supply is allocated to the airdrop. Of this, 30% unlocks at TGE. The remaining supply is released monthly over the following 12 months.

* Public Sale

A total of 0.736% of the token supply is allocated to the public sale. This bucket covers tokens allocated to community members who participated in the Sonar public sale. 0.275% of token supply is unlocked at TGE. The remainder unlocks over the following 24 months, according to the vesting schedule selected by the user.

* Ecosystem and R\&D

The Ecosystem and R\&D bucket contains tokens allocated towards foundation operations, business development, liquidity, and partnerships. It also includes the liquidity tokens provided to market makers for maintaining liquidity across centralized and decentralized exchanges.

A total of 15.5% of the token supply is allocated to this bucket. Of this, 5% is unlocked at TGE. The remainder is subject to a 12-month cliff, after which it unlocks linearly over the following 60 months.

* Community Incentives and Validator Emissions

A total of 50.444% of the token supply is allocated to this bucket. It funds community programs, grants, and ecosystem incentives, as well as delegator and validator rewards. It also includes the allocation provided to centralized exchanges for initial distribution to users.

Vesting for this bucket works as follows:

\- 10.08% of the token supply is unlocked at TGE.

\- Approximately 8.3 bips of the token supply is unlocked every month from TGE as validator emissions, continuing for 72 months.

\- An additional 2% of the token supply unlocks in month 2 within the community initiatives portion of the bucket.

\- A further 1% of the token supply unlocks in month 6.

\- The remainder is subject to a 12-month cliff and unlocks through to month 72.

Community & Foundation allocations follow a long-term, activity-driven distribution model rather than aggressive fixed unlocks. **Tokens are progressively deployed as the ecosystem grows,** based on network participation, community programs, liquidity needs, grants, and strategic ecosystem development.

These allocations are designed to enter circulation progressively over long-term distribution programs extending for up to 10 years, helping align token circulation with real network growth and demand.

### The KII Token: Utility at the Core <a href="#af54" id="af54"></a>

KII is the utility token powering participation across KiiChain’s financial infrastructure. Its utility is centered on network usage and active ecosystem participation rather than mechanisms that reward passive ownership alone.

KII supports core functions across the network, including:

* **Transaction fees:** KII is the native token used to pay transaction fees across KiiChain.
* **Network security:** Validators and delegators use KII to participate in staking and secure the network.
* **Governance:** KII supports participation in protocol-level governance and network decisions.
* **Ecosystem incentives:** Eligible active users may participate in usage-based incentive mechanisms designed to support trading activity, network participation, liquidity, and ecosystem growth.
* **veKII:** Eligible active ecosystem participants may access veKII through supported ecosystem activity and voluntary KII locking, enabling participation in supported functions such as governance, fee discounts, and additional governance-controlled utility features.

### Rewards Built Around Participation <a href="#id-8e66" id="id-8e66"></a>

KiiChain’s rewards infrastructure is designed around a simple principle: Real participation should drive ecosystem incentives. The Utility Rewards Module distributes staking rewards according to predefined onchain parameters from a finite, prefunded rewards pool. It does not mint additional KII as part of reward distributions.

KII Trading Rewards follows the same participation-first philosophy. The program is designed to incentivize eligible activity across KiiChain’s financial infrastructure rather than passive token ownership. Importantly, purchasing or holding KII does not automatically provide access to KII Trading Rewards, veKII, or yield. Participation in KII Trading Rewards is limited to eligible active app traders who satisfy the applicable participation requirements. Rewards are variable, are not guaranteed, and depend on user activity and applicable protocol parameters.

### Fixed Supply, Real Scarcity <a href="#id-8a47" id="id-8a47"></a>

KiiChain operates with a fixed total supply of 1.8 billion KII. There is no uncapped issuance mechanism, and staking rewards are not funded through perpetual token creation. Instead, rewards are distributed from the finite allocation established at genesis.

This creates a predictable supply framework in which ecosystem incentives can be distributed over time without introducing additional monetary inflation through the rewards mechanism. As KiiChain grows, the relationship between token distribution and ecosystem activity remains fundamental to the model: supply is designed to support participation as the network expands.

Scarcity without utility is speculation. KiiChain is building the utility first.

### Built for Real Financial Activity <a href="#id-5038" id="id-5038"></a>

KiiChain is purpose-built around financial infrastructure for emerging markets.

Its core focus includes:

* **Onchain foreign exchange**
* **Stablecoin liquidity**
* **Cross-border payments**
* **Real-world financial flows**
* **Financial infrastructure for businesses and users in emerging markets**

These markets face persistent challenges around fragmented FX liquidity, costly cross-border settlement, limited financial access, and dependence on intermediaries. At the same time, stablecoin adoption is creating new infrastructure for moving and settling value globally.

KiiChain is designed to connect these two realities. Its onchain FX infrastructure, stablecoin liquidity coordination, and cross-border settlement rails are built around real transaction activity rather than purely incentive-driven onchain metrics. That distinction matters for KII. The long-term role of the token is connected to participation in an ecosystem designed around actual financial activity: transactions, network security, governance, liquidity, and supported ecosystem incentives. KiiChain is building an always-on financial layer where FX, stablecoin settlement, and cross-border payments can operate beyond traditional market and banking hours.

### Long-Term Alignment by Design <a href="#dbcd" id="dbcd"></a>

KiiChain’s tokenomics are structured to align builders, users, validators, investors, and ecosystem participants across a multi-year horizon. For the team, this means long cliffs and extended vesting schedules rather than short-term liquidity. For investors, it means structured distribution rather than large early unlocks. For the community, it means the majority of the network’s supply is directed toward participation, rewards, ecosystem development, and long-term growth through the Community and Foundation allocations.

And for KII itself, it means utility is designed around participation in the network rather than passive ownership. This alignment is intentional. KiiChain is being built as long-term financial infrastructure, and its token economy is designed around the same horizon.

### One Network, One Community <a href="#a78d" id="a78d"></a>

KiiChain is a collective effort across builders, users, validators, stakers, holders, developers, and contributors. The tokenomics reflect that structure. With a fixed 1.8 billion KII supply, more than 72% allocated across Community and Foundation initiatives, structured long-term allocations for builders and investors, and utility connected to real network participation, KII is designed to grow alongside the ecosystem it powers.

The principle behind the model is simple: the strongest networks are built when incentives are aligned, supply is disciplined, and real economic activity drives participation. KiiChain’s tokenomics are not designed around a single launch event. They are designed for the network that comes after it.


# Utility

KII's value is derived from its utility rather than a speculative investment. Here are the utility use cases for KII, outlining its value in the real-world and to the network.

KII is the native gas and utility token of KiiChain, a sovereign proof of stake Layer 1. Total supply is fixed at 1,800,000,000 KII. The minting function is disabled at protocol level and cannot be changed by governance, so no further tokens can be created.

Gas, staking and governance are protocol level functions, available to holders in any jurisdiction, and do not require interaction with any KiiGlobal operated service.

1. Gas\
   All network transactions, including transfers, account creation and contract\
   deployment, are paid in KII. Fees accrue to validators. Gas use is\
   permissionless.
2. Staking\
   KII is the only asset eligible for validator bonding and delegation, securing network consensus. Validators, and delegators bonded to them, are paid a validation fee for the consensus service performed. Fees are assessed at protocol level and disbursed automatically by consensus, in proportion to bonded stake.\
   \
   Validation fees are paid from two sources: transaction fees borne by users submitting transactions; and a pre-allocated on-chain fee pool, which is finite, was fully allocated at genesis, and depletes according to a public schedule after which validation fees derive from transaction fees alone. Distribution from both sources is automatic and determined by consensus rules. Neither source involves new issuance. Validation fees are not funded by and do not depend on the revenue, profits or discretionary decisions of KiiGlobal S.A.S. or any affiliate. The fee is consideration for work performed, not a return on capital, and no rate of return is promised or projected.\
   \
   Bonding carries risk of loss through slashing, and an unbonding period during which bonded KII cannot be transferred.
3. Governance\
   KII is the voting asset for on chain protocol governance, which is live from genesis. Governance covers technical protocol matters: network parameters, validator set size, and protocol upgrades. It confers no shareholder, membership or management right in any company and no right to direct the business of any company.
4. Protocol Usage Fees\
   Applications using the KiiChain RWA protocol pay usage fees in KII. The protocol\
   is permissioned software, available only through issuers and distributors authorized in their own jurisdictions, and is geo restricted.\
   \
   KII confers no interest in, claim on or economic exposure to any asset tokenized through the protocol, and holders receive no share of protocol revenue.
5. Ecosystem Incentives\
   KII may be allocated from pre allocated reserves as development grants to third party developers and infrastructure operators building on KiiChain. Grants are discretionary and are not available to holders by virtue of holding KII. They are not a deposit, a yield product or a promised return.
6. Affiliated Application Discount.\
   Holders receive a flat service fee discount on the KiiChain App, operated by KiiGlobal S.A.S. (Colombia). The discount is the same for every eligible holder and does not increase with the amount held. It is a commercial promotion, not a distribution of revenue or profit, and may be modified or withdrawn at any time. The App is available only in jurisdictions where its operation is legally permitted. KII's function as a network asset does not depend on it.
7. Rights not Conferred\
   KII carries no dividend, profit sharing, interest, redemption, buy back or repurchase rights; no claim on the revenue, profits or assets of KiiGlobal S.A.S. or any affiliate; no equity or debt interest; and no contractual right to share in the profits or losses of any common enterprise. No token burn or buy back is funded from the revenue or profits of KiiGlobal S.A.S. or any affiliate.

Disclosure\
KiiGlobal will publicly disclose in advance any change to the utilities described here that could materially affect the value of KII.


# Evergreen Model

The evergreen model has been discontinued indefinitely.


# Getting Started

An introduction and important links.

KiiChain is the onchain FX layer that connects global stablecoin liquidity with local-currency markets. This section covers wallets, bridging KII, and where to start on mainnet or testnet.

### Networks

* **Mainnet** — production network for Kiichain (`kiichain_1783-1`). Details: [Kiichain Mainnet](https://docs.kiiglobal.io/docs/build-on-kiichain/kiichain-mainnet)
* **Testnet Oro** — permanent public testnet for builds, hackathons, and testing. Join activities at [kiichain.io/testnet](https://kiichain.io/testnet)

### Bridge KII

Move KII between Kiichain and supported chains (BSC, Polygon, Base, Ethereum, Mantle) with Hyperlane. Addresses and Nexus instructions:

* [Bridge](https://docs.kiiglobal.io/docs/learn/getting-started/bridge)

### Get a wallet

Kiichain supports wallet connections with EVM and Cosmos based wallets like MetaMask and Keplr. To set up a wallet, make sure you have the MetaMask or Keplr wallet extension downloaded in your web browser. MetaMask supports extension downloads for the following web browsers: Chrome, Firefox, Brave, Edge and Opera. Keplr supports wallets in Chrome, Firefox and Edge.

For further explanation of how to set up your wallet, follow the steps [here](https://docs.kiiglobal.io/docs/learn/getting-started/set-up-a-web-wallet) or connect your wallet to our explorer app automatically by following the steps [here](https://docs.kiiglobal.io/docs/learn/getting-started/connect-wallet-to-explorer-app).

### Get Testnet tokens

Testnet Oro tokens are available in our [Discord faucet](https://discord.com/invite/kiichain) or in the Explorer App. Once you have created a wallet, you can automatically request and receive 2,500 tokens within a 24 hour period. For any developers who would like more tokens, please request a bulk amount in our Discord channels.

The command for requesting tokens in our Discord faucet channel is:

```
$request {address}
```

Example EVM:

```
$request 0x12345abcde…
```

Example Cosmos Address:

```
$request kii12345abcde…
```

**The full list of commands are:**

List commands:

```
$help
```

Request tokens:

```
$request [kii address]
```

Query an address balance:

```
$balance [kii address]
```

Query a transaction:

```
$tx_info [transaction hash ID]
```

Query the faucet and node status:

```
$faucet_status
```

Query the faucet address:

```
$faucet_address
```

### How to stake your tokens

Tokens can be staked in the Explorer App by connecting your wallet and delegating to an active validator. Make sure the wallet you have connected to the Explorer App is funded with tokens.

### Connect wallet to Explorer App

The Explorer App can be automatically connected to MetaMask or Keplr via the RPC endpoints. Once you have installed the MetaMask extension, follow the steps [here](https://docs.kiiglobal.io/docs/learn/getting-started/connect-wallet-to-explorer-app) to connect your wallet and begin delegating.

### Developer resources

If you’re a developer and are interested in building with KiiChain, a good place to start is reviewing the introduction information [here](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-hub).

Quick start links:

* [Launch a node/full node/validator](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/getting-started)
* [Kiichain Mainnet](https://docs.kiiglobal.io/docs/build-on-kiichain/kiichain-mainnet)
* [Blockchain endpoints](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-hub)
* [Deploy a smart contract](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/deploy-a-smart-contract)
* [dApp development](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/deploy-a-dapp)
* [Testnet faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
* [Bridge](https://docs.kiiglobal.io/docs/learn/getting-started/bridge)

### Chat with us on Discord

We’re active on our Discord. Whether you have questions regarding a hackathon or airdrop competition, or simply would just like to chat and build with us, join our discord [here](https://discord.com/invite/kiichain).

General customer service and developer support are available in our channel. Get to know us.

You can find us on Discord:

* [Invitation link](https://discord.com/invite/kiichain)

### How to earn airdrops and rewards

We’re constantly running localized airdrops, hackathons, and competitions in our community.

Follow our X account and stay up to date with all announcements. For additional communities, visit our communities at Galxe, Zealy, TaskOn, and QuestN.

* [X Link](https://x.com/KiiChainio)


# Get a Wallet

Get a wallet for KiiChain Testnet Oro

### **Explorer App (best option for builders)**

Connect your Keplr or MetaMask wallet to the explorer app to stake KII into a validator or to help launch a full node/validator.

### **Web Wallets**

Connect to our web wallet using Keplr or Metamask.


# Download a Mobile Wallet

Available on the App Store and Google Play

### **Download Kii Mobile on the App Store or Google Play**

Mobile wallets are currently in deployment mode for Testnet Oro, and available on the App Store and Google Play for users who would like to have access to the basic functions of the chain. Within the mobile wallet, users can login via email or manage their 24‑word seed phrase.

Apple Store: <https://apps.apple.com/us/app/kii-mobile/id6474740411>

Google Play: <https://play.google.com/store/apps/details?id=com.kiimobile>

In the wallet, users can send, receive, and stake their KII by selecting the validator they would like to use to perform all functions. These wallets are currently connected in Testnet and can be used for all developers, hackathons, and competitions.

Mobile wallets will be compatible with Testnet V1 and Testnet Oro.


# Set Up a Web Wallet

Set up a wallet using MetaMask or Keplr with a web wallet for Testnet Oro. Its important to use a wallet compatible to your browser.

## Step 1: Install MetaMask Extension

Go to Metamask.io and download and install the web extension browser. Make sure the web extension is from [MetaMask](https://chromewebstore.google.com/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn?pli=1).

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FpmdOenvqeW0wa3esSPZT%2FScreen%20Shot%202024-06-11%20at%206.23.06%20PM.png?alt=media&amp;token=833fb73f-57f1-4fd9-8a3c-feb22d889100" alt="" width="563"><figcaption></figcaption></figure>

## Step 2: Create your wallet

Once the download has been completed, a prompt will appear, click "Create a new wallet" to begin.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fg9FVxug4ESPmqjAE8ZgE%2FScreen%20Shot%202024-06-11%20at%206.25.21%20PM.png?alt=media&amp;token=b765156e-a754-4b3c-970c-ac5f9abb237b" alt="" width="480"><figcaption></figcaption></figure>

Create a password that will control access to your account via the extension.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FXB2fMiIQaXqxQSBpyekc%2FScreen%20Shot%202024-06-11%20at%206.26.26%20PM.png?alt=media&amp;token=92dae64f-3a18-440d-931b-d2ece4a5970b" alt="" width="491"><figcaption></figcaption></figure>

Create, record, and properly store your wallet secret phrase. This step is very important as these 12 words are your secret keys to your wallet.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FsPhy2PQD3BZuzNMFUjMD%2FScreen%20Shot%202024-06-11%20at%206.26.55%20PM.png?alt=media&amp;token=3a0c5633-ff14-4d3b-8e9b-70f224405700" alt="" width="399"><figcaption></figcaption></figure>

Awesome, nice work! Your wallet has been created. Make sure you store your keys in a safe place!

## Step 3: Link your wallet to the KiiChain Testnet.

Wallets like MetaMask and Keplr can be manually connected to various testnets. MetaMask supports EVM-compatible blockchains, and at default, is set to the Ethereum network. You will need to manually connect to the KiiChain network.

The link can be done through multiple sources:

* [Kiichain Testnet Page](https://kiichain.io/testnet)
* [Explorer App](https://explorer.kiichain.io/testnet)
* [Chain lists](https://chainlist.org/chain/1336)

### Manually setting the wallet

Click the "Ethereum Mainnet" dropdown bar on the top left and then click "Add Network" on the pop-up box.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FfXHHZhflhLyPdP0kTNqa%2FScreen%20Shot%202024-06-11%20at%206.28.26%20PM.png?alt=media&amp;token=9b288a8f-66b4-4754-a2bc-e4b233545ffa" alt="" width="563"><figcaption></figcaption></figure>

Manually add the following testnet chain ID to add the network.

| Subject            | Value to Insert                                            |
| ------------------ | ---------------------------------------------------------- |
| Network name       | Kiichain Testnet Oro                                       |
| New RPC URL        | <https://json-rpc.dos.sentry.testnet.v3.kiivalidator.com/> |
| Chain ID           | 1336                                                       |
| Currency symbol    | KII                                                        |
| Block explorer URL | <https://explorer.kiichain.io/testnet>                     |

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fqo09suYcJgCcOh911sig%2FScreen%20Shot%202024-06-12%20at%2011.50.44%20AM.png?alt=media&amp;token=6750d6d8-2772-48af-ad42-d658ce50e9cf" alt="" width="563"><figcaption></figcaption></figure>

Upon saving and completion, you should be connected to the testnet network!

Now, get some testnet tokens by following the instructions: [Testnet Tokens](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/testnet-faucet).


# Set Up KiiChain on Bybit Extension

Set up KiiChain on your ByBit Extension

### Requirements

This guide assumes that you have installed the Bybit Wallet Extension and have your wallet already set up.

### Step 1: Adding a new network

To add KiiChain to Bybit, you first need to add a custom network. To add it, you can:

1. On your extension, open the network selector in the top right corner

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FI37U8jUXGWWFcUokUZY3%2Fimage.png?alt=media&amp;token=eba0b913-249d-4cbb-b4f5-24bb2adbeffc" alt=""><figcaption></figcaption></figure>

2. Go to `Add a custom network`

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FRVNoWnakGSxw7ZVGqP3E%2Fimage.png?alt=media&amp;token=d3bce66e-a2c8-432a-a724-f76170fe7ffc" alt=""><figcaption></figcaption></figure>

3. Go to `Add Manually`

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FC6kiLFszmrEVr6KqyRAT%2Fimage.png?alt=media&amp;token=d4f7fdf3-13c1-49c8-9338-0a5844a2c524" alt=""><figcaption></figcaption></figure>

4. Fill in the KiiChain information

The information can be found here:

* RPC URL: `https://json-rpc.kiivalidator.com`
* Network Name: `KiiChain`
* Chain ID: `1783`
* Native Token: `KII`
* Blockchain Explorer: `https://blockscout.kiichain.io`

After you can click on `Add Now`.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FC7L6mTiFbXoeic989pv1%2Fimage.png?alt=media&amp;token=cb507eb7-4b5e-4d3b-9c13-b47bb150d9eb" alt=""><figcaption></figcaption></figure>

### Step 2: Verify if KiiChain was created

Once you complete Step 1, you should be able to see $KII in your wallet:

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FuaAB3GvZrXrKw0d1Sau4%2Fimage.png?alt=media&amp;token=521416be-a110-4ee6-8397-08ae0a775445" alt=""><figcaption></figcaption></figure>

If you don't see it, make sure that you are connected to the correct network:

1. Click on networks

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FjCWtHBK9zWGZFdRNYsRk%2Fimage.png?alt=media&amp;token=0c7bdeef-1483-46a6-b664-2f9a73f58ed9" alt=""><figcaption></figcaption></figure>

2. Select KiiChain under Customized

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FpzaXuhqtpq970iXuDazj%2Fimage.png?alt=media&amp;token=2e0dc418-e145-4b70-81a3-6a132efb1019" alt=""><figcaption></figcaption></figure>


# Connect Wallet to Explorer App

Connect your wallet to the KII interactive explorer and start staking.

### Step 1: Make sure you have installed the MetaMask or Keplr browser extension.

Go to Metamask.io and download and install the web extension browser. Make sure the web extension is from [MetaMask](https://chromewebstore.google.com/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn?pli=1) or [Keplr](https://www.keplr.app/). During testnet, if you do not have MetaMask installed first, you will receive this error.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FDcMMLix85lNp93iemroc%2FScreen%20Shot%202024-06-13%20at%203.05.16%20PM.png?alt=media&amp;token=954eacdf-9d79-4c55-aff4-304b3af16c3f" alt="" width="375"><figcaption></figcaption></figure>

### Step 2: Launch the Explorer App and Connect your Wallet to Testnet Oro.

Go to [https://explorer.kiichain.io](https://app.kiiglobal.io/) and make sure you are connected to the "Testnet Oro" network by selecting the dropdown in the top right.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FR7RsqhiugSy5eJkv15Np%2FScreenshot%202025-01-06%20at%201.07.24%E2%80%AFPM.png?alt=media&amp;token=a2d46876-13d9-4c98-8c50-98fcbca04be6" alt="" width="365"><figcaption></figcaption></figure>

For setting up a web wallet, see "[Set Up a Web Wallet](https://docs.kiiglobal.io/docs/getting-started/set-up-a-web-wallet)". Once your wallet has been created, you can link it to the explorer app by clicking the wallet icon in the top right corner.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FSPIqs0LBbRgpq8g29YAV%2FScreenshot%202025-01-06%20at%201.08.35%E2%80%AFPM.png?alt=media&amp;token=2d4c5078-a1e9-4b6d-ab13-a0962f30a324" alt="" width="423"><figcaption></figcaption></figure>

If you have the MetaMask extension installed in your web browser, it should automatically connect the RPC endpoints.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FuWOOon7KVgugP2whzN60%2FScreen%20Shot%202024-06-12%20at%203.17.24%20PM.png?alt=media&amp;token=101a1ce4-515b-4e54-8c02-7a64ed42f2cd" alt="" width="363"><figcaption></figcaption></figure>

It will then ask for approval to switch the network from Ethereum (default) to Kiichain Testnet. Click the "Switch Network" button.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fk66WrwIhvoUZNl9RCLfq%2FScreen%20Shot%202024-06-12%20at%203.18.11%20PM.png?alt=media&amp;token=f1ba7d41-924c-435f-9656-466d0ae003a4" alt="" width="345"><figcaption></figcaption></figure>

Following, it will ask to link with your new wallet address. Click "Next".

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FDcrmjgAPZBexHvzud0Qi%2FScreen%20Shot%202024-06-12%20at%203.18.19%20PM.png?alt=media&amp;token=0c2e3007-4be7-4e25-b074-74a8f757a54d" alt=""><figcaption></figcaption></figure>

Lastly, it will ask for wallet permissions. Click on "Confirm".

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FYemK30MtFVOrwfVXZNFD%2FScreen%20Shot%202024-06-12%20at%203.18.26%20PM.png?alt=media&amp;token=44325840-75e4-429c-9ae3-4b322017cb0c" alt=""><figcaption></figcaption></figure>

Awesome! Your wallet is now connected to the explorer app! Deposit testnet tokens in your address to delegate to the validator.

### Step 3: Get testnet tokens.

Testnet tokens can be found on the faucet page in the explorer or requested in the discord. For more information, see here: [Testnet Faucet Commands](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/testnet-faucet).


# Bridge

Bridge KII between Kiichain and other networks. Includes Hyperlane warp route addresses and Nexus as a bridging option.

KII can move between Kiichain and supported external chains through Hyperlane warp routes. Use the addresses below to verify you are interacting with the correct contracts, and use [Nexus](https://nexus.hyperlane.xyz/?origin=kiichain\&originToken=KII\&destination=bsc\&destinationToken=KII) as a UI option for bridging assets.

## Bridge with Nexus

[Nexus](https://nexus.hyperlane.xyz/?origin=kiichain\&originToken=KII\&destination=bsc\&destinationToken=KII) is a Hyperlane-powered bridge interface. You can bridge KII between Kiichain and connected chains such as BNB Smart Chain (BSC), Polygon, Base, Ethereum, and Mantle.

Always confirm the destination chain and token address before signing a transaction.

## KII addresses on other chains

Official Hyperlane warp route configuration (source of truth):

* [Hyperlane registry — KII / kiichain-config.yaml](https://github.com/hyperlane-xyz/hyperlane-registry/blob/main/deployments/warp_routes/KII/kiichain-config.yaml)

| Chain                 | Contract address                             | Type                        |
| --------------------- | -------------------------------------------- | --------------------------- |
| Kiichain              | `0xEEC6574eAbBa52bac3f0277F2cD5Ac7e67197886` | Native (EvmHypNative)       |
| BNB Smart Chain (BSC) | `0xEEC6574eAbBa52bac3f0277F2cD5Ac7e67197886` | Synthetic (EvmHypSynthetic) |
| Polygon               | `0xEEC6574eAbBa52bac3f0277F2cD5Ac7e67197886` | Synthetic (EvmHypSynthetic) |
| Ethereum              | `0xEEC6574eAbBa52bac3f0277F2cD5Ac7e67197886` | Synthetic (EvmHypSynthetic) |
| Mantle                | `0xEEC6574eAbBa52bac3f0277F2cD5Ac7e67197886` | Synthetic (EvmHypSynthetic) |
| Base                  | `0x3EBA6644819546C44Eb3e7c3A92f034f921dcA80` | Synthetic (EvmHypSynthetic) |

On Kiichain, the warp route represents native KII. On other chains, the listed address is the synthetic KII token contract for that network.

Decimals are `18` on all listed chains. Symbol: `KII`.

## Safety checklist

* Prefer the Hyperlane registry link above when confirming addresses.
* Base uses a different contract address than the other listed chains.
* Do not send KII to an unverified or manually pasted address from unofficial sources.
* If a UI and the registry disagree, trust the [Hyperlane registry config](https://github.com/hyperlane-xyz/hyperlane-registry/blob/main/deployments/warp_routes/KII/kiichain-config.yaml).


# Kii Ambassadors

Become a Kii Ambassador

### What does it mean to become a KiiAmbassador?

Welcome to the KiiAmbassadors Program, our exclusive initiative to spotlight and reward the most committed voices in the KiiChain community.

This is not just a title — it's a role of influence and responsibility, for those who believe in our vision and want to help us grow the project both on-chain and online.

*All information, tasks, and rewards are shared through the **Private Ambassadors Channel** on our official Discord*.

You can apply to join the Ambassadors Program through the official KiiChain Discord (Official Links Channel): <https://discord.gg/kiichain>

#### KiiAmbassadors are selected community members who:

* Amplify our core messages on Twitter and other platforms.
* Stay active and helpful in Discord.
* Help bring new users to the chain and nurture the community spirit.
* Represent the KiiChain brand publicly, respectfully and consistently.

### To be accepted into the program, you must:

* Have a good follower base and engagement level on social media.
* Follow KiiChain on X and be registered on the ORO Testnet.

### Your core responsibilities

**To maintain your role, we expect:**

* Engage weekly in the Kii Discord, especially in public channels.
* React, share, and comment on KiiChain’s official posts on X.
* Participate in the weekly tasks, shared in the Ambassadors Channel.
* Help grow the community by inviting new users or explaining Kii to newcomers.
* Suggest strong candidates who could join the program in the future.

### Participation perks

Ambassadors who complete tasks consistently and with high quality may receive:

* Rewards in $ORO and $KII.
* Monthly raffles for top ambassadors with USDT prizes.
* Shoutouts on our official socials and Discord.
* Access to exclusive giveaways.
* Special Q\&A sessions with the KiiChain Core Team.
* Early access to new features, tools, and campaigns.

### Points system and performance

To ensure fairness and reward real contribution, we have created a Points System to track all ambassador activities. Each action, such as retweeting, commenting, participating in Discord, creating original content, or attending events, will earn you points.

At the end of each month, top-performing ambassadors will be rewarded based on their accumulated points.

**Our mod team will also share a weekly form where you can submit proof of your participation and activities, ensuring your points are correctly assigned.**

In the table below, you can see how the points system is structured.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2F4zHLbVIsSTly3FnrYv4q%2FKIIAmbassadorPOINTS_Junio_2025%20(1).png?alt=media&amp;token=dae55c98-c84d-4d21-bb48-39bb5554d220" alt=""><figcaption></figcaption></figure>

### Rewards

#### Monthly Reward

* **2,000 USDT in Rewards for the Top Contributors of the Month.** Climb the leaderboard and secure your reward.
* Every active ambassador is eligible to receive $300 USD worth of $KII per month, subject to the following conditions:
  * Publish at least 1 original post per week (e.g., thread, infographic, video).
  * Engage (like, retweet, and comment) with every official Kii post shared in the ambassador group.
  * Be active in public Discord channels with at least 3 helpful messages per week.
  * Complete and submit weekly tasks through our tracking system

*Rewards are vested with a 3-month cliff followed by 18-month linear vesting, and are based on a $100M fully diluted valuation (FDV) for $KII.*

### Ambassador Incentives & Referral-Based Role System

The KiiAmbassadors program rewards not only consistency and engagement, but also your ability to grow the community by bringing in other qualified contributors.

We’ve created a referral-based role progression system, designed to reward ambassadors who actively expand the program with high-quality participants.

#### Role Progression Based on Referrals

For every 3 new KOLs (Key Opinion Leaders) you refer who are accepted into the program, your role is upgraded and you receive a bonus of $200 USD worth of $KII. This structure incentivizes high-quality referrals and gives ambassadors recognition as they grow the program. All bonuses follow the same vesting schedule as the base incentive (3-month cliff, 18-month linear vesting).

To remain active in the program, ambassadors are also required to publish at least 4 pieces of original content per month.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fk64kvvVP5rMOCxj4O50R%2FAmbassadorsRoleProgression_Kii_2025%20(2).jpg?alt=media&amp;token=ae553d71-bfdc-47e1-aba9-172184cf1185" alt=""><figcaption></figcaption></figure>

How to Qualify a Referral

To count as a valid referral:

* The referred KOL must follow KiiChain on X.
* They must join and be approved into the official Ambassador Discord server.
* The referral must be reported and verified by the Kii team.

### How to lose the role

We reserve the right to revoke the role if:

* You spread FUD or attack the KiiChain project or team.
* You share scam links or break Discord’s rules.
* You leak confidential information or early announcements.
* You remain inactive without justification for a prolonged period.
* You repeatedly ignore or skip assigned tasks.

### Evaluation process

Every 30 days, the KiiChain team will evaluate ambassador activity based on:

* Task completion
* Quality of participation
* Alignment with community values

Members who don’t meet the standards may be removed from the program to make room for new voices.

This program will evolve over time with new challenges, perks and surprises. Stay active, stay curious, and keep pushing KiiChain to new frontiers.


# Introduction

KiiChain Pay is non-custodial payments and FX infrastructure. Move money across on-chain and off-chain rails — FX, DEX swaps, on-ramps and off-ramps — through a single API.

**KiiChain Pay** (formerly KiiEx) is the payments and foreign-exchange layer of the Kii ecosystem. It lets you move value between **fiat and crypto**, run **FX** and **DEX** swaps, and operate **on-ramps** and **off-ramps** — mixing on-chain and off-chain operations behind one programmatic interface.

Every KYC-verified account gets its own embedded **crypto Kii Wallet** whose keys are held by our wallet provider and owned by the user, never by KiiChain Pay. To automate on-chain operations from a Kii Wallet, the user grants the platform an explicit **delegation** to sign on its behalf.

{% hint style="info" %}
The KiiChain Pay web app lives at <https://pay.kiichain.io>. This documentation is mainly aimed at API usage. You'll generate API keys, delegate your wallet, and drive FX, ramps and swaps from your own backend.
{% endhint %}

## Core concepts

<table><thead><tr><th width="220">Concept</th><th>What it means</th></tr></thead><tbody><tr><td><strong>Non-custodial by design</strong></td><td>Users transact from a non-custodial wallet — the embedded <strong>Kii Wallet</strong> (keys managed by Privy, owned by the user) or their <strong>own external wallet</strong>. KiiChain Pay never holds a private key.</td></tr><tr><td><strong>Internal wallets (Kii Wallet)</strong></td><td><strong>Optional.</strong> A convenience embedded wallet — one per account, per supported chain (EVM, Cosmos, Solana, Tron, Bitcoin), with sponsored gas and no key management. Users can bring their own external wallet instead; on-ramps, off-ramps and FX swaps work the same either way. Provisioned automatically once KYC is approved. See <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets">Internal wallets</a>.</td></tr><tr><td><strong>Delegated access</strong></td><td>A user delegates their Kii Wallet to the platform's signer so you can sign and broadcast transactions server-side — no per-transaction signing prompt. See <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access">Privy delegated access</a>.</td></tr><tr><td><strong>On-chain + off-chain</strong></td><td>Crypto balances live on-chain in the user's wallet (Kii or external); fiat and reserved balances are tracked in KiiChain Pay's internal double-entry ledger (<code>available</code> / <code>locked</code>).</td></tr><tr><td><strong>KYC-gated</strong></td><td>Kii Wallets, fiat rails, limits and provider access unlock through KYC. <strong>DEX swaps from an external wallet need no KYC.</strong> See <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc">KYC</a>.</td></tr><tr><td><strong>API keys</strong></td><td>Every authenticated API call carries an API key; write calls are additionally signed. See <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys">Generating API keys</a>.</td></tr><tr><td><strong>Permissionless DEX</strong></td><td>DEX swaps run on-chain directly from any external wallet — no account, KYC or authenticated user required, and no activity is recorded.</td></tr></tbody></table>

## How the pieces fit together

```mermaid
flowchart LR
    You[Your backend] -->|API key + signature| API[KiiChain Pay API]
    API --> Ledger[(Off-chain ledger<br/>available / locked)]
    API --> Signer[Platform signer]
    Signer -->|delegated Kii Wallet| Wallet[User wallet<br/>Kii or external]
    You -.->|external wallet: user signs| Wallet
    API --> Providers[On-/off-ramp & FX providers]
    Wallet --> Chains[(EVM · Cosmos · Solana<br/>Tron · Bitcoin)]
```

Crypto moves on-chain through the user's wallet — a **Kii Wallet** or their **own external wallet**; fiat moves through **provider rails** (on-ramps, off-ramps, virtual accounts); and KiiChain Pay keeps both sides reconciled in its **internal ledger**.

## The integration journey

Setup is **dashboard-first**: a few one-time steps in [pay.kiichain.io](https://pay.kiichain.io) unlock the API for everything that follows.

1. **Sign up** for a KiiChain Pay account at [pay.kiichain.io](https://pay.kiichain.io).
2. **Complete KYC** — choose individual or company. This sets your account level and limits. See [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc).
3. **Kii Wallets are provisioned automatically** the moment KYC is approved — one per supported chain. See [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets).
4. **Delegate your Kii Wallet** so the platform can sign wallet operations for you. See [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access).
5. **Create an API key** and store the secret. See [Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys).
6. **Integrate** — build on-ramps, off-ramps and FX swaps via the API. See the [Guides](https://docs.kiiglobal.io/docs/kiichain-pay/guides) and [API Reference](https://docs.kiiglobal.io/docs/kiichain-pay/api-reference).

{% hint style="info" %}
Using your **own external wallet**? You sign transactions yourself — skip delegation (step 4). (**DEX swaps** need none of this flow at all.)
{% endhint %}

## Environments

KiiChain Pay exposes two environments. Point your integration at the matching **API base URL**:

<table><thead><tr><th width="150">Environment</th><th>App</th><th>API base URL</th></tr></thead><tbody><tr><td><strong>Production</strong></td><td>https://pay.kiichain.io</td><td><code>https://backend.pay.kiichain.io</code></td></tr><tr><td><strong>Staging</strong></td><td>https://pay.staging.kiichain.io</td><td><code>https://backend.pay.staging.kiichain.io</code></td></tr></tbody></table>

All REST endpoints are versioned and namespaced by module — for example `/users/v1/...`, `/accounts/v1/...`, and `/market/v1/...`.

{% hint style="success" %}
**Gas is on us.** Every Kii Wallet operation is gas-sponsored by KiiChain Pay, so you don't need to hold native tokens to transact. Lean into it.
{% endhint %}

## Next steps

* [Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys) — create a key and sign requests.
* [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) — understand the Kii Wallet model.
* [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) — enable server-side signing.
* [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc) — levels, limits, and provider verification.
* [Subaccounts](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/subaccounts) — onboard and operate your own customers' accounts.


# Generating API keys

Create an API key in the KiiChain Pay dashboard, understand scopes and expiry, and learn how to authenticate, sign and safely retry your API requests.

Every request to the KiiChain Pay API is authenticated with an **API key**. Write requests are additionally **signed** with the key's private key. You create and manage keys from the dashboard; you then use them from your backend.

## 1. Create a key in the dashboard

API keys are created and managed in the KiiChain Pay app. Sign in at [pay.kiichain.io](https://pay.kiichain.io) and go to **Settings → API Keys**.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-1aa991ec3d1ed1d9f5455e21cfb81ffd64edd8b9%2Fkiichain-pay-api-keys-list.png?alt=media" alt="Settings → API Keys page"><figcaption><p>Settings → API Keys, with the <strong>Create New API Key</strong> button and any existing keys.</p></figcaption></figure>

Click **Create API Key** and fill in:

<table><thead><tr><th width="170">Field</th><th>Description</th></tr></thead><tbody><tr><td><strong>Name</strong></td><td>A label to identify the key (e.g. <code>Production backend</code>). Required.</td></tr><tr><td><strong>Scopes</strong></td><td>The permissions the key grants. At least one is required. A key can only be granted scopes you already have — see <a href="#scopes">Scopes</a>. Quick-select buttons let you pick <em>All access</em>, <em>Read only</em>, <em>Write only</em>, or <em>None</em>.</td></tr><tr><td><strong>Expires at</strong></td><td>Optional expiry date. If omitted, the key does not expire. We recommend setting one and rotating regularly.</td></tr></tbody></table>

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-fc087326f58159249e389a3704199add9c39d595%2Fkiichain-pay-create-api-key.png?alt=media" alt="Create API Key dialog"><figcaption><p>The <strong>Create API Key</strong> dialog: name, scope quick-select, and the grouped scope list.</p></figcaption></figure>

## 2. Store the secret — shown only once

When the key is created you'll see three values:

* **API key** (`api_key`) — the opaque token you send in the `Authorization` header.
* **Private key** (`priv_key`) — the Ed25519 private key used to sign write requests.
* **Public key** (`pub_key`) — stored by KiiChain Pay to verify your signatures; also visible later on the key's card.

{% hint style="danger" %}
The **API key** and **private key** are displayed **only once**, at creation. KiiChain Pay does not store the private key and cannot recover it. Copy both into a secure secret store before closing the dialog. If you lose them, rotate the key.
{% endhint %}

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-409a4337efab588ad4748af2507cd2d9de5986b4%2Fkiichain-pay-api-key-secret.png?alt=media" alt="One-time secret reveal dialog"><figcaption><p>The one-time reveal: copy the <strong>API Key</strong> and <strong>Private Key</strong> before closing — they're never shown again.</p></figcaption></figure>

After you close the dialog, the key appears in the list showing only a **masked prefix** (`abc123def456***`) and its public key. From the key's card you can **copy the public key**, **rotate**, or **delete** the key.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-cd178c8e526f27dd2983044ca2d65584d9fa16bb%2Fkiichain-pay-api-key-card.png?alt=media" alt="API key card with scopes expanded"><figcaption><p>An existing key: masked value, the expanded <strong>Scopes</strong> list, and the copy / rotate / delete actions.</p></figcaption></figure>

* **Rotate** issues a new API key and private key for the same key entry (the old credentials stop working immediately). The new secret is shown once, exactly like creation.
* **Delete** revokes the key immediately.

## 3. Authenticate your requests

Send your API key as an `Authorization` header with the **`APIKey`** scheme (not `Bearer`):

```
Authorization: APIKey <your_api_key>
```

**Read requests** (`GET`, `OPTIONS`) need only this header:

```bash
curl https://backend.pay.kiichain.io/accounts/v1/countries \
  -H "Authorization: APIKey $KII_API_KEY"
```

**Write requests** (`POST`, `PATCH`, `PUT`, `DELETE`) must additionally be **signed** — see below.

## 4. Sign write requests

Write requests carry two extra headers:

<table><thead><tr><th width="180">Header</th><th>Value</th></tr></thead><tbody><tr><td><code>x-timestamp</code></td><td>The current time, as a string. Unix seconds (<code>1739471625</code>) or milliseconds (<code>1739471625123</code>) both work — the server signs whatever string you send. Use the <strong>same value</strong> in the signed payload.</td></tr><tr><td><code>x-signature</code></td><td>Base64url (no padding) Ed25519 signature of the canonical payload below.</td></tr></tbody></table>

The signed **payload** is four lines joined by `\n`:

```
payload = timestamp + "\n" + method + "\n" + uri + "\n" + bodyHash
```

| Part        | Value                                                                                                                                                                                |
| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `timestamp` | The exact string you put in the `x-timestamp` header (Unix seconds or milliseconds — just keep it identical in both places).                                                         |
| `method`    | The HTTP method, uppercase (`POST`, `PATCH`, `PUT`, `DELETE`).                                                                                                                       |
| `uri`       | The request URI **including path and query string** (e.g. `/users/v1/api/create`).                                                                                                   |
| `bodyHash`  | Lowercase **hex** SHA-256 of the raw request body bytes. For an empty body, use the SHA-256 of the empty string: `e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855`. |

Sign the UTF-8 bytes of `payload` with your Ed25519 **private key** and send the base64url-encoded signature in `x-signature`.

{% hint style="warning" %}
Sign exactly the bytes you send. The signature covers the timestamp, method, URI (with query string) and a hash of the request body — any mismatch is rejected. Use a **fresh `x-timestamp` per request** to avoid replay rejection.
{% endhint %}

### Reference implementation

These helpers add the correct headers and sign write requests using only each language's **standard library** — no third-party dependencies.

{% tabs %}
{% tab title="Node.js" %}
Requires Node.js 18+ (for the global `fetch` and `base64url` encoding). The `priv_key` is the raw 64-byte Ed25519 key (`seed || publicKey`), which `node:crypto` imports via a JWK.

```typescript
import { createHash, createPrivateKey, sign } from "node:crypto";

const BASE_URL = "https://backend.pay.kiichain.io";
const API_KEY = process.env.KII_API_KEY!; // the opaque "api_key"
const PRIV_KEY = process.env.KII_PRIV_KEY!; // base64url "priv_key", shown once

const WRITE_METHODS = new Set(["POST", "PATCH", "PUT", "DELETE"]);

// The priv_key is the raw 64-byte Ed25519 key: seed (first 32) || public key (last 32).
const rawPrivKey = Buffer.from(PRIV_KEY, "base64url");
const signingKey = createPrivateKey({
  format: "jwk",
  key: {
    kty: "OKP",
    crv: "Ed25519",
    d: rawPrivKey.subarray(0, 32).toString("base64url"), // private seed
    x: rawPrivKey.subarray(32).toString("base64url"), // public key
  },
});

/**
 * `path` must include the query string, e.g. "/market/v1/products-providers?account_id=…".
 */
export async function kiiFetch(method: string, path: string, body?: unknown) {
  method = method.toUpperCase();
  const rawBody = body === undefined ? "" : JSON.stringify(body);
  const timestamp = Date.now().toString();

  const headers: Record<string, string> = {
    Authorization: `APIKey ${API_KEY}`,
    "x-timestamp": timestamp,
  };

  if (WRITE_METHODS.has(method)) {
    const bodyHash = createHash("sha256").update(rawBody, "utf8").digest("hex");
    const payload = `${timestamp}\n${method}\n${path}\n${bodyHash}`;
    headers["x-signature"] = sign(
      null,
      Buffer.from(payload, "utf8"),
      signingKey,
    ).toString("base64url");
    headers["Content-Type"] = "application/json";
  }

  return fetch(BASE_URL + path, {
    method,
    headers,
    body: rawBody === "" ? undefined : rawBody,
  });
}
```

{% endtab %}

{% tab title="Go" %}

```go
package kiipay

import (
	"bytes"
	"crypto/ed25519"
	"crypto/sha256"
	"encoding/base64"
	"encoding/hex"
	"fmt"
	"net/http"
	"os"
	"strconv"
	"time"
)

const baseURL = "https://backend.pay.kiichain.io"

var writeMethods = map[string]bool{
	http.MethodPost: true, http.MethodPatch: true,
	http.MethodPut: true, http.MethodDelete: true,
}

// KiiRequest builds and sends a signed KiiChain Pay API request.
// path must include the query string, e.g. "/market/v1/products-providers?account_id=…".
func KiiRequest(method, path string, body []byte) (*http.Response, error) {
	apiKey := os.Getenv("KII_API_KEY")   // the opaque "api_key"
	privKey := os.Getenv("KII_PRIV_KEY") // base64url "priv_key", shown once

	timestamp := strconv.FormatInt(time.Now().Unix(), 10) // seconds or millis both work

	req, err := http.NewRequest(method, baseURL+path, bytes.NewReader(body))
	if err != nil {
		return nil, err
	}
	req.Header.Set("Authorization", "APIKey "+apiKey)
	req.Header.Set("x-timestamp", timestamp)

	// Sign write requests (POST, PATCH, PUT, DELETE).
	if writeMethods[method] {
		sum := sha256.Sum256(body)
		bodyHash := hex.EncodeToString(sum[:])
		payload := fmt.Sprintf("%s\n%s\n%s\n%s", timestamp, method, path, bodyHash)

		// priv_key decodes to the raw 64-byte Ed25519 private key.
		priv, err := base64.RawURLEncoding.DecodeString(privKey)
		if err != nil {
			return nil, err
		}
		if len(priv) != ed25519.PrivateKeySize {
			return nil, fmt.Errorf("invalid priv_key: got %d bytes, want %d", len(priv), ed25519.PrivateKeySize)
		}
		sig := ed25519.Sign(ed25519.PrivateKey(priv), []byte(payload))
		req.Header.Set("x-signature", base64.RawURLEncoding.EncodeToString(sig))
		req.Header.Set("Content-Type", "application/json")
	}

	return http.DefaultClient.Do(req)
}
```

{% endtab %}
{% endtabs %}

### Signing in other languages

The scheme is language-agnostic — reproduce these steps with any Ed25519 and SHA-256 library:

1. `bodyHash = hex(sha256(rawBodyBytes))`
2. `payload = "{timestamp}\n{METHOD}\n{uri}\n{bodyHash}"`
3. `signature = base64url_nopad(ed25519_sign(privateKey, utf8(payload)))`
4. Send headers `Authorization: APIKey <api_key>`, `x-timestamp: <timestamp>`, `x-signature: <signature>`.

Base64url-decode `priv_key` to obtain the raw 64-byte Ed25519 private key.

## 5. Retry write requests safely

A write request can time out or lose its connection after the server has already processed it. To retry without running the operation twice (for example creating two tickets), send an optional **`Idempotency-Key`** header:

```
Idempotency-Key: 3f1c9a52-7d4e-4b8a-9e21-6c0f5d2b8a17
```

Generate a new unique key (a UUID v4 works well) for each operation, and send **the same key** on every retry of that operation.

<table><thead><tr><th width="260">Retry</th><th>Result</th></tr></thead><tbody><tr><td>Same key, same request, first attempt succeeded</td><td>The stored response is returned. The operation is <strong>not</strong> run again.</td></tr><tr><td>Same key, first attempt still running</td><td><code>409 Conflict</code>. Wait and retry with the same key.</td></tr><tr><td>Same key, different body or parameters</td><td><code>400 Bad Request</code>. Use a new key for a new operation.</td></tr><tr><td>Same key, first attempt failed</td><td>Nothing was stored, so the request runs again as a new one.</td></tr></tbody></table>

* The key must be between 1 and 255 characters; anything else is rejected with `400 Bad Request`.
* A key is scoped to your user and the endpoint: the same key sent to two different endpoints is treated as two separate keys.
* Keys are kept for **24 hours**. After that, a request with the same key runs as a new one.
* Read requests ignore the header.

{% hint style="warning" %}
The idempotency check runs **after** authentication. Every retry still needs a **fresh `x-timestamp` and a new `x-signature`**, and a valid `X-Mfa-Code` on endpoints that require one. Don't replay the original request's headers byte for byte.
{% endhint %}

`Idempotency-Key` has no effect on [creating or rotating an API key](https://docs.kiiglobal.io/docs/kiichain-pay/api-reference/users). A retry of those runs again.

## Scopes

Scopes follow the pattern `<module>.<resource>.<action>`, where the action is one of `read`, `write`, `update`, `delete`, or `admin`. A key's scopes are validated on every call, and the endpoint you hit declares which scope it requires.

{% hint style="info" %}
A key can never have more access than the account that created it — requested scopes are capped by **your own** scopes. Scopes with an `:all` suffix (cross-account) and `admin` scopes are elevated permissions and are generally not available to integrator keys.
{% endhint %}

Commonly used scopes:

<table><thead><tr><th width="330">Scope</th><th>Grants</th></tr></thead><tbody><tr><td><code>users.api.read</code> / <code>write</code> / <code>update</code> / <code>delete</code></td><td>Manage your API keys.</td></tr><tr><td><code>users.accounts.read</code> / <code>write</code></td><td>Read and manage accounts.</td></tr><tr><td><code>accounts.kyc.read</code> / <code>write</code></td><td>Read KYC status / start KYC.</td></tr><tr><td><code>accounts.withdrawal_destination.read</code> / <code>write</code></td><td>Manage withdrawal destinations (bank accounts, wallet addresses).</td></tr><tr><td><code>market.products.read</code>, <code>market.providers.read</code>, <code>market.dex.read</code>, <code>market.instruments.read</code>, <code>market.fiat_assets.read</code></td><td>Discover on-/off-ramp products, providers, DEX routes, instruments and fiat assets.</td></tr><tr><td><code>market.providers_virtual_accounts.read</code> / <code>write</code></td><td>Create and read virtual accounts for fiat on-/off-ramps.</td></tr><tr><td><code>tickets.tickets.read</code> / <code>write</code></td><td>Create and track on-ramp, off-ramp and swap tickets.</td></tr><tr><td><code>ledger.entries.read</code></td><td>Read ledger balances and transaction history.</td></tr><tr><td><code>accounts.subaccounts.read</code> / <code>write</code></td><td>Manage your company's <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/subaccounts">subaccounts</a> and act on them, on top of each endpoint's own scope.</td></tr></tbody></table>

The dashboard's create dialog always lists the full, current set of scopes available to your account.

## Next steps

* [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) — the Kii Wallet model your API operations act on.
* [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) — required before your key can drive wallet operations.
* [API Reference](https://docs.kiiglobal.io/docs/kiichain-pay/api-reference) — per-endpoint scopes and payloads.


# Internal wallets

The Kii Wallet is an optional, non-custodial embedded wallet with sponsored gas. Users can just as well bring their own external wallet — on-ramps, off-ramps and FX swaps work the same either way.

The **Kii Wallet** is a set of **embedded wallets** that KiiChain Pay can provision for an account. They are **non-custodial**: the private keys are managed by [Privy](https://privy.io) and owned by the user — KiiChain Pay never holds a private key.

Using a Kii Wallet is **optional**. A user can transact with their **own external wallet** instead, and on-ramps, off-ramps and FX swaps work exactly the same either way. The Kii Wallet is simply a convenience for users who'd rather not manage private keys and wallet tooling — and it comes with **sponsored gas**.

Alongside on-chain wallets, KiiChain Pay keeps an **internal ledger** that tracks fiat and reserved balances off-chain. Together they let you mix on-chain and off-chain operations seamlessly.

## What a Kii Wallet is

* An **embedded wallet** created and secured by Privy, one **per account, per supported chain**.
* **Supported chain types:** EVM (Ethereum-compatible, including KiiChain), Cosmos, Solana, Tron, and Bitcoin (SegWit).
* **Non-custodial:** keys live with Privy and belong to the user. To let your backend transact from a wallet, the user must first [delegate it](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) to the platform signer.
* **Gas-sponsored:** every Kii Wallet operation is paid for by KiiChain Pay, so users never need native gas tokens.

{% hint style="info" %}
Kii Wallets are provisioned **automatically when KYC is approved** — not at signup. An account at level 0 (no KYC) has no wallets yet. See [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc).
{% endhint %}

## On-chain balances vs. the off-chain ledger

KiiChain Pay tracks value in two places:

<table><thead><tr><th width="200">Where</th><th>What it holds</th></tr></thead><tbody><tr><td><strong>On-chain (Kii Wallet)</strong></td><td>Crypto assets, held at the wallet's address on each chain. Balances are read directly from the blockchain.</td></tr><tr><td><strong>Off-chain (internal ledger)</strong></td><td>Fiat and reserved balances, tracked in a double-entry ledger. Each balance has an <code>available</code> portion and a <code>locked</code> portion (funds reserved for an in-flight withdrawal, swap or ramp).</td></tr></tbody></table>

This split is why a swap or off-ramp can reserve funds (`locked`) the instant you create it, while the on-chain settlement happens moments later.

## How funds move

Every flow works with **either** a Kii Wallet or a user's own external wallet:

* **Deposits** — receive crypto to the wallet address, or fund a fiat **virtual account** via an on-ramp provider.
* **Withdrawals** — send crypto to an external address, or off-ramp to a bank account through a provider.
* **On-ramps, off-ramps & FX swaps** — bridge fiat and crypto, or swap between assets. The crypto leg settles on-chain through KiiChain Pay's settlement contracts, while the fiat leg moves over provider rails and is reconciled in the internal ledger. Each is tracked as an **activity** (internally, a *ticket*). With a delegated Kii Wallet the platform signs on the user's behalf; with an external wallet the user signs.
* **DEX swaps** — swap tokens directly on-chain through the DEX. **No authenticated user and no KYC are required**: a user can run a DEX swap anonymously from any external wallet, and it creates **no activity**. Sponsored gas applies only to Kii Wallets.

See the [Guides](https://docs.kiiglobal.io/docs/kiichain-pay/guides) for end-to-end [on-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-on-ramp), [off-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-off-ramp), and [FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) walkthroughs.

## Viewing your wallets

In the app, the wallet switcher (top-right) lists the Kii Wallet's address on each supported chain, and the dashboard shows balances across all of them.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-a69ad8be7a23d42523bdf5c3a91844c12cf9a465%2Fkiichain-pay-kii-wallet-addresses.png?alt=media" alt="Kii Wallet address switcher"><figcaption><p>The wallet switcher: per-chain Kii Wallet addresses (EVM, Tron, …), with an external wallet as the alternative.</p></figcaption></figure>

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-b05a9144a45c45ec94cfcb1be3294cf3164424f3%2Fkiichain-pay-kii-wallet-balances.png?alt=media" alt="Dashboard balances"><figcaption><p>The dashboard's available balance and per-token portfolio for the connected wallet.</p></figcaption></figure>

## Accessing wallets via the API

Three endpoints expose Kii Wallets to your backend. All authenticate with an [API key](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys); the examples assume `KII_API_KEY` holds your key and `KII_ACCOUNT_ID` the account whose wallets you use.

### List your Kii Wallets

`GET /blockchain/v1/accounts/{accountId}/wallets/internal` returns the account's Kii Wallets across **every supported chain type**, one entry per chain. This is a read request, so it needs only the `Authorization` header. Requires the `blockchain.wallets.read` scope.

```bash
curl https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_ACCOUNT_ID/wallets/internal \
  -H "Authorization: APIKey $KII_API_KEY"
```

```json
{
  "wallets": [
    {
      "id": "b1c3f0a2-7e4d-4c8a-9f21-0a5b6c7d8e9f",
      "address": "0x1A2b3C4d5E6f7A8b9C0d1E2f3A4b5C6d7E8f9A0b",
      "chainType": "ethereum"
    },
    {
      "id": "d4e5f6a7-8b9c-4d0e-a1f2-3b4c5d6e7f80",
      "address": "TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbfSL",
      "chainType": "tron"
    }
  ]
}
```

### Send tokens from a Kii Wallet

`POST /blockchain/v1/accounts/{accountId}/wallets/internal/send` builds a transfer from the account's Kii Wallet to another address, then signs and broadcasts it using the [delegated](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) wallet — so the wallet **must be delegated** first. It works on any supported chain given its `chain_id`. Requires the `blockchain.wallets.send` scope.

This is a **write request**, so it must also carry the `x-timestamp` and `x-signature` headers described in [Sign write requests](https://docs.kiiglobal.io/pages/Xi9e9VnluBBSJsek157L#4.-sign-write-requests). The examples below show the request shape — compute the signature over the exact body you send.

Request body:

<table><thead><tr><th width="150">Field</th><th>Description</th></tr></thead><tbody><tr><td><code>chain_id</code></td><td>Numeric network ID, as a string (e.g. <code>"1"</code> for Ethereum mainnet). Required.</td></tr><tr><td><code>to</code></td><td>Destination address that receives the balance. Required.</td></tr><tr><td><code>asset</code></td><td>Token contract address to send. Omit (or use the zero address) to send the <strong>native gas token</strong>. Optional.</td></tr><tr><td><code>amount</code></td><td>Amount in the token's <strong>smallest unit</strong> (wei / atoms), as a string. Required.</td></tr></tbody></table>

**Send the native gas token** (omit `asset`) — here, 0.01 ETH (`10000000000000000` wei):

```bash
curl -X POST https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_ACCOUNT_ID/wallets/internal/send \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{
    "chain_id": "1",
    "to": "0x1A2b3C4d5E6f7A8b9C0d1E2f3A4b5C6d7E8f9A0b",
    "amount": "10000000000000000"
  }'
```

**Send an ERC-20 token** (set `asset` to the token contract) — here, 25 USDC (6 decimals → `25000000`):

```bash
curl -X POST https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_ACCOUNT_ID/wallets/internal/send \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{
    "chain_id": "1",
    "to": "0x1A2b3C4d5E6f7A8b9C0d1E2f3A4b5C6d7E8f9A0b",
    "asset": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
    "amount": "25000000"
  }'
```

Both return the broadcast transaction hash:

```json
{
  "txHash": "0x9f8e7d6c5b4a39281706f5e4d3c2b1a09f8e7d6c5b4a39281706f5e4d3c2b1a0"
}
```

### Execute prepared transactions

`POST /blockchain/v1/accounts/{accountId}/transactions/execute` signs and broadcasts a **batch of prepared transactions** from the account's Kii Wallet — again using the [delegated](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) wallet, with gas sponsored. Unlike `send`, you don't describe a transfer; you hand it transactions that were **built for you elsewhere** and just need signing. The two common sources are:

* The `transactions` returned when you create an [off-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-off-ramp) or [FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) activity.
* A [DEX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-a-dex-swap) quote's `evm_tx`, decoded into its fields.

The wallet **must be delegated**, and this requires the `blockchain.transactions.execute` scope. It is a **write request**, so it also carries the `x-timestamp` and `x-signature` headers from [Sign write requests](https://docs.kiiglobal.io/pages/Xi9e9VnluBBSJsek157L#4.-sign-write-requests).

Request body — a `transactions` array. Each entry wraps a chain-specific transaction; for EVM chains that's an `evm` object:

<table><thead><tr><th width="150">Field</th><th>Description</th></tr></thead><tbody><tr><td><code>chain_id</code></td><td>Numeric network ID, as a string. Required.</td></tr><tr><td><code>to</code></td><td>Destination — usually a contract address. Required.</td></tr><tr><td><code>value</code></td><td>Native token amount in wei, as a string (<code>"0"</code> for pure contract calls). Required.</td></tr><tr><td><code>data</code></td><td>Hex-encoded call data (<code>0x…</code>). Required for contract calls.</td></tr><tr><td><code>from</code></td><td>The Kii Wallet address the transaction is signed from.</td></tr></tbody></table>

```bash
curl -X POST https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_ACCOUNT_ID/transactions/execute \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{
    "transactions": [
      {
        "evm": {
          "chain_id": "1",
          "to": "0xRouterContractAddress…",
          "value": "0",
          "data": "0xa9059cbb…"
        }
      }
    ]
  }'
```

Transactions are signed and broadcast **in order**, so an approval placed before a swap in the array is settled first. The response returns one hash per transaction:

```json
{
  "txHashes": [
    "0x9f8e7d6c5b4a39281706f5e4d3c2b1a09f8e7d6c5b4a39281706f5e4d3c2b1a0"
  ]
}
```

{% hint style="info" %}
A hash of `"0x00"` marks a transaction that failed to broadcast. Check each entry before treating the batch as settled.
{% endhint %}

## Next steps

* [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) — let your backend sign wallet operations.
* [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc) — required before wallets are provisioned.


# Privy delegated access

Delegate a Kii Wallet to the KiiChain Pay signer so your backend can sign and broadcast transactions on the user's behalf — without a per-transaction prompt.

Because Kii Wallets are [non-custodial](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets), KiiChain Pay cannot sign a transaction from a user's wallet on its own — the keys belong to the user. **Delegated access** bridges that gap: the user authorizes the platform's signer to act on their embedded wallet, so your backend can sign and broadcast wallet operations through the API without prompting the user for every transaction.

Delegation is built on [Privy](https://privy.io)'s **session signers**. It is explicit, granted by the user, and required for any wallet-scoped API operation.

{% hint style="info" %}
Delegation applies **only to Kii Wallets**. A user transacting with their own external wallet signs each transaction themselves — no delegation needed.
{% endhint %}

## Why delegate

Without delegation, every on-chain action would need the user to sign in real time — impractical for automated, server-driven payments and FX. With delegation:

* Your backend can execute swaps, off-ramps and transfers from the user's Kii Wallet via the API.
* No per-transaction signing prompt.
* Transactions remain **gas-sponsored** by KiiChain Pay.

{% hint style="info" %}
Delegation authorizes **signing on the user's own wallet**. Funds still move only to the destinations your API calls specify; the platform signs on the user's behalf, it does not take custody of the keys.
{% endhint %}

## How it works

```mermaid
flowchart LR
    U[User] -->|delegates Kii Wallet| P[Privy session signer]
    P -->|added as signer on wallet| W[Kii Wallet]
    B[Your backend] -->|API call| API[KiiChain Pay]
    API -->|sign & broadcast| W
```

Under the hood, delegation adds the KiiChain Pay **session signer** to the user's embedded wallet (Privy's `addSigners`). Once added, the platform can call Privy's wallet API to sign and broadcast transactions from that wallet. Privy exposes a `delegated` flag on the wallet, which KiiChain Pay reads to know whether server-side signing is available.

## Granting delegation (dashboard)

The user grants delegation once, from the dashboard. In **Settings → API Keys**, use the **Delegate Wallet** action.

{% hint style="warning" %}
The Kii Wallet must exist first, which means **KYC must be complete** (wallets are provisioned on KYC approval). See [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc).
{% endhint %}

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-fbe76340206bd6889572b4f0e933b0a0ebce6c02%2Fkiichain-pay-delegate-wallet.png?alt=media" alt="Delegate Wallet button"><figcaption><p>Settings → API Keys: the <strong>Delegate Wallet</strong> action, before delegation.</p></figcaption></figure>

After confirming, the wallet shows a **delegation active** state:

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-ef8dcce331ad0a9959cb27cc7cb39b71bf5d65e5%2Fkiichain-pay-delegation-active.png?alt=media" alt="Delegation active state"><figcaption><p>Once delegated, the panel confirms the Kii Wallet can be used for server-side signing.</p></figcaption></figure>

## What delegation unlocks

With a delegated wallet, wallet-scoped API operations — FX swaps, off-ramp settlements — are signed server-side from that user's wallet. Without delegation, those operations return an error.

The [upcoming "send tokens from a Kii Wallet" endpoint](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets#accessing-wallets-via-the-api) will also require delegation.

## Next steps

* [Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys) — the key that authorizes delegated operations.
* [Creating an FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) — a delegated operation end to end.


# KYC

KYC gates wallets, limits and provider access in KiiChain Pay. Learn the account levels, individual vs. company verification, the separate provider KYC/KYB for on- and off-ramps, and which assets an a

KYC (Know Your Customer) is the gate that unlocks KiiChain Pay for an account. Until an account is verified it has **no Kii Wallets, no limits, and no access** to fiat rails. Completing KYC provisions the account's [Kii Wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) and sets its transaction limits.

{% hint style="info" %}
KYC gates **Kii Wallets, fiat on-/off-ramps and limits** — not the chain itself. A user can still run **DEX swaps** anonymously from their own external wallet with no account and no KYC. See [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets#how-funds-move).
{% endhint %}

There are **two independent verification flows**:

1. **System KYC** — KiiChain Pay's own identity verification. Sets your **account level** and platform-wide limits. **Every account completes this.**
2. **Provider KYC / KYB** — occasional extra verification a specific provider may require, and only in certain cases and countries. **Most integrators never need it.** Covered [below](#provider-kyc-kyb).

## System KYC

### Account levels and limits

An account has a **level** (0, 1, or 2) and a **type** (individual or company). Level 0 means no KYC — no access. Levels 1 and 2 unlock rising limits, applied **per action** (`deposit`, `withdraw`, `swap`) in **USD** over a **rolling 30-day** window.

<table><thead><tr><th width="150">Account type</th><th width="100">Level</th><th>Limit per action (USD / 30 days)</th></tr></thead><tbody><tr><td>Individual</td><td>1</td><td>1,000</td></tr><tr><td>Individual</td><td>2</td><td>5,000</td></tr><tr><td>Company</td><td>1</td><td>10,000</td></tr><tr><td>Company</td><td>2</td><td>20,000</td></tr></tbody></table>

{% hint style="info" %}
Level 1 is granted on first successful verification. Level 2 is a limit upgrade you request after reaching level 1. Individual accounts that pass a company verification become company accounts.
{% endhint %}

### The verification flow

System KYC uses the **Sumsub** identity platform, embedded directly in the KiiChain Pay app.

In the app, go to **Settings → KYC** and choose **Individual** or **Company** verification.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-ff9a6d552f161d9003342ea60d5a981ceaeef885%2Fkiichain-pay-kyc-page.png?alt=media" alt="Settings → KYC page, unverified"><figcaption><p>Settings → KYC: the <strong>Individual</strong> and <strong>Company</strong> verification options, before starting.</p></figcaption></figure>

Starting verification opens the Sumsub flow, where the user completes identity checks (and, for companies, company documents).

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-c9afeb39075e408c6cac543f61d2b5c21b232bae%2Fkiichain-pay-sumsub.png?alt=media" alt="Sumsub verification dialog"><figcaption><p>The embedded Sumsub flow — here, the document-upload step.</p></figcaption></figure>

```mermaid
flowchart LR
    A[Start KYC<br/>Individual or Company] --> B[Complete Sumsub checks]
    B --> C{Reviewed}
    C -->|Approved| D[Level set · Kii Wallets provisioned]
    C -->|Rejected| E[Resubmit or contact support]
```

When the review is approved, the account's level and type are set and its **Kii Wallets are provisioned automatically**. The verified level and current limits are then shown in the dashboard.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-f3fad9267a034dd21a3725f33efc0d41da89efc1%2Fkiichain-pay-kyc-level-limits.png?alt=media" alt="Verified account level and limits"><figcaption><p>Verified: account type, level, the per-action limits table, and the <strong>Upgrade Limits</strong> action (level 1 → 2).</p></figcaption></figure>

### Individual vs. company

* **Individual** verification requires personal identity documents.
* **Company** verification (KYB) additionally requires a **company name** and company documentation, and typically covers the authorized representative and the business itself. Company accounts receive higher limits (see the table above).

### KYC status

The dashboard surfaces a status for the verification — for example *not started*, *pending*, *completed*, *verified*, or *rejected* — with a contextual banner guiding the next step. A rejection may be final or ask the user to resubmit with better documents.

## Provider KYC / KYB

{% hint style="info" %}
**Most integrators can skip this.** System KYC (above) is all you need in the common case. Provider KYC is required only in very specific cases and specific countries, where a third-party on-/off-ramp provider imposes its own compliance requirements. **You don't need to seek it out in advance** — when a transaction needs it, KiiChain Pay prompts you to complete that provider's verification.
{% endhint %}

Some on- and off-ramp providers are third parties with their **own** compliance requirements. In those cases, an account must complete that provider's KYC (or KYB, for companies) before transacting through it — this is **separate** from system KYC above, and it's requested only when needed.

When it applies, the **KYC** page's **Providers** tab lists the relevant provider with its verification status (e.g. *pending*, *processing*, *verified*, *rejected*).

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fgit-blob-87d7c63c82f921976b7248750d6b966e07e8a2e2%2Fkiichain-pay-provider-kyc.png?alt=media" alt="Provider KYC tab"><figcaption><p>The <strong>Provider KYC</strong> tab, listing each relevant provider with its verification status.</p></figcaption></figure>

When prompted, starting provider verification opens the provider's flow (a redirect rather than an embedded SDK). **Company (KYB)** accounts complete an extra step — an authorized-representative flow plus a basic company-data step — whereas individuals complete a single flow.

{% hint style="info" %}
Provider verification is per provider: verifying with one provider does not verify you with another. When a provider is required, check its status before routing a transaction through it.
{% endhint %}

## What your account can use

KYC decides which assets and rails an account can use, not just whether it can use KiiChain Pay at all. Rails, swap pairs and fiat holdings each carry an **`availability`** object that tells you, for the requesting account, whether it can be used and, if not, why.

```json
{
  "allowed": false,
  "reason": "fiat_country_required",
  "requiredCountries": ["BRA"]
}
```

<table><thead><tr><th width="200">Field</th><th>Meaning</th></tr></thead><tbody><tr><td><code>allowed</code></td><td>Whether the account can use the row. Always present.</td></tr><tr><td><code>reason</code></td><td>Why the row is blocked. Unset when <code>allowed</code> is <code>true</code>.</td></tr><tr><td><code>requiredCountries</code></td><td>ISO 3166-1 alpha-3 codes that would unlock the row. Only set for <code>fiat_country_required</code>.</td></tr><tr><td><code>providerId</code>, <code>providerName</code></td><td>The provider whose onboarding is pending. Only set for <code>provider_kyc_required</code>.</td></tr></tbody></table>

### Blocking reasons

<table><thead><tr><th width="230">Reason</th><th>Meaning</th><th>What to do</th></tr></thead><tbody><tr><td><code>kyc_required</code></td><td>The account hasn't completed system KYC (level 0).</td><td>Complete <a href="#system-kyc">system KYC</a>.</td></tr><tr><td><code>country_not_supported</code></td><td>The provider doesn't serve the account's country.</td><td>Use another rail for the same asset, if one is allowed.</td></tr><tr><td><code>fiat_country_required</code></td><td>The fiat can only be used by accounts from its issuing country, and none of the account's countries match.</td><td>The account needs one of the <code>requiredCountries</code>. Contact support if its countries are wrong.</td></tr><tr><td><code>provider_kyc_required</code></td><td>The provider runs its own onboarding and hasn't approved the account yet.</td><td>Complete <a href="#provider-kyc-kyb">provider KYC</a> with <code>providerName</code>.</td></tr><tr><td><code>not_offered</code></td><td>No provider currently offers deposits into this fiat.</td><td>Nothing on your side. The balance can still be held.</td></tr></tbody></table>

Each fiat is tied to its issuing countries: **BRL** to Brazil, **COP** to Colombia, **MXN** to Mexico, **USD** to the United States, and **EUR** to the euro area members. `GET /accounts/v1/accounts/{accountId}/countries` lists the countries on an account.

### Where it appears

<table><thead><tr><th width="300">Endpoint</th><th>Field</th><th>Possible reasons</th></tr></thead><tbody><tr><td><code>GET /market/v1/products-providers</code></td><td><code>productsProviders[].availability</code></td><td><code>kyc_required</code>, <code>country_not_supported</code>, <code>fiat_country_required</code></td></tr><tr><td><code>GET /market/v1/instruments</code></td><td><code>instruments[].availability</code></td><td><code>kyc_required</code>, <code>country_not_supported</code></td></tr><tr><td><code>GET /market/v1/trade-instruments</code></td><td><code>tradeInstruments[].products[].availability</code></td><td><code>kyc_required</code>, <code>country_not_supported</code></td></tr><tr><td><code>GET /portfolio/v1/portfolio</code></td><td>each fiat holding's <code>availability</code></td><td>all five</td></tr></tbody></table>

### In your portfolio

The portfolio's fiat holdings list every fiat the account **holds or can deposit into**, each with its `availability`:

* A fiat is allowed when **any** provider lets the account deposit into it. When none does, the first blocking reason is reported, and it stays the same between calls.
* A fiat the account can deposit into but doesn't hold yet appears with a **zero balance**, so you can show it before the first deposit.
* A fiat the account holds but no provider offers anymore still appears, marked `not_offered`.

## Next steps

* [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) — provisioned automatically once system KYC is approved.
* [Creating an on-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-on-ramp) — where provider KYC may come into play.
* [Subaccounts](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/subaccounts) — verify your own customers with a KYC link instead of the dashboard.


# Subaccounts

Subaccounts let a company onboard its own customers on KiiChain Pay and operate their accounts through its API key: create them, send each customer a KYC link, and move funds, swap and trade on their

A **subaccount** is an account a company creates for one of its own customers. The customer never signs up to KiiChain Pay or logs in: the company creates the subaccount, sends the customer a KYC link, and from then on operates the subaccount through its own [API key](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys), just like its own account.

Each subaccount is a full KiiChain Pay account. It has its own [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc) level and limits, its own [Kii Wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets), its own withdrawal destinations and its own activities, all separate from the company's.

{% hint style="info" %}
Only a **KYC-verified company account** can have subaccounts, and a subaccount can't have subaccounts of its own.
{% endhint %}

```mermaid
flowchart LR
    A[Create the subaccount] --> B[Send the customer<br/>the KYC link]
    B --> C{Sumsub review}
    C -->|Approved| D[Level set · Kii Wallets<br/>provisioned and delegated]
    D --> E[Operate it with your API key<br/>send · swap · trade · ramps]
    C -->|Rejected| B
```

## Access

A subaccount is operated with the company's API key, by passing the **subaccount's ID** wherever an endpoint takes an account ID (`{accountId}` in the path or `account_id` in the body or query). KiiChain Pay checks that the subaccount belongs to the company calling it.

On top of the scope each endpoint already requires, acting on a subaccount needs one of these scopes on the key:

<table><thead><tr><th width="280">Scope</th><th>Needed for</th></tr></thead><tbody><tr><td><code>accounts.subaccounts.read</code></td><td>Read endpoints called on a subaccount, and listing or getting subaccounts.</td></tr><tr><td><code>accounts.subaccounts.write</code></td><td>Every other endpoint called on a subaccount, and creating subaccounts or KYC links.</td></tr></tbody></table>

For example, sending from a subaccount's Kii Wallet needs `blockchain.wallets.send` **and** `accounts.subaccounts.write`.

Some endpoints only make sense on the company account itself and are refused when called with a subaccount's ID: account deletion, billing and subscriptions, system KYC (`StartKyc`, subaccounts use the [KYC link](#2.-send-the-customer-a-kyc-link) instead), and managing subaccounts.

## Onboarding a customer

The examples assume `KII_API_KEY` holds the company's API key and `KII_ACCOUNT_ID` the company's account ID. Write requests also carry the `x-timestamp` and `x-signature` headers described in [Sign write requests](https://docs.kiiglobal.io/pages/Xi9e9VnluBBSJsek157L#4.-sign-write-requests).

### 1. Create the subaccount

`POST /accounts/v1/accounts/{accountId}/subaccounts`, where `{accountId}` is the company's account. Requires `accounts.subaccounts.write`.

<table><thead><tr><th width="150">Field</th><th>Description</th></tr></thead><tbody><tr><td><code>name</code></td><td>The subaccount's name, usually the customer's name (1–64 characters). Required.</td></tr><tr><td><code>country</code></td><td>The customer's country, ISO 3166-1 alpha-3 (e.g. <code>BRA</code>). Required.</td></tr><tr><td><code>external_ref</code></td><td>Your own identifier for the customer, unique within your company (1–128 characters). Optional.</td></tr></tbody></table>

```bash
curl -X POST "https://backend.pay.kiichain.io/accounts/v1/accounts/$KII_ACCOUNT_ID/subaccounts" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Maria Silva",
    "country": "BRA",
    "external_ref": "customer-1234"
  }'
```

The response holds the new subaccount. Its `account.id` is the subaccount ID you use from now on:

```json
{
  "subaccount": {
    "account": {
      "id": "115f5269-1dd7-4be8-8af4-2fd38ce8478f",
      "accountName": "Maria Silva",
      "accountType": "individual",
      "countries": ["BRA"]
    },
    "parentAccountId": "4a01b6fe-0fd6-4d29-b5b0-a2ad6ac4c5f2",
    "externalRef": "customer-1234"
  }
}
```

{% hint style="info" %}
Retrying with the same `external_ref` returns the subaccount that was already created instead of a second one, so it's safe to retry a create that timed out.
{% endhint %}

To find subaccounts later, `GET /accounts/v1/accounts/{accountId}/subaccounts` lists them (with `page`, `limit`, and an exact-match `external_ref` filter) and `GET /accounts/v1/accounts/{accountId}/subaccounts/{subaccountId}` gets one. Both require `accounts.subaccounts.read`.

### 2. Send the customer a KYC link

`POST /accounts/v1/accounts/{accountId}/subaccounts/{subaccountId}/kyc/link` returns a link to the hosted Sumsub verification page for that subaccount. Send it to your customer, by email, chat or inside your app. Requires `accounts.subaccounts.write`.

<table><thead><tr><th width="150">Field</th><th>Description</th></tr></thead><tbody><tr><td><code>lang</code></td><td>Two-letter language of the verification page (e.g. <code>en</code>, <code>es</code>, <code>pt</code>). Optional.</td></tr></tbody></table>

```bash
curl -X POST "https://backend.pay.kiichain.io/accounts/v1/accounts/$KII_ACCOUNT_ID/subaccounts/$KII_SUBACCOUNT_ID/kyc/link" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{ "lang": "pt" }'
```

```json
{
  "kycUrl": "https://in.sumsub.com/websdk/p/…",
  "expiresAt": "2026-11-12T10:49:26Z"
}
```

* The link is valid for **7 days**.
* If the customer loses it or it expires, call the endpoint again. You get a new link to the **same** verification, and anything the customer already submitted is kept.
* Once the subaccount is verified, the endpoint answers `KYC applicant already verified`.

### 3. Wait for the review

When Sumsub approves the customer, the subaccount gets its KYC level and limits, and its [Kii Wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) are provisioned. Check it with the get subaccount endpoint: `account.kycInfo.status` becomes `verified` and `account.kycInfo.level` is set.

```bash
curl "https://backend.pay.kiichain.io/accounts/v1/accounts/$KII_ACCOUNT_ID/subaccounts/$KII_SUBACCOUNT_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

A subaccount's Kii Wallets are **already delegated** to the platform signer, so unlike your own account there's no [delegation](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) step: you can send and execute from them as soon as they exist.

## Operating a subaccount

From here on, use the subaccount's ID as the account ID in the regular endpoints and guides.

### Wallets and transfers

The [Kii Wallet endpoints](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets#accessing-wallets-via-the-api) work the same with the subaccount's ID: list its wallets, send from them, and execute prepared transactions, without MFA (see [MFA](#mfa)).

```bash
curl "https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_SUBACCOUNT_ID/wallets/internal" \
  -H "Authorization: APIKey $KII_API_KEY"
```

### Withdrawal destinations

Register destinations on the subaccount with `POST /accounts/v1/accounts/{subaccountId}/withdrawal_destinations`, as described in [Discovering rails & IDs](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids). On a subaccount the destination is **confirmed right away**: there's no verification code to send back, because the code would go to the company's email rather than the customer's.

### Ramps, swaps and trades

The [guides](https://docs.kiiglobal.io/docs/kiichain-pay/guides) apply as they are: pass the subaccount's ID as `account_id`, and its Kii Wallet address as `user_chain_address`. When a guide signs with a delegated Kii Wallet, call `transactions/execute` with the subaccount's ID.

**Permit swaps.** Some swap providers take the input tokens with a signed permit instead of an on-chain transaction. Their swap activity returns a `typedData` action rather than `evm` transactions. Sign it with the subaccount's Kii Wallet, then submit the signature on the activity:

```bash
# Sign the typed data with the subaccount's Kii Wallet
curl -X POST "https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_SUBACCOUNT_ID/wallets/internal/sign-typed-data" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP_1" \
  -H "x-signature: $KII_SIGNATURE_1" \
  -H "Content-Type: application/json" \
  -d '{ "typed_data": "… the typedData.typedData string from the activity …" }'

# Submit it on the activity
curl -X POST "https://backend.pay.kiichain.io/tickets/v1/$KII_TICKET_ID/signature" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP_2" \
  -H "x-signature: $KII_SIGNATURE_2" \
  -H "Content-Type: application/json" \
  -d '{
    "account_id": "'"$KII_SUBACCOUNT_ID"'",
    "type": "permit",
    "signature": "0x…"
  }'
```

`sign-typed-data` requires `blockchain.transactions.execute` and returns `{ "signature": "0x…" }`, the 65-byte EIP-712 signature.

Each request is signed on its own: the signature covers the timestamp, method, path and body, so compute a fresh `x-timestamp` and `x-signature` for the second call rather than reusing the first one's.

### Provider KYC

When a provider needs its own [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc#provider-kyc-kyb) for the subaccount, start it with the subaccount's ID and send the returned `nextUrl` to your customer:

```bash
curl -X POST "https://backend.pay.kiichain.io/market/v1/providers/$KII_PROVIDER_ID/kyc/$KII_SUBACCOUNT_ID/start" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{}'
```

The provider account is opened under the subaccount's `name`, the customer, not under your company. Calling `start` again while the verification is in progress returns the same link, and `POST /market/v1/providers/{providerId}/kyc/{accountId}` returns the current status.

## MFA

You don't need to do anything for this. Because the company's integration has no authenticator code to send, these endpoints skip the `X-Mfa-Code` check when they're called **on a subaccount with an API key**:

* `POST /blockchain/v1/accounts/{accountId}/wallets/internal/send`
* `POST /blockchain/v1/accounts/{accountId}/transactions/execute`
* `POST /blockchain/v1/accounts/{accountId}/wallets/internal/sign-typed-data`
* `POST /accounts/v1/accounts/{accountId}/withdrawal_destinations`

The same calls from a dashboard login, or on the company's own account, still require MFA.

## Next steps

* [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc) — levels, limits, and what an account can use.
* [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) — the wallet endpoints you call with the subaccount's ID.
* [Guides](https://docs.kiiglobal.io/docs/kiichain-pay/guides) — on-ramps, off-ramps, swaps and trades.


# Guides

The four ways to move value with KiiChain Pay — on-ramp, off-ramp, FX swap and DEX swap — the shared quote → create → act → track loop, how they differ, and where to find the IDs each one needs.

KiiChain Pay gives you four ways to move value, split into **two families**:

* **Account-based activities** — **on-ramp**, **off-ramp**, and **FX swap**. Each is recorded as an **activity** (internally a *ticket*), runs through a state machine, is KYC-gated, and is tracked to a terminal status. These are the custodial, reconciled flows.
* **Permissionless DEX swap** — an on-chain token swap routed through a DEX from any wallet. It creates **no activity**, needs **no KYC**, and settles entirely on-chain.

{% hint style="info" %}
New to KiiChain Pay? Start with the [Introduction](https://docs.kiiglobal.io/docs/kiichain-pay/introduction) to set up an account, complete [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc), provision your [Kii Wallet](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets), [delegate it](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access), and [create an API key](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys). This page assumes you have those in place.
{% endhint %}

## The common loop

Every account-based activity follows the same four beats. Only **step 3 (Act)** differs between them.

```mermaid
flowchart LR
    Q[1 · Quote<br/>lock a price] --> C[2 · Create<br/>open the activity]
    C --> A{3 · Act}
    A -->|on-ramp| Pay[Pay fiat off-platform<br/>URL or deposit instructions]
    A -->|off-ramp / swap| Tx[Execute the on-chain tx<br/>Kii Wallet or external wallet]
    Pay --> T[4 · Track<br/>poll display_status]
    Tx --> T
    T --> Done[fulfilled]
```

1. **Quote** — ask for a signed price for the amount you want to move. The quote is an envelope (`quote_payload` + `signature`) you pass back **verbatim** when you create the activity.
2. **Create** — open the activity. Off-ramp and swap return the on-chain **transactions** you must execute; on-ramp returns **fiat payment instructions**.
3. **Act** — this is where the flows diverge (see the table). On-ramp: pay fiat. Off-ramp/swap: execute the returned transaction.
4. **Track** — poll the activity and watch `display_status` until it reaches a terminal value: `fulfilled`, `canceled`, `failed`, `refunded`, or `expired`. (Non-terminal: `pending`, `processing`.)

**DEX swap** does not follow this loop — it has no activity to create or track. See [Creating a DEX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-a-dex-swap).

## How the four compare

|                         | On-ramp                                                                               | Off-ramp                              | FX swap                                                           | DEX swap                                  |
| ----------------------- | ------------------------------------------------------------------------------------- | ------------------------------------- | ----------------------------------------------------------------- | ----------------------------------------- |
| **Direction**           | Fiat → Crypto                                                                         | Crypto → Fiat                         | Crypto → Crypto                                                   | Crypto → Crypto (cross-chain)             |
| **Quote**               | `GET …/products-providers/{id}/quote`                                                 | `GET …/products-providers/{id}/quote` | `GET …/instruments/{id}/quote`                                    | `POST /market/v1/dex/quote`               |
| **Create**              | <p><code>POST …/products-providers/{id}/onramp</code><br><em>(market module)</em></p> | `POST /tickets/v1/offramp`            | `POST /tickets/v1/swap`                                           | — *(no activity)*                         |
| **How the user acts**   | Pay fiat off-platform                                                                 | Execute on-chain tx                   | Execute on-chain tx                                               | Sign & broadcast the returned tx yourself |
| **On-chain signing**    | None                                                                                  | `execute` (delegated) or self-sign    | `execute` (delegated) or self-sign                                | Self-sign (external wallet)               |
| **Destination needed**  | `destination_id` (receives crypto)                                                    | `withdraw_destination_id` (bank)      | Optional `withdraw_destination_id` (defaults to executing wallet) | None                                      |
| **Tracking**            | Poll `display_status`                                                                 | Poll `display_status`                 | Poll `display_status`                                             | On-chain only (watch the tx hash)         |
| **KYC / activity**      | KYC-gated · creates activity                                                          | KYC-gated · creates activity          | KYC-gated · creates activity                                      | No KYC · no activity                      |
| **Provider settlement** | Always                                                                                | Always                                | Sometimes (auto-fulfill or OTC)                                   | On-chain DEX (routed via LiFi)            |

## Discovering rails and IDs

Each create call needs IDs — a `products_provider_id` or `instrument_id`, your `account_id`, and sometimes a destination. Here is where they come from. All base URLs are `https://backend.pay.kiichain.io` (production).

### Your user and account IDs

`GET /users/v1/users/me` returns both in one call — `user.id` is your **`userId`** and `account.id` is your active **`accountId`**.

```bash
curl https://backend.pay.kiichain.io/users/v1/users/me \
  -H "Authorization: APIKey $KII_API_KEY"
```

An account can have more than one; `GET /accounts/v1/users/{userId}/accounts` lists them all as full `Account` objects (each with an `id`).

### On-ramp & off-ramp rails — products-providers

A **products-provider** pairs a product (a crypto token, or a fiat asset) with a provider, in one direction. Its `id` is the `products_provider_id` you use for the quote and the create call.

```bash
curl "https://backend.pay.kiichain.io/market/v1/products-providers?account_id=$KII_ACCOUNT_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

Each entry in `productsProviders[]` carries:

<table><thead><tr><th width="220">Field</th><th>Meaning</th></tr></thead><tbody><tr><td><code>id</code></td><td>The <code>products_provider_id</code> for quotes and creation.</td></tr><tr><td><code>type</code></td><td><strong>Direction</strong> — <code>"onramp"</code> or <code>"offramp"</code>. This is how you tell them apart.</td></tr><tr><td><code>product</code></td><td>The crypto leg. <code>product.chainToken</code> gives the token (<code>token.symbol</code>, <code>token.decimals</code>, <code>contractAddress</code>) and chain (<code>chain.chainId</code>); <code>product.type</code> is <code>"crypto"</code> or <code>"fiat"</code>.</td></tr><tr><td><code>fiatAsset</code></td><td>The fiat leg — <code>{ code, name, symbol }</code> (ISO 4217).</td></tr><tr><td><code>provider</code></td><td>The provider — <code>provider.name</code>, etc.</td></tr><tr><td><code>enabled</code></td><td>Whether the rail is currently available.</td></tr><tr><td><code>availability</code></td><td>Whether <strong>your account</strong> can use the rail: <code>allowed</code>, and a <code>reason</code> when it can't. See <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc#what-your-account-can-use">What your account can use</a>.</td></tr></tbody></table>

Min/max amounts live on a separate call: `GET /market/v1/products-providers/{id}/limits` returns `limits` with `min_fiat_amount`, `max_fiat_amount`, `min_token_amount`, `max_token_amount`.

### FX swap pairs — instruments

An **instrument** is a swap pair (base → quote). Its `id` is the `instrument_id`.

```bash
curl "https://backend.pay.kiichain.io/market/v1/instruments?account_id=$KII_ACCOUNT_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

Each entry in `instruments[]` has `id`, `name`, `description`, `productBase` (input) and `productQuote` (output) — each a full `Product` with its `chainToken`/`fiatAsset` — plus `provider`, `spread`, `enabled`, and `availability` (whether your account can use the pair, see [What your account can use](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc#what-your-account-can-use)). Limits come from `GET /market/v1/instruments/{id}/limits?side=buy|sell` (`minBaseAmount`, `maxBaseAmount`, `minQuoteAmount`, `maxQuoteAmount`).

### Fiat assets

`GET /market/v1/fiat-assets` lists supported fiat currencies (`fiat_assets[]` of `{ code, name, symbol }`); `GET /market/v1/fiat-assets/{code}` fetches one by its 3-letter code.

### Withdrawal destinations

Off-ramp needs a **bank** destination (`withdraw_destination_id`); on-ramp needs a **wallet** destination that receives the crypto (`destination_id`). Both come from the same list:

```bash
curl "https://backend.pay.kiichain.io/accounts/v1/accounts/$KII_ACCOUNT_ID/withdrawal_destinations" \
  -H "Authorization: APIKey $KII_API_KEY"
```

Each entry in `destinations[]` has `id`, `type` (`"bank"` or `"wallet"`), `name` (your label), `rail_code` / `rail_version`, `country`, `status` (confirmed or not), `identifier`, and a rail-specific `payload`.

To **create** one, first read the rail schema so you know which fields the `payload` needs, then register and confirm it:

1. `GET /accounts/v1/rails/schemas?country={country}` → `schemas[]` of `{ rail_code, rail_version, country, type, schema }`, where `schema.fields[]` describes each required field (`name`, `type`, `optional`, `pattern`, `options`).
2. `POST /accounts/v1/accounts/{accountId}/withdrawal_destinations` with `{ rail_code, rail_version, payload, name }`.
3. `POST /accounts/v1/accounts/{accountId}/withdrawal_destinations/{destinationId}:confirm` with the `{ verify_code }` sent to you after registration. Skip this step on a [subaccount](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/subaccounts#withdrawal-destinations): its destinations are confirmed on registration and no code is sent.

### DEX-enabled tokens

DEX token discovery is **public** (no API key). Filter with `mode=dex` to get only DEX-enabled tokens:

```bash
curl "https://backend.pay.kiichain.io/blockchain/v1/chains/tokens/all?mode=dex"
```

`chains_tokens[]` are `ChainToken` objects: `token` (`symbol`, `decimals`, `name`, `logo`), `chain` (`chain_id`, `type`, `name`), `native`, `contract_address` (absent for native tokens), and `enabled_dex`.

## The guides

* [Creating an on-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-on-ramp) — fiat → crypto.
* [Creating an off-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-off-ramp) — crypto → fiat.
* [Creating an FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) — crypto → crypto, custodial.
* [Creating a DEX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-a-dex-swap) — crypto → crypto, permissionless.


# Quick Start

End-to-end walkthroughs for the four KiiChain Pay value flows — on-ramp, off-ramp, FX swap, and permissionless DEX swap.

Each guide takes one flow from start to finish with copy-pasteable `curl`. For the concepts behind them — the shared quote → create → act → track loop, the comparison table, and how to discover the IDs each call needs — start with the [Guides overview](https://docs.kiiglobal.io/docs/kiichain-pay/guides).

* [Creating an on-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-on-ramp) — move **fiat → crypto**. Pay off-platform; no on-chain signing.
* [Creating an off-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-off-ramp) — move **crypto → fiat** into a bank account.
* [Creating an FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) — swap **crypto → crypto** as a custodial, tracked activity.
* [Creating a DEX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-a-dex-swap) — swap **crypto → crypto** on-chain, permissionless — no account, KYC, or activity.


# Creating an on-ramp

Move fiat into crypto with KiiChain Pay. Quote a rail, open the on-ramp, have the user pay off-platform, and track the activity to completion.

An **on-ramp** converts **fiat into crypto**. You quote a rail, open the on-ramp, and the user pays fiat off-platform — through a provider checkout URL or by depositing to a set of instructions (a PIX key, a CLABE, a wallet address). There is **no on-chain transaction for you to sign**: once the fiat lands, the provider settles the crypto and the activity moves to `fulfilled`.

## At a glance

<table><thead><tr><th width="200">Property</th><th>Value</th></tr></thead><tbody><tr><td><strong>Direction</strong></td><td>Fiat → Crypto</td></tr><tr><td><strong>Create endpoint</strong></td><td><code>POST /market/v1/products-providers/{id}/onramp</code> (market module)</td></tr><tr><td><strong>User acts</strong></td><td>Off-chain — pays fiat via a URL or deposit instructions</td></tr><tr><td><strong>On-chain signing</strong></td><td>None</td></tr><tr><td><strong>You need</strong></td><td>A KYC-verified account, an on-ramp <code>products_provider_id</code>, a <code>destination_id</code> (wallet that receives the crypto), and a write-enabled API key</td></tr><tr><td><strong>Tracks via</strong></td><td><code>display_status</code> on the activity</td></tr></tbody></table>

## Prerequisites

* A KiiChain Pay account that has completed [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc).
* An [API key](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys); write calls must be signed (see [Sign write requests](https://docs.kiiglobal.io/pages/Xi9e9VnluBBSJsek157L#4.-sign-write-requests)).
* Your `account_id` and a **wallet destination** that will receive the crypto — see [Discovering rails & IDs](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids). The examples assume `KII_API_KEY`, `KII_ACCOUNT_ID`, and `KII_DESTINATION_ID` are set.

{% hint style="info" %}
Check the rail's `availability.allowed` before quoting. When it's `false`, its `reason` tells you what's missing, such as KYC or a country the fiat requires — see [What your account can use](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc#what-your-account-can-use). Some providers also require their own KYC in certain countries. If so, the create call will tell you — see [Provider KYC / KYB](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc#provider-kyc-kyb).
{% endhint %}

## Step 1 — Get a quote

Find an **on-ramp** rail (a `products-provider` whose `type` is `"onramp"`) and quote it for the **fiat amount** the user wants to spend. For an on-ramp the `amount` is fiat in decimal units.

```bash
curl "https://backend.pay.kiichain.io/market/v1/products-providers/$KII_PP_ID/quote?amount=100&account_id=$KII_ACCOUNT_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

The response is a signed `quote` envelope. You pass it back **unchanged** in the next step.

```json
{
  "quote": {
    "quote_payload": {
      "id": "9b2c1d0e-3f4a-5b6c-7d8e-9f0a1b2c3d4e",
      "account_id": "a1b2c3d4-e5f6-7a8b-9c0d-1e2f3a4b5c6d",
      "target_id": "7f6e5d4c-3b2a-1c0d-9e8f-7a6b5c4d3e2f",
      "target_type": "onramp",
      "asset_in": { "code": "BRL", "type": "fiat", "amount": "100" },
      "asset_out": { "code": "USDC", "type": "crypto", "amount": "19500000" },
      "product_fee": { "code": "BRL", "type": "fiat", "amount": "1.5" },
      "price": "0.195",
      "expiration_date": "2026-07-15T18:45:00Z",
      "exp": 1784138700
    },
    "signature": "MEUCIQD…"
  }
}
```

{% hint style="warning" %}
Quotes expire (`expiration_date` / `exp`). Create the on-ramp promptly, and request a fresh quote if it lapses.
{% endhint %}

## Step 2 — Create the on-ramp

Send the quote, your `account_id`, and the `destination_id` (the wallet that receives the crypto) to the on-ramp endpoint. This is a **write** request, so it must be signed.

```bash
curl -X POST "https://backend.pay.kiichain.io/market/v1/products-providers/$KII_PP_ID/onramp" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{
    "account_id": "'"$KII_ACCOUNT_ID"'",
    "destination_id": "'"$KII_DESTINATION_ID"'",
    "quote": { … the quote object from step 1 … }
  }'
```

The response gives you the new activity's `ticket_id` and **one** of two payment payloads:

**A checkout URL** (`url_payload`) — send the user to a hosted provider flow (e.g. a card checkout):

```json
{
  "ticket_id": "c0ffee00-1234-5678-9abc-def012345678",
  "url_payload": {
    "url": "https://buy.provider.example/session/abc123",
    "expires_at": 1784138700
  }
}
```

**Deposit instructions** (`deposit_payload`) — show the user where to send the fiat:

```json
{
  "ticket_id": "c0ffee00-1234-5678-9abc-def012345678",
  "deposit_payload": {
    "deposit_key": "710969000000431628",
    "deposit_code": "00020126580014br.gov.bcb.pix…"
  }
}
```

`deposit_key` is the rail-agnostic destination (a PIX key, a CLABE, a bank reference); `deposit_code` is an optional copy-and-paste / QR value (for example, a PIX BR Code). Render whichever fields are present.

## Step 3 — The user pays

The user completes payment off-platform — on the checkout URL, or by sending fiat to the deposit instructions. **Nothing to sign on your side.** KiiChain Pay detects the incoming payment and advances the activity through provider processing.

## Step 4 — Track to completion

Poll the activity by its `ticket_id` and watch `display_status`.

```bash
curl "https://backend.pay.kiichain.io/tickets/v1/$KII_TICKET_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

```json
{
  "ticket": {
    "id": "c0ffee00-1234-5678-9abc-def012345678",
    "type": "onramp",
    "amount_usd": "19.5",
    "display_status": "processing"
  }
}
```

`display_status` moves `pending` → `processing` → **`fulfilled`** once the provider settles the crypto to the destination wallet. Terminal values are `fulfilled`, `failed`, `canceled`, `refunded`, and `expired`. If you need to re-show the payment instructions while the activity is still open, call `GET /tickets/v1/{ticketId}/pending_user_actions` — for an on-ramp it returns the `url_payload` again.

## Full example

An end-to-end on-ramp with deposit instructions, using the signing helper from [Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys#reference-implementation) (`kiiFetch` handles the `Authorization`, `x-timestamp` and `x-signature` headers).

```typescript
import { kiiFetch } from "./kii-pay"; // the signed-fetch helper

const ACCOUNT_ID = process.env.KII_ACCOUNT_ID!;
const DESTINATION_ID = process.env.KII_DESTINATION_ID!; // wallet that receives the crypto

// 1 · Find an on-ramp rail (BRL → USDC in this example).
const { productsProviders } = await kiiFetch(
  "GET",
  `/market/v1/products-providers?account_id=${ACCOUNT_ID}`,
).then((r) => r.json());

const rail = productsProviders.find(
  (pp: any) =>
    pp.type === "onramp" &&
    pp.enabled &&
    pp.availability.allowed &&
    pp.fiatAsset.code === "BRL" &&
    pp.product.chainToken?.token.symbol === "USDC",
);
if (!rail) throw new Error("no matching on-ramp rail");

// 2 · Quote it for the fiat amount the user will pay (decimals).
const { quote } = await kiiFetch(
  "GET",
  `/market/v1/products-providers/${rail.id}/quote?amount=100&account_id=${ACCOUNT_ID}`,
).then((r) => r.json());

// 3 · Open the on-ramp.
const created = await kiiFetch(
  "POST",
  `/market/v1/products-providers/${rail.id}/onramp`,
  { account_id: ACCOUNT_ID, destination_id: DESTINATION_ID, quote },
).then((r) => r.json());

const ticketId = created.ticket_id;
if (created.deposit_payload) {
  console.log("Pay to:", created.deposit_payload.deposit_key);
  console.log("Copy-paste / QR:", created.deposit_payload.deposit_code);
} else {
  console.log("Complete payment at:", created.url_payload.url);
}

// 4 · Poll until the activity is terminal.
const TERMINAL = new Set(["fulfilled", "failed", "canceled", "refunded", "expired"]);
let status = "pending";
while (!TERMINAL.has(status)) {
  await new Promise((r) => setTimeout(r, 5000));
  const { ticket } = await kiiFetch("GET", `/tickets/v1/${ticketId}`).then((r) =>
    r.json(),
  );
  status = ticket.display_status;
  console.log("status:", status);
}
console.log(status === "fulfilled" ? "On-ramp complete 🎉" : `Ended as ${status}`);
```

## Related

* [Creating an off-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-off-ramp) — the reverse: crypto → fiat.
* [Guides overview](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids) — discovering rails, destinations, and IDs.
* [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc) — account levels, limits, and provider verification.


# Creating an off-ramp

Move crypto into a bank account with KiiChain Pay. Quote a rail, open the off-ramp, execute the on-chain transaction, and track the activity until the fiat lands.

An **off-ramp** converts **crypto into fiat**, paid out to a bank account. Unlike an on-ramp, the user (or your backend, via a delegated wallet) must **execute an on-chain transaction** to move the crypto into settlement. After that, the activity passes an AML check and provider processing before the fiat is sent to the destination bank account.

## At a glance

<table><thead><tr><th width="200">Property</th><th>Value</th></tr></thead><tbody><tr><td><strong>Direction</strong></td><td>Crypto → Fiat</td></tr><tr><td><strong>Create endpoint</strong></td><td><code>POST /tickets/v1/offramp</code></td></tr><tr><td><strong>User acts</strong></td><td>On-chain — executes the returned transaction</td></tr><tr><td><strong>On-chain signing</strong></td><td>Delegated Kii Wallet (server-side) or external wallet (self-sign)</td></tr><tr><td><strong>You need</strong></td><td>A KYC-verified account, an off-ramp <code>products_provider_id</code>, a <strong>bank</strong> <code>withdraw_destination_id</code>, and a delegated Kii Wallet (for the primary path)</td></tr><tr><td><strong>Tracks via</strong></td><td><code>display_status</code> on the activity</td></tr></tbody></table>

## Prerequisites

* A KiiChain Pay account that has completed [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc), with its [Kii Wallet](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) [delegated](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) if you want KiiChain Pay to sign the on-chain step for you.
* An [API key](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys) with `tickets.tickets.write` and (for the delegated path) `blockchain.transactions.execute`; write calls must be signed.
* Your `account_id`, your on-chain wallet address, and a **bank withdrawal destination**.

### Set up a bank withdrawal destination

The fiat payout goes to a confirmed **bank** destination. If you don't have one yet, create it (see [Discovering rails & IDs](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids) for the full flow):

1. `GET /accounts/v1/rails/schemas?country={country}` — read the bank rail's required `payload` fields.
2. `POST /accounts/v1/accounts/{accountId}/withdrawal_destinations` — register it with `{ rail_code, rail_version, payload, name }`.
3. `POST …/withdrawal_destinations/{destinationId}:confirm` — confirm with the `verify_code` you receive. On a [subaccount](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/subaccounts#withdrawal-destinations) skip this step: the destination is confirmed on registration.

Then list your destinations and pick the `id` of the `"bank"` one — that's your `withdraw_destination_id`. The examples assume `KII_API_KEY`, `KII_ACCOUNT_ID`, `KII_ADDRESS` (your `0x…` wallet address), and `KII_WITHDRAW_DEST_ID` are set.

## Step 1 — Get a quote

Find an **off-ramp** rail (a `products-provider` whose `type` is `"offramp"`) and quote it for the **crypto amount** you want to sell. For an off-ramp the `amount` is crypto in **atoms** (smallest unit).

```bash
# 25 USDC (6 decimals) → 25000000 atoms
curl "https://backend.pay.kiichain.io/market/v1/products-providers/$KII_PP_ID/quote?amount=25000000&account_id=$KII_ACCOUNT_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

The response is a signed `quote` envelope with `target_type: "offramp"`; pass it back unchanged in the next step. Quotes expire — check `expiration_date` / `exp`.

## Step 2 — Create the off-ramp

Create the activity with the quote, your `account_id`, `user_chain_address`, and the bank `withdraw_destination_id`. This is a signed **write** request.

```bash
curl -X POST "https://backend.pay.kiichain.io/tickets/v1/offramp" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{
    "products_provider_id": "'"$KII_PP_ID"'",
    "account_id": "'"$KII_ACCOUNT_ID"'",
    "user_chain_address": "'"$KII_ADDRESS"'",
    "withdraw_destination_id": "'"$KII_WITHDRAW_DEST_ID"'",
    "quote": { … the quote object from step 1 … }
  }'
```

The response holds the new `ticket` **and** the `transactions` you must execute on-chain to fund the off-ramp:

```json
{
  "ticket": {
    "id": "c0ffee00-1234-5678-9abc-def012345678",
    "type": "offramp",
    "display_status": "pending"
  },
  "transactions": [
    {
      "evm": {
        "type": "kiifulfillment",
        "chain_id": "1336",
        "from": "0x1A2b3C4d5E6f7A8b9C0d1E2f3A4b5C6d7E8f9A0b",
        "to": "0xRouterContractAddress…",
        "value": "0",
        "data": "0xa9059cbb…"
      }
    }
  ]
}
```

{% hint style="info" %}
If the token needs an ERC-20 allowance, an `approval` transaction is prepended to the list. Execute the transactions **in order**.
{% endhint %}

## Step 3 — Execute the transaction

KiiChain Pay does **not** sign for you at create time — the transactions come back unsigned. You execute them one of two ways.

### With a delegated Kii Wallet (recommended)

Hand the returned `transactions` straight to the blockchain execute endpoint. KiiChain Pay signs and broadcasts them from your delegated Kii Wallet, with gas sponsored. This is a signed **write** request.

```bash
curl -X POST "https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_ACCOUNT_ID/transactions/execute" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{ "transactions": [ … the transactions from step 2 … ] }'
```

```json
{ "txHashes": ["0x9f8e7d6c5b4a…"] }
```

A hash of `"0x00"` in the array means that transaction failed to broadcast.

{% hint style="warning" %}
This path requires a **delegated** Kii Wallet. Without delegation the call errors — see [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access).
{% endhint %}

### With an external wallet

If the user holds their own keys, don't call KiiChain Pay to sign. Take each `evm` transaction's `chain_id`, `to`, `value`, and `data`, then sign and broadcast it with your own signer (for example, viem's `sendTransaction`). KiiChain Pay observes the on-chain event and advances the activity.

You can re-fetch the outstanding transaction at any time while the activity is open with `GET /tickets/v1/{ticketId}/pending_user_actions` (it returns a `transaction_payload`).

## Step 4 — Track to completion

Poll the activity and watch `display_status`.

```bash
curl "https://backend.pay.kiichain.io/tickets/v1/$KII_TICKET_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

After your transaction confirms, the activity runs an AML check, then provider processing, then pays out — `display_status` moves through `processing` to **`fulfilled`** when the fiat is sent to the bank account. If the AML check or provider rejects the transfer, the crypto is returned and the activity ends as **`refunded`** (or `canceled` / `failed`). While the activity is awaiting on-chain confirmation you can cancel it — `GET /tickets/v1/{ticketId}/user_txs` returns a `cancel` transaction when that action is available.

## Full example

End-to-end off-ramp via a delegated Kii Wallet, using the `kiiFetch` signing helper from [Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys#reference-implementation).

```typescript
import { kiiFetch } from "./kii-pay";

const ACCOUNT_ID = process.env.KII_ACCOUNT_ID!;
const ADDRESS = process.env.KII_ADDRESS!; // your 0x… wallet address
const WITHDRAW_DEST_ID = process.env.KII_WITHDRAW_DEST_ID!; // confirmed bank destination

// 1 · Find an off-ramp rail (USDC → BRL) and quote 25 USDC (atoms).
const { products_providers } = await kiiFetch(
  "GET",
  `/market/v1/products-providers?account_id=${ACCOUNT_ID}`,
).then((r) => r.json());

const rail = products_providers.find(
  (pp: any) =>
    pp.type === "offramp" &&
    pp.enabled &&
    pp.product.chain_token?.token.symbol === "USDC" &&
    pp.fiat_asset.code === "BRL",
);
if (!rail) throw new Error("no matching off-ramp rail");

const { quote } = await kiiFetch(
  "GET",
  `/market/v1/products-providers/${rail.id}/quote?amount=25000000&account_id=${ACCOUNT_ID}`,
).then((r) => r.json());

// 2 · Create the off-ramp — returns the ticket and the tx to execute.
const { ticket, transactions } = await kiiFetch("POST", "/tickets/v1/offramp", {
  products_provider_id: rail.id,
  account_id: ACCOUNT_ID,
  user_chain_address: ADDRESS,
  withdraw_destination_id: WITHDRAW_DEST_ID,
  quote,
}).then((r) => r.json());

// 3 · Execute on-chain from the delegated Kii Wallet.
const { txHashes } = await kiiFetch(
  "POST",
  `/blockchain/v1/accounts/${ACCOUNT_ID}/transactions/execute`,
  {
    transactions,
  },
).then((r) => r.json());

// A "0x00" hash marks a transaction that failed to broadcast. Stop if any did,
// and only keep the ones that actually went out.
const failed = txHashes.filter((h: string) => h === "0x00");
if (failed.length > 0) {
  throw new Error(
    `${failed.length} of ${txHashes.length} transaction(s) failed to broadcast`,
  );
}
const broadcast = txHashes.filter((h: string) => h !== "0x00");
console.log("broadcast:", broadcast);

// 4 · Poll until terminal.
const TERMINAL = new Set([
  "fulfilled",
  "failed",
  "canceled",
  "refunded",
  "expired",
]);
let status = ticket.display_status;
while (!TERMINAL.has(status)) {
  await new Promise((r) => setTimeout(r, 5000));
  const res = await kiiFetch("GET", `/tickets/v1/${ticket.id}`).then((r) =>
    r.json(),
  );
  status = res.ticket.display_status;
  console.log("status:", status);
}
console.log(
  status === "fulfilled" ? "Fiat on its way 🎉" : `Ended as ${status}`,
);
```

## Related

* [Creating an on-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-on-ramp) — the reverse: fiat → crypto.
* [Creating an FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) — same create-and-execute shape, crypto → crypto.
* [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) — server-side signing for the on-chain step.
* [Guides overview](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids) — discovering rails, destinations, and IDs.


# Creating an FX swap

Swap one crypto asset for another as a custodial, tracked KiiChain Pay activity. Quote an instrument, open the swap, execute the on-chain transaction, and track it to completion.

An **FX swap** exchanges one crypto asset for another as a **custodial, tracked activity**. You quote an **instrument** (a swap pair), open the swap, and execute an on-chain transaction. By default the swapped funds land on the wallet that executes the trade; you can optionally redirect them to a registered destination. Depending on the instrument, the swap either **settles automatically** on-chain or routes through provider settlement.

## At a glance

<table><thead><tr><th width="200">Property</th><th>Value</th></tr></thead><tbody><tr><td><strong>Direction</strong></td><td>Crypto → Crypto</td></tr><tr><td><strong>Create endpoint</strong></td><td><code>POST /tickets/v1/swap</code></td></tr><tr><td><strong>User acts</strong></td><td>On-chain — executes the returned transaction</td></tr><tr><td><strong>On-chain signing</strong></td><td>Delegated Kii Wallet (server-side) or external wallet (self-sign)</td></tr><tr><td><strong>You need</strong></td><td>A KYC-verified account, an <code>instrument_id</code>, a delegated Kii Wallet (for the primary path), and optionally a <code>withdraw_destination_id</code> to redirect the output</td></tr><tr><td><strong>Tracks via</strong></td><td><code>display_status</code> on the activity</td></tr></tbody></table>

## Prerequisites

* A KiiChain Pay account that has completed [KYC](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/kyc), with its [Kii Wallet](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) [delegated](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) for the primary (server-side signing) path.
* An [API key](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys) with `tickets.tickets.write` and (for the delegated path) `blockchain.transactions.execute`; write calls must be signed.
* Your `account_id`, your on-chain wallet address, and an `instrument_id` — see [Discovering rails & IDs](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids). The examples assume `KII_API_KEY`, `KII_ACCOUNT_ID`, `KII_ADDRESS`, and `KII_INSTRUMENT_ID` are set.

## Step 1 — Get a quote

Quote the instrument for the **crypto amount** in **atoms**, and specify a `side` — `buy` or `sell` — relative to the instrument's quote asset.

```bash
curl "https://backend.pay.kiichain.io/market/v1/instruments/$KII_INSTRUMENT_ID/quote?amount=25000000&account_id=$KII_ACCOUNT_ID&side=buy" \
  -H "Authorization: APIKey $KII_API_KEY"
```

The response is a signed `quote` envelope with `target_type: "swap"`; pass it back unchanged. Quotes expire — check `expiration_date` / `exp`.

{% hint style="info" %}
An instrument has a `product_base` (input) and `product_quote` (output). Use `GET /market/v1/instruments/{id}/limits?side=sell` to read `min_base_amount` / `max_base_amount` before quoting.
{% endhint %}

## Step 2 — Create the swap

Create the activity with the quote, your `account_id`, and `user_chain_address`. This is a signed **write** request.

```bash
curl -X POST "https://backend.pay.kiichain.io/tickets/v1/swap" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{
    "instrument_id": "'"$KII_INSTRUMENT_ID"'",
    "account_id": "'"$KII_ACCOUNT_ID"'",
    "user_chain_address": "'"$KII_ADDRESS"'",
    "quote": { … the quote object from step 1 … }
  }'
```

{% hint style="info" %}
**Where the swapped funds land.** By default the output asset goes to the wallet that executes the transaction (`user_chain_address`). To send it somewhere else, add an optional `withdraw_destination_id` — the `id` of a registered [withdrawal destination](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids) — and the funds settle there instead, regardless of which wallet executed the trade.
{% endhint %}

The response holds the new `ticket` and the `transactions` to execute on-chain:

```json
{
  "ticket": {
    "id": "c0ffee00-1234-5678-9abc-def012345678",
    "type": "swap",
    "display_status": "pending"
  },
  "transactions": [
    {
      "evm": {
        "type": "kiisettlement",
        "chain_id": "1336",
        "from": "0x1A2b3C4d5E6f7A8b9C0d1E2f3A4b5C6d7E8f9A0b",
        "to": "0xSettlementContractAddress…",
        "value": "0",
        "data": "0x38ed1739…"
      }
    }
  ]
}
```

As with off-ramp, an `approval` transaction is prepended when the token needs an ERC-20 allowance — execute the list **in order**.

## Step 3 — Execute the transaction

The transactions come back unsigned; execute them one of two ways (same as an off-ramp).

### With a delegated Kii Wallet (recommended)

```bash
curl -X POST "https://backend.pay.kiichain.io/blockchain/v1/accounts/$KII_ACCOUNT_ID/transactions/execute" \
  -H "Authorization: APIKey $KII_API_KEY" \
  -H "x-timestamp: $KII_TIMESTAMP" \
  -H "x-signature: $KII_SIGNATURE" \
  -H "Content-Type: application/json" \
  -d '{ "transactions": [ … the transactions from step 2 … ] }'
```

KiiChain Pay signs and broadcasts from your delegated Kii Wallet (gas sponsored) and returns `{ "txHashes": [...] }`. A `"0x00"` entry means that transaction failed.

### With an external wallet

Sign and broadcast each `evm` transaction (`chain_id`, `to`, `value`, `data`) yourself. Re-fetch the outstanding transaction any time with `GET /tickets/v1/{ticketId}/pending_user_actions`.

## Step 4 — Track to completion

Poll the activity and watch `display_status`.

```bash
curl "https://backend.pay.kiichain.io/tickets/v1/$KII_TICKET_ID" \
  -H "Authorization: APIKey $KII_API_KEY"
```

After your transaction confirms, one of two things happens:

* **Auto-fulfillment** — if the settlement contract fills the swap directly, the activity goes straight to **`fulfilled`**.
* **Provider settlement** — otherwise it routes through provider processing (`processing`) before reaching **`fulfilled`**.

Terminal values are `fulfilled`, `failed`, `canceled`, `refunded`, and `expired`; a failed settlement returns your funds as `refunded`.

## Full example

End-to-end custodial swap via a delegated Kii Wallet, using the `kiiFetch` signing helper from [Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys#reference-implementation).

```typescript
import { kiiFetch } from "./kii-pay";

const ACCOUNT_ID = process.env.KII_ACCOUNT_ID!;
const ADDRESS = process.env.KII_ADDRESS!;
const INSTRUMENT_ID = process.env.KII_INSTRUMENT_ID!;

// 1 · Quote the instrument (buy 25 units of the quote asset, in atoms).
const { quote } = await kiiFetch(
  "GET",
  `/market/v1/instruments/${INSTRUMENT_ID}/quote?amount=25000000&account_id=${ACCOUNT_ID}&side=buy`,
).then((r) => r.json());

// 2 · Create the swap — returns the ticket and the tx to execute.
const { ticket, transactions } = await kiiFetch("POST", "/tickets/v1/swap", {
  instrument_id: INSTRUMENT_ID,
  account_id: ACCOUNT_ID,
  user_chain_address: ADDRESS,
  quote,
}).then((r) => r.json());

// 3 · Execute on-chain from the delegated Kii Wallet.
const { txHashes } = await kiiFetch(
  "POST",
  `/blockchain/v1/accounts/${ACCOUNT_ID}/transactions/execute`,
  {
    transactions,
  },
).then((r) => r.json());

// A "0x00" hash marks a transaction that failed to broadcast. Stop if any did,
// and only keep the ones that actually went out.
const failed = txHashes.filter((h: string) => h === "0x00");
if (failed.length > 0) {
  throw new Error(
    `${failed.length} of ${txHashes.length} transaction(s) failed to broadcast`,
  );
}
const broadcast = txHashes.filter((h: string) => h !== "0x00");
console.log("broadcast:", broadcast);

// 4 · Poll until terminal.
const TERMINAL = new Set([
  "fulfilled",
  "failed",
  "canceled",
  "refunded",
  "expired",
]);
let status = ticket.display_status;
while (!TERMINAL.has(status)) {
  await new Promise((r) => setTimeout(r, 5000));
  const res = await kiiFetch("GET", `/tickets/v1/${ticket.id}`).then((r) =>
    r.json(),
  );
  status = res.ticket.display_status;
  console.log("status:", status);
}
console.log(status === "fulfilled" ? "Swap complete 🎉" : `Ended as ${status}`);
```

## Related

* [Creating a DEX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-a-dex-swap) — the permissionless, on-chain alternative (no activity).
* [Creating an off-ramp](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-off-ramp) — same create-and-execute shape, crypto → fiat.
* [Privy delegated access](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access) — server-side signing for the on-chain step.
* [Guides overview](https://docs.kiiglobal.io/docs/kiichain-pay/guides#discovering-rails-and-ids) — discovering instruments and IDs.


# Creating a DEX swap

Swap tokens on-chain through a DEX from any wallet — permissionless, with no account, KYC, or activity. Quote the swap, approve if needed, then sign and broadcast the returned transaction yourself.

{% hint style="warning" %}
DEX swaps will change heavily in the upcoming months, especially once the beta phase is done.
{% endhint %}

A **DEX swap** exchanges one token for another **on-chain**, routed through a decentralized exchange. It is **permissionless**: no account, no KYC, and **no activity** is created. You ask for a quote, and KiiChain Pay returns a ready-to-sign transaction (plus any ERC-20 approval) that **you sign and broadcast from your own wallet**. Routing is handled for you across chains.

{% hint style="info" %}
This is different from an [FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap). An FX swap is a **custodial, tracked activity** (a ticket) that KiiChain Pay settles for you. A DEX swap is a plain on-chain swap you broadcast yourself — there is nothing to track through `display_status`, only the on-chain transaction.
{% endhint %}

## At a glance

<table><thead><tr><th width="200">Property</th><th>Value</th></tr></thead><tbody><tr><td><strong>Direction</strong></td><td>Crypto → Crypto (cross-chain)</td></tr><tr><td><strong>Quote endpoint</strong></td><td><code>POST /market/v1/dex/quote</code> (public)</td></tr><tr><td><strong>You act</strong></td><td>Sign &#x26; broadcast the returned transaction with your own wallet</td></tr><tr><td><strong>Account / KYC</strong></td><td>None</td></tr><tr><td><strong>Activity</strong></td><td>None — settles fully on-chain</td></tr><tr><td><strong>Tracking</strong></td><td>On-chain only (watch the transaction hash)</td></tr></tbody></table>

## Prerequisites

* A wallet on the source chain with the tokens to swap **and** native gas to pay for the transaction. (Gas sponsorship applies only to Kii Wallets, not to self-custody DEX swaps.)
* The token identifiers for both sides. Discover DEX-enabled tokens from the **public** endpoint:

```bash
curl "https://backend.pay.kiichain.io/blockchain/v1/chains/tokens/all?mode=dex"
```

Each `ChainToken` gives you the `chain.chain_id`, the `token.symbol` / `token.decimals`, whether it's `native`, and its `contract_address` (absent for native tokens). Use `contract_address` as the `denom` for ERC-20 tokens.

## Step 1 — Get a DEX quote

Post the source asset (with amount, in base units) and the destination asset. Include your `sender_address` so the returned transaction is built for your wallet.

```bash
curl -X POST "https://backend.pay.kiichain.io/market/v1/dex/quote" \
  -H "Content-Type: application/json" \
  -d '{
    "asset_in": {
      "denom": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
      "chain_id": "1",
      "amount": "25000000"
    },
    "asset_out": {
      "denom": "0xdAC17F958D2ee523a2206206994597C13D831ec7",
      "chain_id": "1"
    },
    "sender_address": "0x1A2b3C4d5E6f7A8b9C0d1E2f3A4b5C6d7E8f9A0b"
  }'
```

The response describes the route and — crucially — includes an **unsigned transaction** to broadcast:

```json
{
  "does_swap": true,
  "estimated_amount_out": "24980000",
  "txs_required": 1,
  "usd_amount_in": "25.00",
  "usd_amount_out": "24.98",
  "swap_price_impact_percent": "0.08",
  "provider": "lifi",
  "evm_tx": "0x02f8b20180…",
  "approval_token": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
  "approval_address": "0xLiFiRouterSpender…",
  "approval_amount": "25000000"
}
```

<table><thead><tr><th width="230">Field</th><th>Meaning</th></tr></thead><tbody><tr><td><code>evm_tx</code></td><td>An RLP-serialized <strong>unsigned EIP-1559 transaction</strong> (0x hex) — the swap itself, ready for you to sign and broadcast.</td></tr><tr><td><code>estimated_amount_out</code></td><td>Minimum output after slippage, in the destination token's base units.</td></tr><tr><td><code>approval_token</code> / <code>approval_address</code> / <code>approval_amount</code></td><td>The ERC-20 allowance the router needs. Present only when an approval is required (empty for native-token swaps).</td></tr><tr><td><code>txs_required</code></td><td>How many transactions the route needs.</td></tr><tr><td><code>swap_price_impact_percent</code></td><td>Estimated price impact, so you can reject a bad route.</td></tr></tbody></table>

{% hint style="warning" %}
The quote does not execute anything. Broadcast promptly — routes and prices are time-sensitive.
{% endhint %}

## Step 2 — Approve the token (if needed)

If `approval_token`, `approval_address`, and `approval_amount` are present, the DEX router needs an ERC-20 allowance before it can pull your tokens. Send a standard `approve(spender, amount)` transaction from your wallet, where `spender` is `approval_address` and `amount` is at least `approval_amount`. Native-token swaps skip this step.

## Step 3 — Sign & broadcast the swap

`evm_tx` is a serialized unsigned transaction. Decode it, sign it with your own wallet, and broadcast it. With [viem](https://viem.sh), parse it and hand the fields to your wallet client:

```typescript
import { parseTransaction } from "viem";

const { evm_tx } = quote; // from step 1
const tx = parseTransaction(evm_tx); // { to, value, data, chainId, ... }

const hash = await walletClient.sendTransaction({
  to: tx.to,
  value: tx.value,
  data: tx.data,
  chainId: tx.chainId,
});
console.log("swap broadcast:", hash);
```

{% hint style="info" %}
**Prefer to have KiiChain Pay sign it?** If you hold a [delegated Kii Wallet](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/privy-delegated-access), you can instead decode `evm_tx` into its `to` / `value` / `data` / `chain_id` fields and submit it through `POST /blockchain/v1/accounts/{accountId}/transactions/execute` (authenticated, gas-sponsored). That routes the same swap through your Kii Wallet rather than an external one. Check out the [actions you can take with internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets#accessing-wallets-via-the-api).
{% endhint %}

## Step 4 — Confirm on-chain

There is no activity to poll — confirmation is on-chain. Wait for the transaction receipt and check the destination-token balance in your wallet:

```typescript
const receipt = await publicClient.waitForTransactionReceipt({ hash });
console.log(receipt.status); // "success" or "reverted"
```

## Full example

An end-to-end ERC-20 → ERC-20 DEX swap with viem: quote, approve if needed, broadcast, confirm.

```typescript
import { parseTransaction } from "viem";
// assumes viem `walletClient` (with your account) and `publicClient` are configured

const BASE_URL = "https://backend.pay.kiichain.io";
const SENDER = walletClient.account.address;

// 1 · Quote: 25 USDC → USDT on Ethereum.
const quote = await fetch(`${BASE_URL}/market/v1/dex/quote`, {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    asset_in: {
      denom: "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
      chain_id: "1",
      amount: "25000000",
    },
    asset_out: {
      denom: "0xdAC17F958D2ee523a2206206994597C13D831ec7",
      chain_id: "1",
    },
    sender_address: SENDER,
  }),
}).then((r) => r.json());

if (!quote.does_swap) throw new Error("no route available");

// 2 · Approve the router if the quote asks for it.
if (quote.approval_token && quote.approval_address) {
  const approveHash = await walletClient.writeContract({
    address: quote.approval_token,
    abi: [
      {
        name: "approve",
        type: "function",
        stateMutability: "nonpayable",
        inputs: [
          { name: "spender", type: "address" },
          { name: "amount", type: "uint256" },
        ],
        outputs: [{ type: "bool" }],
      },
    ],
    functionName: "approve",
    args: [quote.approval_address, BigInt(quote.approval_amount)],
  });
  await publicClient.waitForTransactionReceipt({ hash: approveHash });
}

// 3 · Sign & broadcast the swap transaction.
const tx = parseTransaction(quote.evm_tx);
const hash = await walletClient.sendTransaction({
  to: tx.to,
  value: tx.value,
  data: tx.data,
  chainId: tx.chainId,
});

// 4 · Confirm on-chain.
const receipt = await publicClient.waitForTransactionReceipt({ hash });
console.log(
  receipt.status === "success" ? "Swap complete 🎉" : "Swap reverted",
);
```

## Related

* [Creating an FX swap](https://docs.kiiglobal.io/docs/kiichain-pay/guides/quick-start/creating-an-fx-swap) — the custodial, tracked alternative (creates an activity).
* [Guides overview](https://docs.kiiglobal.io/docs/kiichain-pay/guides) — how DEX swaps compare with the account-based flows.
* [Internal wallets](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/internal-wallets) — Kii Wallet vs. external wallet.


# API Reference

Every KiiChain Pay backend endpoint, plus the official Postman collection.

This section documents every endpoint of the KiiChain Pay backend API. Endpoints are grouped by module.

{% hint style="info" %}
Both this reference and the Postman collection are regenerated automatically on every KiiChain Pay backend release.
{% endhint %}

{% hint style="info" %}
[Generating API keys](https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys) covers authentication and request signing. The [Guides](https://docs.kiiglobal.io/docs/kiichain-pay/guides) walk through full on-ramp, off-ramp, FX and DEX flows end to end.
{% endhint %}

## Try it in Postman

You can explore the API in the **KiiChain Pay Backend** Postman collection. It has every endpoint in this reference, ready to run, with signing already wired up.

{% hint style="success" %}
[**Open the KiiChain Pay Backend collection in Postman →**](https://www.postman.com/devs-453829c1-6442516/kiichain-pay-backend-api/collection/yi3rz5t/kiichain-pay-backend?action=share\&creator=56716314\&active-environment=56716314-01b919a8-c9f7-4f81-86c6-f4a6d9eeb017)
{% endhint %}

What you get:

* **Requests grouped by RPC server.** Folders follow the service boundaries — one per `<Module>QueryServer` (reads) and `<Module>MsgServer` (writes). Example: `UsersQueryServer`, `TicketsMsgServer` — so each folder maps into a module in this reference.
* **Signing handled for you.** A pre-request script computes the Ed25519 signature for every write request (`POST`/`PATCH`/`PUT`/`DELETE`) from your environment's `api_key` and `priv_key`, following the scheme described in [Sign write requests](https://docs.kiiglobal.io/pages/Xi9e9VnluBBSJsek157L#4.-sign-write-requests). No manual `x-timestamp` / `x-signature` headers needed.
* **A ready-made environment.** Fork it alongside the collection and fill in:

<table><thead><tr><th width="140">Variable</th><th>Value</th></tr></thead><tbody><tr><td><code>base_url</code></td><td><code>https://backend.pay.kiichain.io</code> (production), or the staging base URL.</td></tr><tr><td><code>api_key</code></td><td>Your <code>api_key</code> from <a href="https://docs.kiiglobal.io/docs/kiichain-pay/introduction/generating-api-keys">Generating API keys</a>.</td></tr><tr><td><code>priv_key</code></td><td>Your <code>priv_key</code> — the pre-request script uses this to sign write requests.</td></tr></tbody></table>

### Getting started

1. **Fork** the collection and its environment into your own Postman workspace (top-right **Fork** button on each).
2. Open the forked **environment**, select it as active, and fill in `api_key`, and `priv_key`.
3. Send a read request first (You can try `Me` at `UsersQueryServer`) to confirm your API key is valid.
4. Send a write request (Anything with `*MsgServer`). The pre-request script signs it automatically.

{% hint style="warning" %}
Treat `priv_key` like any other private key. Postman environment values are visible to anyone you share the workspace with — don't fork a copy with a production key into a shared team workspace.
{% endhint %}


# Accounts

## GetAccountInfo returns the account information for the provided account id

> Only the account\_id is needed, ownership is checked against the caller.\
> Use GetUserByAccountId to resolve the owning user

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read","users.accounts.read:all"]},{"BearerAuth":["users.accounts.read","users.accounts.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetAccountInfoResponse":{"properties":{"account":{"$ref":"#/components/schemas/v1Account"}},"required":["account"],"title":"GetAccountInfoResponse is the body response structure from the Get account info endpoints","type":"object"},"v1Account":{"properties":{"accountName":{"title":"account_name is the name of the account","type":"string"},"accountType":{"title":"account_type is the type of the account","type":"string"},"countries":{"items":{"type":"string"},"title":"countries is the list of countries associated to the account, in ISO 3166-1 alpha-3 format","type":"array"},"createdAt":{"format":"date-time","title":"created_at is the date when the account was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the account was deleted","type":"string"},"id":{"title":"id is the account identifier","type":"string"},"kycInfo":{"$ref":"#/components/schemas/v1KycInfo"},"privyId":{"title":"privy_id is the identifier of the account on Privy, which is the Wallet provider used by default","type":"string"},"subscription":{"$ref":"#/components/schemas/v1Subscription"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the account was updated","type":"string"},"userId":{"title":"account_name is the user-assigned name of the account","type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/v1Wallet"},"title":"wallets is the information about the wallets associated to the account","type":"array"}},"required":["id","userId","accountName","accountType","wallets","kycInfo","createdAt","updatedAt","privyId"],"title":"Account contains all information with a account","type":"object"},"v1KycInfo":{"properties":{"level":{"format":"int32","title":"level is the name of the KYC level approved","type":"integer"},"provider":{"title":"provider is the KYC provider name","type":"string"},"requestedAt":{"format":"date-time","title":"requested_at is the date when the KYC was requested","type":"string"},"status":{"title":"status is the KYC status","type":"string"},"verifiedAt":{"format":"date-time","title":"verified_at is the date when the KYC was verified","type":"string"}},"required":["provider","level","status","requestedAt","verifiedAt"],"title":"KycInfo contains the KYC information per account","type":"object"},"v1Subscription":{"properties":{"code":{"title":"code is the stable identifier of the subscription plan","type":"string"},"status":{"title":"status is the subscription status. One of: trialing, active, past_due, canceled,\nunpaid, incomplete, paused","type":"string"},"tier":{"format":"int32","title":"tier ranks the plan's access level, higher grants more access","type":"integer"}},"required":["code","tier","status"],"title":"Subscription identifies the billing plan an account is (or was) subscribed to","type":"object"},"v1Wallet":{"properties":{"address":{"title":"address is the unique wallet address","type":"string"},"chainType":{"title":"chain_type is which chain is using this wallet","type":"string"},"id":{"title":"id is the wallet identifier","type":"string"}},"required":["id","address","chainType"],"title":"Wallet contains all information about a wallet","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}":{"get":{"description":"Only the account_id is needed, ownership is checked against the caller.\nUse GetUserByAccountId to resolve the owning user","operationId":"AccountsQueryService_GetAccountInfo","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetAccountInfoResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetAccountInfo returns the account information for the provided account id","tags":["AccountsQueryService"]}}}}
```

## GetAccountCountries returns the list of countries associated with an account

> Set via UpdateAccountCountries — for the full catalog of registered\
> countries use ListCountries instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.kyc.read","accounts.kyc.read:all"]},{"BearerAuth":["accounts.kyc.read","accounts.kyc.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetAccountCountriesResponse":{"properties":{"countries":{"items":{"type":"string"},"title":"countries is the list of ISO 3166-1 alpha-3 country codes associated with the account","type":"array"}},"required":["countries"],"title":"GetAccountCountriesResponse is the response for the get-account-countries endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/countries":{"get":{"description":"Set via UpdateAccountCountries — for the full catalog of registered\ncountries use ListCountries instead","operationId":"AccountsQueryService_GetAccountCountries","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetAccountCountriesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetAccountCountries returns the list of countries associated with an account","tags":["AccountsQueryService"]}}}}
```

## GetAccountLimits returns the limits information for the provided account id

> Merges the level's default limits with any active per-account overrides,\
> and includes current usage

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read","users.accounts.read:all"]},{"BearerAuth":["users.accounts.read","users.accounts.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetAccountLimitsResponse":{"properties":{"limits":{"items":{"$ref":"#/components/schemas/v1AccountLimitWithUsage"},"title":"limits contains the account limits information","type":"array"}},"required":["limits"],"title":"GetAccountLimitsResponse is the body response structure from the Get account limits endpoint","type":"object"},"v1AccountLimitWithUsage":{"properties":{"amountUsd":{"title":"amount_usd defines the amount of the limit in USD","type":"string"},"id":{"title":"id represents the limit identifier","type":"string"},"level":{"format":"int32","title":"level defines the level of the account","type":"integer"},"limitAction":{"title":"limit_action defines the action (withdrawal | deposit | swap)","type":"string"},"name":{"title":"name defines the name of the level","type":"string"},"periodDays":{"format":"int32","title":"period_days defines the period of the limit in days","type":"integer"},"usedAmountUsd":{"title":"used_amount_usd defines the used amount of the limit in USD","type":"string"}},"required":["id","level","name","limitAction","amountUsd","usedAmountUsd","periodDays"],"title":"AccountLimitWithUsage defines the type of account limit with usage information","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/limits":{"get":{"description":"Merges the level's default limits with any active per-account overrides,\nand includes current usage","operationId":"AccountsQueryService_GetAccountLimits","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetAccountLimitsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetAccountLimits returns the limits information for the provided account id","tags":["AccountsQueryService"]}}}}
```

## ListSubaccounts returns the subaccounts of a company account

> Newest first, paginated. external\_ref filters to an exact match

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.subaccounts.read","accounts.subaccounts.read:all"]},{"BearerAuth":["accounts.subaccounts.read","accounts.subaccounts.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1ListSubaccountsResponse":{"properties":{"pagination":{"$ref":"#/components/schemas/v1Pagination"},"subaccounts":{"items":{"$ref":"#/components/schemas/v1Subaccount"},"title":"subaccounts is the page of subaccounts, newest first","type":"array"}},"required":["subaccounts","pagination"],"title":"ListSubaccountsResponse is the response of the ListSubaccounts endpoint","type":"object"},"v1Pagination":{"properties":{"currentPage":{"format":"int32","title":"current_page is the current page number","type":"integer"},"limit":{"format":"int32","title":"limit contains the limit used to calculate the page","type":"integer"},"totalItems":{"format":"int32","title":"total_items is the total number of items","type":"integer"},"totalPages":{"format":"int32","title":"total_pages is the total number of pages","type":"integer"}},"required":["currentPage","totalItems","totalPages","limit"],"title":"Pagination contains the keys to move between pages\nusing the cursor-based pagination","type":"object"},"v1Subaccount":{"properties":{"account":{"$ref":"#/components/schemas/v1Account"},"externalRef":{"title":"external_ref is the company's own identifier for the subaccount, such as its customer id","type":"string"},"parentAccountId":{"title":"parent_account_id is the company account the subaccount belongs to","type":"string"}},"required":["account","parentAccountId"],"title":"Subaccount is an account a company operates on behalf of one of its customers","type":"object"},"v1Account":{"properties":{"accountName":{"title":"account_name is the name of the account","type":"string"},"accountType":{"title":"account_type is the type of the account","type":"string"},"countries":{"items":{"type":"string"},"title":"countries is the list of countries associated to the account, in ISO 3166-1 alpha-3 format","type":"array"},"createdAt":{"format":"date-time","title":"created_at is the date when the account was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the account was deleted","type":"string"},"id":{"title":"id is the account identifier","type":"string"},"kycInfo":{"$ref":"#/components/schemas/v1KycInfo"},"privyId":{"title":"privy_id is the identifier of the account on Privy, which is the Wallet provider used by default","type":"string"},"subscription":{"$ref":"#/components/schemas/v1Subscription"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the account was updated","type":"string"},"userId":{"title":"account_name is the user-assigned name of the account","type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/v1Wallet"},"title":"wallets is the information about the wallets associated to the account","type":"array"}},"required":["id","userId","accountName","accountType","wallets","kycInfo","createdAt","updatedAt","privyId"],"title":"Account contains all information with a account","type":"object"},"v1KycInfo":{"properties":{"level":{"format":"int32","title":"level is the name of the KYC level approved","type":"integer"},"provider":{"title":"provider is the KYC provider name","type":"string"},"requestedAt":{"format":"date-time","title":"requested_at is the date when the KYC was requested","type":"string"},"status":{"title":"status is the KYC status","type":"string"},"verifiedAt":{"format":"date-time","title":"verified_at is the date when the KYC was verified","type":"string"}},"required":["provider","level","status","requestedAt","verifiedAt"],"title":"KycInfo contains the KYC information per account","type":"object"},"v1Subscription":{"properties":{"code":{"title":"code is the stable identifier of the subscription plan","type":"string"},"status":{"title":"status is the subscription status. One of: trialing, active, past_due, canceled,\nunpaid, incomplete, paused","type":"string"},"tier":{"format":"int32","title":"tier ranks the plan's access level, higher grants more access","type":"integer"}},"required":["code","tier","status"],"title":"Subscription identifies the billing plan an account is (or was) subscribed to","type":"object"},"v1Wallet":{"properties":{"address":{"title":"address is the unique wallet address","type":"string"},"chainType":{"title":"chain_type is which chain is using this wallet","type":"string"},"id":{"title":"id is the wallet identifier","type":"string"}},"required":["id","address","chainType"],"title":"Wallet contains all information about a wallet","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/subaccounts":{"get":{"description":"Newest first, paginated. external_ref filters to an exact match","operationId":"AccountsQueryService_ListSubaccounts","parameters":[{"description":"account_id is the parent company account","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"page is an optional query parameter to set the page","in":"query","name":"page","required":false,"schema":{"format":"int32","type":"integer"}},{"description":"limit is an optional query parameter to set the max number of results","in":"query","name":"limit","required":false,"schema":{"format":"int32","type":"integer"}},{"description":"external_ref is an optional exact-match filter on the company's identifier","in":"query","name":"externalRef","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1ListSubaccountsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListSubaccounts returns the subaccounts of a company account","tags":["AccountsQueryService"]}}}}
```

## CreateSubaccount creates a subaccount under a company account

> The parent must be a KYC verified, top-level company account. The subaccount\
> is an individual account with no login of its own, the company operates it.\
> Calling again with the same external\_ref returns the existing subaccount

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"AccountsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.subaccounts.write","accounts.subaccounts.write:all"]},{"BearerAuth":["accounts.subaccounts.write","accounts.subaccounts.write:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"AccountsMsgServiceCreateSubaccountBody":{"properties":{"country":{"title":"country is the subaccount's country in ISO 3166-1 alpha-3 format","type":"string"},"externalRef":{"title":"external_ref is the company's own identifier for the subaccount, unique within the company","type":"string"},"name":{"title":"name is the subaccount name, usually the customer's name","type":"string"}},"required":["name","country"],"title":"CreateSubaccountRequest is the request of the CreateSubaccount endpoint","type":"object"},"v1CreateSubaccountResponse":{"properties":{"subaccount":{"$ref":"#/components/schemas/v1Subaccount"}},"required":["subaccount"],"title":"CreateSubaccountResponse is the response of the CreateSubaccount endpoint","type":"object"},"v1Subaccount":{"properties":{"account":{"$ref":"#/components/schemas/v1Account"},"externalRef":{"title":"external_ref is the company's own identifier for the subaccount, such as its customer id","type":"string"},"parentAccountId":{"title":"parent_account_id is the company account the subaccount belongs to","type":"string"}},"required":["account","parentAccountId"],"title":"Subaccount is an account a company operates on behalf of one of its customers","type":"object"},"v1Account":{"properties":{"accountName":{"title":"account_name is the name of the account","type":"string"},"accountType":{"title":"account_type is the type of the account","type":"string"},"countries":{"items":{"type":"string"},"title":"countries is the list of countries associated to the account, in ISO 3166-1 alpha-3 format","type":"array"},"createdAt":{"format":"date-time","title":"created_at is the date when the account was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the account was deleted","type":"string"},"id":{"title":"id is the account identifier","type":"string"},"kycInfo":{"$ref":"#/components/schemas/v1KycInfo"},"privyId":{"title":"privy_id is the identifier of the account on Privy, which is the Wallet provider used by default","type":"string"},"subscription":{"$ref":"#/components/schemas/v1Subscription"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the account was updated","type":"string"},"userId":{"title":"account_name is the user-assigned name of the account","type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/v1Wallet"},"title":"wallets is the information about the wallets associated to the account","type":"array"}},"required":["id","userId","accountName","accountType","wallets","kycInfo","createdAt","updatedAt","privyId"],"title":"Account contains all information with a account","type":"object"},"v1KycInfo":{"properties":{"level":{"format":"int32","title":"level is the name of the KYC level approved","type":"integer"},"provider":{"title":"provider is the KYC provider name","type":"string"},"requestedAt":{"format":"date-time","title":"requested_at is the date when the KYC was requested","type":"string"},"status":{"title":"status is the KYC status","type":"string"},"verifiedAt":{"format":"date-time","title":"verified_at is the date when the KYC was verified","type":"string"}},"required":["provider","level","status","requestedAt","verifiedAt"],"title":"KycInfo contains the KYC information per account","type":"object"},"v1Subscription":{"properties":{"code":{"title":"code is the stable identifier of the subscription plan","type":"string"},"status":{"title":"status is the subscription status. One of: trialing, active, past_due, canceled,\nunpaid, incomplete, paused","type":"string"},"tier":{"format":"int32","title":"tier ranks the plan's access level, higher grants more access","type":"integer"}},"required":["code","tier","status"],"title":"Subscription identifies the billing plan an account is (or was) subscribed to","type":"object"},"v1Wallet":{"properties":{"address":{"title":"address is the unique wallet address","type":"string"},"chainType":{"title":"chain_type is which chain is using this wallet","type":"string"},"id":{"title":"id is the wallet identifier","type":"string"}},"required":["id","address","chainType"],"title":"Wallet contains all information about a wallet","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/subaccounts":{"post":{"description":"The parent must be a KYC verified, top-level company account. The subaccount\nis an individual account with no login of its own, the company operates it.\nCalling again with the same external_ref returns the existing subaccount","operationId":"AccountsMsgService_CreateSubaccount","parameters":[{"description":"account_id is the parent company account","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountsMsgServiceCreateSubaccountBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateSubaccountResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateSubaccount creates a subaccount under a company account","tags":["AccountsMsgService"]}}}}
```

## GetSubaccount returns one subaccount of a company account

> A subaccount of another company is reported as not found

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.subaccounts.read","accounts.subaccounts.read:all"]},{"BearerAuth":["accounts.subaccounts.read","accounts.subaccounts.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetSubaccountResponse":{"properties":{"subaccount":{"$ref":"#/components/schemas/v1Subaccount"}},"required":["subaccount"],"title":"GetSubaccountResponse is the response of the GetSubaccount endpoint","type":"object"},"v1Subaccount":{"properties":{"account":{"$ref":"#/components/schemas/v1Account"},"externalRef":{"title":"external_ref is the company's own identifier for the subaccount, such as its customer id","type":"string"},"parentAccountId":{"title":"parent_account_id is the company account the subaccount belongs to","type":"string"}},"required":["account","parentAccountId"],"title":"Subaccount is an account a company operates on behalf of one of its customers","type":"object"},"v1Account":{"properties":{"accountName":{"title":"account_name is the name of the account","type":"string"},"accountType":{"title":"account_type is the type of the account","type":"string"},"countries":{"items":{"type":"string"},"title":"countries is the list of countries associated to the account, in ISO 3166-1 alpha-3 format","type":"array"},"createdAt":{"format":"date-time","title":"created_at is the date when the account was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the account was deleted","type":"string"},"id":{"title":"id is the account identifier","type":"string"},"kycInfo":{"$ref":"#/components/schemas/v1KycInfo"},"privyId":{"title":"privy_id is the identifier of the account on Privy, which is the Wallet provider used by default","type":"string"},"subscription":{"$ref":"#/components/schemas/v1Subscription"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the account was updated","type":"string"},"userId":{"title":"account_name is the user-assigned name of the account","type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/v1Wallet"},"title":"wallets is the information about the wallets associated to the account","type":"array"}},"required":["id","userId","accountName","accountType","wallets","kycInfo","createdAt","updatedAt","privyId"],"title":"Account contains all information with a account","type":"object"},"v1KycInfo":{"properties":{"level":{"format":"int32","title":"level is the name of the KYC level approved","type":"integer"},"provider":{"title":"provider is the KYC provider name","type":"string"},"requestedAt":{"format":"date-time","title":"requested_at is the date when the KYC was requested","type":"string"},"status":{"title":"status is the KYC status","type":"string"},"verifiedAt":{"format":"date-time","title":"verified_at is the date when the KYC was verified","type":"string"}},"required":["provider","level","status","requestedAt","verifiedAt"],"title":"KycInfo contains the KYC information per account","type":"object"},"v1Subscription":{"properties":{"code":{"title":"code is the stable identifier of the subscription plan","type":"string"},"status":{"title":"status is the subscription status. One of: trialing, active, past_due, canceled,\nunpaid, incomplete, paused","type":"string"},"tier":{"format":"int32","title":"tier ranks the plan's access level, higher grants more access","type":"integer"}},"required":["code","tier","status"],"title":"Subscription identifies the billing plan an account is (or was) subscribed to","type":"object"},"v1Wallet":{"properties":{"address":{"title":"address is the unique wallet address","type":"string"},"chainType":{"title":"chain_type is which chain is using this wallet","type":"string"},"id":{"title":"id is the wallet identifier","type":"string"}},"required":["id","address","chainType"],"title":"Wallet contains all information about a wallet","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/subaccounts/{subaccountId}":{"get":{"description":"A subaccount of another company is reported as not found","operationId":"AccountsQueryService_GetSubaccount","parameters":[{"description":"account_id is the parent company account","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"subaccount_id is the subaccount to get","in":"path","name":"subaccountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetSubaccountResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetSubaccount returns one subaccount of a company account","tags":["AccountsQueryService"]}}}}
```

## GetUserByAccountId returns the user information for the provided account id

> Resolves account\_id to its owning user

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read","users.accounts.read:all"]},{"BearerAuth":["users.accounts.read","users.accounts.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserByAccountIdResponse":{"properties":{"accounts":{"items":{"type":"string"},"title":"accounts contains the list of account IDs the user belongs to","type":"array"},"user":{"$ref":"#/components/schemas/v1User"}},"required":["user","accounts"],"title":"GetUserByAccountIdResponse is the body response structure from the Get user by account id endpoint","type":"object"},"v1User":{"properties":{"admin":{"title":"admin is the boolean flag to know if the user is an admin (has access to the admin panel)","type":"boolean"},"createdAt":{"format":"date-time","title":"created_at is the date when the user was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the user was deleted","type":"string"},"displayName":{"title":"display_name is the user display name","type":"string"},"email":{"title":"email is the user email","type":"string"},"emailVerified":{"title":"email_verified indicates whether the user's email has been verified","type":"boolean"},"id":{"title":"id is the user identifier","type":"string"},"isMfaEnabled":{"title":"isMfaEnabled is the boolean flag to enable/disable MFA","type":"boolean"},"language":{"title":"language contains the current user language which will be used on notifications","type":"string"},"lockReason":{"title":"lock_reason is the reason when the user is locked","type":"string"},"locked":{"title":"locked is the boolean flag to lock/unlock the user","type":"boolean"},"passwordChangedAt":{"format":"date-time","title":"password_changed_at is the date when the password was changed","type":"string"},"superAdmin":{"title":"super_admin is the boolean flag to enable/disable super admin permissions","type":"boolean"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the user was updated","type":"string"}},"required":["id","email","displayName","isMfaEnabled","locked","superAdmin","language","createdAt","updatedAt","admin","emailVerified"],"title":"User contains all information with a user","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/user":{"get":{"description":"Resolves account_id to its owning user","operationId":"AccountsQueryService_GetUserByAccountId","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserByAccountIdResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserByAccountId returns the user information for the provided account id","tags":["AccountsQueryService"]}}}}
```

## GetAccountWithdrawalDestinations handle the request to get all withdrawal destinations for an account

> Includes destinations in every status (pending and confirmed). Filter\
> client-side if only confirmed ones are needed. Name optionally does a\
> case-insensitive partial match

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.withdrawal_destination.read"]},{"BearerAuth":["accounts.withdrawal_destination.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetAccountWithdrawalDestinationsResponse":{"properties":{"destinations":{"items":{"$ref":"#/components/schemas/v1WithdrawalDestination"},"title":"destinations represents the withdrawal destinations","type":"array"}},"required":["destinations"],"title":"GetWithdrawalDestinationsResponse is the body response structure from the GetWithdrawalDestinations endpoint","type":"object"},"v1WithdrawalDestination":{"properties":{"accountId":{"title":"account_id represents the account associated to the withdrawal destination","type":"string"},"country":{"title":"country returns the country associated to the destination","type":"string"},"createdAt":{"format":"date-time","title":"created_at is the date when the withdrawal destination was created","type":"string"},"id":{"title":"id represents the withdrawal destination identifier on our database","type":"string"},"identifier":{"title":"identifier represents a value that identifier the destination from others\n(e.g on bank transfer is the account number)","type":"string"},"logo":{"title":"logo is the destination logo URL, resolved by the rail from the payload (bank or wallet\nnetwork) or the rail itself (e.g. Pix). Unset when there's no logo","type":"string"},"name":{"title":"name is the user-defined label for this destination","type":"string"},"payload":{"title":"Rail-specific payload (dynamic schema)","type":"object"},"railCode":{"title":"rail_code represents the rail code","type":"string"},"railVersion":{"format":"int32","title":"rail_version represents the rail version","type":"integer"},"scope":{"title":"scope is who receives the money: self (the account owner) or external (a third party,\nwhose beneficiary fields travel in the payload)","type":"string"},"status":{"title":"status represents the withdrawal destination status (if has been verified or not)","type":"string"},"type":{"title":"type contains the destination type (wallet | bank)","type":"string"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the withdrawal destination was updated","type":"string"}},"required":["id","accountId","railCode","railVersion","payload","country","type","status","identifier","createdAt","name","scope"],"title":"WithdrawalDestination represents a withdrawal destination","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/withdrawal_destinations":{"get":{"description":"Includes destinations in every status (pending and confirmed). Filter\nclient-side if only confirmed ones are needed. Name optionally does a\ncase-insensitive partial match","operationId":"AccountsQueryService_GetAccountWithdrawalDestinations","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"name optionally filters destinations by name\nIt ignores case and matches any destination that contains the provided name","in":"query","name":"name","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetAccountWithdrawalDestinationsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetAccountWithdrawalDestinations handle the request to get all withdrawal destinations for an account","tags":["AccountsQueryService"]}}}}
```

## RegisterWithdrawalDestination handle the request to register a withdrawal destination

> payload's shape depends on rail\_code/rail\_version — check\
> GetAllRailSchemas to know what fields to send. A third party destination\
> (scope external) also carries the rail's beneficiary\_schema fields in the payload.\
> The destination isn't usable until ConfirmWithdrawalDestination completes verification

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"AccountsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.withdrawal_destination.write"]},{"BearerAuth":["accounts.withdrawal_destination.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"AccountsMsgServiceRegisterWithdrawalDestinationBody":{"properties":{"name":{"title":"name represents the name of the withdrawal destination","type":"string"},"payload":{"title":"Rail-specific payload (dynamic schema)","type":"object"},"railCode":{"title":"rail_code represents the rail code","type":"string"},"railVersion":{"format":"int32","title":"rail_version represents the rail version","type":"integer"},"scope":{"title":"scope is who receives the money: self (the account owner) or external (a third party).\nDefaults to self. An external destination needs a rail with a beneficiary_schema and its\nfields in the payload","type":"string"}},"required":["railCode","railVersion","payload","name"],"title":"RegisterWithdrawalDestinationRequest is the body request structure from the RegisterWithdrawalDestination endpoint","type":"object"},"v1RegisterWithdrawalDestinationResponse":{"title":"RegisterWithdrawalDestinationResponse is the body response structure from the RegisterWithdrawalDestination endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/withdrawal_destinations":{"post":{"description":"payload's shape depends on rail_code/rail_version — check\nGetAllRailSchemas to know what fields to send. A third party destination\n(scope external) also carries the rail's beneficiary_schema fields in the payload.\nThe destination isn't usable until ConfirmWithdrawalDestination completes verification","operationId":"AccountsMsgService_RegisterWithdrawalDestination","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountsMsgServiceRegisterWithdrawalDestinationBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1RegisterWithdrawalDestinationResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"RegisterWithdrawalDestination handle the request to register a withdrawal destination","tags":["AccountsMsgService"]}}}}
```

## DeleteWithdrawalDestination handle the request to delete a withdrawal destination

> Removes the destination whether it's pending or already confirmed

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"AccountsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.withdrawal_destination.write"]},{"BearerAuth":["accounts.withdrawal_destination.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1DeleteWithdrawalDestinationResponse":{"title":"DeleteWithdrawalDestinationResponse is the body response structure from the DeleteWithdrawalDestination endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/withdrawal_destinations/{destinationId}":{"delete":{"description":"Removes the destination whether it's pending or already confirmed","operationId":"AccountsMsgService_DeleteWithdrawalDestination","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"destination_id represents the withdrawal destination identifier","in":"path","name":"destinationId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1DeleteWithdrawalDestinationResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"DeleteWithdrawalDestination handle the request to delete a withdrawal destination","tags":["AccountsMsgService"]}}}}
```

## UpdateWithdrawalDestination handle the request to update a withdrawal destination

> Only renames the destination. The rail payload itself can't be changed,\
> register a new destination instead if those details need to change

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"AccountsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.withdrawal_destination.write"]},{"BearerAuth":["accounts.withdrawal_destination.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"AccountsMsgServiceUpdateWithdrawalDestinationBody":{"properties":{"name":{"title":"name is the new label for this destination","type":"string"}},"required":["name"],"title":"UpdateWithdrawalDestinationRequest is the body request structure from the UpdateWithdrawalDestination endpoint","type":"object"},"v1UpdateWithdrawalDestinationResponse":{"title":"UpdateWithdrawalDestinationResponse is the body response structure from the UpdateWithdrawalDestination endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/withdrawal_destinations/{destinationId}":{"patch":{"description":"Only renames the destination. The rail payload itself can't be changed,\nregister a new destination instead if those details need to change","operationId":"AccountsMsgService_UpdateWithdrawalDestination","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"destination_id represents the withdrawal destination identifier","in":"path","name":"destinationId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountsMsgServiceUpdateWithdrawalDestinationBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1UpdateWithdrawalDestinationResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"UpdateWithdrawalDestination handle the request to update a withdrawal destination","tags":["AccountsMsgService"]}}}}
```

## ConfirmWithdrawalDestination handle the request to confirm a withdrawal destination

> verify\_code is the one-time code sent out after RegisterWithdrawalDestination\
> — moves the destination from pending to confirmed

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"AccountsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.withdrawal_destination.write"]},{"BearerAuth":["accounts.withdrawal_destination.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1AccountsMsgServiceConfirmWithdrawalDestinationBody":{"properties":{"verifyCode":{"title":"verify_code represents the one time code to verify the destination created","type":"string"}},"required":["verifyCode"],"title":"ConfirmWithdrawalDestinationRequest is the body request structure from the ConfirmWithdrawalDestination endpoint","type":"object"},"v1ConfirmWithdrawalDestinationResponse":{"title":"ConfirmWithdrawalDestinationResponse is the body response structure from the ConfirmWithdrawalDestination endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/accounts/{accountId}/withdrawal_destinations/{destinationId}:confirm":{"post":{"description":"verify_code is the one-time code sent out after RegisterWithdrawalDestination\n— moves the destination from pending to confirmed","operationId":"AccountsMsgService_ConfirmWithdrawalDestination","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"destination_id represents the withdrawal destination identifier","in":"path","name":"destinationId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1AccountsMsgServiceConfirmWithdrawalDestinationBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1ConfirmWithdrawalDestinationResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ConfirmWithdrawalDestination handle the request to confirm a withdrawal destination","tags":["AccountsMsgService"]}}}}
```

## ListCountries returns all countries registered in the platform

> The full reference for countries, not scoped to any\
> account — see GetAccountCountries for a specific account's countries

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.kyc.read"]},{"BearerAuth":["accounts.kyc.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1ListCountriesResponse":{"properties":{"countries":{"items":{"$ref":"#/components/schemas/v1Country"},"title":"countries is the list of all registered countries","type":"array"}},"required":["countries"],"title":"ListCountriesResponse is the response for the list-countries endpoint","type":"object"},"v1Country":{"properties":{"code":{"title":"code is the ISO 3166-1 alpha-3 country code","type":"string"},"name":{"title":"name is the human-readable country name","type":"string"}},"required":["code","name"],"title":"Country represents a country registered in the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/countries":{"get":{"description":"The full reference for countries, not scoped to any\naccount — see GetAccountCountries for a specific account's countries","operationId":"AccountsQueryService_ListCountries","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1ListCountriesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListCountries returns all countries registered in the platform","tags":["AccountsQueryService"]}}}}
```

## ListAccountLevels returns the existing levels for accounts

> Supports optional filtering by account\_type and level

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read"]},{"BearerAuth":["users.accounts.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1ListAccountLevelsResponse":{"properties":{"levels":{"items":{"$ref":"#/components/schemas/v1AccountLevel"},"title":"levels contains the array of account levels","type":"array"}},"required":["levels"],"title":"ListAccountLevelsResponse is the body response structure from the List account levels endpoint","type":"object"},"v1AccountLevel":{"properties":{"accountType":{"title":"account_type defines if the level is for individual or company accounts","type":"string"},"description":{"title":"description defines the description of the level","type":"string"},"id":{"title":"id represents the account level identifier","type":"string"},"level":{"format":"int32","title":"level defines the level of the account","type":"integer"},"name":{"title":"name defines the name of the level","type":"string"}},"required":["id","accountType","level","name","description"],"title":"AccountLevel defines the type of account level","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/levels":{"get":{"description":"Supports optional filtering by account_type and level","operationId":"AccountsQueryService_ListAccountLevels","parameters":[{"description":"account_type is an optional query parameter to filter leves by account type","in":"query","name":"accountType","required":false,"schema":{"type":"string"}},{"description":"level is an optional query parameter to filter leves by level","in":"query","name":"level","required":false,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1ListAccountLevelsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListAccountLevels returns the existing levels for accounts","tags":["AccountsQueryService"]}}}}
```

## ListAccountLimits returns the existing limits for accounts

> The configured defaults per level/action, not a specific account's\
> effective limits — use GetAccountLimits for that

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read"]},{"BearerAuth":["users.accounts.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1ListAccountLimitsResponse":{"properties":{"limits":{"items":{"$ref":"#/components/schemas/v1AccountLimit"},"title":"limits contains the account limits information","type":"array"}},"required":["limits"],"title":"ListAccountLimitsResponse is the body response structure from the List account limits endpoint","type":"object"},"v1AccountLimit":{"properties":{"accountType":{"title":"account_type defines if the limits are for individual or company accounts","type":"string"},"active":{"title":"active defines if the override is active or not","type":"boolean"},"amountUsd":{"title":"amount_usd defines the amount of the limit in USD","type":"string"},"description":{"title":"description defines the description of the level","type":"string"},"id":{"title":"id represents the limit identifier","type":"string"},"level":{"format":"int32","title":"level defines the level of the account","type":"integer"},"limitAction":{"title":"limit_action defines the action (withdrawal | deposit | swap)","type":"string"},"name":{"title":"name defines the name of the level","type":"string"},"periodDays":{"format":"int32","title":"period_days defines the period of the limit in days","type":"integer"}},"required":["id","accountType","level","name","limitAction","amountUsd","periodDays","active"],"title":"AccountLimit defines the type of account limits","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/limits":{"get":{"description":"The configured defaults per level/action, not a specific account's\neffective limits — use GetAccountLimits for that","operationId":"AccountsQueryService_ListAccountLimits","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1ListAccountLimitsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListAccountLimits returns the existing limits for accounts","tags":["AccountsQueryService"]}}}}
```

## ListAccountLimitOverrides returns all the overrides information for the provided account id

> List of overrides, not scoped to a single account. Includes each override's reason and active status

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read"]},{"BearerAuth":["users.accounts.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1ListAccountLimitOverridesResponse":{"properties":{"overrides":{"items":{"$ref":"#/components/schemas/v1AccountLimitOverride"},"title":"overrides contains the account limit overrides information","type":"array"}},"required":["overrides"],"title":"ListAccountLimitOverridesResponse is the body response structure from the Get account limit overrides endpoint","type":"object"},"v1AccountLimitOverride":{"properties":{"accountId":{"title":"account_id represents the account identifier","type":"string"},"active":{"title":"active defines if the override is active or not","type":"boolean"},"amountUsd":{"title":"amount_usd defines the amount of the limit in USD","type":"string"},"id":{"title":"id represents the override identifier","type":"string"},"limitAction":{"title":"limit_action defines the action (withdrawal | deposit | swap)","type":"string"},"periodDays":{"format":"int32","title":"period_days defines the period of the limit in days","type":"integer"},"reason":{"title":"reason defines the reason for the override","type":"string"}},"required":["id","accountId","limitAction","amountUsd","reason","periodDays","active"],"title":"AccountLimitOverride defines the type of account limit override","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/limits/overrides":{"get":{"description":"List of overrides, not scoped to a single account. Includes each override's reason and active status","operationId":"AccountsQueryService_ListAccountLimitOverrides","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1ListAccountLimitOverridesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListAccountLimitOverrides returns all the overrides information for the provided account id","tags":["AccountsQueryService"]}}}}
```

## GetAllRailSchemas handle the request to get all rail schemas

> Each schema describes the payload shape a rail\_code/rail\_version expects\
> Use this to build the payload for RegisterWithdrawalDestination.\
> Country optionally filters to rails available in that country

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["accounts.withdrawal_destination.read"]},{"BearerAuth":["accounts.withdrawal_destination.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetAllRailSchemasResponse":{"properties":{"schemas":{"items":{"$ref":"#/components/schemas/v1RailSchema"},"title":"schemas represents the rail schemas","type":"array"}},"required":["schemas"],"title":"GetAllRailSchemasResponse is the body response structure from the GetAllRailSchemas endpoint","type":"object"},"v1RailSchema":{"properties":{"beneficiarySchema":{"$ref":"#/components/schemas/typesV1Schema"},"country":{"title":"country represents the country associated to the rail schema","type":"string"},"railCode":{"title":"rail_code represents the rail code","type":"string"},"railVersion":{"format":"int32","title":"rail_version represents the rail version","type":"integer"},"schema":{"$ref":"#/components/schemas/typesV1Schema"},"type":{"title":"type represents the rail type (bank | wallet)","type":"string"}},"required":["railCode","railVersion","country","type","schema"],"title":"RailSchema is the structure of a rail schema","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/rails/schemas":{"get":{"description":"Each schema describes the payload shape a rail_code/rail_version expects\nUse this to build the payload for RegisterWithdrawalDestination.\nCountry optionally filters to rails available in that country","operationId":"AccountsQueryService_GetAllRailSchemas","parameters":[{"description":"country represents the country associated to the rail schemas","in":"query","name":"country","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetAllRailSchemasResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetAllRailSchemas handle the request to get all rail schemas","tags":["AccountsQueryService"]}}}}
```

## GetUserAccounts returns all accounts associated to the provided user\_id

> Full account objects (KYC, wallets) for every account the user holds\
> for a single account use GetAccountInfo instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"AccountsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.accounts.read","users.accounts.read:all"]},{"BearerAuth":["users.accounts.read","users.accounts.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserAccountsResponse":{"properties":{"accounts":{"items":{"$ref":"#/components/schemas/v1Account"},"title":"accounts contains the array of accounts associated to the user","type":"array"}},"required":["accounts"],"title":"GetUserAccountsResponse is the body response structure from the Get user accounts endpoint","type":"object"},"v1Account":{"properties":{"accountName":{"title":"account_name is the name of the account","type":"string"},"accountType":{"title":"account_type is the type of the account","type":"string"},"countries":{"items":{"type":"string"},"title":"countries is the list of countries associated to the account, in ISO 3166-1 alpha-3 format","type":"array"},"createdAt":{"format":"date-time","title":"created_at is the date when the account was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the account was deleted","type":"string"},"id":{"title":"id is the account identifier","type":"string"},"kycInfo":{"$ref":"#/components/schemas/v1KycInfo"},"privyId":{"title":"privy_id is the identifier of the account on Privy, which is the Wallet provider used by default","type":"string"},"subscription":{"$ref":"#/components/schemas/v1Subscription"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the account was updated","type":"string"},"userId":{"title":"account_name is the user-assigned name of the account","type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/v1Wallet"},"title":"wallets is the information about the wallets associated to the account","type":"array"}},"required":["id","userId","accountName","accountType","wallets","kycInfo","createdAt","updatedAt","privyId"],"title":"Account contains all information with a account","type":"object"},"v1KycInfo":{"properties":{"level":{"format":"int32","title":"level is the name of the KYC level approved","type":"integer"},"provider":{"title":"provider is the KYC provider name","type":"string"},"requestedAt":{"format":"date-time","title":"requested_at is the date when the KYC was requested","type":"string"},"status":{"title":"status is the KYC status","type":"string"},"verifiedAt":{"format":"date-time","title":"verified_at is the date when the KYC was verified","type":"string"}},"required":["provider","level","status","requestedAt","verifiedAt"],"title":"KycInfo contains the KYC information per account","type":"object"},"v1Subscription":{"properties":{"code":{"title":"code is the stable identifier of the subscription plan","type":"string"},"status":{"title":"status is the subscription status. One of: trialing, active, past_due, canceled,\nunpaid, incomplete, paused","type":"string"},"tier":{"format":"int32","title":"tier ranks the plan's access level, higher grants more access","type":"integer"}},"required":["code","tier","status"],"title":"Subscription identifies the billing plan an account is (or was) subscribed to","type":"object"},"v1Wallet":{"properties":{"address":{"title":"address is the unique wallet address","type":"string"},"chainType":{"title":"chain_type is which chain is using this wallet","type":"string"},"id":{"title":"id is the wallet identifier","type":"string"}},"required":["id","address","chainType"],"title":"Wallet contains all information about a wallet","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/accounts/v1/users/{userId}/accounts":{"get":{"description":"Full account objects (KYC, wallets) for every account the user holds\nfor a single account use GetAccountInfo instead","operationId":"AccountsQueryService_GetUserAccounts","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserAccountsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserAccounts returns all accounts associated to the provided user_id","tags":["AccountsQueryService"]}}}}
```


# Blockchain

## ExecuteTransaction signs and broadcasts a batch of transactions on behalf of the caller

> Each transaction is signed using the account's delegated wallet. Failed\
> transactions are returned as "0x00" in the response and do not abort the\
> rest of the batch

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"BlockchainMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["blockchain.transactions.execute"]},{"BearerAuth":["blockchain.transactions.execute"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"BlockchainMsgServiceExecuteTransactionBody":{"description":"ExecuteTransactionRequest contains the ordered list of transactions to execute.","properties":{"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"type":"array"}},"type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"transactionsExecuteTransactionResponse":{"description":"ExecuteTransactionResponse contains the transaction hashes in the same order as the request.\nFailed transactions are represented as \"0x00\".","properties":{"txHashes":{"items":{"type":"string"},"type":"array"}},"type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/blockchain/v1/accounts/{accountId}/transactions/execute":{"post":{"description":"Each transaction is signed using the account's delegated wallet. Failed\ntransactions are returned as \"0x00\" in the response and do not abort the\nrest of the batch","operationId":"BlockchainMsgService_ExecuteTransaction","parameters":[{"description":"account_id is the account whose delegated wallet signs the transactions","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockchainMsgServiceExecuteTransactionBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/transactionsExecuteTransactionResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ExecuteTransaction signs and broadcasts a batch of transactions on behalf of the caller","tags":["BlockchainMsgService"]}}}}
```

## GetInternalWallets returns the internal wallets owned by the caller

> Lists the internal wallets of the given account, across every chain\
> family

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["blockchain.wallets.read"]},{"BearerAuth":["blockchain.wallets.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"transactionsGetInternalWalletsResponse":{"description":"GetInternalWalletsResponse contains the caller's internal wallets.","properties":{"wallets":{"items":{"$ref":"#/components/schemas/transactionsInternalWallet"},"type":"array"}},"type":"object"},"transactionsInternalWallet":{"description":"InternalWallet represents an internal wallet owned by the caller.","properties":{"address":{"title":"address is the on-chain address of the wallet","type":"string"},"chainType":{"title":"chain_type is the chain family the wallet belongs to (ethereum, solana, tron, ...)","type":"string"},"id":{"title":"id is the internal identifier of the wallet","type":"string"}},"type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/blockchain/v1/accounts/{accountId}/wallets/internal":{"get":{"description":"Lists the internal wallets of the given account, across every chain\nfamily","operationId":"BlockchainQueryService_GetInternalWallets","parameters":[{"description":"account_id is the account whose internal wallets are listed","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/transactionsGetInternalWalletsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetInternalWallets returns the internal wallets owned by the caller","tags":["BlockchainQueryService"]}}}}
```

## SendBalanceFromInternalWallet sends a balance out of the caller's internal wallet

> Builds a native (gas token) or ERC20 transfer from the caller's internal\
> wallet to the given address, then signs and broadcasts it using the\
> account's delegated wallet. The asset field selects the token to send; an\
> empty or zero address sends the native gas token. Works on any supported\
> chain given its chain\_id

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"BlockchainMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["blockchain.wallets.send"]},{"BearerAuth":["blockchain.wallets.send"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"BlockchainMsgServiceSendBalanceFromInternalWalletBody":{"description":"SendBalanceFromInternalWalletRequest asks to send a balance out of the caller's internal wallet.","properties":{"amount":{"title":"amount is the amount to send in the token's smallest unit (wei/atoms)","type":"string"},"asset":{"title":"asset is the token contract address to send; leave empty or use the zero\naddress to send the native gas token","type":"string"},"chainId":{"title":"chain_id is the numeric ID of the network to send on","type":"string"},"to":{"title":"to is the destination address that receives the balance","type":"string"}},"required":["chainId","to","amount"],"type":"object"},"transactionsSendBalanceFromInternalWalletResponse":{"description":"SendBalanceFromInternalWalletResponse contains the broadcast transaction hash.","properties":{"txHash":{"title":"tx_hash is the hash of the broadcast transaction","type":"string"}},"type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/blockchain/v1/accounts/{accountId}/wallets/internal/send":{"post":{"description":"Builds a native (gas token) or ERC20 transfer from the caller's internal\nwallet to the given address, then signs and broadcasts it using the\naccount's delegated wallet. The asset field selects the token to send; an\nempty or zero address sends the native gas token. Works on any supported\nchain given its chain_id","operationId":"BlockchainMsgService_SendBalanceFromInternalWallet","parameters":[{"description":"account_id is the account whose internal wallet sends the balance","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockchainMsgServiceSendBalanceFromInternalWalletBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/transactionsSendBalanceFromInternalWalletResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"SendBalanceFromInternalWallet sends a balance out of the caller's internal wallet","tags":["BlockchainMsgService"]}}}}
```

## GetChains returns a list of chains (enabled only by default, or all if all=true)

> Use GetChainByID instead when only one chain's details are needed

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/chains":{"get":{"description":"Use GetChainByID instead when only one chain's details are needed","operationId":"BlockchainQueryService_GetChains","parameters":[{"description":"all indicates whether to return all chains including disabled ones\nIf false or omitted, only enabled chains are returned","in":"query","name":"all","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/chainsGetChainsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetChains returns a list of chains (enabled only by default, or all if all=true)","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"chainsGetChainsResponse":{"properties":{"chains":{"items":{"$ref":"#/components/schemas/v1Chain"},"title":"chains is the list of chains","type":"array"}},"required":["chains"],"title":"GetChainsResponse is the response message for GetChains","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetTokensByChainIDs returns tokens for a specific set of chains (enabled only by default, or all if all=true)

> Response is keyed by chain\_id, each mapping to its own token\_symbol\
> lookup

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/chains/tokens":{"get":{"description":"Response is keyed by chain_id, each mapping to its own token_symbol\nlookup","operationId":"BlockchainQueryService_GetTokensByChainIDs","parameters":[{"description":"chain_ids is the list of chain IDs to get tokens for","explode":true,"in":"query","name":"chainIds","required":true,"schema":{"items":{"type":"string"},"type":"array"}},{"description":"all indicates whether to return all tokens including disabled ones\nIf false or omitted, only enabled tokens are returned","in":"query","name":"all","required":false,"schema":{"type":"boolean"}},{"description":"mode filters tokens by feature category. Supported values: \"dex\".\nIf omitted, no category filter is applied.","in":"query","name":"mode","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/chains_tokensGetTokensByChainIDsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTokensByChainIDs returns tokens for a specific set of chains (enabled only by default, or all if all=true)","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"chains_tokensGetTokensByChainIDsResponse":{"properties":{"chainsTokens":{"additionalProperties":{"$ref":"#/components/schemas/chains_tokensChainTokens"},"title":"chains_tokens is a map of chain_id to tokens","type":"object"}},"required":["chainsTokens"],"title":"GetTokensByChainIDsResponse is the response message for GetTokensByChainIDs","type":"object"},"chains_tokensChainTokens":{"properties":{"tokens":{"additionalProperties":{"$ref":"#/components/schemas/v1ChainToken"},"title":"tokens is a map of token_symbol to ChainToken","type":"object"}},"required":["tokens"],"title":"ChainTokens represents the tokens for a specific chain","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetChainTokens returns all token/chains relations (enabled only by default, or all if all=true)

> Flat list across every chain. Use GetTokensByChainIDs to scope the\
> lookup to specific chains

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/chains/tokens/all":{"get":{"description":"Flat list across every chain. Use GetTokensByChainIDs to scope the\nlookup to specific chains","operationId":"BlockchainQueryService_GetChainTokens","parameters":[{"description":"all indicates whether to return all chain-tokens including disabled ones\nIf false or omitted, only enabled chain-tokens are returned","in":"query","name":"all","required":false,"schema":{"type":"boolean"}},{"description":"mode filters chain-tokens by feature category. Supported values: \"dex\".\nIf omitted, no category filter is applied.","in":"query","name":"mode","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/chains_tokensGetChainTokensResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetChainTokens returns all token/chains relations (enabled only by default, or all if all=true)","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"chains_tokensGetChainTokensResponse":{"properties":{"chainsTokens":{"items":{"$ref":"#/components/schemas/v1ChainToken"},"title":"chains_tokens is a list of all chain-token relations","type":"array"}},"required":["chainsTokens"],"title":"GetChainTokensResponse is the response message for GetChainTokensResponse","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetChainByID returns a single chain by ID

> Includes the chain's contracts map and confirmation depth

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/chains/{chainId}":{"get":{"description":"Includes the chain's contracts map and confirmation depth","operationId":"BlockchainQueryService_GetChainByID","parameters":[{"description":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum)","in":"path","name":"chainId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/chainsGetChainByIDResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetChainByID returns a single chain by ID","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"chainsGetChainByIDResponse":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"}},"required":["chain"],"title":"GetChainByIDResponse is the response message for GetChainByID","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetChainTokenRelation returns a single chain-token relation

> Looked up by chain\_id and token\_symbol together

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/chains/{chainId}/tokens/{tokenSymbol}":{"get":{"description":"Looked up by chain_id and token_symbol together","operationId":"BlockchainQueryService_GetChainTokenRelation","parameters":[{"description":"chain_id is the unique identifier of the chain","in":"path","name":"chainId","required":true,"schema":{"type":"string"}},{"description":"token_symbol is the ticker symbol of the token","in":"path","name":"tokenSymbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/chains_tokensGetChainTokenRelationResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetChainTokenRelation returns a single chain-token relation","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"chains_tokensGetChainTokenRelationResponse":{"properties":{"chainToken":{"$ref":"#/components/schemas/v1ChainToken"}},"required":["chainToken"],"title":"GetChainTokenRelationResponse is the response message for GetChainTokenRelation","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetTokens returns a list of tokens (enabled only by default, or all if all=true)

> Platform-wide list, not scoped to a chain or wallet

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/tokens":{"get":{"description":"Platform-wide list, not scoped to a chain or wallet","operationId":"BlockchainQueryService_GetTokens","parameters":[{"description":"all indicates whether to return all tokens including disabled ones\nIf false or omitted, only enabled tokens are returned","in":"query","name":"all","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/tokensGetTokensResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTokens returns a list of tokens (enabled only by default, or all if all=true)","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"tokensGetTokensResponse":{"properties":{"tokens":{"items":{"$ref":"#/components/schemas/v1Token"},"title":"tokens is the list of tokens","type":"array"}},"required":["tokens"],"title":"GetTokensResponse is the response message for GetTokens","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetTokenBySymbol returns a single token by symbol

> Returns the token's platform-wide metadata regardless of chain

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"BlockchainQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/blockchain/v1/tokens/{symbol}":{"get":{"description":"Returns the token's platform-wide metadata regardless of chain","operationId":"BlockchainQueryService_GetTokenBySymbol","parameters":[{"description":"symbol is the ticker symbol of the token","in":"path","name":"symbol","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/tokensGetTokenBySymbolResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTokenBySymbol returns a single token by symbol","tags":["BlockchainQueryService"]}}},"components":{"schemas":{"tokensGetTokenBySymbolResponse":{"properties":{"token":{"$ref":"#/components/schemas/v1Token"}},"required":["token"],"title":"GetTokenBySymbolResponse is the response message for GetTokenBySymbol","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```


# Geofence

## GetGeofenceStatus returns the geofence status for the calling client

> Resolves the caller's country from the edge-provided header and reports whether\
> geofenced endpoints are barred, together with the full list of geofenced endpoints\
> so the client can gate navigation before the user hits a 403

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"GeofenceQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/geofence/v1/status":{"get":{"description":"Resolves the caller's country from the edge-provided header and reports whether\ngeofenced endpoints are barred, together with the full list of geofenced endpoints\nso the client can gate navigation before the user hits a 403","operationId":"GeofenceQueryService_GetGeofenceStatus","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetGeofenceStatusResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetGeofenceStatus returns the geofence status for the calling client","tags":["GeofenceQueryService"]}}},"components":{"schemas":{"v1GetGeofenceStatusResponse":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-2 code resolved for the caller, empty when unknown","type":"string"},"endpoints":{"items":{"$ref":"#/components/schemas/v1GeofencedEndpoint"},"title":"endpoints is the full set of geofenced endpoints, each reporting whether the caller is blocked","type":"array"}},"title":"GetGeofenceStatusResponse is the body response structure from the GetGeofenceStatus endpoint","type":"object"},"v1GeofencedEndpoint":{"properties":{"blocked":{"title":"blocked is true when the caller's resolved country cannot reach this endpoint","type":"boolean"},"method":{"title":"method is the HTTP method, e.g. \"GET\" or \"POST\" (may be a custom verb if the binding uses google.api.http custom patterns)","type":"string"},"path":{"title":"path is the REST path template, e.g. \"/tickets/v1/offramp\"","type":"string"}},"required":["method","path","blocked"],"title":"GeofencedEndpoint is a single REST binding of a geofenced method","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```


# Ledger

## GetAvailableBalances returns the user's available balance for each product

> Splits available vs locked amounts derived from the ledger entries,\
> rather than returning the entries themselves

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"LedgerQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["ledger.entries.read"]},{"BearerAuth":["ledger.entries.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetAvailableBalancesResponse":{"properties":{"balances":{"items":{"$ref":"#/components/schemas/ledgerV1Balance"},"title":"balances contains the available balance for each product","type":"array"}},"required":["balances"],"title":"GetAvailableBalancesResponse is the response for retrieving a user's available balance per product","type":"object"},"ledgerV1Balance":{"properties":{"available":{"title":"available represents the current available balance for the asset","type":"string"},"locked":{"title":"locked represents the locked amount for the asset","type":"string"},"productId":{"title":"product_id represents the product identifier","type":"string"}},"required":["productId","available","locked"],"title":"Balance represents the balance for a specific asset","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/ledger/v1/balances/{accountId}":{"get":{"description":"Splits available vs locked amounts derived from the ledger entries,\nrather than returning the entries themselves","operationId":"LedgerQueryService_GetAvailableBalances","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetAvailableBalancesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetAvailableBalances returns the user's available balance for each product","tags":["LedgerQueryService"]}}}}
```

## GetUserTradeHistory returns historical ticket trade data for a user (paginated)

> Each entry is a single ticket-linked trade (deposit, withdraw, swap)\
> Use GetUserTradeHistoryGrouped for aggregated totals per time bucket\
> instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"LedgerQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["ledger.entries.read"]},{"BearerAuth":["ledger.entries.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserTradeHistoryResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/v1TradeHistoryEntry"},"title":"entries contains the paginated list of trade entries","type":"array"},"total":{"format":"int64","title":"total is the total number of entries (for pagination)","type":"string"}},"required":["entries","total"],"title":"GetUserTradeHistoryResponse is the response for retrieving a user's trade history","type":"object"},"v1TradeHistoryEntry":{"properties":{"amount":{"title":"amount is the net token-unit volume for this trade","type":"string"},"amountUsd":{"title":"amount_usd is the USD value of the trade","type":"string"},"createdAt":{"format":"date-time","title":"created_at is when the trade was recorded","type":"string"},"journalId":{"title":"journal_id is the ledger journal identifier","type":"string"},"subType":{"title":"sub_type is the trade subtype (deposit, withdraw, swap)","type":"string"},"symbol":{"title":"symbol is the ticker symbol of the traded asset (e.g. \"USDC\")","type":"string"},"ticketId":{"title":"ticket_id is the ticket identifier (ref_id from the journal)","type":"string"}},"required":["journalId","ticketId","symbol","subType","amount","amountUsd","createdAt"],"title":"TradeHistoryEntry represents a single ticket-linked trade in the user's ledger","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/ledger/v1/trades/{accountId}":{"get":{"description":"Each entry is a single ticket-linked trade (deposit, withdraw, swap)\nUse GetUserTradeHistoryGrouped for aggregated totals per time bucket\ninstead","operationId":"LedgerQueryService_GetUserTradeHistory","parameters":[{"description":"account_id is the user's account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"limit is the maximum number of entries to return (defaults to 50)","in":"query","name":"limit","required":false,"schema":{"format":"int32","type":"integer"}},{"description":"page is the 1-indexed page number (defaults to 1)","in":"query","name":"page","required":false,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserTradeHistoryResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserTradeHistory returns historical ticket trade data for a user (paginated)","tags":["LedgerQueryService"]}}}}
```

## GetUserTradeHistoryGrouped returns historical ticket trade data grouped by time frame for a user

> Buckets trades by day, week or month, aggregating amount and ticket\
> count per bucket instead of returning individual trades

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"LedgerQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["ledger.entries.read"]},{"BearerAuth":["ledger.entries.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserTradeHistoryGroupedResponse":{"properties":{"groups":{"items":{"$ref":"#/components/schemas/v1TradeHistoryGroup"},"title":"groups contains the aggregated trade data per time bucket","type":"array"}},"required":["groups"],"title":"GetUserTradeHistoryGroupedResponse is the response for grouped trade history","type":"object"},"v1TradeHistoryGroup":{"properties":{"period":{"format":"date-time","title":"period is the start of the time bucket","type":"string"},"subType":{"title":"sub_type is the trade subtype (deposit, withdraw, swap)","type":"string"},"symbol":{"title":"symbol is the ticker symbol of the traded asset (e.g. \"USDC\")","type":"string"},"ticketCount":{"format":"int64","title":"ticket_count is the number of distinct tickets in this period","type":"string"},"totalAmount":{"title":"total_amount is the net token-unit volume for this period","type":"string"},"totalAmountUsd":{"title":"total_amount_usd is the total USD volume for this period","type":"string"}},"required":["period","subType","symbol","totalAmount","totalAmountUsd","ticketCount"],"title":"TradeHistoryGroup represents aggregated trade data for a single time period","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/ledger/v1/trades/{accountId}/grouped":{"get":{"description":"Buckets trades by day, week or month, aggregating amount and ticket\ncount per bucket instead of returning individual trades","operationId":"LedgerQueryService_GetUserTradeHistoryGrouped","parameters":[{"description":"account_id is the user's account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"time_frame specifies the grouping period: \"day\", \"week\", or \"month\"","in":"query","name":"timeFrame","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserTradeHistoryGroupedResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserTradeHistoryGrouped returns historical ticket trade data grouped by time frame for a user","tags":["LedgerQueryService"]}}}}
```

## GetLedgerEntries returns all ledger entries for an account

> Unfiltered and unpaginated. Use GetLedgerEntriesFiltered for large\
> accounts or when scoping to a product/time range

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"LedgerQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["ledger.entries.read"]},{"BearerAuth":["ledger.entries.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetLedgerEntriesResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/v1LedgerEntry"},"title":"entries contains the list of ledger entries","type":"array"}},"required":["entries"],"title":"GetLedgerEntriesResponse is the body response structure from the Get ledger entries endpoint","type":"object"},"v1LedgerEntry":{"properties":{"accountId":{"title":"account_id represents the account identifier","type":"string"},"amount":{"title":"amount represents the amount of the ledger entry (positive for credit, negative for debit)","type":"string"},"amountUsd":{"title":"amount_usd represents the USD value of the ledger entry","type":"string"},"createdAt":{"format":"date-time","title":"created_at represents the time when the ledger entry was created","type":"string"},"description":{"title":"description provides additional information about the ledger entry","type":"string"},"direction":{"title":"direction represents whether the entry is a credit or debit","type":"string"},"id":{"format":"int64","title":"id represents the unique identifier for the ledger entry","type":"string"},"journalId":{"title":"journal_id represents the journal identifier","type":"string"},"productId":{"title":"product_id represents the product identifier","type":"string"},"subType":{"title":"sub_type represents the type of the ledger entry (locked, available, etc.)","type":"string"},"type":{"title":"type represents the primary account type of the ledger entry (available, locked, limit, etc.)","type":"string"}},"required":["id","accountId","journalId","productId","amount","amountUsd","direction","type","subType","createdAt"],"title":"LedgerEntry represents a single ledger entry","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/ledger/v1/{accountId}":{"get":{"description":"Unfiltered and unpaginated. Use GetLedgerEntriesFiltered for large\naccounts or when scoping to a product/time range","operationId":"LedgerQueryService_GetLedgerEntries","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetLedgerEntriesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetLedgerEntries returns all ledger entries for an account","tags":["LedgerQueryService"]}}}}
```

## GetLedgerEntriesFiltered returns a user's entries filtered by product and time range

> product\_id, start\_date and end\_date are all optional and independently\
> combinable

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"LedgerQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["ledger.entries.read"]},{"BearerAuth":["ledger.entries.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetLedgerEntriesFilteredResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/v1LedgerEntry"},"title":"entries contains the list of ledger entries","type":"array"}},"required":["entries"],"title":"GetLedgerEntriesFilteredResponse is the response for retrieving a user's entries filtered by product and time range","type":"object"},"v1LedgerEntry":{"properties":{"accountId":{"title":"account_id represents the account identifier","type":"string"},"amount":{"title":"amount represents the amount of the ledger entry (positive for credit, negative for debit)","type":"string"},"amountUsd":{"title":"amount_usd represents the USD value of the ledger entry","type":"string"},"createdAt":{"format":"date-time","title":"created_at represents the time when the ledger entry was created","type":"string"},"description":{"title":"description provides additional information about the ledger entry","type":"string"},"direction":{"title":"direction represents whether the entry is a credit or debit","type":"string"},"id":{"format":"int64","title":"id represents the unique identifier for the ledger entry","type":"string"},"journalId":{"title":"journal_id represents the journal identifier","type":"string"},"productId":{"title":"product_id represents the product identifier","type":"string"},"subType":{"title":"sub_type represents the type of the ledger entry (locked, available, etc.)","type":"string"},"type":{"title":"type represents the primary account type of the ledger entry (available, locked, limit, etc.)","type":"string"}},"required":["id","accountId","journalId","productId","amount","amountUsd","direction","type","subType","createdAt"],"title":"LedgerEntry represents a single ledger entry","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/ledger/v1/{accountId}/entries":{"get":{"description":"product_id, start_date and end_date are all optional and independently\ncombinable","operationId":"LedgerQueryService_GetLedgerEntriesFiltered","parameters":[{"description":"account_id represents the account identifier","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"product_id optionally filters entries to a single product","in":"query","name":"productId","required":false,"schema":{"type":"string"}},{"description":"start_date optionally filters entries created at or after this time","in":"query","name":"startDate","required":false,"schema":{"format":"date-time","type":"string"}},{"description":"end_date optionally filters entries created at or before this time","in":"query","name":"endDate","required":false,"schema":{"format":"date-time","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetLedgerEntriesFilteredResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetLedgerEntriesFiltered returns a user's entries filtered by product and time range","tags":["LedgerQueryService"]}}}}
```


# Market

## GetDexQuote returns a cross-chain route quote from the configured DEX provider

> Quote-only. Does not execute the swap. The response carries the ordered transactions the\
> caller has to submit to execute it, approvals included

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/market/v1/dex/quote":{"post":{"description":"Quote-only. Does not execute the swap. The response carries the ordered transactions the\ncaller has to submit to execute it, approvals included","operationId":"MarketQueryService_GetDexQuote","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/dexGetDexQuoteRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/dexGetDexQuoteResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetDexQuote returns a cross-chain route quote from the configured DEX provider","tags":["MarketQueryService"]}}},"components":{"schemas":{"dexGetDexQuoteRequest":{"properties":{"allowMultiHops":{"description":"allow_multi_hops allows routes that require more than one transaction.\nA route that needs more than one leg is priced here but never handed out executable: the\nresponse comes back without transactions, and the route is executed by creating a dex\nticket with the same flag, which offers one leg at a time as the previous one delivers.","type":"boolean"},"assetIn":{"$ref":"#/components/schemas/dexDexAssetAmount"},"assetOut":{"$ref":"#/components/schemas/dexDexAsset"},"senderAddress":{"description":"sender_address is the wallet address of the user initiating the swap.","type":"string"}},"required":["assetIn","assetOut"],"title":"GetDexQuoteRequest is the request body for the GetDexQuote method","type":"object"},"dexDexAssetAmount":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination (integer, no decimals)","type":"string"},"chainId":{"title":"chain_id is the chain the asset lives on","type":"string"},"denom":{"title":"denom is the asset denomination","type":"string"}},"required":["denom","chainId","amount"],"title":"DexAssetAmount is a cross-chain asset paired with an amount","type":"object"},"dexDexAsset":{"properties":{"chainId":{"title":"chain_id is the chain the asset lives on","type":"string"},"denom":{"title":"denom is the asset denomination (e.g. ERC-20 contract address or native token sentinel)","type":"string"}},"required":["denom","chainId"],"title":"DexAsset identifies a cross-chain asset by its denomination and chain","type":"object"},"dexGetDexQuoteResponse":{"properties":{"affiliateAddress":{"description":"affiliate_address is the address that receives the affiliate fee for this route.","type":"string"},"affiliateFeeBps":{"description":"affiliate_fee_bps is the affiliate fee in basis points applied to this route (e.g. 100 = 1.00%).","format":"int32","type":"integer"},"assetIn":{"$ref":"#/components/schemas/dexDexAssetAmount"},"assetOut":{"$ref":"#/components/schemas/dexDexAssetAmount"},"minAmountOut":{"description":"min_amount_out is the smallest output the route was built for, in the destination asset's\nbase units.","type":"string"},"provider":{"description":"provider identifies which DEX routing provider fulfilled this quote (\"skip\" or \"lifi\").","type":"string"},"swapPriceImpactPercent":{"title":"swap_price_impact_percent is the price impact of any swaps in the route","type":"string"},"transactions":{"description":"transactions is the ordered list the caller submits to execute the route, approvals included.\nEach transaction carries its own type (\"approval\", \"dexswap\"), so the client renders and\nsubmits them in order without inspecting the calldata.\nEmpty when sender_address was not supplied, which makes the response a pricing-only quote.\nAlso empty when the route needs more than one leg, which makes the response pricing-only\nwhatever was supplied: such a route is executed by creating a dex ticket with\nallow_multi_hops, which tracks each leg and offers the next one once the previous delivered.","items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"type":"array"},"usdAmountIn":{"title":"usd_amount_in is the USD value of the input amount","type":"string"},"usdAmountOut":{"title":"usd_amount_out is the USD value of the output amount","type":"string"}},"title":"GetDexQuoteResponse is the response for the GetDexQuote method","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```

## GetFiatAssets returns a list of fiat assets

> Static reference list of fiat currencies (ISO codes) supported across\
> on-ramp/off-ramp products

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.fiat_assets.read"]},{"BearerAuth":["market.fiat_assets.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"fiat_assetsGetFiatAssetsResponse":{"properties":{"fiatAssets":{"items":{"$ref":"#/components/schemas/v1FiatAsset"},"title":"fiat_assets represents the list of fiat assets","type":"array"}},"required":["fiatAssets"],"title":"GetFiatAssetsResponse is the body response structure from the GetFiatAssets endpoint","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/fiat-assets":{"get":{"description":"Static reference list of fiat currencies (ISO codes) supported across\non-ramp/off-ramp products","operationId":"MarketQueryService_GetFiatAssets","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/fiat_assetsGetFiatAssetsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetFiatAssets returns a list of fiat assets","tags":["MarketQueryService"]}}}}
```

## GetFiatAsset returns a fiat asset by id

> code is the 3-letter ISO fiat currency code (e.g. "USD", "BRL")

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.fiat_assets.read"]},{"BearerAuth":["market.fiat_assets.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"fiat_assetsGetFiatAssetResponse":{"properties":{"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"}},"required":["fiatAsset"],"title":"GetFiatAssetResponse is the body response structure from the GetFiatAsset endpoint","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/fiat-assets/{code}":{"get":{"description":"code is the 3-letter ISO fiat currency code (e.g. \"USD\", \"BRL\")","operationId":"MarketQueryService_GetFiatAsset","parameters":[{"description":"code represents the fiat asset identifier","in":"path","name":"code","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/fiat_assetsGetFiatAssetResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetFiatAsset returns a fiat asset by id","tags":["MarketQueryService"]}}}}
```

## ListInstruments lists all the instruments for the users

> Scoped to the instruments account\_id has access to, not a global list

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.instruments.read"]},{"BearerAuth":["market.instruments.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"instrumentsListInstrumentsResponse":{"properties":{"instruments":{"items":{"$ref":"#/components/schemas/instrumentsInstrument"},"title":"instruments is the list of instruments","type":"array"}},"required":["instruments"],"title":"ListInstrumentsResponse is the response message for the ListInstruments method","type":"object"},"instrumentsInstrument":{"properties":{"availability":{"$ref":"#/components/schemas/v1Availability"},"createdAt":{"format":"date-time","title":"created_at is the timestamp when the relation products providers was created","type":"string"},"description":{"title":"description is the description of the instrument","type":"string"},"enabled":{"title":"enabled is the flag that shows if the instrument is enabled or disabled","type":"boolean"},"id":{"title":"id is the instrument identificator","type":"string"},"name":{"title":"name is the name of the instrument","type":"string"},"productBase":{"$ref":"#/components/schemas/productsProduct"},"productQuote":{"$ref":"#/components/schemas/productsProduct"},"provider":{"$ref":"#/components/schemas/providersProvider"},"spread":{"$ref":"#/components/schemas/instrumentsSpread"},"updatedAt":{"format":"date-time","title":"updated_at is the timestamp when the relation products providers was updated","type":"string"}},"required":["id","name","description","productBase","productQuote","provider","enabled","spread","createdAt","updatedAt","availability"],"title":"Instrument defines the Instrument type","type":"object"},"v1Availability":{"properties":{"allowed":{"title":"allowed reports whether the account can use the row","type":"boolean"},"providerId":{"title":"provider_id is the provider whose onboarding is pending, only set for provider_kyc_required","type":"string"},"providerName":{"title":"provider_name is the display name of that provider, only set for provider_kyc_required","type":"string"},"reason":{"title":"reason is why the row is blocked, unset when allowed\n(kyc_required | country_not_supported | fiat_country_required | not_offered |\nprovider_kyc_required)","type":"string"},"requiredCountries":{"items":{"type":"string"},"title":"required_countries lists the ISO 3166-1 alpha-3 codes that would unlock the row,\nonly set for fiat_country_required","type":"array"}},"required":["allowed"],"title":"Availability tells whether the requesting account can use a row and, if not, why","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"instrumentsSpread":{"properties":{"bps":{"$ref":"#/components/schemas/instrumentsBpsSpread"}},"title":"Spread represents the Spread for an instrument","type":"object"},"instrumentsBpsSpread":{"properties":{"askBps":{"format":"int64","title":"ask_bps is the ask bps spread","type":"string"},"bidBps":{"format":"int64","title":"bid_bps is the bid bps spread","type":"string"}},"required":["bidBps","askBps"],"title":"BpsSpread represents a bps spread for an instrument","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/instruments":{"get":{"description":"Scoped to the instruments account_id has access to, not a global list","operationId":"MarketQueryService_ListInstruments","parameters":[{"description":"account_id is the account identifier used to validate if the user has access to the provider","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/instrumentsListInstrumentsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListInstruments lists all the instruments for the users","tags":["MarketQueryService"]}}}}
```

## GetInstrument retrieves a single instrument by its id

> account\_id is checked to confirm the caller has access to this\
> instrument before returning it

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.instruments.read"]},{"BearerAuth":["market.instruments.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"instrumentsGetInstrumentResponse":{"properties":{"instrument":{"$ref":"#/components/schemas/instrumentsInstrument"}},"required":["instrument"],"title":"GetInstrumentResponse is the response message for the GetInstrument method","type":"object"},"instrumentsInstrument":{"properties":{"availability":{"$ref":"#/components/schemas/v1Availability"},"createdAt":{"format":"date-time","title":"created_at is the timestamp when the relation products providers was created","type":"string"},"description":{"title":"description is the description of the instrument","type":"string"},"enabled":{"title":"enabled is the flag that shows if the instrument is enabled or disabled","type":"boolean"},"id":{"title":"id is the instrument identificator","type":"string"},"name":{"title":"name is the name of the instrument","type":"string"},"productBase":{"$ref":"#/components/schemas/productsProduct"},"productQuote":{"$ref":"#/components/schemas/productsProduct"},"provider":{"$ref":"#/components/schemas/providersProvider"},"spread":{"$ref":"#/components/schemas/instrumentsSpread"},"updatedAt":{"format":"date-time","title":"updated_at is the timestamp when the relation products providers was updated","type":"string"}},"required":["id","name","description","productBase","productQuote","provider","enabled","spread","createdAt","updatedAt","availability"],"title":"Instrument defines the Instrument type","type":"object"},"v1Availability":{"properties":{"allowed":{"title":"allowed reports whether the account can use the row","type":"boolean"},"providerId":{"title":"provider_id is the provider whose onboarding is pending, only set for provider_kyc_required","type":"string"},"providerName":{"title":"provider_name is the display name of that provider, only set for provider_kyc_required","type":"string"},"reason":{"title":"reason is why the row is blocked, unset when allowed\n(kyc_required | country_not_supported | fiat_country_required | not_offered |\nprovider_kyc_required)","type":"string"},"requiredCountries":{"items":{"type":"string"},"title":"required_countries lists the ISO 3166-1 alpha-3 codes that would unlock the row,\nonly set for fiat_country_required","type":"array"}},"required":["allowed"],"title":"Availability tells whether the requesting account can use a row and, if not, why","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"instrumentsSpread":{"properties":{"bps":{"$ref":"#/components/schemas/instrumentsBpsSpread"}},"title":"Spread represents the Spread for an instrument","type":"object"},"instrumentsBpsSpread":{"properties":{"askBps":{"format":"int64","title":"ask_bps is the ask bps spread","type":"string"},"bidBps":{"format":"int64","title":"bid_bps is the bid bps spread","type":"string"}},"required":["bidBps","askBps"],"title":"BpsSpread represents a bps spread for an instrument","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/instruments/{id}":{"get":{"description":"account_id is checked to confirm the caller has access to this\ninstrument before returning it","operationId":"MarketQueryService_GetInstrument","parameters":[{"description":"id is the id of the instrument","in":"path","name":"id","required":true,"schema":{"type":"string"}},{"description":"account_id is the account identifier used to validate if the user has access to the instrument","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/instrumentsGetInstrumentResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetInstrument retrieves a single instrument by its id","tags":["MarketQueryService"]}}}}
```

## GetInstrumentLimits retrieves the limits from the provided instrument

> Returns the min/max tradeable amount for the given side (buy or sell)

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.instruments.read"]},{"BearerAuth":["market.instruments.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"instrumentsGetInstrumentLimitsResponse":{"properties":{"limits":{"$ref":"#/components/schemas/v1InstrumentLimits"}},"required":["limits"],"title":"GetInstrumentLimitsResponse is the response message for the GetInstrumentLimits method","type":"object"},"v1InstrumentLimits":{"properties":{"maxBaseAmount":{"title":"max_base_amount contains the maximum amount of the input asset to perform the action","type":"string"},"maxQuoteAmount":{"title":"max_quote_amount contains the maximum amount of the output asset to perform the action","type":"string"},"minBaseAmount":{"title":"min_base_amount contains the minimum amount of the input asset to perform the action","type":"string"},"minQuoteAmount":{"title":"min_quote_amount contains the minimum amount of the output asset to perform the action","type":"string"}},"required":["minBaseAmount","maxBaseAmount","minQuoteAmount","maxQuoteAmount"],"title":"InstrumentLimits contains the limits for an instrument","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/instruments/{id}/limits":{"get":{"description":"Returns the min/max tradeable amount for the given side (buy or sell)","operationId":"MarketQueryService_GetInstrumentLimits","parameters":[{"description":"id is the id of the instrument","in":"path","name":"id","required":true,"schema":{"type":"string"}},{"description":"side is the side of the quote (buy or sell)","in":"query","name":"side","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/instrumentsGetInstrumentLimitsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetInstrumentLimits retrieves the limits from the provided instrument","tags":["MarketQueryService"]}}}}
```

## GetInstrumentQuote retrieves the quote from the provided instrument

> Applies the instrument's configured spread on top of the underlying\
> provider price for the given side (buy or sell) and amount

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.instruments.read"]},{"BearerAuth":["market.instruments.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"instrumentsGetInstrumentQuoteResponse":{"properties":{"instantSettlement":{"title":"instant_settlement predicts whether a ticket created from this quote settles without waiting\non an OTC approval. It is a hint only, the ticket checks again when it is created","type":"boolean"},"quote":{"$ref":"#/components/schemas/v1Quote"}},"required":["quote","instantSettlement"],"title":"GetInstrumentQuoteResponse is the response message for the GetInstrumentQuote method","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/instruments/{id}/quote":{"get":{"description":"Applies the instrument's configured spread on top of the underlying\nprovider price for the given side (buy or sell) and amount","operationId":"MarketQueryService_GetInstrumentQuote","parameters":[{"description":"id is the id of the instrument","in":"path","name":"id","required":true,"schema":{"type":"string"}},{"description":"amount contains the amount to transfer (must be atoms)","in":"query","name":"amount","required":true,"schema":{"type":"string"}},{"description":"account_id is the ID of the account used to sign the quote","in":"query","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"side is the side of the quote (buy or sell)","in":"query","name":"side","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/instrumentsGetInstrumentQuoteResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetInstrumentQuote retrieves the quote from the provided instrument","tags":["MarketQueryService"]}}}}
```

## ListProducts lists all products with optional filtering

> Returns every product regardless of enabled status. Filter client-side\
> if only enabled ones are needed

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products.read"]},{"BearerAuth":["market.products.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"productsListProductsResponse":{"properties":{"products":{"items":{"$ref":"#/components/schemas/productsProduct"},"title":"products is a list of retrieved products","type":"array"}},"required":["products"],"title":"ListProductsResponse is the response message for the ListProducts method","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products":{"get":{"description":"Returns every product regardless of enabled status. Filter client-side\nif only enabled ones are needed","operationId":"MarketQueryService_ListProducts","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/productsListProductsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListProducts lists all products with optional filtering","tags":["MarketQueryService"]}}}}
```

## ListProductsProviders returns the store relations products providers

> account\_id scopes the list to relations that account is allowed to use

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products_providers.read","market.products_providers.read:all"]},{"BearerAuth":["market.products_providers.read","market.products_providers.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"products_providersListProductsProvidersResponse":{"properties":{"productsProviders":{"items":{"$ref":"#/components/schemas/products_providersProductsProvider"},"title":"products_providers is the list of relations products providers","type":"array"}},"required":["productsProviders"],"title":"ListProductsProvidersResponse is the response message for the ListProductsProviders method","type":"object"},"products_providersProductsProvider":{"properties":{"availability":{"$ref":"#/components/schemas/v1Availability"},"createdAt":{"format":"date-time","title":"created_at is the timestamp when the relation products providers was created","type":"string"},"enabled":{"title":"enabled is the flag that shows if the relation products providers is enabled or disabled","type":"boolean"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the id of the relation products providers","type":"string"},"product":{"$ref":"#/components/schemas/productsProduct"},"provider":{"$ref":"#/components/schemas/providersProvider"},"type":{"title":"type is the type of the provider","type":"string"},"updatedAt":{"format":"date-time","title":"updated_at is the timestamp when the relation products providers was updated","type":"string"}},"required":["id","product","provider","fiatAsset","type","enabled","createdAt","updatedAt","availability"],"title":"ProductsProvider defines the ProductsProvider type","type":"object"},"v1Availability":{"properties":{"allowed":{"title":"allowed reports whether the account can use the row","type":"boolean"},"providerId":{"title":"provider_id is the provider whose onboarding is pending, only set for provider_kyc_required","type":"string"},"providerName":{"title":"provider_name is the display name of that provider, only set for provider_kyc_required","type":"string"},"reason":{"title":"reason is why the row is blocked, unset when allowed\n(kyc_required | country_not_supported | fiat_country_required | not_offered |\nprovider_kyc_required)","type":"string"},"requiredCountries":{"items":{"type":"string"},"title":"required_countries lists the ISO 3166-1 alpha-3 codes that would unlock the row,\nonly set for fiat_country_required","type":"array"}},"required":["allowed"],"title":"Availability tells whether the requesting account can use a row and, if not, why","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products-providers":{"get":{"description":"account_id scopes the list to relations that account is allowed to use","operationId":"MarketQueryService_ListProductsProviders","parameters":[{"description":"account_id is the ID of the account to verify if it's allowed to use the provider","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/products_providersListProductsProvidersResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListProductsProviders returns the store relations products providers","tags":["MarketQueryService"]}}}}
```

## GetProductsProvider returns a single products provider relation by ID

> account\_id is checked to confirm the caller can use this relation

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products_providers.read"]},{"BearerAuth":["market.products_providers.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"products_providersGetProductsProviderResponse":{"properties":{"productsProvider":{"$ref":"#/components/schemas/products_providersProductsProvider"}},"required":["productsProvider"],"title":"GetProductsProviderResponse is the response message for the GetProductsProvider method","type":"object"},"products_providersProductsProvider":{"properties":{"availability":{"$ref":"#/components/schemas/v1Availability"},"createdAt":{"format":"date-time","title":"created_at is the timestamp when the relation products providers was created","type":"string"},"enabled":{"title":"enabled is the flag that shows if the relation products providers is enabled or disabled","type":"boolean"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the id of the relation products providers","type":"string"},"product":{"$ref":"#/components/schemas/productsProduct"},"provider":{"$ref":"#/components/schemas/providersProvider"},"type":{"title":"type is the type of the provider","type":"string"},"updatedAt":{"format":"date-time","title":"updated_at is the timestamp when the relation products providers was updated","type":"string"}},"required":["id","product","provider","fiatAsset","type","enabled","createdAt","updatedAt","availability"],"title":"ProductsProvider defines the ProductsProvider type","type":"object"},"v1Availability":{"properties":{"allowed":{"title":"allowed reports whether the account can use the row","type":"boolean"},"providerId":{"title":"provider_id is the provider whose onboarding is pending, only set for provider_kyc_required","type":"string"},"providerName":{"title":"provider_name is the display name of that provider, only set for provider_kyc_required","type":"string"},"reason":{"title":"reason is why the row is blocked, unset when allowed\n(kyc_required | country_not_supported | fiat_country_required | not_offered |\nprovider_kyc_required)","type":"string"},"requiredCountries":{"items":{"type":"string"},"title":"required_countries lists the ISO 3166-1 alpha-3 codes that would unlock the row,\nonly set for fiat_country_required","type":"array"}},"required":["allowed"],"title":"Availability tells whether the requesting account can use a row and, if not, why","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products-providers/{id}":{"get":{"description":"account_id is checked to confirm the caller can use this relation","operationId":"MarketQueryService_GetProductsProvider","parameters":[{"description":"id is the id of the relation products providers to retrieve","in":"path","name":"id","required":true,"schema":{"type":"string"}},{"description":"account_id is the ID of the account to verify if it's allowed to use the provider","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/products_providersGetProductsProviderResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetProductsProvider returns a single products provider relation by ID","tags":["MarketQueryService"]}}}}
```

## GetProductProviderLimits retrieves the limits for a provider based on the product, fiat and amount

> Returns the min/max tradeable amount for on-ramp/off-ramp through this\
> relation

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products.read"]},{"BearerAuth":["market.products.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"products_providersGetProductProviderLimitsResponse":{"properties":{"limits":{"$ref":"#/components/schemas/v1Limits"}},"required":["limits"],"title":"GetProductProviderLimitsResponse is the response message for the GetProductProviderLimits method","type":"object"},"v1Limits":{"properties":{"maxFiatAmount":{"title":"max_fiat_amount contains the maximum amount of fiat asset to perform the action","type":"string"},"maxTokenAmount":{"title":"max_token_amount contains the maximum amount of token asset to perform the action","type":"string"},"minFiatAmount":{"title":"min_fiat_amount contains the minimum amount of fiat asset to perform the action","type":"string"},"minTokenAmount":{"title":"min_token_amount contains the minimum amount of token asset to perform the action","type":"string"}},"required":["minFiatAmount","maxFiatAmount","minTokenAmount","maxTokenAmount"],"title":"Limits contains the limits for a product_provider to perform an action\noff-ramp or on-ramp","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products-providers/{id}/limits":{"get":{"description":"Returns the min/max tradeable amount for on-ramp/off-ramp through this\nrelation","operationId":"MarketQueryService_GetProductProviderLimits","parameters":[{"description":"id is the id of the relation products providers","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/products_providersGetProductProviderLimitsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetProductProviderLimits retrieves the limits for a provider based on the product, fiat and amount","tags":["MarketQueryService"]}}}}
```

## ProcessOnRamp initializes the on-ramp process with the given information

> Creates the on-ramp ticket and returns a provider-specific payload\
> Either a redirect URL (e.g. MoonPay widget) or PIX payment details\
> (e.g. Avenia PIX), depending on the provider

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Mutations (write operations)","name":"MarketMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products_providers_onramp.write"]},{"BearerAuth":["market.products_providers_onramp.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"MarketMsgServiceProcessOnRampBody":{"properties":{"accountId":{"title":"account_id is the ID of the account to verify if it's allowed to use the provider","type":"string"},"destinationId":{"title":"destination_id is the address that receives the funds, required for a crypto product and\nomitted for a fiat product (which settles inside the provider's own ledger)","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"}},"required":["accountId","quote"],"title":"ProcessOnRampRequest is the request message for the ProcessOnRamp method","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"products_providersProcessOnRampResponse":{"description":"ProcessOnRampResponse is the response message for the ProcessOnRamp method.\nExactly one of url_payload or deposit_payload is set, depending on the on-ramp type.","properties":{"depositPayload":{"$ref":"#/components/schemas/products_providersOnRampDepositPayload"},"ticketId":{"title":"ticket_id is the ticket ID associated with the on-ramp process","type":"string"},"urlPayload":{"$ref":"#/components/schemas/products_providersOnRampUrlPayload"}},"required":["ticketId"],"type":"object"},"products_providersOnRampDepositPayload":{"description":"OnRampDepositPayload contains the bank-deposit details returned by deposit-based\non-ramp providers. It is rail-agnostic: deposit_key holds the destination\nidentifier (a PIX key, a SPEI CLABE, or any future equivalent) and deposit_code\nholds an optional scannable/copy-paste code (e.g. the PIX BR Code).","properties":{"depositCode":{"title":"deposit_code is an optional copy-paste / QR code for the deposit (e.g. PIX BR Code)","type":"string"},"depositKey":{"title":"deposit_key is the destination identifier the user transfers funds to\n(PIX key, CLABE, etc.)","type":"string"}},"type":"object"},"products_providersOnRampUrlPayload":{"properties":{"expiresAt":{"format":"int64","title":"expires_at is the Unix timestamp when the URL expires","type":"string"},"url":{"title":"url is the redirect URL or widget URL","type":"string"}},"required":["url","expiresAt"],"title":"OnRampUrlPayload contains the redirect URL and expiry for URL-based on-ramp providers","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products-providers/{id}/onramp":{"post":{"description":"Creates the on-ramp ticket and returns a provider-specific payload\nEither a redirect URL (e.g. MoonPay widget) or PIX payment details\n(e.g. Avenia PIX), depending on the provider","operationId":"MarketMsgService_ProcessOnRamp","parameters":[{"description":"id is the id of the relation products providers","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketMsgServiceProcessOnRampBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/products_providersProcessOnRampResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ProcessOnRamp initializes the on-ramp process with the given information","tags":["MarketMsgService"]}}}}
```

## GetProductProviderQuote retrieves the quote for a product based on the provider, fiat and amount

> Quote-only. Use ProcessOnRamp separately to act on it. amount can be\
> crypto (atoms) or fiat (decimal) depending on the relation's direction

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products.read"]},{"BearerAuth":["market.products.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"products_providersGetProductProviderQuoteResponse":{"properties":{"instantSettlement":{"title":"instant_settlement predicts whether a ticket created from this quote settles without waiting\non an OTC approval. It is a hint only, the ticket checks again when it is created","type":"boolean"},"quote":{"$ref":"#/components/schemas/v1Quote"}},"required":["quote","instantSettlement"],"title":"GetProductProviderQuoteResponse is the response message for the GetProductProviderQuote method","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products-providers/{id}/quote":{"get":{"description":"Quote-only. Use ProcessOnRamp separately to act on it. amount can be\ncrypto (atoms) or fiat (decimal) depending on the relation's direction","operationId":"MarketQueryService_GetProductProviderQuote","parameters":[{"description":"id is the id of the relation products providers","in":"path","name":"id","required":true,"schema":{"type":"string"}},{"description":"amount contains the amount to transfer (can be crypto in atoms or fiat in decimals)","in":"query","name":"amount","required":true,"schema":{"type":"string"}},{"description":"account_id is the ID of the account used to sign the quote","in":"query","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"withdraw_destination_id is the account's withdrawal destination an off-ramp sends to, used by\nproviders whose fee depends on the bank rail, ignored by the rest","in":"query","name":"withdrawDestinationId","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/products_providersGetProductProviderQuoteResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetProductProviderQuote retrieves the quote for a product based on the provider, fiat and amount","tags":["MarketQueryService"]}}}}
```

## GetProduct retrieves a product by its ID

> Includes the product's chain/token, fee spec and AML check flag

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.products.read"]},{"BearerAuth":["market.products.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"productsGetProductResponse":{"properties":{"product":{"$ref":"#/components/schemas/productsProduct"}},"required":["product"],"title":"GetProductResponse is the response message for the GetProduct method","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/products/{productId}":{"get":{"description":"Includes the product's chain/token, fee spec and AML check flag","operationId":"MarketQueryService_GetProduct","parameters":[{"description":"product_id is the ID of the product to retrieve","in":"path","name":"productId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/productsGetProductResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetProduct retrieves a product by its ID","tags":["MarketQueryService"]}}}}
```

## ListProviders returns all registered providers

> DB-registered providers only. Use ListRegistryProviders to see\
> providers implemented in code but not yet registered

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.providers.read"]},{"BearerAuth":["market.providers.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"providersListProvidersResponse":{"properties":{"providers":{"items":{"$ref":"#/components/schemas/providersProvider"},"title":"providers is a list of retrieved providers","type":"array"}},"required":["providers"],"title":"ListProvidersResponse is the response message for the ListProviders method","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/providers":{"get":{"description":"DB-registered providers only. Use ListRegistryProviders to see\nproviders implemented in code but not yet registered","operationId":"MarketQueryService_ListProviders","parameters":[{"description":"account_id is the ID of the account to verify if it's allowed to use the provider","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/providersListProvidersResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListProviders returns all registered providers","tags":["MarketQueryService"]}}}}
```

## GetProvider returns the provided information from the Id

> account\_id is used to resolve kyc\_status for that specific account on this provider

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.providers.read"]},{"BearerAuth":["market.providers.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"providersGetProviderResponse":{"properties":{"provider":{"$ref":"#/components/schemas/providersProvider"}},"required":["provider"],"title":"GetProviderResponse is the response message for the GetProvider method","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/providers/{providerId}":{"get":{"description":"account_id is used to resolve kyc_status for that specific account on this provider","operationId":"MarketQueryService_GetProvider","parameters":[{"description":"provider_id is the ID of the provider to retrieve","in":"path","name":"providerId","required":true,"schema":{"type":"string"}},{"description":"account_id is the ID of the account associated to the provider","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/providersGetProviderResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetProvider returns the provided information from the Id","tags":["MarketQueryService"]}}}}
```

## GetProviderKyc returns the KYC data for the user on the given provider

> Always fetches a fresh status from the provider and persists a history\
> record. It doesn't just read the last known status from the DB

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Mutations (write operations)","name":"MarketMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.providers.read"]},{"BearerAuth":["market.providers.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"MarketMsgServiceGetProviderKycBody":{"title":"GetProviderKycRequest is the request message for the GetProviderKyc method","type":"object"},"providersGetProviderKycResponse":{"properties":{"basicCompanyDataUrl":{"description":"basic_company_data_url is the second URL for KYB (company) accounts only.\nPresent when the sub-account is a company; absent for individual KYC.","type":"string"},"history":{"items":{"$ref":"#/components/schemas/providersProviderKycEvent"},"title":"history contains the chronological list of KYC status changes for this account","type":"array"},"metadata":{"title":"metadata contains provider-specific KYC metadata","type":"object"},"nextUrl":{"description":"next_url is the redirect URL to continue the KYC process (when applicable).\nFor KYB (company) accounts this is the authorized representative URL.","type":"string"},"providerAccountId":{"title":"provider_account_id is the provider-side account identifier linked to this user","type":"string"},"reason":{"title":"reason contains the rejection reason when status is REJECTED","type":"string"},"status":{"description":"status is the current KYC status for the account on this provider.\nPossible values: \"pending\", \"processing\", \"verified\", \"rejected\".","type":"string"}},"required":["status","history"],"title":"GetProviderKycResponse is the response message for the GetProviderKyc method","type":"object"},"providersProviderKycEvent":{"properties":{"createdAt":{"format":"date-time","title":"created_at is when this event was recorded","type":"string"},"reason":{"title":"reason contains the rejection reason when status is REJECTED","type":"string"},"status":{"description":"status is the KYC status at the time this event was recorded.\nPossible values: \"pending\", \"processing\", \"verified\", \"rejected\".","type":"string"}},"required":["status","createdAt"],"title":"ProviderKycEvent represents a single KYC status change recorded in history","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/providers/{providerId}/kyc/{accountId}":{"post":{"description":"Always fetches a fresh status from the provider and persists a history\nrecord. It doesn't just read the last known status from the DB","operationId":"MarketMsgService_GetProviderKyc","parameters":[{"description":"provider_id is the DB ID of the provider","in":"path","name":"providerId","required":true,"schema":{"type":"string"}},{"description":"account_id is the ID of the account to retrieve KYC data for","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketMsgServiceGetProviderKycBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/providersGetProviderKycResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetProviderKyc returns the KYC data for the user on the given provider","tags":["MarketMsgService"]}}}}
```

## StartProviderKyc initiates the KYC process for the user on the given provider

> Creates the provider sub-account and returns the KYC redirect URL. Must\
> be called explicitly by the user. GetProviderKyc no longer auto-triggers\
> this

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Mutations (write operations)","name":"MarketMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.providers.read"]},{"BearerAuth":["market.providers.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"MarketMsgServiceStartProviderKycBody":{"title":"StartProviderKycRequest is the request message for the StartProviderKyc method","type":"object"},"providersStartProviderKycResponse":{"properties":{"basicCompanyDataUrl":{"description":"basic_company_data_url is the second URL for KYB (company) accounts only.\nPresent when the sub-account is a company; absent for individual KYC.","type":"string"},"nextUrl":{"description":"next_url is the redirect URL the user must follow to complete the KYC process.\nFor KYB (company) accounts this is the authorized representative URL.","type":"string"},"status":{"description":"status is the current KYC status after initiating the flow.\nPossible values: \"pending\", \"processing\", \"verified\", \"rejected\".","type":"string"}},"required":["status"],"title":"StartProviderKycResponse is the response message for the StartProviderKyc method","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/providers/{providerId}/kyc/{accountId}/start":{"post":{"description":"Creates the provider sub-account and returns the KYC redirect URL. Must\nbe called explicitly by the user. GetProviderKyc no longer auto-triggers\nthis","operationId":"MarketMsgService_StartProviderKyc","parameters":[{"description":"provider_id is the DB ID of the provider","in":"path","name":"providerId","required":true,"schema":{"type":"string"}},{"description":"account_id is the ID of the account to initiate KYC for","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketMsgServiceStartProviderKycBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/providersStartProviderKycResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"StartProviderKyc initiates the KYC process for the user on the given provider","tags":["MarketMsgService"]}}}}
```

## ListTradeInstruments lists the trade instruments available to the account

> Each instrument carries its hydrated products so the caller can render the\
> pair picker that GetTradeInstrumentQuote expects

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TradeInstrumentsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.trade_instrument.read"]},{"BearerAuth":["market.trade_instrument.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"trade_instrumentsListTradeInstrumentsResponse":{"properties":{"tradeInstruments":{"items":{"$ref":"#/components/schemas/trade_instrumentsTradeInstrument"},"title":"trade_instruments contains the instruments with their products hydrated","type":"array"}},"title":"ListTradeInstrumentsResponse contains the trade instruments available to the account","type":"object"},"trade_instrumentsTradeInstrument":{"properties":{"createdAt":{"format":"date-time","title":"created_at contains the creation date of the instrument","type":"string"},"description":{"title":"description contains the description of the trade instrument","type":"string"},"enabled":{"title":"enabled reports whether the instrument can be quoted","type":"boolean"},"id":{"title":"id contains the identifier of the trade instrument","type":"string"},"name":{"title":"name contains the name of the trade instrument","type":"string"},"products":{"items":{"$ref":"#/components/schemas/trade_instrumentsTradeInstrumentProduct"},"title":"products contains the base and quote products of the instrument","type":"array"},"provider":{"$ref":"#/components/schemas/providersProvider"},"spread":{"$ref":"#/components/schemas/instrumentsSpread"},"updatedAt":{"format":"date-time","title":"updated_at contains the last update date of the instrument","type":"string"}},"title":"TradeInstrument is a tradable group of products quoted by a single provider","type":"object"},"trade_instrumentsTradeInstrumentProduct":{"properties":{"availability":{"$ref":"#/components/schemas/v1Availability"},"product":{"$ref":"#/components/schemas/productsProduct"},"role":{"title":"role is base or quote","type":"string"}},"required":["product","role","availability"],"title":"TradeInstrumentProduct is a product attached to an instrument, hydrated","type":"object"},"v1Availability":{"properties":{"allowed":{"title":"allowed reports whether the account can use the row","type":"boolean"},"providerId":{"title":"provider_id is the provider whose onboarding is pending, only set for provider_kyc_required","type":"string"},"providerName":{"title":"provider_name is the display name of that provider, only set for provider_kyc_required","type":"string"},"reason":{"title":"reason is why the row is blocked, unset when allowed\n(kyc_required | country_not_supported | fiat_country_required | not_offered |\nprovider_kyc_required)","type":"string"},"requiredCountries":{"items":{"type":"string"},"title":"required_countries lists the ISO 3166-1 alpha-3 codes that would unlock the row,\nonly set for fiat_country_required","type":"array"}},"required":["allowed"],"title":"Availability tells whether the requesting account can use a row and, if not, why","type":"object"},"productsProduct":{"properties":{"applyAmlCheck":{"title":"apply_aml_check indicates whether an AML check via Elliptic should be run before the ticket is accepted","type":"boolean"},"chainToken":{"$ref":"#/components/schemas/v1ChainToken"},"enabled":{"title":"enabled indicates whether the product is enabled","type":"boolean"},"feeSpec":{"$ref":"#/components/schemas/productsFeeSpec"},"fiatAsset":{"$ref":"#/components/schemas/v1FiatAsset"},"id":{"title":"id is the ID of the product","type":"string"},"name":{"title":"name is the name of the product","type":"string"},"type":{"title":"type contains the type of the product (crypto | fiat)","type":"string"}},"required":["id","name","enabled","feeSpec","applyAmlCheck","type"],"title":"Product represents a product in the market","type":"object"},"v1ChainToken":{"properties":{"chain":{"$ref":"#/components/schemas/v1Chain"},"chainTokenEnabled":{"title":"chain_token_enabled indicates whether the token is enabled for this specific chain","type":"boolean"},"contractAddress":{"title":"contract_address is the smart contract address of the token on the chain (null for native tokens)","type":"string"},"enabledDex":{"title":"enabled_dex indicates whether the token is enabled for DEX operations on this chain","type":"boolean"},"fireblocksDenom":{"title":"fireblocks_denom is the asset denomination Fireblocks uses for this chain-token (e.g.\n\"USDT_POLYGON\"), used to interact with Fireblocks custody instead of resolving it live from\nFireblocks' own API - null if this asset isn't Fireblocks-custodied","type":"string"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain-token relation","type":"integer"},"native":{"title":"native indicates whether the token is native to the chain","type":"boolean"},"token":{"$ref":"#/components/schemas/v1Token"}},"required":["id","chain","token","native","chainTokenEnabled","enabledDex"],"title":"ChainToken represents a token enabled on a specific chain","type":"object"},"v1Chain":{"properties":{"chainId":{"title":"chain_id is the blockchain network identifier (e.g., \"1\" for Ethereum, \"137\" for Polygon)","type":"string"},"confirmationDepth":{"format":"int32","title":"confirmation_depth is the number of block confirmations required before processing","type":"integer"},"contracts":{"additionalProperties":{"$ref":"#/components/schemas/v1ContractEntry"},"title":"contracts maps contract name to its on-chain address and ABI version","type":"object"},"enabled":{"title":"enabled indicates whether the chain is enabled on the platform","type":"boolean"},"feeAddress":{"title":"fee_address is the address that receives the affiliate fee on this chain","type":"string"},"feeBps":{"format":"int32","title":"fee_bps is the affiliate fee in basis points charged on routes through this chain (e.g. 30 = 0.30%)","type":"integer"},"id":{"format":"int32","title":"id is the surrogate identifier of the chain","type":"integer"},"logo":{"title":"logo is the URL to the logo of the chain","type":"string"},"name":{"title":"name is the human-readable name of the chain","type":"string"},"testnet":{"title":"testnet indicates whether the chain is a testnet or mainnet","type":"boolean"},"type":{"title":"type is the type of the chain (e.g., \"evm\", \"cosmos\", \"solana\", \"bitcoin\", \"tron\")","type":"string"}},"required":["id","chainId","type","name","logo","testnet","enabled","confirmationDepth","contracts"],"title":"Chain represents a chain supported by the platform","type":"object"},"v1ContractEntry":{"properties":{"address":{"title":"address is the on-chain contract address","type":"string"},"version":{"title":"version is the optional version identifier","type":"string"}},"required":["address"],"title":"ContractEntry represents a single on-chain contract: its address and optional ABI version","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"productsFeeSpec":{"properties":{"bpsValue":{"title":"bps_value is the basis points (0–10000); required for bps and max fee types","type":"string"},"flatValue":{"title":"flat_value is the fixed fee amount; required for flat and max fee types","type":"string"},"type":{"title":"type is the type of fee specification (flat, bps or max)","type":"string"}},"required":["type"],"title":"FeeSpec represents the fee specification for a product","type":"object"},"v1FiatAsset":{"properties":{"code":{"title":"code represents the fiat asset identifier using ISO 4217","type":"string"},"country":{"title":"country is the ISO 3166-1 alpha-3 code of the issuing country (e.g. USA, BRA)\nor EUR for the European Union","type":"string"},"minorUnits":{"format":"int32","title":"minor_units is the number of decimal places this fiat currency's minor unit uses (e.g. 2 for\nBRL/MXN centavos) - the source of truth for converting between fiat minor units and face value","type":"integer"},"name":{"title":"name represents the fiat asset name","type":"string"},"symbol":{"title":"symbol represents the fiat asset symbol","type":"string"}},"required":["code","name","symbol","minorUnits"],"title":"FiatAsset contains the fiat asset data","type":"object"},"providersProvider":{"properties":{"additionalTemplate":{"$ref":"#/components/schemas/typesV1Schema"},"alias":{"title":"alias is the user-facing label shown instead of the name (e.g. the stablecoin \"BRLA\"),\nunset when the name should be shown","type":"string"},"autoConfirm":{"title":"auto_confirm indicates whether the provider's off-ramp tickets are automatically confirmed","type":"boolean"},"enabled":{"title":"enabled indicates whether the provider is enabled","type":"boolean"},"id":{"title":"id is the ID of the provider","type":"string"},"identifier":{"title":"identifier is the identifier of the provider","type":"string"},"kycStatus":{"description":"kyc_status is the current KYC verification status for the requesting user on this provider.","type":"string"},"name":{"title":"name is the name of the provider","type":"string"}},"required":["id","identifier","name","enabled","kycStatus","autoConfirm"],"title":"Provider defines the Provider","type":"object"},"typesV1Schema":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/v1FieldSchema"},"title":"fields are the fields that the schema contains","type":"array"},"title":{"title":"title is the name of the schema","type":"string"}},"required":["title","fields"],"title":"Schema defines the Schema type used to returns schemas on Rails and providers","type":"object"},"v1FieldSchema":{"properties":{"name":{"title":"name is the name of the field required by the backend","type":"string"},"optionLogos":{"additionalProperties":{"type":"string"},"title":"option_logos maps an option to its logo URL (e.g. bank logos on a bank selector),\nonly set for options that have a logo","type":"object"},"optional":{"title":"optional contains the flag that determines if the field is optional or not","type":"boolean"},"options":{"items":{"type":"string"},"title":"options contains the available options if type is an enum","type":"array"},"pattern":{"title":"pattern contains the regex expresion to evaluate the field","type":"string"},"type":{"title":"type contains the type of the field","type":"string"},"visibleWhen":{"items":{"$ref":"#/components/schemas/v1FieldCondition"},"title":"visible_when lists the conditions to show and validate the field\nEmpty means the field is always shown","type":"array"}},"required":["name","type","optional"],"title":"FieldSchema describe the field on the schema and its properties","type":"object"},"v1FieldCondition":{"properties":{"field":{"title":"field is the name of the field the condition looks at","type":"string"},"values":{"items":{"type":"string"},"title":"values are the values of the field that make the condition hold","type":"array"}},"required":["field","values"],"title":"FieldCondition holds when another field of the schema has one of the values","type":"object"},"instrumentsSpread":{"properties":{"bps":{"$ref":"#/components/schemas/instrumentsBpsSpread"}},"title":"Spread represents the Spread for an instrument","type":"object"},"instrumentsBpsSpread":{"properties":{"askBps":{"format":"int64","title":"ask_bps is the ask bps spread","type":"string"},"bidBps":{"format":"int64","title":"bid_bps is the bid bps spread","type":"string"}},"required":["bidBps","askBps"],"title":"BpsSpread represents a bps spread for an instrument","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/trade-instruments":{"get":{"description":"Each instrument carries its hydrated products so the caller can render the\npair picker that GetTradeInstrumentQuote expects","operationId":"TradeInstrumentsQueryService_ListTradeInstruments","parameters":[{"description":"account_id is the identifier of the account listing the instruments","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/trade_instrumentsListTradeInstrumentsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListTradeInstruments lists the trade instruments available to the account","tags":["TradeInstrumentsQueryService"]}}}}
```

## GetTradeInstrumentQuote returns a quote for a pair inside a trade instrument

> Both legs are named explicitly. Exactly one of them must be the instrument's\
> quote product, which is what determines the side of the trade

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TradeInstrumentsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.trade_instrument.read"]},{"BearerAuth":["market.trade_instrument.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"trade_instrumentsGetTradeInstrumentQuoteResponse":{"properties":{"quote":{"$ref":"#/components/schemas/v1Quote"}},"title":"GetTradeInstrumentQuoteResponse contains the signed quote for the pair","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/trade-instruments/{id}/quote":{"get":{"description":"Both legs are named explicitly. Exactly one of them must be the instrument's\nquote product, which is what determines the side of the trade","operationId":"TradeInstrumentsQueryService_GetTradeInstrumentQuote","parameters":[{"description":"id contains the identifier of the trade instrument","in":"path","name":"id","required":true,"schema":{"type":"string"}},{"description":"account_id is the identifier of the account requesting the quote","in":"query","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"product_in_id is the product the user gives up","in":"query","name":"productInId","required":true,"schema":{"type":"string"}},{"description":"product_out_id is the product the user receives","in":"query","name":"productOutId","required":true,"schema":{"type":"string"}},{"description":"amount contains the amount of product_in, in atoms for crypto products and in the fiat\nnormal unit like 1000.56 for fiat products","in":"query","name":"amount","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/trade_instrumentsGetTradeInstrumentQuoteResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTradeInstrumentQuote returns a quote for a pair inside a trade instrument","tags":["TradeInstrumentsQueryService"]}}}}
```

## CreateYieldDeposit creates a deposit intent for a yield vault

> Returns the ERC-20 transfer the frontend signs and broadcasts from the user's\
> connected wallet, which then reports the hash back through ReportYieldDepositTx\
> The transaction's from is left empty, only the frontend knows the signing wallet

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Mutations (write operations)","name":"MarketMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.write"]},{"BearerAuth":["market.yields.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsCreateYieldDepositRequest":{"properties":{"accountId":{"title":"account_id is the depositing account","type":"string"},"amount":{"title":"amount is the exact deposit amount in token units","type":"string"},"chain":{"title":"chain is the provider network key the transfer happens on, e.g. ethereum, base,\narbitrum, polygon, ethereum_sepolia","type":"string"},"userAddress":{"description":"Required whenever the chain charges a deposit fee: the fee is collected through\nKiiRouter, which binds the request to one signer and refuses any other sender. A\nchain with no fee configured builds a plain transfer and ignores this field","title":"user_address is the wallet the transfer is signed from","type":"string"},"vaultId":{"title":"vault_id is the vault to deposit into","type":"string"}},"required":["accountId","vaultId","amount","chain"],"title":"CreateYieldDepositRequest is the request message for the CreateYieldDeposit method","type":"object"},"yieldsCreateYieldDepositResponse":{"properties":{"amount":{"title":"amount is the exact amount the frontend must send","type":"string"},"chain":{"title":"chain is the provider network key of the transfer, e.g. ethereum, base, arbitrum,\npolygon, ethereum_sepolia","type":"string"},"depositAddress":{"title":"deposit_address is where the transfer must be sent","type":"string"},"depositId":{"title":"deposit_id is our deposit intent id","type":"string"},"fee":{"$ref":"#/components/schemas/yieldsYieldFee"},"netAmount":{"title":"net_amount is what reaches the vault: amount minus the fee. It is the amount the\nposition and the deposit history are recorded against","type":"string"},"status":{"title":"status is the deposit status: pending, sent, processing, completed, failed, expired","type":"string"},"tokenContract":{"title":"token_contract is the ERC-20 contract the transfer is called on","type":"string"},"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"title":"transactions is the transfer the frontend signs and broadcasts, from is left empty","type":"array"},"walletStatus":{"title":"wallet_status is the provisioning state of the account's yield wallet: creating, idle,\nfailed. Only idle carries a deposit, every other value leaves every other field on this\nmessage empty (fee included, which arrives null) and means the caller should retry once\nthe wallet settles","type":"string"}},"required":["depositId","status","depositAddress","tokenContract","chain","amount","transactions","walletStatus","fee","netAmount"],"title":"CreateYieldDepositResponse is the response message for the CreateYieldDeposit method","type":"object"},"yieldsYieldFee":{"properties":{"amount":{"title":"amount is the charged fee in token units, \"0\" when the chain charges nothing","type":"string"},"asset":{"title":"asset is the token the fee is taken in, always the vault deposit token","type":"string"},"type":{"title":"type is how the fee was computed: flat, bps or max, empty when the chain charges nothing","type":"string"}},"required":["type","amount","asset"],"title":"YieldFee is what Kii charges on a yields operation, deducted from the amount the user\ncommits. type is flat, bps or max, amount is in token units and asset is the token symbol","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/deposits":{"post":{"description":"Returns the ERC-20 transfer the frontend signs and broadcasts from the user's\nconnected wallet, which then reports the hash back through ReportYieldDepositTx\nThe transaction's from is left empty, only the frontend knows the signing wallet","operationId":"MarketMsgService_CreateYieldDeposit","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsCreateYieldDepositRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsCreateYieldDepositResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateYieldDeposit creates a deposit intent for a yield vault","tags":["MarketMsgService"]}}}}
```

## ListYieldDeposits lists the account's deposit history

> Includes in-flight intents, used by the frontend to poll deposit status

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.read"]},{"BearerAuth":["market.yields.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsListYieldDepositsResponse":{"properties":{"deposits":{"items":{"$ref":"#/components/schemas/yieldsYieldDeposit"},"title":"deposits are the account's deposit records, newest first","type":"array"}},"title":"ListYieldDepositsResponse is the response message for the ListYieldDeposits method","type":"object"},"yieldsYieldDeposit":{"properties":{"amount":{"title":"amount is the deposit amount in token units","type":"string"},"chain":{"title":"chain is the provider network key of the transfer, e.g. ethereum, base, arbitrum,\npolygon, ethereum_sepolia","type":"string"},"createdAt":{"title":"created_at is the intent creation time in RFC 3339","type":"string"},"id":{"title":"id is our deposit intent id","type":"string"},"source":{"title":"source is user or unsolicited","type":"string"},"status":{"title":"status is pending, sent, processing, completed, failed or expired","type":"string"},"token":{"title":"token is the deposited token symbol","type":"string"},"txHash":{"title":"tx_hash is the on-chain transfer hash once known","type":"string"},"vaultId":{"title":"vault_id is the vault deposited into","type":"string"}},"required":["id","vaultId","source","chain","token","amount","status","createdAt"],"title":"YieldDeposit is a deposit intent record","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/deposits/{accountId}":{"get":{"description":"Includes in-flight intents, used by the frontend to poll deposit status","operationId":"MarketQueryService_ListYieldDeposits","parameters":[{"description":"account_id is the account to list deposits for","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsListYieldDepositsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListYieldDeposits lists the account's deposit history","tags":["MarketQueryService"]}}}}
```

## ReportYieldDepositTx attaches the frontend-signed transaction hash to a deposit

> Called after the user's connected wallet broadcasts the transfer, moving the\
> deposit intent from pending to sent

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Mutations (write operations)","name":"MarketMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.write"]},{"BearerAuth":["market.yields.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"MarketMsgServiceReportYieldDepositTxBody":{"properties":{"accountId":{"title":"account_id is the owning account","type":"string"},"txHash":{"title":"tx_hash is the broadcast transaction hash","type":"string"}},"required":["accountId","txHash"],"title":"ReportYieldDepositTxRequest is the request message for the ReportYieldDepositTx method","type":"object"},"yieldsReportYieldDepositTxResponse":{"title":"ReportYieldDepositTxResponse is the response message for the ReportYieldDepositTx method","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/deposits/{depositId}/tx":{"post":{"description":"Called after the user's connected wallet broadcasts the transfer, moving the\ndeposit intent from pending to sent","operationId":"MarketMsgService_ReportYieldDepositTx","parameters":[{"description":"deposit_id is the deposit intent the transaction belongs to","in":"path","name":"depositId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketMsgServiceReportYieldDepositTxBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsReportYieldDepositTxResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ReportYieldDepositTx attaches the frontend-signed transaction hash to a deposit","tags":["MarketMsgService"]}}}}
```

## GetYieldPortfolio returns the account's position in each vault

> Balances, earned yield and withdrawable amounts are read through from the\
> yields provider per active wallet

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.read"]},{"BearerAuth":["market.yields.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsGetYieldPortfolioResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/yieldsYieldPortfolioEntry"},"title":"entries are the account's vault positions","type":"array"}},"title":"GetYieldPortfolioResponse is the response message for the GetYieldPortfolio method","type":"object"},"yieldsYieldPortfolioEntry":{"properties":{"cashUsd":{"title":"cash_usd is idle undeployed cash, non-zero when a deposit was below the\nprovider deployment minimum","type":"string"},"earnedUsd":{"title":"earned_usd is the yield earned in USD","type":"string"},"reservedUsd":{"title":"reserved_usd is the part of the balance the provider is holding and will not pay out\nyet, typically funds moving through a rebalance or an in-flight withdrawal. A\nwithdrawal larger than total_usd minus reserved_usd is rejected","type":"string"},"totalUsd":{"title":"total_usd is the current position value in USD","type":"string"},"vault":{"$ref":"#/components/schemas/yieldsYieldVault"},"withdrawableUsd":{"title":"withdrawable_usd is the amount currently withdrawable in USD","type":"string"}},"required":["vault","totalUsd","earnedUsd","withdrawableUsd"],"title":"YieldPortfolioEntry is the account's position in one vault","type":"object"},"yieldsYieldVault":{"properties":{"addresses":{"items":{"$ref":"#/components/schemas/yieldsYieldVaultAddress"},"title":"addresses are the vault's published on-chain addresses","type":"array"},"allocations":{"items":{"$ref":"#/components/schemas/yieldsYieldVaultAllocation"},"title":"allocations break down what the vault currently holds","type":"array"},"apyBps":{"format":"int64","title":"apy_bps is the current APY in basis points","type":"string"},"chain":{"title":"chain is the provider network key the vault runs on, e.g. ethereum, base, arbitrum,\npolygon, ethereum_sepolia","type":"string"},"depositToken":{"title":"deposit_token is the token the vault accepts (e.g. USDC)","type":"string"},"description":{"title":"description is the long-form vault explanation","type":"string"},"id":{"title":"id is our vault id","type":"string"},"links":{"items":{"$ref":"#/components/schemas/yieldsYieldVaultLink"},"title":"links are external references for the vault","type":"array"},"maxAllocationUsd":{"title":"max_allocation_usd is the cap on what the vault will accept, in USD","type":"string"},"name":{"title":"name is the vault display name","type":"string"},"navUpdateMode":{"title":"nav_update_mode is how the vault values its position: continuous or discrete","type":"string"},"protocol":{"title":"protocol is the underlying protocol the vault routes into, e.g. centrifuge, maple","type":"string"},"status":{"title":"status is which operations the vault currently accepts: active (both), buy_only\n(deposits only), sell_only (withdrawals only), frozen (neither), inactive (delisted by\nthe provider, withdrawals still allowed). Delisted vaults are not returned by\nListYieldVaults but can still appear on a portfolio entry","type":"string"},"tvlUsd":{"title":"tvl_usd is the vault TVL in USD","type":"string"},"utilizationPct":{"title":"utilization_pct is how much of the vault's capacity is deployed, as a percentage","type":"string"},"withdrawPolicy":{"title":"withdraw_policy is the provider processing policy JSON driving delay warnings","type":"string"}},"required":["id","name","chain","depositToken","apyBps","status"],"title":"YieldVault is a catalog entry for a vault users can deposit into","type":"object"},"yieldsYieldVaultAddress":{"properties":{"label":{"title":"label is the address role, e.g. Vault or Asset token","type":"string"},"value":{"title":"value is the address itself, or the token symbol for a non-address entry","type":"string"}},"required":["label","value"],"title":"YieldVaultAddress is a labeled on-chain address the provider publishes for a vault","type":"object"},"yieldsYieldVaultAllocation":{"properties":{"address":{"title":"address is the leg's on-chain address when it has one","type":"string"},"description":{"title":"description is the long-form explanation of the leg","type":"string"},"label":{"title":"label describes the holding","type":"string"},"pct":{"title":"pct is the leg's percentage share of the vault","type":"string"},"type":{"title":"type is the provider's asset class for the leg, e.g. rwa, credit","type":"string"},"valueUsd":{"title":"value_usd is the leg value in USD","type":"string"}},"required":["label"],"title":"YieldVaultAllocation is one leg of what a vault holds","type":"object"},"yieldsYieldVaultLink":{"properties":{"label":{"title":"label is the link display text","type":"string"},"url":{"title":"url is the link target","type":"string"}},"required":["label","url"],"title":"YieldVaultLink is a labeled external link for a vault, e.g. the protocol's own page","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/portfolio/{accountId}":{"get":{"description":"Balances, earned yield and withdrawable amounts are read through from the\nyields provider per active wallet","operationId":"MarketQueryService_GetYieldPortfolio","parameters":[{"description":"account_id is the account to fetch the portfolio for","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsGetYieldPortfolioResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetYieldPortfolio returns the account's position in each vault","tags":["MarketQueryService"]}}}}
```

## ListYieldVaults lists the active yield vault catalog

> Returns the vault catalog with APY, TVL and withdrawal policy metadata, enriched\
> with the provider's presentation data (description, protocol, allocations, links)\
> needed to render a vault page. The provider catalog is cached, so a call costs a\
> provider fetch at most once every 15 minutes

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.read"]},{"BearerAuth":["market.yields.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsListYieldVaultsResponse":{"properties":{"vaults":{"items":{"$ref":"#/components/schemas/yieldsYieldVault"},"title":"vaults are the active catalog entries","type":"array"}},"title":"ListYieldVaultsResponse is the response message for the ListYieldVaults method","type":"object"},"yieldsYieldVault":{"properties":{"addresses":{"items":{"$ref":"#/components/schemas/yieldsYieldVaultAddress"},"title":"addresses are the vault's published on-chain addresses","type":"array"},"allocations":{"items":{"$ref":"#/components/schemas/yieldsYieldVaultAllocation"},"title":"allocations break down what the vault currently holds","type":"array"},"apyBps":{"format":"int64","title":"apy_bps is the current APY in basis points","type":"string"},"chain":{"title":"chain is the provider network key the vault runs on, e.g. ethereum, base, arbitrum,\npolygon, ethereum_sepolia","type":"string"},"depositToken":{"title":"deposit_token is the token the vault accepts (e.g. USDC)","type":"string"},"description":{"title":"description is the long-form vault explanation","type":"string"},"id":{"title":"id is our vault id","type":"string"},"links":{"items":{"$ref":"#/components/schemas/yieldsYieldVaultLink"},"title":"links are external references for the vault","type":"array"},"maxAllocationUsd":{"title":"max_allocation_usd is the cap on what the vault will accept, in USD","type":"string"},"name":{"title":"name is the vault display name","type":"string"},"navUpdateMode":{"title":"nav_update_mode is how the vault values its position: continuous or discrete","type":"string"},"protocol":{"title":"protocol is the underlying protocol the vault routes into, e.g. centrifuge, maple","type":"string"},"status":{"title":"status is which operations the vault currently accepts: active (both), buy_only\n(deposits only), sell_only (withdrawals only), frozen (neither), inactive (delisted by\nthe provider, withdrawals still allowed). Delisted vaults are not returned by\nListYieldVaults but can still appear on a portfolio entry","type":"string"},"tvlUsd":{"title":"tvl_usd is the vault TVL in USD","type":"string"},"utilizationPct":{"title":"utilization_pct is how much of the vault's capacity is deployed, as a percentage","type":"string"},"withdrawPolicy":{"title":"withdraw_policy is the provider processing policy JSON driving delay warnings","type":"string"}},"required":["id","name","chain","depositToken","apyBps","status"],"title":"YieldVault is a catalog entry for a vault users can deposit into","type":"object"},"yieldsYieldVaultAddress":{"properties":{"label":{"title":"label is the address role, e.g. Vault or Asset token","type":"string"},"value":{"title":"value is the address itself, or the token symbol for a non-address entry","type":"string"}},"required":["label","value"],"title":"YieldVaultAddress is a labeled on-chain address the provider publishes for a vault","type":"object"},"yieldsYieldVaultAllocation":{"properties":{"address":{"title":"address is the leg's on-chain address when it has one","type":"string"},"description":{"title":"description is the long-form explanation of the leg","type":"string"},"label":{"title":"label describes the holding","type":"string"},"pct":{"title":"pct is the leg's percentage share of the vault","type":"string"},"type":{"title":"type is the provider's asset class for the leg, e.g. rwa, credit","type":"string"},"valueUsd":{"title":"value_usd is the leg value in USD","type":"string"}},"required":["label"],"title":"YieldVaultAllocation is one leg of what a vault holds","type":"object"},"yieldsYieldVaultLink":{"properties":{"label":{"title":"label is the link display text","type":"string"},"url":{"title":"url is the link target","type":"string"}},"required":["label","url"],"title":"YieldVaultLink is a labeled external link for a vault, e.g. the protocol's own page","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/vaults":{"get":{"description":"Returns the vault catalog with APY, TVL and withdrawal policy metadata, enriched\nwith the provider's presentation data (description, protocol, allocations, links)\nneeded to render a vault page. The provider catalog is cached, so a call costs a\nprovider fetch at most once every 15 minutes","operationId":"MarketQueryService_ListYieldVaults","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsListYieldVaultsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListYieldVaults lists the active yield vault catalog","tags":["MarketQueryService"]}}}}
```

## PreviewYieldDeposit previews the fee split of a deposit before creating it

> Returns what Kii charges on the chain and what would reach the vault, without\
> touching the account's yield wallet or recording an intent. Nothing is created,\
> so it is safe to call while the user is still typing an amount

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.read"]},{"BearerAuth":["market.yields.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsPreviewYieldDepositResponse":{"properties":{"amount":{"title":"amount is the requested amount, what the user's wallet would be debited","type":"string"},"chain":{"title":"chain is the provider network key the preview was computed for","type":"string"},"fee":{"$ref":"#/components/schemas/yieldsYieldFee"},"netAmount":{"title":"net_amount is what would reach the vault: amount minus the fee","type":"string"},"token":{"title":"token is the vault deposit token symbol","type":"string"},"tokenContract":{"title":"token_contract is the ERC-20 contract the transfer would be called on, for the\nfrontend to check the user's balance before committing","type":"string"}},"required":["chain","token","tokenContract","amount","netAmount","fee"],"title":"PreviewYieldDepositResponse is the response message for the PreviewYieldDeposit method","type":"object"},"yieldsYieldFee":{"properties":{"amount":{"title":"amount is the charged fee in token units, \"0\" when the chain charges nothing","type":"string"},"asset":{"title":"asset is the token the fee is taken in, always the vault deposit token","type":"string"},"type":{"title":"type is how the fee was computed: flat, bps or max, empty when the chain charges nothing","type":"string"}},"required":["type","amount","asset"],"title":"YieldFee is what Kii charges on a yields operation, deducted from the amount the user\ncommits. type is flat, bps or max, amount is in token units and asset is the token symbol","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/vaults/{vaultId}/deposit-preview":{"get":{"description":"Returns what Kii charges on the chain and what would reach the vault, without\ntouching the account's yield wallet or recording an intent. Nothing is created,\nso it is safe to call while the user is still typing an amount","operationId":"MarketQueryService_PreviewYieldDeposit","parameters":[{"description":"vault_id is the vault the deposit would go to","in":"path","name":"vaultId","required":true,"schema":{"type":"string"}},{"description":"chain is the provider network key the transfer would happen on, e.g. ethereum, base,\narbitrum, polygon, ethereum_sepolia","in":"query","name":"chain","required":true,"schema":{"type":"string"}},{"description":"amount is the deposit amount in token units, the same value CreateYieldDeposit takes","in":"query","name":"amount","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsPreviewYieldDepositResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"PreviewYieldDeposit previews the fee split of a deposit before creating it","tags":["MarketQueryService"]}}}}
```

## PreviewYieldWithdrawal previews a withdrawal before creating it

> Returns the destination-specific withdrawable amount and the estimated\
> processing delay used for the frontend warning

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.read"]},{"BearerAuth":["market.yields.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsPreviewYieldWithdrawalResponse":{"properties":{"estimatedDelay":{"title":"estimated_delay is the ISO-8601 processing delay estimate","type":"string"},"feeUsd":{"title":"fee_usd is the provider fee estimate","type":"string"},"withdrawableUsd":{"title":"withdrawable_usd is the destination-specific withdrawable amount, and the ceiling any\nwithdrawal to this destination must stay under","type":"string"}},"required":["withdrawableUsd","estimatedDelay","feeUsd"],"title":"PreviewYieldWithdrawalResponse is the response message for the PreviewYieldWithdrawal method","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/vaults/{vaultId}/withdrawal-preview":{"get":{"description":"Returns the destination-specific withdrawable amount and the estimated\nprocessing delay used for the frontend warning","operationId":"MarketQueryService_PreviewYieldWithdrawal","parameters":[{"description":"vault_id is the vault to withdraw from","in":"path","name":"vaultId","required":true,"schema":{"type":"string"}},{"description":"account_id is the withdrawing account","in":"query","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"amount_usd is the amount to withdraw in USD units\n\nOmit it to ask what the maximum withdrawable amount is for this destination instead of\ntesting a specific amount. That is the number to drive a Max button, the wallet balance\nis not: it counts funds the provider currently reserves","in":"query","name":"amountUsd","required":false,"schema":{"type":"string"}},{"description":"destination_chain is the provider network key of the payout, e.g. ethereum, base,\narbitrum, polygon, ethereum_sepolia","in":"query","name":"destinationChain","required":true,"schema":{"type":"string"}},{"description":"withdraw_destination_id is the payout destination, it must be a confirmed EVM wallet\nthe account saved in its withdrawal destinations","in":"query","name":"withdrawDestinationId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsPreviewYieldWithdrawalResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"PreviewYieldWithdrawal previews a withdrawal before creating it","tags":["MarketQueryService"]}}}}
```

## CreateYieldWithdrawal initiates a withdrawal from a yield vault

> Withdrawals are asynchronous and can take from minutes to banking days\
> depending on the vault, use PreviewYieldWithdrawal for the delay estimate

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Mutations (write operations)","name":"MarketMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.write"]},{"BearerAuth":["market.yields.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsCreateYieldWithdrawalRequest":{"properties":{"accountId":{"title":"account_id is the withdrawing account","type":"string"},"amountUsd":{"title":"amount_usd is the amount to withdraw in USD units","type":"string"},"destinationChain":{"title":"destination_chain is the provider network key of the payout, e.g. ethereum, base,\narbitrum, polygon, ethereum_sepolia","type":"string"},"vaultId":{"title":"vault_id is the vault to withdraw from","type":"string"},"withdrawDestinationId":{"title":"withdraw_destination_id is the payout destination, it must be a confirmed EVM wallet\nthe account saved in its withdrawal destinations","type":"string"}},"required":["accountId","vaultId","amountUsd","destinationChain","withdrawDestinationId"],"title":"CreateYieldWithdrawalRequest is the request message for the CreateYieldWithdrawal method","type":"object"},"yieldsCreateYieldWithdrawalResponse":{"properties":{"status":{"title":"status is the withdrawal status: processing, awaiting_approval, completed,\npartially_completed, failed, cancelled","type":"string"},"withdrawalId":{"title":"withdrawal_id is our withdrawal record id","type":"string"}},"required":["withdrawalId","status"],"title":"CreateYieldWithdrawalResponse is the response message for the CreateYieldWithdrawal method","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/withdrawals":{"post":{"description":"Withdrawals are asynchronous and can take from minutes to banking days\ndepending on the vault, use PreviewYieldWithdrawal for the delay estimate","operationId":"MarketMsgService_CreateYieldWithdrawal","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsCreateYieldWithdrawalRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsCreateYieldWithdrawalResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateYieldWithdrawal initiates a withdrawal from a yield vault","tags":["MarketMsgService"]}}}}
```

## ListYieldWithdrawals lists the account's withdrawal history

> Includes in-flight withdrawals, used by the frontend to poll withdrawal status

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"MarketQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["market.yields.read"]},{"BearerAuth":["market.yields.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"yieldsListYieldWithdrawalsResponse":{"properties":{"withdrawals":{"items":{"$ref":"#/components/schemas/yieldsYieldWithdrawal"},"title":"withdrawals are the account's withdrawal records, newest first","type":"array"}},"title":"ListYieldWithdrawalsResponse is the response message for the ListYieldWithdrawals method","type":"object"},"yieldsYieldWithdrawal":{"properties":{"amountUsd":{"title":"amount_usd is the requested amount in USD units","type":"string"},"createdAt":{"title":"created_at is the record creation time in RFC 3339","type":"string"},"destinationAddress":{"title":"destination_address is the payout address","type":"string"},"destinationChain":{"title":"destination_chain is the provider network key of the payout, e.g. ethereum, base,\narbitrum, polygon, ethereum_sepolia","type":"string"},"id":{"title":"id is our withdrawal record id","type":"string"},"legs":{"title":"legs is the provider per-leg payout detail JSON","type":"string"},"status":{"title":"status is processing, awaiting_approval, completed, partially_completed,\nfailed or cancelled","type":"string"},"vaultId":{"title":"vault_id is the vault withdrawn from","type":"string"}},"required":["id","vaultId","amountUsd","destinationAddress","destinationChain","status","createdAt"],"title":"YieldWithdrawal is a withdrawal record","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/market/v1/yields/withdrawals/{accountId}":{"get":{"description":"Includes in-flight withdrawals, used by the frontend to poll withdrawal status","operationId":"MarketQueryService_ListYieldWithdrawals","parameters":[{"description":"account_id is the account to list withdrawals for","in":"path","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/yieldsListYieldWithdrawalsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"ListYieldWithdrawals lists the account's withdrawal history","tags":["MarketQueryService"]}}}}
```


# Notifications

## MarkUserPushNotificationsAsRead marks a list of push notifications as read for the authenticated user

> Accepts up to 200 notification\_ids per call. Only affects notifications\
> owned by the caller

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"NotificationsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["notifications.user_notifications.write"]},{"BearerAuth":["notifications.user_notifications.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1MarkUserPushNotificationsAsReadRequest":{"properties":{"notificationIds":{"items":{"type":"string"},"title":"notification_ids contains the list of push notification identifiers to mark as read","type":"array"}},"required":["notificationIds"],"title":"MarkUserPushNotificationsAsReadRequest is the body request from the mark notifications as read endpoint","type":"object"},"v1MarkUserPushNotificationsAsReadResponse":{"properties":{"notifications":{"items":{"$ref":"#/components/schemas/v1Notification"},"title":"notifications contains the updated push notifications","type":"array"}},"required":["notifications"],"title":"MarkUserPushNotificationsAsReadResponse is the body response from the mark notifications as read endpoint","type":"object"},"v1Notification":{"properties":{"channel":{"title":"channel is the way to send the notification","type":"string"},"createdAt":{"format":"date-time","title":"created_at is the date when the notification was created","type":"string"},"failReason":{"title":"fail_reason is the notification fail reason","type":"string"},"id":{"title":"id is the notification identifier","type":"string"},"notificationName":{"title":"notification_name is the notification name","type":"string"},"payload":{"title":"payload contains the notification information (headers and body)","type":"string"},"readAt":{"format":"date-time","title":"read_at is the timestamp when the notification was read (absent = unread)","type":"string"},"status":{"title":"status is the notification status","type":"string"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the notification was updated","type":"string"},"userId":{"title":"user_id is the user identifier who has received the notification","type":"string"}},"required":["id","userId","channel","notificationName","status","payload","createdAt"],"title":"Notification contains all information with a notification","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/notifications/v1/me/notifications/push/read":{"post":{"description":"Accepts up to 200 notification_ids per call. Only affects notifications\nowned by the caller","operationId":"NotificationsMsgService_MarkUserPushNotificationsAsRead","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1MarkUserPushNotificationsAsReadRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1MarkUserPushNotificationsAsReadResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"MarkUserPushNotificationsAsRead marks a list of push notifications as read for the authenticated user","tags":["NotificationsMsgService"]}}}}
```

## GetNotificationsByUserId returns all notification on the system associated to the provided user

> Includes every channel and status, not just push. For a single user's\
> unread push notifications use GetUserPushNotifications instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"NotificationsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["notifications.user_notifications.read","notifications.user_notifications.read:all"]},{"BearerAuth":["notifications.user_notifications.read","notifications.user_notifications.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetNotificationsByUserIdResponse":{"properties":{"notifications":{"items":{"$ref":"#/components/schemas/v1Notification"},"title":"notifications contains the array of notifications","type":"array"},"pagination":{"$ref":"#/components/schemas/v1Pagination"}},"required":["notifications","pagination"],"title":"GetNotificationsByUserIdResponse is the body response from the get notifications by user id endpoint","type":"object"},"v1Notification":{"properties":{"channel":{"title":"channel is the way to send the notification","type":"string"},"createdAt":{"format":"date-time","title":"created_at is the date when the notification was created","type":"string"},"failReason":{"title":"fail_reason is the notification fail reason","type":"string"},"id":{"title":"id is the notification identifier","type":"string"},"notificationName":{"title":"notification_name is the notification name","type":"string"},"payload":{"title":"payload contains the notification information (headers and body)","type":"string"},"readAt":{"format":"date-time","title":"read_at is the timestamp when the notification was read (absent = unread)","type":"string"},"status":{"title":"status is the notification status","type":"string"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the notification was updated","type":"string"},"userId":{"title":"user_id is the user identifier who has received the notification","type":"string"}},"required":["id","userId","channel","notificationName","status","payload","createdAt"],"title":"Notification contains all information with a notification","type":"object"},"v1Pagination":{"properties":{"currentPage":{"format":"int32","title":"current_page is the current page number","type":"integer"},"limit":{"format":"int32","title":"limit contains the limit used to calculate the page","type":"integer"},"totalItems":{"format":"int32","title":"total_items is the total number of items","type":"integer"},"totalPages":{"format":"int32","title":"total_pages is the total number of pages","type":"integer"}},"required":["currentPage","totalItems","totalPages","limit"],"title":"Pagination contains the keys to move between pages\nusing the cursor-based pagination","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/notifications/v1/users/{userId}/notifications":{"get":{"description":"Includes every channel and status, not just push. For a single user's\nunread push notifications use GetUserPushNotifications instead","operationId":"NotificationsQueryService_GetNotificationsByUserId","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}},{"description":"page is an optional query parameter to set the page number","in":"query","name":"page","required":false,"schema":{"format":"int32","type":"integer"}},{"description":"limit is an optional query parameter to set the max amount of\nresults per page","in":"query","name":"limit","required":false,"schema":{"format":"int32","type":"integer"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetNotificationsByUserIdResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetNotificationsByUserId returns all notification on the system associated to the provided user","tags":["NotificationsQueryService"]}}}}
```

## GetUserPushNotifications returns all unread push notifications for the authenticated user

> Push channel only and unread only. Mark them read via\
> MarkUserPushNotificationsAsRead once shown to the user

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"NotificationsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["notifications.user_notifications.read","notifications.user_notifications.read:all"]},{"BearerAuth":["notifications.user_notifications.read","notifications.user_notifications.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserPushNotificationsResponse":{"properties":{"notifications":{"items":{"$ref":"#/components/schemas/v1Notification"},"title":"notifications contains the array of unread push notifications for the authenticated user","type":"array"}},"required":["notifications"],"title":"GetUserPushNotificationsResponse is the body response from the get user push notifications endpoint","type":"object"},"v1Notification":{"properties":{"channel":{"title":"channel is the way to send the notification","type":"string"},"createdAt":{"format":"date-time","title":"created_at is the date when the notification was created","type":"string"},"failReason":{"title":"fail_reason is the notification fail reason","type":"string"},"id":{"title":"id is the notification identifier","type":"string"},"notificationName":{"title":"notification_name is the notification name","type":"string"},"payload":{"title":"payload contains the notification information (headers and body)","type":"string"},"readAt":{"format":"date-time","title":"read_at is the timestamp when the notification was read (absent = unread)","type":"string"},"status":{"title":"status is the notification status","type":"string"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the notification was updated","type":"string"},"userId":{"title":"user_id is the user identifier who has received the notification","type":"string"}},"required":["id","userId","channel","notificationName","status","payload","createdAt"],"title":"Notification contains all information with a notification","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/notifications/v1/users/{userId}/notifications/push":{"get":{"description":"Push channel only and unread only. Mark them read via\nMarkUserPushNotificationsAsRead once shown to the user","operationId":"NotificationsQueryService_GetUserPushNotifications","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserPushNotificationsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserPushNotifications returns all unread push notifications for the authenticated user","tags":["NotificationsQueryService"]}}}}
```


# Portfolio

## GenerateReport generates and streams a report file for download

> Uses the reporters registered for report\_type/format (see\
> x/portfolio/infra/reporters) — account\_id defaults to the caller's own\
> account and requires the :all scope to query on behalf of another

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"PortfolioQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["reports.generate.read","reports.generate.read:all"]},{"BearerAuth":["reports.generate.read","reports.generate.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"apiHttpBody":{"description":"Message that represents an arbitrary HTTP body. It should only be used for\npayload formats that can't be represented as JSON, such as raw binary or\nan HTML page.\n\n\nThis message can be used both in streaming and non-streaming API methods in\nthe request as well as the response.\n\nIt can be used as a top-level request field, which is convenient if one\nwants to extract parameters from either the URL or HTTP template into the\nrequest fields and also want access to the raw HTTP body.\n\nExample:\n\n    message GetResourceRequest {\n      // A unique request id.\n      string request_id = 1;\n\n      // The raw HTTP body is bound to this field.\n      google.api.HttpBody http_body = 2;\n\n    }\n\n    service ResourceService {\n      rpc GetResource(GetResourceRequest)\n        returns (google.api.HttpBody);\n      rpc UpdateResource(google.api.HttpBody)\n        returns (google.protobuf.Empty);\n\n    }\n\nExample with streaming methods:\n\n    service CaldavService {\n      rpc GetCalendar(stream google.api.HttpBody)\n        returns (stream google.api.HttpBody);\n      rpc UpdateCalendar(stream google.api.HttpBody)\n        returns (stream google.api.HttpBody);\n\n    }\n\nUse of this type only changes how the request and response bodies are\nhandled, all other features will continue to work unchanged.","properties":{"contentType":{"description":"The HTTP Content-Type header value specifying the content type of the body.","type":"string"},"data":{"description":"The HTTP request/response body as raw binary.","format":"byte","type":"string"},"extensions":{"description":"Application specific response metadata. Must be set in the first response\nfor streaming APIs.","items":{"$ref":"#/components/schemas/protobufAny"},"type":"array"}},"type":"object"},"protobufAny":{"additionalProperties":{},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\n Example 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\n Example 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n====\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","properties":{"@type":{"description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com. As of May 2023, there are no widely used type server\nimplementations and no plans to implement one.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics.","type":"string"}},"type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/portfolio/v1/generate":{"get":{"description":"Uses the reporters registered for report_type/format (see\nx/portfolio/infra/reporters) — account_id defaults to the caller's own\naccount and requires the :all scope to query on behalf of another","operationId":"PortfolioQueryService_GenerateReport","parameters":[{"description":"report_type identifies the kind of report to generate (e.g. \"trade\")","in":"query","name":"reportType","required":true,"schema":{"type":"string"}},{"description":"format identifies the output format (e.g. \"csv\", \"pdf\")","in":"query","name":"format","required":true,"schema":{"type":"string"}},{"description":"start_date is the optional inclusive start of the report date range","in":"query","name":"startDate","required":false,"schema":{"format":"date-time","type":"string"}},{"description":"end_date is the optional inclusive end of the report date range","in":"query","name":"endDate","required":false,"schema":{"format":"date-time","type":"string"}},{"description":"account_id is optional; absent means self-service (from auth context).\nProviding it requires the reports.generate.read:all scope (admin).","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/apiHttpBody"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GenerateReport generates and streams a report file for download","tags":["PortfolioQueryService"]}}}}
```

## GetPortfolio returns the aggregated holdings for an account

> Aggregates custodial ledger balances, Privy-managed wallet balances, and\
> caller-supplied external wallet balances into a single USD-valued view

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"PortfolioBalancesQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["portfolio.portfolio.read","portfolio.portfolio.read:all"]},{"BearerAuth":["portfolio.portfolio.read","portfolio.portfolio.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetPortfolioResponse":{"properties":{"crypto":{"items":{"$ref":"#/components/schemas/v1TokenByWallet"},"title":"crypto is every on-chain token balance held, in the same shape GetTokensByWallet returns","type":"array"},"fiat":{"items":{"$ref":"#/components/schemas/v1FiatHolding"},"type":"array"},"summary":{"$ref":"#/components/schemas/v1Summary"}},"required":["summary","crypto","fiat"],"title":"GetPortfolioResponse is the aggregated portfolio view","type":"object"},"v1TokenByWallet":{"properties":{"address":{"title":"address is the wallet address holding the token","type":"string"},"chainId":{"title":"chain_id is the blockchain network of the token","type":"string"},"tokenAddress":{"title":"token_address is the contract address of the token (empty for native tokens)","type":"string"},"tokenBalance":{"title":"token_balance is the balance of the token held by the wallet","type":"string"},"tokenMetadata":{"$ref":"#/components/schemas/v1Token"}},"required":["address","chainId","tokenBalance","tokenMetadata"],"title":"TokenByWallet represents a token held by a wallet","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"v1FiatHolding":{"properties":{"amount":{"type":"string"},"availability":{"$ref":"#/components/schemas/v1Availability"},"available":{"type":"string"},"decimals":{"format":"int32","type":"integer"},"fiatAssetCode":{"type":"string"},"locked":{"type":"string"},"logo":{"type":"string"},"name":{"type":"string"},"symbol":{"type":"string"},"usdValue":{"type":"string"}},"required":["symbol","name","logo","decimals","fiatAssetCode","amount","available","locked","usdValue","availability"],"title":"FiatHolding is a custodial ledger balance for a fiat asset","type":"object"},"v1Availability":{"properties":{"allowed":{"title":"allowed reports whether the account can use the row","type":"boolean"},"providerId":{"title":"provider_id is the provider whose onboarding is pending, only set for provider_kyc_required","type":"string"},"providerName":{"title":"provider_name is the display name of that provider, only set for provider_kyc_required","type":"string"},"reason":{"title":"reason is why the row is blocked, unset when allowed\n(kyc_required | country_not_supported | fiat_country_required | not_offered |\nprovider_kyc_required)","type":"string"},"requiredCountries":{"items":{"type":"string"},"title":"required_countries lists the ISO 3166-1 alpha-3 codes that would unlock the row,\nonly set for fiat_country_required","type":"array"}},"required":["allowed"],"title":"Availability tells whether the requesting account can use a row and, if not, why","type":"object"},"v1Summary":{"properties":{"external":{"$ref":"#/components/schemas/v1GroupBreakdown"},"internal":{"$ref":"#/components/schemas/v1GroupBreakdown"},"totalUsd":{"type":"string"}},"required":["totalUsd","internal","external"],"title":"Summary holds the portfolio totals and per-group breakdowns","type":"object"},"v1GroupBreakdown":{"properties":{"sources":{"items":{"$ref":"#/components/schemas/v1SourceContribution"},"type":"array"},"usdValue":{"type":"string"}},"required":["usdValue","sources"],"title":"GroupBreakdown is a placement group total with per-source contributions","type":"object"},"v1SourceContribution":{"properties":{"address":{"type":"string"},"network":{"title":"network is the wallet chain family (EVM, Tron), set only for wallet sources","type":"string"},"type":{"title":"type is fiat_ledger or wallet","type":"string"},"usdValue":{"type":"string"}},"required":["type","usdValue"],"title":"SourceContribution is one source's USD contribution to a group","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/portfolio/v1/portfolio":{"get":{"description":"Aggregates custodial ledger balances, Privy-managed wallet balances, and\ncaller-supplied external wallet balances into a single USD-valued view","operationId":"PortfolioBalancesQueryService_GetPortfolio","parameters":[{"in":"query","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"evm is a caller-owned EVM wallet to include alongside the internal ones","in":"query","name":"evm","required":false,"schema":{"type":"string"}},{"description":"tron is a caller-owned Tron wallet to include alongside the internal ones","in":"query","name":"tron","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetPortfolioResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetPortfolio returns the aggregated holdings for an account","tags":["PortfolioBalancesQueryService"]}}}}
```

## GetTokensByWallet returns tokens held by EVM and/or Tron wallet addresses across supported chains

> Queries on-chain balances directly, not the internal ledger. At least\
> one of evm or tron must be provided

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"PortfolioBalancesQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"paths":{"/portfolio/v1/tokens-by-wallet":{"get":{"description":"Queries on-chain balances directly, not the internal ledger. At least\none of evm or tron must be provided","operationId":"PortfolioBalancesQueryService_GetTokensByWallet","parameters":[{"description":"evm is an EVM-compatible wallet address (0x-prefixed, 20 bytes)","in":"query","name":"evm","required":false,"schema":{"type":"string"}},{"description":"tron is a Tron wallet address (base58, starts with T)","in":"query","name":"tron","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetTokensByWalletResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTokensByWallet returns tokens held by EVM and/or Tron wallet addresses across supported chains","tags":["PortfolioBalancesQueryService"]}}},"components":{"schemas":{"v1GetTokensByWalletResponse":{"properties":{"tokens":{"items":{"$ref":"#/components/schemas/v1TokenByWallet"},"title":"tokens is the list of tokens held by the wallet","type":"array"}},"required":["tokens"],"title":"GetTokensByWalletResponse is the response message for GetTokensByWallet","type":"object"},"v1TokenByWallet":{"properties":{"address":{"title":"address is the wallet address holding the token","type":"string"},"chainId":{"title":"chain_id is the blockchain network of the token","type":"string"},"tokenAddress":{"title":"token_address is the contract address of the token (empty for native tokens)","type":"string"},"tokenBalance":{"title":"token_balance is the balance of the token held by the wallet","type":"string"},"tokenMetadata":{"$ref":"#/components/schemas/v1Token"}},"required":["address","chainId","tokenBalance","tokenMetadata"],"title":"TokenByWallet represents a token held by a wallet","type":"object"},"v1Token":{"properties":{"country":{"title":"country is the ISO 3166-1 alpha-3 code of the country the stablecoin tracks (e.g. USA, BRA)\nor EUR for the European Union, unset for non-stable tokens","type":"string"},"decimals":{"format":"int32","title":"decimals is the number of decimal places the token uses","type":"integer"},"enabled":{"title":"enabled indicates whether the token is enabled on the platform","type":"boolean"},"id":{"format":"int32","title":"id is the surrogate identifier of the token","type":"integer"},"logo":{"title":"logo is the URL to the token's logo image","type":"string"},"name":{"title":"name is the full name of the token","type":"string"},"stable":{"title":"stable indicates whether the token is a stablecoin","type":"boolean"},"symbol":{"title":"symbol is the ticker symbol of the token","type":"string"}},"required":["id","name","symbol","decimals","logo","enabled","stable"],"title":"Token represents a coin/token supported by the platform","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}}}
```


# Tickets

## GetTicketsByAccount returns tickets for a specific account with pagination and filtering

> Scoped to a single account\_id. Use GetTickets for the platform-wide\
> admin view across every account

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TicketsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.read"]},{"BearerAuth":["tickets.tickets.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetTicketsByAccountResponse":{"properties":{"pagination":{"$ref":"#/components/schemas/v1Pagination"},"tickets":{"items":{"$ref":"#/components/schemas/v1Ticket"},"title":"tickets contains the list of tickets for the requested account","type":"array"}},"required":["tickets","pagination"],"title":"GetTicketsByAccountResponse is the response structure for the GetTicketsByAccount endpoint","type":"object"},"v1Pagination":{"properties":{"currentPage":{"format":"int32","title":"current_page is the current page number","type":"integer"},"limit":{"format":"int32","title":"limit contains the limit used to calculate the page","type":"integer"},"totalItems":{"format":"int32","title":"total_items is the total number of items","type":"integer"},"totalPages":{"format":"int32","title":"total_pages is the total number of pages","type":"integer"}},"required":["currentPage","totalItems","totalPages","limit"],"title":"Pagination contains the keys to move between pages\nusing the cursor-based pagination","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/accounts/{accountId}":{"get":{"description":"Scoped to a single account_id. Use GetTickets for the platform-wide\nadmin view across every account","operationId":"TicketsQueryService_GetTicketsByAccount","parameters":[{"description":"account_id is the unique identifier of the account whose tickets are requested","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"page is an optional query parameter to set the page","in":"query","name":"page","required":false,"schema":{"format":"int32","type":"integer"}},{"description":"limit is an optional query parameter to set the max number of results","in":"query","name":"limit","required":false,"schema":{"format":"int32","type":"integer"}},{"description":"display_status is an optional filter to return only tickets with the given display status","in":"query","name":"displayStatus","required":false,"schema":{"type":"string"}},{"description":"state is an optional filter to return only tickets with the given state","in":"query","name":"state","required":false,"schema":{"type":"string"}},{"description":"type is an optional filter to return only tickets of the given type","in":"query","name":"type","required":false,"schema":{"type":"string"}},{"description":"sort_by is an optional field to sort the results","in":"query","name":"sortBy","required":false,"schema":{"type":"string"}},{"description":"sort_order is an optional field to set the sort direction","in":"query","name":"sortOrder","required":false,"schema":{"type":"string"}},{"description":"start_date optionally keeps only tickets created at or after this time","in":"query","name":"startDate","required":false,"schema":{"format":"date-time","type":"string"}},{"description":"end_date optionally keeps only tickets created before this time (exclusive)","in":"query","name":"endDate","required":false,"schema":{"format":"date-time","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetTicketsByAccountResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTicketsByAccount returns tickets for a specific account with pagination and filtering","tags":["TicketsQueryService"]}}}}
```

## GetTicketsSummaryByAccount returns the ticket counts and USD totals of an account

> Totals are grouped by type and display status, so a client can build any\
> breakdown (money in, money out, swapped) from one call. USD values are the\
> ones stored when each ticket was created. Use GetTicketsSummary for the\
> platform-wide admin view

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TicketsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.read"]},{"BearerAuth":["tickets.tickets.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetTicketsSummaryByAccountResponse":{"properties":{"summary":{"$ref":"#/components/schemas/v1TicketsSummary"}},"required":["summary"],"title":"GetTicketsSummaryByAccountResponse is the response structure for the GetTicketsSummaryByAccount endpoint","type":"object"},"v1TicketsSummary":{"properties":{"amountUsd":{"title":"amount_usd is the sum of the matched tickets' USD amounts, as a decimal (e.g. \"123.45\")","type":"string"},"count":{"format":"int32","title":"count is the number of tickets matched","type":"integer"},"firstCreatedAt":{"format":"date-time","title":"first_created_at is when the oldest matched ticket was created, absent when nothing matched","type":"string"},"groups":{"items":{"$ref":"#/components/schemas/v1TicketsSummaryGroup"},"title":"groups breaks the totals down per type and display status. Combinations with no tickets are left out","type":"array"},"lastCreatedAt":{"format":"date-time","title":"last_created_at is when the newest matched ticket was created, absent when nothing matched","type":"string"}},"required":["count","amountUsd","groups"],"title":"TicketsSummary holds the ticket counts and USD totals of a set of tickets","type":"object"},"v1TicketsSummaryGroup":{"properties":{"amountUsd":{"title":"amount_usd is the sum of the group's USD amounts, as a decimal (e.g. \"123.45\")","type":"string"},"count":{"format":"int32","title":"count is the number of tickets in the group","type":"integer"},"displayStatus":{"title":"display_status is the display status of the group","type":"string"},"maxAmountUsd":{"title":"max_amount_usd is the largest USD amount in the group, as a decimal (e.g. \"123.45\")","type":"string"},"type":{"title":"type is the ticket type of the group","type":"string"}},"required":["type","displayStatus","count","amountUsd","maxAmountUsd"],"title":"TicketsSummaryGroup holds the totals of the tickets sharing one type and display status","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/accounts/{accountId}/summary":{"get":{"description":"Totals are grouped by type and display status, so a client can build any\nbreakdown (money in, money out, swapped) from one call. USD values are the\nones stored when each ticket was created. Use GetTicketsSummary for the\nplatform-wide admin view","operationId":"TicketsQueryService_GetTicketsSummaryByAccount","parameters":[{"description":"account_id is the unique identifier of the account whose tickets are summarized","in":"path","name":"accountId","required":true,"schema":{"type":"string"}},{"description":"start_date optionally keeps only tickets created at or after this time","in":"query","name":"startDate","required":false,"schema":{"format":"date-time","type":"string"}},{"description":"end_date optionally keeps only tickets created before this time (exclusive)","in":"query","name":"endDate","required":false,"schema":{"format":"date-time","type":"string"}},{"description":"types optionally keeps only tickets of these types.\nPossible values: \"onramp\", \"offramp\", \"swap\", \"trade\", \"dex\", \"subscription_payment\"","explode":true,"in":"query","name":"types","required":false,"schema":{"items":{"type":"string"},"type":"array"}},{"description":"display_statuses optionally keeps only tickets in these display statuses.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\"","explode":true,"in":"query","name":"displayStatuses","required":false,"schema":{"items":{"type":"string"},"type":"array"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetTicketsSummaryByAccountResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTicketsSummaryByAccount returns the ticket counts and USD totals of an account","tags":["TicketsQueryService"]}}}}
```

## CreateDexTicket creates a ticket that tracks a cross-chain DEX route

> Re-runs the DEX router server-side and persists the fresh route, because route calldata\
> is only valid for seconds. The response carries every transaction of the route in\
> submission order, an approval together with the swap or bridge it unlocks, for the caller\
> to sign and report through SubmitDexStep. TicketGetPendingUserAction returns the ones not\
> submitted yet while the ticket waits on a step

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1CreateDexTicketRequest":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"allowMultiHops":{"title":"allow_multi_hops allows a route that needs more than one leg. The first leg comes back here,\neach later one appears on GetPendingUserAction once the previous leg delivered, with the\nticket back in dex_waiting_step. Send the same value used on the pricing quote","type":"boolean"},"assetIn":{"$ref":"#/components/schemas/v1DexTicketAssetAmount"},"assetOut":{"$ref":"#/components/schemas/v1DexTicketAsset"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"minAmountOut":{"title":"min_amount_out is the floor the caller already accepted on the quote shown to them.\nCreation fails if the fresh server-side re-quote's expected output comes back below it.\nThe route's on-chain minimum can still land up to one slippage under it","type":"string"},"userChainAddress":{"title":"user_chain_address is the wallet address that signs every step of the route","type":"string"}},"required":["accountId","assetIn","assetOut","minAmountOut","userChainAddress"],"title":"CreateDexTicketRequest is the body request structure for the CreateDexTicket endpoint","type":"object"},"v1DexTicketAssetAmount":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination (integer, no decimals)","type":"string"},"chainId":{"title":"chain_id is the chain the asset lives on","type":"string"},"denom":{"title":"denom is the asset denomination","type":"string"}},"required":["denom","chainId","amount"],"title":"DexTicketAssetAmount is a cross-chain asset paired with an amount","type":"object"},"v1DexTicketAsset":{"properties":{"chainId":{"title":"chain_id is the chain the asset lives on","type":"string"},"denom":{"title":"denom is the asset denomination (e.g. ERC-20 contract address or native token sentinel)","type":"string"}},"required":["denom","chainId"],"title":"DexTicketAsset identifies a cross-chain asset by its denomination and chain, with no amount","type":"object"},"v1CreateDexTicketResponse":{"properties":{"ticket":{"$ref":"#/components/schemas/v1Ticket"},"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"title":"transactions is the route's first leg in submission order, all signed and submitted by the\ncaller. A route that needs more than one leg hands the later ones out through\nGetPendingUserAction, once the previous leg delivered","type":"array"}},"required":["ticket","transactions"],"title":"CreateDexTicketResponse is the body response structure for the CreateDexTicket endpoint","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/dex":{"post":{"description":"Re-runs the DEX router server-side and persists the fresh route, because route calldata\nis only valid for seconds. The response carries every transaction of the route in\nsubmission order, an approval together with the swap or bridge it unlocks, for the caller\nto sign and report through SubmitDexStep. TicketGetPendingUserAction returns the ones not\nsubmitted yet while the ticket waits on a step","operationId":"TicketsMsgService_CreateDexTicket","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateDexTicketRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateDexTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateDexTicket creates a ticket that tracks a cross-chain DEX route","tags":["TicketsMsgService"]}}}}
```

## CreateOffRampTicket creates a new off-ramp ticket

> Kicks off the off-ramp flow for the given quote. Response includes the\
> transactions the user must sign to fund it

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1CreateOffRampTicketRequest":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productsProviderId":{"title":"Target ID associated with the ticket","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"template":{"title":"Template information as JSON","type":"object"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["productsProviderId","accountId","userChainAddress","quote"],"title":"CreateOffRampTicketRequest is the body request structure for the CreateOffRampTicket endpoint","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"v1CreateOffRampTicketResponse":{"properties":{"ticket":{"$ref":"#/components/schemas/v1Ticket"},"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"title":"Transaction message containing the information needed to execute the transaction on the blockchain","type":"array"}},"required":["ticket","transactions"],"title":"CreateOffRampTicketResponse is the body response structure for the CreateOffRampTicket endpoint","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/offramp":{"post":{"description":"Kicks off the off-ramp flow for the given quote. Response includes the\ntransactions the user must sign to fund it","operationId":"TicketsMsgService_CreateOffRampTicket","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateOffRampTicketRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateOffRampTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateOffRampTicket creates a new off-ramp ticket","tags":["TicketsMsgService"]}}}}
```

## CreateSubscriptionPaymentTicket creates a ticket that pays for a self-billed subscription plan

> Covers the first purchase and every renewal. The price fixes the chain-token and the amount.\
> The response carries the KiiSettlement createEscrow transaction for user\_chain\_address to sign\
> within 24 hours. The contract holds the funds until the account's 1Money KYC is decided

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1CreateSubscriptionPaymentTicketRequest":{"properties":{"accountId":{"title":"account_id is the account paying for the subscription","type":"string"},"priceId":{"title":"price_id is the plan price being paid, one of the prices ListAvailablePlans returns","type":"string"},"userChainAddress":{"title":"user_chain_address is the wallet that signs the escrow and gets the funds back on a refund","type":"string"}},"required":["accountId","priceId","userChainAddress"],"title":"CreateSubscriptionPaymentTicketRequest is the request for the CreateSubscriptionPaymentTicket endpoint","type":"object"},"v1CreateSubscriptionPaymentTicketResponse":{"properties":{"ticket":{"$ref":"#/components/schemas/v1Ticket"},"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"title":"transactions is the createEscrow transaction, with any token approval before it, for\nuser_chain_address to sign","type":"array"}},"required":["ticket","transactions"],"title":"CreateSubscriptionPaymentTicketResponse is the response for the CreateSubscriptionPaymentTicket endpoint","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/subscription_payment":{"post":{"description":"Covers the first purchase and every renewal. The price fixes the chain-token and the amount.\nThe response carries the KiiSettlement createEscrow transaction for user_chain_address to sign\nwithin 24 hours. The contract holds the funds until the account's 1Money KYC is decided","operationId":"TicketsMsgService_CreateSubscriptionPaymentTicket","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateSubscriptionPaymentTicketRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateSubscriptionPaymentTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateSubscriptionPaymentTicket creates a ticket that pays for a self-billed subscription plan","tags":["TicketsMsgService"]}}}}
```

## CreateSwapTicket creates a new swap ticket with the given parameters

> Kicks off the swap flow for an instrument's quote. Response includes\
> the transactions the user must sign to fund it

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1CreateSwapTicketRequest":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"instrumentId":{"title":"instrument_id contains the target ID associated with the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"quote":{"$ref":"#/components/schemas/v1Quote"},"template":{"title":"Template information as JSON","type":"object"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["instrumentId","accountId","userChainAddress","quote"],"title":"CreateSwapTicketRequest is the body request structure for the CreateSwapTicket endpoint","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"v1CreateSwapTicketResponse":{"properties":{"ticket":{"$ref":"#/components/schemas/v1Ticket"},"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"title":"Transaction message containing the information needed to execute the transaction on the blockchain","type":"array"}},"required":["ticket","transactions"],"title":"CreateSwapTicketResponse is the body response structure for the CreateSwapTicket endpoint","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/swap":{"post":{"description":"Kicks off the swap flow for an instrument's quote. Response includes\nthe transactions the user must sign to fund it","operationId":"TicketsMsgService_CreateSwapTicket","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateSwapTicketRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateSwapTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateSwapTicket creates a new swap ticket with the given parameters","tags":["TicketsMsgService"]}}}}
```

## CreateTradeTicket creates a new trade ticket for the trade page feature

> Kicks off the trade flow for a trade instrument's quote. Crypto-input trades\
> return the deposit details on the ticket metadata; fiat-input trades lock the ledger

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1CreateTradeTicketRequest":{"properties":{"accountId":{"title":"account_id is the account creating the trade","type":"string"},"instrumentId":{"title":"instrument_id is the trade instrument targeted by the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata information - user managed","type":"object"},"quote":{"$ref":"#/components/schemas/v1Quote"},"template":{"title":"template information as JSON","type":"object"},"userChainAddress":{"title":"user_chain_address is the user's chain address, optional since fiat-input trades have none","type":"string"},"withdrawDestinationId":{"title":"withdraw_destination_id is the payout destination, required for crypto-output trades","type":"string"}},"required":["instrumentId","accountId","quote"],"title":"CreateTradeTicketRequest is the body request structure for the CreateTradeTicket endpoint","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"v1CreateTradeTicketResponse":{"properties":{"ticket":{"$ref":"#/components/schemas/v1Ticket"},"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"title":"transactions is present for parity with other create endpoints; trades never return one","type":"array"}},"required":["ticket"],"title":"CreateTradeTicketResponse is the body response structure for the CreateTradeTicket endpoint","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/trade":{"post":{"description":"Kicks off the trade flow for a trade instrument's quote. Crypto-input trades\nreturn the deposit details on the ticket metadata; fiat-input trades lock the ledger","operationId":"TicketsMsgService_CreateTradeTicket","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateTradeTicketRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateTradeTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateTradeTicket creates a new trade ticket for the trade page feature","tags":["TicketsMsgService"]}}}}
```

## GetTicket returns a ticket by its ID

> Ticket data only. Use GetTicketDetails for the context, flows and\
> provider information as well

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TicketsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.read","tickets.tickets.read:all"]},{"BearerAuth":["tickets.tickets.read","tickets.tickets.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetTicketResponse":{"properties":{"ticket":{"$ref":"#/components/schemas/v1Ticket"}},"required":["ticket"],"title":"GetTicketResponse is the body response structure for the GetTicket endpoint","type":"object"},"v1Ticket":{"properties":{"accountId":{"title":"Account ID associated with the ticket","type":"string"},"amount":{"title":"Amount in asset units (in atoms) - integer only, no decimals","type":"string"},"amountUsd":{"title":"Amount in USD - decimal value (e.g. \"123.45\")","type":"string"},"billingPlanId":{"title":"billing_plan_id is the billing plan this ticket pays for (target_type = \"billing_plan\")","type":"string"},"createdAt":{"format":"date-time","title":"Created at timestamp","type":"string"},"deadline":{"format":"date-time","title":"Expire at timestamp","type":"string"},"dexValueLocation":{"$ref":"#/components/schemas/v1DexValueLocation"},"displayStatus":{"description":"Display status of the ticket for user-friendly display.\nPossible values: \"pending\", \"fulfilled\", \"canceled\", \"failed\", \"refunded\", \"processing\", \"expired\", \"stuck\".","type":"string"},"id":{"title":"Unique identifier for the ticket","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"Metadata information - user managed","type":"object"},"productFee":{"title":"Product fee amount in atoms - integer only, no decimals","type":"string"},"productProviderId":{"title":"product_provider_id is the product-provider this ticket targets (target_type = \"onramp\" or \"offramp\")","type":"string"},"providerId":{"title":"provider_id is the DEX aggregator provider this ticket targets (target_type = \"dex\")","type":"string"},"quote":{"$ref":"#/components/schemas/v1Quote"},"state":{"title":"State of the ticket","type":"string"},"swapInstrumentId":{"title":"swap_instrument_id is the swap instrument this ticket targets (target_type = \"swap\")","type":"string"},"targetType":{"title":"Legacy discriminator, kept only to identify a ticket's target type when all the\ntyped target fields below are null (target was deleted)","type":"string"},"template":{"title":"Template information as JSON","type":"object"},"tradeInstrumentId":{"title":"trade_instrument_id is the trade instrument this ticket targets (target_type = \"trade\")","type":"string"},"type":{"title":"Type of the ticket (off-ramp, cex-custodial, cex-non-custodial, on-ramp, etc.)","type":"string"},"updatedAt":{"format":"date-time","title":"Updated at timestamp","type":"string"},"userChainAddress":{"title":"UserChainAddress associated with the ticket","type":"string"},"withdrawDestinationId":{"title":"Withdrawal destination ID associated with the ticket","type":"string"}},"required":["id","type","targetType","accountId","userChainAddress","amount","amountUsd","state","displayStatus","productFee","createdAt","updatedAt"],"title":"Ticket represents a support or issue ticket","type":"object"},"v1DexValueLocation":{"properties":{"amount":{"title":"amount is the quantity in the asset's base denomination, empty when the route halted\nbefore anything reported what was delivered","type":"string"},"chainId":{"title":"chain_id is the chain the value sits on","type":"string"},"denom":{"title":"denom is the asset denomination, empty when the halt cannot tell which asset landed","type":"string"},"lastTxHash":{"title":"last_tx_hash is the hash of the last transaction seen for the route before it halted","type":"string"}},"required":["chainId","lastTxHash"],"title":"DexValueLocation is where a halted DEX route left the user's value","type":"object"},"v1Quote":{"properties":{"quotePayload":{"$ref":"#/components/schemas/v1QuotePayload"},"signature":{"title":"signature contains the signature of the quote","type":"string"}},"required":["quotePayload","signature"],"title":"Quote contains the quote information","type":"object"},"v1QuotePayload":{"properties":{"accountId":{"title":"account_id is the account identifier","type":"string"},"assetIn":{"$ref":"#/components/schemas/v1AssetRef"},"assetOut":{"$ref":"#/components/schemas/v1AssetRef"},"exp":{"format":"int64","title":"exp contains the expiration timestamp in Unix","type":"string"},"expirationDate":{"format":"date-time","title":"total_fee contains the fees substracted from the amounts\nexpiration_date contains the date when the quote will expire in RFC 3339 format","type":"string"},"externalId":{"title":"external_id is the identifier of the quote if the provider does not return\nthe quote values. Instead of that return an ID that have to be fetched by API","type":"string"},"id":{"title":"id is the quote identifier","type":"string"},"meta":{"additionalProperties":{"type":"string"},"title":"meta contains additional metadata attached to the quote","type":"object"},"penaltyFee":{"$ref":"#/components/schemas/v1AssetRef"},"price":{"title":"Price contains the final price shown to the user","type":"string"},"productFee":{"$ref":"#/components/schemas/v1AssetRef"},"providerFee":{"$ref":"#/components/schemas/v1AssetRef"},"targetId":{"title":"target_id is the target identifier when type is offramp/onramp the\ntarget_id is the UUID of the product_provider. Otherwise when\ntype is swap the target_id is the instrument UUID","type":"string"},"targetType":{"title":"target_type is the quote type (offramp | onramp | swap | trade)","type":"string"}},"required":["id","accountId","targetId","targetType","assetIn","assetOut","providerFee","productFee","price","expirationDate","exp","meta"],"title":"QuotePayload describe the quote payload","type":"object"},"v1AssetRef":{"properties":{"amount":{"title":"amount contains the amount of the asset","type":"string"},"code":{"title":"code contains the identifier of the asset","type":"string"},"productId":{"title":"product_id is the identifier of the product this asset resolved to, when known. Disambiguates\nbetween multiple products sharing the same code on one trade instrument (e.g. the same token\non different chains) - unset on quotes signed before this field existed","type":"string"},"type":{"title":"type contains the type of the asset (fiat | crypto)","type":"string"}},"required":["code","type","amount"],"title":"AssetRef contains the asset information","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/{ticketId}":{"get":{"description":"Ticket data only. Use GetTicketDetails for the context, flows and\nprovider information as well","operationId":"TicketsQueryService_GetTicket","parameters":[{"description":"Unique identifier for the ticket","in":"path","name":"ticketId","required":true,"schema":{"type":"string"}},{"description":"account_id is the account that owns the ticket, the ticket is reported as not found otherwise","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetTicket returns a ticket by its ID","tags":["TicketsQueryService"]}}}}
```

## SubmitDexStep records the transaction hash for the step a DEX ticket is waiting on

> Submissions are only accepted while the ticket waits on a step, and the ticket must belong\
> to account\_id. The hash is verified against the expected step before it is accepted: it\
> has to exist on that step's chain, be sent by the ticket's wallet, and target the step's\
> contract. Resubmitting a hash already recorded on the route is a no-op, even after the\
> ticket moved on. Three FailedPrecondition errors are retryable with the same hash: the\
> transaction is not found on chain yet, its sender and target are not readable yet, or the\
> ticket is not waiting on a step, which a just-created ticket reports until its flow\
> reaches the step

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"TicketsMsgServiceSubmitDexStepBody":{"properties":{"accountId":{"title":"account_id is the account that owns the ticket","type":"string"},"txHash":{"title":"tx_hash is the hash of the transaction the caller submitted for the step the ticket is\ncurrently waiting on","type":"string"}},"required":["txHash","accountId"],"title":"SubmitDexStepRequest is the body request structure for the SubmitDexStep endpoint","type":"object"},"v1SubmitDexStepResponse":{"title":"SubmitDexStepResponse is the body response structure for the SubmitDexStep endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/{ticketId}/dex/step":{"post":{"description":"Submissions are only accepted while the ticket waits on a step, and the ticket must belong\nto account_id. The hash is verified against the expected step before it is accepted: it\nhas to exist on that step's chain, be sent by the ticket's wallet, and target the step's\ncontract. Resubmitting a hash already recorded on the route is a no-op, even after the\nticket moved on. Three FailedPrecondition errors are retryable with the same hash: the\ntransaction is not found on chain yet, its sender and target are not readable yet, or the\nticket is not waiting on a step, which a just-created ticket reports until its flow\nreaches the step","operationId":"TicketsMsgService_SubmitDexStep","parameters":[{"description":"ticket_id is the dex ticket the step belongs to","in":"path","name":"ticketId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketsMsgServiceSubmitDexStepBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1SubmitDexStepResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"SubmitDexStep records the transaction hash for the step a DEX ticket is waiting on","tags":["TicketsMsgService"]}}}}
```

## TicketGetPendingUserAction returns the pending user actions for a ticket

> Returns either a transaction the user still needs to sign/submit or a\
> URL they need to visit, depending on the ticket's current state

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TicketsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.read","tickets.tickets.read:all"]},{"BearerAuth":["tickets.tickets.read","tickets.tickets.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1TicketGetPendingUserActionResponse":{"properties":{"transactionPayload":{"$ref":"#/components/schemas/v1TransactionPayload"},"type":{"title":"The type of the ticket.\nExamples: offramp, onramp, swap","type":"string"},"urlPayload":{"$ref":"#/components/schemas/v1UrlPayload"}},"title":"TicketGetPendingUserActionResponse is the response structure for the TicketGetPendingUserAction endpoint","type":"object"},"v1TransactionPayload":{"properties":{"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"type":"array"}},"title":"TransactionPayload contains the list of transactions to be executed for a user action","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"v1UrlPayload":{"properties":{"expiresAt":{"format":"int64","title":"expires_at represents the expiration time of the URL","type":"string"},"url":{"title":"url represents the URL to be opened for the user action","type":"string"}},"required":["expiresAt"],"title":"UrlPayload contains the URL to be opened for a user action","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/{ticketId}/pending_user_actions":{"get":{"description":"Returns either a transaction the user still needs to sign/submit or a\nURL they need to visit, depending on the ticket's current state","operationId":"TicketsQueryService_TicketGetPendingUserAction","parameters":[{"description":"Unique identifier for the ticket","in":"path","name":"ticketId","required":true,"schema":{"type":"string"}},{"description":"account_id is the account that owns the ticket, the ticket is reported as not found otherwise","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1TicketGetPendingUserActionResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"TicketGetPendingUserAction returns the pending user actions for a ticket","tags":["TicketsQueryService"]}}}}
```

## SubmitTicketSignature sends the signature of a typed data action the ticket is waiting on

> Used when a ticket returns a typed\_data action instead of a transaction, for example the\
> permit of a swap. The signature must come from the signer of the action and the ticket must\
> belong to account\_id and still be waiting on the user. A wrong signature is rejected and the\
> ticket keeps waiting, so the user can sign again

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"TicketsMsgServiceSubmitTicketSignatureBody":{"properties":{"accountId":{"title":"account_id is the account that owns the ticket","type":"string"},"signature":{"title":"signature is the 65 byte EIP-712 signature as 0x prefixed hex","type":"string"},"type":{"title":"type is the type of the typed data action being signed, the accepted values are: permit","type":"string"}},"required":["accountId","type","signature"],"title":"SubmitTicketSignatureRequest is the body request structure for the SubmitTicketSignature endpoint","type":"object"},"v1SubmitTicketSignatureResponse":{"title":"SubmitTicketSignatureResponse is the body response structure for the SubmitTicketSignature endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/{ticketId}/signature":{"post":{"description":"Used when a ticket returns a typed_data action instead of a transaction, for example the\npermit of a swap. The signature must come from the signer of the action and the ticket must\nbelong to account_id and still be waiting on the user. A wrong signature is rejected and the\nticket keeps waiting, so the user can sign again","operationId":"TicketsMsgService_SubmitTicketSignature","parameters":[{"description":"ticket_id is the ticket waiting on the signature","in":"path","name":"ticketId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketsMsgServiceSubmitTicketSignatureBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1SubmitTicketSignatureResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"SubmitTicketSignature sends the signature of a typed data action the ticket is waiting on","tags":["TicketsMsgService"]}}}}
```

## CancelSubscriptionPaymentTicket cancels a subscription payment the user hasn't funded yet

> Only accepted while the ticket still waits for the escrow and none exists on-chain, the ticket\
> must belong to account\_id. The ticket ends expired, which frees the account to start a new\
> payment, for example on another chain. Canceling an already expired ticket is a no-op. A\
> funded escrow is canceled on-chain by the user instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Msg service (write operations)","name":"TicketsMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.write"]},{"BearerAuth":["tickets.tickets.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"TicketsMsgServiceCancelSubscriptionPaymentTicketBody":{"properties":{"accountId":{"title":"account_id is the account that owns the ticket","type":"string"}},"required":["accountId"],"title":"CancelSubscriptionPaymentTicketRequest is the request for the CancelSubscriptionPaymentTicket endpoint","type":"object"},"v1CancelSubscriptionPaymentTicketResponse":{"title":"CancelSubscriptionPaymentTicketResponse is the response for the CancelSubscriptionPaymentTicket endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/{ticketId}/subscription_payment/cancel":{"post":{"description":"Only accepted while the ticket still waits for the escrow and none exists on-chain, the ticket\nmust belong to account_id. The ticket ends expired, which frees the account to start a new\npayment, for example on another chain. Canceling an already expired ticket is a no-op. A\nfunded escrow is canceled on-chain by the user instead","operationId":"TicketsMsgService_CancelSubscriptionPaymentTicket","parameters":[{"description":"ticket_id is the subscription payment to cancel","in":"path","name":"ticketId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketsMsgServiceCancelSubscriptionPaymentTicketBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CancelSubscriptionPaymentTicketResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CancelSubscriptionPaymentTicket cancels a subscription payment the user hasn't funded yet","tags":["TicketsMsgService"]}}}}
```

## GetUserTransactions returns the list of available user transactions for a ticket based on its current state

> Transactions the end user still needs to sign and submit themselves\
> For admin-side transactions see GetAdminTransactions

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"TicketsQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["tickets.tickets.read","tickets.tickets.read:all"]},{"BearerAuth":["tickets.tickets.read","tickets.tickets.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserTransactionsResponse":{"properties":{"transactions":{"additionalProperties":{"$ref":"#/components/schemas/v1AdminTransactionList"},"title":"Map of transaction group key to list of transactions the user can submit","type":"object"}},"required":["transactions"],"title":"GetUserTransactionsResponse is the response structure for the GetUserTransactions endpoint","type":"object"},"v1AdminTransactionList":{"properties":{"transactions":{"items":{"$ref":"#/components/schemas/blockchainV1Transaction"},"type":"array"}},"required":["transactions"],"title":"AdminTransactionList wraps a repeated list of blockchain transactions","type":"object"},"blockchainV1Transaction":{"properties":{"evm":{"$ref":"#/components/schemas/v1EVMTransaction"},"typedData":{"$ref":"#/components/schemas/v1EVMTypedData"}},"title":"Transaction wraps the user actions to build an ordered list, either a transaction to send\nor a typed data to sign","type":"object"},"v1EVMTransaction":{"properties":{"chainId":{"title":"chain_id is the ID of the network","type":"string"},"data":{"title":"data is the hex raw call data to be sent on the transaction","type":"string"},"from":{"title":"from is the address from which the transaction should be sent","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information to be sent with the transaction","type":"object"},"to":{"title":"to is the address to which the transaction should be sent","type":"string"},"type":{"title":"type is the type of the tx -- kiirouter, approval, etc","type":"string"},"value":{"title":"value is the amount of native token to be sent with the transaction","type":"string"}},"required":["type","chainId","from","to","value","data"],"title":"EVMTransaction represents an EVM transaction to be sent to the blockchain","type":"object"},"v1EVMTypedData":{"description":"Sign typed_data as is with eth_signTypedData_v4 from the signer wallet, then send the\nsignature back with SubmitTicketSignature","properties":{"chainId":{"title":"chain_id is the ID of the network the typed data is bound to","type":"string"},"metadata":{"additionalProperties":{"type":"string"},"title":"metadata is the map of additional information sent with the typed data","type":"object"},"signer":{"title":"signer is the address that must sign the typed data","type":"string"},"type":{"title":"type is what is being signed, the accepted values are: permit","type":"string"},"typedData":{"title":"typed_data is the full EIP-712 JSON (types, domain, primaryType and message)","type":"string"}},"required":["type","chainId","signer","typedData"],"title":"EVMTypedData is an EIP-712 message the user signs instead of sending a transaction","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/tickets/v1/{ticketId}/user_txs":{"get":{"description":"Transactions the end user still needs to sign and submit themselves\nFor admin-side transactions see GetAdminTransactions","operationId":"TicketsQueryService_GetUserTransactions","parameters":[{"description":"The ID of the ticket","in":"path","name":"ticketId","required":true,"schema":{"type":"string"}},{"description":"account_id is the account that owns the ticket, the ticket is reported as not found otherwise","in":"query","name":"accountId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserTransactionsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserTransactions returns the list of available user transactions for a ticket based on its current state","tags":["TicketsQueryService"]}}}}
```


# Users

## CreateApiKey creates a new API Key

> priv\_key is returned only once, in this response. It isn't stored and\
> can't be retrieved again, only rotated via RotateApiKey

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.api.write"]},{"BearerAuth":["users.api.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1CreateApiKeyRequest":{"properties":{"allowedIps":{"items":{"type":"string"},"title":"allowed_ips is the list of IPs (1.2.3.4) or CIDR ranges (203.0.113.0/24) the api key can be used from,\nIPv4 or IPv6, empty means the api key works from any IP. Ranges can't have host bits set (203.0.113.5/24)","type":"array"},"expiresAt":{"format":"date-time","title":"expires_at is the date RFC 3339 (ISO 8601) when the Api key will expire","type":"string"},"name":{"title":"name is the user-assigned name of the api key","type":"string"},"scopes":{"items":{"type":"string"},"title":"scopes is the list of scopes asociated to the Api key","type":"array"}},"required":["name","scopes"],"title":"CreateApiKeyRequest represents the request body of the CreateApi endpoint","type":"object"},"v1CreateApiKeyResponse":{"properties":{"apiKey":{"title":"api_key represents the api key returned after successfully creation","type":"string"},"privKey":{"title":"priv_key is the base64 generated private key","type":"string"}},"required":["apiKey","privKey"],"title":"CreateApiKeyResponse represents the response body from the CreateApi endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/api/create":{"post":{"description":"priv_key is returned only once, in this response. It isn't stored and\ncan't be retrieved again, only rotated via RotateApiKey","operationId":"UsersMsgService_CreateApiKey","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateApiKeyRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1CreateApiKeyResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"CreateApiKey creates a new API Key","tags":["UsersMsgService"]}}}}
```

## UpdateApiKey overwrite the Api key information (scopes)

> Full replace of scopes, expires\_at and allowed\_ips. The key material itself is\
> unchanged. Use RotateApiKey to replace credentials instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.api.update"]},{"BearerAuth":["users.api.update"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"UsersMsgServiceUpdateApiKeyBody":{"properties":{"allowedIps":{"items":{"type":"string"},"title":"allowed_ips is the list of IPs (1.2.3.4) or CIDR ranges (203.0.113.0/24) the api key can be used from,\nIPv4 or IPv6, empty means the api key works from any IP. Ranges can't have host bits set (203.0.113.5/24)","type":"array"},"expiresAt":{"format":"date-time","title":"expires_at is the date RFC 3339 (ISO 8601) when the Api key will expire","type":"string"},"scopes":{"items":{"type":"string"},"title":"scopes is the list of scopes asociated to the Api key","type":"array"}},"required":["scopes"],"title":"UpdateApiKeyRequest represents the request body of the UpdateApi endpoint","type":"object"},"v1UpdateApiKeyResponse":{"title":"UpdateApiKeyResponse represents the response body from the UpdateApi endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/api/{apiKeyId}":{"patch":{"description":"Full replace of scopes, expires_at and allowed_ips. The key material itself is\nunchanged. Use RotateApiKey to replace credentials instead","operationId":"UsersMsgService_UpdateApiKey","parameters":[{"description":"api_key represents the api key returned after successfully creation","in":"path","name":"apiKeyId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsersMsgServiceUpdateApiKeyBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1UpdateApiKeyResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"UpdateApiKey overwrite the Api key information (scopes)","tags":["UsersMsgService"]}}}}
```

## DeleteApiKey deletes the provided api key id

> Immediate and irreversible. Any client still using this key starts\
> failing authentication right away

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.api.delete"]},{"BearerAuth":["users.api.delete"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1DeleteApiKeyResponse":{"title":"DeleteApiKeyResponse represents the response body from the DeleteApi endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/api/{apiKeyId}/delete":{"delete":{"description":"Immediate and irreversible. Any client still using this key starts\nfailing authentication right away","operationId":"UsersMsgService_DeleteApiKey","parameters":[{"description":"api_key represents the api key returned after successfully creation","in":"path","name":"apiKeyId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1DeleteApiKeyResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"DeleteApiKey deletes the provided api key id","tags":["UsersMsgService"]}}}}
```

## RotateApiKey takes the provided Api Key and rotates credentials (changes Api Key, Pub Key and Priv Key)

> The old api\_key stops working immediately. Priv\_key is only returned\
> in this response, same as on creation

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.api.write"]},{"BearerAuth":["users.api.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1RotateApiKeyResponse":{"properties":{"apiKey":{"title":"api_key represents the new api key after rotataion","type":"string"},"privKey":{"title":"priv_key is the new base64 generated after rotation","type":"string"},"pubKey":{"title":"pub_key is the new base64 generated after rotation","type":"string"}},"required":["apiKey","pubKey","privKey"],"title":"RotateApiKeyResponse represents the response body from the RotateApiKey endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/api/{apiKeyId}/rotate":{"patch":{"description":"The old api_key stops working immediately. Priv_key is only returned\nin this response, same as on creation","operationId":"UsersMsgService_RotateApiKey","parameters":[{"description":"api_key represents the provided api key","in":"path","name":"apiKeyId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1RotateApiKeyResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"RotateApiKey takes the provided Api Key and rotates credentials (changes Api Key, Pub Key and Priv Key)","tags":["UsersMsgService"]}}}}
```

## GetApiKeyScopes returns the scopes associated to the provided api key id

> Scopes an API key carries directly, distinct from the calling user's own\
> role-based scopes (see GetUserRoles)

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.api.read"]},{"BearerAuth":["users.api.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetApiKeyScopesResponse":{"properties":{"scopes":{"items":{"type":"string"},"title":"scopes is the list of scopes asociated to the Api key","type":"array"}},"required":["scopes"],"title":"GetApiKeyScopesScopes represents the response body from the GetApiKeyScopes endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/api/{apiKeyId}/scopes":{"get":{"description":"Scopes an API key carries directly, distinct from the calling user's own\nrole-based scopes (see GetUserRoles)","operationId":"UsersQueryService_GetApiKeyScopes","parameters":[{"description":"api_key represents the provided api key","in":"path","name":"apiKeyId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetApiKeyScopesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetApiKeyScopes returns the scopes associated to the provided api key id","tags":["UsersQueryService"]}}}}
```

## GetUserApiKeys returns all the user api keys

> Never includes priv\_key. That's only ever returned once, at\
> creation/rotation time

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.api.read","users.api.read:all"]},{"BearerAuth":["users.api.read","users.api.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserApiKeysResponse":{"properties":{"apiKey":{"items":{"$ref":"#/components/schemas/v1ApiKey"},"title":"api_keys is the list of api keys asociated to the user","type":"array"}},"required":["apiKey"],"title":"GetUserApiKeysResponse represents the response body from the GetUserApiKeys endpoint","type":"object"},"v1ApiKey":{"properties":{"allowedIps":{"items":{"type":"string"},"title":"allowed_ips is the list of IPs or CIDR ranges the api key can be used from, empty means any IP","type":"array"},"apiKey":{"title":"api_key is the opaque string related to the api key","type":"string"},"createdAt":{"format":"date-time","title":"created_at is the date when the api key was created","type":"string"},"expiresAt":{"format":"date-time","title":"revoked_at is the date when the api key was revoked","type":"string"},"id":{"title":"id is the api key identifier","type":"string"},"lastUsedAt":{"format":"date-time","title":"last_used_at is the date when the api key was last used","type":"string"},"name":{"title":"name is the user-assigned name of the api key","type":"string"},"privKey":{"title":"priv_key is the base64 generated private key","type":"string"},"pubKey":{"title":"pub_key is the base64 generated public key","type":"string"},"revokedAt":{"format":"date-time","title":"revoked_at is the date when the api key was revoked","type":"string"},"scopes":{"items":{"type":"string"},"title":"scopes is the list of scopes asociated to the Api key","type":"array"}},"required":["id","name","apiKey","scopes","pubKey","privKey","createdAt","allowedIps"],"title":"ApiKey contains all information with a api key","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/api/{userId}/api-keys":{"get":{"description":"Never includes priv_key. That's only ever returned once, at\ncreation/rotation time","operationId":"UsersQueryService_GetUserApiKeys","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserApiKeysResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserApiKeys returns all the user api keys","tags":["UsersQueryService"]}}}}
```

## Me is the endpoint to get the current authenticated user

> Also returns the active account (with KYC and wallets) and the caller's\
> roles, which GetUser doesn't include

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.read"]},{"BearerAuth":["users.profile.read"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1MeResponse":{"properties":{"account":{"$ref":"#/components/schemas/v1Account"},"hasPassword":{"title":"has_password is false for users who signed up with an OAuth provider and never set a password","type":"boolean"},"roles":{"items":{"type":"string"},"title":"roles contains the list of roles associated to the user","type":"array"},"user":{"$ref":"#/components/schemas/v1User"}},"required":["user","account","roles","hasPassword"],"title":"MeResponse is the body response structure from the Me endpoint","type":"object"},"v1Account":{"properties":{"accountName":{"title":"account_name is the name of the account","type":"string"},"accountType":{"title":"account_type is the type of the account","type":"string"},"countries":{"items":{"type":"string"},"title":"countries is the list of countries associated to the account, in ISO 3166-1 alpha-3 format","type":"array"},"createdAt":{"format":"date-time","title":"created_at is the date when the account was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the account was deleted","type":"string"},"id":{"title":"id is the account identifier","type":"string"},"kycInfo":{"$ref":"#/components/schemas/v1KycInfo"},"privyId":{"title":"privy_id is the identifier of the account on Privy, which is the Wallet provider used by default","type":"string"},"subscription":{"$ref":"#/components/schemas/v1Subscription"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the account was updated","type":"string"},"userId":{"title":"account_name is the user-assigned name of the account","type":"string"},"wallets":{"items":{"$ref":"#/components/schemas/v1Wallet"},"title":"wallets is the information about the wallets associated to the account","type":"array"}},"required":["id","userId","accountName","accountType","wallets","kycInfo","createdAt","updatedAt","privyId"],"title":"Account contains all information with a account","type":"object"},"v1KycInfo":{"properties":{"level":{"format":"int32","title":"level is the name of the KYC level approved","type":"integer"},"provider":{"title":"provider is the KYC provider name","type":"string"},"requestedAt":{"format":"date-time","title":"requested_at is the date when the KYC was requested","type":"string"},"status":{"title":"status is the KYC status","type":"string"},"verifiedAt":{"format":"date-time","title":"verified_at is the date when the KYC was verified","type":"string"}},"required":["provider","level","status","requestedAt","verifiedAt"],"title":"KycInfo contains the KYC information per account","type":"object"},"v1Subscription":{"properties":{"code":{"title":"code is the stable identifier of the subscription plan","type":"string"},"status":{"title":"status is the subscription status. One of: trialing, active, past_due, canceled,\nunpaid, incomplete, paused","type":"string"},"tier":{"format":"int32","title":"tier ranks the plan's access level, higher grants more access","type":"integer"}},"required":["code","tier","status"],"title":"Subscription identifies the billing plan an account is (or was) subscribed to","type":"object"},"v1Wallet":{"properties":{"address":{"title":"address is the unique wallet address","type":"string"},"chainType":{"title":"chain_type is which chain is using this wallet","type":"string"},"id":{"title":"id is the wallet identifier","type":"string"}},"required":["id","address","chainType"],"title":"Wallet contains all information about a wallet","type":"object"},"v1User":{"properties":{"admin":{"title":"admin is the boolean flag to know if the user is an admin (has access to the admin panel)","type":"boolean"},"createdAt":{"format":"date-time","title":"created_at is the date when the user was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the user was deleted","type":"string"},"displayName":{"title":"display_name is the user display name","type":"string"},"email":{"title":"email is the user email","type":"string"},"emailVerified":{"title":"email_verified indicates whether the user's email has been verified","type":"boolean"},"id":{"title":"id is the user identifier","type":"string"},"isMfaEnabled":{"title":"isMfaEnabled is the boolean flag to enable/disable MFA","type":"boolean"},"language":{"title":"language contains the current user language which will be used on notifications","type":"string"},"lockReason":{"title":"lock_reason is the reason when the user is locked","type":"string"},"locked":{"title":"locked is the boolean flag to lock/unlock the user","type":"boolean"},"passwordChangedAt":{"format":"date-time","title":"password_changed_at is the date when the password was changed","type":"string"},"superAdmin":{"title":"super_admin is the boolean flag to enable/disable super admin permissions","type":"boolean"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the user was updated","type":"string"}},"required":["id","email","displayName","isMfaEnabled","locked","superAdmin","language","createdAt","updatedAt","admin","emailVerified"],"title":"User contains all information with a user","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/me":{"get":{"description":"Also returns the active account (with KYC and wallets) and the caller's\nroles, which GetUser doesn't include","operationId":"UsersQueryService_Me","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1MeResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"Me is the endpoint to get the current authenticated user","tags":["UsersQueryService"]}}}}
```

## UpdateMyProfile is the endpoint for a user to update their own profile (display\_name, language).

> Self-service only. No user\_id in the request, it always acts on the\
> caller.

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.write"]},{"BearerAuth":["users.profile.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1UpdateMyProfileRequest":{"properties":{"displayName":{"title":"display_name is the user display name","type":"string"},"language":{"title":"language is the user language","type":"string"}},"required":["displayName","language"],"title":"UpdateMyProfileRequest is the body request for the user self-update profile endpoint","type":"object"},"v1UpdateMyProfileResponse":{"title":"UpdateMyProfileResponse is the body response for the user self-update profile endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/me/change_profile":{"patch":{"description":"Self-service only. No user_id in the request, it always acts on the\ncaller.","operationId":"UsersMsgService_UpdateMyProfile","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1UpdateMyProfileRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1UpdateMyProfileResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"UpdateMyProfile is the endpoint for a user to update their own profile (display_name, language).","tags":["UsersMsgService"]}}}}
```

## StartEmailChange starts changing the caller's email and sends a code to the new address

> MFA users send the X-Mfa-Code header. Otherwise users with a password send\
> password, and users without one send current\_email\_code from\
> RequestEmailChangeCode. A new request replaces any pending change

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.write"]},{"BearerAuth":["users.profile.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1StartEmailChangeRequest":{"properties":{"currentEmailCode":{"title":"current_email_code is the 6-digit code from RequestEmailChangeCode, required\nwhen the caller has no password and no MFA","type":"string"},"newEmail":{"title":"new_email is the email the caller wants to switch to","type":"string"},"password":{"title":"password is the caller's password, required when they have one and no MFA","type":"string"}},"required":["newEmail"],"title":"StartEmailChangeRequest is the body request for starting an email change","type":"object"},"v1StartEmailChangeResponse":{"title":"StartEmailChangeResponse is the response for starting an email change","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/me/email/change":{"post":{"description":"MFA users send the X-Mfa-Code header. Otherwise users with a password send\npassword, and users without one send current_email_code from\nRequestEmailChangeCode. A new request replaces any pending change","operationId":"UsersMsgService_StartEmailChange","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1StartEmailChangeRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1StartEmailChangeResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"StartEmailChange starts changing the caller's email and sends a code to the new address","tags":["UsersMsgService"]}}}}
```

## RequestEmailChangeCode sends a one-time code to the caller's current email

> Security step for users without a password and without MFA (OAuth signups)\
> before StartEmailChange. One code per minute

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.write"]},{"BearerAuth":["users.profile.write"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1RequestEmailChangeCodeRequest":{"title":"RequestEmailChangeCodeRequest is the body request for sending a code to the current email","type":"object"},"v1RequestEmailChangeCodeResponse":{"title":"RequestEmailChangeCodeResponse is the response for sending a code to the current email","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/me/email/current-code":{"post":{"description":"Security step for users without a password and without MFA (OAuth signups)\nbefore StartEmailChange. One code per minute","operationId":"UsersMsgService_RequestEmailChangeCode","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1RequestEmailChangeCodeRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1RequestEmailChangeCodeResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"RequestEmailChangeCode sends a one-time code to the caller's current email","tags":["UsersMsgService"]}}}}
```

## GetUser returns a single user

> Lookup by user\_id. For the caller's own profile use Me instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.read","users.profile.read:all"]},{"BearerAuth":["users.profile.read","users.profile.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserResponse":{"properties":{"accounts":{"items":{"type":"string"},"title":"accounts contains the list of accounts the user belongs to","type":"array"},"user":{"$ref":"#/components/schemas/v1User"}},"required":["user","accounts"],"title":"GetUserResponse is the body response structure from the Get user endpoint","type":"object"},"v1User":{"properties":{"admin":{"title":"admin is the boolean flag to know if the user is an admin (has access to the admin panel)","type":"boolean"},"createdAt":{"format":"date-time","title":"created_at is the date when the user was created","type":"string"},"deletedAt":{"format":"date-time","title":"deleted_at is the date when the user was deleted","type":"string"},"displayName":{"title":"display_name is the user display name","type":"string"},"email":{"title":"email is the user email","type":"string"},"emailVerified":{"title":"email_verified indicates whether the user's email has been verified","type":"boolean"},"id":{"title":"id is the user identifier","type":"string"},"isMfaEnabled":{"title":"isMfaEnabled is the boolean flag to enable/disable MFA","type":"boolean"},"language":{"title":"language contains the current user language which will be used on notifications","type":"string"},"lockReason":{"title":"lock_reason is the reason when the user is locked","type":"string"},"locked":{"title":"locked is the boolean flag to lock/unlock the user","type":"boolean"},"passwordChangedAt":{"format":"date-time","title":"password_changed_at is the date when the password was changed","type":"string"},"superAdmin":{"title":"super_admin is the boolean flag to enable/disable super admin permissions","type":"boolean"},"updatedAt":{"format":"date-time","title":"updated_at is the date when the user was updated","type":"string"}},"required":["id","email","displayName","isMfaEnabled","locked","superAdmin","language","createdAt","updatedAt","admin","emailVerified"],"title":"User contains all information with a user","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/{userId}":{"get":{"description":"Lookup by user_id. For the caller's own profile use Me instead","operationId":"UsersQueryService_GetUser","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUser returns a single user","tags":["UsersQueryService"]}}}}
```

## UpdateLanguage is the endpoint to update the user language

> Callable on any user. For a user updating\
> their own language use UpdateMyProfile instead

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.write","users.profile.write:all"]},{"BearerAuth":["users.profile.write","users.profile.write:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"UsersMsgServiceUpdateLanguageBody":{"properties":{"language":{"title":"language represents the desired language","type":"string"}},"required":["language"],"title":"UpdateLanguageRequest is the body request for the update language endpoint","type":"object"},"v1UpdateLanguageResponse":{"title":"UpdateLanguageResponse is the body response for the update language endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/{userId}/language":{"patch":{"description":"Callable on any user. For a user updating\ntheir own language use UpdateMyProfile instead","operationId":"UsersMsgService_UpdateLanguage","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsersMsgServiceUpdateLanguageBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1UpdateLanguageResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"UpdateLanguage is the endpoint to update the user language","tags":["UsersMsgService"]}}}}
```

## GetUserRoles is the endpoint to get the user roles and scopes

> scopes is the flattened, deduplicated union of every role's scopes\
> This is what actually determines the user's permissions

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.read","users.profile.read:all"]},{"BearerAuth":["users.profile.read","users.profile.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserRolesResponse":{"properties":{"roles":{"items":{"$ref":"#/components/schemas/v1UserRole"},"title":"roles contains the list of role objects associated to the user","type":"array"},"scopes":{"items":{"type":"string"},"title":"scopes contains the list of scopes associated to the user through its roles","type":"array"}},"required":["roles","scopes"],"type":"object"},"v1UserRole":{"properties":{"id":{"format":"int64","title":"id represents the role identifier","type":"string"},"name":{"title":"name represents the role name","type":"string"}},"required":["id","name"],"title":"GetUserRolesResponse is the body response structure from the GetUserRoles endpoint.\nIt returns the list of roles and scopes associated to the user, it is used to determine the user permissions in the system","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/{userId}/roles":{"get":{"description":"scopes is the flattened, deduplicated union of every role's scopes\nThis is what actually determines the user's permissions","operationId":"UsersQueryService_GetUserRoles","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserRolesResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserRoles is the endpoint to get the user roles and scopes","tags":["UsersQueryService"]}}}}
```

## GetUserSettings returns the settings for a user

> Currently just max\_allowance. Update via PatchUserSettings

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.settings.read","users.settings.read:all"]},{"BearerAuth":["users.settings.read","users.settings.read:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetUserSettingsResponse":{"properties":{"settings":{"$ref":"#/components/schemas/v1UserSettings"}},"required":["settings"],"title":"GetUserSettingsResponse is the response for the get user settings endpoint","type":"object"},"v1UserSettings":{"properties":{"id":{"title":"id is the settings row identifier","type":"string"},"maxAllowance":{"title":"max_allowance controls whether max allowance is enabled for the user","type":"boolean"},"userId":{"title":"user_id is the user this settings row belongs to","type":"string"}},"required":["id","userId","maxAllowance"],"title":"UserSettings holds the settings for a user","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/{userId}/settings":{"get":{"description":"Currently just max_allowance. Update via PatchUserSettings","operationId":"UsersQueryService_GetUserSettings","parameters":[{"description":"user_id is the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetUserSettingsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetUserSettings returns the settings for a user","tags":["UsersQueryService"]}}}}
```

## PatchUserSettings partially updates the settings for a user. Any setting not set in the body will be left unchanged.

> max\_allowance is optional in the request specifically so it can be\
> omitted to leave the current value untouched

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Commands (write operations)","name":"UsersMsgService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.settings.write","users.settings.write:all"]},{"BearerAuth":["users.settings.write","users.settings.write:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"UsersMsgServicePatchUserSettingsBody":{"properties":{"maxAllowance":{"title":"max_allowance when set, updates whether max allowance is enabled for the user","type":"boolean"}},"title":"PatchUserSettingsRequest is the request for the patch user settings endpoint","type":"object"},"v1PatchUserSettingsResponse":{"title":"PatchUserSettingsResponse is the response for the patch user settings endpoint","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/users/{userId}/settings":{"patch":{"description":"max_allowance is optional in the request specifically so it can be\nomitted to leave the current value untouched","operationId":"UsersMsgService_PatchUserSettings","parameters":[{"description":"user_id is the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsersMsgServicePatchUserSettingsBody"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1PatchUserSettingsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"PatchUserSettings partially updates the settings for a user. Any setting not set in the body will be left unchanged.","tags":["UsersMsgService"]}}}}
```

## GetMfaMethods returns the Mfa method registered for the user (if any)

> Only non-sensitive info per method (type, label, verified/primary\
> flags). Never secrets like the TOTP seed

```json
{"openapi":"3.0.0","info":{"title":"KiiChain Pay Backend","version":"v1"},"tags":[{"description":"Queries (read operations)","name":"UsersQueryService"}],"servers":[{"description":"Production","url":"https://backend.pay.kiichain.io"},{"description":"Staging","url":"https://backend.pay.staging.kiichain.io"}],"security":[{"ApiKeyAuth":["users.profile.mfa","users.profile.mfa:all"]},{"BearerAuth":["users.profile.mfa","users.profile.mfa:all"]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"Send 'Authorization: APIKey <api-key>' to authenticate with a API key.","in":"header","name":"Authorization","type":"apiKey"},"BearerAuth":{"flows":{"password":{"scopes":{},"tokenUrl":"https://backend.pay.kiichain.io/users/v1/auth/login"}},"type":"oauth2"}},"schemas":{"v1GetMfaMethodsResponse":{"properties":{"methods":{"items":{"$ref":"#/components/schemas/v1MfaMethod"},"type":"array"}},"required":["methods"],"title":"GetMfaMethodsResponse is the response body structure from the Get Mfa Methods endpoint","type":"object"},"v1MfaMethod":{"properties":{"isPrimary":{"title":"is_primary is a flag that represents if this Mfa method is the primary one","type":"boolean"},"isVerified":{"title":"is_verified is a flag that represents if this Mfa method is verified","type":"boolean"},"label":{"title":"label means the name of the method provided by the user","type":"string"},"lastUsedAt":{"format":"date-time","title":"last_used_at is the date when the mfa method was last used","type":"string"},"mfaId":{"title":"mfa_id contains the identifier of the method","type":"string"},"mfaType":{"title":"mfa_type represents the desired mfa method","type":"string"}},"required":["mfaId","mfaType","label","isPrimary","isVerified"],"title":"MfaMethod is the custom type for a Mfa Method with only the information\nand non-sensitive information that can be shown to the user","type":"object"},"AppErrorStatus":{"description":"The error envelope this API returns for every non-2xx response. `details` always contains exactly one AppError.","properties":{"code":{"description":"gRPC status code","format":"int32","type":"integer"},"details":{"description":"Always contains exactly one AppError","items":{"$ref":"#/components/schemas/AppError"},"type":"array"},"message":{"description":"Human-readable error message","type":"string"}},"type":"object"},"AppError":{"description":"Structured error detail responded by any non-2xx response.","properties":{"@type":{"description":"Protobuf Any type URL, always \"type.googleapis.com/pay.common.error.v1.AppError\" for this API","type":"string"},"internalCode":{"description":"Internal error code, unique within the module","format":"int32","type":"integer"},"message":{"description":"Human-readable error message","type":"string"},"meta":{"additionalProperties":{"type":"string"},"description":"Additional structured context for the error, if any","type":"object"},"module":{"description":"Module name where the error occurred (e.g. \"accounts\", \"market\")","type":"string"}},"type":"object"}},"responses":{"AppError":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppErrorStatus"}}},"description":"An unexpected error response. `details[0]` is always an AppError, see #/components/schemas/AppError"}}},"paths":{"/users/v1/{userId}/mfa/methods":{"get":{"description":"Only non-sensitive info per method (type, label, verified/primary\nflags). Never secrets like the TOTP seed","operationId":"UsersQueryService_GetMfaMethods","parameters":[{"description":"user_id represents the user identifier","in":"path","name":"userId","required":true,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v1GetMfaMethodsResponse"}}},"description":"A successful response."},"default":{"$ref":"#/components/responses/AppError"}},"summary":"GetMfaMethods returns the Mfa method registered for the user (if any)","tags":["UsersQueryService"]}}}}
```


# Developer Hub

Everything you need to know about building on KiiChain. Your hub for connecting to the chain and building applications on the decentralized web.

## Networks

### Mainnet

Kiichain mainnet is the production network (`kiichain_1783-1`, EVM chain ID `1783`). Use it for production deployments and mainnet validator operations:

* [Kiichain Mainnet](https://docs.kiiglobal.io/docs/build-on-kiichain/kiichain-mainnet)

### Testnets

Testnet Oro is the permanent public testnet with smart contract functionality and EVM compatibility. Use it for hackathons, builds, airdrops, and test deployments:

* [Testnet Oro](https://docs.kiiglobal.io/docs/build-on-kiichain/testnet-oro)

## Bridge

Bridge KII between Kiichain and supported chains via Hyperlane:

* [Bridge](https://docs.kiiglobal.io/docs/learn/getting-started/bridge)

## Developer Tools

If you are a developer we also have our official SDKs for development:

* [Rust SDK](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/rust-sdk)
* [JS/TS SDK](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/js-ts-sdk)

## Protocols

Kii protocols can be found at these links:

* [RWA Protocol](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/rwa-protocol)

## Endpoints

Generally, our chains (testnets and mainnet) follow the same set of endpoints. More information about our endpoints can be found here:

* [Endpoints - EVM](https://docs.kiiglobal.io/docs/build-on-kiichain/endpoints-evm)
* [Endpoints - Cosmos](https://docs.kiiglobal.io/docs/build-on-kiichain/endpoints-cosmos)

## **KiiChain Discord Server**

If you would like to connect directly with the community and ask questions related to building on the network, join the discord server where our internal developers are ready to field any questions you have.

* [Discord Kiichain invite](https://discord.com/invite/fUcfeYYtVF)


# Kiichain Mainnet

Everything you need to know about Kiichain mainnet.

Kiichain is a peer-to-peer decentralized EVM-compatible network built with the Cosmos SDK. The mainnet chain ID is `kiichain_1783-1`.

For experimentation, hackathons, and test deployments, use [Testnet Oro](https://docs.kiiglobal.io/docs/build-on-kiichain/testnet-oro). Use mainnet for production deployments and mainnet validator operations.

## Source code

* [Kiichain](https://github.com/KiiChain/kiichain)
* [Mainnet configs and join scripts](https://github.com/KiiChain/mainnets/tree/main/kiichain)

## Endpoints

* **RPC:** <https://rpc.kiivalidator.com>
* **Rest (LCD):** <https://lcd.kiivalidator.com>
* **GRPC:** grpc.kiivalidator.com:443
* **JSON-RPC (EVM):** <https://json-rpc.kiivalidator.com>
* **WebSocket:** wss\://ws.kiivalidator.com/websocket

Persistent peers:

* `4d0c3be48018cf8234faa46d789634f8a811dc5b@p2p-1.kiivalidator.com:26656`
* `ac58976b16880535d56b2e1fe1f499a3841c4039@p2p-2.kiivalidator.com:26656`

## Chain information

* **Chain ID:** `kiichain_1783-1`
* **EVM Chain ID:** `1783`
* **Token Denom:** `akii`
* **Decimals:** `18`
* **Bech32 Prefix:** `kii`
* **Max Supply:** `1.8b KII`

## How to join the network

Instructions and join scripts are available in the mainnets repository:

* [Join Kiichain](https://github.com/KiiChain/mainnets/blob/main/kiichain/join_kiichain.sh)
* [Join Kiichain with Cosmovisor](https://github.com/KiiChain/mainnets/blob/main/kiichain/join_kiichain_cv.sh)
* [Step-by-Step Guide](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/step-by-step-guide)

## Bridge KII

KII is available on connected chains through Hyperlane. See:

* [Bridge](https://docs.kiiglobal.io/docs/learn/getting-started/bridge)

## Developer tools

* [RWA Protocol](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/rwa-protocol)
* [Deploying a smart contract](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/deploy-a-smart-contract)
* [Deploying a dApp](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/deploy-a-dapp)
* [Endpoints - EVM](https://docs.kiiglobal.io/docs/build-on-kiichain/endpoints-evm)
* [Endpoints - Cosmos](https://docs.kiiglobal.io/docs/build-on-kiichain/endpoints-cosmos)


# Testnet Oro

Everything you need to know  about our Testnet Oro

KiiChain is a peer-to-peer decentralized EVM-compatible network built with the Cosmos SDK. The public testnet is called KiiChain Testnet Oro.

Testnet Oro is the permanent testnet with smart contract functionality and EVM compatibility. All Hackathons, Builds, Airdrops, and test deployments should be done on this network.

## Source code

The source code for the Testnet Oro can be found at:

* [Kiichain](https://github.com/KiiChain/kiichain)

## Endpoints

Testnet Oro has the following endpoints open for development purposes:

**Sentry #1:**

* **RPC:** <https://rpc.uno.sentry.testnet.v3.kiivalidator.com/>
* **Rest (LCD):** <https://lcd.uno.sentry.testnet.v3.kiivalidator.com/>
* **GRPC:** grpc.uno.sentry.testnet.v3.kiivalidator.com:443
* **JSON-RPC (EVM):** <https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/>
* **Peer:** <5b6aa55124c0fd28e47d7da091a69973964a9fe1@uno.sentry.testnet.v3.kiivalidator.com>:26656

**Sentry #2:**

* **RPC:** <https://rpc.dos.sentry.testnet.v3.kiivalidator.com/>
* **Rest (LCD):** <https://lcd.dos.sentry.testnet.v3.kiivalidator.com/>
* **GRPC:** grpc.dos.sentry.testnet.v3.kiivalidator.com:443
* **JSON-RPC (EVM):** <https://json-rpc.dos.sentry.testnet.v3.kiivalidator.com/>
* **Peer:** <5e6b283c8879e8d1b0866bda20949f9886aff967@dos.sentry.testnet.v3.kiivalidator.com>:26656

Currently, there are no seed nodes or persistent peers available to the public.

## Chain information

Here you can find further information about Testnet Oro:

* **Chain ID:** `oro_1336-1`
* **Total Supply:** `1.8b Kii`
* **Token Denom:** `akii`
* **EVM Chain ID:** `1336`
* **Bech32 Prefix:** `kii`

## How to chain the network

Instructions on how to join the network can be found at:

* [Step-by-Step Guide](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/step-by-step-guide)

## Faucet

You can get tokens to our Testnet Oro by using our Explorer app:

* [KiiChain Explorer Faucet](https://explorer.kiichain.io/faucet)

Our through our Discord channel:

* [Discord Kiichain Invitation](https://discord.com/invite/kiichain)

More information about how to use our discord Faucet can be found at:

* [Testnet Faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)

## Explorer

The testnet Oro also has its own Explorer, it can be found here:

* [Testnet Oro Explorer](https://testnet.explorer.kiichain.io/)

## Developer Tools

You can find guides to the testnet at our [Developer Tools](#developer-tools):

* [RWA Protocol](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/rwa-protocol)
* [Deploying a smart contract](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/deploy-a-smart-contract)
* [Deploying a dApp](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/deploy-a-dapp)

## Endpoints

Rest and EVM endpoints for Testnet Oro can be found here:

* [Endpoints - Cosmos](https://docs.kiiglobal.io/docs/build-on-kiichain/endpoints-cosmos)
* [Endpoints - EVM](https://docs.kiiglobal.io/docs/build-on-kiichain/endpoints-evm)

## **EVM / CW Addresses**

KiiChain Testnet Oro features a mirrored EVM - CW smart contract module that replicates EVM compatibility. CW addresses are structured in Bech32 format with a distinctive "kii" prefix, characteristic of Cosmos-based chains. EVM addresses are structured with the hexadecimal format akin to Ethereum addresses. This alteration reflects a strategic adaptation to streamline interoperability with Ethereum-based tools and infrastructure, facilitating a seamless transition for developers and users alike.

```
// CosmWasm based addresses
kii123abc...

// EVM based addresses
0x123abc...
```

## **Tokens**

KII serves as the primary utility token within the KiiChain ecosystem, facilitating transactions and powering network operations, notably through the payment of gas fees. Distinguished by its fungibility and interoperability, KII can be seamlessly transferred and utilized across various wallet providers, including popular EVM rpc-based options like MetaMask & Coinbase wallet and cosmos-based wallets like Keplr and Leap. By leveraging KII, users can engage in a diverse array of interactions within the KiiChain network, ranging from simple transactions to more complex smart contract executions, thereby driving the adoption and utility of the native token within the broader blockchain landscape.


# Endpoints - EVM

EVM Endpoints for Kiichain

Kiichain follows the standard JSON-RPC calls from Ethereum.

You can find more information about all the available endpoints at:

* [JSON-RPC API Methods](https://ethereum.org/developers/docs/apis/json-rpc)

## Mainnet

* **EVM Chain ID:** `1783`
* **JSON-RPC:** <https://json-rpc.kiivalidator.com>
* **WebSocket:** wss\://ws.kiivalidator.com/websocket

See also: [Kiichain Mainnet](https://docs.kiiglobal.io/docs/build-on-kiichain/kiichain-mainnet)

## Testnet Oro

* **EVM Chain ID:** `1336`
* **JSON-RPC (Sentry #1):** <https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/>
* **JSON-RPC (Sentry #2):** <https://json-rpc.dos.sentry.testnet.v3.kiivalidator.com/>

See also: [Testnet Oro](https://docs.kiiglobal.io/docs/build-on-kiichain/testnet-oro)


# Endpoints - Cosmos

Endpoints for Testnet Oro


# EVM


# VM

## GET /cosmos/evm/vm/v1/params

> Params queries the parameters of x/vm module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/params":{"get":{"summary":"Params queries the parameters of x/vm module.","operationId":"VmParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params define the evm module parameters.","type":"object","properties":{"evm_denom":{"type":"string","description":"evm_denom represents the token denomination used to run the EVM state\ntransitions."},"extra_eips":{"type":"array","items":{"type":"string"},"title":"extra_eips defines the additional EIPs for the vm.Config"},"chain_config":{"title":"chain_config defines the EVM chain configuration parameters","type":"object","properties":{"homestead_block":{"type":"string","title":"homestead_block switch (nil no fork, 0 = already homestead)"},"dao_fork_block":{"type":"string","title":"dao_fork_block corresponds to TheDAO hard-fork switch block (nil no fork)"},"dao_fork_support":{"type":"boolean","title":"dao_fork_support defines whether the nodes supports or opposes the DAO\nhard-fork"},"eip150_block":{"type":"string","title":"eip150_block: EIP150 implements the Gas price changes\n(https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork)"},"eip150_hash":{"type":"string","title":"eip150_hash: EIP150 HF hash (needed for header only clients as only gas\npricing changed)"},"eip155_block":{"type":"string","title":"eip155_block: EIP155Block HF block"},"eip158_block":{"type":"string","title":"eip158_block: EIP158 HF block"},"byzantium_block":{"type":"string","title":"byzantium_block: Byzantium switch block (nil no fork, 0 = already on\nbyzantium)"},"constantinople_block":{"type":"string","title":"constantinople_block: Constantinople switch block (nil no fork, 0 = already\nactivated)"},"petersburg_block":{"type":"string","title":"petersburg_block: Petersburg switch block (nil same as Constantinople)"},"istanbul_block":{"type":"string","title":"istanbul_block: Istanbul switch block (nil no fork, 0 = already on\nistanbul)"},"muir_glacier_block":{"type":"string","title":"muir_glacier_block: Eip-2384 (bomb delay) switch block (nil no fork, 0 =\nalready activated)"},"berlin_block":{"type":"string","title":"berlin_block: Berlin switch block (nil = no fork, 0 = already on berlin)"},"london_block":{"type":"string","title":"london_block: London switch block (nil = no fork, 0 = already on london)"},"arrow_glacier_block":{"type":"string","title":"arrow_glacier_block: Eip-4345 (bomb delay) switch block (nil = no fork, 0 =\nalready activated)"},"gray_glacier_block":{"type":"string","title":"gray_glacier_block: EIP-5133 (bomb delay) switch block (nil = no fork, 0 =\nalready activated)"},"merge_netsplit_block":{"type":"string","title":"merge_netsplit_block: Virtual fork after The Merge to use as a network\nsplitter"},"shanghai_block":{"type":"string","title":"shanghai_block switch block (nil = no fork, 0 = already on shanghai)"},"cancun_block":{"type":"string","title":"cancun_block switch block (nil = no fork, 0 = already on cancun)"},"chain_id":{"type":"string","format":"uint64","title":"chain_id is the id of the chain (EIP-155)"},"denom":{"type":"string","title":"denom is the denomination used on the EVM"},"decimals":{"type":"string","format":"uint64","title":"decimals is the real decimal precision of the denomination used on the EVM"}},"description":"ChainConfig defines the Ethereum ChainConfig parameters using *sdk.Int values\ninstead of *big.Int."},"allow_unprotected_txs":{"type":"boolean","description":"allow_unprotected_txs defines if replay-protected (i.e non EIP155\nsigned) transactions can be executed on the state machine."},"evm_channels":{"type":"array","items":{"type":"string"},"title":"evm_channels is the list of channel identifiers from EVM compatible chains"},"access_control":{"title":"access_control defines the permission policy of the EVM","type":"object","properties":{"create":{"title":"create defines the permission policy for creating contracts","type":"object","properties":{"access_type":{"title":"access_type defines which type of permission is required for the operation","type":"string","enum":["ACCESS_TYPE_PERMISSIONLESS","ACCESS_TYPE_RESTRICTED","ACCESS_TYPE_PERMISSIONED"],"default":"ACCESS_TYPE_PERMISSIONLESS","description":"- ACCESS_TYPE_PERMISSIONLESS: ACCESS_TYPE_PERMISSIONLESS does not restrict the operation to anyone\n - ACCESS_TYPE_RESTRICTED: ACCESS_TYPE_RESTRICTED restrict the operation to anyone\n - ACCESS_TYPE_PERMISSIONED: ACCESS_TYPE_PERMISSIONED only allows the operation for specific addresses"},"access_control_list":{"type":"array","items":{"type":"string"},"title":"access_control_list defines defines different things depending on the\nAccessType:\n- ACCESS_TYPE_PERMISSIONLESS: list of addresses that are blocked from\nperforming the operation\n- ACCESS_TYPE_RESTRICTED: ignored\n- ACCESS_TYPE_PERMISSIONED: list of addresses that are allowed to perform\nthe operation"}}},"call":{"title":"call defines the permission policy for calling contracts","type":"object","properties":{"access_type":{"title":"access_type defines which type of permission is required for the operation","type":"string","enum":["ACCESS_TYPE_PERMISSIONLESS","ACCESS_TYPE_RESTRICTED","ACCESS_TYPE_PERMISSIONED"],"default":"ACCESS_TYPE_PERMISSIONLESS","description":"- ACCESS_TYPE_PERMISSIONLESS: ACCESS_TYPE_PERMISSIONLESS does not restrict the operation to anyone\n - ACCESS_TYPE_RESTRICTED: ACCESS_TYPE_RESTRICTED restrict the operation to anyone\n - ACCESS_TYPE_PERMISSIONED: ACCESS_TYPE_PERMISSIONED only allows the operation for specific addresses"},"access_control_list":{"type":"array","items":{"type":"string"},"title":"access_control_list defines defines different things depending on the\nAccessType:\n- ACCESS_TYPE_PERMISSIONLESS: list of addresses that are blocked from\nperforming the operation\n- ACCESS_TYPE_RESTRICTED: ignored\n- ACCESS_TYPE_PERMISSIONED: list of addresses that are allowed to perform\nthe operation"}}}}},"active_static_precompiles":{"type":"array","items":{"type":"string"},"title":"active_static_precompiles defines the slice of hex addresses of the\nprecompiled contracts that are active"}},"title":"Params defines the EVM module parameters"}},"description":"QueryParamsResponse defines the response type for querying x/vm parameters."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/account/{address}

> Account queries an Ethereum account.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/account/{address}":{"get":{"summary":"Account queries an Ethereum account.","operationId":"VmAccount","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"balance":{"type":"string","description":"balance is the balance of the EVM denomination."},"code_hash":{"type":"string","description":"code_hash is the hex-formatted code bytes from the EOA."},"nonce":{"type":"string","format":"uint64","description":"nonce is the account's sequence number."}},"description":"QueryAccountResponse is the response type for the Query/Account RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the ethereum hex address to query the account for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/balances/{address}

> Balance queries the balance of a the EVM denomination for a single\
> account.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/balances/{address}":{"get":{"summary":"Balance queries the balance of a the EVM denomination for a single\naccount.","operationId":"VmBalance","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"balance":{"type":"string","description":"balance is the balance of the EVM denomination."}},"description":"QueryBalanceResponse is the response type for the Query/Balance RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the ethereum hex address to query the balance for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/base\_fee

> BaseFee queries the base fee of the parent block of the current block,\
> it's similar to feemarket module's method, but also checks london hardfork\
> status.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/base_fee":{"get":{"summary":"BaseFee queries the base fee of the parent block of the current block,\nit's similar to feemarket module's method, but also checks london hardfork\nstatus.","operationId":"VmBaseFee","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"base_fee":{"type":"string","title":"base_fee is the EIP1559 base fee"}},"description":"QueryBaseFeeResponse returns the EIP1559 base fee."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/codes/{address}

> Code queries the balance of all coins for a single account.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/codes/{address}":{"get":{"summary":"Code queries the balance of all coins for a single account.","operationId":"VmCode","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","format":"byte","description":"code represents the code bytes from an ethereum address."}},"description":"QueryCodeResponse is the response type for the Query/Code RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the ethereum hex address to query the code for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/config

> Config queries the EVM configuration

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/config":{"get":{"summary":"Config queries the EVM configuration","operationId":"VmConfig","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"config":{"title":"config is the evm configuration","type":"object","properties":{"homestead_block":{"type":"string","title":"homestead_block switch (nil no fork, 0 = already homestead)"},"dao_fork_block":{"type":"string","title":"dao_fork_block corresponds to TheDAO hard-fork switch block (nil no fork)"},"dao_fork_support":{"type":"boolean","title":"dao_fork_support defines whether the nodes supports or opposes the DAO\nhard-fork"},"eip150_block":{"type":"string","title":"eip150_block: EIP150 implements the Gas price changes\n(https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork)"},"eip150_hash":{"type":"string","title":"eip150_hash: EIP150 HF hash (needed for header only clients as only gas\npricing changed)"},"eip155_block":{"type":"string","title":"eip155_block: EIP155Block HF block"},"eip158_block":{"type":"string","title":"eip158_block: EIP158 HF block"},"byzantium_block":{"type":"string","title":"byzantium_block: Byzantium switch block (nil no fork, 0 = already on\nbyzantium)"},"constantinople_block":{"type":"string","title":"constantinople_block: Constantinople switch block (nil no fork, 0 = already\nactivated)"},"petersburg_block":{"type":"string","title":"petersburg_block: Petersburg switch block (nil same as Constantinople)"},"istanbul_block":{"type":"string","title":"istanbul_block: Istanbul switch block (nil no fork, 0 = already on\nistanbul)"},"muir_glacier_block":{"type":"string","title":"muir_glacier_block: Eip-2384 (bomb delay) switch block (nil no fork, 0 =\nalready activated)"},"berlin_block":{"type":"string","title":"berlin_block: Berlin switch block (nil = no fork, 0 = already on berlin)"},"london_block":{"type":"string","title":"london_block: London switch block (nil = no fork, 0 = already on london)"},"arrow_glacier_block":{"type":"string","title":"arrow_glacier_block: Eip-4345 (bomb delay) switch block (nil = no fork, 0 =\nalready activated)"},"gray_glacier_block":{"type":"string","title":"gray_glacier_block: EIP-5133 (bomb delay) switch block (nil = no fork, 0 =\nalready activated)"},"merge_netsplit_block":{"type":"string","title":"merge_netsplit_block: Virtual fork after The Merge to use as a network\nsplitter"},"shanghai_block":{"type":"string","title":"shanghai_block switch block (nil = no fork, 0 = already on shanghai)"},"cancun_block":{"type":"string","title":"cancun_block switch block (nil = no fork, 0 = already on cancun)"},"chain_id":{"type":"string","format":"uint64","title":"chain_id is the id of the chain (EIP-155)"},"denom":{"type":"string","title":"denom is the denomination used on the EVM"},"decimals":{"type":"string","format":"uint64","title":"decimals is the real decimal precision of the denomination used on the EVM"}},"description":"ChainConfig defines the Ethereum ChainConfig parameters using *sdk.Int values\ninstead of *big.Int."}},"description":"QueryConfigResponse returns the EVM config."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/cosmos\_account/{address}

> CosmosAccount queries an Ethereum account's Cosmos Address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/cosmos_account/{address}":{"get":{"summary":"CosmosAccount queries an Ethereum account's Cosmos Address.","operationId":"CosmosAccount","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"cosmos_address":{"type":"string","description":"cosmos_address is the cosmos address of the account."},"sequence":{"type":"string","format":"uint64","description":"sequence is the account's sequence number."},"account_number":{"type":"string","format":"uint64","title":"account_number is the account number"}},"description":"QueryCosmosAccountResponse is the response type for the Query/CosmosAccount\nRPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the ethereum hex address to query the account for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/estimate\_gas

> EstimateGas implements the \`eth\_estimateGas\` rpc api

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/estimate_gas":{"get":{"summary":"EstimateGas implements the `eth_estimateGas` rpc api","operationId":"EstimateGas","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"gas":{"type":"string","format":"uint64","title":"gas returns the estimated gas"},"ret":{"type":"string","format":"byte","title":"ret is the returned data from evm function (result or data supplied with\nrevert opcode)"},"vm_error":{"type":"string","title":"vm_error is the error returned by vm execution"}},"title":"EstimateGasResponse defines EstimateGas response"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"args","description":"args uses the same json format as the json rpc api.","in":"query","required":false,"type":"string","format":"byte"},{"name":"gas_cap","description":"gas_cap defines the default gas cap to be used.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"proposer_address","description":"proposer_address of the requested block in hex format.","in":"query","required":false,"type":"string","format":"byte"},{"name":"chain_id","description":"chain_id is the eip155 chain id parsed from the requested block header.","in":"query","required":false,"type":"string","format":"int64"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/eth\_call

> EthCall implements the \`eth\_call\` rpc api

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/eth_call":{"get":{"summary":"EthCall implements the `eth_call` rpc api","operationId":"EthCall","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"hash":{"type":"string","title":"hash of the ethereum transaction in hex format. This hash differs from the\nTendermint sha256 hash of the transaction bytes. See\nhttps://github.com/tendermint/tendermint/issues/6539 for reference"},"logs":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","title":"address of the contract that generated the event"},"topics":{"type":"array","items":{"type":"string"},"description":"topics is a list of topics provided by the contract."},"data":{"type":"string","format":"byte","title":"data which is supplied by the contract, usually ABI-encoded"},"block_number":{"type":"string","format":"uint64","title":"block_number of the block in which the transaction was included"},"tx_hash":{"type":"string","title":"tx_hash is the transaction hash"},"tx_index":{"type":"string","format":"uint64","title":"tx_index of the transaction in the block"},"block_hash":{"type":"string","title":"block_hash of the block in which the transaction was included"},"index":{"type":"string","format":"uint64","title":"index of the log in the block"},"removed":{"type":"boolean","description":"removed is true if this log was reverted due to a chain\nreorganisation. You must pay attention to this field if you receive logs\nthrough a filter query."}},"description":"Log represents an protobuf compatible Ethereum Log that defines a contract\nlog event. These events are generated by the LOG opcode and stored/indexed by\nthe node.\n\nNOTE: address, topics and data are consensus fields. The rest of the fields\nare derived, i.e. filled in by the nodes, but not secured by consensus."},"description":"logs contains the transaction hash and the proto-compatible ethereum\nlogs."},"ret":{"type":"string","format":"byte","title":"ret is the returned data from evm function (result or data supplied with\nrevert opcode)"},"vm_error":{"type":"string","title":"vm_error is the error returned by vm execution"},"gas_used":{"type":"string","format":"uint64","title":"gas_used specifies how much gas was consumed by the transaction"}},"description":"MsgEthereumTxResponse defines the Msg/EthereumTx response type."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"args","description":"args uses the same json format as the json rpc api.","in":"query","required":false,"type":"string","format":"byte"},{"name":"gas_cap","description":"gas_cap defines the default gas cap to be used.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"proposer_address","description":"proposer_address of the requested block in hex format.","in":"query","required":false,"type":"string","format":"byte"},{"name":"chain_id","description":"chain_id is the eip155 chain id parsed from the requested block header.","in":"query","required":false,"type":"string","format":"int64"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/min\_gas\_price

> GlobalMinGasPrice queries the MinGasPrice\
> it's similar to feemarket module's method,\
> but makes the conversion to 18 decimals\
> when the evm denom is represented with a different precision.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/min_gas_price":{"get":{"summary":"GlobalMinGasPrice queries the MinGasPrice\nit's similar to feemarket module's method,\nbut makes the conversion to 18 decimals\nwhen the evm denom is represented with a different precision.","operationId":"GlobalMinGasPrice","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"min_gas_price":{"type":"string","title":"min_gas_price is the feemarket's min_gas_price"}},"title":"QueryGlobalMinGasPriceResponse returns the GlobalMinGasPrice"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/storage/{address}/{key}

> Storage queries the balance of all coins for a single account.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/storage/{address}/{key}":{"get":{"summary":"Storage queries the balance of all coins for a single account.","operationId":"Storage","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"value":{"type":"string","description":"value defines the storage state value hash associated with the given key."}},"description":"QueryStorageResponse is the response type for the Query/Storage RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the ethereum hex address to query the storage state for.","in":"path","required":true,"type":"string"},{"name":"key","description":"key defines the key of the storage state","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/trace\_block

> TraceBlock implements the \`debug\_traceBlockByNumber\` and\
> \`debug\_traceBlockByHash\` rpc api

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/trace_block":{"get":{"summary":"TraceBlock implements the `debug_traceBlockByNumber` and\n`debug_traceBlockByHash` rpc api","operationId":"TraceBlock","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","format":"byte","title":"data is the response serialized in bytes"}},"title":"QueryTraceBlockResponse defines TraceBlock response"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"trace_config.tracer","description":"tracer is a custom javascript tracer.","in":"query","required":false,"type":"string"},{"name":"trace_config.timeout","description":"timeout overrides the default timeout of 5 seconds for JavaScript-based\ntracing calls.","in":"query","required":false,"type":"string"},{"name":"trace_config.reexec","description":"reexec defines the number of blocks the tracer is willing to go back.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"trace_config.disable_stack","description":"disable_stack switches stack capture.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.disable_storage","description":"disable_storage switches storage capture.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.debug","description":"debug can be used to print output during capture end.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.limit","description":"limit defines the maximum length of output, but zero means unlimited.","in":"query","required":false,"type":"integer","format":"int32"},{"name":"trace_config.overrides.homestead_block","description":"homestead_block switch (nil no fork, 0 = already homestead).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.dao_fork_block","description":"dao_fork_block corresponds to TheDAO hard-fork switch block (nil no fork).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.dao_fork_support","description":"dao_fork_support defines whether the nodes supports or opposes the DAO\nhard-fork.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.overrides.eip150_block","description":"eip150_block: EIP150 implements the Gas price changes\n(https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.eip150_hash","description":"eip150_hash: EIP150 HF hash (needed for header only clients as only gas\npricing changed).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.eip155_block","description":"eip155_block: EIP155Block HF block.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.eip158_block","description":"eip158_block: EIP158 HF block.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.byzantium_block","description":"byzantium_block: Byzantium switch block (nil no fork, 0 = already on\nbyzantium).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.constantinople_block","description":"constantinople_block: Constantinople switch block (nil no fork, 0 = already\nactivated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.petersburg_block","description":"petersburg_block: Petersburg switch block (nil same as Constantinople).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.istanbul_block","description":"istanbul_block: Istanbul switch block (nil no fork, 0 = already on\nistanbul).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.muir_glacier_block","description":"muir_glacier_block: Eip-2384 (bomb delay) switch block (nil no fork, 0 =\nalready activated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.berlin_block","description":"berlin_block: Berlin switch block (nil = no fork, 0 = already on berlin).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.london_block","description":"london_block: London switch block (nil = no fork, 0 = already on london).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.arrow_glacier_block","description":"arrow_glacier_block: Eip-4345 (bomb delay) switch block (nil = no fork, 0 =\nalready activated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.gray_glacier_block","description":"gray_glacier_block: EIP-5133 (bomb delay) switch block (nil = no fork, 0 =\nalready activated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.merge_netsplit_block","description":"merge_netsplit_block: Virtual fork after The Merge to use as a network\nsplitter.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.shanghai_block","description":"shanghai_block switch block (nil = no fork, 0 = already on shanghai).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.cancun_block","description":"cancun_block switch block (nil = no fork, 0 = already on cancun).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.chain_id","description":"chain_id is the id of the chain (EIP-155).","in":"query","required":false,"type":"string","format":"uint64"},{"name":"trace_config.overrides.denom","description":"denom is the denomination used on the EVM.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.decimals","description":"decimals is the real decimal precision of the denomination used on the EVM.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"trace_config.enable_memory","description":"enable_memory switches memory capture.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.enable_return_data","description":"enable_return_data switches the capture of return data.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.tracer_json_config","description":"tracer_json_config configures the tracer using a JSON string.","in":"query","required":false,"type":"string"},{"name":"block_number","description":"block_number of the traced block.","in":"query","required":false,"type":"string","format":"int64"},{"name":"block_hash","description":"block_hash (hex) of the traced block.","in":"query","required":false,"type":"string"},{"name":"block_time","description":"block_time of the traced block.","in":"query","required":false,"type":"string","format":"date-time"},{"name":"proposer_address","description":"proposer_address is the address of the requested block.","in":"query","required":false,"type":"string","format":"byte"},{"name":"chain_id","description":"chain_id is the eip155 chain id parsed from the requested block header.","in":"query","required":false,"type":"string","format":"int64"},{"name":"block_max_gas","description":"block_max_gas of the traced block.","in":"query","required":false,"type":"string","format":"int64"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/trace\_tx

> TraceTx implements the \`debug\_traceTransaction\` rpc api

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/trace_tx":{"get":{"summary":"TraceTx implements the `debug_traceTransaction` rpc api","operationId":"TraceTx","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","format":"byte","title":"data is the response serialized in bytes"}},"title":"QueryTraceTxResponse defines TraceTx response"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"msg.data.type_url","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics.","in":"query","required":false,"type":"string"},{"name":"msg.data.value","description":"Must be a valid serialized protocol buffer of the above specified type.","in":"query","required":false,"type":"string","format":"byte"},{"name":"msg.size","description":"size is the encoded storage size of the transaction (DEPRECATED).","in":"query","required":false,"type":"number","format":"double"},{"name":"msg.hash","description":"hash of the transaction in hex format.","in":"query","required":false,"type":"string"},{"name":"msg.from","description":"from is the ethereum signer address in hex format. This address value is\nchecked against the address derived from the signature (V, R, S) using the\nsecp256k1 elliptic curve.","in":"query","required":false,"type":"string"},{"name":"trace_config.tracer","description":"tracer is a custom javascript tracer.","in":"query","required":false,"type":"string"},{"name":"trace_config.timeout","description":"timeout overrides the default timeout of 5 seconds for JavaScript-based\ntracing calls.","in":"query","required":false,"type":"string"},{"name":"trace_config.reexec","description":"reexec defines the number of blocks the tracer is willing to go back.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"trace_config.disable_stack","description":"disable_stack switches stack capture.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.disable_storage","description":"disable_storage switches storage capture.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.debug","description":"debug can be used to print output during capture end.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.limit","description":"limit defines the maximum length of output, but zero means unlimited.","in":"query","required":false,"type":"integer","format":"int32"},{"name":"trace_config.overrides.homestead_block","description":"homestead_block switch (nil no fork, 0 = already homestead).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.dao_fork_block","description":"dao_fork_block corresponds to TheDAO hard-fork switch block (nil no fork).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.dao_fork_support","description":"dao_fork_support defines whether the nodes supports or opposes the DAO\nhard-fork.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.overrides.eip150_block","description":"eip150_block: EIP150 implements the Gas price changes\n(https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.eip150_hash","description":"eip150_hash: EIP150 HF hash (needed for header only clients as only gas\npricing changed).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.eip155_block","description":"eip155_block: EIP155Block HF block.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.eip158_block","description":"eip158_block: EIP158 HF block.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.byzantium_block","description":"byzantium_block: Byzantium switch block (nil no fork, 0 = already on\nbyzantium).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.constantinople_block","description":"constantinople_block: Constantinople switch block (nil no fork, 0 = already\nactivated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.petersburg_block","description":"petersburg_block: Petersburg switch block (nil same as Constantinople).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.istanbul_block","description":"istanbul_block: Istanbul switch block (nil no fork, 0 = already on\nistanbul).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.muir_glacier_block","description":"muir_glacier_block: Eip-2384 (bomb delay) switch block (nil no fork, 0 =\nalready activated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.berlin_block","description":"berlin_block: Berlin switch block (nil = no fork, 0 = already on berlin).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.london_block","description":"london_block: London switch block (nil = no fork, 0 = already on london).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.arrow_glacier_block","description":"arrow_glacier_block: Eip-4345 (bomb delay) switch block (nil = no fork, 0 =\nalready activated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.gray_glacier_block","description":"gray_glacier_block: EIP-5133 (bomb delay) switch block (nil = no fork, 0 =\nalready activated).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.merge_netsplit_block","description":"merge_netsplit_block: Virtual fork after The Merge to use as a network\nsplitter.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.shanghai_block","description":"shanghai_block switch block (nil = no fork, 0 = already on shanghai).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.cancun_block","description":"cancun_block switch block (nil = no fork, 0 = already on cancun).","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.chain_id","description":"chain_id is the id of the chain (EIP-155).","in":"query","required":false,"type":"string","format":"uint64"},{"name":"trace_config.overrides.denom","description":"denom is the denomination used on the EVM.","in":"query","required":false,"type":"string"},{"name":"trace_config.overrides.decimals","description":"decimals is the real decimal precision of the denomination used on the EVM.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"trace_config.enable_memory","description":"enable_memory switches memory capture.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.enable_return_data","description":"enable_return_data switches the capture of return data.","in":"query","required":false,"type":"boolean"},{"name":"trace_config.tracer_json_config","description":"tracer_json_config configures the tracer using a JSON string.","in":"query","required":false,"type":"string"},{"name":"block_number","description":"block_number of requested transaction.","in":"query","required":false,"type":"string","format":"int64"},{"name":"block_hash","description":"block_hash of requested transaction.","in":"query","required":false,"type":"string"},{"name":"block_time","description":"block_time of requested transaction.","in":"query","required":false,"type":"string","format":"date-time"},{"name":"proposer_address","description":"proposer_address is the proposer of the requested block.","in":"query","required":false,"type":"string","format":"byte"},{"name":"chain_id","description":"chain_id is the eip155 chain id parsed from the requested block header.","in":"query","required":false,"type":"string","format":"int64"},{"name":"block_max_gas","description":"block_max_gas of the block of the requested transaction.","in":"query","required":false,"type":"string","format":"int64"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/vm/v1/validator\_account/{cons\_address}

> ValidatorAccount queries an Ethereum account's from a validator consensus\
> Address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/vm/v1/validator_account/{cons_address}":{"get":{"summary":"ValidatorAccount queries an Ethereum account's from a validator consensus\nAddress.","operationId":"ValidatorAccount","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"account_address":{"type":"string","description":"account_address is the cosmos address of the account in bech32 format."},"sequence":{"type":"string","format":"uint64","description":"sequence is the account's sequence number."},"account_number":{"type":"string","format":"uint64","title":"account_number is the account number"}},"description":"QueryValidatorAccountResponse is the response type for the\nQuery/ValidatorAccount RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"cons_address","description":"cons_address is the validator cons address to query the account for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```


# ERC20

## GET /cosmos/evm/erc20/v1/params

> Params retrieves the erc20 module params

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/erc20/v1/params":{"get":{"summary":"Params retrieves the erc20 module params","operationId":"Erc20Params","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"title":"params are the erc20 module parameters","type":"object","properties":{"enable_erc20":{"type":"boolean","description":"enable_erc20 is the parameter to enable the conversion of Cosmos coins <-->\nERC20 tokens."},"native_precompiles":{"type":"array","items":{"type":"string"},"title":"native_precompiles defines the slice of hex addresses of the\nactive precompiles that are used to interact with native staking coins as\nERC20s"},"dynamic_precompiles":{"type":"array","items":{"type":"string"},"title":"dynamic_precompiles defines the slice of hex addresses of the\nactive precompiles that are used to interact with Bank coins as ERC20s"}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/erc20/v1/token\_pairs

> TokenPairs retrieves registered token pairs

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/erc20/v1/token_pairs":{"get":{"summary":"TokenPairs retrieves registered token pairs","operationId":"TokenPairs","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"token_pairs":{"type":"array","items":{"type":"object","properties":{"erc20_address":{"type":"string","title":"erc20_address is the hex address of ERC20 contract token"},"denom":{"type":"string","title":"denom defines the cosmos base denomination to be mapped to"},"enabled":{"type":"boolean","title":"enabled defines the token mapping enable status"},"contract_owner":{"title":"contract_owner is the an ENUM specifying the type of ERC20 owner (0\ninvalid, 1 ModuleAccount, 2 external address)","type":"string","enum":["OWNER_UNSPECIFIED","OWNER_MODULE","OWNER_EXTERNAL"],"default":"OWNER_UNSPECIFIED","description":"Owner enumerates the ownership of a ERC20 contract.\n\n - OWNER_UNSPECIFIED: OWNER_UNSPECIFIED defines an invalid/undefined owner.\n - OWNER_MODULE: OWNER_MODULE - erc20 is owned by the erc20 module account.\n - OWNER_EXTERNAL: OWNER_EXTERNAL - erc20 is owned by an external account."}},"description":"TokenPair defines an instance that records a pairing consisting of a native\nCosmos Coin and an ERC20 token address."},"title":"token_pairs is a slice of registered token pairs for the erc20 module"},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryTokenPairsResponse is the response type for the Query/TokenPairs RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/evm/erc20/v1/token\_pairs/{token}

> TokenPair retrieves a registered token pair

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/erc20/v1/token_pairs/{token}":{"get":{"summary":"TokenPair retrieves a registered token pair","operationId":"TokenPair","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"token_pair":{"type":"object","properties":{"erc20_address":{"type":"string","title":"erc20_address is the hex address of ERC20 contract token"},"denom":{"type":"string","title":"denom defines the cosmos base denomination to be mapped to"},"enabled":{"type":"boolean","title":"enabled defines the token mapping enable status"},"contract_owner":{"title":"contract_owner is the an ENUM specifying the type of ERC20 owner (0\ninvalid, 1 ModuleAccount, 2 external address)","type":"string","enum":["OWNER_UNSPECIFIED","OWNER_MODULE","OWNER_EXTERNAL"],"default":"OWNER_UNSPECIFIED","description":"Owner enumerates the ownership of a ERC20 contract.\n\n - OWNER_UNSPECIFIED: OWNER_UNSPECIFIED defines an invalid/undefined owner.\n - OWNER_MODULE: OWNER_MODULE - erc20 is owned by the erc20 module account.\n - OWNER_EXTERNAL: OWNER_EXTERNAL - erc20 is owned by an external account."}},"description":"TokenPair defines an instance that records a pairing consisting of a native\nCosmos Coin and an ERC20 token address.","title":"token_pairs returns the info about a registered token pair for the erc20\nmodule"}},"description":"QueryTokenPairResponse is the response type for the Query/TokenPair RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"token","description":"token identifier can be either the hex contract address of the ERC20 or the\nCosmos base denomination","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```


# FeeMarket

## GET /cosmos/evm/feemarket/v1/params

> Params queries the parameters of x/feemarket module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/feemarket/v1/params":{"get":{"summary":"Params queries the parameters of x/feemarket module.","operationId":"FeemarketParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params define the evm module parameters.","type":"object","properties":{"no_base_fee":{"type":"boolean","title":"no_base_fee forces the EIP-1559 base fee to 0 (needed for 0 price calls)"},"base_fee_change_denominator":{"type":"integer","format":"int64","description":"base_fee_change_denominator bounds the amount the base fee can change\nbetween blocks."},"elasticity_multiplier":{"type":"integer","format":"int64","description":"elasticity_multiplier bounds the maximum gas limit an EIP-1559 block may\nhave."},"enable_height":{"type":"string","format":"int64","description":"enable_height defines at which block height the base fee calculation is\nenabled."},"base_fee":{"type":"string","description":"base_fee for EIP-1559 blocks."},"min_gas_price":{"type":"string","title":"min_gas_price defines the minimum gas price value for cosmos and eth\ntransactions"},"min_gas_multiplier":{"type":"string","title":"min_gas_multiplier bounds the minimum gas used to be charged\nto senders based on gas limit"}},"title":"Params defines the EVM module parameters"}},"description":"QueryParamsResponse defines the response type for querying x/vm parameters."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/feemarket/v1/base\_fee

> BaseFee queries the base fee of the parent block of the current block.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/feemarket/v1/base_fee":{"get":{"summary":"BaseFee queries the base fee of the parent block of the current block.","operationId":"BaseFee","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"base_fee":{"type":"string","title":"base_fee is the EIP1559 base fee"}},"description":"QueryBaseFeeResponse returns the EIP1559 base fee."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/evm/feemarket/v1/block\_gas

> BlockGas queries the gas used at a given block height

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evm/feemarket/v1/block_gas":{"get":{"summary":"BlockGas queries the gas used at a given block height","operationId":"BlockGas","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"gas":{"type":"string","format":"int64","title":"gas is the returned block gas"}},"description":"QueryBlockGasResponse returns block gas used for a given height."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```


# IBC

## GET /ibc/apps/fee/v1/incentivized\_packets

> IncentivizedPackets returns all incentivized packets and their associated fees

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/incentivized_packets":{"get":{"summary":"IncentivizedPackets returns all incentivized packets and their associated fees","operationId":"IncentivizedPackets","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"incentivized_packets":{"type":"array","items":{"type":"object","properties":{"packet_id":{"title":"unique packet identifier comprised of the channel ID, port ID and sequence","type":"object","properties":{"port_id":{"type":"string","title":"channel port identifier"},"channel_id":{"type":"string","title":"channel unique identifier"},"sequence":{"type":"string","format":"uint64","title":"packet sequence"}}},"packet_fees":{"type":"array","items":{"type":"object","properties":{"fee":{"title":"fee encapsulates the recv, ack and timeout fees associated with an IBC packet","type":"object","properties":{"recv_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet receive fee"},"ack_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet acknowledgement fee"},"timeout_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet timeout fee"}}},"refund_address":{"type":"string","title":"the refund address for unspent fees"},"relayers":{"type":"array","items":{"type":"string"},"title":"optional list of relayers permitted to receive fees"}},"title":"PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers"},"title":"list of packet fees"}},"title":"IdentifiedPacketFees contains a list of type PacketFee and associated PacketId"},"title":"list of identified fees for incentivized packets"},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPackets rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"},{"name":"query_height","description":"block height at which to query.","in":"query","required":false,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{packet\_id.channel\_id}/ports/{packet\_id.port\_id}/sequences/{packet\_id.sequence}/incentivized\_packet

> IncentivizedPacket returns all packet fees for a packet given its identifier

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/incentivized_packet":{"get":{"summary":"IncentivizedPacket returns all packet fees for a packet given its identifier","operationId":"IncentivizedPacket","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"incentivized_packet":{"type":"object","properties":{"packet_id":{"title":"unique packet identifier comprised of the channel ID, port ID and sequence","type":"object","properties":{"port_id":{"type":"string","title":"channel port identifier"},"channel_id":{"type":"string","title":"channel unique identifier"},"sequence":{"type":"string","format":"uint64","title":"packet sequence"}}},"packet_fees":{"type":"array","items":{"type":"object","properties":{"fee":{"title":"fee encapsulates the recv, ack and timeout fees associated with an IBC packet","type":"object","properties":{"recv_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet receive fee"},"ack_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet acknowledgement fee"},"timeout_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet timeout fee"}}},"refund_address":{"type":"string","title":"the refund address for unspent fees"},"relayers":{"type":"array","items":{"type":"string"},"title":"optional list of relayers permitted to receive fees"}},"title":"PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers"},"title":"list of packet fees"}},"title":"IdentifiedPacketFees contains a list of type PacketFee and associated PacketId"}},"title":"QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPacket rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"packet_id.channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.port_id","description":"channel port identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"},{"name":"query_height","description":"block height at which to query.","in":"query","required":false,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{channel\_id}/ports/{port\_id}/incentivized\_packets

> Gets all incentivized packets for a specific channel

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{channel_id}/ports/{port_id}/incentivized_packets":{"get":{"summary":"Gets all incentivized packets for a specific channel","operationId":"IncentivizedPacketsForChannel","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"incentivized_packets":{"type":"array","items":{"type":"object","properties":{"packet_id":{"title":"unique packet identifier comprised of the channel ID, port ID and sequence","type":"object","properties":{"port_id":{"type":"string","title":"channel port identifier"},"channel_id":{"type":"string","title":"channel unique identifier"},"sequence":{"type":"string","format":"uint64","title":"packet sequence"}}},"packet_fees":{"type":"array","items":{"type":"object","properties":{"fee":{"title":"fee encapsulates the recv, ack and timeout fees associated with an IBC packet","type":"object","properties":{"recv_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet receive fee"},"ack_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet acknowledgement fee"},"timeout_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the packet timeout fee"}}},"refund_address":{"type":"string","title":"the refund address for unspent fees"},"relayers":{"type":"array","items":{"type":"string"},"title":"optional list of relayers permitted to receive fees"}},"title":"PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers"},"title":"list of packet fees"}},"title":"IdentifiedPacketFees contains a list of type PacketFee and associated PacketId"},"title":"Map of all incentivized_packets"},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryIncentivizedPacketsResponse defines the response type for the incentivized packets RPC"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","in":"path","required":true,"type":"string"},{"name":"port_id","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"},{"name":"query_height","description":"Height to query at.","in":"query","required":false,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}

> Channel queries an IBC Channel.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}":{"get":{"summary":"Channel queries an IBC Channel.","operationId":"Channel","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"channel":{"title":"channel associated with the request identifiers","type":"object","properties":{"state":{"title":"current state of the channel end","type":"string","enum":["STATE_UNINITIALIZED_UNSPECIFIED","STATE_INIT","STATE_TRYOPEN","STATE_OPEN","STATE_CLOSED","STATE_FLUSHING","STATE_FLUSHCOMPLETE"],"default":"STATE_UNINITIALIZED_UNSPECIFIED","description":"State defines if a channel is in one of the following states:\nCLOSED, INIT, TRYOPEN, OPEN, FLUSHING, FLUSHCOMPLETE or UNINITIALIZED.\n\n - STATE_UNINITIALIZED_UNSPECIFIED: Default State\n - STATE_INIT: A channel has just started the opening handshake.\n - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain.\n - STATE_OPEN: A channel has completed the handshake. Open channels are\nready to send and receive packets.\n - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive\npackets.\n - STATE_FLUSHING: A channel has just accepted the upgrade handshake attempt and is flushing in-flight packets.\n - STATE_FLUSHCOMPLETE: A channel has just completed flushing any in-flight packets."},"ordering":{"title":"whether the channel is ordered or unordered","type":"string","enum":["ORDER_NONE_UNSPECIFIED","ORDER_UNORDERED","ORDER_ORDERED"],"default":"ORDER_NONE_UNSPECIFIED","description":"- ORDER_NONE_UNSPECIFIED: zero-value for channel ordering\n - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in\nwhich they were sent.\n - ORDER_ORDERED: packets are delivered exactly in the order which they were sent"},"counterparty":{"title":"counterparty channel end","type":"object","properties":{"port_id":{"type":"string","description":"port on the counterparty chain which owns the other end of the channel."},"channel_id":{"type":"string","title":"channel end on the counterparty chain"}}},"connection_hops":{"type":"array","items":{"type":"string"},"title":"list of connection identifiers, in order, along which packets sent on\nthis channel will travel"},"version":{"type":"string","title":"opaque channel version, which is agreed upon during the handshake"},"upgrade_sequence":{"type":"string","format":"uint64","title":"upgrade sequence indicates the latest upgrade attempt performed by this channel\nthe value of 0 indicates the channel has never been upgraded"}},"description":"Channel defines pipeline for exactly-once packet delivery between specific\nmodules on separate blockchains, which has at least one end capable of\nsending packets and one end capable of receiving packets."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"description":"QueryChannelResponse is the response type for the Query/Channel RPC method.\nBesides the Channel end, it includes a proof and the height from which the\nproof was retrieved."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/connection/v1/connections/{connection\_id}

> Connection queries an IBC connection end.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/connection/v1/connections/{connection_id}":{"get":{"summary":"Connection queries an IBC connection end.","operationId":"Connection","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"connection":{"title":"connection associated with the request identifier","type":"object","properties":{"client_id":{"type":"string","description":"client associated with this connection."},"versions":{"type":"array","items":{"type":"object","properties":{"identifier":{"type":"string","title":"unique version identifier"},"features":{"type":"array","items":{"type":"string"},"title":"list of features compatible with the specified identifier"}},"description":"Version defines the versioning scheme used to negotiate the IBC verison in\nthe connection handshake."},"description":"IBC version which can be utilised to determine encodings or protocols for\nchannels or packets utilising this connection."},"state":{"description":"current state of the connection end.","type":"string","enum":["STATE_UNINITIALIZED_UNSPECIFIED","STATE_INIT","STATE_TRYOPEN","STATE_OPEN"],"default":"STATE_UNINITIALIZED_UNSPECIFIED"},"counterparty":{"description":"counterparty chain associated with this connection.","type":"object","properties":{"client_id":{"type":"string","description":"identifies the client on the counterparty chain associated with a given\nconnection."},"connection_id":{"type":"string","description":"identifies the connection end on the counterparty chain associated with a\ngiven connection."},"prefix":{"description":"commitment merkle prefix of the counterparty chain.","type":"object","properties":{"key_prefix":{"type":"string","format":"byte"}},"title":"MerklePrefix is merkle path prefixed to the key.\nThe constructed key from the Path and the key will be append(Path.KeyPath,\nappend(Path.KeyPrefix, key...))"}}},"delay_period":{"type":"string","format":"uint64","description":"delay period that must pass before a consensus state can be used for\npacket-verification NOTE: delay period logic is only implemented by some\nclients."}},"description":"ConnectionEnd defines a stateful object on a chain connected to another\nseparate one.\nNOTE: there must only be 2 defined ConnectionEnds to establish\na connection between two chains."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"description":"QueryConnectionResponse is the response type for the Query/Connection RPC\nmethod. Besides the connection end, it includes a proof and the height from\nwhich the proof was retrieved."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"connection_id","description":"connection unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/client\_states/{client\_id}

> ClientState queries an IBC light client.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/client_states/{client_id}":{"get":{"summary":"ClientState queries an IBC light client.","operationId":"ClientState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"client_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"client state associated with the request identifier"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"description":"QueryClientStateResponse is the response type for the Query/ClientState RPC\nmethod. Besides the client state, it includes a proof and the height from\nwhich the proof was retrieved."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"client_id","description":"client state unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels

> Channels queries all the IBC channels of a chain.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels":{"get":{"summary":"Channels queries all the IBC channels of a chain.","operationId":"Channels","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"channels":{"type":"array","items":{"type":"object","properties":{"state":{"title":"current state of the channel end","type":"string","enum":["STATE_UNINITIALIZED_UNSPECIFIED","STATE_INIT","STATE_TRYOPEN","STATE_OPEN","STATE_CLOSED","STATE_FLUSHING","STATE_FLUSHCOMPLETE"],"default":"STATE_UNINITIALIZED_UNSPECIFIED","description":"State defines if a channel is in one of the following states:\nCLOSED, INIT, TRYOPEN, OPEN, FLUSHING, FLUSHCOMPLETE or UNINITIALIZED.\n\n - STATE_UNINITIALIZED_UNSPECIFIED: Default State\n - STATE_INIT: A channel has just started the opening handshake.\n - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain.\n - STATE_OPEN: A channel has completed the handshake. Open channels are\nready to send and receive packets.\n - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive\npackets.\n - STATE_FLUSHING: A channel has just accepted the upgrade handshake attempt and is flushing in-flight packets.\n - STATE_FLUSHCOMPLETE: A channel has just completed flushing any in-flight packets."},"ordering":{"title":"whether the channel is ordered or unordered","type":"string","enum":["ORDER_NONE_UNSPECIFIED","ORDER_UNORDERED","ORDER_ORDERED"],"default":"ORDER_NONE_UNSPECIFIED","description":"- ORDER_NONE_UNSPECIFIED: zero-value for channel ordering\n - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in\nwhich they were sent.\n - ORDER_ORDERED: packets are delivered exactly in the order which they were sent"},"counterparty":{"title":"counterparty channel end","type":"object","properties":{"port_id":{"type":"string","description":"port on the counterparty chain which owns the other end of the channel."},"channel_id":{"type":"string","title":"channel end on the counterparty chain"}}},"connection_hops":{"type":"array","items":{"type":"string"},"title":"list of connection identifiers, in order, along which packets sent on\nthis channel will travel"},"version":{"type":"string","title":"opaque channel version, which is agreed upon during the handshake"},"port_id":{"type":"string","title":"port identifier"},"channel_id":{"type":"string","title":"channel identifier"},"upgrade_sequence":{"type":"string","format":"uint64","title":"upgrade sequence indicates the latest upgrade attempt performed by this channel\nthe value of 0 indicates the channel has never been upgraded"}},"description":"IdentifiedChannel defines a channel with additional port and channel\nidentifier fields."},"description":"list of stored channels of the chain."},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"description":"QueryChannelsResponse is the response type for the Query/Channels RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/connection/v1/connections

> Connections queries all the IBC connections of a chain.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/connection/v1/connections":{"get":{"summary":"Connections queries all the IBC connections of a chain.","operationId":"Connections","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"connections":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"connection identifier."},"client_id":{"type":"string","description":"client associated with this connection."},"versions":{"type":"array","items":{"type":"object","properties":{"identifier":{"type":"string","title":"unique version identifier"},"features":{"type":"array","items":{"type":"string"},"title":"list of features compatible with the specified identifier"}},"description":"Version defines the versioning scheme used to negotiate the IBC verison in\nthe connection handshake."},"title":"IBC version which can be utilised to determine encodings or protocols for\nchannels or packets utilising this connection"},"state":{"description":"current state of the connection end.","type":"string","enum":["STATE_UNINITIALIZED_UNSPECIFIED","STATE_INIT","STATE_TRYOPEN","STATE_OPEN"],"default":"STATE_UNINITIALIZED_UNSPECIFIED"},"counterparty":{"description":"counterparty chain associated with this connection.","type":"object","properties":{"client_id":{"type":"string","description":"identifies the client on the counterparty chain associated with a given\nconnection."},"connection_id":{"type":"string","description":"identifies the connection end on the counterparty chain associated with a\ngiven connection."},"prefix":{"description":"commitment merkle prefix of the counterparty chain.","type":"object","properties":{"key_prefix":{"type":"string","format":"byte"}},"title":"MerklePrefix is merkle path prefixed to the key.\nThe constructed key from the Path and the key will be append(Path.KeyPath,\nappend(Path.KeyPrefix, key...))"}}},"delay_period":{"type":"string","format":"uint64","description":"delay period associated with this connection."}},"description":"IdentifiedConnection defines a connection with additional connection\nidentifier field."},"description":"list of stored connections of the chain."},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"description":"QueryConnectionsResponse is the response type for the Query/Connections RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/client\_status/{client\_id}

> Status queries the status of an IBC client.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/client_status/{client_id}":{"get":{"summary":"Status queries the status of an IBC client.","operationId":"ClientStatus","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string"}},"description":"QueryClientStatusResponse is the response type for the Query/ClientStatus RPC\nmethod. It returns the current status of the IBC client."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"client_id","description":"client unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/client\_states

> ClientStates queries all the IBC light clients of a chain.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/client_states":{"get":{"summary":"ClientStates queries all the IBC light clients of a chain.","operationId":"ClientStates","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"client_states":{"type":"array","items":{"type":"object","properties":{"client_id":{"type":"string","title":"client identifier"},"client_state":{"title":"client state","type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}},"description":"IdentifiedClientState defines a client state with an additional client\nidentifier field."},"description":"list of stored ClientStates of the chain."},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"}},"description":"QueryClientStatesResponse is the response type for the Query/ClientStates RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## POST /ibc/core/client/v1/verify\_membership

> VerifyMembership queries an IBC light client for proof verification of a value at a given key path.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/verify_membership":{"post":{"summary":"VerifyMembership queries an IBC light client for proof verification of a value at a given key path.","operationId":"VerifyMembership","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"boolean indicating success or failure of proof verification."}},"title":"QueryVerifyMembershipResponse is the response type for the Query/VerifyMembership RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"client_id":{"type":"string","description":"client unique identifier."},"proof":{"type":"string","format":"byte","description":"the proof to be verified by the client."},"proof_height":{"type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset","title":"Height is a monotonically increasing data type\nthat can be compared against another Height for the purposes of updating and\nfreezing clients"},"merkle_path":{"description":"the commitment key path.","type":"object","properties":{"key_path":{"type":"array","items":{"type":"string"}}},"title":"MerklePath is the path used to verify commitment proofs, which can be an\narbitrary structured object (defined by a commitment type).\nMerklePath is represented from root-to-leaf"},"value":{"type":"string","format":"byte","description":"the value which is proven."},"time_delay":{"type":"string","format":"uint64","title":"optional time delay"},"block_delay":{"type":"string","format":"uint64","title":"optional block delay"}},"title":"QueryVerifyMembershipRequest is the request type for the Query/VerifyMembership RPC method"}}},"required":true}}}}}
```

## GET /ibc/apps/transfer/v1/channels/{channel\_id}/ports/{port\_id}/escrow\_address

> EscrowAddress returns the escrow address for a particular port and channel id.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/transfer/v1/channels/{channel_id}/ports/{port_id}/escrow_address":{"get":{"summary":"EscrowAddress returns the escrow address for a particular port and channel id.","operationId":"EscrowAddress","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"escrow_address":{"type":"string","title":"the escrow account address"}},"description":"QueryEscrowAddressResponse is the response type of the EscrowAddress RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"channel_id","description":"unique channel identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"unique port identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/transfer/v1/denom\_hashes/{trace}

> DenomHash queries a denomination hash information.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/transfer/v1/denom_hashes/{trace}":{"get":{"summary":"DenomHash queries a denomination hash information.","operationId":"DenomHash","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"hash":{"type":"string","description":"hash (in hex format) of the denomination trace information."}},"description":"QueryDenomHashResponse is the response type for the Query/DenomHash RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"trace","description":"The denomination trace ([port_id]/[channel_id])+/[denom]","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/transfer/v1/denom\_traces

> DenomTraces queries all denomination traces.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/transfer/v1/denom_traces":{"get":{"summary":"DenomTraces queries all denomination traces.","operationId":"DenomTraces","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"denom_traces":{"type":"array","items":{"type":"object","properties":{"path":{"type":"string","description":"path defines the chain of port/channel identifiers used for tracing the\nsource of the fungible token."},"base_denom":{"type":"string","description":"base denomination of the relayed fungible token."}},"description":"DenomTrace contains the base denomination for ICS20 fungible tokens and the\nsource tracing information path."},"description":"denom_traces returns all denominations trace information."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryConnectionsResponse is the response type for the Query/DenomTraces RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/transfer/v1/denom\_traces/{hash}

> DenomTrace queries a denomination trace information.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/transfer/v1/denom_traces/{hash}":{"get":{"summary":"DenomTrace queries a denomination trace information.","operationId":"DenomTrace","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"denom_trace":{"type":"object","properties":{"path":{"type":"string","description":"path defines the chain of port/channel identifiers used for tracing the\nsource of the fungible token."},"base_denom":{"type":"string","description":"base denomination of the relayed fungible token."}},"description":"DenomTrace contains the base denomination for ICS20 fungible tokens and the\nsource tracing information path."}},"description":"QueryDenomTraceResponse is the response type for the Query/DenomTrace RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"hash","description":"hash (in hex format) or denom (full denom with ibc prefix) of the denomination trace information.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/transfer/v1/params

> Params queries all parameters of the ibc-transfer module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/transfer/v1/params":{"get":{"summary":"Params queries all parameters of the ibc-transfer module.","operationId":"TransferParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"send_enabled":{"type":"boolean","description":"send_enabled enables or disables all cross-chain token transfers from this\nchain."},"receive_enabled":{"type":"boolean","description":"receive_enabled enables or disables all cross-chain token transfers to this\nchain."}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{channel\_id}/ports/{port\_id}/fee\_enabled

> FeeEnabledChannel returns true if the provided port and channel identifiers belong to a fee enabled channel

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{channel_id}/ports/{port_id}/fee_enabled":{"get":{"summary":"FeeEnabledChannel returns true if the provided port and channel identifiers belong to a fee enabled channel","operationId":"FeeEnabledChannel","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"fee_enabled":{"type":"boolean","title":"boolean flag representing the fee enabled channel status"}},"title":"QueryFeeEnabledChannelResponse defines the response type for the FeeEnabledChannel rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"unique channel identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"unique port identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/transfer/v1/denoms/{denom}/total\_escrow

> TotalEscrowForDenom returns the total amount of tokens in escrow based on the denom.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/transfer/v1/denoms/{denom}/total_escrow":{"get":{"summary":"TotalEscrowForDenom returns the total amount of tokens in escrow based on the denom.","operationId":"TotalEscrowForDenom","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"amount":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"QueryTotalEscrowForDenomResponse is the response type for TotalEscrowForDenom RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{channel\_id}/relayers/{relayer}/counterparty\_payee

> CounterpartyPayee returns the registered counterparty payee for forward relaying

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{channel_id}/relayers/{relayer}/counterparty_payee":{"get":{"summary":"CounterpartyPayee returns the registered counterparty payee for forward relaying","operationId":"CounterpartyPayee","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"counterparty_payee":{"type":"string","title":"the counterparty payee address used to compensate forward relaying"}},"title":"QueryCounterpartyPayeeResponse defines the response type for the CounterpartyPayee rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"unique channel identifier","in":"path","required":true,"type":"string"},{"name":"relayer","description":"the relayer address to which the counterparty is registered","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{channel\_id}/relayers/{relayer}/payee

> Payee returns the registered payee address for a specific channel given the relayer address

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{channel_id}/relayers/{relayer}/payee":{"get":{"summary":"Payee returns the registered payee address for a specific channel given the relayer address","operationId":"Payee","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"payee_address":{"type":"string","title":"the payee address to which packet fees are paid out"}},"title":"QueryPayeeResponse defines the response type for the Payee rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"unique channel identifier","in":"path","required":true,"type":"string"},{"name":"relayer","description":"the relayer address to which the distribution address is registered","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{packet\_id.channel\_id}/ports/{packet\_id.port\_id}/sequences/{packet\_id.sequence}/total\_ack\_fees

> TotalAckFees returns the total acknowledgement fees for a packet given its identifier

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_ack_fees":{"get":{"summary":"TotalAckFees returns the total acknowledgement fees for a packet given its identifier","operationId":"TotalAckFees","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"ack_fees":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the total packet acknowledgement fees"}},"title":"QueryTotalAckFeesResponse defines the response type for the TotalAckFees rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"packet_id.channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.port_id","description":"channel port identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{packet\_id.channel\_id}/ports/{packet\_id.port\_id}/sequences/{packet\_id.sequence}/total\_recv\_fees

> TotalRecvFees returns the total receive fees for a packet given its identifier

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_recv_fees":{"get":{"summary":"TotalRecvFees returns the total receive fees for a packet given its identifier","operationId":"TotalRecvFees","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"recv_fees":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the total packet receive fees"}},"title":"QueryTotalRecvFeesResponse defines the response type for the TotalRecvFees rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"packet_id.channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.port_id","description":"channel port identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/channels/{packet\_id.channel\_id}/ports/{packet\_id.port\_id}/sequences/{packet\_id.sequence}/total\_timeout\_fees

> TotalTimeoutFees returns the total timeout fees for a packet given its identifier

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_timeout_fees":{"get":{"summary":"TotalTimeoutFees returns the total timeout fees for a packet given its identifier","operationId":"TotalTimeoutFees","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"timeout_fees":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"the total packet timeout fees"}},"title":"QueryTotalTimeoutFeesResponse defines the response type for the TotalTimeoutFees rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"packet_id.channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.port_id","description":"channel port identifier","in":"path","required":true,"type":"string"},{"name":"packet_id.sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/fee/v1/fee\_enabled

> FeeEnabledChannels returns a list of all fee enabled channels

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/fee/v1/fee_enabled":{"get":{"summary":"FeeEnabledChannels returns a list of all fee enabled channels","operationId":"FeeEnabledChannels","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"fee_enabled_channels":{"type":"array","items":{"type":"object","properties":{"port_id":{"type":"string","title":"unique port identifier"},"channel_id":{"type":"string","title":"unique channel identifier"}},"title":"FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel"},"title":"list of fee enabled channels"},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryFeeEnabledChannelsResponse defines the response type for the FeeEnabledChannels rpc"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"},{"name":"query_height","description":"block height at which to query.","in":"query","required":false,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/interchain\_accounts/controller/v1/owners/{owner}/connections/{connection\_id}

> InterchainAccount returns the interchain account address for a given owner address on a given connection

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/interchain_accounts/controller/v1/owners/{owner}/connections/{connection_id}":{"get":{"summary":"InterchainAccount returns the interchain account address for a given owner address on a given connection","operationId":"InterchainAccount","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"address":{"type":"string"}},"description":"QueryInterchainAccountResponse the response type for the Query/InterchainAccount RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"owner","in":"path","required":true,"type":"string"},{"name":"connection_id","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/apps/interchain\_accounts/controller/v1/params

> Params queries all parameters of the ICA controller submodule.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/interchain_accounts/controller/v1/params":{"get":{"summary":"Params queries all parameters of the ICA controller submodule.","operationId":"InterchainAccountsControllerParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"controller_enabled":{"type":"boolean","description":"controller_enabled enables or disables the controller submodule."}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/apps/interchain\_accounts/host/v1/params

> Params queries all parameters of the ICA host submodule.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/apps/interchain_accounts/host/v1/params":{"get":{"summary":"Params queries all parameters of the ICA host submodule.","operationId":"InterchainAccountsHostParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"host_enabled":{"type":"boolean","description":"host_enabled enables or disables the host submodule."},"allow_messages":{"type":"array","items":{"type":"string"},"description":"allow_messages defines a list of sdk message typeURLs allowed to be executed on a host chain."}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/consensus\_state/revision/{revision\_number}/height/{revision\_height}

> ChannelConsensusState queries for the consensus state for the channel\
> associated with the provided channel identifiers.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/consensus_state/revision/{revision_number}/height/{revision_height}":{"get":{"summary":"ChannelConsensusState queries for the consensus state for the channel\nassociated with the provided channel identifiers.","operationId":"ChannelConsensusState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"consensus_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"consensus state associated with the channel"},"client_id":{"type":"string","title":"client ID associated with the consensus state"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryChannelClientStateResponse is the Response type for the\nQuery/QueryChannelClientState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"revision_number","description":"revision number of the consensus state","in":"path","required":true,"type":"string","format":"uint64"},{"name":"revision_height","description":"revision height of the consensus state","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/next\_sequence

> NextSequenceReceive returns the next receive sequence for a given channel.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/next_sequence":{"get":{"summary":"NextSequenceReceive returns the next receive sequence for a given channel.","operationId":"NextSequenceReceive","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"next_sequence_receive":{"type":"string","format":"uint64","title":"next sequence receive number"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QuerySequenceResponse is the response type for the\nQuery/QueryNextSequenceReceiveResponse RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/client\_state

> ChannelClientState queries for the client state for the channel associated\
> with the provided channel identifiers.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/client_state":{"get":{"summary":"ChannelClientState queries for the client state for the channel associated\nwith the provided channel identifiers.","operationId":"ChannelClientState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"identified_client_state":{"title":"client state associated with the channel","type":"object","properties":{"client_id":{"type":"string","title":"client identifier"},"client_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"client state"}},"description":"IdentifiedClientState defines a client state with an additional client\nidentifier field."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryChannelClientStateResponse is the Response type for the\nQuery/QueryChannelClientState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/next\_sequence\_send

> NextSequenceSend returns the next send sequence for a given channel.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/next_sequence_send":{"get":{"summary":"NextSequenceSend returns the next send sequence for a given channel.","operationId":"NextSequenceSend","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"next_sequence_send":{"type":"string","format":"uint64","title":"next sequence send number"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryNextSequenceSendResponse is the request type for the\nQuery/QueryNextSequenceSend RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_acknowledgements

> PacketAcknowledgements returns all the packet acknowledgements associated\
> with a channel.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements":{"get":{"summary":"PacketAcknowledgements returns all the packet acknowledgements associated\nwith a channel.","operationId":"PacketAcknowledgements","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"acknowledgements":{"type":"array","items":{"type":"object","properties":{"port_id":{"type":"string","description":"channel port identifier."},"channel_id":{"type":"string","description":"channel unique identifier."},"sequence":{"type":"string","format":"uint64","description":"packet sequence."},"data":{"type":"string","format":"byte","description":"embedded data that represents packet state."}},"description":"PacketState defines the generic type necessary to retrieve and store\npacket commitments, acknowledgements, and receipts.\nCaller is responsible for knowing the context necessary to interpret this\nstate as a commitment, acknowledgement, or a receipt."}},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryPacketAcknowledgemetsResponse is the request type for the\nQuery/QueryPacketAcknowledgements RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"},{"name":"packet_commitment_sequences","description":"list of packet sequences.","in":"query","required":false,"type":"array","items":{"type":"string","format":"uint64"},"collectionFormat":"multi"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_acks/{sequence}

> PacketAcknowledgement queries a stored packet acknowledgement hash.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}":{"get":{"summary":"PacketAcknowledgement queries a stored packet acknowledgement hash.","operationId":"PacketAcknowledgement","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"acknowledgement":{"type":"string","format":"byte","title":"packet associated with the request fields"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryPacketAcknowledgementResponse defines the client query response for a\npacket which also includes a proof and the height from which the\nproof was retrieved"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_commitments

> PacketCommitments returns all the packet commitments hashes associated\
> with a channel.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments":{"get":{"summary":"PacketCommitments returns all the packet commitments hashes associated\nwith a channel.","operationId":"PacketCommitments","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"commitments":{"type":"array","items":{"type":"object","properties":{"port_id":{"type":"string","description":"channel port identifier."},"channel_id":{"type":"string","description":"channel unique identifier."},"sequence":{"type":"string","format":"uint64","description":"packet sequence."},"data":{"type":"string","format":"byte","description":"embedded data that represents packet state."}},"description":"PacketState defines the generic type necessary to retrieve and store\npacket commitments, acknowledgements, and receipts.\nCaller is responsible for knowing the context necessary to interpret this\nstate as a commitment, acknowledgement, or a receipt."}},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryPacketCommitmentsResponse is the request type for the\nQuery/QueryPacketCommitments RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_commitments/{packet\_ack\_sequences}/unreceived\_acks

> UnreceivedAcks returns all the unreceived IBC acknowledgements associated\
> with a channel and sequences.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_ack_sequences}/unreceived_acks":{"get":{"summary":"UnreceivedAcks returns all the unreceived IBC acknowledgements associated\nwith a channel and sequences.","operationId":"UnreceivedAcks","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"sequences":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unreceived acknowledgement sequences"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryUnreceivedAcksResponse is the response type for the\nQuery/UnreceivedAcks RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"packet_ack_sequences","description":"list of acknowledgement sequences","in":"path","required":true,"type":"array","items":{"type":"string","format":"uint64"},"collectionFormat":"csv","minItems":1}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_commitments/{packet\_commitment\_sequences}/unreceived\_packets

> UnreceivedPackets returns all the unreceived IBC packets associated with a\
> channel and sequences.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_commitment_sequences}/unreceived_packets":{"get":{"summary":"UnreceivedPackets returns all the unreceived IBC packets associated with a\nchannel and sequences.","operationId":"UnreceivedPackets","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"sequences":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unreceived packet sequences"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryUnreceivedPacketsResponse is the response type for the\nQuery/UnreceivedPacketCommitments RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"packet_commitment_sequences","description":"list of packet sequences","in":"path","required":true,"type":"array","items":{"type":"string","format":"uint64"},"collectionFormat":"csv","minItems":1}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_commitments/{sequence}

> PacketCommitment queries a stored packet commitment hash.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}":{"get":{"summary":"PacketCommitment queries a stored packet commitment hash.","operationId":"PacketCommitment","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"commitment":{"type":"string","format":"byte","title":"packet associated with the request fields"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryPacketCommitmentResponse defines the client query response for a packet\nwhich also includes a proof and the height from which the proof was\nretrieved"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/packet\_receipts/{sequence}

> PacketReceipt queries if a given packet sequence has been received on the\
> queried chain

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}":{"get":{"summary":"PacketReceipt queries if a given packet sequence has been received on the\nqueried chain","operationId":"PacketReceipt","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"received":{"type":"boolean","title":"success flag for if receipt exists"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryPacketReceiptResponse defines the client query response for a packet\nreceipt which also includes a proof, and the height from which the proof was\nretrieved"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","description":"channel unique identifier","in":"path","required":true,"type":"string"},{"name":"port_id","description":"port unique identifier","in":"path","required":true,"type":"string"},{"name":"sequence","description":"packet sequence","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/upgrade

> Upgrade returns the upgrade for a given port and channel id.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/upgrade":{"get":{"summary":"Upgrade returns the upgrade for a given port and channel id.","operationId":"Upgrade","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"upgrade":{"type":"object","properties":{"fields":{"type":"object","properties":{"ordering":{"type":"string","enum":["ORDER_NONE_UNSPECIFIED","ORDER_UNORDERED","ORDER_ORDERED"],"default":"ORDER_NONE_UNSPECIFIED","description":"- ORDER_NONE_UNSPECIFIED: zero-value for channel ordering\n - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in\nwhich they were sent.\n - ORDER_ORDERED: packets are delivered exactly in the order which they were sent","title":"Order defines if a channel is ORDERED or UNORDERED"},"connection_hops":{"type":"array","items":{"type":"string"}},"version":{"type":"string"}},"description":"UpgradeFields are the fields in a channel end which may be changed\nduring a channel upgrade."},"timeout":{"type":"object","properties":{"height":{"title":"block height after which the packet or upgrade times out","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"},"timestamp":{"type":"string","format":"uint64","title":"block timestamp (in nanoseconds) after which the packet or upgrade times out"}},"description":"Timeout defines an execution deadline structure for 04-channel handlers.\nThis includes packet lifecycle handlers as well as the upgrade handshake handlers.\nA valid Timeout contains either one or both of a timestamp and block height (sequence)."},"next_sequence_send":{"type":"string","format":"uint64"}},"description":"Upgrade is a verifiable type which contains the relevant information\nfor an attempted upgrade. It provides the proposed changes to the channel\nend, the timeout for this upgrade attempt and the next packet sequence\nwhich allows the counterparty to efficiently know the highest sequence it has received.\nThe next sequence send is used for pruning and upgrading from unordered to ordered channels."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryUpgradeResponse is the response type for the QueryUpgradeResponse RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","in":"path","required":true,"type":"string"},{"name":"port_id","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/channels/{channel\_id}/ports/{port\_id}/upgrade\_error

> UpgradeError returns the error receipt if the upgrade handshake failed.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/upgrade_error":{"get":{"summary":"UpgradeError returns the error receipt if the upgrade handshake failed.","operationId":"UpgradeError","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"error_receipt":{"type":"object","properties":{"sequence":{"type":"string","format":"uint64","title":"the channel upgrade sequence"},"message":{"type":"string","title":"the error message detailing the cause of failure"}},"description":"ErrorReceipt defines a type which encapsulates the upgrade sequence and error associated with the\nupgrade handshake failure. When a channel upgrade handshake is aborted both chains are expected to increment to the\nnext sequence."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryUpgradeErrorResponse is the response type for the Query/QueryUpgradeError RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"channel_id","in":"path","required":true,"type":"string"},{"name":"port_id","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/connections/{connection}/channels

> ConnectionChannels queries all the channels associated with a connection\
> end.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/connections/{connection}/channels":{"get":{"summary":"ConnectionChannels queries all the channels associated with a connection\nend.","operationId":"ConnectionChannels","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"channels":{"type":"array","items":{"type":"object","properties":{"state":{"title":"current state of the channel end","type":"string","enum":["STATE_UNINITIALIZED_UNSPECIFIED","STATE_INIT","STATE_TRYOPEN","STATE_OPEN","STATE_CLOSED","STATE_FLUSHING","STATE_FLUSHCOMPLETE"],"default":"STATE_UNINITIALIZED_UNSPECIFIED","description":"State defines if a channel is in one of the following states:\nCLOSED, INIT, TRYOPEN, OPEN, FLUSHING, FLUSHCOMPLETE or UNINITIALIZED.\n\n - STATE_UNINITIALIZED_UNSPECIFIED: Default State\n - STATE_INIT: A channel has just started the opening handshake.\n - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain.\n - STATE_OPEN: A channel has completed the handshake. Open channels are\nready to send and receive packets.\n - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive\npackets.\n - STATE_FLUSHING: A channel has just accepted the upgrade handshake attempt and is flushing in-flight packets.\n - STATE_FLUSHCOMPLETE: A channel has just completed flushing any in-flight packets."},"ordering":{"title":"whether the channel is ordered or unordered","type":"string","enum":["ORDER_NONE_UNSPECIFIED","ORDER_UNORDERED","ORDER_ORDERED"],"default":"ORDER_NONE_UNSPECIFIED","description":"- ORDER_NONE_UNSPECIFIED: zero-value for channel ordering\n - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in\nwhich they were sent.\n - ORDER_ORDERED: packets are delivered exactly in the order which they were sent"},"counterparty":{"title":"counterparty channel end","type":"object","properties":{"port_id":{"type":"string","description":"port on the counterparty chain which owns the other end of the channel."},"channel_id":{"type":"string","title":"channel end on the counterparty chain"}}},"connection_hops":{"type":"array","items":{"type":"string"},"title":"list of connection identifiers, in order, along which packets sent on\nthis channel will travel"},"version":{"type":"string","title":"opaque channel version, which is agreed upon during the handshake"},"port_id":{"type":"string","title":"port identifier"},"channel_id":{"type":"string","title":"channel identifier"},"upgrade_sequence":{"type":"string","format":"uint64","title":"upgrade sequence indicates the latest upgrade attempt performed by this channel\nthe value of 0 indicates the channel has never been upgraded"}},"description":"IdentifiedChannel defines a channel with additional port and channel\nidentifier fields."},"description":"list of channels associated with a connection."},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"},"height":{"title":"query block height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryConnectionChannelsResponse is the Response type for the\nQuery/QueryConnectionChannels RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"connection","description":"connection unique identifier","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/channel/v1/params

> ChannelParams queries all parameters of the ibc channel submodule.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/channel/v1/params":{"get":{"summary":"ChannelParams queries all parameters of the ibc channel submodule.","operationId":"ChannelParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"upgrade_timeout":{"type":"object","properties":{"height":{"title":"block height after which the packet or upgrade times out","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"},"timestamp":{"type":"string","format":"uint64","title":"block timestamp (in nanoseconds) after which the packet or upgrade times out"}},"description":"Timeout defines an execution deadline structure for 04-channel handlers.\nThis includes packet lifecycle handlers as well as the upgrade handshake handlers.\nA valid Timeout contains either one or both of a timestamp and block height (sequence)."}}}},"description":"QueryChannelParamsResponse is the response type for the Query/ChannelParams RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/core/connection/v1/client\_connections/{client\_id}

> ClientConnections queries the connection paths associated with a client\
> state.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/connection/v1/client_connections/{client_id}":{"get":{"summary":"ClientConnections queries the connection paths associated with a client\nstate.","operationId":"ClientConnections","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"connection_paths":{"type":"array","items":{"type":"string"},"description":"slice of all the connection paths associated with a client."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was generated","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryClientConnectionsResponse is the response type for the\nQuery/ClientConnections RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"client_id","description":"client identifier associated with a connection","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/connection/v1/connections/{connection\_id}/client\_state

> ConnectionClientState queries the client state associated with the\
> connection.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/connection/v1/connections/{connection_id}/client_state":{"get":{"summary":"ConnectionClientState queries the client state associated with the\nconnection.","operationId":"ConnectionClientState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"identified_client_state":{"title":"client state associated with the channel","type":"object","properties":{"client_id":{"type":"string","title":"client identifier"},"client_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"client state"}},"description":"IdentifiedClientState defines a client state with an additional client\nidentifier field."},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryConnectionClientStateResponse is the response type for the\nQuery/ConnectionClientState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"connection_id","description":"connection identifier","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /ibc/core/connection/v1/connections/{connection\_id}/consensus\_state/revision/{revision\_number}/height/{revision\_height}

> ConnectionConsensusState queries the consensus state associated with the\
> connection.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/connection/v1/connections/{connection_id}/consensus_state/revision/{revision_number}/height/{revision_height}":{"get":{"summary":"ConnectionConsensusState queries the consensus state associated with the\nconnection.","operationId":"ConnectionConsensusState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"consensus_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"consensus state associated with the channel"},"client_id":{"type":"string","title":"client ID associated with the consensus state"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"title":"height at which the proof was retrieved","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"}},"title":"QueryConnectionConsensusStateResponse is the response type for the\nQuery/ConnectionConsensusState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"connection_id","description":"connection identifier","in":"path","required":true,"type":"string"},{"name":"revision_number","in":"path","required":true,"type":"string","format":"uint64"},{"name":"revision_height","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /ibc/core/connection/v1/params

> ConnectionParams queries all parameters of the ibc connection submodule.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/connection/v1/params":{"get":{"summary":"ConnectionParams queries all parameters of the ibc connection submodule.","operationId":"ConnectionParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"max_expected_time_per_block":{"type":"string","format":"uint64","description":"maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the\nlargest amount of time that the chain might reasonably take to produce the next block under normal operating\nconditions. A safe choice is 3-5x the expected time per block."}}}},"description":"QueryConnectionParamsResponse is the response type for the Query/ConnectionParams RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/consensus\_states/{client\_id}

> ConsensusStates queries all the consensus state associated with a given\
> client.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/consensus_states/{client_id}":{"get":{"summary":"ConsensusStates queries all the consensus state associated with a given\nclient.","operationId":"ConsensusStates","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"consensus_states":{"type":"array","items":{"type":"object","properties":{"height":{"title":"consensus state height","type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset"},"consensus_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"consensus state"}},"description":"ConsensusStateWithHeight defines a consensus state with an additional height\nfield."},"title":"consensus states associated with the identifier"},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"}},"title":"QueryConsensusStatesResponse is the response type for the\nQuery/ConsensusStates RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"client_id","description":"client identifier","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/consensus\_states/{client\_id}/heights

> ConsensusStateHeights queries the height of every consensus states associated with a given client.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/consensus_states/{client_id}/heights":{"get":{"summary":"ConsensusStateHeights queries the height of every consensus states associated with a given client.","operationId":"ConsensusStateHeights","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"consensus_state_heights":{"type":"array","items":{"type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset","title":"Height is a monotonically increasing data type\nthat can be compared against another Height for the purposes of updating and\nfreezing clients"},"title":"consensus state heights"},"pagination":{"title":"pagination response","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"}},"title":"QueryConsensusStateHeightsResponse is the response type for the\nQuery/ConsensusStateHeights RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"client_id","description":"client identifier","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/consensus\_states/{client\_id}/revision/{revision\_number}/height/{revision\_height}

> ConsensusState queries a consensus state associated with a client state at\
> a given height.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/consensus_states/{client_id}/revision/{revision_number}/height/{revision_height}":{"get":{"summary":"ConsensusState queries a consensus state associated with a client state at\na given height.","operationId":"ConsensusState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"consensus_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"consensus state associated with the client identifier at the given height"},"proof":{"type":"string","format":"byte","title":"merkle proof of existence"},"proof_height":{"type":"object","properties":{"revision_number":{"type":"string","format":"uint64","title":"the revision that the client is currently on"},"revision_height":{"type":"string","format":"uint64","title":"the height within the given revision"}},"description":"Normally the RevisionHeight is incremented at each height while keeping\nRevisionNumber the same. However some consensus algorithms may choose to\nreset the height in certain conditions e.g. hard forks, state-machine\nbreaking changes In these cases, the RevisionNumber is incremented so that\nheight continues to be monitonically increasing even as the RevisionHeight\ngets reset","title":"Height is a monotonically increasing data type\nthat can be compared against another Height for the purposes of updating and\nfreezing clients"}},"title":"QueryConsensusStateResponse is the response type for the Query/ConsensusState\nRPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"client_id","description":"client identifier","in":"path","required":true,"type":"string"},{"name":"revision_number","description":"consensus state revision number","in":"path","required":true,"type":"string","format":"uint64"},{"name":"revision_height","description":"consensus state revision height","in":"path","required":true,"type":"string","format":"uint64"},{"name":"latest_height","description":"latest_height overrrides the height field and queries the latest stored\nConsensusState.","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/params

> ClientParams queries all parameters of the ibc client submodule.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/params":{"get":{"summary":"ClientParams queries all parameters of the ibc client submodule.","operationId":"ClientParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"allowed_clients":{"type":"array","items":{"type":"string"},"description":"allowed_clients defines the list of allowed client state types which can be created\nand interacted with. If a client type is removed from the allowed clients list, usage\nof this client will be disabled until it is added again to the list."}}}},"description":"QueryClientParamsResponse is the response type for the Query/ClientParams RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/upgraded\_client\_states

> UpgradedClientState queries an Upgraded IBC light client.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/upgraded_client_states":{"get":{"summary":"UpgradedClientState queries an Upgraded IBC light client.","operationId":"UpgradedClientState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"upgraded_client_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"client state associated with the request identifier"}},"description":"QueryUpgradedClientStateResponse is the response type for the\nQuery/UpgradedClientState RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /ibc/core/client/v1/upgraded\_consensus\_states

> UpgradedConsensusState queries an Upgraded IBC consensus state.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/ibc/core/client/v1/upgraded_consensus_states":{"get":{"summary":"UpgradedConsensusState queries an Upgraded IBC consensus state.","operationId":"ClientUpgradedConsensusState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"upgraded_consensus_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }","title":"Consensus state associated with the request identifier"}},"description":"QueryUpgradedConsensusStateResponse is the response type for the\nQuery/UpgradedConsensusState RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```


# Kiichain


# TokenFactory

## GET /kiichain/tokenfactory/v1beta1/params

> Params defines a gRPC query method that returns the tokenfactory module's\
> parameters.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/kiichain/tokenfactory/v1beta1/params":{"get":{"summary":"Params defines a gRPC query method that returns the tokenfactory module's\nparameters.","operationId":"TokenFactoryParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"denom_creation_fee":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"denom_creation_gas_consume":{"type":"string","format":"uint64","title":"if denom_creation_fee is an empty array, then this field is used to add\nmore gas consumption to the base cost.\nhttps://github.com/CosmWasm/token-factory/issues/11"}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /kiichain/tokenfactory/v1beta1/denoms/{denom}/authority\_metadata

> DenomAuthorityMetadata defines a gRPC query method for fetching\
> DenomAuthorityMetadata for a particular denom.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/kiichain/tokenfactory/v1beta1/denoms/{denom}/authority_metadata":{"get":{"summary":"DenomAuthorityMetadata defines a gRPC query method for fetching\nDenomAuthorityMetadata for a particular denom.","operationId":"DenomAuthorityMetadata","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"authority_metadata":{"type":"object","properties":{"admin":{"type":"string","title":"Can be empty for no admin, or a valid kii address"}},"description":"DenomAuthorityMetadata specifies metadata for addresses that have specific\ncapabilities over a token factory denom. Right now there is only one Admin\npermission, but is planned to be extended to the future."}},"description":"QueryDenomAuthorityMetadataResponse defines the response structure for the\nDenomAuthorityMetadata gRPC query."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /kiichain/tokenfactory/v1beta1/denoms\_from\_admin/{admin}

> DenomsFromAdmin defines a gRPC query method for fetching all\
> denominations owned by a specific admin.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/kiichain/tokenfactory/v1beta1/denoms_from_admin/{admin}":{"get":{"summary":"DenomsFromAdmin defines a gRPC query method for fetching all\ndenominations owned by a specific admin.","operationId":"DenomsFromAdmin","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"denoms":{"type":"array","items":{"type":"string"}}},"description":"QueryDenomsFromAdminRequest defines the response structure for the\nDenomsFromAdmin gRPC query."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"admin","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /kiichain/tokenfactory/v1beta1/denoms\_from\_creator/{creator}

> DenomsFromCreator defines a gRPC query method for fetching all\
> denominations created by a specific admin/creator.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/kiichain/tokenfactory/v1beta1/denoms_from_creator/{creator}":{"get":{"summary":"DenomsFromCreator defines a gRPC query method for fetching all\ndenominations created by a specific admin/creator.","operationId":"DenomsFromCreator","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"denoms":{"type":"array","items":{"type":"string"}}},"description":"QueryDenomsFromCreatorRequest defines the response structure for the\nDenomsFromCreator gRPC query."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"creator","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```


# Cosmwasm

## GET /cosmwasm/wasm/v1/code

> Codes gets the metadata for all stored wasm codes

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/code":{"get":{"summary":"Codes gets the metadata for all stored wasm codes","operationId":"Codes","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"code_infos":{"type":"array","items":{"type":"object","properties":{"code_id":{"type":"string","format":"uint64"},"creator":{"type":"string"},"data_hash":{"type":"string","format":"byte"},"instantiate_permission":{"type":"object","properties":{"permission":{"type":"string","enum":["ACCESS_TYPE_UNSPECIFIED","ACCESS_TYPE_NOBODY","ACCESS_TYPE_EVERYBODY","ACCESS_TYPE_ANY_OF_ADDRESSES"],"default":"ACCESS_TYPE_UNSPECIFIED","description":"- ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value\n - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden\n - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted\n - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses","title":"AccessType permission types"},"addresses":{"type":"array","items":{"type":"string"}}},"description":"AccessConfig access control type."}},"title":"CodeInfoResponse contains code meta data from CodeInfo"}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryCodesResponse is the response type for the Query/Codes RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/code/{code\_id}

> Code gets the binary code and metadata for a singe wasm code

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/code/{code_id}":{"get":{"summary":"Code gets the binary code and metadata for a singe wasm code","operationId":"Code","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"code_info":{"type":"object","properties":{"code_id":{"type":"string","format":"uint64"},"creator":{"type":"string"},"data_hash":{"type":"string","format":"byte"},"instantiate_permission":{"type":"object","properties":{"permission":{"type":"string","enum":["ACCESS_TYPE_UNSPECIFIED","ACCESS_TYPE_NOBODY","ACCESS_TYPE_EVERYBODY","ACCESS_TYPE_ANY_OF_ADDRESSES"],"default":"ACCESS_TYPE_UNSPECIFIED","description":"- ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value\n - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden\n - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted\n - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses","title":"AccessType permission types"},"addresses":{"type":"array","items":{"type":"string"}}},"description":"AccessConfig access control type."}},"title":"CodeInfoResponse contains code meta data from CodeInfo"},"data":{"type":"string","format":"byte"}},"title":"QueryCodeResponse is the response type for the Query/Code RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"code_id","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/code/{code\_id}/contracts

> ContractsByCode lists all smart contracts for a code id

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/code/{code_id}/contracts":{"get":{"summary":"ContractsByCode lists all smart contracts for a code id","operationId":"ContractsByCode","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"contracts":{"type":"array","items":{"type":"string"},"title":"contracts are a set of contract addresses"},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryContractsByCodeResponse is the response type for the\nQuery/ContractsByCode RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"code_id","in":"path","required":true,"type":"string","format":"uint64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/codes/params

> Params gets the module params

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/codes/params":{"get":{"summary":"Params gets the module params","operationId":"WasmParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"code_upload_access":{"type":"object","properties":{"permission":{"type":"string","enum":["ACCESS_TYPE_UNSPECIFIED","ACCESS_TYPE_NOBODY","ACCESS_TYPE_EVERYBODY","ACCESS_TYPE_ANY_OF_ADDRESSES"],"default":"ACCESS_TYPE_UNSPECIFIED","description":"- ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value\n - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden\n - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted\n - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses","title":"AccessType permission types"},"addresses":{"type":"array","items":{"type":"string"}}},"description":"AccessConfig access control type."},"instantiate_default_permission":{"type":"string","enum":["ACCESS_TYPE_UNSPECIFIED","ACCESS_TYPE_NOBODY","ACCESS_TYPE_EVERYBODY","ACCESS_TYPE_ANY_OF_ADDRESSES"],"default":"ACCESS_TYPE_UNSPECIFIED","description":"- ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value\n - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden\n - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted\n - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses","title":"AccessType permission types"}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/codes/pinned

> PinnedCodes gets the pinned code ids

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/codes/pinned":{"get":{"summary":"PinnedCodes gets the pinned code ids","operationId":"PinnedCodes","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"code_ids":{"type":"array","items":{"type":"string","format":"uint64"}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryPinnedCodesResponse is the response type for the\nQuery/PinnedCodes RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contract/build\_address

> BuildAddress builds a contract address

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contract/build_address":{"get":{"summary":"BuildAddress builds a contract address","operationId":"BuildAddress","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"address":{"type":"string","title":"Address is the contract address"}},"description":"QueryBuildAddressResponse is the response type for the Query/BuildAddress RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"code_hash","description":"CodeHash is the hash of the code.","in":"query","required":false,"type":"string"},{"name":"creator_address","description":"CreatorAddress is the address of the contract instantiator.","in":"query","required":false,"type":"string"},{"name":"salt","description":"Salt is a hex encoded salt.","in":"query","required":false,"type":"string"},{"name":"init_args","description":"InitArgs are optional json encoded init args to be used in contract address\nbuilding if provided.","in":"query","required":false,"type":"string","format":"byte"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contract/{address}

> ContractInfo gets the contract meta data

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contract/{address}":{"get":{"summary":"ContractInfo gets the contract meta data","operationId":"ContractInfo","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"address":{"type":"string","title":"address is the address of the contract"},"contract_info":{"type":"object","properties":{"code_id":{"type":"string","format":"uint64","title":"CodeID is the reference to the stored Wasm code"},"creator":{"type":"string","title":"Creator address who initially instantiated the contract"},"admin":{"type":"string","title":"Admin is an optional address that can execute migrations"},"label":{"type":"string","description":"Label is optional metadata to be stored with a contract instance."},"created":{"description":"Created Tx position when the contract was instantiated.","type":"object","properties":{"block_height":{"type":"string","format":"uint64","title":"BlockHeight is the block the contract was created at"},"tx_index":{"type":"string","format":"uint64","title":"TxIndex is a monotonic counter within the block (actual transaction index,\nor gas consumed)"}}},"ibc_port_id":{"type":"string"},"extension":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}},"title":"ContractInfo stores a WASM contract instance"}},"title":"QueryContractInfoResponse is the response type for the Query/ContractInfo RPC\nmethod"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the address of the contract to query","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contract/{address}/history

> ContractHistory gets the contract code history

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contract/{address}/history":{"get":{"summary":"ContractHistory gets the contract code history","operationId":"ContractHistory","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"operation":{"type":"string","enum":["CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED","CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT","CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE","CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS"],"default":"CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED","description":"- CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value\n - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation\n - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration\n - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data","title":"ContractCodeHistoryOperationType actions that caused a code change"},"code_id":{"type":"string","format":"uint64","title":"CodeID is the reference to the stored WASM code"},"updated":{"description":"Updated Tx position when the operation was executed.","type":"object","properties":{"block_height":{"type":"string","format":"uint64","title":"BlockHeight is the block the contract was created at"},"tx_index":{"type":"string","format":"uint64","title":"TxIndex is a monotonic counter within the block (actual transaction index,\nor gas consumed)"}}},"msg":{"type":"string","format":"byte"}},"description":"ContractCodeHistoryEntry metadata to a contract."}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryContractHistoryResponse is the response type for the\nQuery/ContractHistory RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the address of the contract to query","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contract/{address}/raw/{query\_data}

> RawContractState gets single key from the raw store data of a contract

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contract/{address}/raw/{query_data}":{"get":{"summary":"RawContractState gets single key from the raw store data of a contract","operationId":"RawContractState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","format":"byte","title":"Data contains the raw store data"}},"title":"QueryRawContractStateResponse is the response type for the\nQuery/RawContractState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the address of the contract","in":"path","required":true,"type":"string"},{"name":"query_data","in":"path","required":true,"type":"string","format":"byte"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contract/{address}/smart/{query\_data}

> SmartContractState get smart query result from the contract

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contract/{address}/smart/{query_data}":{"get":{"summary":"SmartContractState get smart query result from the contract","operationId":"SmartContractState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","format":"byte","title":"Data contains the json data returned from the smart contract"}},"title":"QuerySmartContractStateResponse is the response type for the\nQuery/SmartContractState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the address of the contract","in":"path","required":true,"type":"string"},{"name":"query_data","description":"QueryData contains the query data passed to the contract","in":"path","required":true,"type":"string","format":"byte"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contract/{address}/state

> AllContractState gets all raw store data for a single contract

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contract/{address}/state":{"get":{"summary":"AllContractState gets all raw store data for a single contract","operationId":"AllContractState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"models":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string","format":"byte","title":"hex-encode key to read it better (this is often ascii)"},"value":{"type":"string","format":"byte","title":"base64-encode raw value"}},"title":"Model is a struct that holds a KV pair"}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryAllContractStateResponse is the response type for the\nQuery/AllContractState RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the address of the contract","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmwasm/wasm/v1/contracts/creator/{creator\_address}

> ContractsByCreator gets the contracts by creator

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmwasm/wasm/v1/contracts/creator/{creator_address}":{"get":{"summary":"ContractsByCreator gets the contracts by creator","operationId":"ContractsByCreator","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"contract_addresses":{"type":"array","items":{"type":"string"},"title":"ContractAddresses result set"},"pagination":{"description":"Pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryContractsByCreatorResponse is the response type for the\nQuery/ContractsByCreator RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"creator_address","description":"CreatorAddress is the address of contract creator","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```


# Cosmos


# Auth

## GET /cosmos/auth/v1beta1/params

> Params queries all parameters.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/params":{"get":{"summary":"Params queries all parameters.","operationId":"AuthParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"max_memo_characters":{"type":"string","format":"uint64"},"tx_sig_limit":{"type":"string","format":"uint64"},"tx_size_cost_per_byte":{"type":"string","format":"uint64"},"sig_verify_cost_ed25519":{"type":"string","format":"uint64"},"sig_verify_cost_secp256k1":{"type":"string","format":"uint64"}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## AccountInfo queries account info which is common to all account types.

> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/account_info/{address}":{"get":{"summary":"AccountInfo queries account info which is common to all account types.","description":"Since: cosmos-sdk 0.47","operationId":"AccountInfo","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"info":{"description":"info is the account info which is represented by BaseAccount.","type":"object","properties":{"address":{"type":"string"},"pub_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"account_number":{"type":"string","format":"uint64"},"sequence":{"type":"string","format":"uint64"}}}},"description":"QueryAccountInfoResponse is the Query/AccountInfo response type.\n\nSince: cosmos-sdk 0.47"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address is the account address string.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## Accounts returns all the existing accounts.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.\
> \
> Since: cosmos-sdk 0.43

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/accounts":{"get":{"summary":"Accounts returns all the existing accounts.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.\n\nSince: cosmos-sdk 0.43","operationId":"Accounts","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"accounts":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"accounts are the existing accounts"},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryAccountsResponse is the response type for the Query/Accounts RPC method.\n\nSince: cosmos-sdk 0.43"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/auth/v1beta1/accounts/{address}

> Account returns account details based on address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/accounts/{address}":{"get":{"summary":"Account returns account details based on address.","operationId":"Account","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"account":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}},"description":"QueryAccountResponse is the response type for the Query/Account RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address","description":"address defines the address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## AccountAddressByID returns account address based on account number.

> Since: cosmos-sdk 0.46.2

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/address_by_id/{id}":{"get":{"summary":"AccountAddressByID returns account address based on account number.","description":"Since: cosmos-sdk 0.46.2","operationId":"AccountAddressByID","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"account_address":{"type":"string"}},"description":"Since: cosmos-sdk 0.46.2","title":"QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"id","description":"Deprecated, use account_id instead\n\nid is the account number of the address to be queried. This field\nshould have been an uint64 (like all account numbers), and will be\nupdated to uint64 in a future version of the auth query.","in":"path","required":true,"type":"string","format":"int64"},{"name":"account_id","description":"account_id is the account number of the address to be queried.\n\nSince: cosmos-sdk 0.47","in":"query","required":false,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## Bech32Prefix queries bech32Prefix

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/bech32":{"get":{"summary":"Bech32Prefix queries bech32Prefix","description":"Since: cosmos-sdk 0.46","operationId":"Bech32Prefix","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"bech32_prefix":{"type":"string"}},"description":"Bech32PrefixResponse is the response type for Bech32Prefix rpc method.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## AddressBytesToString converts Account Address bytes to string

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/bech32/{address_bytes}":{"get":{"summary":"AddressBytesToString converts Account Address bytes to string","description":"Since: cosmos-sdk 0.46","operationId":"AddressBytesToString","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"address_string":{"type":"string"}},"description":"AddressBytesToStringResponse is the response type for AddressString rpc method.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address_bytes","in":"path","required":true,"type":"string","format":"byte"}],"tags":["Query"]}}}}
```

## AddressStringToBytes converts Address string to bytes

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/bech32/{address_string}":{"get":{"summary":"AddressStringToBytes converts Address string to bytes","description":"Since: cosmos-sdk 0.46","operationId":"AddressStringToBytes","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"address_bytes":{"type":"string","format":"byte"}},"description":"AddressStringToBytesResponse is the response type for AddressBytes rpc method.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"address_string","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## ModuleAccounts returns all the existing module accounts.

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/module_accounts":{"get":{"summary":"ModuleAccounts returns all the existing module accounts.","description":"Since: cosmos-sdk 0.46","operationId":"ModuleAccounts","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"accounts":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}},"description":"QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/auth/v1beta1/module\_accounts/{name}

> ModuleAccountByName returns the module account info by module name

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/auth/v1beta1/module_accounts/{name}":{"get":{"summary":"ModuleAccountByName returns the module account info by module name","operationId":"ModuleAccountByName","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"account":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}},"description":"QueryModuleAccountByNameResponse is the response type for the Query/ModuleAccountByName RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"name","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```


# Authz

## GET /cosmos/authz/v1beta1/grants

> Returns list of \`Authorization\`, granted to the grantee by the granter.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/authz/v1beta1/grants":{"get":{"summary":"Returns list of `Authorization`, granted to the grantee by the granter.","operationId":"Grants","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"grants":{"type":"array","items":{"type":"object","properties":{"authorization":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"expiration":{"type":"string","format":"date-time","title":"time when the grant will expire and will be pruned. If null, then the grant\ndoesn't have a time expiration (other conditions  in `authorization`\nmay apply to invalidate the grant)"}},"description":"Grant gives permissions to execute\nthe provide method with expiration time."},"description":"authorizations is a list of grants granted for grantee by granter."},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryGrantsResponse is the response type for the Query/Authorizations RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"granter","in":"query","required":false,"type":"string"},{"name":"grantee","in":"query","required":false,"type":"string"},{"name":"msg_type_url","description":"Optional, msg_type_url, when set, will query only grants matching given msg type.","in":"query","required":false,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GranteeGrants returns a list of \`GrantAuthorization\` by grantee.

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/authz/v1beta1/grants/grantee/{grantee}":{"get":{"summary":"GranteeGrants returns a list of `GrantAuthorization` by grantee.","description":"Since: cosmos-sdk 0.46","operationId":"GranteeGrants","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"grants":{"type":"array","items":{"type":"object","properties":{"granter":{"type":"string"},"grantee":{"type":"string"},"authorization":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"expiration":{"type":"string","format":"date-time"}},"title":"GrantAuthorization extends a grant with both the addresses of the grantee and granter.\nIt is used in genesis.proto and query.proto"},"description":"grants is a list of grants granted to the grantee."},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryGranteeGrantsResponse is the response type for the Query/GranteeGrants RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"grantee","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GranterGrants returns list of \`GrantAuthorization\`, granted by granter.

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/authz/v1beta1/grants/granter/{granter}":{"get":{"summary":"GranterGrants returns list of `GrantAuthorization`, granted by granter.","description":"Since: cosmos-sdk 0.46","operationId":"GranterGrants","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"grants":{"type":"array","items":{"type":"object","properties":{"granter":{"type":"string"},"grantee":{"type":"string"},"authorization":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"expiration":{"type":"string","format":"date-time"}},"title":"GrantAuthorization extends a grant with both the addresses of the grantee and granter.\nIt is used in genesis.proto and query.proto"},"description":"grants is a list of grants granted by the granter."},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryGranterGrantsResponse is the response type for the Query/GranterGrants RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"granter","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```


# Bank

## AllBalances queries the balance of all coins for a single account.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/balances/{address}":{"get":{"summary":"AllBalances queries the balance of all coins for a single account.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"AllBalances","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"balances":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"balances is the balances of all the coins."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryAllBalancesResponse is the response type for the Query/AllBalances RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"address","description":"address is the address to query balances for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"},{"name":"resolve_denom","description":"resolve_denom is the flag to resolve the denom into a human-readable form from the metadata.\n\nSince: cosmos-sdk 0.50","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/bank/v1beta1/balances/{address}/by\_denom

> Balance queries the balance of a single coin for a single account.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/balances/{address}/by_denom":{"get":{"summary":"Balance queries the balance of a single coin for a single account.","operationId":"Balance","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"QueryBalanceResponse is the response type for the Query/Balance RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"address","description":"address is the address to query balances for.","in":"path","required":true,"type":"string"},{"name":"denom","description":"denom is the coin denom to query balances for.","in":"query","required":false,"type":"string"}],"tags":["Query"]}}}}
```

DenomOwners queries for all account addresses that own a particular token\
denomination.
-------------

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.\
> \
> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/denom_owners/{denom}":{"get":{"summary":"DenomOwners queries for all account addresses that own a particular token\ndenomination.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.\n\nSince: cosmos-sdk 0.46","operationId":"DenomOwners","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"denom_owners":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","description":"address defines the address that owns a particular denomination."},"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"DenomOwner defines structure representing an account that owns or holds a\nparticular denominated token. It contains the account address and account\nbalance of the denominated token.\n\nSince: cosmos-sdk 0.46"}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDenomOwnersResponse defines the RPC response of a DenomOwners RPC query.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","description":"denom defines the coin denomination to query all account holders for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

DenomOwnersByQuery queries for all account addresses that own a particular token\
denomination.
-------------

> Since: cosmos-sdk 0.50.3

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/denom_owners_by_query":{"get":{"summary":"DenomOwnersByQuery queries for all account addresses that own a particular token\ndenomination.","description":"Since: cosmos-sdk 0.50.3","operationId":"DenomOwnersByQuery","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"denom_owners":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","description":"address defines the address that owns a particular denomination."},"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"DenomOwner defines structure representing an account that owns or holds a\nparticular denominated token. It contains the account address and account\nbalance of the denominated token.\n\nSince: cosmos-sdk 0.46"}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDenomOwnersByQueryResponse defines the RPC response of a DenomOwnersByQuery RPC query.\n\nSince: cosmos-sdk 0.50.3"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","description":"denom defines the coin denomination to query all account holders for.","in":"query","required":false,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/bank/v1beta1/denoms\_metadata

> DenomsMetadata queries the client metadata for all registered coin\
> denominations.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/denoms_metadata":{"get":{"summary":"DenomsMetadata queries the client metadata for all registered coin\ndenominations.","operationId":"DenomsMetadata","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"metadatas":{"type":"array","items":{"type":"object","properties":{"description":{"type":"string"},"denom_units":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string","description":"denom represents the string name of the given denom unit (e.g uatom)."},"exponent":{"type":"integer","format":"int64","description":"exponent represents power of 10 exponent that one must\nraise the base_denom to in order to equal the given DenomUnit's denom\n1 denom = 10^exponent base_denom\n(e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with\nexponent = 6, thus: 1 atom = 10^6 uatom)."},"aliases":{"type":"array","items":{"type":"string"},"title":"aliases is a list of string aliases for the given denom"}},"description":"DenomUnit represents a struct that describes a given\ndenomination unit of the basic token."},"title":"denom_units represents the list of DenomUnit's for a given coin"},"base":{"type":"string","description":"base represents the base denom (should be the DenomUnit with exponent = 0)."},"display":{"type":"string","description":"display indicates the suggested denom that should be\ndisplayed in clients."},"name":{"type":"string","description":"Since: cosmos-sdk 0.43","title":"name defines the name of the token (eg: Cosmos Atom)"},"symbol":{"type":"string","description":"symbol is the token symbol usually shown on exchanges (eg: ATOM). This can\nbe the same as the display.\n\nSince: cosmos-sdk 0.43"},"uri":{"type":"string","description":"URI to a document (on or off-chain) that contains additional information. Optional.\n\nSince: cosmos-sdk 0.46"},"uri_hash":{"type":"string","description":"URIHash is a sha256 hash of a document pointed by URI. It's used to verify that\nthe document didn't change. Optional.\n\nSince: cosmos-sdk 0.46"}},"description":"Metadata represents a struct that describes\na basic token."},"description":"metadata provides the client information for all the registered tokens."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/bank/v1beta1/denoms\_metadata/{denom}

> DenomMetadata queries the client metadata of a given coin denomination.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/denoms_metadata/{denom}":{"get":{"summary":"DenomMetadata queries the client metadata of a given coin denomination.","operationId":"DenomMetadata","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"metadata":{"type":"object","properties":{"description":{"type":"string"},"denom_units":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string","description":"denom represents the string name of the given denom unit (e.g uatom)."},"exponent":{"type":"integer","format":"int64","description":"exponent represents power of 10 exponent that one must\nraise the base_denom to in order to equal the given DenomUnit's denom\n1 denom = 10^exponent base_denom\n(e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with\nexponent = 6, thus: 1 atom = 10^6 uatom)."},"aliases":{"type":"array","items":{"type":"string"},"title":"aliases is a list of string aliases for the given denom"}},"description":"DenomUnit represents a struct that describes a given\ndenomination unit of the basic token."},"title":"denom_units represents the list of DenomUnit's for a given coin"},"base":{"type":"string","description":"base represents the base denom (should be the DenomUnit with exponent = 0)."},"display":{"type":"string","description":"display indicates the suggested denom that should be\ndisplayed in clients."},"name":{"type":"string","description":"Since: cosmos-sdk 0.43","title":"name defines the name of the token (eg: Cosmos Atom)"},"symbol":{"type":"string","description":"symbol is the token symbol usually shown on exchanges (eg: ATOM). This can\nbe the same as the display.\n\nSince: cosmos-sdk 0.43"},"uri":{"type":"string","description":"URI to a document (on or off-chain) that contains additional information. Optional.\n\nSince: cosmos-sdk 0.46"},"uri_hash":{"type":"string","description":"URIHash is a sha256 hash of a document pointed by URI. It's used to verify that\nthe document didn't change. Optional.\n\nSince: cosmos-sdk 0.46"}},"description":"Metadata represents a struct that describes\na basic token."}},"description":"QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","description":"denom is the coin denom to query the metadata for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/bank/v1beta1/denoms\_metadata\_by\_query\_string

> DenomMetadataByQueryString queries the client metadata of a given coin denomination.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/denoms_metadata_by_query_string":{"get":{"summary":"DenomMetadataByQueryString queries the client metadata of a given coin denomination.","operationId":"DenomMetadataByQueryString","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"metadata":{"type":"object","properties":{"description":{"type":"string"},"denom_units":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string","description":"denom represents the string name of the given denom unit (e.g uatom)."},"exponent":{"type":"integer","format":"int64","description":"exponent represents power of 10 exponent that one must\nraise the base_denom to in order to equal the given DenomUnit's denom\n1 denom = 10^exponent base_denom\n(e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with\nexponent = 6, thus: 1 atom = 10^6 uatom)."},"aliases":{"type":"array","items":{"type":"string"},"title":"aliases is a list of string aliases for the given denom"}},"description":"DenomUnit represents a struct that describes a given\ndenomination unit of the basic token."},"title":"denom_units represents the list of DenomUnit's for a given coin"},"base":{"type":"string","description":"base represents the base denom (should be the DenomUnit with exponent = 0)."},"display":{"type":"string","description":"display indicates the suggested denom that should be\ndisplayed in clients."},"name":{"type":"string","description":"Since: cosmos-sdk 0.43","title":"name defines the name of the token (eg: Cosmos Atom)"},"symbol":{"type":"string","description":"symbol is the token symbol usually shown on exchanges (eg: ATOM). This can\nbe the same as the display.\n\nSince: cosmos-sdk 0.43"},"uri":{"type":"string","description":"URI to a document (on or off-chain) that contains additional information. Optional.\n\nSince: cosmos-sdk 0.46"},"uri_hash":{"type":"string","description":"URIHash is a sha256 hash of a document pointed by URI. It's used to verify that\nthe document didn't change. Optional.\n\nSince: cosmos-sdk 0.46"}},"description":"Metadata represents a struct that describes\na basic token."}},"description":"QueryDenomMetadataByQueryStringResponse is the response type for the Query/DenomMetadata RPC\nmethod. Identical with QueryDenomMetadataResponse but receives denom as query string in request."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","description":"denom is the coin denom to query the metadata for.","in":"query","required":false,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/bank/v1beta1/params

> Params queries the parameters of x/bank module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/params":{"get":{"summary":"Params queries the parameters of x/bank module.","operationId":"BankParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params provides the parameters of the bank module.","type":"object","properties":{"send_enabled":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"enabled":{"type":"boolean"}},"description":"SendEnabled maps coin denom to a send_enabled status (whether a denom is\nsendable)."},"description":"Deprecated: Use of SendEnabled in params is deprecated.\nFor genesis, use the newly added send_enabled field in the genesis object.\nStorage, lookup, and manipulation of this information is now in the keeper.\n\nAs of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files."},"default_send_enabled":{"type":"boolean"}}}},"description":"QueryParamsResponse defines the response type for querying x/bank parameters."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## SendEnabled queries for SendEnabled entries.

> This query only returns denominations that have specific SendEnabled settings.\
> Any denomination that does not have a specific setting will use the default\
> params.default\_send\_enabled, and will not be returned by this query.\
> \
> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/send_enabled":{"get":{"summary":"SendEnabled queries for SendEnabled entries.","description":"This query only returns denominations that have specific SendEnabled settings.\nAny denomination that does not have a specific setting will use the default\nparams.default_send_enabled, and will not be returned by this query.\n\nSince: cosmos-sdk 0.47","operationId":"SendEnabled","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"send_enabled":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"enabled":{"type":"boolean"}},"description":"SendEnabled maps coin denom to a send_enabled status (whether a denom is\nsendable)."}},"pagination":{"description":"pagination defines the pagination in the response. This field is only\npopulated if the denoms field in the request is empty.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QuerySendEnabledResponse defines the RPC response of a SendEnable query.\n\nSince: cosmos-sdk 0.47"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denoms","description":"denoms is the specific denoms you want look up. Leave empty to get all entries.","in":"query","required":false,"type":"array","items":{"type":"string"},"collectionFormat":"multi"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

SpendableBalances queries the spendable balance of all coins for a single\
account.
--------

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.\
> \
> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/spendable_balances/{address}":{"get":{"summary":"SpendableBalances queries the spendable balance of all coins for a single\naccount.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.\n\nSince: cosmos-sdk 0.46","operationId":"SpendableBalances","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"balances":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"balances is the spendable balances of all the coins."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QuerySpendableBalancesResponse defines the gRPC response structure for querying\nan account's spendable balances.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"address","description":"address is the address to query spendable balances for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

SpendableBalanceByDenom queries the spendable balance of a single denom for\
a single account.
-----------------

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.\
> \
> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/spendable_balances/{address}/by_denom":{"get":{"summary":"SpendableBalanceByDenom queries the spendable balance of a single denom for\na single account.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.\n\nSince: cosmos-sdk 0.47","operationId":"SpendableBalanceByDenom","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"QuerySpendableBalanceByDenomResponse defines the gRPC response structure for\nquerying an account's spendable balance for a specific denom.\n\nSince: cosmos-sdk 0.47"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"address","description":"address is the address to query balances for.","in":"path","required":true,"type":"string"},{"name":"denom","description":"denom is the coin denom to query balances for.","in":"query","required":false,"type":"string"}],"tags":["Query"]}}}}
```

## TotalSupply queries the total supply of all coins.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/supply":{"get":{"summary":"TotalSupply queries the total supply of all coins.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"TotalSupply","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"supply":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"supply is the supply of the coins"},"pagination":{"description":"pagination defines the pagination in the response.\n\nSince: cosmos-sdk 0.43","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC\nmethod"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## SupplyOf queries the supply of a single coin.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/bank/v1beta1/supply/by_denom":{"get":{"summary":"SupplyOf queries the supply of a single coin.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"SupplyOf","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"amount":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"denom","description":"denom is the coin denom to query balances for.","in":"query","required":false,"type":"string"}],"tags":["Query"]}}}}
```


# Tendermint

ABCIQuery defines a query handler that supports ABCI queries directly to the\
application, bypassing Tendermint completely. The ABCI query must contain\
a valid and supported path, including app, custom, p2p, and store.
------------------------------------------------------------------

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/abci_query":{"get":{"summary":"ABCIQuery defines a query handler that supports ABCI queries directly to the\napplication, bypassing Tendermint completely. The ABCI query must contain\na valid and supported path, including app, custom, p2p, and store.","description":"Since: cosmos-sdk 0.46","operationId":"ABCIQuery","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int64"},"log":{"type":"string"},"info":{"type":"string"},"index":{"type":"string","format":"int64"},"key":{"type":"string","format":"byte"},"value":{"type":"string","format":"byte"},"proof_ops":{"type":"object","properties":{"ops":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"key":{"type":"string","format":"byte"},"data":{"type":"string","format":"byte"}},"description":"ProofOp defines an operation used for calculating Merkle root. The data could\nbe arbitrary format, providing necessary data for example neighbouring node\nhash.\n\nNote: This type is a duplicate of the ProofOp proto type defined in Tendermint."}}},"description":"ProofOps is Merkle proof defined by the list of ProofOps.\n\nNote: This type is a duplicate of the ProofOps proto type defined in Tendermint."},"height":{"type":"string","format":"int64"},"codespace":{"type":"string"}},"description":"ABCIQueryResponse defines the response structure for the ABCIQuery gRPC query.\n\nNote: This type is a duplicate of the ResponseQuery proto type defined in\nTendermint."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"data","in":"query","required":false,"type":"string","format":"byte"},{"name":"path","in":"query","required":false,"type":"string"},{"name":"height","in":"query","required":false,"type":"string","format":"int64"},{"name":"prove","in":"query","required":false,"type":"boolean"}],"tags":["Service"]}}}}
```

## GET /cosmos/base/tendermint/v1beta1/blocks/latest

> GetLatestBlock returns the latest block.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/blocks/latest":{"get":{"summary":"GetLatestBlock returns the latest block.","operationId":"GetLatestBlock","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"block":{"title":"Deprecated: please use `sdk_block` instead","type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"data":{"type":"object","properties":{"txs":{"type":"array","items":{"type":"string","format":"byte"},"description":"Txs that will be applied by state @ block.Height+1.\nNOTE: not all txs here are valid.  We're just agreeing on the order first.\nThis means that block.AppHash does not include these txs."}},"title":"Data contains the set of transactions included in the block"},"evidence":{"type":"object","properties":{"evidence":{"type":"array","items":{"type":"object","properties":{"duplicate_vote_evidence":{"type":"object","properties":{"vote_a":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"vote_b":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"total_voting_power":{"type":"string","format":"int64"},"validator_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes."},"light_client_attack_evidence":{"type":"object","properties":{"conflicting_block":{"type":"object","properties":{"signed_header":{"type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"validator_set":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"proposer":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}},"total_voting_power":{"type":"string","format":"int64"}}}}},"common_height":{"type":"string","format":"int64"},"byzantine_validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"total_voting_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client."}}}}}},"last_commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"sdk_block":{"title":"Since: cosmos-sdk 0.47","type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","description":"proposer_address is the original block proposer address, formatted as a Bech32 string.\nIn Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string\nfor better UX."}},"description":"Header defines the structure of a Tendermint block header."},"data":{"type":"object","properties":{"txs":{"type":"array","items":{"type":"string","format":"byte"},"description":"Txs that will be applied by state @ block.Height+1.\nNOTE: not all txs here are valid.  We're just agreeing on the order first.\nThis means that block.AppHash does not include these txs."}},"title":"Data contains the set of transactions included in the block"},"evidence":{"type":"object","properties":{"evidence":{"type":"array","items":{"type":"object","properties":{"duplicate_vote_evidence":{"type":"object","properties":{"vote_a":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"vote_b":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"total_voting_power":{"type":"string","format":"int64"},"validator_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes."},"light_client_attack_evidence":{"type":"object","properties":{"conflicting_block":{"type":"object","properties":{"signed_header":{"type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"validator_set":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"proposer":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}},"total_voting_power":{"type":"string","format":"int64"}}}}},"common_height":{"type":"string","format":"int64"},"byzantine_validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"total_voting_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client."}}}}}},"last_commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}},"description":"Block is tendermint type Block, with the Header proposer address\nfield converted to bech32 string."}},"description":"GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"]}}}}
```

## GET /cosmos/base/tendermint/v1beta1/blocks/{height}

> GetBlockByHeight queries block for given height.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/blocks/{height}":{"get":{"summary":"GetBlockByHeight queries block for given height.","operationId":"GetBlockByHeight","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"block":{"title":"Deprecated: please use `sdk_block` instead","type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"data":{"type":"object","properties":{"txs":{"type":"array","items":{"type":"string","format":"byte"},"description":"Txs that will be applied by state @ block.Height+1.\nNOTE: not all txs here are valid.  We're just agreeing on the order first.\nThis means that block.AppHash does not include these txs."}},"title":"Data contains the set of transactions included in the block"},"evidence":{"type":"object","properties":{"evidence":{"type":"array","items":{"type":"object","properties":{"duplicate_vote_evidence":{"type":"object","properties":{"vote_a":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"vote_b":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"total_voting_power":{"type":"string","format":"int64"},"validator_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes."},"light_client_attack_evidence":{"type":"object","properties":{"conflicting_block":{"type":"object","properties":{"signed_header":{"type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"validator_set":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"proposer":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}},"total_voting_power":{"type":"string","format":"int64"}}}}},"common_height":{"type":"string","format":"int64"},"byzantine_validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"total_voting_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client."}}}}}},"last_commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"sdk_block":{"title":"Since: cosmos-sdk 0.47","type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","description":"proposer_address is the original block proposer address, formatted as a Bech32 string.\nIn Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string\nfor better UX."}},"description":"Header defines the structure of a Tendermint block header."},"data":{"type":"object","properties":{"txs":{"type":"array","items":{"type":"string","format":"byte"},"description":"Txs that will be applied by state @ block.Height+1.\nNOTE: not all txs here are valid.  We're just agreeing on the order first.\nThis means that block.AppHash does not include these txs."}},"title":"Data contains the set of transactions included in the block"},"evidence":{"type":"object","properties":{"evidence":{"type":"array","items":{"type":"object","properties":{"duplicate_vote_evidence":{"type":"object","properties":{"vote_a":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"vote_b":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"total_voting_power":{"type":"string","format":"int64"},"validator_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes."},"light_client_attack_evidence":{"type":"object","properties":{"conflicting_block":{"type":"object","properties":{"signed_header":{"type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"validator_set":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"proposer":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}},"total_voting_power":{"type":"string","format":"int64"}}}}},"common_height":{"type":"string","format":"int64"},"byzantine_validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"total_voting_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client."}}}}}},"last_commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}},"description":"Block is tendermint type Block, with the Header proposer address\nfield converted to bech32 string."}},"description":"GetBlockByHeightResponse is the response type for the Query/GetBlockByHeight RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"height","in":"path","required":true,"type":"string","format":"int64"}],"tags":["Service"]}}}}
```

## GET /cosmos/base/tendermint/v1beta1/node\_info

> GetNodeInfo queries the current node info.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/node_info":{"get":{"summary":"GetNodeInfo queries the current node info.","operationId":"GetNodeInfo","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"default_node_info":{"type":"object","properties":{"protocol_version":{"type":"object","properties":{"p2p":{"type":"string","format":"uint64"},"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}}},"default_node_id":{"type":"string"},"listen_addr":{"type":"string"},"network":{"type":"string"},"version":{"type":"string"},"channels":{"type":"string","format":"byte"},"moniker":{"type":"string"},"other":{"type":"object","properties":{"tx_index":{"type":"string"},"rpc_address":{"type":"string"}}}}},"application_version":{"type":"object","properties":{"name":{"type":"string"},"app_name":{"type":"string"},"version":{"type":"string"},"git_commit":{"type":"string"},"build_tags":{"type":"string"},"go_version":{"type":"string"},"build_deps":{"type":"array","items":{"type":"object","properties":{"path":{"type":"string","title":"module path"},"version":{"type":"string","title":"module version"},"sum":{"type":"string","title":"checksum"}},"title":"Module is the type for VersionInfo"}},"cosmos_sdk_version":{"type":"string","title":"Since: cosmos-sdk 0.43"}},"description":"VersionInfo is the type for the GetNodeInfoResponse message."}},"description":"GetNodeInfoResponse is the response type for the Query/GetNodeInfo RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"]}}}}
```

## GET /cosmos/base/tendermint/v1beta1/syncing

> GetSyncing queries node syncing.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/syncing":{"get":{"summary":"GetSyncing queries node syncing.","operationId":"GetSyncing","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"syncing":{"type":"boolean"}},"description":"GetSyncingResponse is the response type for the Query/GetSyncing RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"]}}}}
```

## GET /cosmos/base/tendermint/v1beta1/validatorsets/latest

> GetLatestValidatorSet queries latest validator-set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/validatorsets/latest":{"get":{"summary":"GetLatestValidatorSet queries latest validator-set.","operationId":"GetLatestValidatorSet","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"block_height":{"type":"string","format":"int64"},"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string"},"pub_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}},"description":"Validator is the type for the validator-set."}},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"GetLatestValidatorSetResponse is the response type for the Query/GetValidatorSetByHeight RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Service"]}}}}
```

## GET /cosmos/base/tendermint/v1beta1/validatorsets/{height}

> GetValidatorSetByHeight queries validator-set at a given height.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/tendermint/v1beta1/validatorsets/{height}":{"get":{"summary":"GetValidatorSetByHeight queries validator-set at a given height.","operationId":"GetValidatorSetByHeight","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"block_height":{"type":"string","format":"int64"},"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string"},"pub_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}},"description":"Validator is the type for the validator-set."}},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"GetValidatorSetByHeightResponse is the response type for the Query/GetValidatorSetByHeight RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"height","in":"path","required":true,"type":"string","format":"int64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Service"]}}}}
```

## GET /cosmos/base/node/v1beta1/config

> Config queries for the operator configuration.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/node/v1beta1/config":{"get":{"summary":"Config queries for the operator configuration.","operationId":"Config","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"minimum_gas_price":{"type":"string"},"pruning_keep_recent":{"type":"string"},"pruning_interval":{"type":"string"},"halt_height":{"type":"string","format":"uint64"}},"description":"ConfigResponse defines the response structure for the Config gRPC query."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Service"]}}}}
```

## GET /cosmos/base/node/v1beta1/status

> Status queries for the node status.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/base/node/v1beta1/status":{"get":{"summary":"Status queries for the node status.","operationId":"Status","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"earliest_store_height":{"type":"string","format":"uint64"},"height":{"type":"string","format":"uint64"},"timestamp":{"type":"string","format":"date-time"},"app_hash":{"type":"string","format":"byte"},"validator_hash":{"type":"string","format":"byte"}},"description":"StateResponse defines the response structure for the status of a node."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Service"]}}}}
```


# Consensus

## GET /cosmos/consensus/v1/params

> Params queries the parameters of x/consensus module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/consensus/v1/params":{"get":{"summary":"Params queries the parameters of x/consensus module.","operationId":"ConsensusParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params are the tendermint consensus params stored in the consensus module.\nPlease note that `params.version` is not populated in this response, it is\ntracked separately in the x/upgrade module.","type":"object","properties":{"block":{"type":"object","properties":{"max_bytes":{"type":"string","format":"int64","title":"Max block size, in bytes.\nNote: must be greater than 0"},"max_gas":{"type":"string","format":"int64","title":"Max gas per block.\nNote: must be greater or equal to -1"}},"description":"BlockParams contains limits on the block size."},"evidence":{"type":"object","properties":{"max_age_num_blocks":{"type":"string","format":"int64","description":"Max age of evidence, in blocks.\n\nThe basic formula for calculating this is: MaxAgeDuration / {average block\ntime}."},"max_age_duration":{"type":"string","description":"Max age of evidence, in time.\n\nIt should correspond with an app's \"unbonding period\" or other similar\nmechanism for handling [Nothing-At-Stake\nattacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed)."},"max_bytes":{"type":"string","format":"int64","title":"This sets the maximum size of total evidence in bytes that can be committed in a single block.\nand should fall comfortably under the max block bytes.\nDefault is 1048576 or 1MB"}},"description":"EvidenceParams determine how we handle evidence of malfeasance."},"validator":{"type":"object","properties":{"pub_key_types":{"type":"array","items":{"type":"string"}}},"description":"ValidatorParams restrict the public key types validators can use.\nNOTE: uses ABCI pubkey naming, not Amino names."},"version":{"type":"object","properties":{"app":{"type":"string","format":"uint64"}},"description":"VersionParams contains the ABCI application version."},"abci":{"type":"object","properties":{"vote_extensions_enable_height":{"type":"string","format":"int64","description":"vote_extensions_enable_height configures the first height during which\nvote extensions will be enabled. During this specified height, and for all\nsubsequent heights, precommit messages that do not contain valid extension data\nwill be considered invalid. Prior to this height, vote extensions will not\nbe used or accepted by validators on the network.\n\nOnce enabled, vote extensions will be created by the application in ExtendVote,\npassed to the application for validation in VerifyVoteExtension and given\nto the application to use when proposing a block during PrepareProposal."}},"description":"ABCIParams configure functionality specific to the Application Blockchain Interface."}}}},"description":"QueryParamsResponse defines the response type for querying x/consensus parameters."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```


# Distribution

## GET /cosmos/distribution/v1beta1/params

> Params queries params of the distribution module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/params":{"get":{"summary":"Params queries params of the distribution module.","operationId":"DistributionParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params defines the parameters of the module.","type":"object","properties":{"community_tax":{"type":"string"},"base_proposer_reward":{"type":"string","description":"Deprecated: The base_proposer_reward field is deprecated and is no longer used\nin the x/distribution module's reward mechanism."},"bonus_proposer_reward":{"type":"string","description":"Deprecated: The bonus_proposer_reward field is deprecated and is no longer used\nin the x/distribution module's reward mechanism."},"withdraw_addr_enabled":{"type":"boolean"}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/delegators/{delegator\_address}/validators

> DelegatorValidators queries the validators of a delegator.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/delegators/{delegator_address}/validators":{"get":{"summary":"DelegatorValidators queries the validators of a delegator.","operationId":"DistributionDelegatorValidators","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"string"},"description":"validators defines the validators a delegator is delegating for."}},"description":"QueryDelegatorValidatorsResponse is the response type for the\nQuery/DelegatorValidators RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"delegator_address","description":"delegator_address defines the delegator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/validators/{validator\_address}

> ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/validators/{validator_address}":{"get":{"summary":"ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator","operationId":"ValidatorDistributionInfo","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"operator_address":{"type":"string","description":"operator_address defines the validator operator address."},"self_bond_rewards":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."},"description":"self_bond_rewards defines the self delegations rewards."},"commission":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."},"description":"commission defines the commission the validator received."}},"description":"QueryValidatorDistributionInfoResponse is the response type for the Query/ValidatorDistributionInfo RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"validator_address","description":"validator_address defines the validator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/community\_pool

> CommunityPool queries the community pool coins.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/community_pool":{"get":{"summary":"CommunityPool queries the community pool coins.","operationId":"CommunityPool","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"pool":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."},"description":"pool defines community pool's coins."}},"description":"QueryCommunityPoolResponse is the response type for the Query/CommunityPool\nRPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/delegators/{delegator\_address}/rewards

> DelegationTotalRewards queries the total rewards accrued by each\
> validator.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards":{"get":{"summary":"DelegationTotalRewards queries the total rewards accrued by each\nvalidator.","operationId":"DelegationTotalRewards","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"rewards":{"type":"array","items":{"type":"object","properties":{"validator_address":{"type":"string"},"reward":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."}}},"description":"DelegationDelegatorReward represents the properties\nof a delegator's delegation reward."},"description":"rewards defines all the rewards accrued by a delegator."},"total":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."},"description":"total defines the sum of all the rewards."}},"description":"QueryDelegationTotalRewardsResponse is the response type for the\nQuery/DelegationTotalRewards RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"delegator_address","description":"delegator_address defines the delegator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/delegators/{delegator\_address}/rewards/{validator\_address}

> DelegationRewards queries the total rewards accrued by a delegation.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards/{validator_address}":{"get":{"summary":"DelegationRewards queries the total rewards accrued by a delegation.","operationId":"DelegationRewards","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"rewards":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."},"description":"rewards defines the rewards accrued by a delegation."}},"description":"QueryDelegationRewardsResponse is the response type for the\nQuery/DelegationRewards RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"delegator_address","description":"delegator_address defines the delegator address to query for.","in":"path","required":true,"type":"string"},{"name":"validator_address","description":"validator_address defines the validator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/delegators/{delegator\_address}/withdraw\_address

> DelegatorWithdrawAddress queries withdraw address of a delegator.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/delegators/{delegator_address}/withdraw_address":{"get":{"summary":"DelegatorWithdrawAddress queries withdraw address of a delegator.","operationId":"DelegatorWithdrawAddress","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"withdraw_address":{"type":"string","description":"withdraw_address defines the delegator address to query for."}},"description":"QueryDelegatorWithdrawAddressResponse is the response type for the\nQuery/DelegatorWithdrawAddress RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"delegator_address","description":"delegator_address defines the delegator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/validators/{validator\_address}/commission

> ValidatorCommission queries accumulated commission for a validator.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/validators/{validator_address}/commission":{"get":{"summary":"ValidatorCommission queries accumulated commission for a validator.","operationId":"ValidatorCommission","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"commission":{"description":"commission defines the commission the validator received.","type":"object","properties":{"commission":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."}}}}},"title":"QueryValidatorCommissionResponse is the response type for the\nQuery/ValidatorCommission RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"validator_address","description":"validator_address defines the validator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/validators/{validator\_address}/outstanding\_rewards

> ValidatorOutstandingRewards queries rewards of a validator address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/validators/{validator_address}/outstanding_rewards":{"get":{"summary":"ValidatorOutstandingRewards queries rewards of a validator address.","operationId":"ValidatorOutstandingRewards","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"rewards":{"type":"object","properties":{"rewards":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"DecCoin defines a token with a denomination and a decimal amount.\n\nNOTE: The amount field is an Dec which implements the custom method\nsignatures required by gogoproto."}}},"description":"ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards\nfor a validator inexpensive to track, allows simple sanity checks."}},"description":"QueryValidatorOutstandingRewardsResponse is the response type for the\nQuery/ValidatorOutstandingRewards RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"validator_address","description":"validator_address defines the validator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/distribution/v1beta1/validators/{validator\_address}/slashes

> ValidatorSlashes queries slash events of a validator.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/distribution/v1beta1/validators/{validator_address}/slashes":{"get":{"summary":"ValidatorSlashes queries slash events of a validator.","operationId":"ValidatorSlashes","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"slashes":{"type":"array","items":{"type":"object","properties":{"validator_period":{"type":"string","format":"uint64"},"fraction":{"type":"string"}},"description":"ValidatorSlashEvent represents a validator slash event.\nHeight is implicit within the store key.\nThis is needed to calculate appropriate amount of staking tokens\nfor delegations which are withdrawn after a slash has occurred."},"description":"slashes defines the slashes the validator received."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryValidatorSlashesResponse is the response type for the\nQuery/ValidatorSlashes RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"validator_address","description":"validator_address defines the validator address to query for.","in":"path","required":true,"type":"string"},{"name":"starting_height","description":"starting_height defines the optional starting height to query the slashes.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"ending_height","description":"starting_height defines the optional ending height to query the slashes.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```


# Evidence

## GET /cosmos/evidence/v1beta1/evidence/{hash}

> Evidence queries evidence based on evidence hash.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evidence/v1beta1/evidence/{hash}":{"get":{"summary":"Evidence queries evidence based on evidence hash.","operationId":"Evidence","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"evidence":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}},"description":"QueryEvidenceResponse is the response type for the Query/Evidence RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"hash","description":"hash defines the evidence hash of the requested evidence.\n\nSince: cosmos-sdk 0.47","in":"path","required":true,"type":"string"},{"name":"evidence_hash","description":"evidence_hash defines the hash of the requested evidence.\nDeprecated: Use hash, a HEX encoded string, instead.","in":"query","required":false,"type":"string","format":"byte"}],"tags":["Query"]}}}}
```

## GET /cosmos/evidence/v1beta1/evidence

> AllEvidence queries all evidence.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/evidence/v1beta1/evidence":{"get":{"summary":"AllEvidence queries all evidence.","operationId":"AllEvidence","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"evidence":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"evidence returns all evidences."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryAllEvidenceResponse is the response type for the Query/AllEvidence RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```


# Feegrant

## AllowancesByGranter returns all the grants given by an address

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/feegrant/v1beta1/issued/{granter}":{"get":{"summary":"AllowancesByGranter returns all the grants given by an address","description":"Since: cosmos-sdk 0.46","operationId":"AllowancesByGranter","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"allowances":{"type":"array","items":{"type":"object","properties":{"granter":{"type":"string","description":"granter is the address of the user granting an allowance of their funds."},"grantee":{"type":"string","description":"grantee is the address of the user being granted an allowance of another user's funds."},"allowance":{"description":"allowance can be any of basic, periodic, allowed fee allowance.","type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}}}},"title":"Grant is stored in the KVStore to record a grant with full context"},"description":"allowances that have been issued by the granter."},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method.\n\nSince: cosmos-sdk 0.46"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"granter","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/feegrant/v1beta1/allowance/{granter}/{grantee}

> Allowance returns granted allwance to the grantee by the granter.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/feegrant/v1beta1/allowance/{granter}/{grantee}":{"get":{"summary":"Allowance returns granted allwance to the grantee by the granter.","operationId":"Allowance","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"allowance":{"description":"allowance is a allowance granted for grantee by granter.","type":"object","properties":{"granter":{"type":"string","description":"granter is the address of the user granting an allowance of their funds."},"grantee":{"type":"string","description":"grantee is the address of the user being granted an allowance of another user's funds."},"allowance":{"description":"allowance can be any of basic, periodic, allowed fee allowance.","type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}}}},"title":"Grant is stored in the KVStore to record a grant with full context"}},"description":"QueryAllowanceResponse is the response type for the Query/Allowance RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"granter","description":"granter is the address of the user granting an allowance of their funds.","in":"path","required":true,"type":"string"},{"name":"grantee","description":"grantee is the address of the user being granted an allowance of another user's funds.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/feegrant/v1beta1/allowances/{grantee}

> Allowances returns all the grants for the given grantee address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/feegrant/v1beta1/allowances/{grantee}":{"get":{"summary":"Allowances returns all the grants for the given grantee address.","operationId":"Allowances","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"allowances":{"type":"array","items":{"type":"object","properties":{"granter":{"type":"string","description":"granter is the address of the user granting an allowance of their funds."},"grantee":{"type":"string","description":"grantee is the address of the user being granted an allowance of another user's funds."},"allowance":{"description":"allowance can be any of basic, periodic, allowed fee allowance.","type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}}}},"title":"Grant is stored in the KVStore to record a grant with full context"},"description":"allowances are allowance's granted for grantee by granter."},"pagination":{"description":"pagination defines an pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryAllowancesResponse is the response type for the Query/Allowances RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"grantee","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```


# Gov

## GET /cosmos/gov/v1beta1/params/{params\_type}

> Params queries all parameters of the gov module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/params/{params_type}":{"get":{"summary":"Params queries all parameters of the gov module.","operationId":"GovParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"voting_params":{"description":"voting_params defines the parameters related to voting.","type":"object","properties":{"voting_period":{"type":"string","description":"Duration of the voting period."}}},"deposit_params":{"description":"deposit_params defines the parameters related to deposit.","type":"object","properties":{"min_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"Minimum deposit for a proposal to enter voting period."},"max_deposit_period":{"type":"string","description":"Maximum period for Atom holders to deposit on a proposal. Initial value: 2\nmonths."}}},"tally_params":{"description":"tally_params defines the parameters related to tally.","type":"object","properties":{"quorum":{"type":"string","format":"byte","description":"Minimum percentage of total stake needed to vote for a result to be\nconsidered valid."},"threshold":{"type":"string","format":"byte","description":"Minimum proportion of Yes votes for proposal to pass. Default value: 0.5."},"veto_threshold":{"type":"string","format":"byte","description":"Minimum value of Veto votes to Total votes ratio for proposal to be\nvetoed. Default value: 1/3."}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"params_type","description":"params_type defines which parameters to query for, can be one of \"voting\",\n\"tallying\" or \"deposit\".","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/params/{params\_type}

> Params queries all parameters of the gov module.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/params/{params_type}":{"get":{"summary":"Params queries all parameters of the gov module.","operationId":"GovV1Params","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"voting_params":{"description":"Deprecated: Prefer to use `params` instead.\nvoting_params defines the parameters related to voting.","type":"object","properties":{"voting_period":{"type":"string","description":"Duration of the voting period."}}},"deposit_params":{"description":"Deprecated: Prefer to use `params` instead.\ndeposit_params defines the parameters related to deposit.","type":"object","properties":{"min_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"Minimum deposit for a proposal to enter voting period."},"max_deposit_period":{"type":"string","description":"Maximum period for Atom holders to deposit on a proposal. Initial value: 2\nmonths."}}},"tally_params":{"description":"Deprecated: Prefer to use `params` instead.\ntally_params defines the parameters related to tally.","type":"object","properties":{"quorum":{"type":"string","description":"Minimum percentage of total stake needed to vote for a result to be\nconsidered valid."},"threshold":{"type":"string","description":"Minimum proportion of Yes votes for proposal to pass. Default value: 0.5."},"veto_threshold":{"type":"string","description":"Minimum value of Veto votes to Total votes ratio for proposal to be\nvetoed. Default value: 1/3."}}},"params":{"description":"params defines all the paramaters of x/gov module.\n\nSince: cosmos-sdk 0.47","type":"object","properties":{"min_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"Minimum deposit for a proposal to enter voting period."},"max_deposit_period":{"type":"string","description":"Maximum period for Atom holders to deposit on a proposal. Initial value: 2\nmonths."},"voting_period":{"type":"string","description":"Duration of the voting period."},"quorum":{"type":"string","description":"Minimum percentage of total stake needed to vote for a result to be\n considered valid."},"threshold":{"type":"string","description":"Minimum proportion of Yes votes for proposal to pass. Default value: 0.5."},"veto_threshold":{"type":"string","description":"Minimum value of Veto votes to Total votes ratio for proposal to be\n vetoed. Default value: 1/3."},"min_initial_deposit_ratio":{"type":"string","description":"The ratio representing the proportion of the deposit value that must be paid at proposal submission."},"proposal_cancel_ratio":{"type":"string","description":"The cancel ratio which will not be returned back to the depositors when a proposal is cancelled.\n\nSince: cosmos-sdk 0.50"},"proposal_cancel_dest":{"type":"string","description":"The address which will receive (proposal_cancel_ratio * deposit) proposal deposits.\nIf empty, the (proposal_cancel_ratio * deposit) proposal deposits will be burned.\n\nSince: cosmos-sdk 0.50"},"expedited_voting_period":{"type":"string","description":"Duration of the voting period of an expedited proposal.\n\nSince: cosmos-sdk 0.50"},"expedited_threshold":{"type":"string","description":"Minimum proportion of Yes votes for proposal to pass. Default value: 0.67.\n\nSince: cosmos-sdk 0.50"},"expedited_min_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"Minimum expedited deposit for a proposal to enter voting period."},"burn_vote_quorum":{"type":"boolean","title":"burn deposits if a proposal does not meet quorum"},"burn_proposal_deposit_prevote":{"type":"boolean","title":"burn deposits if the proposal does not enter voting period"},"burn_vote_veto":{"type":"boolean","title":"burn deposits if quorum with vote type no_veto is met"},"min_deposit_ratio":{"type":"string","description":"The ratio representing the proportion of the deposit value minimum that must be met when making a deposit.\nDefault value: 0.01. Meaning that for a chain with a min_deposit of 100stake, a deposit of 1stake would be\nrequired.\n\nSince: cosmos-sdk 0.50"}}}},"description":"QueryParamsResponse is the response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"params_type","description":"params_type defines which parameters to query for, can be one of \"voting\",\n\"tallying\" or \"deposit\".","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals

> Proposals queries all proposals based on given status.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals":{"get":{"summary":"Proposals queries all proposals based on given status.","operationId":"GovV1Proposal","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"proposals":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uint64","description":"id defines the unique id of the proposal."},"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages are the arbitrary messages to be executed if the proposal passes."},"status":{"description":"status defines the proposal status.","type":"string","enum":["PROPOSAL_STATUS_UNSPECIFIED","PROPOSAL_STATUS_DEPOSIT_PERIOD","PROPOSAL_STATUS_VOTING_PERIOD","PROPOSAL_STATUS_PASSED","PROPOSAL_STATUS_REJECTED","PROPOSAL_STATUS_FAILED"],"default":"PROPOSAL_STATUS_UNSPECIFIED"},"final_tally_result":{"description":"final_tally_result is the final tally result of the proposal. When\nquerying a proposal via gRPC, this field is not populated until the\nproposal's voting period has ended.","type":"object","properties":{"yes_count":{"type":"string","description":"yes_count is the number of yes votes on a proposal."},"abstain_count":{"type":"string","description":"abstain_count is the number of abstain votes on a proposal."},"no_count":{"type":"string","description":"no_count is the number of no votes on a proposal."},"no_with_veto_count":{"type":"string","description":"no_with_veto_count is the number of no with veto votes on a proposal."}}},"submit_time":{"type":"string","format":"date-time","description":"submit_time is the time of proposal submission."},"deposit_end_time":{"type":"string","format":"date-time","description":"deposit_end_time is the end time for deposition."},"total_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"total_deposit is the total deposit on the proposal."},"voting_start_time":{"type":"string","format":"date-time","description":"voting_start_time is the starting time to vote on a proposal."},"voting_end_time":{"type":"string","format":"date-time","description":"voting_end_time is the end time of voting on a proposal."},"metadata":{"type":"string","title":"metadata is any arbitrary metadata attached to the proposal.\nthe recommended format of the metadata is to be found here:\nhttps://docs.cosmos.network/v0.47/modules/gov#proposal-3"},"title":{"type":"string","description":"Since: cosmos-sdk 0.47","title":"title is the title of the proposal"},"summary":{"type":"string","description":"Since: cosmos-sdk 0.47","title":"summary is a short summary of the proposal"},"proposer":{"type":"string","description":"Since: cosmos-sdk 0.47","title":"proposer is the address of the proposal sumbitter"},"expedited":{"type":"boolean","description":"Since: cosmos-sdk 0.50","title":"expedited defines if the proposal is expedited"},"failed_reason":{"type":"string","description":"Since: cosmos-sdk 0.50","title":"failed_reason defines the reason why the proposal failed"}},"description":"Proposal defines the core field members of a governance proposal."},"description":"proposals defines all the requested governance proposals."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryProposalsResponse is the response type for the Query/Proposals RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_status","description":"proposal_status defines the status of the proposals.\n\n - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status.\n - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit\nperiod.\n - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting\nperiod.\n - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has\npassed.\n - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has\nbeen rejected.\n - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has\nfailed.","in":"query","required":false,"type":"string","enum":["PROPOSAL_STATUS_UNSPECIFIED","PROPOSAL_STATUS_DEPOSIT_PERIOD","PROPOSAL_STATUS_VOTING_PERIOD","PROPOSAL_STATUS_PASSED","PROPOSAL_STATUS_REJECTED","PROPOSAL_STATUS_FAILED"],"default":"PROPOSAL_STATUS_UNSPECIFIED"},{"name":"voter","description":"voter defines the voter address for the proposals.","in":"query","required":false,"type":"string"},{"name":"depositor","description":"depositor defines the deposit addresses from the proposals.","in":"query","required":false,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals/{proposal\_id}

> Proposal queries proposal details based on ProposalID.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals/{proposal_id}":{"get":{"summary":"Proposal queries proposal details based on ProposalID.","operationId":"GovV1Proposal","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"proposal":{"type":"object","properties":{"id":{"type":"string","format":"uint64","description":"id defines the unique id of the proposal."},"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages are the arbitrary messages to be executed if the proposal passes."},"status":{"description":"status defines the proposal status.","type":"string","enum":["PROPOSAL_STATUS_UNSPECIFIED","PROPOSAL_STATUS_DEPOSIT_PERIOD","PROPOSAL_STATUS_VOTING_PERIOD","PROPOSAL_STATUS_PASSED","PROPOSAL_STATUS_REJECTED","PROPOSAL_STATUS_FAILED"],"default":"PROPOSAL_STATUS_UNSPECIFIED"},"final_tally_result":{"description":"final_tally_result is the final tally result of the proposal. When\nquerying a proposal via gRPC, this field is not populated until the\nproposal's voting period has ended.","type":"object","properties":{"yes_count":{"type":"string","description":"yes_count is the number of yes votes on a proposal."},"abstain_count":{"type":"string","description":"abstain_count is the number of abstain votes on a proposal."},"no_count":{"type":"string","description":"no_count is the number of no votes on a proposal."},"no_with_veto_count":{"type":"string","description":"no_with_veto_count is the number of no with veto votes on a proposal."}}},"submit_time":{"type":"string","format":"date-time","description":"submit_time is the time of proposal submission."},"deposit_end_time":{"type":"string","format":"date-time","description":"deposit_end_time is the end time for deposition."},"total_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"total_deposit is the total deposit on the proposal."},"voting_start_time":{"type":"string","format":"date-time","description":"voting_start_time is the starting time to vote on a proposal."},"voting_end_time":{"type":"string","format":"date-time","description":"voting_end_time is the end time of voting on a proposal."},"metadata":{"type":"string","title":"metadata is any arbitrary metadata attached to the proposal.\nthe recommended format of the metadata is to be found here:\nhttps://docs.cosmos.network/v0.47/modules/gov#proposal-3"},"title":{"type":"string","description":"Since: cosmos-sdk 0.47","title":"title is the title of the proposal"},"summary":{"type":"string","description":"Since: cosmos-sdk 0.47","title":"summary is a short summary of the proposal"},"proposer":{"type":"string","description":"Since: cosmos-sdk 0.47","title":"proposer is the address of the proposal sumbitter"},"expedited":{"type":"boolean","description":"Since: cosmos-sdk 0.50","title":"expedited defines if the proposal is expedited"},"failed_reason":{"type":"string","description":"Since: cosmos-sdk 0.50","title":"failed_reason defines the reason why the proposal failed"}},"description":"Proposal defines the core field members of a governance proposal."}},"description":"QueryProposalResponse is the response type for the Query/Proposal RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals/{proposal\_id}/deposits

> Deposits queries all deposits of a single proposal.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals/{proposal_id}/deposits":{"get":{"summary":"Deposits queries all deposits of a single proposal.","operationId":"GovV1Deposit","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"deposits":{"type":"array","items":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"depositor":{"type":"string","description":"depositor defines the deposit addresses from the proposals."},"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"amount to be deposited by depositor."}},"description":"Deposit defines an amount deposited by an account address to an active\nproposal."},"description":"deposits defines the requested deposits."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDepositsResponse is the response type for the Query/Deposits RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals/{proposal\_id}/deposits/{depositor}

> Deposit queries single deposit information based on proposalID, depositAddr.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals/{proposal_id}/deposits/{depositor}":{"get":{"summary":"Deposit queries single deposit information based on proposalID, depositAddr.","operationId":"GovV1Deposit","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"deposit":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"depositor":{"type":"string","description":"depositor defines the deposit addresses from the proposals."},"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"amount to be deposited by depositor."}},"description":"Deposit defines an amount deposited by an account address to an active\nproposal."}},"description":"QueryDepositResponse is the response type for the Query/Deposit RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"depositor","description":"depositor defines the deposit addresses from the proposals.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals/{proposal\_id}/tally

> TallyResult queries the tally of a proposal vote.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals/{proposal_id}/tally":{"get":{"summary":"TallyResult queries the tally of a proposal vote.","operationId":"GovV1TallyResult","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"tally":{"description":"tally defines the requested tally.","type":"object","properties":{"yes_count":{"type":"string","description":"yes_count is the number of yes votes on a proposal."},"abstain_count":{"type":"string","description":"abstain_count is the number of abstain votes on a proposal."},"no_count":{"type":"string","description":"no_count is the number of no votes on a proposal."},"no_with_veto_count":{"type":"string","description":"no_with_veto_count is the number of no with veto votes on a proposal."}}}},"description":"QueryTallyResultResponse is the response type for the Query/Tally RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals/{proposal\_id}/votes

> Votes queries votes of a given proposal.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals/{proposal_id}/votes":{"get":{"summary":"Votes queries votes of a given proposal.","operationId":"GovV1Votes","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"votes":{"type":"array","items":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"voter":{"type":"string","description":"voter is the voter address of the proposal."},"options":{"type":"array","items":{"type":"object","properties":{"option":{"description":"option defines the valid vote options, it must not contain duplicate vote options.","type":"string","enum":["VOTE_OPTION_UNSPECIFIED","VOTE_OPTION_YES","VOTE_OPTION_ABSTAIN","VOTE_OPTION_NO","VOTE_OPTION_NO_WITH_VETO"],"default":"VOTE_OPTION_UNSPECIFIED"},"weight":{"type":"string","description":"weight is the vote weight associated with the vote option."}},"description":"WeightedVoteOption defines a unit of vote for vote split."},"description":"options is the weighted vote options."},"metadata":{"type":"string","title":"metadata is any arbitrary metadata attached to the vote.\nthe recommended format of the metadata is to be found here: https://docs.cosmos.network/v0.47/modules/gov#vote-5"}},"description":"Vote defines a vote on a governance proposal.\nA Vote consists of a proposal ID, the voter, and the vote option."},"description":"votes defines the queried votes."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryVotesResponse is the response type for the Query/Votes RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/proposals/{proposal\_id}/votes/{voter}

> Vote queries voted information based on proposalID, voterAddr.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/proposals/{proposal_id}/votes/{voter}":{"get":{"summary":"Vote queries voted information based on proposalID, voterAddr.","operationId":"GovV1Vote","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"vote":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"voter":{"type":"string","description":"voter is the voter address of the proposal."},"options":{"type":"array","items":{"type":"object","properties":{"option":{"description":"option defines the valid vote options, it must not contain duplicate vote options.","type":"string","enum":["VOTE_OPTION_UNSPECIFIED","VOTE_OPTION_YES","VOTE_OPTION_ABSTAIN","VOTE_OPTION_NO","VOTE_OPTION_NO_WITH_VETO"],"default":"VOTE_OPTION_UNSPECIFIED"},"weight":{"type":"string","description":"weight is the vote weight associated with the vote option."}},"description":"WeightedVoteOption defines a unit of vote for vote split."},"description":"options is the weighted vote options."},"metadata":{"type":"string","title":"metadata is any arbitrary metadata attached to the vote.\nthe recommended format of the metadata is to be found here: https://docs.cosmos.network/v0.47/modules/gov#vote-5"}},"description":"Vote defines a vote on a governance proposal.\nA Vote consists of a proposal ID, the voter, and the vote option."}},"description":"QueryVoteResponse is the response type for the Query/Vote RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"voter","description":"voter defines the voter address for the proposals.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals

> Proposals queries all proposals based on given status.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals":{"get":{"summary":"Proposals queries all proposals based on given status.","operationId":"Proposals","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"proposals":{"type":"array","items":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"content":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"status":{"description":"status defines the proposal status.","type":"string","enum":["PROPOSAL_STATUS_UNSPECIFIED","PROPOSAL_STATUS_DEPOSIT_PERIOD","PROPOSAL_STATUS_VOTING_PERIOD","PROPOSAL_STATUS_PASSED","PROPOSAL_STATUS_REJECTED","PROPOSAL_STATUS_FAILED"],"default":"PROPOSAL_STATUS_UNSPECIFIED"},"final_tally_result":{"description":"final_tally_result is the final tally result of the proposal. When\nquerying a proposal via gRPC, this field is not populated until the\nproposal's voting period has ended.","type":"object","properties":{"yes":{"type":"string","description":"yes is the number of yes votes on a proposal."},"abstain":{"type":"string","description":"abstain is the number of abstain votes on a proposal."},"no":{"type":"string","description":"no is the number of no votes on a proposal."},"no_with_veto":{"type":"string","description":"no_with_veto is the number of no with veto votes on a proposal."}}},"submit_time":{"type":"string","format":"date-time","description":"submit_time is the time of proposal submission."},"deposit_end_time":{"type":"string","format":"date-time","description":"deposit_end_time is the end time for deposition."},"total_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"total_deposit is the total deposit on the proposal."},"voting_start_time":{"type":"string","format":"date-time","description":"voting_start_time is the starting time to vote on a proposal."},"voting_end_time":{"type":"string","format":"date-time","description":"voting_end_time is the end time of voting on a proposal."}},"description":"Proposal defines the core field members of a governance proposal."},"description":"proposals defines all the requested governance proposals."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryProposalsResponse is the response type for the Query/Proposals RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_status","description":"proposal_status defines the status of the proposals.\n\n - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status.\n - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit\nperiod.\n - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting\nperiod.\n - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has\npassed.\n - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has\nbeen rejected.\n - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has\nfailed.","in":"query","required":false,"type":"string","enum":["PROPOSAL_STATUS_UNSPECIFIED","PROPOSAL_STATUS_DEPOSIT_PERIOD","PROPOSAL_STATUS_VOTING_PERIOD","PROPOSAL_STATUS_PASSED","PROPOSAL_STATUS_REJECTED","PROPOSAL_STATUS_FAILED"],"default":"PROPOSAL_STATUS_UNSPECIFIED"},{"name":"voter","description":"voter defines the voter address for the proposals.","in":"query","required":false,"type":"string"},{"name":"depositor","description":"depositor defines the deposit addresses from the proposals.","in":"query","required":false,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals/{proposal\_id}

> Proposal queries proposal details based on ProposalID.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals/{proposal_id}":{"get":{"summary":"Proposal queries proposal details based on ProposalID.","operationId":"Proposal","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"proposal":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"content":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"status":{"description":"status defines the proposal status.","type":"string","enum":["PROPOSAL_STATUS_UNSPECIFIED","PROPOSAL_STATUS_DEPOSIT_PERIOD","PROPOSAL_STATUS_VOTING_PERIOD","PROPOSAL_STATUS_PASSED","PROPOSAL_STATUS_REJECTED","PROPOSAL_STATUS_FAILED"],"default":"PROPOSAL_STATUS_UNSPECIFIED"},"final_tally_result":{"description":"final_tally_result is the final tally result of the proposal. When\nquerying a proposal via gRPC, this field is not populated until the\nproposal's voting period has ended.","type":"object","properties":{"yes":{"type":"string","description":"yes is the number of yes votes on a proposal."},"abstain":{"type":"string","description":"abstain is the number of abstain votes on a proposal."},"no":{"type":"string","description":"no is the number of no votes on a proposal."},"no_with_veto":{"type":"string","description":"no_with_veto is the number of no with veto votes on a proposal."}}},"submit_time":{"type":"string","format":"date-time","description":"submit_time is the time of proposal submission."},"deposit_end_time":{"type":"string","format":"date-time","description":"deposit_end_time is the end time for deposition."},"total_deposit":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"total_deposit is the total deposit on the proposal."},"voting_start_time":{"type":"string","format":"date-time","description":"voting_start_time is the starting time to vote on a proposal."},"voting_end_time":{"type":"string","format":"date-time","description":"voting_end_time is the end time of voting on a proposal."}},"description":"Proposal defines the core field members of a governance proposal."}},"description":"QueryProposalResponse is the response type for the Query/Proposal RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals/{proposal\_id}/deposits

> Deposits queries all deposits of a single proposal.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals/{proposal_id}/deposits":{"get":{"summary":"Deposits queries all deposits of a single proposal.","operationId":"Deposits","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"deposits":{"type":"array","items":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"depositor":{"type":"string","description":"depositor defines the deposit addresses from the proposals."},"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"amount to be deposited by depositor."}},"description":"Deposit defines an amount deposited by an account address to an active\nproposal."},"description":"deposits defines the requested deposits."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDepositsResponse is the response type for the Query/Deposits RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals/{proposal\_id}/deposits/{depositor}

> Deposit queries single deposit information based on proposalID, depositor address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals/{proposal_id}/deposits/{depositor}":{"get":{"summary":"Deposit queries single deposit information based on proposalID, depositor address.","operationId":"Deposit","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"deposit":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"depositor":{"type":"string","description":"depositor defines the deposit addresses from the proposals."},"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"description":"amount to be deposited by depositor."}},"description":"Deposit defines an amount deposited by an account address to an active\nproposal."}},"description":"QueryDepositResponse is the response type for the Query/Deposit RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"depositor","description":"depositor defines the deposit addresses from the proposals.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals/{proposal\_id}/tally

> TallyResult queries the tally of a proposal vote.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals/{proposal_id}/tally":{"get":{"summary":"TallyResult queries the tally of a proposal vote.","operationId":"TallyResult","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"tally":{"description":"tally defines the requested tally.","type":"object","properties":{"yes":{"type":"string","description":"yes is the number of yes votes on a proposal."},"abstain":{"type":"string","description":"abstain is the number of abstain votes on a proposal."},"no":{"type":"string","description":"no is the number of no votes on a proposal."},"no_with_veto":{"type":"string","description":"no_with_veto is the number of no with veto votes on a proposal."}}}},"description":"QueryTallyResultResponse is the response type for the Query/Tally RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals/{proposal\_id}/votes

> Votes queries votes of a given proposal.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals/{proposal_id}/votes":{"get":{"summary":"Votes queries votes of a given proposal.","operationId":"Votes","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"votes":{"type":"array","items":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"voter":{"type":"string","description":"voter is the voter address of the proposal."},"option":{"description":"Deprecated: Prefer to use `options` instead. This field is set in queries\nif and only if `len(options) == 1` and that option has weight 1. In all\nother cases, this field will default to VOTE_OPTION_UNSPECIFIED.","type":"string","enum":["VOTE_OPTION_UNSPECIFIED","VOTE_OPTION_YES","VOTE_OPTION_ABSTAIN","VOTE_OPTION_NO","VOTE_OPTION_NO_WITH_VETO"],"default":"VOTE_OPTION_UNSPECIFIED"},"options":{"type":"array","items":{"type":"object","properties":{"option":{"description":"option defines the valid vote options, it must not contain duplicate vote options.","type":"string","enum":["VOTE_OPTION_UNSPECIFIED","VOTE_OPTION_YES","VOTE_OPTION_ABSTAIN","VOTE_OPTION_NO","VOTE_OPTION_NO_WITH_VETO"],"default":"VOTE_OPTION_UNSPECIFIED"},"weight":{"type":"string","description":"weight is the vote weight associated with the vote option."}},"description":"WeightedVoteOption defines a unit of vote for vote split.\n\nSince: cosmos-sdk 0.43"},"description":"options is the weighted vote options.\n\nSince: cosmos-sdk 0.43"}},"description":"Vote defines a vote on a governance proposal.\nA Vote consists of a proposal ID, the voter, and the vote option."},"description":"votes defines the queried votes."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryVotesResponse is the response type for the Query/Votes RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1beta1/proposals/{proposal\_id}/votes/{voter}

> Vote queries voted information based on proposalID, voterAddr.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1beta1/proposals/{proposal_id}/votes/{voter}":{"get":{"summary":"Vote queries voted information based on proposalID, voterAddr.","operationId":"Vote","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"vote":{"type":"object","properties":{"proposal_id":{"type":"string","format":"uint64","description":"proposal_id defines the unique id of the proposal."},"voter":{"type":"string","description":"voter is the voter address of the proposal."},"option":{"description":"Deprecated: Prefer to use `options` instead. This field is set in queries\nif and only if `len(options) == 1` and that option has weight 1. In all\nother cases, this field will default to VOTE_OPTION_UNSPECIFIED.","type":"string","enum":["VOTE_OPTION_UNSPECIFIED","VOTE_OPTION_YES","VOTE_OPTION_ABSTAIN","VOTE_OPTION_NO","VOTE_OPTION_NO_WITH_VETO"],"default":"VOTE_OPTION_UNSPECIFIED"},"options":{"type":"array","items":{"type":"object","properties":{"option":{"description":"option defines the valid vote options, it must not contain duplicate vote options.","type":"string","enum":["VOTE_OPTION_UNSPECIFIED","VOTE_OPTION_YES","VOTE_OPTION_ABSTAIN","VOTE_OPTION_NO","VOTE_OPTION_NO_WITH_VETO"],"default":"VOTE_OPTION_UNSPECIFIED"},"weight":{"type":"string","description":"weight is the vote weight associated with the vote option."}},"description":"WeightedVoteOption defines a unit of vote for vote split.\n\nSince: cosmos-sdk 0.43"},"description":"options is the weighted vote options.\n\nSince: cosmos-sdk 0.43"}},"description":"Vote defines a vote on a governance proposal.\nA Vote consists of a proposal ID, the voter, and the vote option."}},"description":"QueryVoteResponse is the response type for the Query/Vote RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"proposal_id","description":"proposal_id defines the unique id of the proposal.","in":"path","required":true,"type":"string","format":"uint64"},{"name":"voter","description":"voter defines the voter address for the proposals.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/gov/v1/constitution

> Constitution queries the chain's constitution.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/gov/v1/constitution":{"get":{"summary":"Constitution queries the chain's constitution.","operationId":"Constitution","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"constitution":{"type":"string"}},"title":"QueryConstitutionResponse is the response type for the Query/Constitution RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```


# Slashing

## GET /cosmos/slashing/v1beta1/params

> Params queries the parameters of slashing module

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/slashing/v1beta1/params":{"get":{"summary":"Params queries the parameters of slashing module","operationId":"SlashingParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"type":"object","properties":{"signed_blocks_window":{"type":"string","format":"int64"},"min_signed_per_window":{"type":"string","format":"byte"},"downtime_jail_duration":{"type":"string"},"slash_fraction_double_sign":{"type":"string","format":"byte"},"slash_fraction_downtime":{"type":"string","format":"byte"}},"description":"Params represents the parameters used for by the slashing module."}},"title":"QueryParamsResponse is the response type for the Query/Params RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/slashing/v1beta1/signing\_infos

> SigningInfos queries signing info of all validators

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/slashing/v1beta1/signing_infos":{"get":{"summary":"SigningInfos queries signing info of all validators","operationId":"SigningInfos","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"info":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string"},"start_height":{"type":"string","format":"int64","title":"Height at which validator was first a candidate OR was un-jailed"},"index_offset":{"type":"string","format":"int64","description":"Index which is incremented every time a validator is bonded in a block and\n_may_ have signed a pre-commit or not. This in conjunction with the\nsigned_blocks_window param determines the index in the missed block bitmap."},"jailed_until":{"type":"string","format":"date-time","description":"Timestamp until which the validator is jailed due to liveness downtime."},"tombstoned":{"type":"boolean","description":"Whether or not a validator has been tombstoned (killed out of validator\nset). It is set once the validator commits an equivocation or for any other\nconfigured misbehavior."},"missed_blocks_counter":{"type":"string","format":"int64","description":"A counter of missed (unsigned) blocks. It is used to avoid unnecessary\nreads in the missed block bitmap."}},"description":"ValidatorSigningInfo defines a validator's signing info for monitoring their\nliveness activity."},"title":"info is the signing info of all validators"},"pagination":{"type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}},"description":"PageResponse is to be embedded in gRPC response messages where the\ncorresponding request message has used PageRequest.\n\n message SomeResponse {\n         repeated Bar results = 1;\n         PageResponse page = 2;\n }"}},"title":"QuerySigningInfosResponse is the response type for the Query/SigningInfos RPC\nmethod"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/slashing/v1beta1/signing\_infos/{cons\_address}

> SigningInfo queries the signing info of given cons address

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/slashing/v1beta1/signing_infos/{cons_address}":{"get":{"summary":"SigningInfo queries the signing info of given cons address","operationId":"SigningInfo","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"val_signing_info":{"type":"object","properties":{"address":{"type":"string"},"start_height":{"type":"string","format":"int64","title":"Height at which validator was first a candidate OR was un-jailed"},"index_offset":{"type":"string","format":"int64","description":"Index which is incremented every time a validator is bonded in a block and\n_may_ have signed a pre-commit or not. This in conjunction with the\nsigned_blocks_window param determines the index in the missed block bitmap."},"jailed_until":{"type":"string","format":"date-time","description":"Timestamp until which the validator is jailed due to liveness downtime."},"tombstoned":{"type":"boolean","description":"Whether or not a validator has been tombstoned (killed out of validator\nset). It is set once the validator commits an equivocation or for any other\nconfigured misbehavior."},"missed_blocks_counter":{"type":"string","format":"int64","description":"A counter of missed (unsigned) blocks. It is used to avoid unnecessary\nreads in the missed block bitmap."}},"description":"ValidatorSigningInfo defines a validator's signing info for monitoring their\nliveness activity.","title":"val_signing_info is the signing info of requested val cons address"}},"title":"QuerySigningInfoResponse is the response type for the Query/SigningInfo RPC\nmethod"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string"},"value":{"type":"string","format":"byte"}}}}}}}}}},"parameters":[{"name":"cons_address","description":"cons_address is the address to query signing info of","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```


# Staking

## GET /cosmos/staking/v1beta1/params

> Parameters queries the staking parameters.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/params":{"get":{"summary":"Parameters queries the staking parameters.","operationId":"StakingParams","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"params":{"description":"params holds all the parameters of this module.","type":"object","properties":{"unbonding_time":{"type":"string","description":"unbonding_time is the time duration of unbonding."},"max_validators":{"type":"integer","format":"int64","description":"max_validators is the maximum number of validators."},"max_entries":{"type":"integer","format":"int64","description":"max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio)."},"historical_entries":{"type":"integer","format":"int64","description":"historical_entries is the number of historical entries to persist."},"bond_denom":{"type":"string","description":"bond_denom defines the bondable coin denomination."},"min_commission_rate":{"type":"string","title":"min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators"}}}},"description":"QueryParamsResponse is response type for the Query/Params RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## DelegatorDelegations queries all delegations of a given delegator address.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/delegations/{delegator_addr}":{"get":{"summary":"DelegatorDelegations queries all delegations of a given delegator address.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"DelegatorDelegations","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"delegation_responses":{"type":"array","items":{"type":"object","properties":{"delegation":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the encoded address of the delegator."},"validator_address":{"type":"string","description":"validator_address is the encoded address of the validator."},"shares":{"type":"string","description":"shares define the delegation shares received."}},"description":"Delegation represents the bond with tokens held by an account. It is\nowned by one delegator, and is associated with the voting power of one\nvalidator."},"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"DelegationResponse is equivalent to Delegation except that it contains a\nbalance in addition to shares which is more suitable for client responses."},"description":"delegation_responses defines all the delegations' info of a delegator."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDelegatorDelegationsResponse is response type for the\nQuery/DelegatorDelegations RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## Redelegations queries redelegations of given address.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/delegators/{delegator_addr}/redelegations":{"get":{"summary":"Redelegations queries redelegations of given address.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"Redelegations","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"redelegation_responses":{"type":"array","items":{"type":"object","properties":{"redelegation":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the bech32-encoded address of the delegator."},"validator_src_address":{"type":"string","description":"validator_src_address is the validator redelegation source operator address."},"validator_dst_address":{"type":"string","description":"validator_dst_address is the validator redelegation destination operator address."},"entries":{"type":"array","items":{"type":"object","properties":{"creation_height":{"type":"string","format":"int64","description":"creation_height  defines the height which the redelegation took place."},"completion_time":{"type":"string","format":"date-time","description":"completion_time defines the unix time for redelegation completion."},"initial_balance":{"type":"string","description":"initial_balance defines the initial balance when redelegation started."},"shares_dst":{"type":"string","description":"shares_dst is the amount of destination-validator shares created by redelegation."},"unbonding_id":{"type":"string","format":"uint64","title":"Incrementing id that uniquely identifies this entry"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"Strictly positive if this entry's unbonding has been stopped by external modules"}},"description":"RedelegationEntry defines a redelegation object with relevant metadata."},"description":"entries are the redelegation entries."}},"description":"Redelegation contains the list of a particular delegator's redelegating bonds\nfrom a particular source validator to a particular destination validator."},"entries":{"type":"array","items":{"type":"object","properties":{"redelegation_entry":{"type":"object","properties":{"creation_height":{"type":"string","format":"int64","description":"creation_height  defines the height which the redelegation took place."},"completion_time":{"type":"string","format":"date-time","description":"completion_time defines the unix time for redelegation completion."},"initial_balance":{"type":"string","description":"initial_balance defines the initial balance when redelegation started."},"shares_dst":{"type":"string","description":"shares_dst is the amount of destination-validator shares created by redelegation."},"unbonding_id":{"type":"string","format":"uint64","title":"Incrementing id that uniquely identifies this entry"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"Strictly positive if this entry's unbonding has been stopped by external modules"}},"description":"RedelegationEntry defines a redelegation object with relevant metadata."},"balance":{"type":"string"}},"description":"RedelegationEntryResponse is equivalent to a RedelegationEntry except that it\ncontains a balance in addition to shares which is more suitable for client\nresponses."}}},"description":"RedelegationResponse is equivalent to a Redelegation except that its entries\ncontain a balance in addition to shares which is more suitable for client\nresponses."}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryRedelegationsResponse is response type for the Query/Redelegations RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"},{"name":"src_validator_addr","description":"src_validator_addr defines the validator address to redelegate from.","in":"query","required":false,"type":"string"},{"name":"dst_validator_addr","description":"dst_validator_addr defines the validator address to redelegate to.","in":"query","required":false,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

DelegatorUnbondingDelegations queries all unbonding delegations of a given\
delegator address.
------------------

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/delegators/{delegator_addr}/unbonding_delegations":{"get":{"summary":"DelegatorUnbondingDelegations queries all unbonding delegations of a given\ndelegator address.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"DelegatorUnbondingDelegations","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"unbonding_responses":{"type":"array","items":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the encoded address of the delegator."},"validator_address":{"type":"string","description":"validator_address is the encoded address of the validator."},"entries":{"type":"array","items":{"type":"object","properties":{"creation_height":{"type":"string","format":"int64","description":"creation_height is the height which the unbonding took place."},"completion_time":{"type":"string","format":"date-time","description":"completion_time is the unix time for unbonding completion."},"initial_balance":{"type":"string","description":"initial_balance defines the tokens initially scheduled to receive at completion."},"balance":{"type":"string","description":"balance defines the tokens to receive at completion."},"unbonding_id":{"type":"string","format":"uint64","title":"Incrementing id that uniquely identifies this entry"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"Strictly positive if this entry's unbonding has been stopped by external modules"}},"description":"UnbondingDelegationEntry defines an unbonding object with relevant metadata."},"description":"entries are the unbonding delegation entries."}},"description":"UnbondingDelegation stores all of a single delegator's unbonding bonds\nfor a single validator in an time-ordered list."}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryUnbondingDelegatorDelegationsResponse is response type for the\nQuery/UnbondingDelegatorDelegations RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

DelegatorValidators queries all validators info for given delegator\
address.
--------

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/delegators/{delegator_addr}/validators":{"get":{"summary":"DelegatorValidators queries all validators info for given delegator\naddress.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"DelegatorValidators","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"operator_address":{"type":"string","description":"operator_address defines the address of the validator's operator; bech encoded in JSON."},"consensus_pubkey":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"jailed":{"type":"boolean","description":"jailed defined whether the validator has been jailed from bonded status or not."},"status":{"description":"status is the validator status (bonded/unbonding/unbonded).","type":"string","enum":["BOND_STATUS_UNSPECIFIED","BOND_STATUS_UNBONDED","BOND_STATUS_UNBONDING","BOND_STATUS_BONDED"],"default":"BOND_STATUS_UNSPECIFIED"},"tokens":{"type":"string","description":"tokens define the delegated tokens (incl. self-delegation)."},"delegator_shares":{"type":"string","description":"delegator_shares defines total shares issued to a validator's delegators."},"description":{"description":"description defines the description terms for the validator.","type":"object","properties":{"moniker":{"type":"string","description":"moniker defines a human-readable name for the validator."},"identity":{"type":"string","description":"identity defines an optional identity signature (ex. UPort or Keybase)."},"website":{"type":"string","description":"website defines an optional website link."},"security_contact":{"type":"string","description":"security_contact defines an optional email for security contact."},"details":{"type":"string","description":"details define other optional details."}}},"unbonding_height":{"type":"string","format":"int64","description":"unbonding_height defines, if unbonding, the height at which this validator has begun unbonding."},"unbonding_time":{"type":"string","format":"date-time","description":"unbonding_time defines, if unbonding, the min time for the validator to complete unbonding."},"commission":{"description":"commission defines the commission parameters.","type":"object","properties":{"commission_rates":{"description":"commission_rates defines the initial commission rates to be used for creating a validator.","type":"object","properties":{"rate":{"type":"string","description":"rate is the commission rate charged to delegators, as a fraction."},"max_rate":{"type":"string","description":"max_rate defines the maximum commission rate which validator can ever charge, as a fraction."},"max_change_rate":{"type":"string","description":"max_change_rate defines the maximum daily increase of the validator commission, as a fraction."}}},"update_time":{"type":"string","format":"date-time","description":"update_time is the last time the commission rate was changed."}}},"min_self_delegation":{"type":"string","description":"min_self_delegation is the validator's self declared minimum self delegation.\n\nSince: cosmos-sdk 0.46"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"strictly positive if this validator's unbonding has been stopped by external modules"},"unbonding_ids":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unbonding ids, each uniquely identifing an unbonding of this validator"}},"description":"Validator defines a validator, together with the total amount of the\nValidator's bond shares and their exchange rate to coins. Slashing results in\na decrease in the exchange rate, allowing correct calculation of future\nundelegations without iterating over delegators. When coins are delegated to\nthis validator, the validator is credited with a delegation whose number of\nbond shares is based on the amount of coins delegated divided by the current\nexchange rate. Voting power can be calculated as total bonded shares\nmultiplied by exchange rate."},"description":"validators defines the validators' info of a delegator."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryDelegatorValidatorsResponse is response type for the\nQuery/DelegatorValidators RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/staking/v1beta1/delegators/{delegator\_addr}/validators/{validator\_addr}

> DelegatorValidator queries validator info for given delegator validator\
> pair.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/delegators/{delegator_addr}/validators/{validator_addr}":{"get":{"summary":"DelegatorValidator queries validator info for given delegator validator\npair.","operationId":"DelegatorValidator","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"validator":{"type":"object","properties":{"operator_address":{"type":"string","description":"operator_address defines the address of the validator's operator; bech encoded in JSON."},"consensus_pubkey":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"jailed":{"type":"boolean","description":"jailed defined whether the validator has been jailed from bonded status or not."},"status":{"description":"status is the validator status (bonded/unbonding/unbonded).","type":"string","enum":["BOND_STATUS_UNSPECIFIED","BOND_STATUS_UNBONDED","BOND_STATUS_UNBONDING","BOND_STATUS_BONDED"],"default":"BOND_STATUS_UNSPECIFIED"},"tokens":{"type":"string","description":"tokens define the delegated tokens (incl. self-delegation)."},"delegator_shares":{"type":"string","description":"delegator_shares defines total shares issued to a validator's delegators."},"description":{"description":"description defines the description terms for the validator.","type":"object","properties":{"moniker":{"type":"string","description":"moniker defines a human-readable name for the validator."},"identity":{"type":"string","description":"identity defines an optional identity signature (ex. UPort or Keybase)."},"website":{"type":"string","description":"website defines an optional website link."},"security_contact":{"type":"string","description":"security_contact defines an optional email for security contact."},"details":{"type":"string","description":"details define other optional details."}}},"unbonding_height":{"type":"string","format":"int64","description":"unbonding_height defines, if unbonding, the height at which this validator has begun unbonding."},"unbonding_time":{"type":"string","format":"date-time","description":"unbonding_time defines, if unbonding, the min time for the validator to complete unbonding."},"commission":{"description":"commission defines the commission parameters.","type":"object","properties":{"commission_rates":{"description":"commission_rates defines the initial commission rates to be used for creating a validator.","type":"object","properties":{"rate":{"type":"string","description":"rate is the commission rate charged to delegators, as a fraction."},"max_rate":{"type":"string","description":"max_rate defines the maximum commission rate which validator can ever charge, as a fraction."},"max_change_rate":{"type":"string","description":"max_change_rate defines the maximum daily increase of the validator commission, as a fraction."}}},"update_time":{"type":"string","format":"date-time","description":"update_time is the last time the commission rate was changed."}}},"min_self_delegation":{"type":"string","description":"min_self_delegation is the validator's self declared minimum self delegation.\n\nSince: cosmos-sdk 0.46"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"strictly positive if this validator's unbonding has been stopped by external modules"},"unbonding_ids":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unbonding ids, each uniquely identifing an unbonding of this validator"}},"description":"Validator defines a validator, together with the total amount of the\nValidator's bond shares and their exchange rate to coins. Slashing results in\na decrease in the exchange rate, allowing correct calculation of future\nundelegations without iterating over delegators. When coins are delegated to\nthis validator, the validator is credited with a delegation whose number of\nbond shares is based on the amount of coins delegated divided by the current\nexchange rate. Voting power can be calculated as total bonded shares\nmultiplied by exchange rate."}},"description":"QueryDelegatorValidatorResponse response type for the\nQuery/DelegatorValidator RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"},{"name":"validator_addr","description":"validator_addr defines the validator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/staking/v1beta1/historical\_info/{height}

> HistoricalInfo queries the historical info for given height.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/historical_info/{height}":{"get":{"summary":"HistoricalInfo queries the historical info for given height.","operationId":"HistoricalInfo","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"hist":{"description":"hist defines the historical info at the given height.","type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"title":"prev block info","type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}}},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"valset":{"type":"array","items":{"type":"object","properties":{"operator_address":{"type":"string","description":"operator_address defines the address of the validator's operator; bech encoded in JSON."},"consensus_pubkey":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"jailed":{"type":"boolean","description":"jailed defined whether the validator has been jailed from bonded status or not."},"status":{"description":"status is the validator status (bonded/unbonding/unbonded).","type":"string","enum":["BOND_STATUS_UNSPECIFIED","BOND_STATUS_UNBONDED","BOND_STATUS_UNBONDING","BOND_STATUS_BONDED"],"default":"BOND_STATUS_UNSPECIFIED"},"tokens":{"type":"string","description":"tokens define the delegated tokens (incl. self-delegation)."},"delegator_shares":{"type":"string","description":"delegator_shares defines total shares issued to a validator's delegators."},"description":{"description":"description defines the description terms for the validator.","type":"object","properties":{"moniker":{"type":"string","description":"moniker defines a human-readable name for the validator."},"identity":{"type":"string","description":"identity defines an optional identity signature (ex. UPort or Keybase)."},"website":{"type":"string","description":"website defines an optional website link."},"security_contact":{"type":"string","description":"security_contact defines an optional email for security contact."},"details":{"type":"string","description":"details define other optional details."}}},"unbonding_height":{"type":"string","format":"int64","description":"unbonding_height defines, if unbonding, the height at which this validator has begun unbonding."},"unbonding_time":{"type":"string","format":"date-time","description":"unbonding_time defines, if unbonding, the min time for the validator to complete unbonding."},"commission":{"description":"commission defines the commission parameters.","type":"object","properties":{"commission_rates":{"description":"commission_rates defines the initial commission rates to be used for creating a validator.","type":"object","properties":{"rate":{"type":"string","description":"rate is the commission rate charged to delegators, as a fraction."},"max_rate":{"type":"string","description":"max_rate defines the maximum commission rate which validator can ever charge, as a fraction."},"max_change_rate":{"type":"string","description":"max_change_rate defines the maximum daily increase of the validator commission, as a fraction."}}},"update_time":{"type":"string","format":"date-time","description":"update_time is the last time the commission rate was changed."}}},"min_self_delegation":{"type":"string","description":"min_self_delegation is the validator's self declared minimum self delegation.\n\nSince: cosmos-sdk 0.46"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"strictly positive if this validator's unbonding has been stopped by external modules"},"unbonding_ids":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unbonding ids, each uniquely identifing an unbonding of this validator"}},"description":"Validator defines a validator, together with the total amount of the\nValidator's bond shares and their exchange rate to coins. Slashing results in\na decrease in the exchange rate, allowing correct calculation of future\nundelegations without iterating over delegators. When coins are delegated to\nthis validator, the validator is credited with a delegation whose number of\nbond shares is based on the amount of coins delegated divided by the current\nexchange rate. Voting power can be calculated as total bonded shares\nmultiplied by exchange rate."}}}}},"description":"QueryHistoricalInfoResponse is response type for the Query/HistoricalInfo RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"height","description":"height defines at which height to query the historical info.","in":"path","required":true,"type":"string","format":"int64"}],"tags":["Query"]}}}}
```

## GET /cosmos/staking/v1beta1/pool

> Pool queries the pool info.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/pool":{"get":{"summary":"Pool queries the pool info.","operationId":"Pool","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"pool":{"description":"pool defines the pool info.","type":"object","properties":{"not_bonded_tokens":{"type":"string"},"bonded_tokens":{"type":"string"}}}},"description":"QueryPoolResponse is response type for the Query/Pool RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## Validators queries all validators that match the given status.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/validators":{"get":{"summary":"Validators queries all validators that match the given status.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"Validators","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"operator_address":{"type":"string","description":"operator_address defines the address of the validator's operator; bech encoded in JSON."},"consensus_pubkey":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"jailed":{"type":"boolean","description":"jailed defined whether the validator has been jailed from bonded status or not."},"status":{"description":"status is the validator status (bonded/unbonding/unbonded).","type":"string","enum":["BOND_STATUS_UNSPECIFIED","BOND_STATUS_UNBONDED","BOND_STATUS_UNBONDING","BOND_STATUS_BONDED"],"default":"BOND_STATUS_UNSPECIFIED"},"tokens":{"type":"string","description":"tokens define the delegated tokens (incl. self-delegation)."},"delegator_shares":{"type":"string","description":"delegator_shares defines total shares issued to a validator's delegators."},"description":{"description":"description defines the description terms for the validator.","type":"object","properties":{"moniker":{"type":"string","description":"moniker defines a human-readable name for the validator."},"identity":{"type":"string","description":"identity defines an optional identity signature (ex. UPort or Keybase)."},"website":{"type":"string","description":"website defines an optional website link."},"security_contact":{"type":"string","description":"security_contact defines an optional email for security contact."},"details":{"type":"string","description":"details define other optional details."}}},"unbonding_height":{"type":"string","format":"int64","description":"unbonding_height defines, if unbonding, the height at which this validator has begun unbonding."},"unbonding_time":{"type":"string","format":"date-time","description":"unbonding_time defines, if unbonding, the min time for the validator to complete unbonding."},"commission":{"description":"commission defines the commission parameters.","type":"object","properties":{"commission_rates":{"description":"commission_rates defines the initial commission rates to be used for creating a validator.","type":"object","properties":{"rate":{"type":"string","description":"rate is the commission rate charged to delegators, as a fraction."},"max_rate":{"type":"string","description":"max_rate defines the maximum commission rate which validator can ever charge, as a fraction."},"max_change_rate":{"type":"string","description":"max_change_rate defines the maximum daily increase of the validator commission, as a fraction."}}},"update_time":{"type":"string","format":"date-time","description":"update_time is the last time the commission rate was changed."}}},"min_self_delegation":{"type":"string","description":"min_self_delegation is the validator's self declared minimum self delegation.\n\nSince: cosmos-sdk 0.46"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"strictly positive if this validator's unbonding has been stopped by external modules"},"unbonding_ids":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unbonding ids, each uniquely identifing an unbonding of this validator"}},"description":"Validator defines a validator, together with the total amount of the\nValidator's bond shares and their exchange rate to coins. Slashing results in\na decrease in the exchange rate, allowing correct calculation of future\nundelegations without iterating over delegators. When coins are delegated to\nthis validator, the validator is credited with a delegation whose number of\nbond shares is based on the amount of coins delegated divided by the current\nexchange rate. Voting power can be calculated as total bonded shares\nmultiplied by exchange rate."},"description":"validators contains all the queried validators."},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryValidatorsResponse is response type for the Query/Validators RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"status","description":"status enables to query for validators matching a given status.","in":"query","required":false,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/staking/v1beta1/validators/{validator\_addr}

> Validator queries validator info for given validator address.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/validators/{validator_addr}":{"get":{"summary":"Validator queries validator info for given validator address.","operationId":"Validator","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"validator":{"type":"object","properties":{"operator_address":{"type":"string","description":"operator_address defines the address of the validator's operator; bech encoded in JSON."},"consensus_pubkey":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"jailed":{"type":"boolean","description":"jailed defined whether the validator has been jailed from bonded status or not."},"status":{"description":"status is the validator status (bonded/unbonding/unbonded).","type":"string","enum":["BOND_STATUS_UNSPECIFIED","BOND_STATUS_UNBONDED","BOND_STATUS_UNBONDING","BOND_STATUS_BONDED"],"default":"BOND_STATUS_UNSPECIFIED"},"tokens":{"type":"string","description":"tokens define the delegated tokens (incl. self-delegation)."},"delegator_shares":{"type":"string","description":"delegator_shares defines total shares issued to a validator's delegators."},"description":{"description":"description defines the description terms for the validator.","type":"object","properties":{"moniker":{"type":"string","description":"moniker defines a human-readable name for the validator."},"identity":{"type":"string","description":"identity defines an optional identity signature (ex. UPort or Keybase)."},"website":{"type":"string","description":"website defines an optional website link."},"security_contact":{"type":"string","description":"security_contact defines an optional email for security contact."},"details":{"type":"string","description":"details define other optional details."}}},"unbonding_height":{"type":"string","format":"int64","description":"unbonding_height defines, if unbonding, the height at which this validator has begun unbonding."},"unbonding_time":{"type":"string","format":"date-time","description":"unbonding_time defines, if unbonding, the min time for the validator to complete unbonding."},"commission":{"description":"commission defines the commission parameters.","type":"object","properties":{"commission_rates":{"description":"commission_rates defines the initial commission rates to be used for creating a validator.","type":"object","properties":{"rate":{"type":"string","description":"rate is the commission rate charged to delegators, as a fraction."},"max_rate":{"type":"string","description":"max_rate defines the maximum commission rate which validator can ever charge, as a fraction."},"max_change_rate":{"type":"string","description":"max_change_rate defines the maximum daily increase of the validator commission, as a fraction."}}},"update_time":{"type":"string","format":"date-time","description":"update_time is the last time the commission rate was changed."}}},"min_self_delegation":{"type":"string","description":"min_self_delegation is the validator's self declared minimum self delegation.\n\nSince: cosmos-sdk 0.46"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"strictly positive if this validator's unbonding has been stopped by external modules"},"unbonding_ids":{"type":"array","items":{"type":"string","format":"uint64"},"title":"list of unbonding ids, each uniquely identifing an unbonding of this validator"}},"description":"Validator defines a validator, together with the total amount of the\nValidator's bond shares and their exchange rate to coins. Slashing results in\na decrease in the exchange rate, allowing correct calculation of future\nundelegations without iterating over delegators. When coins are delegated to\nthis validator, the validator is credited with a delegation whose number of\nbond shares is based on the amount of coins delegated divided by the current\nexchange rate. Voting power can be calculated as total bonded shares\nmultiplied by exchange rate."}},"title":"QueryValidatorResponse is response type for the Query/Validator RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"validator_addr","description":"validator_addr defines the validator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## ValidatorDelegations queries delegate info for given validator.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/validators/{validator_addr}/delegations":{"get":{"summary":"ValidatorDelegations queries delegate info for given validator.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"ValidatorDelegations","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"delegation_responses":{"type":"array","items":{"type":"object","properties":{"delegation":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the encoded address of the delegator."},"validator_address":{"type":"string","description":"validator_address is the encoded address of the validator."},"shares":{"type":"string","description":"shares define the delegation shares received."}},"description":"Delegation represents the bond with tokens held by an account. It is\nowned by one delegator, and is associated with the voting power of one\nvalidator."},"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"DelegationResponse is equivalent to Delegation except that it contains a\nbalance in addition to shares which is more suitable for client responses."}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"title":"QueryValidatorDelegationsResponse is response type for the\nQuery/ValidatorDelegations RPC method"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"validator_addr","description":"validator_addr defines the validator address to query for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```

## GET /cosmos/staking/v1beta1/validators/{validator\_addr}/delegations/{delegator\_addr}

> Delegation queries delegate info for given validator delegator pair.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/validators/{validator_addr}/delegations/{delegator_addr}":{"get":{"summary":"Delegation queries delegate info for given validator delegator pair.","operationId":"Delegation","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"delegation_response":{"type":"object","properties":{"delegation":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the encoded address of the delegator."},"validator_address":{"type":"string","description":"validator_address is the encoded address of the validator."},"shares":{"type":"string","description":"shares define the delegation shares received."}},"description":"Delegation represents the bond with tokens held by an account. It is\nowned by one delegator, and is associated with the voting power of one\nvalidator."},"balance":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."}},"description":"DelegationResponse is equivalent to Delegation except that it contains a\nbalance in addition to shares which is more suitable for client responses."}},"description":"QueryDelegationResponse is response type for the Query/Delegation RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"validator_addr","description":"validator_addr defines the validator address to query for.","in":"path","required":true,"type":"string"},{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## GET /cosmos/staking/v1beta1/validators/{validator\_addr}/delegations/{delegator\_addr}/unbonding\_delegation

> UnbondingDelegation queries unbonding info for given validator delegator\
> pair.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/validators/{validator_addr}/delegations/{delegator_addr}/unbonding_delegation":{"get":{"summary":"UnbondingDelegation queries unbonding info for given validator delegator\npair.","operationId":"UnbondingDelegation","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"unbond":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the encoded address of the delegator."},"validator_address":{"type":"string","description":"validator_address is the encoded address of the validator."},"entries":{"type":"array","items":{"type":"object","properties":{"creation_height":{"type":"string","format":"int64","description":"creation_height is the height which the unbonding took place."},"completion_time":{"type":"string","format":"date-time","description":"completion_time is the unix time for unbonding completion."},"initial_balance":{"type":"string","description":"initial_balance defines the tokens initially scheduled to receive at completion."},"balance":{"type":"string","description":"balance defines the tokens to receive at completion."},"unbonding_id":{"type":"string","format":"uint64","title":"Incrementing id that uniquely identifies this entry"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"Strictly positive if this entry's unbonding has been stopped by external modules"}},"description":"UnbondingDelegationEntry defines an unbonding object with relevant metadata."},"description":"entries are the unbonding delegation entries."}},"description":"UnbondingDelegation stores all of a single delegator's unbonding bonds\nfor a single validator in an time-ordered list."}},"description":"QueryDelegationResponse is response type for the Query/UnbondingDelegation\nRPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"validator_addr","description":"validator_addr defines the validator address to query for.","in":"path","required":true,"type":"string"},{"name":"delegator_addr","description":"delegator_addr defines the delegator address to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## ValidatorUnbondingDelegations queries unbonding delegations of a validator.

> When called from another module, this query might consume a high amount of\
> gas if the pagination field is incorrectly set.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/staking/v1beta1/validators/{validator_addr}/unbonding_delegations":{"get":{"summary":"ValidatorUnbondingDelegations queries unbonding delegations of a validator.","description":"When called from another module, this query might consume a high amount of\ngas if the pagination field is incorrectly set.","operationId":"ValidatorUnbondingDelegations","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"unbonding_responses":{"type":"array","items":{"type":"object","properties":{"delegator_address":{"type":"string","description":"delegator_address is the encoded address of the delegator."},"validator_address":{"type":"string","description":"validator_address is the encoded address of the validator."},"entries":{"type":"array","items":{"type":"object","properties":{"creation_height":{"type":"string","format":"int64","description":"creation_height is the height which the unbonding took place."},"completion_time":{"type":"string","format":"date-time","description":"completion_time is the unix time for unbonding completion."},"initial_balance":{"type":"string","description":"initial_balance defines the tokens initially scheduled to receive at completion."},"balance":{"type":"string","description":"balance defines the tokens to receive at completion."},"unbonding_id":{"type":"string","format":"uint64","title":"Incrementing id that uniquely identifies this entry"},"unbonding_on_hold_ref_count":{"type":"string","format":"int64","title":"Strictly positive if this entry's unbonding has been stopped by external modules"}},"description":"UnbondingDelegationEntry defines an unbonding object with relevant metadata."},"description":"entries are the unbonding delegation entries."}},"description":"UnbondingDelegation stores all of a single delegator's unbonding bonds\nfor a single validator in an time-ordered list."}},"pagination":{"description":"pagination defines the pagination in the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"QueryValidatorUnbondingDelegationsResponse is response type for the\nQuery/ValidatorUnbondingDelegations RPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"validator_addr","description":"validator_addr defines the validator address to query for.","in":"path","required":true,"type":"string"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Query"]}}}}
```


# Tx

## TxDecode decodes the transaction.

> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/decode":{"post":{"summary":"TxDecode decodes the transaction.","description":"Since: cosmos-sdk 0.47","operationId":"TxDecode","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.TxDecodeResponse"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"tx_bytes":{"type":"string","format":"byte","description":"tx_bytes is the raw transaction."}},"description":"TxDecodeRequest is the request type for the Service.TxDecode\nRPC method.\n\nSince: cosmos-sdk 0.47"}}},"required":true}}}},"components":{"schemas":{"cosmos.tx.v1beta1.TxDecodeResponse":{"type":"object","properties":{"tx":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.Tx","description":"tx is the decoded transaction."}},"description":"TxDecodeResponse is the response type for the\nService.TxDecode method.\n\nSince: cosmos-sdk 0.47"},"cosmos.tx.v1beta1.Tx":{"type":"object","properties":{"body":{"title":"body is the processable content of the transaction","type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages is a list of messages to be executed. The required signers of\nthose messages define the number and order of elements in AuthInfo's\nsigner_infos and Tx's signatures. Each required signer address is added to\nthe list only the first time it occurs.\nBy convention, the first required signer (usually from the first message)\nis referred to as the primary signer and pays the fee for the whole\ntransaction."},"memo":{"type":"string","description":"memo is any arbitrary note/comment to be added to the transaction.\nWARNING: in clients, any publicly exposed text should not be called memo,\nbut should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122)."},"timeout_height":{"type":"string","format":"uint64","title":"timeout is the block height after which this transaction will not\nbe processed by the chain"},"extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, the transaction will be rejected"},"non_critical_extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, they will be ignored"}},"description":"TxBody is the body of a transaction that all signers sign over."},"auth_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.AuthInfo","title":"auth_info is the authorization related content of the transaction,\nspecifically signers, signer modes and fee"},"signatures":{"type":"array","items":{"type":"string","format":"byte"},"description":"signatures is a list of signatures that matches the length and order of\nAuthInfo's signer_infos to allow connecting signature meta information like\npublic key and signing mode by position."}},"description":"Tx is the standard type used for broadcasting transactions."},"cosmos.tx.v1beta1.AuthInfo":{"type":"object","properties":{"signer_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SignerInfo"},"description":"signer_infos defines the signing modes for the required signers. The number\nand order of elements must match the required signers from TxBody's\nmessages. The first element is the primary signer and the one which pays\nthe fee."},"fee":{"description":"Fee is the fee and gas limit for the transaction. The first signer is the\nprimary signer and the one which pays the fee. The fee can be calculated\nbased on the cost of evaluating the body and doing signature verification\nof the signers. This can be estimated via simulation.","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of coins to be paid as a fee"},"gas_limit":{"type":"string","format":"uint64","title":"gas_limit is the maximum gas that can be used in transaction processing\nbefore an out of gas error occurs"},"payer":{"type":"string","description":"if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees.\nthe payer must be a tx signer (and thus have signed this field in AuthInfo).\nsetting this field does *not* change the ordering of required signers for the transaction."},"granter":{"type":"string","title":"if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used\nto pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does\nnot support fee grants, this will fail"}}},"tip":{"description":"Tip is the optional tip used for transactions fees paid in another denom.\n\nThis field is ignored if the chain didn't enable tips, i.e. didn't add the\n`TipDecorator` in its posthandler.\n\nSince: cosmos-sdk 0.46","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of the tip"},"tipper":{"type":"string","title":"tipper is the address of the account paying for the tip"}}}},"description":"AuthInfo describes the fee and signer modes that are used to sign a\ntransaction."},"cosmos.tx.v1beta1.SignerInfo":{"type":"object","properties":{"public_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"mode_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo","title":"mode_info describes the signing mode of the signer and is a nested\nstructure to support nested multisig pubkey's"},"sequence":{"type":"string","format":"uint64","description":"sequence is the sequence of the account, which describes the\nnumber of committed transactions signed by a given address. It is used to\nprevent replay attacks."}},"description":"SignerInfo describes the public key and signing mode of a single top-level\nsigner."},"cosmos.tx.v1beta1.ModeInfo":{"type":"object","properties":{"single":{"title":"single represents a single signer","type":"object","properties":{"mode":{"title":"mode is the signing mode of the single signer","type":"string","enum":["SIGN_MODE_UNSPECIFIED","SIGN_MODE_DIRECT","SIGN_MODE_TEXTUAL","SIGN_MODE_DIRECT_AUX","SIGN_MODE_LEGACY_AMINO_JSON","SIGN_MODE_EIP_191"],"default":"SIGN_MODE_UNSPECIFIED","description":"SignMode represents a signing mode with its own security guarantees.\n\nThis enum should be considered a registry of all known sign modes\nin the Cosmos ecosystem. Apps are not expected to support all known\nsign modes. Apps that would like to support custom  sign modes are\nencouraged to open a small PR against this file to add a new case\nto this SignMode enum describing their sign mode so that different\napps have a consistent version of this enum.\n\n - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be\nrejected.\n - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is\nverified with raw bytes from Tx.\n - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some\nhuman-readable textual representation on top of the binary representation\nfrom SIGN_MODE_DIRECT.\n\nSince: cosmos-sdk 0.50\n - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses\nSignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not\nrequire signers signing over other signers' `signer_info`.\n\nSince: cosmos-sdk 0.46\n - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses\nAmino JSON and will be removed in the future.\n - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos\nSDK. Ref: https://eips.ethereum.org/EIPS/eip-191\n\nCurrently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant,\nbut is not implemented on the SDK by default. To enable EIP-191, you need\nto pass a custom `TxConfig` that has an implementation of\n`SignModeHandler` for EIP-191. The SDK may decide to fully support\nEIP-191 in the future.\n\nSince: cosmos-sdk 0.45.2"}}},"multi":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo.Multi","title":"multi represents a nested multisig signer"}},"description":"ModeInfo describes the signing mode of a single or nested multisig signer."},"cosmos.tx.v1beta1.ModeInfo.Multi":{"type":"object","properties":{"bitarray":{"title":"bitarray specifies which keys within the multisig are signing","type":"object","properties":{"extra_bits_stored":{"type":"integer","format":"int64"},"elems":{"type":"string","format":"byte"}},"description":"CompactBitArray is an implementation of a space efficient bit array.\nThis is used to ensure that the encoded data takes up a minimal amount of\nspace after proto encoding.\nThis is not thread safe, and is not intended for concurrent usage."},"mode_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo"},"title":"mode_infos is the corresponding modes of the signers of the multisig\nwhich could include nested multisig public keys"}},"title":"Multi is the mode info for a multisig public key"}}}}
```

## TxEncode encodes the transaction.

> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/encode":{"post":{"summary":"TxEncode encodes the transaction.","description":"Since: cosmos-sdk 0.47","operationId":"TxEncode","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"tx_bytes":{"type":"string","format":"byte","description":"tx_bytes is the encoded transaction bytes."}},"description":"TxEncodeResponse is the response type for the\nService.TxEncode method.\n\nSince: cosmos-sdk 0.47"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.TxEncodeRequest"}}},"required":true}}}},"components":{"schemas":{"cosmos.tx.v1beta1.TxEncodeRequest":{"type":"object","properties":{"tx":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.Tx","description":"tx is the transaction to encode."}},"description":"TxEncodeRequest is the request type for the Service.TxEncode\nRPC method.\n\nSince: cosmos-sdk 0.47"},"cosmos.tx.v1beta1.Tx":{"type":"object","properties":{"body":{"title":"body is the processable content of the transaction","type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages is a list of messages to be executed. The required signers of\nthose messages define the number and order of elements in AuthInfo's\nsigner_infos and Tx's signatures. Each required signer address is added to\nthe list only the first time it occurs.\nBy convention, the first required signer (usually from the first message)\nis referred to as the primary signer and pays the fee for the whole\ntransaction."},"memo":{"type":"string","description":"memo is any arbitrary note/comment to be added to the transaction.\nWARNING: in clients, any publicly exposed text should not be called memo,\nbut should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122)."},"timeout_height":{"type":"string","format":"uint64","title":"timeout is the block height after which this transaction will not\nbe processed by the chain"},"extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, the transaction will be rejected"},"non_critical_extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, they will be ignored"}},"description":"TxBody is the body of a transaction that all signers sign over."},"auth_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.AuthInfo","title":"auth_info is the authorization related content of the transaction,\nspecifically signers, signer modes and fee"},"signatures":{"type":"array","items":{"type":"string","format":"byte"},"description":"signatures is a list of signatures that matches the length and order of\nAuthInfo's signer_infos to allow connecting signature meta information like\npublic key and signing mode by position."}},"description":"Tx is the standard type used for broadcasting transactions."},"cosmos.tx.v1beta1.AuthInfo":{"type":"object","properties":{"signer_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SignerInfo"},"description":"signer_infos defines the signing modes for the required signers. The number\nand order of elements must match the required signers from TxBody's\nmessages. The first element is the primary signer and the one which pays\nthe fee."},"fee":{"description":"Fee is the fee and gas limit for the transaction. The first signer is the\nprimary signer and the one which pays the fee. The fee can be calculated\nbased on the cost of evaluating the body and doing signature verification\nof the signers. This can be estimated via simulation.","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of coins to be paid as a fee"},"gas_limit":{"type":"string","format":"uint64","title":"gas_limit is the maximum gas that can be used in transaction processing\nbefore an out of gas error occurs"},"payer":{"type":"string","description":"if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees.\nthe payer must be a tx signer (and thus have signed this field in AuthInfo).\nsetting this field does *not* change the ordering of required signers for the transaction."},"granter":{"type":"string","title":"if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used\nto pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does\nnot support fee grants, this will fail"}}},"tip":{"description":"Tip is the optional tip used for transactions fees paid in another denom.\n\nThis field is ignored if the chain didn't enable tips, i.e. didn't add the\n`TipDecorator` in its posthandler.\n\nSince: cosmos-sdk 0.46","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of the tip"},"tipper":{"type":"string","title":"tipper is the address of the account paying for the tip"}}}},"description":"AuthInfo describes the fee and signer modes that are used to sign a\ntransaction."},"cosmos.tx.v1beta1.SignerInfo":{"type":"object","properties":{"public_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"mode_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo","title":"mode_info describes the signing mode of the signer and is a nested\nstructure to support nested multisig pubkey's"},"sequence":{"type":"string","format":"uint64","description":"sequence is the sequence of the account, which describes the\nnumber of committed transactions signed by a given address. It is used to\nprevent replay attacks."}},"description":"SignerInfo describes the public key and signing mode of a single top-level\nsigner."},"cosmos.tx.v1beta1.ModeInfo":{"type":"object","properties":{"single":{"title":"single represents a single signer","type":"object","properties":{"mode":{"title":"mode is the signing mode of the single signer","type":"string","enum":["SIGN_MODE_UNSPECIFIED","SIGN_MODE_DIRECT","SIGN_MODE_TEXTUAL","SIGN_MODE_DIRECT_AUX","SIGN_MODE_LEGACY_AMINO_JSON","SIGN_MODE_EIP_191"],"default":"SIGN_MODE_UNSPECIFIED","description":"SignMode represents a signing mode with its own security guarantees.\n\nThis enum should be considered a registry of all known sign modes\nin the Cosmos ecosystem. Apps are not expected to support all known\nsign modes. Apps that would like to support custom  sign modes are\nencouraged to open a small PR against this file to add a new case\nto this SignMode enum describing their sign mode so that different\napps have a consistent version of this enum.\n\n - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be\nrejected.\n - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is\nverified with raw bytes from Tx.\n - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some\nhuman-readable textual representation on top of the binary representation\nfrom SIGN_MODE_DIRECT.\n\nSince: cosmos-sdk 0.50\n - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses\nSignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not\nrequire signers signing over other signers' `signer_info`.\n\nSince: cosmos-sdk 0.46\n - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses\nAmino JSON and will be removed in the future.\n - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos\nSDK. Ref: https://eips.ethereum.org/EIPS/eip-191\n\nCurrently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant,\nbut is not implemented on the SDK by default. To enable EIP-191, you need\nto pass a custom `TxConfig` that has an implementation of\n`SignModeHandler` for EIP-191. The SDK may decide to fully support\nEIP-191 in the future.\n\nSince: cosmos-sdk 0.45.2"}}},"multi":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo.Multi","title":"multi represents a nested multisig signer"}},"description":"ModeInfo describes the signing mode of a single or nested multisig signer."},"cosmos.tx.v1beta1.ModeInfo.Multi":{"type":"object","properties":{"bitarray":{"title":"bitarray specifies which keys within the multisig are signing","type":"object","properties":{"extra_bits_stored":{"type":"integer","format":"int64"},"elems":{"type":"string","format":"byte"}},"description":"CompactBitArray is an implementation of a space efficient bit array.\nThis is used to ensure that the encoded data takes up a minimal amount of\nspace after proto encoding.\nThis is not thread safe, and is not intended for concurrent usage."},"mode_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo"},"title":"mode_infos is the corresponding modes of the signers of the multisig\nwhich could include nested multisig public keys"}},"title":"Multi is the mode info for a multisig public key"}}}}
```

## TxDecodeAmino decodes an Amino transaction from encoded bytes to JSON.

> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/decode/amino":{"post":{"summary":"TxDecodeAmino decodes an Amino transaction from encoded bytes to JSON.","description":"Since: cosmos-sdk 0.47","operationId":"TxDecodeAmino","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"amino_json":{"type":"string"}},"description":"TxDecodeAminoResponse is the response type for the Service.TxDecodeAmino\nRPC method.\n\nSince: cosmos-sdk 0.47"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"amino_binary":{"type":"string","format":"byte"}},"description":"TxDecodeAminoRequest is the request type for the Service.TxDecodeAmino\nRPC method.\n\nSince: cosmos-sdk 0.47"}}},"required":true}}}}}
```

## TxEncodeAmino encodes an Amino transaction from JSON to encoded bytes.

> Since: cosmos-sdk 0.47

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/encode/amino":{"post":{"summary":"TxEncodeAmino encodes an Amino transaction from JSON to encoded bytes.","description":"Since: cosmos-sdk 0.47","operationId":"TxEncodeAmino","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"amino_binary":{"type":"string","format":"byte"}},"description":"TxEncodeAminoResponse is the response type for the Service.TxEncodeAmino\nRPC method.\n\nSince: cosmos-sdk 0.47"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"amino_json":{"type":"string"}},"description":"TxEncodeAminoRequest is the request type for the Service.TxEncodeAmino\nRPC method.\n\nSince: cosmos-sdk 0.47"}}},"required":true}}}}}
```

## GET /cosmos/tx/v1beta1/txs

> GetTxsEvent fetches txs by event.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/txs":{"get":{"summary":"GetTxsEvent fetches txs by event.","operationId":"GetTxsEvent","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.GetTxsEventResponse"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"events","description":"events is the list of transaction event type.\nDeprecated post v0.47.x: use query instead, which should contain a valid\nevents query.","in":"query","required":false,"type":"array","items":{"type":"string"},"collectionFormat":"multi"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"},{"name":"order_by","description":" - ORDER_BY_UNSPECIFIED: ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults\nto ASC in this case.\n - ORDER_BY_ASC: ORDER_BY_ASC defines ascending order\n - ORDER_BY_DESC: ORDER_BY_DESC defines descending order","in":"query","required":false,"type":"string","enum":["ORDER_BY_UNSPECIFIED","ORDER_BY_ASC","ORDER_BY_DESC"],"default":"ORDER_BY_UNSPECIFIED"},{"name":"page","description":"page is the page number to query, starts at 1. If not provided, will\ndefault to first page.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"query","description":"query defines the transaction event query that is proxied to Tendermint's\nTxSearch RPC method. The query must be valid.\n\nSince cosmos-sdk 0.50","in":"query","required":false,"type":"string"}],"tags":["Service"]}}},"components":{"schemas":{"cosmos.tx.v1beta1.GetTxsEventResponse":{"type":"object","properties":{"txs":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.Tx"},"description":"txs is the list of queried transactions."},"tx_responses":{"type":"array","items":{"type":"object","properties":{"height":{"type":"string","format":"int64","title":"The block height"},"txhash":{"type":"string","description":"The transaction hash."},"codespace":{"type":"string","title":"Namespace for the Code"},"code":{"type":"integer","format":"int64","description":"Response code."},"data":{"type":"string","description":"Result bytes, if any."},"raw_log":{"type":"string","description":"The output of the application's logger (raw string). May be\nnon-deterministic."},"logs":{"type":"array","items":{"type":"object","properties":{"msg_index":{"type":"integer","format":"int64"},"log":{"type":"string"},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"}},"description":"Attribute defines an attribute wrapper where the key and value are\nstrings instead of raw bytes."}}},"description":"StringEvent defines en Event object wrapper where all the attributes\ncontain key/value pairs that are strings instead of raw bytes."},"description":"Events contains a slice of Event objects that were emitted during some\nexecution."}},"description":"ABCIMessageLog defines a structure containing an indexed tx ABCI message log."},"description":"The output of the application's logger (typed). May be non-deterministic."},"info":{"type":"string","description":"Additional information. May be non-deterministic."},"gas_wanted":{"type":"string","format":"int64","description":"Amount of gas requested for transaction."},"gas_used":{"type":"string","format":"int64","description":"Amount of gas consumed by transaction."},"tx":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"timestamp":{"type":"string","description":"Time of the previous block. For heights > 1, it's the weighted median of\nthe timestamps of the valid votes in the block.LastCommit. For height == 1,\nit's genesis time."},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"},"index":{"type":"boolean"}},"description":"EventAttribute is a single key-value pair, associated with an event."}}},"description":"Event allows application developers to attach additional information to\nResponseFinalizeBlock and ResponseCheckTx.\nLater, transactions may be queried using these events."},"description":"Events defines all the events emitted by processing a transaction. Note,\nthese events include those emitted by processing all the messages and those\nemitted from the ante. Whereas Logs contains the events, with\nadditional metadata, emitted only by processing the messages.\n\nSince: cosmos-sdk 0.42.11, 0.44.5, 0.45"}},"description":"TxResponse defines a structure containing relevant tx data and metadata. The\ntags are stringified and the log is JSON decoded."},"description":"tx_responses is the list of queried TxResponses."},"pagination":{"description":"pagination defines a pagination for the response.\nDeprecated post v0.46.x: use total instead.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}},"total":{"type":"string","format":"uint64","title":"total is total number of results available"}},"description":"GetTxsEventResponse is the response type for the Service.TxsByEvents\nRPC method."},"cosmos.tx.v1beta1.Tx":{"type":"object","properties":{"body":{"title":"body is the processable content of the transaction","type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages is a list of messages to be executed. The required signers of\nthose messages define the number and order of elements in AuthInfo's\nsigner_infos and Tx's signatures. Each required signer address is added to\nthe list only the first time it occurs.\nBy convention, the first required signer (usually from the first message)\nis referred to as the primary signer and pays the fee for the whole\ntransaction."},"memo":{"type":"string","description":"memo is any arbitrary note/comment to be added to the transaction.\nWARNING: in clients, any publicly exposed text should not be called memo,\nbut should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122)."},"timeout_height":{"type":"string","format":"uint64","title":"timeout is the block height after which this transaction will not\nbe processed by the chain"},"extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, the transaction will be rejected"},"non_critical_extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, they will be ignored"}},"description":"TxBody is the body of a transaction that all signers sign over."},"auth_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.AuthInfo","title":"auth_info is the authorization related content of the transaction,\nspecifically signers, signer modes and fee"},"signatures":{"type":"array","items":{"type":"string","format":"byte"},"description":"signatures is a list of signatures that matches the length and order of\nAuthInfo's signer_infos to allow connecting signature meta information like\npublic key and signing mode by position."}},"description":"Tx is the standard type used for broadcasting transactions."},"cosmos.tx.v1beta1.AuthInfo":{"type":"object","properties":{"signer_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SignerInfo"},"description":"signer_infos defines the signing modes for the required signers. The number\nand order of elements must match the required signers from TxBody's\nmessages. The first element is the primary signer and the one which pays\nthe fee."},"fee":{"description":"Fee is the fee and gas limit for the transaction. The first signer is the\nprimary signer and the one which pays the fee. The fee can be calculated\nbased on the cost of evaluating the body and doing signature verification\nof the signers. This can be estimated via simulation.","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of coins to be paid as a fee"},"gas_limit":{"type":"string","format":"uint64","title":"gas_limit is the maximum gas that can be used in transaction processing\nbefore an out of gas error occurs"},"payer":{"type":"string","description":"if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees.\nthe payer must be a tx signer (and thus have signed this field in AuthInfo).\nsetting this field does *not* change the ordering of required signers for the transaction."},"granter":{"type":"string","title":"if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used\nto pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does\nnot support fee grants, this will fail"}}},"tip":{"description":"Tip is the optional tip used for transactions fees paid in another denom.\n\nThis field is ignored if the chain didn't enable tips, i.e. didn't add the\n`TipDecorator` in its posthandler.\n\nSince: cosmos-sdk 0.46","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of the tip"},"tipper":{"type":"string","title":"tipper is the address of the account paying for the tip"}}}},"description":"AuthInfo describes the fee and signer modes that are used to sign a\ntransaction."},"cosmos.tx.v1beta1.SignerInfo":{"type":"object","properties":{"public_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"mode_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo","title":"mode_info describes the signing mode of the signer and is a nested\nstructure to support nested multisig pubkey's"},"sequence":{"type":"string","format":"uint64","description":"sequence is the sequence of the account, which describes the\nnumber of committed transactions signed by a given address. It is used to\nprevent replay attacks."}},"description":"SignerInfo describes the public key and signing mode of a single top-level\nsigner."},"cosmos.tx.v1beta1.ModeInfo":{"type":"object","properties":{"single":{"title":"single represents a single signer","type":"object","properties":{"mode":{"title":"mode is the signing mode of the single signer","type":"string","enum":["SIGN_MODE_UNSPECIFIED","SIGN_MODE_DIRECT","SIGN_MODE_TEXTUAL","SIGN_MODE_DIRECT_AUX","SIGN_MODE_LEGACY_AMINO_JSON","SIGN_MODE_EIP_191"],"default":"SIGN_MODE_UNSPECIFIED","description":"SignMode represents a signing mode with its own security guarantees.\n\nThis enum should be considered a registry of all known sign modes\nin the Cosmos ecosystem. Apps are not expected to support all known\nsign modes. Apps that would like to support custom  sign modes are\nencouraged to open a small PR against this file to add a new case\nto this SignMode enum describing their sign mode so that different\napps have a consistent version of this enum.\n\n - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be\nrejected.\n - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is\nverified with raw bytes from Tx.\n - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some\nhuman-readable textual representation on top of the binary representation\nfrom SIGN_MODE_DIRECT.\n\nSince: cosmos-sdk 0.50\n - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses\nSignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not\nrequire signers signing over other signers' `signer_info`.\n\nSince: cosmos-sdk 0.46\n - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses\nAmino JSON and will be removed in the future.\n - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos\nSDK. Ref: https://eips.ethereum.org/EIPS/eip-191\n\nCurrently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant,\nbut is not implemented on the SDK by default. To enable EIP-191, you need\nto pass a custom `TxConfig` that has an implementation of\n`SignModeHandler` for EIP-191. The SDK may decide to fully support\nEIP-191 in the future.\n\nSince: cosmos-sdk 0.45.2"}}},"multi":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo.Multi","title":"multi represents a nested multisig signer"}},"description":"ModeInfo describes the signing mode of a single or nested multisig signer."},"cosmos.tx.v1beta1.ModeInfo.Multi":{"type":"object","properties":{"bitarray":{"title":"bitarray specifies which keys within the multisig are signing","type":"object","properties":{"extra_bits_stored":{"type":"integer","format":"int64"},"elems":{"type":"string","format":"byte"}},"description":"CompactBitArray is an implementation of a space efficient bit array.\nThis is used to ensure that the encoded data takes up a minimal amount of\nspace after proto encoding.\nThis is not thread safe, and is not intended for concurrent usage."},"mode_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo"},"title":"mode_infos is the corresponding modes of the signers of the multisig\nwhich could include nested multisig public keys"}},"title":"Multi is the mode info for a multisig public key"}}}}
```

## GET /cosmos/tx/v1beta1/txs/{hash}

> GetTx fetches a tx by hash.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/txs/{hash}":{"get":{"summary":"GetTx fetches a tx by hash.","operationId":"GetTx","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.GetTxResponse"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"hash","description":"hash is the tx hash to query, encoded as a hex string.","in":"path","required":true,"type":"string"}],"tags":["Service"]}}},"components":{"schemas":{"cosmos.tx.v1beta1.GetTxResponse":{"type":"object","properties":{"tx":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.Tx","description":"tx is the queried transaction."},"tx_response":{"type":"object","properties":{"height":{"type":"string","format":"int64","title":"The block height"},"txhash":{"type":"string","description":"The transaction hash."},"codespace":{"type":"string","title":"Namespace for the Code"},"code":{"type":"integer","format":"int64","description":"Response code."},"data":{"type":"string","description":"Result bytes, if any."},"raw_log":{"type":"string","description":"The output of the application's logger (raw string). May be\nnon-deterministic."},"logs":{"type":"array","items":{"type":"object","properties":{"msg_index":{"type":"integer","format":"int64"},"log":{"type":"string"},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"}},"description":"Attribute defines an attribute wrapper where the key and value are\nstrings instead of raw bytes."}}},"description":"StringEvent defines en Event object wrapper where all the attributes\ncontain key/value pairs that are strings instead of raw bytes."},"description":"Events contains a slice of Event objects that were emitted during some\nexecution."}},"description":"ABCIMessageLog defines a structure containing an indexed tx ABCI message log."},"description":"The output of the application's logger (typed). May be non-deterministic."},"info":{"type":"string","description":"Additional information. May be non-deterministic."},"gas_wanted":{"type":"string","format":"int64","description":"Amount of gas requested for transaction."},"gas_used":{"type":"string","format":"int64","description":"Amount of gas consumed by transaction."},"tx":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"timestamp":{"type":"string","description":"Time of the previous block. For heights > 1, it's the weighted median of\nthe timestamps of the valid votes in the block.LastCommit. For height == 1,\nit's genesis time."},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"},"index":{"type":"boolean"}},"description":"EventAttribute is a single key-value pair, associated with an event."}}},"description":"Event allows application developers to attach additional information to\nResponseFinalizeBlock and ResponseCheckTx.\nLater, transactions may be queried using these events."},"description":"Events defines all the events emitted by processing a transaction. Note,\nthese events include those emitted by processing all the messages and those\nemitted from the ante. Whereas Logs contains the events, with\nadditional metadata, emitted only by processing the messages.\n\nSince: cosmos-sdk 0.42.11, 0.44.5, 0.45"}},"description":"TxResponse defines a structure containing relevant tx data and metadata. The\ntags are stringified and the log is JSON decoded."}},"description":"GetTxResponse is the response type for the Service.GetTx method."},"cosmos.tx.v1beta1.Tx":{"type":"object","properties":{"body":{"title":"body is the processable content of the transaction","type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages is a list of messages to be executed. The required signers of\nthose messages define the number and order of elements in AuthInfo's\nsigner_infos and Tx's signatures. Each required signer address is added to\nthe list only the first time it occurs.\nBy convention, the first required signer (usually from the first message)\nis referred to as the primary signer and pays the fee for the whole\ntransaction."},"memo":{"type":"string","description":"memo is any arbitrary note/comment to be added to the transaction.\nWARNING: in clients, any publicly exposed text should not be called memo,\nbut should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122)."},"timeout_height":{"type":"string","format":"uint64","title":"timeout is the block height after which this transaction will not\nbe processed by the chain"},"extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, the transaction will be rejected"},"non_critical_extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, they will be ignored"}},"description":"TxBody is the body of a transaction that all signers sign over."},"auth_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.AuthInfo","title":"auth_info is the authorization related content of the transaction,\nspecifically signers, signer modes and fee"},"signatures":{"type":"array","items":{"type":"string","format":"byte"},"description":"signatures is a list of signatures that matches the length and order of\nAuthInfo's signer_infos to allow connecting signature meta information like\npublic key and signing mode by position."}},"description":"Tx is the standard type used for broadcasting transactions."},"cosmos.tx.v1beta1.AuthInfo":{"type":"object","properties":{"signer_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SignerInfo"},"description":"signer_infos defines the signing modes for the required signers. The number\nand order of elements must match the required signers from TxBody's\nmessages. The first element is the primary signer and the one which pays\nthe fee."},"fee":{"description":"Fee is the fee and gas limit for the transaction. The first signer is the\nprimary signer and the one which pays the fee. The fee can be calculated\nbased on the cost of evaluating the body and doing signature verification\nof the signers. This can be estimated via simulation.","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of coins to be paid as a fee"},"gas_limit":{"type":"string","format":"uint64","title":"gas_limit is the maximum gas that can be used in transaction processing\nbefore an out of gas error occurs"},"payer":{"type":"string","description":"if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees.\nthe payer must be a tx signer (and thus have signed this field in AuthInfo).\nsetting this field does *not* change the ordering of required signers for the transaction."},"granter":{"type":"string","title":"if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used\nto pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does\nnot support fee grants, this will fail"}}},"tip":{"description":"Tip is the optional tip used for transactions fees paid in another denom.\n\nThis field is ignored if the chain didn't enable tips, i.e. didn't add the\n`TipDecorator` in its posthandler.\n\nSince: cosmos-sdk 0.46","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of the tip"},"tipper":{"type":"string","title":"tipper is the address of the account paying for the tip"}}}},"description":"AuthInfo describes the fee and signer modes that are used to sign a\ntransaction."},"cosmos.tx.v1beta1.SignerInfo":{"type":"object","properties":{"public_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"mode_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo","title":"mode_info describes the signing mode of the signer and is a nested\nstructure to support nested multisig pubkey's"},"sequence":{"type":"string","format":"uint64","description":"sequence is the sequence of the account, which describes the\nnumber of committed transactions signed by a given address. It is used to\nprevent replay attacks."}},"description":"SignerInfo describes the public key and signing mode of a single top-level\nsigner."},"cosmos.tx.v1beta1.ModeInfo":{"type":"object","properties":{"single":{"title":"single represents a single signer","type":"object","properties":{"mode":{"title":"mode is the signing mode of the single signer","type":"string","enum":["SIGN_MODE_UNSPECIFIED","SIGN_MODE_DIRECT","SIGN_MODE_TEXTUAL","SIGN_MODE_DIRECT_AUX","SIGN_MODE_LEGACY_AMINO_JSON","SIGN_MODE_EIP_191"],"default":"SIGN_MODE_UNSPECIFIED","description":"SignMode represents a signing mode with its own security guarantees.\n\nThis enum should be considered a registry of all known sign modes\nin the Cosmos ecosystem. Apps are not expected to support all known\nsign modes. Apps that would like to support custom  sign modes are\nencouraged to open a small PR against this file to add a new case\nto this SignMode enum describing their sign mode so that different\napps have a consistent version of this enum.\n\n - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be\nrejected.\n - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is\nverified with raw bytes from Tx.\n - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some\nhuman-readable textual representation on top of the binary representation\nfrom SIGN_MODE_DIRECT.\n\nSince: cosmos-sdk 0.50\n - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses\nSignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not\nrequire signers signing over other signers' `signer_info`.\n\nSince: cosmos-sdk 0.46\n - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses\nAmino JSON and will be removed in the future.\n - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos\nSDK. Ref: https://eips.ethereum.org/EIPS/eip-191\n\nCurrently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant,\nbut is not implemented on the SDK by default. To enable EIP-191, you need\nto pass a custom `TxConfig` that has an implementation of\n`SignModeHandler` for EIP-191. The SDK may decide to fully support\nEIP-191 in the future.\n\nSince: cosmos-sdk 0.45.2"}}},"multi":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo.Multi","title":"multi represents a nested multisig signer"}},"description":"ModeInfo describes the signing mode of a single or nested multisig signer."},"cosmos.tx.v1beta1.ModeInfo.Multi":{"type":"object","properties":{"bitarray":{"title":"bitarray specifies which keys within the multisig are signing","type":"object","properties":{"extra_bits_stored":{"type":"integer","format":"int64"},"elems":{"type":"string","format":"byte"}},"description":"CompactBitArray is an implementation of a space efficient bit array.\nThis is used to ensure that the encoded data takes up a minimal amount of\nspace after proto encoding.\nThis is not thread safe, and is not intended for concurrent usage."},"mode_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo"},"title":"mode_infos is the corresponding modes of the signers of the multisig\nwhich could include nested multisig public keys"}},"title":"Multi is the mode info for a multisig public key"}}}}
```

## POST /cosmos/tx/v1beta1/txs

> BroadcastTx broadcast transaction.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/txs":{"post":{"summary":"BroadcastTx broadcast transaction.","operationId":"BroadcastTx","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"tx_response":{"type":"object","properties":{"height":{"type":"string","format":"int64","title":"The block height"},"txhash":{"type":"string","description":"The transaction hash."},"codespace":{"type":"string","title":"Namespace for the Code"},"code":{"type":"integer","format":"int64","description":"Response code."},"data":{"type":"string","description":"Result bytes, if any."},"raw_log":{"type":"string","description":"The output of the application's logger (raw string). May be\nnon-deterministic."},"logs":{"type":"array","items":{"type":"object","properties":{"msg_index":{"type":"integer","format":"int64"},"log":{"type":"string"},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"}},"description":"Attribute defines an attribute wrapper where the key and value are\nstrings instead of raw bytes."}}},"description":"StringEvent defines en Event object wrapper where all the attributes\ncontain key/value pairs that are strings instead of raw bytes."},"description":"Events contains a slice of Event objects that were emitted during some\nexecution."}},"description":"ABCIMessageLog defines a structure containing an indexed tx ABCI message log."},"description":"The output of the application's logger (typed). May be non-deterministic."},"info":{"type":"string","description":"Additional information. May be non-deterministic."},"gas_wanted":{"type":"string","format":"int64","description":"Amount of gas requested for transaction."},"gas_used":{"type":"string","format":"int64","description":"Amount of gas consumed by transaction."},"tx":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"timestamp":{"type":"string","description":"Time of the previous block. For heights > 1, it's the weighted median of\nthe timestamps of the valid votes in the block.LastCommit. For height == 1,\nit's genesis time."},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"},"index":{"type":"boolean"}},"description":"EventAttribute is a single key-value pair, associated with an event."}}},"description":"Event allows application developers to attach additional information to\nResponseFinalizeBlock and ResponseCheckTx.\nLater, transactions may be queried using these events."},"description":"Events defines all the events emitted by processing a transaction. Note,\nthese events include those emitted by processing all the messages and those\nemitted from the ante. Whereas Logs contains the events, with\nadditional metadata, emitted only by processing the messages.\n\nSince: cosmos-sdk 0.42.11, 0.44.5, 0.45"}},"description":"TxResponse defines a structure containing relevant tx data and metadata. The\ntags are stringified and the log is JSON decoded."}},"description":"BroadcastTxResponse is the response type for the\nService.BroadcastTx method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"tx_bytes":{"type":"string","format":"byte","description":"tx_bytes is the raw transaction."},"mode":{"type":"string","enum":["BROADCAST_MODE_UNSPECIFIED","BROADCAST_MODE_BLOCK","BROADCAST_MODE_SYNC","BROADCAST_MODE_ASYNC"],"default":"BROADCAST_MODE_UNSPECIFIED","description":"BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC\nmethod.\n\n - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering\n - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead,\nBROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards.\n - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits\nfor a CheckTx execution response only.\n - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client\nreturns immediately."}},"description":"BroadcastTxRequest is the request type for the Service.BroadcastTxRequest\nRPC method."}}},"required":true}}}}}
```

## GetBlockWithTxs fetches a block with decoded txs.

> Since: cosmos-sdk 0.45.2

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/txs/block/{height}":{"get":{"summary":"GetBlockWithTxs fetches a block with decoded txs.","description":"Since: cosmos-sdk 0.45.2","operationId":"GetBlockWithTxs","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.GetBlockWithTxsResponse"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"height","description":"height is the height of the block to query.","in":"path","required":true,"type":"string","format":"int64"},{"name":"pagination.key","description":"key is a value returned in PageResponse.next_key to begin\nquerying the next page most efficiently. Only one of offset or key\nshould be set.","in":"query","required":false,"type":"string","format":"byte"},{"name":"pagination.offset","description":"offset is a numeric offset that can be used when key is unavailable.\nIt is less efficient than using key. Only one of offset or key should\nbe set.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.limit","description":"limit is the total number of results to be returned in the result page.\nIf left empty it will default to a value to be set by each app.","in":"query","required":false,"type":"string","format":"uint64"},{"name":"pagination.count_total","description":"count_total is set to true  to indicate that the result set should include\na count of the total number of items available for pagination in UIs.\ncount_total is only respected when offset is used. It is ignored when key\nis set.","in":"query","required":false,"type":"boolean"},{"name":"pagination.reverse","description":"reverse is set to true if results are to be returned in the descending order.\n\nSince: cosmos-sdk 0.43","in":"query","required":false,"type":"boolean"}],"tags":["Service"]}}},"components":{"schemas":{"cosmos.tx.v1beta1.GetBlockWithTxsResponse":{"type":"object","properties":{"txs":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.Tx"},"description":"txs are the transactions in the block."},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"block":{"type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"data":{"type":"object","properties":{"txs":{"type":"array","items":{"type":"string","format":"byte"},"description":"Txs that will be applied by state @ block.Height+1.\nNOTE: not all txs here are valid.  We're just agreeing on the order first.\nThis means that block.AppHash does not include these txs."}},"title":"Data contains the set of transactions included in the block"},"evidence":{"type":"object","properties":{"evidence":{"type":"array","items":{"type":"object","properties":{"duplicate_vote_evidence":{"type":"object","properties":{"vote_a":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"vote_b":{"type":"object","properties":{"type":{"type":"string","enum":["SIGNED_MSG_TYPE_UNKNOWN","SIGNED_MSG_TYPE_PREVOTE","SIGNED_MSG_TYPE_PRECOMMIT","SIGNED_MSG_TYPE_PROPOSAL"],"default":"SIGNED_MSG_TYPE_UNKNOWN","description":"SignedMsgType is a type of signed message in the consensus.\n\n - SIGNED_MSG_TYPE_PREVOTE: Votes\n - SIGNED_MSG_TYPE_PROPOSAL: Proposals"},"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"timestamp":{"type":"string","format":"date-time"},"validator_address":{"type":"string","format":"byte"},"validator_index":{"type":"integer","format":"int32"},"signature":{"type":"string","format":"byte","description":"Vote signature by the validator if they participated in consensus for the\nassociated block."},"extension":{"type":"string","format":"byte","description":"Vote extension provided by the application. Only valid for precommit\nmessages."},"extension_signature":{"type":"string","format":"byte","description":"Vote extension signature by the validator if they participated in\nconsensus for the associated block.\nOnly valid for precommit messages."}},"description":"Vote represents a prevote or precommit vote from validators for\nconsensus."},"total_voting_power":{"type":"string","format":"int64"},"validator_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes."},"light_client_attack_evidence":{"type":"object","properties":{"conflicting_block":{"type":"object","properties":{"signed_header":{"type":"object","properties":{"header":{"type":"object","properties":{"version":{"title":"basic block info","type":"object","properties":{"block":{"type":"string","format":"uint64"},"app":{"type":"string","format":"uint64"}},"description":"Consensus captures the consensus rules for processing a block in the blockchain,\nincluding all blockchain data structures and the rules of the application's\nstate transition machine."},"chain_id":{"type":"string"},"height":{"type":"string","format":"int64"},"time":{"type":"string","format":"date-time"},"last_block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"last_commit_hash":{"type":"string","format":"byte","title":"hashes of block data"},"data_hash":{"type":"string","format":"byte"},"validators_hash":{"type":"string","format":"byte","title":"hashes from the app output from the prev block"},"next_validators_hash":{"type":"string","format":"byte"},"consensus_hash":{"type":"string","format":"byte"},"app_hash":{"type":"string","format":"byte"},"last_results_hash":{"type":"string","format":"byte"},"evidence_hash":{"type":"string","format":"byte","title":"consensus info"},"proposer_address":{"type":"string","format":"byte"}},"description":"Header defines the structure of a block header."},"commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"validator_set":{"type":"object","properties":{"validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"proposer":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}},"total_voting_power":{"type":"string","format":"int64"}}}}},"common_height":{"type":"string","format":"int64"},"byzantine_validators":{"type":"array","items":{"type":"object","properties":{"address":{"type":"string","format":"byte"},"pub_key":{"type":"object","properties":{"ed25519":{"type":"string","format":"byte"},"secp256k1":{"type":"string","format":"byte"}},"title":"PublicKey defines the keys available for use with Validators"},"voting_power":{"type":"string","format":"int64"},"proposer_priority":{"type":"string","format":"int64"}}}},"total_voting_power":{"type":"string","format":"int64"},"timestamp":{"type":"string","format":"date-time"}},"description":"LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client."}}}}}},"last_commit":{"type":"object","properties":{"height":{"type":"string","format":"int64"},"round":{"type":"integer","format":"int32"},"block_id":{"type":"object","properties":{"hash":{"type":"string","format":"byte"},"part_set_header":{"type":"object","properties":{"total":{"type":"integer","format":"int64"},"hash":{"type":"string","format":"byte"}},"title":"PartsetHeader"}},"title":"BlockID"},"signatures":{"type":"array","items":{"type":"object","properties":{"block_id_flag":{"type":"string","enum":["BLOCK_ID_FLAG_UNKNOWN","BLOCK_ID_FLAG_ABSENT","BLOCK_ID_FLAG_COMMIT","BLOCK_ID_FLAG_NIL"],"default":"BLOCK_ID_FLAG_UNKNOWN","title":"BlockIdFlag indicates which BlockID the signature is for"},"validator_address":{"type":"string","format":"byte"},"timestamp":{"type":"string","format":"date-time"},"signature":{"type":"string","format":"byte"}},"description":"CommitSig is a part of the Vote included in a Commit."}}},"description":"Commit contains the evidence that a block was committed by a set of validators."}}},"pagination":{"description":"pagination defines a pagination for the response.","type":"object","properties":{"next_key":{"type":"string","format":"byte","description":"next_key is the key to be passed to PageRequest.key to\nquery the next page most efficiently. It will be empty if\nthere are no more results."},"total":{"type":"string","format":"uint64","title":"total is total number of results available if PageRequest.count_total\nwas set, its value is undefined otherwise"}}}},"description":"GetBlockWithTxsResponse is the response type for the Service.GetBlockWithTxs\nmethod.\n\nSince: cosmos-sdk 0.45.2"},"cosmos.tx.v1beta1.Tx":{"type":"object","properties":{"body":{"title":"body is the processable content of the transaction","type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages is a list of messages to be executed. The required signers of\nthose messages define the number and order of elements in AuthInfo's\nsigner_infos and Tx's signatures. Each required signer address is added to\nthe list only the first time it occurs.\nBy convention, the first required signer (usually from the first message)\nis referred to as the primary signer and pays the fee for the whole\ntransaction."},"memo":{"type":"string","description":"memo is any arbitrary note/comment to be added to the transaction.\nWARNING: in clients, any publicly exposed text should not be called memo,\nbut should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122)."},"timeout_height":{"type":"string","format":"uint64","title":"timeout is the block height after which this transaction will not\nbe processed by the chain"},"extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, the transaction will be rejected"},"non_critical_extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, they will be ignored"}},"description":"TxBody is the body of a transaction that all signers sign over."},"auth_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.AuthInfo","title":"auth_info is the authorization related content of the transaction,\nspecifically signers, signer modes and fee"},"signatures":{"type":"array","items":{"type":"string","format":"byte"},"description":"signatures is a list of signatures that matches the length and order of\nAuthInfo's signer_infos to allow connecting signature meta information like\npublic key and signing mode by position."}},"description":"Tx is the standard type used for broadcasting transactions."},"cosmos.tx.v1beta1.AuthInfo":{"type":"object","properties":{"signer_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SignerInfo"},"description":"signer_infos defines the signing modes for the required signers. The number\nand order of elements must match the required signers from TxBody's\nmessages. The first element is the primary signer and the one which pays\nthe fee."},"fee":{"description":"Fee is the fee and gas limit for the transaction. The first signer is the\nprimary signer and the one which pays the fee. The fee can be calculated\nbased on the cost of evaluating the body and doing signature verification\nof the signers. This can be estimated via simulation.","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of coins to be paid as a fee"},"gas_limit":{"type":"string","format":"uint64","title":"gas_limit is the maximum gas that can be used in transaction processing\nbefore an out of gas error occurs"},"payer":{"type":"string","description":"if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees.\nthe payer must be a tx signer (and thus have signed this field in AuthInfo).\nsetting this field does *not* change the ordering of required signers for the transaction."},"granter":{"type":"string","title":"if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used\nto pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does\nnot support fee grants, this will fail"}}},"tip":{"description":"Tip is the optional tip used for transactions fees paid in another denom.\n\nThis field is ignored if the chain didn't enable tips, i.e. didn't add the\n`TipDecorator` in its posthandler.\n\nSince: cosmos-sdk 0.46","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of the tip"},"tipper":{"type":"string","title":"tipper is the address of the account paying for the tip"}}}},"description":"AuthInfo describes the fee and signer modes that are used to sign a\ntransaction."},"cosmos.tx.v1beta1.SignerInfo":{"type":"object","properties":{"public_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"mode_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo","title":"mode_info describes the signing mode of the signer and is a nested\nstructure to support nested multisig pubkey's"},"sequence":{"type":"string","format":"uint64","description":"sequence is the sequence of the account, which describes the\nnumber of committed transactions signed by a given address. It is used to\nprevent replay attacks."}},"description":"SignerInfo describes the public key and signing mode of a single top-level\nsigner."},"cosmos.tx.v1beta1.ModeInfo":{"type":"object","properties":{"single":{"title":"single represents a single signer","type":"object","properties":{"mode":{"title":"mode is the signing mode of the single signer","type":"string","enum":["SIGN_MODE_UNSPECIFIED","SIGN_MODE_DIRECT","SIGN_MODE_TEXTUAL","SIGN_MODE_DIRECT_AUX","SIGN_MODE_LEGACY_AMINO_JSON","SIGN_MODE_EIP_191"],"default":"SIGN_MODE_UNSPECIFIED","description":"SignMode represents a signing mode with its own security guarantees.\n\nThis enum should be considered a registry of all known sign modes\nin the Cosmos ecosystem. Apps are not expected to support all known\nsign modes. Apps that would like to support custom  sign modes are\nencouraged to open a small PR against this file to add a new case\nto this SignMode enum describing their sign mode so that different\napps have a consistent version of this enum.\n\n - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be\nrejected.\n - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is\nverified with raw bytes from Tx.\n - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some\nhuman-readable textual representation on top of the binary representation\nfrom SIGN_MODE_DIRECT.\n\nSince: cosmos-sdk 0.50\n - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses\nSignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not\nrequire signers signing over other signers' `signer_info`.\n\nSince: cosmos-sdk 0.46\n - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses\nAmino JSON and will be removed in the future.\n - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos\nSDK. Ref: https://eips.ethereum.org/EIPS/eip-191\n\nCurrently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant,\nbut is not implemented on the SDK by default. To enable EIP-191, you need\nto pass a custom `TxConfig` that has an implementation of\n`SignModeHandler` for EIP-191. The SDK may decide to fully support\nEIP-191 in the future.\n\nSince: cosmos-sdk 0.45.2"}}},"multi":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo.Multi","title":"multi represents a nested multisig signer"}},"description":"ModeInfo describes the signing mode of a single or nested multisig signer."},"cosmos.tx.v1beta1.ModeInfo.Multi":{"type":"object","properties":{"bitarray":{"title":"bitarray specifies which keys within the multisig are signing","type":"object","properties":{"extra_bits_stored":{"type":"integer","format":"int64"},"elems":{"type":"string","format":"byte"}},"description":"CompactBitArray is an implementation of a space efficient bit array.\nThis is used to ensure that the encoded data takes up a minimal amount of\nspace after proto encoding.\nThis is not thread safe, and is not intended for concurrent usage."},"mode_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo"},"title":"mode_infos is the corresponding modes of the signers of the multisig\nwhich could include nested multisig public keys"}},"title":"Multi is the mode info for a multisig public key"}}}}
```

## POST /cosmos/tx/v1beta1/simulate

> Simulate simulates executing a transaction for estimating gas usage.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/tx/v1beta1/simulate":{"post":{"summary":"Simulate simulates executing a transaction for estimating gas usage.","operationId":"Simulate","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"gas_info":{"description":"gas_info is the information about gas used in the simulation.","type":"object","properties":{"gas_wanted":{"type":"string","format":"uint64","description":"GasWanted is the maximum units of work we allow this tx to perform."},"gas_used":{"type":"string","format":"uint64","description":"GasUsed is the amount of gas actually consumed."}}},"result":{"description":"result is the result of the simulation.","type":"object","properties":{"data":{"type":"string","format":"byte","description":"Data is any data returned from message or handler execution. It MUST be\nlength prefixed in order to separate data from multiple message executions.\nDeprecated. This field is still populated, but prefer msg_response instead\nbecause it also contains the Msg response typeURL."},"log":{"type":"string","description":"Log contains the log information from message or handler execution."},"events":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"attributes":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"},"index":{"type":"boolean"}},"description":"EventAttribute is a single key-value pair, associated with an event."}}},"description":"Event allows application developers to attach additional information to\nResponseFinalizeBlock and ResponseCheckTx.\nLater, transactions may be queried using these events."},"description":"Events contains a slice of Event objects that were emitted during message\nor handler execution."},"msg_responses":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"msg_responses contains the Msg handler responses type packed in Anys.\n\nSince: cosmos-sdk 0.46"}}}},"description":"SimulateResponse is the response type for the\nService.SimulateRPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Service"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SimulateRequest"}}},"required":true}}}},"components":{"schemas":{"cosmos.tx.v1beta1.SimulateRequest":{"type":"object","properties":{"tx":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.Tx","description":"tx is the transaction to simulate.\nDeprecated. Send raw tx bytes instead."},"tx_bytes":{"type":"string","format":"byte","description":"tx_bytes is the raw transaction.\n\nSince: cosmos-sdk 0.43"}},"description":"SimulateRequest is the request type for the Service.Simulate\nRPC method."},"cosmos.tx.v1beta1.Tx":{"type":"object","properties":{"body":{"title":"body is the processable content of the transaction","type":"object","properties":{"messages":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"description":"messages is a list of messages to be executed. The required signers of\nthose messages define the number and order of elements in AuthInfo's\nsigner_infos and Tx's signatures. Each required signer address is added to\nthe list only the first time it occurs.\nBy convention, the first required signer (usually from the first message)\nis referred to as the primary signer and pays the fee for the whole\ntransaction."},"memo":{"type":"string","description":"memo is any arbitrary note/comment to be added to the transaction.\nWARNING: in clients, any publicly exposed text should not be called memo,\nbut should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122)."},"timeout_height":{"type":"string","format":"uint64","title":"timeout is the block height after which this transaction will not\nbe processed by the chain"},"extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, the transaction will be rejected"},"non_critical_extension_options":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"title":"extension_options are arbitrary options that can be added by chains\nwhen the default options are not sufficient. If any of these are present\nand can't be handled, they will be ignored"}},"description":"TxBody is the body of a transaction that all signers sign over."},"auth_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.AuthInfo","title":"auth_info is the authorization related content of the transaction,\nspecifically signers, signer modes and fee"},"signatures":{"type":"array","items":{"type":"string","format":"byte"},"description":"signatures is a list of signatures that matches the length and order of\nAuthInfo's signer_infos to allow connecting signature meta information like\npublic key and signing mode by position."}},"description":"Tx is the standard type used for broadcasting transactions."},"cosmos.tx.v1beta1.AuthInfo":{"type":"object","properties":{"signer_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.SignerInfo"},"description":"signer_infos defines the signing modes for the required signers. The number\nand order of elements must match the required signers from TxBody's\nmessages. The first element is the primary signer and the one which pays\nthe fee."},"fee":{"description":"Fee is the fee and gas limit for the transaction. The first signer is the\nprimary signer and the one which pays the fee. The fee can be calculated\nbased on the cost of evaluating the body and doing signature verification\nof the signers. This can be estimated via simulation.","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of coins to be paid as a fee"},"gas_limit":{"type":"string","format":"uint64","title":"gas_limit is the maximum gas that can be used in transaction processing\nbefore an out of gas error occurs"},"payer":{"type":"string","description":"if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees.\nthe payer must be a tx signer (and thus have signed this field in AuthInfo).\nsetting this field does *not* change the ordering of required signers for the transaction."},"granter":{"type":"string","title":"if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used\nto pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does\nnot support fee grants, this will fail"}}},"tip":{"description":"Tip is the optional tip used for transactions fees paid in another denom.\n\nThis field is ignored if the chain didn't enable tips, i.e. didn't add the\n`TipDecorator` in its posthandler.\n\nSince: cosmos-sdk 0.46","type":"object","properties":{"amount":{"type":"array","items":{"type":"object","properties":{"denom":{"type":"string"},"amount":{"type":"string"}},"description":"Coin defines a token with a denomination and an amount.\n\nNOTE: The amount field is an Int which implements the custom method\nsignatures required by gogoproto."},"title":"amount is the amount of the tip"},"tipper":{"type":"string","title":"tipper is the address of the account paying for the tip"}}}},"description":"AuthInfo describes the fee and signer modes that are used to sign a\ntransaction."},"cosmos.tx.v1beta1.SignerInfo":{"type":"object","properties":{"public_key":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"},"mode_info":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo","title":"mode_info describes the signing mode of the signer and is a nested\nstructure to support nested multisig pubkey's"},"sequence":{"type":"string","format":"uint64","description":"sequence is the sequence of the account, which describes the\nnumber of committed transactions signed by a given address. It is used to\nprevent replay attacks."}},"description":"SignerInfo describes the public key and signing mode of a single top-level\nsigner."},"cosmos.tx.v1beta1.ModeInfo":{"type":"object","properties":{"single":{"title":"single represents a single signer","type":"object","properties":{"mode":{"title":"mode is the signing mode of the single signer","type":"string","enum":["SIGN_MODE_UNSPECIFIED","SIGN_MODE_DIRECT","SIGN_MODE_TEXTUAL","SIGN_MODE_DIRECT_AUX","SIGN_MODE_LEGACY_AMINO_JSON","SIGN_MODE_EIP_191"],"default":"SIGN_MODE_UNSPECIFIED","description":"SignMode represents a signing mode with its own security guarantees.\n\nThis enum should be considered a registry of all known sign modes\nin the Cosmos ecosystem. Apps are not expected to support all known\nsign modes. Apps that would like to support custom  sign modes are\nencouraged to open a small PR against this file to add a new case\nto this SignMode enum describing their sign mode so that different\napps have a consistent version of this enum.\n\n - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be\nrejected.\n - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is\nverified with raw bytes from Tx.\n - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some\nhuman-readable textual representation on top of the binary representation\nfrom SIGN_MODE_DIRECT.\n\nSince: cosmos-sdk 0.50\n - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses\nSignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not\nrequire signers signing over other signers' `signer_info`.\n\nSince: cosmos-sdk 0.46\n - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses\nAmino JSON and will be removed in the future.\n - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos\nSDK. Ref: https://eips.ethereum.org/EIPS/eip-191\n\nCurrently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant,\nbut is not implemented on the SDK by default. To enable EIP-191, you need\nto pass a custom `TxConfig` that has an implementation of\n`SignModeHandler` for EIP-191. The SDK may decide to fully support\nEIP-191 in the future.\n\nSince: cosmos-sdk 0.45.2"}}},"multi":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo.Multi","title":"multi represents a nested multisig signer"}},"description":"ModeInfo describes the signing mode of a single or nested multisig signer."},"cosmos.tx.v1beta1.ModeInfo.Multi":{"type":"object","properties":{"bitarray":{"title":"bitarray specifies which keys within the multisig are signing","type":"object","properties":{"extra_bits_stored":{"type":"integer","format":"int64"},"elems":{"type":"string","format":"byte"}},"description":"CompactBitArray is an implementation of a space efficient bit array.\nThis is used to ensure that the encoded data takes up a minimal amount of\nspace after proto encoding.\nThis is not thread safe, and is not intended for concurrent usage."},"mode_infos":{"type":"array","items":{"$ref":"#/components/schemas/cosmos.tx.v1beta1.ModeInfo"},"title":"mode_infos is the corresponding modes of the signers of the multisig\nwhich could include nested multisig public keys"}},"title":"Multi is the mode info for a multisig public key"}}}}
```


# Upgrade

## GET /cosmos/upgrade/v1beta1/upgraded\_consensus\_state/{last\_height}

> UpgradedConsensusState queries the consensus state that will serve\
> as a trusted kernel for the next version of this chain. It will only be\
> stored at the last height of this chain.\
> UpgradedConsensusState RPC not supported with legacy querier\
> This rpc is deprecated now that IBC has its own replacement\
> (<https://github.com/cosmos/ibc-go/blob/2c880a22e9f9cc75f62b527ca94aa75ce1106001/proto/ibc/core/client/v1/query.proto#L54>)

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/upgrade/v1beta1/upgraded_consensus_state/{last_height}":{"get":{"summary":"UpgradedConsensusState queries the consensus state that will serve\nas a trusted kernel for the next version of this chain. It will only be\nstored at the last height of this chain.\nUpgradedConsensusState RPC not supported with legacy querier\nThis rpc is deprecated now that IBC has its own replacement\n(https://github.com/cosmos/ibc-go/blob/2c880a22e9f9cc75f62b527ca94aa75ce1106001/proto/ibc/core/client/v1/query.proto#L54)","operationId":"UpgradedConsensusState","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"upgraded_consensus_state":{"type":"string","format":"byte","title":"Since: cosmos-sdk 0.43"}},"description":"QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState\nRPC method."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"last_height","description":"last height of the current chain must be sent in request\nas this is the height under which next consensus state is stored","in":"path","required":true,"type":"string","format":"int64"}],"tags":["Query"]}}}}
```

## GET /cosmos/upgrade/v1beta1/applied\_plan/{name}

> AppliedPlan queries a previously applied upgrade plan by its name.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/upgrade/v1beta1/applied_plan/{name}":{"get":{"summary":"AppliedPlan queries a previously applied upgrade plan by its name.","operationId":"AppliedPlan","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"height":{"type":"string","format":"int64","description":"height is the block height at which the plan was applied."}},"description":"QueryAppliedPlanResponse is the response type for the Query/AppliedPlan RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"name","description":"name is the name of the applied plan to query for.","in":"path","required":true,"type":"string"}],"tags":["Query"]}}}}
```

## Returns the account with authority to conduct upgrades

> Since: cosmos-sdk 0.46

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/upgrade/v1beta1/authority":{"get":{"summary":"Returns the account with authority to conduct upgrades","description":"Since: cosmos-sdk 0.46","operationId":"Authority","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"address":{"type":"string"}},"description":"Since: cosmos-sdk 0.46","title":"QueryAuthorityResponse is the response type for Query/Authority"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## GET /cosmos/upgrade/v1beta1/current\_plan

> CurrentPlan queries the current upgrade plan.

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/upgrade/v1beta1/current_plan":{"get":{"summary":"CurrentPlan queries the current upgrade plan.","operationId":"CurrentPlan","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"plan":{"description":"plan is the current upgrade plan.","type":"object","properties":{"name":{"type":"string","description":"Sets the name for the upgrade. This name will be used by the upgraded\nversion of the software to apply any special \"on-upgrade\" commands during\nthe first BeginBlock method after the upgrade is applied. It is also used\nto detect whether a software version can handle a given upgrade. If no\nupgrade handler with this name has been set in the software, it will be\nassumed that the software is out-of-date when the upgrade Time or Height is\nreached and the software will exit."},"time":{"type":"string","format":"date-time","description":"Deprecated: Time based upgrades have been deprecated. Time based upgrade logic\nhas been removed from the SDK.\nIf this field is not empty, an error will be thrown."},"height":{"type":"string","format":"int64","description":"The height at which the upgrade must be performed."},"info":{"type":"string","title":"Any application specific upgrade info to be included on-chain\nsuch as a git commit that validators could automatically upgrade to"},"upgraded_client_state":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}},"description":"QueryCurrentPlanResponse is the response type for the Query/CurrentPlan RPC\nmethod."}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"tags":["Query"]}}}}
```

## ModuleVersions queries the list of module versions from state.

> Since: cosmos-sdk 0.43

```json
{"openapi":"3.1.1","info":{"title":"Kiichain - HTTP API Console","version":"v1"},"servers":[{"url":"https://lcd.uno.sentry.testnet.v3.kiivalidator.com"}],"paths":{"/cosmos/upgrade/v1beta1/module_versions":{"get":{"summary":"ModuleVersions queries the list of module versions from state.","description":"Since: cosmos-sdk 0.43","operationId":"ModuleVersions","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","properties":{"module_versions":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","title":"name of the app module"},"version":{"type":"string","format":"uint64","title":"consensus version of the app module"}},"description":"ModuleVersion specifies a module and its consensus version.\n\nSince: cosmos-sdk 0.43"},"description":"module_versions is a list of module names with their consensus versions."}},"description":"QueryModuleVersionsResponse is the response type for the Query/ModuleVersions\nRPC method.\n\nSince: cosmos-sdk 0.43"}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"type_url":{"type":"string","description":"A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n  value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n  URL, or have them precompiled into a binary to avoid any\n  lookup. Therefore, binary compatibility needs to be preserved\n  on changes to types. (Use versioned type names to manage\n  breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics."},"value":{"type":"string","format":"byte","description":"Must be a valid serialized protocol buffer of the above specified type."}},"description":"`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n    Foo foo = ...;\n    Any any;\n    any.PackFrom(foo);\n    ...\n    if (any.UnpackTo(&foo)) {\n      ...\n    }\n\nExample 2: Pack and unpack a message in Java.\n\n    Foo foo = ...;\n    Any any = Any.pack(foo);\n    ...\n    if (any.is(Foo.class)) {\n      foo = any.unpack(Foo.class);\n    }\n    // or ...\n    if (any.isSameTypeAs(Foo.getDefaultInstance())) {\n      foo = any.unpack(Foo.getDefaultInstance());\n    }\n\nExample 3: Pack and unpack a message in Python.\n\n    foo = Foo(...)\n    any = Any()\n    any.Pack(foo)\n    ...\n    if any.Is(Foo.DESCRIPTOR):\n      any.Unpack(foo)\n      ...\n\nExample 4: Pack and unpack a message in Go\n\n     foo := &pb.Foo{...}\n     any, err := anypb.New(foo)\n     if err != nil {\n       ...\n     }\n     ...\n     foo := &pb.Foo{}\n     if err := any.UnmarshalTo(foo); err != nil {\n       ...\n     }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\nJSON\n\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n    package google.profile;\n    message Person {\n      string first_name = 1;\n      string last_name = 2;\n    }\n\n    {\n      \"@type\": \"type.googleapis.com/google.profile.Person\",\n      \"firstName\": <string>,\n      \"lastName\": <string>\n    }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n    {\n      \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n      \"value\": \"1.212s\"\n    }"}}}}}}}},"parameters":[{"name":"module_name","description":"module_name is a field to query a specific module\nconsensus version from state. Leaving this empty will\nfetch the full list of module versions from state.","in":"query","required":false,"type":"string"}],"tags":["Query"]}}}}
```


# Developer Tools

Build on the ecosystem.

An overview of developer tools, SDKs and resources for accessing the network.


# RWA Protocol

T-REX Protocol on KiiChain

**Note: This project is still under development so future changes will be made.**

### Overview

This document outlines the detailed implementation plan for the T-REX (Token for Regulated EXchanges) protocol using CosmWasm smart contracts on KiiChain. The T-REX protocol is designed for compliant issuance and management of tokens on blockchain networks.

### Important Links

* [GitHub Repo](https://github.com/KiiChain/Kii-RWA-Protocol)
* [Rust SDK](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/rust-sdk)

### Contracts and Their Methods

#### 1. CW20 T-REX Token

Extends the CW20 standard with T-REX functionalities and implements permissioned transfers.

**Storage**

* `token_info`: TokenInfo
* `balances`: Map\<Addr, Uint128>
* `allowances`: Map<(Addr, Addr), AllowanceInfo>
* `identity_registry`: Addr
* `compliance`: Addr

**Execute**

* `transfer(recipient: Addr, amount: Uint128) -> Result<Response>`
  * Description: Transfers tokens to a recipient if they are verified and compliant.
  * Interaction: Calls `is_verified` on Identity Registry and `can_transfer` on Modular Compliance.
* `transfer_from(owner: Addr, recipient: Addr, amount: Uint128) -> Result<Response>`
  * Description: Transfers tokens on behalf of the owner if the recipient is verified and compliant.
  * Interaction: Similar to `transfer`, but checks allowances first.

**Query**

* `balance(address: Addr) -> BalanceResponse`
* `token_info() -> TokenInfoResponse`
* `is_verified_transfer(from: Addr, to: Addr, amount: Uint128) -> IsVerifiedTransferResponse`
  * Description: Checks if a transfer would be valid without executing it.
  * Interaction: Calls Identity Registry and Modular Compliance.

#### 2. Identity Registry

Manages investor identities and eligibility.

**Storage**

* `identity_storage`: Addr
* `trusted_issuers_registry`: Addr
* `claim_topics_registry`: Addr
* `agents`: Vec

**Execute**

* `register_identity(address: Addr, identity: Addr) -> Result<Response>`
  * Description: Registers a new identity for an address.
  * Interaction: Calls Identity Registry Storage to store the mapping.
* `update_identity(address: Addr, identity: Addr) -> Result<Response>`
  * Description: Updates an existing identity for an address.
* `remove_identity(address: Addr) -> Result<Response>`
  * Description: Removes an identity for an address.

**Query**

* `is_verified(address: Addr) -> IsVerifiedResponse`
  * Description: Checks if an address is verified (has required claims).
  * Interaction: Queries Identity Registry Storage, Trusted Issuers Registry, and Claim Topics Registry.

#### 3. Identity Registry Storage

Stores the mapping of wallet addresses to identity contracts.

**Storage**

* `identities`: Map\<Addr, Addr>

**Execute**

* `add_identity(address: Addr, identity: Addr) -> Result<Response>`
* `remove_identity(address: Addr) -> Result<Response>`

**Query**

* `get_identity(address: Addr) -> GetIdentityResponse`

#### 4. Trusted Issuers Registry

Manages the list of trusted claim issuers.

**Storage**

* `trusted_issuers`: Map\<Addr, TrustedIssuer>

**Execute**

* `add_trusted_issuer(issuer: Addr, claim_topics: Vec<u32>) -> Result<Response>`
* `remove_trusted_issuer(issuer: Addr) -> Result<Response>`

**Query**

* `is_trusted_issuer(issuer: Addr) -> IsTrustedIssuerResponse`
* `get_trusted_issuers() -> GetTrustedIssuersResponse`

#### 5. Claim Topics Registry

Stores the required claim topics for token eligibility.

**Storage**

* `required_claim_topics`: Vec

**Execute**

* `add_claim_topic(topic: u32) -> Result<Response>`
* `remove_claim_topic(topic: u32) -> Result<Response>`

**Query**

* `get_required_claim_topics() -> GetRequiredClaimTopicsResponse`

#### 6. Modular Compliance

Implements transfer restriction rules.

**Storage**

* `modules`: Vec
* `bound_tokens`: Vec

**Execute**

* `add_module(module: Addr) -> Result<Response>`
* `remove_module(module: Addr) -> Result<Response>`
* `bind_token(token: Addr) -> Result<Response>`

**Query**

* `can_transfer(from: Addr, to: Addr, amount: Uint128) -> CanTransferResponse`
  * Description: Checks if a transfer complies with all modules.
  * Interaction: Calls `check_transfer` on each compliance module.

#### 7. ONCHAINID

Represents user identities (similar to ERC-734/735).

**Storage**

* `keys`: Map\<bytes32, Key>
* `claims`: Map\<bytes32, Claim>

**Execute**

* `add_key(key: bytes32, purpose: u32, key_type: u32) -> Result<Response>`
* `remove_key(key: bytes32) -> Result<Response>`
* `add_claim(topic: u32, scheme: u32, issuer: Addr, signature: Vec<u8>, data: Vec<u8>, uri: String) -> Result<Response>`
* `remove_claim(topic: u32) -> Result<Response>`

**Query**

* `get_key(key: bytes32) -> GetKeyResponse`
* `get_claim(topic: u32) -> GetClaimResponse`

#### 8. T-REX Factory

Deploys and configures T-REX token suites.

**Storage**

* `implementation_authority`: Addr
* `deployed_tokens`: Vec

**Execute**

* `deploy_token_suite(token_info: TokenInfo, compliance_info: ComplianceInfo, identity_info: IdentityInfo) -> Result<Response>`
  * Description: Deploys a new T-REX token suite.
  * Interaction: Instantiates all necessary contracts and configures them.

**Query**

* `get_deployed_tokens() -> GetDeployedTokensResponse`

#### 9. Implementation Authority

Manages contract upgrades and versioning.

**Storage**

* `versions`: Map\<String, ContractVersion>
* `current_version`: String

**Execute**

* `add_version(name: String, contracts: Vec<(String, Addr)>) -> Result<Response>`
* `set_current_version(name: String) -> Result<Response>`

**Query**

* `get_current_version() -> GetCurrentVersionResponse`
* `get_version(name: String) -> GetVersionResponse`

### Implementation Roadmap

1. Implement CW20 T-REX Token
2. Implement Identity Registry and Identity Registry Storage
3. Implement Trusted Issuers Registry and Claim Topics Registry
4. Implement Modular Compliance
5. Implement ONCHAINID
6. Implement T-REX Factory
7. Implement Implementation Authority
8. Integrate all contracts and perform thorough testing
9. Conduct security audit
10. Deploy to Kii-Chain testnet
11. Final testing and adjustments
12. Deploy to Kii-Chain mainnet

### Testing Strategy

* Implement unit tests for each contract function
* Develop integration tests for contract interactions
* Create end-to-end scenarios to test the entire T-REX suite
* Perform fuzz testing to uncover edge cases
* Conduct governance testing to ensure proper access control


# Rust SDK

Rust SDK for the RWA Protocol on KiiChain

**Note: This project is still under development so future changes will be made.**

### Important Links

* [Github RWA Repo](https://github.com/KiiChain/Kii-RWA-Protocol)
* [Rust SDK Repo](https://github.com/KiiChain/kiirust-sdk)

### KiiChain RWA SDK

The RWA (Real World Asset) SDK is a Rust library for interacting with tokenized real-world assets on Cosmos-based blockchains. It provides functionality for token operations, identity management, and compliance handling.

#### Features

* Token transfers and balance checks
* Identity registration and management
* Compliance module integration
* Blockchain interaction via RPC

#### Usage Example

```rust
use rwa_sdk::RwaClient;
use cosmrs::crypto::secp256k1::SigningKey;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    // Initialize the client
    let client = RwaClient::new(
        "http://rpc.example.com:26657",
        "my-chain-id",
        "cosmos1token...",
        "cosmos1identity...",
        "cosmos1compliance...",
        "sei",
        "gas_price"

    )?;

    // Perform a token transfer
    let signer = SigningKey::from_slice(&[/* your private key */])?;
    let transfer_result = client.transfer(TransferMessageRequest {
        from: "cosmos1sender...".to_string(),
        to: "cosmos1recipient...".to_string(),
        amount: 100,
        signer,
        gas_limit
    }).await?;
    println!("Transfer hash: {}", transfer_result.hash);

    // Check a balance
    let balance = client.balance(TokenInfoRequest {
        address: "cosmos1address...".to_string(),
    }).await?;
    println!("Balance: {}", balance.balance);

    Ok(())
}
```

This example demonstrates how to initialize the `RwaClient`, perform a token transfer, and check an account balance. Error handling and proper setup of the signing key are crucial for production use.

For more detailed information on each function and module, please refer to their respective documentation.


# JS/TS SDK

An SDK written in Javascript/Typescript for KiiChain

**Note: This project is still under development, so future changes will be made.**

## Kiijs-SDK

KiiJS is a monorepo that contains multiple NPM libraries for writing applications that interact with KiiChain. Apart from the built SDK, the chain matches a lot of operability from cosmjs.

### Documentation

Each package has its own documentation under its readme file.

### Packages

KiiJS consists of smaller NPM packages within the @kiichain namespace. For more detailed documentation on each package, please refer to the table below.

| Package                                                                                                         | Description                                                                                            |
| --------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------ |
| [@kiichain/kiijs-evm](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/js-ts-sdk/kiijs-evm)     | Typescript library containing helper functions for interacting with the EVM on Kiichain.               |
| [@kiichain/kiijs-proto](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/js-ts-sdk/kiijs-proto) | Typescript support for KiiChain protofiles, generated with Telescope                                   |
| [@kiichain/kiijs-utils](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/js-ts-sdk/kiijs-utils) | Typescript support for a few generic Kiichain functions, like address conversion or ethscp256-1 signer |

### Contributing

All contributions are very welcome! Remember, contribution is not only PRs and code, but any help with docs or helping other developers solve their issues are very appreciated!

Read below to learn how you can take part in the KiiPy project.

#### Code of Conduct

Please be sure to read and follow our [Code of Conduct](https://github.com/KiiChain/kiijs-sdk/blob/main/CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code.

#### Contribution Guidelines

Read our [contribution guidelines](https://github.com/KiiChain/kiijs-sdk/blob/main/CONTRIBUTING.md) to learn about our issue and pull request submission processes, coding rules, and more.

#### Issues, Questions and Discussions

We use [GitHub Issues](https://github.com/KiiChain/kiijs-sdk/issues) for tracking requests and bugs, for general questions and discussion.

### License

The KiiPy project is licensed under [Apache License 2.0](https://github.com/KiiChain/kiijs-sdk/blob/main/LICENSE).


# Kiijs-evm

## @kiichain/kiijs-evm

Typescript library containing helper functions for interacting with the EVM on KiiChain. The full code can be found here: <https://github.com/KiiChain/kiijs-sdk/tree/main/packages/evm>

### Installation

```bash
yarn add @kiichain/kiijs-evm ethers viem
```

### Wallet Connection

This package provides exports for easily interacting with viem, and ethers.js. You can interact with the KiiChain EVM using all the same hooks and helper functions these tools offer. Read the viem and ethers v6 documentation for more information on how to use these tools.

#### Wallet network setup

Ensure that your EVM wallet has the KiiChain network enabled.

#### Connection with ethers v6

The 'ethers' package is a popular library for interacting with the Ethereum blockchain. This package provides a helper function for creating an ethers provider that is connected to the KiiChain EVM.

```tsx
import { getBankPrecompileEthersV6Contract } from '@kiichain/kiijs-evm';
import { ethers } from 'ethers';

const provider = new ethers.BrowserProvider(window.ethereum); // or any other provider
const signer = await provider.getSigner();

const accounts = await provider.send('eth_requestAccounts', []);

const contract = getBankPrecompileEthersV6Contract(signer);

const cosmosAddress = await contract.balances("yourAddress");
```

An alternative without the popup is to directly use your private key to connect.

```tsx
import { ethers } from 'ethers';

const provider = new ethers.JsonRpcProvider('https://json-rpc.dos.sentry.testnet.v3.kiivalidator.com/');
const wallet = new ethers.Wallet("0xyourprivatekey", provider);
```

#### Usage with viem

This package exports `viem` Chains and precompile ABI's for KiiChain. The ABI used in the ethers example above is a viem ABI instance and the `ARCTIC_1_VIEM_CHAIN` is a `viem Chain` instance.

### Interoperability with Cosmos

KiiChain supports both EVM JSON-RPC and Cosmos RPC interfaces. In order to easily interact with certain Cosmos modules, KiiChain has a set of precompiled contracts that can be called from the EVM.

| Precompile                                          | Description                                                                                              |
| --------------------------------------------------- | -------------------------------------------------------------------------------------------------------- |
| [Bank Precompile](#bank-precompile)                 | Provides functionalities for checking balances and supply.                                               |
| [Bech32 Precompile](#bech32-precompile)             | Facilitates conversion between hex address and bech32                                                    |
| [Distribution Precompile](#distribution-precompile) | Deals with reward distribution and related                                                               |
| [Governance Precompile](#governance-precompile)     | Supports actions such as depositing funds into proposals, voting and interacting with proposals.         |
| [IBC Precompile](#ibc-precompile)                   | Allows IBC transfers                                                                                     |
| [ICS20 Precompile](#ics20-precompile)               | Facilitates conversion between hex address and bech32                                                    |
| [Slashing Precompile](#slashing-precompile)         | Provides management and query options for penalties                                                      |
| [Staking Precompile](#staking-precompile)           | Enables staking functionalities like delegation and undelegation or obtaining information on validators. |
| [Wasm Precompile](#wasm-precompile)                 | Precompile for interacting with wasm contracts                                                           |

#### Interoperability using Wagmi, viem, and ethers

Each precompile has contract exports a typed 'ethers' contracts and provides the ABI and contract addresses for each precompile for usage with Wagmi and viem.

### Bank Precompile

The Bank precompile contract provides functionalities for managing balances, supply, symbols, and more.

**Functions**

| Function Name | Input Parameters | Return Value                                     | Description                                                          |
| ------------- | ---------------- | ------------------------------------------------ | -------------------------------------------------------------------- |
| `balances`    | `acc: string`    | `balances : [{ denom: string, amount: string }]` | Retrieves the balances of a given address                            |
| `supplyOf`    | `denom: string`  | `{ response: string }`                           | Retrieves the total supply of tokens for the specified denomination. |
| `totalSupply` | -                | `balances : [{ denom: string, amount: string }]` | Retrieves all the supplies from the chain                            |

**Precompile Addresses**

0x000000000000000000000000000000000000080

### Bech32 Precompile

The bech32 precompile contract provides ways to turn a hex address to bech32 and vice-versa. There is also functions in the library under the precompile to do the same without using the contract.

```tsx
import { HexToBech32, Bech32ToHex } from '@kiichain/kiijs-evm'

const kiiAddress = HexToBech32("0xyourhex")

const evmAddress = Bech32ToHex("kiiYouraddress)
```

### Distribution Precompile

The Distribution precompile contract facilitates operations related to rewards withdrawal and distribution.

**Functions**

Here's the table representation of your Distribution ABI:

| Function Name                 | Input Parameters                                                                                                                                                                                                                                             | Return Value                                                                                                                                                                                                 | Description                                        |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------- |
| `claimRewards`                | <p><code>delegatorAddress: string</code> (address)<br><code>maxRetrieve: number</code> (uint32)</p>                                                                                                                                                          | `success: boolean`                                                                                                                                                                                           | Claims rewards for a delegator (up to maxRetrieve) |
| `delegationRewards`           | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code></p>                                                                                                                                                              | `rewards: [{ denom: string, amount: string, precision: number }]`                                                                                                                                            | Gets rewards for a specific delegation             |
| `delegationTotalRewards`      | `delegatorAddress: string` (address)                                                                                                                                                                                                                         | <p><code>rewards: \[{ validatorAddress: string, reward: \[{ denom: string, amount: string, precision: number }] }]</code><br><code>total: \[{ denom: string, amount: string, precision: number }]</code></p> | Gets all rewards for a delegator with totals       |
| `delegatorValidators`         | `delegatorAddress: string` (address)                                                                                                                                                                                                                         | `validators: string[]`                                                                                                                                                                                       | Lists all validators a delegator is staked with    |
| `delegatorWithdrawAddress`    | `delegatorAddress: string` (address)                                                                                                                                                                                                                         | `withdrawAddress: string`                                                                                                                                                                                    | Gets the withdrawal address for a delegator        |
| `fundCommunityPool`           | <p><code>depositor: string</code> (address)<br><code>amount: string</code> (uint256)</p>                                                                                                                                                                     | `success: boolean`                                                                                                                                                                                           | Funds the community pool                           |
| `setWithdrawAddress`          | <p><code>delegatorAddress: string</code> (address)<br><code>withdrawerAddress: string</code></p>                                                                                                                                                             | `success: boolean`                                                                                                                                                                                           | Sets the withdrawal address for rewards            |
| `validatorCommission`         | `validatorAddress: string`                                                                                                                                                                                                                                   | `commission: [{ denom: string, amount: string, precision: number }]`                                                                                                                                         | Gets commission rewards for a validator            |
| `validatorDistributionInfo`   | `validatorAddress: string`                                                                                                                                                                                                                                   | `distributionInfo: { operatorAddress: string, selfBondRewards: [{ denom: string, amount: string, precision: number }], commission: [{ denom: string, amount: string, precision: number }] }`                 | Gets full distribution info for a validator        |
| `validatorOutstandingRewards` | `validatorAddress: string`                                                                                                                                                                                                                                   | `rewards: [{ denom: string, amount: string, precision: number }]`                                                                                                                                            | Gets outstanding rewards for a validator           |
| `validatorSlashes`            | <p><code>validatorAddress: string</code><br><code>startingHeight: number</code> (uint64)<br><code>endingHeight: number</code> (uint64)<br><code>pageRequest: { key: bytes, offset: number, limit: number, countTotal: boolean, reverse: boolean }</code></p> | <p><code>slashes: \[{ validatorPeriod: number, fraction: { value: string, precision: number } }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p>                                  | Gets slash events for a validator with pagination  |
| `withdrawDelegatorRewards`    | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code></p>                                                                                                                                                              | `amount: [{ denom: string, amount: string }]`                                                                                                                                                                | Withdraws delegator's rewards from a validator     |
| `withdrawValidatorCommission` | `validatorAddress: string`                                                                                                                                                                                                                                   | `amount: [{ denom: string, amount: string }]`                                                                                                                                                                | Withdraws validator's commission rewards           |

**Precompile Addresses**

0x0000000000000000000000000000000000000801

### Evidence Precompile

The Evidence precompile contract provides functionalities for dealing with evidences.

**Functions**

| Function Name    | Input Parameters                                                                                    | Return Value                                                                                                                                                               | Description                                    |
| ---------------- | --------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------- |
| `evidence`       | `evidenceHash: bytes`                                                                               | `evidence: { height: number, time: number, power: number, consensusAddress: string }`                                                                                      | Retrieves evidence by its hash                 |
| `getAllEvidence` | `pageRequest: { key: bytes, offset: number, limit: number, countTotal: boolean, reverse: boolean }` | <p><code>evidence: \[{ height: number, time: number, power: number, consensusAddress: string }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p> | Retrieves all evidence with pagination support |
| `submitEvidence` | `evidence: { height: number, time: number, power: number, consensusAddress: string }`               | `success: boolean`                                                                                                                                                         | Submits new evidence of validator equivocation |

**Precompile Addresses**

0x0000000000000000000000000000000000000807

### Governance Precompile

The Governance precompile contract supports actions to deposit funds into proposals, view them and interact with them.

**Functions**

| Function Name    | Input Parameters                                                                                                                                                                        | Return Value                                                                                                                                                                                          | Description                                      |
| ---------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------ |
| `getDeposit`     | <p><code>proposalId: number</code> (uint64)<br><code>depositor: string</code> (address)</p>                                                                                             | `deposit: { proposalId: number, depositor: string, amount: [{ denom: string, amount: string }] }`                                                                                                     | Gets a specific deposit for a proposal           |
| `getDeposits`    | <p><code>proposalId: number</code> (uint64)<br><code>pagination: { key: bytes, offset: number, limit: number, countTotal: boolean, reverse: boolean }</code></p>                        | <p><code>deposits: \[{ proposalId: number, depositor: string, amount: \[{ denom: string, amount: string }] }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p>              | Gets all deposits for a proposal with pagination |
| `getParams`      | -                                                                                                                                                                                       | `params: { votingPeriod: number, minDeposit: [{ denom: string, amount: string }], maxDepositPeriod: number, quorum: string, threshold: string, vetoThreshold: string, ... }`                          | Returns governance parameters                    |
| `getProposal`    | `proposalId: number` (uint64)                                                                                                                                                           | `proposal: { id: number, messages: string[], status: number, finalTallyResult: { yes: string, abstain: string, no: string, noWithVeto: string }, submitTime: number, ... }`                           | Gets full proposal details                       |
| `getProposals`   | <p><code>proposalStatus: number</code> (uint32)<br><code>voter: string</code> (address)<br><code>depositor: string</code> (address)<br><code>pagination: { ... }</code></p>             | <p><code>proposals: \[{ id: number, messages: string\[], status: number, finalTallyResult: { ... }, ... }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p>                 | Lists proposals with filters and pagination      |
| `getTallyResult` | `proposalId: number` (uint64)                                                                                                                                                           | `tallyResult: { yes: string, abstain: string, no: string, noWithVeto: string }`                                                                                                                       | Gets current tally results for a proposal        |
| `getVote`        | <p><code>proposalId: number</code> (uint64)<br><code>voter: string</code> (address)</p>                                                                                                 | `vote: { proposalId: number, voter: string, options: [{ option: number, weight: string }], metadata: string }`                                                                                        | Gets an individual vote                          |
| `getVotes`       | <p><code>proposalId: number</code> (uint64)<br><code>pagination: { ... }</code></p>                                                                                                     | <p><code>votes: \[{ proposalId: number, voter: string, options: \[{ option: number, weight: string }], metadata: string }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p> | Gets all votes for a proposal with pagination    |
| `vote`           | <p><code>voter: string</code> (address)<br><code>proposalId: number</code> (uint64)<br><code>option: number</code> (uint8)<br><code>metadata: string</code></p>                         | `success: boolean`                                                                                                                                                                                    | Submits a vote on a proposal                     |
| `voteWeighted`   | <p><code>voter: string</code> (address)<br><code>proposalId: number</code> (uint64)<br><code>options: \[{ option: number, weight: string }]</code><br><code>metadata: string</code></p> | `success: boolean`                                                                                                                                                                                    | Submits a weighted vote on a proposal            |

**Precompile Addresses**

0x0000000000000000000000000000000000000805

### IBC Precompile

Enables cross-chain token transfers via IBC with simplified parameters

**Functions**

| Function Name                    | Input Parameters                                                                                                                                                                                                                                                                                                                                                  | Return Value       | Description                                                                           |
| -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ | ------------------------------------------------------------------------------------- |
| **`transfer`**                   | <p><code>receiver: string</code> (address)<br><code>port: string</code><br><code>channel: string</code><br><code>denom: string</code><br><code>amount: string</code> (uint256)<br><code>revisionNumber: number</code> (uint64)<br><code>revisionHeight: number</code> (uint64)<br><code>timeoutTimestamp: number</code> (uint64)<br><code>memo: string</code></p> | `success: boolean` | Initiates an IBC token transfer with full timeout control (both height and timestamp) |
| **`transferWithDefaultTimeout`** | <p><code>receiver: string</code> (address)<br><code>port: string</code><br><code>channel: string</code><br><code>denom: string</code><br><code>amount: string</code> (uint256)<br><code>memo: string</code></p>                                                                                                                                                   | `success: boolean` | Initiates an IBC transfer using default timeout values (simplified interface)         |

**Precompile Addresses**

0x0000000000000000000000000000000000001002

### ICS20 Precompile

Enables cross-chain token transfers via IBC with granular permission control over channels and denominations.

**Functions**

| Function Name           | Input Parameters                                                                                                                                                                                                                                                                                                                                                                      | Return Value                                                                                                                                                      | Description                                                                                   |
| ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
| **`allowance`**         | <p><code>grantee: string</code> (address)<br><code>granter: string</code> (address)</p>                                                                                                                                                                                                                                                                                               | `allocations: [{ sourcePort: string, sourceChannel: string, spendLimit: [{ denom: string, amount: string }], allowList: string[], allowedPacketData: string[] }]` | Checks granted IBC transfer permissions                                                       |
| **`approve`**           | <p><code>grantee: string</code> (address)<br><code>allocations: \[{ sourcePort: string, sourceChannel: string, spendLimit: \[{ denom: string, amount: string }], ... }]</code></p>                                                                                                                                                                                                    | `approved: boolean`                                                                                                                                               | Grants IBC transfer permissions                                                               |
| **`decreaseAllowance`** | <p><code>grantee: string</code> (address)<br><code>sourcePort: string</code><br><code>sourceChannel: string</code><br><code>denom: string</code><br><code>amount: string</code> (uint256)</p>                                                                                                                                                                                         | `approved: boolean`                                                                                                                                               | Reduces spend limit for a specific channel/denom                                              |
| **`denomHash`**         | `trace: string` (e.g., "transfer/channel-1/uatom")                                                                                                                                                                                                                                                                                                                                    | `hash: string` (IBC denom hash)                                                                                                                                   | Converts IBC denom trace to hash (e.g., `ibc/27394FB092...`)                                  |
| **`denomTrace`**        | `hash: string` (IBC denom hash)                                                                                                                                                                                                                                                                                                                                                       | `denomTrace: { path: string, baseDenom: string }`                                                                                                                 | Decodes IBC hash to original trace (e.g., `path: "transfer/channel-1"`, `baseDenom: "uatom"`) |
| **`denomTraces`**       | `pageRequest: { key: bytes, offset: number, limit: number, ... }`                                                                                                                                                                                                                                                                                                                     | <p><code>denomTraces: \[{ path: string, baseDenom: string }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p>                           | Lists all registered denom traces with pagination                                             |
| **`increaseAllowance`** | <p><code>grantee: string</code> (address)<br><code>sourcePort: string</code><br><code>sourceChannel: string</code><br><code>denom: string</code><br><code>amount: string</code> (uint256)</p>                                                                                                                                                                                         | `approved: boolean`                                                                                                                                               | Increases spend limit for a specific channel/denom                                            |
| **`revoke`**            | `grantee: string` (address)                                                                                                                                                                                                                                                                                                                                                           | `revoked: boolean`                                                                                                                                                | Revokes all IBC transfer permissions for a grantee                                            |
| **`transfer`**          | <p><code>sourcePort: string</code><br><code>sourceChannel: string</code><br><code>denom: string</code><br><code>amount: string</code> (uint256)<br><code>sender: string</code> (address)<br><code>receiver: string</code><br><code>timeoutHeight: { revisionNumber: number, revisionHeight: number }</code><br><code>timeoutTimestamp: number</code><br><code>memo: string</code></p> | `nextSequence: number` (uint64)                                                                                                                                   | Initiates an IBC token transfer                                                               |

**Precompile Addresses**

0x0000000000000000000000000000000000000802

### Slashing Precompile

Enables query, interaction and management of validator penalties.

**Functions**

| Function Name     | Input Parameters                                                                                   | Return Value                                                                                                                                                                                                                                       | Description                                     |
| ----------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------- |
| `getParams`       | -                                                                                                  | `params: { signedBlocksWindow: number, minSignedPerWindow: string, downtimeJailDuration: number, slashFractionDoubleSign: string, slashFractionDowntime: string }`                                                                                 | Returns slashing module parameters              |
| `getSigningInfo`  | `consAddress: string` (address)                                                                    | `signingInfo: { validatorAddress: string, startHeight: number, indexOffset: number, jailedUntil: number, tombstoned: boolean, missedBlocksCounter: number }`                                                                                       | Gets signing info for a validator               |
| `getSigningInfos` | `pagination: { key: bytes, offset: number, limit: number, countTotal: boolean, reverse: boolean }` | <p><code>signingInfos: \[{ validatorAddress: string, startHeight: number, indexOffset: number, jailedUntil: number, tombstoned: boolean, missedBlocksCounter: number }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p> | Gets all validator signing info with pagination |
| `unjail`          | `validatorAddress: string` (address)                                                               | `success: boolean`                                                                                                                                                                                                                                 | Releases a validator from jail status           |

**Precompile Addresses**

0x0000000000000000000000000000000000000806

### Staking Precompile

The Staking precompile manages validator operations, delegations, and governance permissions in a Cosmos-based blockchain with EVM compatibility.

**Functions**

| Function Name                   | Input Parameters                                                                                                                                                                                                                                                                                                        | Return Value                                                                                                               | Description                                                     |
| ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------- |
| **`allowance`**                 | <p><code>grantee: string</code> (address)<br><code>granter: string</code> (address)<br><code>method: string</code></p>                                                                                                                                                                                                  | `remaining: string` (uint256)                                                                                              | Checks remaining allowance for a grantee's staking actions      |
| **`approve`**                   | <p><code>grantee: string</code> (address)<br><code>amount: string</code> (uint256)<br><code>methods: string\[]</code></p>                                                                                                                                                                                               | `approved: boolean`                                                                                                        | Grants staking permissions to another address                   |
| **`cancelUnbondingDelegation`** | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code><br><code>amount: string</code> (uint256)<br><code>creationHeight: string</code> (uint256)</p>                                                                                                                               | `success: boolean`                                                                                                         | Cancels an unbonding delegation before completion               |
| **`createValidator`**           | <p><code>description: { moniker: string, identity: string, ... }</code><br><code>commissionRates: { rate: string, maxRate: string, ... }</code><br><code>minSelfDelegation: string</code><br><code>validatorAddress: string</code> (address)<br><code>pubkey: string</code><br><code>value: string</code> (uint256)</p> | `success: boolean`                                                                                                         | Registers a new validator                                       |
| **`decreaseAllowance`**         | <p><code>grantee: string</code> (address)<br><code>amount: string</code> (uint256)<br><code>methods: string\[]</code></p>                                                                                                                                                                                               | `approved: boolean`                                                                                                        | Reduces staking permissions for a grantee                       |
| **`delegate`**                  | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code><br><code>amount: string</code> (uint256)</p>                                                                                                                                                                                | `success: boolean`                                                                                                         | Delegates tokens to a validator                                 |
| **`delegation`**                | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code></p>                                                                                                                                                                                                                         | <p><code>shares: string</code> (uint256)<br><code>balance: { denom: string, amount: string }</code></p>                    | Returns delegation details between a delegator and validator    |
| **`editValidator`**             | <p><code>description: { moniker: string, ... }</code><br><code>validatorAddress: string</code> (address)<br><code>commissionRate: number</code> (int256)<br><code>minSelfDelegation: number</code> (int256)</p>                                                                                                         | `success: boolean`                                                                                                         | Modifies validator metadata/parameters                          |
| **`increaseAllowance`**         | <p><code>grantee: string</code> (address)<br><code>amount: string</code> (uint256)<br><code>methods: string\[]</code></p>                                                                                                                                                                                               | `approved: boolean`                                                                                                        | Increases staking permissions for a grantee                     |
| **`redelegate`**                | <p><code>delegatorAddress: string</code> (address)<br><code>srcValidatorAddress: string</code><br><code>dstValidatorAddress: string</code><br><code>amount: string</code> (uint256)</p>                                                                                                                                 | `completionTime: number` (int64)                                                                                           | Transfers delegation between validators (with unbonding period) |
| **`redelegation`**              | <p><code>delegatorAddress: string</code> (address)<br><code>srcValidatorAddress: string</code><br><code>dstValidatorAddress: string</code></p>                                                                                                                                                                          | `redelegation: { entries: [{ creationHeight: number, completionTime: number, ... }] }`                                     | Returns redelegation details                                    |
| **`redelegations`**             | <p><code>delegatorAddress: string</code> (address)<br><code>srcValidatorAddress: string</code><br><code>dstValidatorAddress: string</code><br><code>pageRequest: { key: bytes, ... }</code></p>                                                                                                                         | <p><code>response: \[{ redelegation: { ... } }]</code><br><code>pageResponse: { nextKey: bytes, total: number }</code></p> | Paginated redelegation history                                  |
| **`revoke`**                    | <p><code>grantee: string</code> (address)<br><code>methods: string\[]</code></p>                                                                                                                                                                                                                                        | `revoked: boolean`                                                                                                         | Revokes all staking permissions for a grantee                   |
| **`unbondingDelegation`**       | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code></p>                                                                                                                                                                                                                         | `unbondingDelegation: { entries: [{ creationHeight: number, completionTime: number, ... }] }`                              | Returns active unbonding delegations                            |
| **`undelegate`**                | <p><code>delegatorAddress: string</code> (address)<br><code>validatorAddress: string</code><br><code>amount: string</code> (uint256)</p>                                                                                                                                                                                | `completionTime: number` (int64)                                                                                           | Initiates token unbonding from a validator                      |
| **`validator`**                 | `validatorAddress: string` (address)                                                                                                                                                                                                                                                                                    | `validator: { operatorAddress: string, jailed: boolean, tokens: string, ... }`                                             | Returns validator details by address                            |
| **`validators`**                | <p><code>status: string</code><br><code>pageRequest: { key: bytes, ... }</code></p>                                                                                                                                                                                                                                     | <p><code>validators: \[{ operatorAddress: string, jailed: boolean, ... }]</code><br><code>pageResponse: { ... }</code></p> | Lists validators (filtered by status) with pagination           |

**Precompile Addresses**

0x0000000000000000000000000000000000000800

### Wasm Precompile

The wasm precompile makes wasm contracts available to being used via evm, with instantiate, query and execute.

**Functions**

| Function Name     | Input Parameters                                                                                                                                                                                                    | Return Value                  | Description                                             |
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------- | ------------------------------------------------------- |
| **`execute`**     | <p><code>contractAddress: string</code><br><code>msg: bytes</code> (JSON-encoded)<br><code>coins: \[{ denom: string, amount: string }]</code></p>                                                                   | `success: boolean`            | Executes a contract method with optional token transfer |
| **`instantiate`** | <p><code>admin: string</code> (address)<br><code>codeID: number</code> (uint64)<br><code>label: string</code><br><code>msg: bytes</code> (init msg)<br><code>coins: \[{ denom: string, amount: string }]</code></p> | `success: boolean`            | Deploys a new contract instance from stored code        |
| **`queryRaw`**    | <p><code>contractAddress: string</code><br><code>queryData: bytes</code> (raw query)</p>                                                                                                                            | `data: bytes` (raw response)  | Low-level contract query (returns raw bytes)            |
| **`querySmart`**  | <p><code>contractAddress: string</code><br><code>msg: bytes</code> (JSON-encoded query)</p>                                                                                                                         | `data: bytes` (JSON response) | Smart query (parses input/output as JSON)               |

**Precompile Addresses**

0x0000000000000000000000000000000000001001

\ <br>


# Kiijs-proto

## @kiichain/kiijs-evm

### install

```sh
npm install @kiichain/kiijs-proto
```

### Usage

You can utilize the types to build and send messages. To query, you can utilize an RPC query client, while for transactions you will need a wallet client paired with composing a message and then broadcasting it.

#### RPC Clients

To create an RPC client you can import the following helper and utilize it:

```js
import { kiichain } from '@kiichain/kiijs-proto';

const { createRPCQueryClient } = kiichain.ClientFactory; 
const client = await createRPCQueryClient({ rpcEndpoint: RPC_ENDPOINT });

// now you can query the cosmos modules
const balance = await client.cosmos.bank.v1beta1
    .balance({ address: 'kiichain1addresshere', denom: 'akii' });

```

Explore the types to find out what types of queries are available and how to utilized them.

#### Composing Messages

To compose messages, you can utilize the message composer of the respective type you want to build. For instance, tokenfactory messages can be found like this:

```js
import { kiichain } from '@kiichain/kiijs-proto';

const {
    createDenom,
    mint,
    burn,
    changeAdmin,
    setDenomMetadata,
    forceTransfer,
    updateParams
} = kiichain.tokenfactory.v1beta1.MessageComposer.withTypeUrl;
```

We have a small section with a few more examples.

**Cosmos Messages**

```js
import { cosmos } from '@kiichain/kiijs-proto';

const {
    fundCommunityPool,
    setWithdrawAddress,
    withdrawDelegatorReward,
    withdrawValidatorCommission
} = cosmos.distribution.v1beta1.MessageComposer.fromPartial;

const {
    multiSend,
    send
} = cosmos.bank.v1beta1.MessageComposer.fromPartial;

const {
    beginRedelegate,
    createValidator,
    delegate,
    editValidator,
    undelegate
} = cosmos.staking.v1beta1.MessageComposer.fromPartial;

const {
    deposit,
    submitProposal,
    vote,
    voteWeighted
} = cosmos.gov.v1beta1.MessageComposer.fromPartial;
```

### Connecting with Wallets and Signing Messages

⚡️ For web interfaces, we recommend using [cosmos-kit](https://github.com/hyperweb-io/cosmos-kit). Continue below to see how to manually construct signers and clients.

Here are the docs on [creating signers](https://docs.hyperweb.io/cosmos-kit) in cosmos-kit that can be used with Keplr and other wallets.

#### Initializing the Stargate Client

Use `getSigningKiiChainClient` to get your `SigningStargateClient`, with the proto/amino messages full-loaded. No need to manually add amino types, just require and initialize the client:

```js
import { getSigningKiiChainClient } from '@kiichain/kiijs-proto';

const stargateClient = await getSigningKiiChainClient({
  rpcEndpoint,
  signer // OfflineSigner
});
```

#### Creating Signers

To broadcast messages, you can create signers with a variety of options:

* [cosmos-kit](https://docs.hyperweb.io/cosmos-kit) (recommended)
* [keplr](https://docs.keplr.app/api/cosmjs.html)
* [cosmjs](https://gist.github.com/webmaster128/8444d42a7eceeda2544c8a59fbd7e1d9)

#### Amino Signer

Likely you'll want to use the Amino, so unless you need proto, you should use this one:

```js
import { getOfflineSignerAmino as getOfflineSigner } from 'cosmjs-utils';
```

#### Proto Signer

```js
import { getOfflineSignerProto as getOfflineSigner } from 'cosmjs-utils';
```

WARNING: NOT RECOMMENDED TO USE PLAIN-TEXT MNEMONICS. Please take care of your security and use best practices such as AES encryption and/or methods from 12factor applications.

```js
import { chains } from 'chain-registry';

const mnemonic =
  'unfold client turtle either pilot stock floor glow toward bullet car science';
  const chain = chains.find(({ chain_name }) => chain_name === 'kiichain');
  const signer = await getOfflineSigner({
    mnemonic,
    chain
  });
```

#### Broadcasting Messages

Now that you have your `stargateClient`, you can broadcast messages:

```js
import { cosmos } from '@kiichain/kiijs-proto'

const { send } = cosmos.bank.v1beta1.MessageComposer.withTypeUrl;

const msg = send({
    amount: [
    {
        denom: 'akii',
        amount: '10000000000000000'
    }
    ],
    toAddress: address,
    fromAddress: address
});

const fee: StdFee = {
    amount: [
    {
        denom: 'akii',
        amount: '10000000000000000'
    }
    ],
    gas: '86364'
};
const response = await stargateClient.signAndBroadcast(address, [msg], fee);
```

### Converting from Hex to Bech32 and vice-versa

We have a few helper functions for converting Hex to Bech32 and vice versa on the @kiichain/kiijs-evm. We did not import them over here since the proto files are all generated.

```tsx
import { HexToBech32, Bech32ToHex } from '@kiichain/kiijs-evm'

const kiiAddress = HexToBech32("0xyourhex")

const evmAddress = Bech32ToHex("kiiYouraddress)
```

### Advanced Usage

If you want to manually construct a stargate client

```js
import { OfflineSigner, GeneratedType, Registry } from "@cosmjs/proto-signing";
import { AminoTypes, SigningStargateClient } from "@cosmjs/stargate";

import { 
    cosmosAminoConverters,
    cosmosProtoRegistry,
    cosmwasmAminoConverters,
    cosmwasmProtoRegistry,
    ibcProtoRegistry,
    ibcAminoConverters,
    kiichainAminoConverters,
    kiichainProtoRegistry
} from '@kiichain/kiijs-proto';

const signer: OfflineSigner = /* create your signer (see above)  */
const rpcEndpoint = 'https://rpc.dos.sentry.testnet.v3.kiivalidator.com/'; // or another URL

const protoRegistry: ReadonlyArray<[string, GeneratedType]> = [
    ...cosmosProtoRegistry,
    ...cosmwasmProtoRegistry,
    ...ibcProtoRegistry,
    ...kiichainProtoRegistry
];

const aminoConverters = {
    ...cosmosAminoConverters,
    ...cosmwasmAminoConverters,
    ...ibcAminoConverters,
    ...kiichainAminoConverters
};

const registry = new Registry(protoRegistry);
const aminoTypes = new AminoTypes(aminoConverters);

const stargateClient = await SigningStargateClient.connectWithSigner(rpcEndpoint, signer, {
    registry,
    aminoTypes
});
```


# Kiijs-utils

## @kiichain/kiijs-utils

Typescript library containing general utility functions for interacting with Kiichain.

### Installation

```bash
yarn add @kiichain/kiijs-utils @kiichain/kiijs-proto
```

### Bech32 conversion

The package has utils to easen up conversion between hex and bech32 addresses. They can be used like this:

```tsx
import { HexToBech32, Bech32ToHex } from '@kiichain/kiijs-utils'

const kiiAddress = HexToBech32("0xyourhex")

const evmAddress = Bech32ToHex("kiiYouraddress)
```

### ETHSECP signer

Some wallets do not recognize the ETHSECP256-1 PubKey signatures. We made a couple helpers to utilize it without problems.

#### Signing a transaction

1. Create the `SigningStargateClient` with the correct type

```typescript
import { ethsecpAccountParser, signWithEthsecpSigner } from '@kiichain/kiijs-utils';

// Start the client connection
// The stargate client must use the custom account parser
// This is necessary to handle the ethsecp256k1 PubKey format in queries
const client = await SigningStargateClient.connectWithSigner(
  RPC_ENDPOINT,
  offlineSigner,
  {
    accountParser: ethsecpAccountParser,
  }
);
```

The signing client must use a custom account parser to handle the `ethsecp256k1` public key format. This is crucial for correctly signing transactions.

2. Sign the transaction with a custom pubkey

```typescript
// This is the important bit
// This signs the transaction using the ethsecp256k1 signer
// It basically rewrite the Pubkey to the ethsecp256k1 format
const txRaw = await signWithEthsecpSigner(
  client,
  offlineSigner,
  CHAIN_ID,
  address,
  [msgSend],
  "This is a sample transaction memo",
  KEPLR_CHAIN_INFO.feeCurrencies[0].gasPriceStep.high,
  1.5
);
```

3. Broadcast the signed transaction

```typescript
const receipt = await client.broadcastTx(txRaw);

A full example can be found [here](https://github.com/KiiChain/keplr-tx-template/blob/main/src/App.tsx)
```


# Deploy a smart contract

Overview for deploying a smart contract with Hardhat, Remix, Foundry, and Thirdweb.

### Chain Information

| RPC URL:  | <https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/> |
| --------- | ---------------------------------------------------------- |
| Chain Id: | 1336                                                       |

### Deploy with Hardhat

#### 1. Install Hardhat

Install the hardhat framework in your project, by typing the following command:

```yaml
$ npm install --save-dev hardhat
```

#### 2. Create a hardhat project

After installing Hardhat, create a project. You can create it using typescript or javascript in the following screen:

```yaml
$ npx hardhat init
```

```tsx
888    888                      888 888               888
888    888                      888 888               888
888    888                      888 888               888
8888888888  8888b.  888d888 .d88888 88888b.   8888b.  888888
888    888     "88b 888P"  d88" 888 888 "88b     "88b 888
888    888 .d888888 888    888  888 888  888 .d888888 888
888    888 888  888 888    Y88b 888 888  888 888  888 Y88b.
888    888 "Y888888 888     "Y88888 888  888 "Y888888  "Y888

Welcome to Hardhat v2.22.8 

? What do you want to do? …
❯ Create a JavaScript project
  Create a TypeScript project
  Create a TypeScript project (with Viem)
  Create an empty hardhat.config.js
  Quit
```

#### 3. Create a Smart contract and Compile project

After creating the smart contract in the “Contracts” folder, run the following command to check your code.

```yaml
$ npx hardhat compile 
```

#### 4. Set the hardhat configuration file and deploy the smart contract

After creating the ignition deploy file, let's set the blockchain information into the hardhat.config file, with the following information:

```tsx
import { HardhatUserConfig } from "hardhat/config";
import "@nomicfoundation/hardhat-toolbox";

const config: HardhatUserConfig = {
  solidity: "0.8.20", // Solidity Version
  networks: {
    kiichain: {
      url: "https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/",
      chainId: 1336,
      accounts: [`0x${yourPrivateKey}`],
    },
  },
};

export default config;

```

```yaml
$ npx hardhat ignition deploy ignition/modules/<contractName>.ts --network kiichain
```

### Deploy with Remix

Remix is a web compiler page where you can write smart contracts, scripts and deploy using your wallet from Metamask. You can enter Remix [here](https://remix.ethereum.org/#lang=en\&optimize=false\&runs=200\&evmVersion=null).

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FkSoVtlKmpupriuOyqmbj%2Fimage%20(15).png?alt=media&amp;token=42a7ed76-662f-44e8-8ad0-8dd5ba82ac25" alt="" width="563"><figcaption></figcaption></figure>

In the Workspace create the file which contains the Smart contract with the .sol extension.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Flp13ZOdNZ8afhuUMBuFb%2Fimage%20(16).png?alt=media&amp;token=300ec97e-4f5f-44ff-a648-c82a761943ba" alt="" width="272"><figcaption></figcaption></figure>

After writing the smart contract, go to the Solidity Compiler section and select your compiler version, is recommended to use the most recent one.

Then press “Compile” button under the Compiler selector.

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FfIoIL4CYK5SeCelF95zZ%2Fimage%20(17).png?alt=media&amp;token=85569d01-bcc9-40bc-bd39-e702836f333d" alt="" width="320"><figcaption></figcaption></figure>

#### 3. Select your Metamask wallet as Deploy environment

In the “Deploy and Run Transactions” section, move to the Environment and select your Metamask Provider, remember you must be connected to KiiChain Testnet

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FY9AShaDty9FTBlW6DMZ3%2Fimage%20(18).png?alt=media&amp;token=fe668736-8d22-415a-87f6-8efe0bad5521" alt="" width="320"><figcaption></figcaption></figure>

#### 4. Deploy Smart contract

Select the smart contract to be deployed and write the Constructor parameters if Remix detects them

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FVQqzf7zlOIl5Ytxk4euH%2Fimage%20(19).png?alt=media&amp;token=3451c865-4059-471e-ad64-417528a6eadb" alt="" width="563"><figcaption></figcaption></figure>

Finally, you can interact with the different functions in the same section above the Deploy button.

### Deploy with Foundry

#### 1. Create a project and installation

Run the following commands in your terminal in order to start the foundry’s installation.

```bash
curl -L https://foundry.paradigm.xyz | bash
```

then run the following command in another terminal or restart the current one for finishing the installation process.

```json
foundryup
```

After finishing the foundry’s installation let’s create a new project, run the following commands for starting the new project and then move to it’s folder:

```bash
forge init projectName
cd projectName
```

#### 2. Write and build a contract

Write your smart contract in ‘/src/smartContractName.sol’ and the script in ‘/script/smartContractName.s.sol’, here is an example of that:

This contract will be placed in the path: /src/Counter.sol

```solidity
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.13;

contract Counter {
    uint256 public number;

    function setNumber(uint256 newNumber) public {
        number = newNumber;
    }

    function increment() public {
        number++;
    }
    
    
    function getCounter() public view returns (uint256) {
        return number;
    }
}

```

This is the script and will be placed in /script/Counter.s.sol remember to add the .s before the .sol extension.

```solidity
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.13;

import {Script, console} from "forge-std/Script.sol";
import {Counter} from "../src/Counter.sol";

contract CounterScript is Script {
    Counter public counter;

    function setUp() public {}

    function run() public {
        vm.startBroadcast();

        counter = new Counter();

        vm.stopBroadcast();
    }
}

```

then run the following command for build and check that everything is correct.

```bash
forge build
```

#### 3. Deploy

First, you need to run a simulation.

```bash
forge script script/Counter.s.sol:CounterScript --fork-url https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/ --private-key yourPrivateKey
```

The simulation will be complete after that, and you can run with broadcast.

```bash
forge script script/Counter.s.sol:CounterScript --fork-url https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/ --private-key yourPrivateKey --broadcast
```

A success message should appear.

### Troubleshooting — Remix on Oro (Testnet, Chain ID 1336)

If a Remix deploy shows **“Transaction mined but execution failed (status 0x0)”**, set:

* **Solidity Compiler → EVM Version = `london`**
* **Optimizer: enabled (200 runs)**
* **Disable `viaIR`** (if it was enabled)

Re-compile, then deploy again on **KiiChain Testnet (Oro, chainId 1336)**. This avoids newer EVM opcodes not yet supported by Oro.

#### Hardhat — KiiChain Oro Network

```ts
// hardhat.config.ts
import { HardhatUserConfig } from "hardhat/config";
import "@nomicfoundation/hardhat-toolbox";

const config: HardhatUserConfig = {
  solidity: { version: "0.8.20", settings: { optimizer: { enabled: true, runs: 200 } } },
  networks: {
    kiichain: {
      url: "https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com/",
      chainId: 1336,
      // accounts: [process.env.PRIVATE_KEY!], // use .env, never hardcode keys
    },
  },
};
export default config;

```


# Deploy a dApp

Deploy a decentralized application on KiiChain.

## Introduction

In this tutorial, you will learn how to create a simple decentralized application (dApp) built on KiiChain. We will use tools such as React, TypeScript, and Ethers.js to build a basic wallet management system.

## Project setup

### Tools

We will be using the following tools:

* `npx` for managing Node.js packages and running commands.
* `ethers` for interacting with the Ethereum blockchain and other compatible chains like KiiChain.
* `React` for building the user interface.
* `TypeScript` for adding static types to JavaScript.

### Create project

First, navigate to your working directory, open a terminal, and run the following commands to create a new React project with TypeScript:

```bash
npx create-react-app kii-dapp --template typescript
cd kii-dapp
```

After the project is set up, open the code in your preferred editor. If you are using Visual Studio Code, you can do this with:

```bash
code .
```

You should now see the following project structure:

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2Fmo4rSzTy67hSpmEhhxo2%2Fdapp1.png?alt=media&amp;token=3a1feb02-94fa-400d-b238-77bae4d6c325" alt="" width="345"><figcaption></figcaption></figure>

### Install dependencies

Next, you need to install the `ethers` library. Run the following command in the terminal within your project directory:

```bash
npm i ethers
```

The version used in this tutorial is [Ethers.js v6](https://docs.ethers.org/v6/).

## Coding the dApp

### Create the Repository

Create a new file at `src/repository/kiichain.repository.ts`. The directory needs to be created.

```tsx
import { ethers } from 'ethers';

export function getProvider(): ethers.JsonRpcProvider {
    const url = "<https://a.sentry.testnet.kiivalidator.com:8645/>";
    const provider = new ethers.JsonRpcProvider(url, {
        chainId: 123454321,
        name: "kiichaind",
    });
    return provider;
}

export function getSigner(
    wallet: ethers.Wallet,
    provider: ethers.JsonRpcProvider
): ethers.Wallet {
    return wallet.connect(provider);
}

export function createWallet(
    provider: ethers.JsonRpcProvider
): ethers.HDNodeWallet {
    return ethers.Wallet.createRandom(provider);
}

export function getWalletFromPhrase(
    Phrase: string,
    provider: ethers.JsonRpcProvider
): ethers.HDNodeWallet {
    return ethers.Wallet.fromPhrase(Phrase!).connect(provider);
}
```

This repository file contains functions for basic operations like creating a wallet, connecting to a wallet using a seed phrase, and getting the balance of a wallet.

### What is a Signer and a Provider?

In decentralized application (dApp) development, especially when interacting with blockchains like KiiChain, it's essential to understand the concepts of **Provider** and **Signer**. These components play crucial roles in communicating with and managing transactions on the blockchain.

#### Provider

A **Provider** is a component that allows your dApp to connect to and interact with the blockchain. It provides methods to read data from the blockchain, such as transaction statuses, account balances, and other network details. The provider does not have access to private keys and therefore cannot sign transactions.

#### Signer

A **Signer** is a component that represents an entity capable of making transactions on the blockchain, meaning it can sign them. A signer has access to the private keys necessary to authorize and send transactions, allowing you to modify the blockchain state, such as transferring tokens or interacting with smart contracts.

### Create the Wallet Manager Component

Create a new file at `src/components/WalletManager.tsx` . The directory needs to be created

```tsx
import React, { useEffect, useState } from 'react';
import { ethers } from 'ethers';
import { createWallet, getProvider, getWalletFromPhrase } from '../repository/kiichain.repository';

const WalletManager: React.FC = () => {
    const [wallet, setWallet] = useState<ethers.HDNodeWallet | null>(null);
    const [balance, setBalance] = useState<string | null>(null);
    const [mnemonic, setMnemonic] = useState<string>(''); // Estado para la seed phrase

    const provider = getProvider();

    // Handle wallet creation
    const handleCreateWallet = (): void => {
        const newWallet = createWallet(provider);
        setWallet(newWallet);
        console.log('New Wallet Address:', newWallet.address);
        console.log('Seed Phrase:', newWallet.mnemonic?.phrase);
    };

    // Handle connecting to a wallet via a mnemonic phrase
    const handleConnectWallet = (): void => {
        if (!mnemonic) {
            console.error('Mnemonic is empty');
            return;
        }
        const existingWallet = getWalletFromPhrase(mnemonic, provider);
        setWallet(existingWallet);
        console.log('Connected Wallet Address:', existingWallet.address);
    };

    // Fetch and display wallet balance
    const handleGetBalance = async (): Promise<void> => {
        if (wallet) {
            const balance: bigint = await provider.getBalance(wallet.address);
            setBalance(ethers.formatEther(balance));
        } else {
            console.error('No wallet connected');
        }
    };

    useEffect(() => {
        if (wallet) {
            handleGetBalance();
        }
    }, [wallet]);
    return (
        <div>
            <h1>Kiichain Wallet Manager</h1>
            <button onClick={handleCreateWallet}>Create New Wallet</button>

            <div>
                <input
                    type="password"
                    value={mnemonic}
                    onChange={(e) => setMnemonic(e.target.value)}
                    placeholder="Enter your seed phrase"
                />
                <button onClick={handleConnectWallet}>Connect Wallet via Seed Phrase</button>
            </div>

            {wallet && <p>Wallet Address: {wallet.address}</p>}
            {balance && <p>Wallet Balance: {balance} Kii</p>}
        </div>
    );
};

export default WalletManager;

```

This component implements the functions from the repository and displays the relevant information, such as the wallet address and balance.

## Run the dApp

To check if everything is working correctly, you need to run the project. Open your terminal in the project directory and execute the following command:

```tsx
npm run start
```

If everything is set up properly, your application should start, and the following screen will appear:

<figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FMGTmhL91DRsJ0LS7b0cX%2Fimage%20(22).png?alt=media&amp;token=9ef616e0-3f70-4c69-b4e4-758f6475555e" alt="" width="478"><figcaption></figcaption></figure>

### Testing the Wallet Functionality

1. **Create a New Wallet**: Click the "Create New Wallet" button. A new wallet will be generated, and the address along with the seed phrase will be displayed in the console.
2. **Access the Developer Console**:
   * Right-click anywhere on the page and select "Inspect" to open the Developer Tools.
   * Navigate to the "Console" tab to see the output.
3. **Connect to the Wallet**: Copy the seed phrase from the console, paste it into the input field under "Enter your seed phrase," and click "Connect Wallet via Seed Phrase."
4. **View Wallet Balance**: If connected successfully, the wallet's balance should be displayed on the screen.

By following these steps, you can confirm that the dApp is functioning as expected.

## Deploying the dApp Using Firebase

To deploy your decentralized application (dApp) using Firebase Hosting, follow these steps:

### Step 1: Set Up a Firebase Project

1. **Create a Project in Firebase**:

   * Visit the [Firebase Console](https://console.firebase.google.com/).
   * Click on **"Create a project"**.

   <figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2F8GuY3b2vw7TBSBExbBs0%2Fimage%20(23).png?alt=media&amp;token=d90e7a6b-7165-415b-9957-76f98e59dfc9" alt="" width="375"><figcaption></figcaption></figure>

   * Name your project and disable Google Analytics (optional for this tutorial).

   <figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FZu9mo4DNYRmEz09D5zdc%2Fimage%20(24).png?alt=media&amp;token=780075ff-2710-4ea6-a741-44327a9b291e" alt="" width="375"><figcaption></figcaption></figure>

   * Click **"Continue"** once the project is ready.

   <figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FnuGdl4hDfJ1QiZ902GOh%2Fimage%20(25).png?alt=media&amp;token=cad455aa-22c6-4e60-93fb-c1f57924cef9" alt="" width="337"><figcaption></figcaption></figure>
2. **Access Firebase Hosting**:

   * In the left menu, go to **Build** → **Hosting**.
   * Click **"Get started"** to begin setting up Firebase Hosting.

   <figure><img src="https://3914576130-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLp9bjbiKt9M7tGE7GNdh%2Fuploads%2FRrBaF9pHxhT3IHIaq6HC%2Fimage%20(26).png?alt=media&amp;token=e7c6540a-c2dd-4a67-8168-11c95b72665f" alt="" width="563"><figcaption></figcaption></figure>

### Step 2: Initialize Firebase Hosting

1. **Install Firebase CLI**:
   * Open your terminal and install Firebase CLI globally

     ```bash
     npm install -g firebase-tools
     ```
2. **Login and Initialize Firebase**:

   * Inside your project directory, run

     ```bash
     firebase login
     firebase init
     ```
   * During initialization, select the following options:
     * **Features**: Hosting: Configure files for Firebase Hosting
     * **Project Setup**: Use an existing project
     * **Public Directory**: ‘build’
     * **Single-page App**: No
     * **Automatic Builds/Deploys**: No

   ```bash
   ? Are you ready to proceed? Yes
   ? Which Firebase features do you want to set up for this directory? Press Space to select features, then Enter to confirm your choices. Hosting: Configure files  
   for Firebase Hosting and (optionally) set up GitHub Action deploys

   === Project Setup

   First, let's associate this project directory with a Firebase project.
   You can create multiple project aliases by running firebase use --add,
   but for now we'll just set up a default project.

   ? Please select an option: Use an existing project
   ? Select a default Firebase project for this directory: kii-dapp-test (kii-dapp-test)
   i  Using project kii-dapp-test (kii-dapp-test)

   === Hosting Setup

   Your public directory is the folder (relative to your project directory) that
   will contain Hosting assets to be uploaded with firebase deploy. If you
   have a build process for your assets, use your build's output directory.

   ? What do you want to use as your public directory? build
   ? Configure as a single-page app (rewrite all urls to /index.html)? No
   ? Set up automatic builds and deploys with GitHub? No
   +  Wrote build/404.html
   +  Wrote build/index.html

   i  Writing configuration info to firebase.json...
   i  Writing project information to .firebaserc...

   +  Firebase initialization complete!
   ```

### Step 3: Build and Deploy Your dApp

1. **Build the project:**
   * Run the following command to generate the production-ready files

     ```bash
     npm run build
     ```
2. **Deploy to Firebase**
   * Deploy your built project to Firebase Hosting

     ```bash
     firebase deploy
     ```

     ```bash
     === Deploying to 'kii-dapp-test'...

     i  deploying hosting
     i  hosting[kii-dapp-test]: beginning deploy...
     i  hosting[kii-dapp-test]: found 14 files in build
     +  hosting[kii-dapp-test]: file upload complete
     i  hosting[kii-dapp-test]: finalizing version...
     +  hosting[kii-dapp-test]: version finalized
     i  hosting[kii-dapp-test]: releasing new version...
     +  hosting[kii-dapp-test]: release complete

     +  Deploy complete!

     Project Console: <https://console.firebase.google.com/project/kii-dapp-test/overview>
     Hosting URL: <https://kii-dapp-test.web.app>
     ```

Once the deployment is complete, the URL of your live dApp will be shown in the terminal.


# Testnet faucet

Join the testnet, set up your wallet, and request KII tokens.

### About the Faucet

Testnet participation is a great way to signal to the community that you are ready and able to operate a validator.

Important to create your web wallet first and then link to the explorer app.

* [Testnet explorer app](https://explorer.kiichain.io/faucet)

Testnet KII can be found in the faucet in Discord and on our Explorer App. It can be called on every 24 hours.

* [Discord Kiichain Invitation](https://discord.com/invite/kiichain)

### Discord Faucet Commands

Request tokens:

```
$request {address}
```

Example EVM:

```
$request 0x12345abcde…
```

Example CW:

```
$request kii12345abcde…
```

### List of Commands:

See all available commands:

```
$help
```

Request tokens:

```
$request [kii address]
```

Query an address balance:

```
$balance [kii address]
```

Query a transaction:

```
$tx_info [transaction hash ID]
```

Query the faucet and node status:

```
$faucet_status [chain ID]
```

Query the faucet address:

```
$faucet_address [chain ID]
```


# Resources

Helpful resources to start building on Kiichain

**CosmJS** - <https://github.com/cosmos/cosmjs>

This is a Javascript library that could be utilized on the frontend for creating robust dApps in the cosmos ecosystem. This library has been used to build many things such as wallets and applications that require sending transaction messages on a cosmos based blockchain.

Easy CosmJS starting point documentation - <https://gist.github.com/webmaster128/8444d42a7eceeda2544c8a59fbd7e1d9>

**Cosmpy** - <https://github.com/fetchai/cosmpy>

A python library created by fetchai. Similar to CosmJS, this library handles connectivity and transaction creation and broadcasting to cosmos based chains.

If adding a library in your dApp is not an option or you prefer not to use javascript/typescript or python, communicating via rpc endpoints is also possible. Kiichain validators expose rpc endpoints that dApp developers can utilize when building dApps. It is highly recommended for dApp developers to bring up their own node in order to utilize these rpc endpoints (more information about setting up a node here: [Run a Validator / Full Node](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/getting-started))

Kiichain RPC endpoints:

* **Mainnet:** <https://rpc.kiivalidator.com> (JSON-RPC: <https://json-rpc.kiivalidator.com>)
* **Testnet Oro:** <https://rpc.uno.sentry.testnet.v3.kiivalidator.com/>

See also:

* [Kiichain Mainnet](https://docs.kiiglobal.io/docs/build-on-kiichain/kiichain-mainnet)
* [Testnet Oro](https://docs.kiiglobal.io/docs/build-on-kiichain/testnet-oro)
* [Bridge](https://docs.kiiglobal.io/docs/learn/getting-started/bridge)


# Precompiled Contracts

KiiChain boasts a sophisticated framework of precompiled smart contracts meticulously crafted to harmonize with the Cosmos SDK functionalities, bolstering the network's efficiency and adaptability.

### **KiiChain Precompiled Contracts**

Among these contracts, the "Bank," "Staking," and "Rewards" contracts are integral components seamlessly integrated into Kiichain's operations through the Polaris EVM module, meticulously engineered by Berachain. These contracts play pivotal roles in managing sKII balances, orchestrating staking activities, and computing rewards, thereby fortifying the network's core functions while maintaining compatibility with the Ethereum Virtual Machine standards.

| Contract Name | Contract Address                                          | Description                                                                                                                                                                                                                                                                           |
| ------------- | --------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Bank          | 0x4381dC2aB14285160c808659aEe005D51255adD7                | The Bank contract governs the determination of sKII balances associated with individual addresses, serving as the cornerstone for transactional integrity and account management within Kiichain.                                                                                     |
| Staking       | 0xd9A998CaC66092748FfEc7cFBD155Aae1737C2fF                | The Staking contract intricately manages the staking functionality within Kiichain, including the delegation of sKII tokens to validators and the maintenance of staking balances, ensuring the robustness and security of the network's consensus mechanism.                         |
| Rewards       | 0x55684E2CA2BACE0ADC512C1AFF880B15B8EA7214                | The Rewards contract plays a crucial role in computing and distributing accumulated rewards stemming from the staking activity within Kiichain, fostering incentivization and participation among network participants through fair and transparent reward allocation mechanisms.     |
| Swap          | 0xF948f57612E05320A6636a965cA4fbaed3147A0f (Only Testnet) | The custom-deployed Swap contract facilitates the seamless exchange of sKII tokens to KII and vice versa, enabling fluid token interoperability and liquidity provision within the Kiichain ecosystem, thereby enhancing user accessibility and utility across token functionalities. |

Complementing these foundational contracts, the custom-deployed Swap contract serves as a pivotal component in enabling seamless token conversion between sKII and KII, further enriching Kiichain's utility and accessibility. Together, these contracts, spearheaded by the Polaris EVM module developed by Berachain, form the bedrock of Kiichain's operational infrastructure, fostering a cohesive ecosystem conducive to streamlined interactions and value exchange among participants.

To interact with these precompiled contracts, you can view them over at Berachain's Precompiled Contracts Docs.

<https://github.com/berachain/polaris/tree/main/cosmos/precompile>

For the Swap contract, below shows the two function signatures that you would require to interact with if exchanging tokens. ***NOTE: You will need KII to pay for gas fees when interacting with any of the smart contracts.***

```
// exchange your KII for sKII
function buySkii() external payable

// exchange your sKII for KII
function sellSkii(uint256 amount) external
```

***ABI for the Swap Contract***

```
[
    {
      "inputs": [],
      "name": "bankContractAddress",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "buySkii",
      "outputs": [],
      "stateMutability": "payable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "amount",
          "type": "uint256"
        }
      ],
      "name": "sellSkii",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    }
  ] 
```

<br>


# Smart Contracts

How to deploy smart contracts

Kiichain supports **natively supports both CosmWasm and EVM smart contracts.** Developers can choose between any of the two to create amazing dApps.

***

## Working with Cosmwasm

#### Prerequisites

* Install Rust and CosmWasm toolchain:

  ```bash
  rustup default stable
  rustup target add wasm32-unknown-unknown
  cargo install cargo-generate --features vendored-openssl
  cargo install cargo-run-script
  ```
* Create a new CosmWasm contract:

  ```bash
  cargo generate --git https://github.com/CosmWasm/cosmwasm-template.git --name my-contract
  cd my-contract
  ```
* Compile the contract:

  ```bash
  cargo wasm
  cargo schema
  ```

#### Upload and Instantiate the Contract

1. **Store the Contract**

   ```bash
   kiichaind wasmd tx wasm store artifacts/my_contract.wasm --from my-key --gas auto --gas-adjustment 1.2 --node <KIICHAIN_NODE> --chain-id <KIICHAIN_CHAIN_ID>
   ```
2. **Instantiate the Contract**

   ```bash
   kiichaind wasmd tx wasm instantiate <CONTRACT_CODE_ID> '{}' --from my-key --label "My Contract" --gas auto --gas-adjustment 1.2 --node <KIICHAIN_NODE> --chain-id <KIICHAIN_CHAIN_ID>
   ```
3. **Execute the Contract**

   ```bash
   kiichaind wasmd tx wasm execute <CONTRACT_ADDRESS> '{"your_method": {}}' --from my-key --gas auto --gas-adjustment 1.2 --node <KIICHAIN_NODE> --chain-id <KIICHAIN_CHAIN_ID>
   ```

***

## Working with EVM

#### Prerequisites

* Install **Node.js** and **Hardhat**:

  ```bash
  npm install -g hardhat
  mkdir my-evm-contract && cd my-evm-contract
  npx hardhat
  ```
* Install dependencies:

  ```bash
  npm install --save-dev @nomicfoundation/hardhat-toolbox
  ```

#### Write and Compile the Smart Contract

1. Create a Solidity file (`MyContract.sol`) in `contracts/`:

   ```solidity
   // SPDX-License-Identifier: MIT
   pragma solidity ^0.8.19;

   contract MyContract {
       string public message;

       constructor(string memory _message) {
           message = _message;
       }

       function setMessage(string memory _newMessage) public {
           message = _newMessage;
       }
   }
   ```
2. Compile the contract:

   ```bash
   npx hardhat compile
   ```

#### Deploy the Smart Contract

1. Create a deployment script (`scripts/deploy.js`):

   ```javascript
   const hre = require("hardhat");

   async function main() {
       const MyContract = await hre.ethers.getContractFactory("MyContract");
       const contract = await MyContract.deploy("Hello, Kiichain!");
       await contract.deployed();
       console.log("Contract deployed at:", contract.address);
   }

   main().catch((error) => {
       console.error(error);
       process.exitCode = 1;
   });
   ```
2. Deploy to Kiichain:

   ```bash
   npx hardhat run scripts/deploy.js --network kiichain
   ```

#### Interact with the Deployed Contract

* **Using Hardhat Console**:

  ```bash
  npx hardhat console --network kiichain
  ```

  ```javascript
  const contract = await ethers.getContractAt("MyContract", "<DEPLOYED_CONTRACT_ADDRESS>");
  await contract.setMessage("New Message");
  ```

***

## References

* **CosmWasm Documentation:** [CosmWasm Docs](https://docs.cosmwasm.com/)
* **Ethereum Hardhat Guide:** [Hardhat Docs](https://hardhat.org/getting-started)


# Wasmbindings

Wasm contract bindings for custom modules

### Core Concept

**WASM Bindings** (WebAssembly bindings) are interfaces that allow CosmWasm smart contracts to interact with **native blockchain modules** beyond the standard Cosmos SDK bank and staking modules. They provide a bridge between WebAssembly smart contracts and the underlying blockchain's specialized functionality.

We currently only support queries for our custom modules.

### Covered modules

<table><thead><tr><th width="139.33331298828125">Module Name</th><th>Queries</th></tr></thead><tbody><tr><td>TokenFactory</td><td>FullDenom, Admin, Metadata, DenomsByCreator, Params</td></tr><tr><td>EVM</td><td>EthCall, ERC20Information, ERC20Balance, ERC20Allowance</td></tr><tr><td>Oracle</td><td>ExchangeRate, ExchangeRates, Twaps</td></tr><tr><td>Bech32</td><td>HexToBech32, Bech32ToHex</td></tr></tbody></table>


# Modules

Description of all the custom modules that makes Kiichain work


# TokenFactory

## Token Factory

The tokenfactory module allows any account to create a new token with the name `factory/{creator address}/{subdenom}`.\
Because tokens are namespaced by creator address, this allows token minting to be permissionless, due to not needing to resolve name collisions.\
A single account can create multiple denoms, by providing a unique subdenom for each created denom. Once a denom is created, the original creator is given "admin" privileges over the asset.

This allows them to:

* Mint their denom to any account
* Burn their denom from any account
* Create a transfer of their denom between any two accounts
* Change the admin. In the future, more admin capabilities may be added. Admins can choose to share admin privileges with other accounts using the authz module. The `ChangeAdmin` functionality, allows changing the master admin account, or even setting it to `""`, meaning no account has admin privileges for the asset.

### Interaction with other modules

<table><thead><tr><th width="188.83331298828125">Module</th><th>Interaction</th></tr></thead><tbody><tr><td>Account</td><td>Finds module accounts when they are used by tokens</td></tr><tr><td>Bank</td><td>Mint, burn and intermediate tokens. Checks blocked addresses.</td></tr><tr><td>Community pool</td><td>Fees for denom creation go to the community pool</td></tr></tbody></table>

### Messages

#### CreateDenom

Creates a denom `factory/{creator address}/{subdenom}` given the denom creator address and the subdenom. Subdenoms can contain `[a-zA-Z0-9./]`.

```go
message MsgCreateDenom {
  string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ];
  string subdenom = 2 [ (gogoproto.moretags) = "yaml:\"subdenom\"" ];
}
```

**State Modifications:**

* Fund the community pool with the denom creation fee from the creator address, set in `Params`.
* Set `DenomMetaData` via the bank keeper.
* Set `AuthorityMetadata` for the given denom to store the admin for the created denom `factory/{creator address}/{subdenom}`. Admin is automatically set as the Msg sender.
* Add denom to the `CreatorPrefixStore`, where a state of denoms created per creator is kept.

#### Mint

Minting of a specific denom is only allowed for the current admin.\
Note, the current admin is defaulted to the creator of the denom.

```go
message MsgMint {
  string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ];
  cosmos.base.v1beta1.Coin amount = 2 [
    (gogoproto.moretags) = "yaml:\"amount\"",
    (gogoproto.nullable) = false
  ];
}
```

**State Modifications:**

* Safety check the following
  * Check that the denom minting is created via `tokenfactory` module
  * Check that the sender of the message is the admin of the denom
* Mint a designated amount of tokens for the denom via `bank` module

#### Burn

Burning of a specific denom is only allowed for the current admin.\
Note, the current admin is defaulted to the creator of the denom.

```go
message MsgBurn {
  string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ];
  cosmos.base.v1beta1.Coin amount = 2 [
    (gogoproto.moretags) = "yaml:\"amount\"",
    (gogoproto.nullable) = false
  ];
}
```

**State Modifications:**

* Safety check the following
  * Check that the denom minting is created via `tokenfactory` module
  * Check that the sender of the message is the admin of the denom
* Burn a designated amount of tokens for the denom via `bank` module

#### ChangeAdmin

Change the admin of a denom. Note, this is only allowed to be called by the current admin of the denom.

```go
message MsgChangeAdmin {
  string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ];
  string denom = 2 [ (gogoproto.moretags) = "yaml:\"denom\"" ];
  string newAdmin = 3 [ (gogoproto.moretags) = "yaml:\"new_admin\"" ];
}
```

#### SetDenomMetadata

Setting of metadata for a specific denom is only allowed for the admin of the denom.\
It allows the overwriting of the denom metadata in the bank module.

```go
message MsgChangeAdmin {
  string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ];
  cosmos.bank.v1beta1.Metadata metadata = 2 [ (gogoproto.moretags) = "yaml:\"metadata\"", (gogoproto.nullable)   = false ];
}
```

**State Modifications:**

* Check that the sender of the message is the admin of the denom
* Modify `AuthorityMetadata` state entry to change the admin of the denom


# EVM

The **EVM Module** enables full Ethereum Virtual Machine compatibility within Kiichain, allowing developers to deploy and interact with Ethereum smart contracts using familiar tools like MetaMask, Remix, Hardhat, and Web3 libraries.

This module is built on top of the [Cosmos EVM implementation](https://github.com/cosmos/evm).

## Overview

The `evm` module provides:

* EVM Execution Environment within Cosmos-SDK
* Support for Ethereum JSON-RPC APIs
* Full Solidity smart contract compatibility

## Available Messages and Transactions

The EVM module provides several messages and transactions that users and developers can utilize:​

### Ethereum Transactions

* **Submit Ethereum Transactions**: Users can submit Ethereum-formatted transactions (`MsgEthereumTx`) to Kiichain, which are processed by the EVM module.​

### CLI Commands

Kiichain offers command-line interface (CLI) commands for interacting with the EVM module:​

* Query Smart Contract Code:

```
kiichaind query evm code [address]
# Example:
kiichaind query evm code 0x7bf7b17da59880d9bcca24915679668db75f9397
```

* Query Storage:

```
kiichaind query evm storage [address] [key] [flags]
# Example:
kiichaind query evm storage 0x0f54f47bf9b8e317b214ccd6a7c3e38b893cd7f0 0 --height 0
```

* Submit Raw Ethereum Transaction:

```
kiichaind tx evm raw [tx_hex]
# Example:
kiichaind tx evm raw 0xf9ff74c86aefeb5f6019d77280bbb44fb695b4d45cfe97e6eed7acd62905f4a85034d5c68ed25a2e7a8eeb9baf1b84
```

### JSON-RPC Support

Kiichain's EVM module exposes standard Ethereum JSON-RPC endpoints, allowing developers to interact with the blockchain using familiar methods:​

* **eth\_sendTransaction**: Send a transaction
* **eth\_call**: Call a smart contract function without making a state-changing transaction
* **eth\_estimateGas**: Estimate the gas required for a transaction
* **debug\_traceTransaction**: Trace the execution of a transaction for debugging purposes

And other general EVM JSON-RPC calls.

## FeeMarket Module

The `x/feemarket` module implements a dynamic fee mechanism inspired by Ethereum's EIP-1559, enhancing transaction fee predictability and network efficiency.​

### Key Concepts

* **Base Fee**: A global, per-block fee that adjusts based on network demand. It increases when blocks are above the gas target and decreases when below. Unlike Ethereum, where the base fee is burned, Kiichain allocates it for regular Cosmos SDK fee distribution.​
* **Priority Tip**: An optional fee that users can include to prioritize their transactions. While Cosmos SDK v0.46 lacks native transaction prioritization, this tip can still influence transaction inclusion.
* **Effective Gas Price**: Determined by the minimum of `(baseFee + priorityTip)` and `gasFeeCap`, ensuring users don't overpay for transactions.
* **Minimum Gas Prices**: Validators can set local minimum gas prices, and a global minimum can be established via governance. Transactions below these thresholds are discarded, mitigating spam

This module ensures a more stable and predictable fee structure, benefiting both users and validators.

## ERC20

The `x/erc20` module facilitates seamless, trustless conversion between Cosmos-native tokens and ERC-20 tokens, bridging the gap between the Cosmos and Ethereum ecosystems.

### Key Concepts

* **Bidirectional Conversion**: Users can convert native Cosmos `sdk.Coins` to ERC-20 tokens and vice versa, enabling interoperability between different blockchain applications.
* **Token Pair Registration**: Mappings between Cosmos denominations and ERC-20 contract addresses, known as `TokenPairs`, are managed via governance proposals. This ensures controlled and secure token conversions.
* Use Cases
  * Utilize Cosmos assets (e.g., ATOM, OSMO) in Ethereum-based DeFi protocols.
  * Transfer ERC-20 tokens to Kiichain for use within the Cosmos ecosystem.
  * Enable applications that require ERC-20 standard tokens while leveraging Cosmos SDK features.

By supporting ERC-20 token standards, Kiichain enhances its interoperability, allowing for a broader range of decentralized applications and services.​


# Rewards

The rewards module (also called the Utility Rewards Module) pays staking rewards from a prefunded pool. Each block it moves tokens from its module account into the `fee_collector`, and the distribution module pays them out to validators and delegators in the same way as transaction fees.

The amount released each block follows an inflation curve driven by the bonded ratio, the same model as the Cosmos SDK `x/mint` module.

{% hint style="info" %}
The rewards module **does not mint KII**. Every token it pays out must first be sent to the module account. Emissions stop when that account is empty.
{% endhint %}

Emissions are off by default (`supply_base = 0`). Governance turns them on.

### Flow

1. Fund the pool: send tokens to the rewards module account with a normal bank send. Anyone can do this.
2. Pass a governance proposal with `MsgUpdateParams` that sets `supply_base` above `0`.
3. At the start of each block, the module releases `inflation(bondedRatio) × supply_base / blocks_per_year` into the fee collector.
4. Emissions continue until the module account is empty or governance sets `supply_base` back to `0`.

The rewards module runs before the distribution module in each block, so a block's release is paid out in that same block.

### Module account

| Format | Address                                      |
| ------ | -------------------------------------------- |
| Bech32 | `kii1245yut9zht8q4hz39sd0lzqtzkuw5us5rermc4` |
| Hex    | `0x55684e2ca2bace0adc512c1aff880b15b8ea7214` |

The address is derived from the module name, so it is the same on every KiiChain network.

### Interaction with other modules

<table><thead><tr><th width="181.5">Module</th><th>Interaction</th></tr></thead><tbody><tr><td>Bank</td><td>Holds the pool as the rewards module account balance; moves the release from the module account to the fee collector</td></tr><tr><td>Staking</td><td>Provides the bonded ratio that drives the emission curve</td></tr><tr><td>Distribution</td><td>Pays the fee collector balance out to validators and delegators</td></tr><tr><td>Governance</td><td>The only account that can change module params, including enabling and disabling emissions</td></tr></tbody></table>

### Emission formula

```
inflation = clamp((1 - bondedRatio / goalBonded) × inflationRateChange × bondedRatio,
                  inflationMin, inflationMax)
amount    = inflation × supplyBase / blocksPerYear
pay       = min(amount, moduleBalance)
```

| Term                            | Meaning                                                                           |
| ------------------------------- | --------------------------------------------------------------------------------- |
| `bondedRatio`                   | Bonded tokens divided by total staking-token supply, read from the staking module |
| `goalBonded`                    | Target bonded ratio (param `goal_bonded`)                                         |
| `inflationRateChange`           | Steepness of the curve (param `inflation_rate_change`)                            |
| `inflationMin` / `inflationMax` | Floor and ceiling on the annual emission rate                                     |
| `supplyBase`                    | Notional base used to size annual provisions (param `supply_base`)                |
| `blocksPerYear`                 | Expected number of blocks per year (param `blocks_per_year`)                      |
| `moduleBalance`                 | Rewards module account balance in `token_denom`                                   |

If the calculated amount is larger than the module balance, the block pays only the balance.

#### Curve shape

Before clamping, the curve is a parabola in the bonded ratio:

* It is `0` when nothing is bonded and when `bondedRatio = goalBonded`.
* It peaks at `bondedRatio = goalBonded / 2`, with value `inflationRateChange × goalBonded / 4`.
* Above `goalBonded` it would go negative, so the clamp returns `inflationMin`.

With the default params, the peak rate is `0.13 × 0.67 / 4 = 2.1775%` per year. The default `inflation_max` of 20% does not come into play unless `inflation_rate_change` or `goal_bonded` is raised.

{% hint style="warning" %}
This curve is different from `x/mint`. Here the rate rises as the bonded ratio climbs toward `goalBonded / 2`, then falls to the floor as it approaches `goalBonded`.
{% endhint %}

#### `supply_base` is not the total supply

The annual provision is `inflation × supply_base`. `supply_base` is a governance setting that controls the scale of emissions. It is **not** read from the chain's total supply. It is an integer in base units of `token_denom` (`akii`, 18 decimals).

#### Per block, not per second

Each block releases a fixed share of the annual provision (`annual / blocks_per_year`), as in `x/mint`. Release does not depend on elapsed time. If blocks are slower than `blocks_per_year` assumes, less is released per calendar year. The default `15778800` assumes 2-second blocks.

#### Example

Default params, with `supply_base = 1000000000000000000000000000` (1,000,000,000 KII):

| Bonded ratio | Inflation  | Annual provision | Per block   |
| ------------ | ---------- | ---------------- | ----------- |
| 0.335 (peak) | 2.1775%    | 21,775,000 KII   | \~1.380 KII |
| 0.50         | \~1.6493%  | \~16,492,537 KII | \~1.045 KII |
| 0.67 or more | 0% (floor) | 0                | 0           |

### Each block

At the start of every block the module:

1. Does nothing if `supply_base` is `0` or the module account is empty.
2. Reads the bonded ratio and calculates the release.
3. Caps the release at the module account balance.
4. Sends the release to the fee collector.
5. Adds the release to `total_released` and emits a `reward_distributed` event.

If reading the bonded ratio or sending the funds fails, the module logs the error and skips that block. The chain does not halt.

### Params

| Param                   | Default    | Rule              | Description                                           |
| ----------------------- | ---------- | ----------------- | ----------------------------------------------------- |
| `token_denom`           | `akii`     | Valid denom       | Denom paid out                                        |
| `goal_bonded`           | `0.67`     | `0 < x ≤ 1`       | Target bonded ratio                                   |
| `inflation_min`         | `0`        | `≥ 0`             | Floor on the annual rate                              |
| `inflation_max`         | `0.20`     | `≥ inflation_min` | Ceiling on the annual rate                            |
| `supply_base`           | `0`        | `≥ 0`             | Emission scale in base units. `0` turns emissions off |
| `inflation_rate_change` | `0.13`     | `0 < x ≤ 1`       | Curve steepness                                       |
| `blocks_per_year`       | `15778800` | `> 0`             | Expected blocks per year                              |

### Internal state

```go
type RewardPool struct {
    // Cumulative amount sent to the fee collector
    TotalReleased types.Coin `protobuf:"bytes,3,opt,name=total_released,json=totalReleased,proto3" json:"total_released" yaml:"total_released"`
}
```

`RewardPool` only tracks what has been released. The funds available to pay out are the module account balance in the bank module.

### Messages

#### Update Params

Changes module params. Only the governance module account can send it, so others need to pass a proposal. All params must be supplied.

```protobuf
message MsgUpdateParams {
  // authority is the address of the governance account.
  string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ];

  // params defines the x/rewards parameters to update.
  //
  // NOTE: All parameters must be supplied.
  Params params = 2 [ (gogoproto.nullable) = false ];
}

message Params {
  string token_denom = 1;
  string goal_bonded = 2;           // LegacyDec, e.g. "0.67"
  string inflation_min = 3;         // LegacyDec, e.g. "0.00"
  string inflation_max = 4;         // LegacyDec, e.g. "0.20"
  string supply_base = 5;           // Int, base units; 0 disables emissions
  string inflation_rate_change = 6; // LegacyDec, e.g. "0.13"
  uint64 blocks_per_year = 7;
}
```

**State Modifications:**

* Validates and replaces all module params
* Setting `supply_base` above `0` starts emissions; setting it to `0` stops them. Funds stay in the module account.
* Emits an `update_params` event

#### Funding the pool

There is no fund message. Send tokens to the module account with a bank send:

```bash
kiichaind tx bank send <from> kii1245yut9zht8q4hz39sd0lzqtzkuw5us5rermc4 1000000000000000000000akii
```

### Enabling emissions

Create `proposal.json`:

```json
{
  "messages": [
    {
      "@type": "/kiichain.rewards.v1.MsgUpdateParams",
      "authority": "kii10d07y265gmmuvt4z0w9aw880jnsr700jrff0qv",
      "params": {
        "token_denom": "akii",
        "goal_bonded": "0.67",
        "inflation_min": "0",
        "inflation_max": "0.20",
        "supply_base": "1000000000000000000000000000",
        "inflation_rate_change": "0.13",
        "blocks_per_year": "15778800"
      }
    }
  ],
  "metadata": "",
  "deposit": "10000000akii",
  "title": "Enable utility rewards emissions",
  "summary": "Set supply_base to start x/rewards emissions"
}
```

Submit it:

```bash
kiichaind tx gov submit-proposal proposal.json --from <key>
```

Set the deposit to at least the governance minimum deposit for the network. To stop emissions, submit the same proposal with `"supply_base": "0"`.

### Queries

| CLI                               | REST                                   | Returns                                                     |
| --------------------------------- | -------------------------------------- | ----------------------------------------------------------- |
| `kiichaind q rewards params`      | `GET /kiichain/rewards/v1/params`      | Module params                                               |
| `kiichaind q rewards reward-pool` | `GET /kiichain/rewards/v1/reward-pool` | `total_released` and the module account balance (`balance`) |

### Events

| Type                 | Attributes                                                   | When                                   |
| -------------------- | ------------------------------------------------------------ | -------------------------------------- |
| `update_params`      | —                                                            | Params are updated                     |
| `reward_distributed` | `amount`, `total_released`, `inflation_rate`, `bonded_ratio` | A release is sent to the fee collector |

### Upgrading from the release schedule

Earlier versions of the module released a fixed budget linearly until an end date (`ReleaseSchedule`). That model was removed in consensus version 2, together with `MsgChangeSchedule`, `MsgFundPool`, and the release-schedule query and CLI.

The upgrade migration deletes the old schedule, fills the new params with defaults, and keeps the existing `token_denom`. `supply_base` stays `0`, so emissions stay off until governance enables them.

The API package is now `kiichain.rewards.v1`. The old `kiichain.rewards.v1beta1` types are still registered so existing transactions and proposals decode:

| v1beta1                 | Behavior                                                 |
| ----------------------- | -------------------------------------------------------- |
| `MsgUpdateParams`       | Updates only `token_denom`                               |
| `MsgFundPool`           | Returns an error. Use a bank send to the module account. |
| `MsgChangeSchedule`     | Returns an error                                         |
| `Query/Params`          | Returns `token_denom` only                               |
| `Query/RewardPool`      | Reports the module account balance as `community_pool`   |
| `Query/ReleaseSchedule` | Returns an error                                         |


# Oracle

The Oracle module brings up price feeds and exchange rates to Kiichain.

* It allows validators to submit price data, which can be used by other modules or smart contracts (EVM and Wasm).
* It supports multiple price feeds, allowing for a diverse set of data sources
* It provides a mechanism for price data to be aggregated and made available on-chain

### Price feeder

Our official implementation for the price feeder is available at [Kiichain Price Feeder](https://github.com/KiiChain/price-feeder).

* The price must be ran by a validator or a delegated address
* The price feeder is responsible for submitting the price data to the Oracle module
* More information can be found at the project readme

### Core functionality

The Oracle module works as follows:

* Validators submit price data for arbitrary assets, which are defined in the module params
* The module aggregates the price data submitted by validators and calculates a final exchange rate for each asset
* The final exchange rate is stored on-chain and can be queried by other modules or smart contracts

The Exchange Vote is done as following:

1. A new block is created
2. Validators submit their votes for the price of each asset in the whitelist through the `MsgExchangeRateVote` message

* This message is feeless as long as its the first vote for the validator in the current voting period
* The vote can be submitted by the validator itself or a delegated address (feeder address)
  * By using a delegated address, validators can separate their voting actions from their staking address

3. The module aggregates the votes and calculates the final exchange rate for each asset
4. If no vote is submitted by a validator in the current voting period, the module will slash the validator's stake according to the `slash_fraction` parameter
5. The final exchange rate is stored on-chain and can be queried by other modules or smart contracts

### Interaction with other modules

<table><thead><tr><th width="155.83331298828125">Module</th><th>Interaction</th></tr></thead><tbody><tr><td>Account</td><td>Enforces oracle module account</td></tr><tr><td>Bank</td><td>Checks balances and update denom metadata of tokens</td></tr><tr><td>Staking</td><td>Fetches validator information for tally and potentially slash them on misbehavior</td></tr><tr><td>Price feed</td><td>External tool that fetches and calculates prices</td></tr></tbody></table>

### State

These are the most important state types used by the Oracle module:

#### Params

Params stores the module wide configuration. Its defined as:

```protobuf
// Params defines the parameters for the module
message Params {
    option (gogoproto.equal)            = true;
    option (gogoproto.goproto_stringer) = false; // Allow custom logs

    // The number of blocks per voting
    uint64 vote_period =1 [(gogoproto.moretags) = "yaml:\"vote_period\""];

    // Minimum percentage of validators required to approve a price. For instance, if vote_threshold = "0.5" at least 50% of validators must submit votes
    // "cosmossdk.io/math.LegacyDec" = Cosmos SDK decimal data type
    string vote_threshold = 2 [
        (gogoproto.moretags) = "yaml:\"vote_threshold\"",
        (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
        (gogoproto.nullable) = false
    ];

    // Acceptable deviation from the media price (higher and lower)
    // "cosmossdk.io/math.LegacyDec" = Cosmos SDK decimal data type
    string reward_band = 3 [
        (gogoproto.moretags) = "yaml:\"reward_band\"",
        (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
        (gogoproto.nullable) = false
    ];

    // List of allowed assets
    // DenomList is a custom data type, defined on x/oracle/types/denom.go
    repeated Denom whitelist = 4 [
        (gogoproto.moretags) = "yaml:\"whitelist\"",
        (gogoproto.castrepeated) = "DenomList",
        (gogoproto.nullable) = false
    ];

    // How much stake is slashed if a validator fails to submit votes
    // "cosmossdk.io/math.LegacyDec" = Cosmos SDK decimal data type
    string slash_fraction = 5 [
        (gogoproto.moretags) = "yaml:\"slash_fraction\"",
        (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
        (gogoproto.nullable) = false
    ];

    // Define the window (in blocks) to vote, if not receive penalties due to bad performance
    uint64 slash_window = 6 [(gogoproto.moretags) = "yaml:\"slash_window\""];

    // Minimum percentage of voting on windows to avoid slashing. For instance, if min_valid_per_window = 0.8, then a validator must submit votes in 80% of windows to avoid slashing
    // "cosmossdk.io/math.LegacyDec" = Cosmos SDK decimal data type
    string min_valid_per_window = 7 [
        (gogoproto.moretags) = "yaml:\"min_valid_per_window\"",
        (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
        (gogoproto.nullable) = false
    ];

    // How far back (in blocks) the module can compute historical price metrics
    uint64 lookback_duration = 9 [(gogoproto.moretags) = "yaml:\"lookback_duration\""];
}
```

#### Exchange Rates

Exchange rates are the single entry for a price data on the chain. Its stored as a Key-Value pair in the store, where the key is the asset denom and the value is the price data.

The price data is defined as:

```protobuf
// Data type that stores the final calculated exchange rate after all votes were
// aggregated to that single exchange, record the last block height and timestamp when rate was updated
message OracleExchangeRate {
    option (gogoproto.equal)            = false;
    option (gogoproto.goproto_getters)  = false;
    option (gogoproto.goproto_stringer) = false;

    string exchange_rate = 1 [
        (gogoproto.moretags)   = "yaml:\"exchange_rate\"",
        (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
        (gogoproto.nullable)   = false
    ];

    string last_update = 2 [
        (gogoproto.moretags)   = "yaml:\"last_update\"",
        (gogoproto.customtype) = "cosmossdk.io/math.Int",
        (gogoproto.nullable)   = false
    ];

    int64 last_update_timestamp = 3 [(gogoproto.moretags)   = "yaml:\"last_update_timestamp\""];
}
```

#### FeederDelegation

Feeder delegations is the correlation between a validator and a feeder address. It allows validators to use a different address to submit votes.

The FeederDelegation is defined as:

```protobuf
// FeederDelegation is the structure on the genesis regarding the delegation process
message FeederDelegation {
  // feeder_address is the address delegated
  string feeder_address    = 1;

  // validator_address is the validator's address who delegate its voting action
  string validator_address = 2;
}
```

### Messages

The Oracle module expose the following messages:

#### AggregateExchangeRateVote

The `MsgAggregateExchangeRateVote` message is used by validators to submit their votes for the price of each asset in the whitelist. It contains the following fields:

```protobuf
// MsgAggregateExchangeRateVote represent the message to submit
// an aggregate exchange rate vote
message MsgAggregateExchangeRateVote{
  option (gogoproto.equal)           = false;
  option (gogoproto.goproto_getters) = false;

  option (cosmos.msg.v1.signer) = "feeder";
  option (amino.name) = "oracle/aggregate-exchange-rate-vote";

  string exchange_rates = 1 [(gogoproto.moretags) = "yaml:\"exchange_rates\""];
  string feeder = 2 [(gogoproto.moretags) = "yaml:\"feeder\""];
  string validator = 3 [(gogoproto.moretags) = "yaml:\"validator\""];
}
```

#### DelegateFeedConsent

The `MsgDelegateFeedConsent` message is used to delegate the right to submit votes to a different address. The message contains the following fields:

```protobuf
// MsgDelegateFeedConsent represents a message to delegate oracle voting
// rights to another address
message MsgDelegateFeedConsent{
  option (gogoproto.equal)           = false;
  option (gogoproto.goproto_getters) = false;

  option (cosmos.msg.v1.signer) = "validator_owner";
  option (amino.name) = "oracle/delegate-feed-consent";

  string validator_owner = 1 [(gogoproto.moretags) = "yaml:\"validator_owner\""];
  string delegate = 2 [(gogoproto.moretags) = "yaml:\"delegate\""];
}
```

#### UpdateParams

The `MsgUpdateParams` message is used to update the module parameters. Only the governance module can call the message. It contains the following fields:

```protobuf
// MsgUpdateParams is the Msg/UpdateParams request type
message MsgUpdateParams {
  option (cosmos.msg.v1.signer) = "authority";

  // authority is the address that controls the module (defaults to x/gov)
  string authority    = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"];
  option (amino.name) = "kiichain/x/oracle/MsgUpdateParams";

  // params defines the x/oracle parameters to update
  //
  // NOTE: All parameters must be supplied.
  Params params = 2 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true];
}
```

### Begin block

On each ABCI call, the Oracle module performs the following actions:

1. Check if we are under a new slash window
2. Check the slash counters for validators and slash them if they didn't submit enough votes in the previous voting period
3. Remove the excess feeds

### End block

At the end of each block, the Oracle module performs the following actions:

1. Check if we are under a new voting period
2. Iterate the votes
3. Calculate the final exchange rate for each asset in the whitelist
4. Store the final exchange rate on-chain

### Ante handler

The Oracle module ignores fees from validators on their first vote in the current voting period. The following is done:

1. Check if the message is a `MsgAggregateExchangeRateVote`
2. Check the validator/feeder relationship
3. If the validator is voting for the first time in the current voting period, ignore the fees

## Acknowledgments

Special thanks to the SEI team. Your contributions to the Cosmos SDK ecosystem are greatly appreciated. The original implementation of the Oracle module can be found in the [SEI repository](https://github.com/sei-protocol/sei-chain/tree/main/x/oracle)


# Fee Abstraction

The Fee Abstraction module allows the payment of transaction fees in other arbitrary tokens different from the native token of the chain. This allows users to pay for fees in a more flexible way, using stablecoins, for example.

The functionality of the module allows:

* Pricing of transaction fees in arbitrary tokens.
* Payment through native token (unwrapped) or through ERC20 tokens (wrapped).
* Pricing of tokens is defined by the oracle module, which provides the exchange rates for the tokens.
  * This allows the use of stablecoins as fee tokens.
* Applies safety mechanisms to prevent price manipulation:
  * Uses TWAP (Time-Weighted Average Price) instead of spot prices.
  * Applies a clamp factor to limit extreme price deviations.
  * Disables tokens with missing or zero prices.

### Core functionality

In its code, the module changes the fee-paying ante handlers to allow payment of fees with tokens different from the native gas token.

* This is done through both EVM and cosmos SDK ante handlers.
* The pricing of tokens is done with the following logic:
  * The price of the token is defined by the oracle module in USD
  * The module then stores the price of the token per gas token
  * This allows for easy conversion when paying fees
  * And allows for easy querying

### Interaction with other modules

<table><thead><tr><th width="141.16668701171875">Module</th><th>Interaction</th></tr></thead><tbody><tr><td>Bank</td><td>Used to check sufficient balance from signer</td></tr><tr><td>ERC20</td><td>Converts balance from alternate tokens used as fee</td></tr><tr><td>Oracle</td><td>Provides information for exchange rate used in token conversion</td></tr></tbody></table>

#### Price calculation

The price calculation happens at the beginning of each block:

* We query the oracle module for the Twap (Time Weighted Average Price) of all available tokens in USD
* Then we iterate over all the possible fee tokens and calculate the price of the token in gas tokens
  * The formula is:

```
price_in_gas_token = price_in_usd / gas_price_in_usd
```

* During this calculation, we don't consider decimals, and all prices are in the same unit
* The final pricing is stored in the module state

We have a few safety mechanisms to ensure the prices are valid:

* If the oracle module can't provide a price, the fee token is disabled
* If prices go to zero, the fee token is disabled
* The Twap of the token is used to avoid sudden price changes
* Price changes are clamped to avoid extreme values

#### Fee payment

The module by itself does not handle the fee payment:

* It returns available assets to each ante handler to process the deduct fee

The following is the process to check for possible fee tokens:

1. Ante handler receives and calculates the fee for the native gas token
2. The fee goes to the fee abstraction module and is validated
   * The module ignores zero tokens, tokens different from the native fee token, and fees with multiple tokens
   * Due to the chain EVM nature, fees with multiple tokens are not supported
3. The user's balance is checked for the fee token
   * If the user has enough balance, the fee is returned as it is
4. If the user does not have enough balance, the module checks for available fee tokens
   * The available fee tokens are those that have a valid price and are not disabled
5. The module then calculates the fee in the available fee tokens
   * The fee is calculated using the price stored in the module state
6. If not available through the unwrapped native token, the module checks for wrapped ERC20 tokens
   * If the user has enough balance in the wrapped token, the token is unwrapped
   * This makes the token available for the fee payment
7. The fee is returned from the module to the ante handler
8. The ante handler then deducts the fee from the user's balance

### State

The most important state types used by the Fee Abstraction module are:

#### Params

Params stores the module wide configuration. It is defined as:

```proto
// Params defines the parameters for the fee abstraction module
message Params {
  // Native denom
  string native_denom = 1;
  // Oracle module identifier
  string native_oracle_denom = 2;
  // Enabled indicates if the fee abstraction module is enabled
  bool enabled = 3;
  // ClampFactor is the factor to clamp the price deviation
  string clamp_factor = 4 [
    (gogoproto.moretags) = "yaml:\"clamp_factor\"",
    (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
    (gogoproto.nullable) = false
  ];
  // TwapLookbackWindow is the lookback window for calculating TWAPs
  uint64 twap_lookback_window = 5;
  // FallbackNativePrice is the fallback price for the native token if the
  // oracle price is not available (in USD)
  string fallback_native_price = 6 [
    (gogoproto.moretags) = "yaml:\"fallback_native_price\"",
    (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
    (gogoproto.nullable) = false
  ];
}
```

#### FeeToken

FeeToken stores the information about a fee token. It is defined as:

```proto
// FeeTokenMetadata defines the metadata for a fee token
message FeeTokenMetadata {
  // Denom is the token denom
  string denom = 1;
  // Identifier on the oracle module
  string oracle_denom = 2;
  // Decimals is the number of decimals for the token
  uint32 decimals = 3;
  // Price is the price of the token in the native denom
  // This price is paired against the native denom
  // So, this equals to the token/native denom
  string price = 4 [
    (gogoproto.moretags) = "yaml:\"price\"",
    (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
    (gogoproto.nullable) = false
  ];
  // Enabled indicates if the token is enabled for fee abstraction
  bool enabled = 6;
}

// Defines a collection of fee token metadata
message FeeTokenMetadataCollection {
  // Items is a repeated field of FeeTokenMetadata
  repeated FeeTokenMetadata items = 1 [ (gogoproto.nullable) = false ];
}
```

### Messages

The module defines the following messages:

#### MsgUpdateParams

MsgUpdateParams is used to update the module parameters. Only the governance account can update the parameters, and it requires a valid signature. It is defined as:

```proto
// MsgUpdateParams is the Msg/UpdateParams request type.
message MsgUpdateParams {
  option (cosmos.msg.v1.signer) = "authority";
  option (amino.name) = "feeabstraction/update-params";

  // authority is the address of the governance account.
  string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ];

  // params defines the x/feeabstraction parameters to update.
  Params params = 2 [ (gogoproto.nullable) = false ];
}
```

#### MsgUpdateFeeTokens

The `MsgUpdateFeeTokens` message is used to update the fee tokens metadata. Only the governance account can update the fee tokens, and it requires a valid signature. On each update, all fee tokens must be provided, even if they are not changed:

* Ordering is important, since the balance will be calculated based on the order of the fee tokens.

It is defined as:

```proto
// MsgUpdateFeeTokens is the Msg/UpdateFeeTokens request type.
message MsgUpdateFeeTokens {
  option (cosmos.msg.v1.signer) = "authority";
  option (amino.name) = "feeabstraction/update-fee-tokens";

  // authority is the address of the governance account.
  string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ];

  // fee_tokens defines the fee tokens to update.
  FeeTokenMetadataCollection fee_tokens = 2 [ (gogoproto.nullable) = false ];
}
```

### Queries

The module provides the following queries:

#### QueryParams

The `QueryParams` query is used to retrieve the current module parameters. It does not require any input and returns the current parameters.

```proto
// QueryParamsResponse is the response type for the Query/Params RPC method.
message QueryParamsResponse {
  // params defines the parameters of the module.
  Params params = 1 [ (gogoproto.nullable) = false ];
}
```

#### QueryFeeTokens

The `QueryFeeTokens` query is used to retrieve the current fee tokens metadata. It does not require any input and returns the current fee tokens.

```proto
// QueryFeeTokensResponse is the response type for the Query/FeeTokens RPC
// method
message QueryFeeTokensResponse {
  // fee_tokens defines the fee tokens registered in the module.
  FeeTokenMetadataCollection fee_tokens = 1;
}
```

### Begin block

On each ABCI call, the Fee Abstraction module performs the following actions:

1. Check the current Twap for each fee token against the oracle module.
2. Update the price of each fee token based on the Twap.
3. Clamp the price of each fee token to avoid extreme values.
4. Disable fee tokens that have no valid price or have a price of zero.
5. Update the module state with the new prices and enabled status of the fee tokens.
6. If the module is disabled, it will not perform any of the above actions and will not allow fee abstraction.

### Ante Handlers

The Fee Abstraction module provides custom ante handlers to handle fee payments in the specified fee tokens.

#### fee.go (Cosmos Ante Handler)

This is the Cosmos SDK ante handler:

* Has the same implementation as the [original fee ante handler](https://github.com/cosmos/cosmos-sdk/blob/main/x/auth/ante/fee.go).
* The main difference is that the fees goes though the Fee Abstraction module before fee deduction.

#### mono\_decorator.go (EVM Ante Handler)

This is the EVM ante handler:

* Since the EVM module has a coupled implementation of the ante handler, the whole ante had to be migrated
* The implementation is mostly the same as the [original EVM ante handler](https://github.com/cosmos/evm/blob/main/ante/evm/mono_decorator.go)

The following was required to be changed:

* Balance checks were broken down into different steps:
  * Check if the user has enough balance to pay for fees
  * Check if the user has enough balance to pay for TX value
* Account creation was moved up to allow accounts to exist before the fee deduction
* At the end of the ante handler, the fee is registered on the context
  * This allows fee refunds to be processed correctly

### Limitation

A limitation happens with **fresh wallets** (wallets that have never executed a transaction):

* **Scenario 1: Fresh wallet with ERC20 (wrapped) fee tokens**
  * If the first transaction attempted is a **Cosmos SDK transaction** using only ERC20 fee tokens:
    * The transaction will **fail with an “account doesn’t exist” error**.
    * This is because the Cosmos SDK requires an on-chain account to exist prior to executing any Cosmos transaction, and ERC20 balances alone do not create the account record.
* **Scenario 2: Fresh wallet with native (unwrapped) fee tokens**
  * If the first transaction attempted is a **Cosmos SDK transaction** using native fee tokens:
    * The transaction will **succeed**, as the presence of the native asset allows account creation during the transaction flow, and the fee abstraction module can process the fees normally.
* **Scenario 3: Fresh wallet with either ERC20 or native fee tokens, performing EVM transactions**
  * If the first transaction attempted is an **EVM transaction**:
    * The transaction will **succeed**, regardless of whether the wallet holds ERC20 or native tokens, as the EVM module internally handles account creation differently.

#### Implication

Users must perform **one of the following actions** before attempting a Cosmos SDK transaction using ERC20 fee tokens:

* Fund the wallet with **any amount of the native (unwrapped) token** and execute a small Cosmos transaction to create the account.
* Or perform an **EVM transaction first** which also creates the account record.


# Precompiled contracts

KiiChain has precompiled smart contracts crafted to allow EVM interaction with the Cosmos SDK functionalities

### List of precompiles and their addresses

KiiChain supports both EVM JSON-RPC and Cosmos RPC interfaces. In order to easily interact with certain Cosmos modules, KiiChain has a set of precompiled contracts that can be called from the EVM.

<table><thead><tr><th width="134.41668701171875">Precompile</th><th>Description</th><th>Address</th></tr></thead><tbody><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/bank">Bank</a></td><td>Provides functionalities for checking balances and supply</td><td>0x0000000000000000000000000000000000000804</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/bech32">Bech32</a></td><td>Utilities for address format conversion between EVM and Cosmos</td><td>0x0000000000000000000000000000000000000400</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/distribution">Distribution</a></td><td>Deals with reward distribution and related</td><td>0x0000000000000000000000000000000000000801</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/governance">Governance</a></td><td>Supports actions such as depositing funds into proposals, voting and interacting with proposals</td><td>0x0000000000000000000000000000000000000805</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/p256">P256</a></td><td>Support for verifying secp256r1 curve signatures</td><td>0x0000000000000000000000000000000000000100</td></tr><tr><td><a href="https://docs.kiiglobal.io/docs/build-on-kiichain/precompiled-contracts/oracle-precompile">Oracle</a></td><td>Support for price information and oracle module</td><td>0x0000000000000000000000000000000000001003</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/slashing">Slashing</a></td><td>Provides management and query options for penalties</td><td>0x0000000000000000000000000000000000000806</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/staking">Staking</a></td><td>Enables staking functionalities like delegation and undelegation or obtaining information on validators.</td><td>0x0000000000000000000000000000000000000800</td></tr><tr><td>Vesting</td><td>Interacts with Cosmos Vesting module</td><td>0x0000000000000000000000000000000000000803</td></tr><tr><td><a href="https://docs.cosmos.network/evm/v0.5.0/documentation/smart-contracts/precompiles/werc20">WERC20</a></td><td>ERC20 interface for native Kii</td><td>0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE</td></tr></tbody></table>

### Interacting with precompiles

You can utilize direct json-rpc connections to those addresses. We also have [a TS/JS library ](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/js-ts-sdk/kiijs-evm)to help interact with them.


# Oracle Precompile

The oracle precompile provides access to real-time exchange rate data and time-weighted average prices (TWAPs) for different denominations.

### **Functions**

| Function Name          | Input Parameters                                    | Return Value                                                                                                                                                  | Description                                                                                        |
| ---------------------- | --------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- |
| **`getExchangeRate`**  | `denom: string` (currency denomination)             | <p><code>rate: string</code><br><code>lastUpdate: string</code><br><code>lastUpdateTimestamp: int64</code></p>                                                | Gets the current exchange rate for a specific denomination with update metadata                    |
| **`getExchangeRates`** | None                                                | <p><code>denoms: string\[]</code><br><code>rates: string\[]</code><br><code>lastUpdate: string\[]</code><br><code>lastUpdateTimestamps: uint256\[]</code></p> | Gets exchange rates for all available denominations with update metadata                           |
| **`getTwaps`**         | `lookbackSeconds: uint256` (time window in seconds) | <p><code>denoms: string\[]</code><br><code>twaps: string\[]</code></p>                                                                                        | Gets time-weighted average prices (TWAPs) for all denominations over the specified lookback period |

**Precompile Address**

`0x0000000000000000000000000000000000001003`


# Getting Started


# What is a delegator?

A delegator is a person or entity that wants to Stake their tokens without managing a node or full node.

### Delegating = Staking

People who cannot or do not want to operate Validators (full nodes) can still participate in the staking process as delegators. Indeed, validators are not chosen based on their self-delegated stake but based on their total stake, which is the sum of their self-delegated stake and of the stake that is delegated to them. This is an important property, as it makes delegators a safeguard against validators who exhibit bad behavior. If a validator misbehaves, their delegators will move their KIIs away from them, thereby reducing their stake. Eventually, if a validator's stake falls under the top 100 addresses with the highest stake, they will exit the validator set.

Delegators share the revenue of their validators, but they also share the risks. In terms of revenue, validators, and delegators differ in that validators can apply a commission on the revenue that goes to their delegator before it is distributed. This commission is known to delegators beforehand and can only change according to predefined constraints (see section below). In terms of risk, delegators' KIIs can be slashed if their validator misbehaves.

To become delegators, KII holders need to send a "Delegate transaction" where they specify how many KIIs they want to bond and to which validator. A list of validator candidates will be displayed in KII Explorer. Later, if a delegator wants to unbond part or all of their stake, they needs to send an "Unbond transaction". From there, the delegator will have to wait 21 days to retrieve their KIIs. Delegators can also send a "Rebond Transaction" to switch from one validator to another, without having to go through the 3-week waiting period.

### What is staking? <a href="#what-is-staking" id="what-is-staking"></a>

Kiichain is a public Proof-Of-Stake (PoS) blockchain, meaning that the weight of validators is determined by the amount of staking tokens (KII) bonded as collateral. These KII tokens can be self-delegated directly by the validator or delegated to the validator by other KII holders.

Any user in the system can declare their intention to become a validator by sending a `create-validator` transaction to become validator candidates.

The weight (i.e. voting power) of a validator determines whether they are an active validator.


# What is a validator?

Validators power the network.

### What is a Kii validator? <a href="#what-is-a-cosmos-validator" id="what-is-a-cosmos-validator"></a>

KiiChain is a Cosmos-based blockchain powered by CometBFT that relies on a set of validators to secure the network. The role of validators is to run a full node and participate in consensus by broadcasting votes that contain cryptographic signatures signed by the validator's private key. Validators commit new blocks in the blockchain and receive revenue in exchange for their work. Validators must also participate in governance by voting on proposals. Validators are weighted according to their total stake.

**Validator minimum:** 10,000 KII

### What is a full node? <a href="#what-is-a-full-node" id="what-is-a-full-node"></a>

A full node is a server running a chain's *binary* (its software) that fully validates transactions and blocks of a blockchain and keeps a full record of all historic activity. A full node is distinct from a pruned node that processes only block headers and a small subset of transactions. Running a full node requires more resources than a pruned node. Validators can decide to run either a full node or a pruned node, but they need to make sure they retain enough blocks to be able to validate new blocks.

Of course, it is possible and encouraged for users to run full nodes even if they do not plan to be validators.


# What is an Oracle?

An oracle is a blockchain component that provides external real-world data and store on the Blockchain

### What is the Kii Oracle? <a href="#what-is-a-cosmos-validator" id="what-is-a-cosmos-validator"></a>

The **Kii Oracle** is a decentralized price feed system that provides secure and reliable real-world market data (primarily cryptocurrency prices and tokenized assets) to the KiiChain blockchain. Unlike simple data oracles, it implements a robust **validator-based consensus mechanism** where:

* **Trusted validators** independently fetch prices from multiple exchanges
* Submitted prices are aggregated using a **weighted median** (where voting power corresponds to a validator's stake)
* Votes that deviate beyond predefined **standard deviation thresholds** are automatically rejected, preventing price manipulation
* The final agreed-upon price is recorded on-chain through on-chain **Oracle** module

This dual-layer system (off-chain data collection + on-chain consensus) ensures DeFi applications like stablecoins and lending protocols receive **tamper-resistant price data** while maintaining full decentralization.

### What kind of information does the Kii Oracle store? <a href="#what-is-a-cosmos-validator" id="what-is-a-cosmos-validator"></a>

The Kii Oracle stores and manages:

* **Cryptocurrency price pairs** (e.g., `BTC/USDT`, `ETH/USDT`) with:
  * **Chain-denominated values** (e.g., `ubtc`, `uusdt` for KiiChain assets).
  * **Deviation thresholds** to prevent volatile or manipulated data.
  * **Provider lists** (e.g., Binance, Coinbase) for data aggregation.
* **Validator-submitted prices**, aggregated into a consensus value.

The data is stored on-chain in the Oracle module’s state and updated periodically by the `price-feeder` to ensure accuracy.

### **What is the Purpose of an Oracle in Kiichain**?

An Oracle in **Kiichain** serves as the **essential bridge** between blockchain-based financial applications and real-world market data. It provides **secure, decentralized, and tamper-proof price feeds** that enable smart contracts to interact with external economic information and empowers developers to build financial tools with key requirements such as **open, fair, and resilient**.


# Run a Validator / Full Node

Initial steps before announcing your entry as a validator

**Introduction**

Kiichain is a cosmos based blockchain that relies on a set of validators that are responsible for committing new blocks in the blockchain. These validators participate in the consensus protocol by broadcasting votes that contain cryptographic signatures signed by each validator's private key.

Validator candidates can bond their own KII and have KII "delegated", or staked, to them by token holders. Kiichain has an open set of 100 validators who reviews rewards, but over time the number of validators can be increased with governance proposals. The validators are determined by the total number of KII tokens delegated to them — the top 100 validator candidates with the most voting power are the current Kii validators.

Validators and their delegators earn KII as block provisions and tokens as transaction fees through execution of the Tendermint consensus protocol. Note that validators can set a commission percentage on the fees their delegators receive as additional incentive.

If validators double sign or are offline for an extended period, their staked KII (including KII of users that delegated to them) can be slashed. The penalty depends on the severity of the violation.

**Hardware**

For validator key management, validators must set up a physical operation that is secured with restricted access. A good starting place, for example, would be co-locating in secure data centers.

Validators are expected to equip their datacenter location with redundant power, connectivity, and storage backups. Expect to have several redundant networking boxes for fiber, firewall, and switching and then small servers with redundant hard drive and failover.

As the network grows, bandwidth, CPU, and memory requirements rise. Large hard drives are recommended for storing years of blockchain history, as well as significant RAM to process the increasing amount of transactions.

**Create a Validator Website**

To get started as a validator, create your dedicated validator website and signal your intention to become a validator in the Kii Discord validator channel. Posting your validator website is essential because delegators want to have information about the entity who is receiving their delegated KII.

**Seek Legal and Tax Advice**

As always, do your own research and seek legal advice if you intend to run a validator node.

**Community**

Discuss the finer details of being a validator on our community Discord. Follow Kii Global on all socials and sign up for the Kii newsletter to get regular updates.


# Getting started

Everyone is welcome to launch their own validator. Please review all information carefully.

### How to become a validator? <a href="#how-to-become-a-validator" id="how-to-become-a-validator"></a>

Any participant in the network can signal that they want to become a validator by sending a `create-validator` transaction, where they must fill out the following parameters:

* **Validator's Pubkey:** The private key associated with this Tendermint `PubKey` is used to sign *prevotes* and *precommits*.
* **Validator's Address:** Application level address that is used to publicly identify your validator. The private key associated with this address is used to delegate, unbond, claim rewards, and participate in governance.
* **Validator's name**
* **Validator's website (Optional)**
* **Validator's description (Optional)**
* **Initial commission rate**: The commission rate on block rewards and fees charged to delegators.
* **Maximum commission:** The maximum commission rate that this validator can charge. This parameter is fixed and cannot be changed after the `create-validator` transaction is processed.
* **Commission max change rate:** The maximum daily increase of the validator commission. This parameter is fixed cannot be changed after the `create-validator` transaction is processed.

After a validator is created, KII holders can delegate KII to them, effectively adding stake to the validator's pool. The total stake of an address is the combination of KII bonded by delegators and KII self-bonded by the validator.

From all validator candidates that signaled themselves, the 100 validators with the most total stake are the designated **validators**. If a validator's total stake falls below the top 100, then that validator loses its validator privileges. The validator cannot participate in consensus or generate rewards until the stake is high enough to be in the top 100. Over time, the maximum number of validators may be increased via on-chain governance proposal.


# Step-by-Step Guide

Onboarding for validators

It's always nice to see new users onboarding into the Testnet Oro.

This will guide you through the process of running your own full node, then [becoming a validator](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/step-by-step-guide/becoming-a-validator) and finally running[ the price feeder](https://docs.kiiglobal.io/docs/validate-the-network/run-a-validator-full-node/running-the-price-feeder)

## Install

`kiichaind` is the command-line interface (CLI) for interacting with the Kiichain blockchain. This section covers the installation of the necessary binaries to run a Kiichain node.

### Requirements

* **Golang version:** `v1.23.x`
* **Build tools:** `build-essential` package (Linux)

### Binary installation

To install Kiichain, download the pre-built binaries:

```bash
git clone https://github.com/KiiChain/kiichain.git
cd kiichain
make install
```

Verify the installation by checking the version of kiichaind:

```bash
kiichaind version
```

## Joining the Testnet

To join the Testnet Oro, you must have the daemon `kiichaind` installed in your machine.

### Recommended configuration

For optimal performance, we recommend:

* 4 vCPU x86\_64
* 8 GB RAM
* 1 TB NVME SSD

### Quick bootstrap

The easiest way to prepare a node is by using our provided scripts.

{% hint style="info" %}
These scripts are designed for systems running **Ubuntu 20.04** or **Ubuntu 22.04**. Ensure your operating system matches this requirement before proceeding.
{% endhint %}

* **Join Testnet Oro Script**: Use this script to bootstrap a full node quickly.

```bash
curl -O https://raw.githubusercontent.com/KiiChain/testnets/refs/heads/main/testnet_oro/join_oro.sh
chmod +x join_oro.sh
./join_oro.sh
```

* **Join Testnet with Cosmosvisor Script**: Use this script to set up a full node with Cosmosvisor for automated upgrades

```bash
curl -O https://raw.githubusercontent.com/KiiChain/testnets/refs/heads/main/testnet_oro/join_oro_cv.sh
chmod +x join_oro_cv.sh
./join_oro_cv.sh
```

### Running your node

Prepare your system by backing up and removing old configurations:

```bash
# Backup old configuration
cp -r $HOME/.kiichain $HOME/.kiichain-bk
# Clean any old configuration
rm -r $HOME/.kiichain
```

Connect to the testnet with the following commands:

```bash
# Variables used during the configuration
PERSISTENT_PEERS="5b6aa55124c0fd28e47d7da091a69973964a9fe1@uno.sentry.testnet.v3.kiivalidator.com:26656,5e6b283c8879e8d1b0866bda20949f9886aff967@dos.sentry.testnet.v3.kiivalidator.com:26656"
CHAIN_ID="oro_1336-1"
NODE_HOME=~/.kiichain
NODE_MONIKER=testnet_oro
GENESIS_URL=https://raw.githubusercontent.com/KiiChain/testnets/refs/heads/main/testnet_oro/genesis.json
MINIMUM_GAS_PRICES="1000000000akii"

# Initialize the chain
kiichaind init $NODE_MONIKER --chain-id $CHAIN_ID --home $NODE_HOME

# Set the persistent-peers
sed -i -e "/persistent-peers =/ s^= .*^= \"$PERSISTENT_PEERS\"^" $NODE_HOME/config/config.toml
# Set the min gas price
sed -i -e "/minimum-gas-prices =/ s^= .*^= \"$MINIMUM_GAS_PRICES\"^" $NODE_HOME/config/app.toml

# Set the genesis
wget $GENESIS_URL -O genesis.json
mv genesis.json $NODE_HOME/config/genesis.json

# Start the chain
kiichaind start --home $NODE_HOME
```

**(Optional but recommended)**: Before running the chain you can also check the SHA256:

```bash
sha256sum $NODE_HOME/config/genesis.json
```

The expected SHA256 checksum is: `2805ae1752dc8c3435afd6bdceea929b3bbd2883606f3f3589f4d62c99156d2d`

{% hint style="warning" %}
This configuration runs a full node. For validators, update the configuration accordingly!
{% endhint %}

### Cosmosvisor

Cosmosvisor is a process manager for handling chain upgrades. It enables low maintenance and automatic updates for nodes.

* If an upgrade is scheduled, cosmosvisor has the capability of automatically downloading binaries and restarting any Kiichain processes
* This gives the node low maintenance and auto updates capabilities

A version of our node bootstrapper can install cosmosvisor for you:

```
curl -O https://raw.githubusercontent.com/KiiChain/testnets/refs/heads/main/testnet_oro/join_oro_cv.sh
chmod +x join_oro_cv.sh
./join_oro_cv.sh
```

More information about cosmovision can be found at [Cosmosvisor Quick Start](https://docs.cosmos.network/v0.45/run-node/cosmovisor.html).

#### Preparing cosmosvisor upgrade

First, you need to compile new binaries:

* A new Kiichaind binary must be compiled with the target OS in mind
* Ideally, you should compile all binaries on it’s own machines
* **The build must be done on top of the upgrade tag (E.g. v1.0.1, v2.0.0)**
* Check the section [Binary Installation](#binary-installation) on how to do it

Make sure that the binary has the correct version with:

```
kiichaind version
```

To add a new upgrade you must run the following command on Cosmovisor:

```
cosmovisor add-upgrade <upgrade-name> <path-to-binary>
```

Where:

* `<upgrade-name>` is the on-chain upgrade name
* `<path-to-binary>` is the full path for the binary

Example:

```
cosmovisor add-upgrade 1.3.0 /home/ubuntu/kiichain/build/kiichaind
```

### Configure state sync

State sync significantly reduces the time required to synchronize a node by downloading and verifying state data from trusted peers rather than replaying every historical block. This is particularly beneficial for nodes joining the network late or recovering from a significant downtime.

Follow these steps to configure state sync for your Kiichain node:

1. **Set Trust Height Delta and Fetch Block Information**

Define a height delta and retrieve the latest block height and block hash from the primary RPC endpoint.

```shellscript
# Configure state-sync
TRUST_HEIGHT_DELTA=500
LATEST_HEIGHT=$(curl -s https://rpc.uno.sentry.testnet.v3.kiivalidator.com/block | jq -r ".block.header.height")
if [[ "$LATEST_HEIGHT" -gt "$TRUST_HEIGHT_DELTA" ]]; then
SYNC_BLOCK_HEIGHT=$(($LATEST_HEIGHT - $TRUST_HEIGHT_DELTA))
else
SYNC_BLOCK_HEIGHT=$LATEST_HEIGHT
fi

# Get the sync block hash
SYNC_BLOCK_HASH=$(curl -s "https://rpc.uno.sentry.testnet.v3.kiivalidator.com/block?height=$SYNC_BLOCK_HEIGHT" | jq -r ".block_id.hash")
```

2. Enable State Sync in Configuration

Modify the `config.toml` file to enable state sync and set the required parameters.

```bash
sed -i.bak -e "s|^enable *=.*|enable = true|" $NODE_HOME/config/config.toml
sed -i.bak -e "s|^rpc_servers *=.*|rpc_servers = \"$PRIMARY_ENDPOINT,$SECONDARY_ENDPOINT\"|" $NODE_HOME/config/config.toml
sed -i.bak -e "s|^trust_height *=.*|trust_height = $SYNC_BLOCK_HEIGHT|" $NODE_HOME/config/config.toml
sed -i.bak -e "s|^trust_hash *=.*|trust_hash = \"$SYNC_BLOCK_HASH\"|" $NODE_HOME/config/config.toml
```

### Turning your node into an archival node

Newly created nodes have the pruning option configured as default. If you desire to turn your node into an archival node, the following flag must be changed:

1. Go to `$NODE_HOME/config/app.toml`and update the following flag:

```
pruning = "nothing"
```

Other options available as default for pruning are:

* `default`: Keep the recent 362880 blocks and prune is triggered every 10 blocks
* `nothing`: all historic states will be saved, and nothing will be deleted (i.e. archiving node)
* `everything`: all saved states will be deleted, storing only the recent 2 blocks; pruning at every block
* `custom`: allow pruning options to be manually specified through 'pruning-keep-recent' and 'pruning-interval'

### Node Architecture for Validators

Further instructions on how to build a great node architecture can be found on:

* [Playbook For Cosmos Validators: Node Architecture Choices](https://medium.com/@kidinamoto/tech-choices-for-cosmos-validators-27c7242061ea)

## References

* [Running a Validator](https://hub.cosmos.network/main/validators/validator-setup.html)
* [Playbook For Cosmos Validators: Node Architecture Choices](https://medium.com/@kidinamoto/tech-choices-for-cosmos-validators-27c7242061ea)
* [Cosmosvisor Quick Start](https://docs.cosmos.network/v0.45/run-node/cosmovisor.html)
* [Join Testnet Oro](https://raw.githubusercontent.com/KiiChain/testnets/refs/heads/main/testnet_oro/join_oro.sh)
* [Join Testnet Oro CV](https://raw.githubusercontent.com/KiiChain/testnets/refs/heads/main/testnet_oro/join_oro_cv.sh)




---

[Next Page](https://docs.kiiglobal.io/docs/llms-full.txt/1)

