Initial commit
This commit is contained in:
66
app/api/v2/entities/public_trade.rb
Normal file
66
app/api/v2/entities/public_trade.rb
Normal file
@@ -0,0 +1,66 @@
|
||||
# encoding: UTF-8
|
||||
# frozen_string_literal: true
|
||||
|
||||
module API
|
||||
module V2
|
||||
module Entities
|
||||
class PublicTrade < Base
|
||||
expose(
|
||||
:id,
|
||||
documentation: {
|
||||
type: String,
|
||||
desc: 'Trade ID.'
|
||||
}
|
||||
)
|
||||
|
||||
expose(
|
||||
:price,
|
||||
documentation: {
|
||||
type: BigDecimal,
|
||||
desc: 'Trade price.'
|
||||
}
|
||||
)
|
||||
|
||||
expose(
|
||||
:amount,
|
||||
documentation: {
|
||||
type: BigDecimal,
|
||||
desc: 'Trade amount.'
|
||||
}
|
||||
)
|
||||
|
||||
expose(
|
||||
:total,
|
||||
documentation: {
|
||||
type: BigDecimal,
|
||||
desc: 'Trade total (Amount * Price).'
|
||||
}
|
||||
)
|
||||
|
||||
expose(
|
||||
:market,
|
||||
documentation: {
|
||||
type: String,
|
||||
desc: 'Trade market id.'
|
||||
}
|
||||
)
|
||||
|
||||
expose(
|
||||
:created_at,
|
||||
documentation: {
|
||||
type: String,
|
||||
desc: 'Trade create time in iso8601 format.'
|
||||
}
|
||||
)
|
||||
|
||||
expose(
|
||||
:taker_type,
|
||||
documentation: {
|
||||
type: String,
|
||||
desc: 'Trade taker order type (sell or buy).'
|
||||
}
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user