-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathassets.go
31 lines (23 loc) · 1.02 KB
/
assets.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package gokraken
import "github.com/danmrichards/gokraken/asset"
const (
// AssetsResource is the API resource for the Kraken API asset info.
AssetsResource = "Assets"
// AssetInfo is the info level for asset.
AssetInfo AssetsInfoLevel = "info"
// AssetCurrency is the asset class for asset.
AssetCurrency AssetsClass = "currency"
)
// AssetsInfoLevel represents an info level for an asset request.
type AssetsInfoLevel string
// AssetsClass represents an asset class for an asset request.
type AssetsClass string
// AssetsResponse represents an array of asset names and their info.
type AssetsResponse map[asset.Currency]Asset
// Asset represents a Kraken asset.
type Asset struct {
AltName string `json:"altname"` // Alternate name.
AClass AssetsClass `json:"aclass"` // Asset class.
Decimals int `json:"decimals"` // Scaling decimal places for record keeping.
DisplayDecimals int `json:"display_decimals"` // Scaling decimal places for output display.
}