Exchange - project-sapphire/prism GitHub Wiki

An exchange provides one PUB and one REP socket. These are bound on static addresses.

PUB

Periodically publishes the latest exchange data with the following frames:

  1. currency code
  2. module id
  3. array
    1. currency code
    2. rate

REP

Handles queries with the frames:

  1. operation
  2. currency code
  3. ...

Queries

  • history

    Returns history for a currency.

    Fields:

    1. array
      1. array
        1. currency code
        2. rate