# exchange

# Abstract

The exchange module is the heart of the Injective Chain which enables fully decentralized spot and derivative exchange.
It is the sine qua non module of the chain and integrates tightly with the auction, insurance, oracle, and peggy modules.

The exchange protocol enables traders to create and trade on arbitrary spot and derivative markets. The entire process of orderbook management, trade execution, order matching and settlement occurs on chain through the logic codified by the exchange module.

The exchange module enables the exchange of tokens on two types of markets:

  1. Derivative Market: Either a Perpetual Swap Market or a Futures Market.
  2. Spot Market

# Contents

  1. Derivative Market Concepts
  2. Spot Market Concepts
  3. Other Concepts
  4. State
  5. State Transitions
  6. Messages
  7. Proposals
  8. Begin Block
  9. End Block
  10. Events
  11. Params