#Peatio 1.7.0 (April 19, 2018)


This release is focused on:

  1. Ability to manage currencies in admin panel.

  2. Ability to manage market pairs in admin panel.

  3. Support for multiple fiat currencies.

  4. Migration to Bootstrap 4 from Bootstrap 3.

  5. Brand-new Events API on top of AMQ protocol used for extending Peatio (experiment).

  6. Lot of refactoring and improvements after major changes in 1.6.

    The release also includes various fixes and improvements.

Breaking changes

  • #800: Remove «WithdrawDestination» model in favor of RID (recipient ID).

    The patch makes Peatio free out of all bank credentials, bank accounts and other stuff. People should think about Peatio like microservice for wallet management and trading. Applications which use Peatio for these kind of tasks are now able to link withdraw on Peatio to their's own using field called rid (recipient ID). This field is required and must uniquely identify bank account (for cryptocurrency withdraws it must identity wallet address in blockchain).

    The changes to API:

    • GET /api/v2/withdraws/destinations, POST /api/v2/withdraws/destinations: API calls removed.

    • Request formats of GET /api/v2/withdraws, POST /api/v2/withdraws: parameter destination_id replaced with rid.

    • Response formats of GET /api/v2/withdraws, POST /api/v2/withdraws: txid is not exposed as blockhain_txid, destination replaced with rid.

    • Request formats of POST /management_api/v1/withdraws/new: parameter destination_id was removed.

    IMPORTANT: The patch drops table withdraw_destinations. Be sure to backup the data before running migrations. The migration will automatically calculate field rid from Withdraw#bank_account_number (for fiat withdraws) and Withdraw#address (for crypto).

    Also fixes: #799, #772.

    The patch merged to 1.6 and up.

  • #820: Remove Deposit#fund_extra, Deposit#fund_uid and usages.

    The patch removes useless fields from deposit: fund_extra, fund_uid. Be sure to backup your data in case you need these fields.

  • #816: Remove Withdraw#sn and all usages.

    The patch removed useless withdraw model fields: sn. Be sure to backup this field in case you need the values.

  • #829: Replace PaymentTransaction in favor of Deposit.

    The patch drops PaymentTransaction model in favor of Deposit which simplifies the code a lot.

    We also improved database indices for deposits.

    The breaking changes include:

    • Response format of GET /api/v2/deposits, GET /api/v2/deposit: done_at is now exposed as completed_at.

    • Response format of POST /management_api/v1/deposits, POST /management_api/v1/deposits/get, POST /management_api/v1/deposits/new, PUT /management_api/v1/deposits/state: added blockchain_confirmations to response.

  • #850: Remove mailing stuff from Peatio.

    The patch removes mailers, views, gems, variables and documentation related to mailing. Now Peatio will not send any emails. It means you will need to implement your own mailing system using upcoming Peatio Events API. For example, you can send mail «Your deposit successfully accepted» when your application received event from Peatio (via AMQP) and deposit payload has status «accepted». This is very flexible way of extending Peatio with any amount of functionality. If you really need mails stay on 1.6.

  • #881: Embed «DepositChannel» in «Currency».

    The patch migrates config/deposit_channels.yml to database layer.

    The migration steps include:

    1. Rename config/deposit_channels.yml to config/deposit_channels.old.yml.

    2. Execute bundle exec rake db:migrate.

    The patch adds Currency#deposit_confirmations which defines how many confirmations in blockchain transaction must receive to be accepted on Peatio.

  • #884: Embed «WithdrawChannel» in «Currency».

    The patch migrates config/withdraw_channels.yml to database layer.

    1. Rename config/withdraw_channels.yml to config/withdraw_channels.old.yml.

    2. Execute bundle exec rake db:migrate.

    The patch adds Currency#withdraw_fee which defined fixed fee for withdraw.

New features

  • #781: Ability to manage market pairs using admin panel.

    The patch adds ability to manage market pairs using admin panel (/admin/markets). You can create new markets, edit trading fees, change the order of markets, etc.

  • #828: Migration to Bootstrap 4.

    The patch migrates from Bootstrap 3 to Bootstrap 4 improving user experience in both cabinet and admin panel.

  • #825: Ability to manage currencies using admin panel.

    The patch adds ability to manage currencies using admin panel (/admin/currencies). You can create new currencies, edit API settings, change symbols, etc.

  • #826: Add support for multiple fiat currencies.

    The patch finally adds support for multiple fiat currencies. You can add currency in admin panel, create market pair for it, deposit some money and start trading.

    New variable has been added: DISPLAY_CURRENCY. This variable defines currency which is used to display amount of other currencies. Check more about it in config/application.yml.

  • #914: Event API based on AMQP used for extending Peatio (experiment).

    This feature allows other applications to extend Peatio functionality (like business logic) by relying on AMQP (RabbitMQ) standard.

    Checkout the specification docs/specs/event_api.md for complete details.


  • #782: Improved English phrasing in README.

    The patch updated README with fixes and improvements.

  • #783: Fix typos and update details for Ubuntu installation instruction.

    The patch updates docs for Ubuntu installation. IMPORTANT: We don't support this type of installation, we support Docker type of installation only.

  • #762: Add gem «bullet».

    The patch adds gem bullet to development dependencies which helps to resolve N+1 problems and optimize SQL.

  • #808: Suppress warnings from figaro.

    The patch tweaks config/application.yml so figaro doesn't output warnings anymore.

  • #815: Set member API version to match Peatio version.

    The patch sets version in API docs the same as version of Peatio.

  • #751: Hide «unsecure protocol» warning from Bundler.

  • #832: Ignore .yarnrc and .cache in Git.

  • #833: Add ability to set UID and GID as Docker build args.

    Merged to 1.6 and up.

  • #794: Remove trading UI leftovers in Peatio.

    The patch removes lot of translations, assets & views which was still in Peatio ever after extraction of trading UI.

  • #844: Remove Swagger UI leftovers.

    The patch removes all custom Swagger UI dependencies.

  • #836: Remove gem Slim.

  • #860: Finish Capybara tests in features/admin/withdraw_spec.rb.

    The patch completes pending acceptance tests for admin withdraw page.

  • #885: Gemfile optimization: eventmachine & em-websocket.

    The patch changes Gemfile to require the gems listed above only when they are needed (in lib/daemons/websocket_api.rb).

  • #906: Extend type of fee columns to match type of amount columns in database (DECIMAL(32, 16)).

    The patch ensures database can store fee equal to 100% of amount.

  • #896: Update omniauth-barong version (compatibility with Barong 1.7).


  • #791: Fix «NoMethodError: undefined method 'fetch' for #<OpenSSL::PKey::RSA>».

    The patch fixes error related to parsing of config/management_api_v1.yml at config/initializers/jwt.rb. Merged to 1.6 and up.

  • #709: Add missing translation for «ORDER FULFILLED» (account version reason) and fix spelling.

    The patch adds missing locale entries.

  • #769: Add missing step for installation with PostgreSQL.

    The patch updated docs for installation with PostgreSQL.

  • #811: PUSHER_CLIENT_ENCRYPTED is ignored when value is «false».

    The value of variable PUSHER_CLIENT_ENCRYPTED was ignored if set to false. Merged to 1.5 and up.

  • #807: Page should not be reloaded after creation of withdraw.

    The patch prevents page from being reloaded after withdraw cancelation. Peatio must be correctly configured with Slanger (or Pusher) so the changes will be reflected without reload of page.

  • #806: Get rid of errors «Undefined method may_*?» for deposits and withdraws.

    The patch fixes bugs which popped out after refactoring of deposit & withdraw states.

    Merged to 1.6 and up.

  • #796: Fix failing specs with seed 59081 & 39808 (Capybara + DatabaseCleaner issue).

    The patch updates spec configuration for better compatibility between DatabaseCleaner & Capybara.

  • #797: Fixes & specs for updated BitGo API (address creation issue).

    The patch updates existing CoinAPI::BitGo#create_address! to be compatible with unexpectedly updated BitGo API and adds support for async address generation.

  • #839: Add missing Private::DepositsController#destroy action (couldn't cancel deposit).

    Merged to 1.5 and up.

  • #856: Enqueue new matching engine after market create.

    The patch fixes issues:

    • List of orders is not displayed in trading UI for new markets.

    • Cancellation of orders doesn't work on markets added from admin panel.

    Merged to 1.6 and up.

  • #870: Fix typos in README.

  • #874: Don't create payment addresses for fiat accounts. Additional checks for address generation.

    The patch adds additional checks which ensure payment address will not be generated for fiat accounts.

    Previously there was a way to enqueue generation of payment address for fiat currency. This resulted in infinite error at deposit address generation worker. Now this is finally fixes and patched.

    Merged to 1.5 and up.

  • #880: Various fixes after migration to BS4.

  • #892: Fix error in OrderBook entity caused by class loading order bug in Grape.

    The patch fixes overlapping between constants Order and APIv2::Entities::Order.

    Merged to 1.5 and up.

  • #879: Store fee in Order#fee.

    The patch embeds field fee in table orders. Previously the value was stored only in market and retrieved from it every time. This was a critical bug which prevented orders from showing real fee value at the moment when order was executed (it displayed only the latest value retrieved from market).

    Merged to 1.6 and up.