Ripple Charts API
The Ripple Charts API, also known as the Data API, provides past and present information about the state of the Ripple Network through an HTTP API, with additional information calculated for analysis purposes. The Ripple Charts API is used as a data source by applications such as Ripple Charts and ripple.com.
(The API does not follow the conventions of a REST API, but you can use an HTTP client to access it in the same way you would access a REST API.)
Architecture
The Ripple Charts API is a Node.js application that uses HBase as its datastore.
Components
Ledger Importer
The ledger importer imports ledgers from the Ripple Network into the data store. The process is set up to import continously in real time as ledgers are validated, and also import historical ledgers.
Data Store
The data store uses HBase to store ledgers. This is not as flexible as the old CouchDB data store, but it scales much better.
API Server
Accessing the historical data is not done by querying the database directly but through a node.js API server. The server takes requests in the form of JSON data, interprets it into one or several database queries, processes the data as necessary and returns the results.
Setup
Setup for the Ripple Charts API on top of HBase is not currently documented.
Start API Service
The following command starts the API service:
grunt watch
(This requires read permissions to the database. Write permissions are not necessary.)
Start Ledger Importer
The following command starts the ledger importer service:
node db/importer
Alternatively, you can use the experimental websocket-based importer:
node db/import
(Either way, you need write permission to the database.)
Formatting Conventions
Requests to the Charts API generally take the same format:
- Use the HTTP POST method
- The URL defines the API method to use
- All parameters are in the request body.
- The
Content-Typeheader has the valueapplication/json. Caution: If you omit or specify the wrong Content-Type, the API may respond with misleading error messages such as{"error":"Please specify an account"}
Dates and Times
The Ripple Charts API uses Moment.js to parse strings, and therefore accepts any date-time string that Moment.js recognizes as input.
The Ripple Charts API always outputs dates in UTC, in the following format:
YYYY-MM-DDThh-mm-ss+00:00
For example:
2015-03-01T00:00:00+00:00
(midnight exactly on March 3, 2015 UTC)
Currency Objects
Many methods define a currency as an object with the following fields:
| Field | Value | Description |
|---|---|---|
| currency | String | Three-letter ISO 4217 Currency Code string, or a 160-bit hex string according to Ripple's internal Currency format. |
| issuer | String | Account address of the counterparty holding the currency. Usually an issuing gateway in the Ripple network. Omitted or null for XRP. |
Some methods describe an amount of currency, for example a quantity traded in a currency exchange. In JSON format, this takes the form of a nested JSON object with the following fields:
| Field | Value | Description |
|---|---|---|
| currency | String | Same as the currency field of a currency object. |
| issuer | String | Same as the issuer field of a currency object. |
| amount | Number | The quantity of the currency exchanged. |
In CSV or array format, a currency amount is specified as three separate attributes that correspond to the fields of the JSON object. The name of the fields depends on the context: for example, the baseAmount column is equivalent to the amount field of the base currency amount object.
Warning: JavaScript's native number type does not support rippled's full range of precision. When dealing with very large or very small numbers, the amount values returned by the Charts API lose precision.
Response Formats
Several methods provide a format parameter, which lets you request results in one of three formats:
csv- Comma-separated-values table. The first line is a row of column headers, and each subsequent line represents one result or interval, with its attributes in columns. The columns are separated by comma (,) characters.json- The request contains some top-level information at the top level, and aresultsarray. Each member of theresultsarray is a JSON object with attributes and values that represent one result or interval.- Two-dimensional array format - If neither
csvnorjsonis specified, the API returns an array of JSON arrays, in a format that resembles CSV. The first member of the top-level array is an array of table headers, and each subsequent member is a nested array representing one result or interval, with its members corresponding to the attribute names in the header row.
API Method Reference
To use a method in this document, append the path for that method to the hostname of the Charts API instance you want to use. Ripple Labs runs a public instance of the Ripple Charts API with full data, available at:
https://api.ripplecharts.com
The API provides the following methods:
- Accounts Created -
POST /api/accounts_created - Exchange Rates -
POST /api/exchange_rates - Issuer Capitalization -
POST /api/issuer_capitalization - Market Traders -
POST /api/market_traders - Offers Exercised -
POST /api/offers_exercised - Top Markets -
POST /api/top_markets
As of August 19, 2015, the following methods are no longer available: Account Transaction Stats, Account Transactions, Account Offers Exercised, Ledgers Closed, Offers, Total Network Value, Total Value Sent, Transaction Stats, and Value Sent.
Accounts Created
Retrieve information about the creation of new Ripple accounts.
Request Format
The request includes the following body parameters:
| Field | Value | Description |
|---|---|---|
| startTime | String (Date-Time) | Retrieve information starting at this time. |
| endTime | String (Date-Time) | Retrieve information ending at this time. |
| timeIncrement | String | (Optional) Divide results into intervals of the specified length: week, day, hour. The value all collapses the results into just one interval. Defaults to all. |
| descending | Boolean | (Optional) If true, return results in descending order. Defaults to false. |
| reduce | Boolean | (Optional) If false, include accounts individually instead of collapsing them into results over time. Ignored if timeIncrement is provided. Defaults to true. |
| limit | Number | (Optional) If reduce is false, this value defines the maximum number of transactions to return in one response. Use with offset to paginate results. Defaults to 500. |
| offset | Number | (Optional) If reduce is false, this value defines a number of transactions to skip before returning results. Use with limit to paginate results. Defaults to 0. |
| format | String | (Optional) The Response Format to use: csv or json. If omitted, defaults to a CSV-like JSON array format. |
Response Format
The format of the response depends on the format and reduce parameters from the request. See Response Format for details. Examples of successful responses:
If results are reduced (the default), then each result represents an interval of time, with the following attributes, in order:
| Field | Type | Description |
|---|---|---|
| time | String (Date-Time) | The time this interval begins |
| count | Number | The number of accounts created (successfully funded with the XRP reserve) in this interval. |
If the results are not reduced (the request specified reduce as false and did not include a timeIncrement), then each result represents an individual account that was created, with the following attributes:
| Field | Type | Description |
|---|---|---|
| time | String (Date-Time) | The time this account was created, as defined by the close time of the ledger containing the transaction that created it. |
| account | String (Ripple Address) | The address of the newly-created account. |
| txHash | String (Transaction Hash) | The identifying hash of the transaction that created this account. |
| ledgerIndex | Number | The sequence number of the ledger when this account was created. |
Exchange Rates
Retrieve information about the exchange rates between one or more pairs of currency, based on trading activity in the network.
Request Format
The request includes the following body parameters:
| Field | Value | Description |
|---|---|---|
| pairs | Array | (Optional) Array of currency pairs to compare. Each member of the array should be an object with a base field and a counter field, whose values are Currency Objects. If live is true, each pair can also include a depth field specifying how deep to dig into the order book to calculate the live rate. |
| base | Object (Currency Object) | (Optional) One currency to compare. Ignored if pairs provided. |
| counter | Object (Currency Object) | (Optional) The other currency to compare. Ignored if pairs provided. |
| depth | Number | (Optional) Ignored unless live is true. Ignored if pairs is provided. Retrieve exchange rates for this amount of the counter currency. Provides a more accurate picture when the best orders in the market do not have enough volume to fully satisfy an exchange. Defaults to 0 (use the first bid and ask only). |
| range | String | (Optional) Time period over which the exchange rate is calculated: year, month, week, day, or hour. Defaults to day. Ignored if live is true. |
| last | Boolean | (Optional) If true, only return the price from the most recent exchange, without calculating VWAP. Use for a faster response. Defaults to false. |
| live | Boolean | (Optional) If true, retrieve the current price directly from the Ripple network instead, as the midpoint between weighted average of the bid and asks up to the depth specified . Otherwise, use historical data from the past range amount of time. Defaults to false. |
You must provide either pairs or both base and counter.
Response Format
Examples of successful responses:
A successful result contains a JSON array. Each member of the array represents a currency pair, as an object with the following fields:
| Field | Type | Description |
|---|---|---|
| base | Object (Currency Object) | The base currency specified for this pair, possibly including a name field with the Ripple Name for the issuer address. |
| counter | Object (Currency Object) | The counter currency specified for this pair, possibly including a name field with the Ripple Name for the issuer address. |
| depth | Number | (May be omitted) The depth to search for this currency pair, if provided. |
| rate | Number | (May be omitted) The amount of the counter currency that you can purchase with 1 unit of the base currency. By default, this is calculated volume-weighted average price for all exchanges executed during the range period from the request. If the request specified live as true, this is instead calculated as the midpoint between the weighted average of current bid and ask rates in the network up to the specified depth. Omitted if the request specified last as true. |
| last | Number | (May be omitted) The rate of the single most recent exchange to take place. |
If no exchanges are found for a currency pair from the request, that pair is omitted from the response.
Issuer Capitalization
Retrieve the total capitalization (outstanding balance) of specified currency issuers over time.
Request Format
The request includes the following body parameters:
| Field | Value | Description |
|---|---|---|
| currencies | Array of Currency Objects) | A list of currency/issuer pairs to look up. |
| startTime | String (Date-Time) | Retrieve information starting at this time. |
| endTime | String (Date-Time) | Retrieve information ending at this time. |
| timeIncrement | String | (Optional) Divide results into intervals of the specified length: year, month, day, hour, minute, or second. The value all collapses the results into just one interval. Defaults to all. Ignored if reduce is false. |
Response Format
An example of a successful response:
[
{
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B",
"name": "Bitstamp",
"hotwallets": [
"rrpNnNLKrartuEqfJGpqyDwPj1AFPg9vn1",
"rGFuMiw48HdbnrUbkRYuitXTmfrDBNTCnX"
],
"results": [
[
"2014-01-01T00:00:00+00:00",
2182532.512563024
],
[
"2014-02-01T00:00:00+00:00",
1672428.6072806932
],
[
"2014-03-01T00:00:00+00:00",
1475205.4287192414
],
[
"2014-04-01T00:00:00+00:00",
1475129.7523240475
],
[
"2014-05-01T00:00:00+00:00",
1641170.5998081048
],
[
"2014-06-01T00:00:00+00:00",
2823512.0227728607
],
[
"2014-07-01T00:00:00+00:00",
2181718.7345464956
],
[
"2014-08-01T00:00:00+00:00",
2150290.1475041625
],
[
"2014-09-01T00:00:00+00:00",
1370978.1335410434
],
[
"2014-10-01T00:00:00+00:00",
1386720.726560316
],
[
"2014-11-01T00:00:00+00:00",
1171158.4417431813
],
[
"2014-12-01T00:00:00+00:00",
1651264.0460538066
],
[
"2015-01-01T00:00:00+00:00",
2272895.4608580153
]
]
},
{
"currency": "USD",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q",
"name": "SnapSwap",
"hotwallets": [
"ra7JkEzrgeKHdzKgo4EUUVBnxggY4z37kt",
"rQsAshmCjPsxkYnxY9GnmBTAeEUaePDAie",
"rEk9i7G8ac1kUs1mFjtze1qjj9FzGvXAG",
"rsTQ7iwrCik9Ugc3zbpcbo2K3SbAdYJss1",
"rwm98fCBS8tV1YB8CGho8zUPW5J7N41th2",
"rnd8KJ4qeip6FPJvC1fyv82nW2Lm8C8KjQ",
"r5ymZSvtdNgbKVc8ay1Jhmq5f9QgnvEtj"
],
"results": [
[
"2014-01-01T00:00:00+00:00",
308414.17014300067
],
[
"2014-02-01T00:00:00+00:00",
221127.8278553265
],
[
"2014-03-01T00:00:00+00:00",
189103.31201476356
],
[
"2014-04-01T00:00:00+00:00",
166239.66201052035
],
[
"2014-05-01T00:00:00+00:00",
181126.05199917927
],
[
"2014-06-01T00:00:00+00:00",
352360.96199815325
],
[
"2014-07-01T00:00:00+00:00",
406900.8018140941
],
[
"2014-08-01T00:00:00+00:00",
522981.4027866862
],
[
"2014-09-01T00:00:00+00:00",
823727.7361699624
],
[
"2014-10-01T00:00:00+00:00",
1285657.1682029555
],
[
"2014-11-01T00:00:00+00:00",
1162233.7115210893
],
[
"2014-12-01T00:00:00+00:00",
1631690.8946927704
],
[
"2015-01-01T00:00:00+00:00",
3778040.482102244
]
]
}
]
A successful result contains a JSON array of objects representing the issuers from the request. Each member object has the following fields:
| Field | Type | Description |
|---|---|---|
| currency | String | Currency code of the currency described by this record. |
| issuer | String (Ripple Address) | The account address of the gateway issuing this currency. |
| name | String | The name of this gateway, which usually corresponds to the Ripple Name of the account. |
| hotwallets | Array of Ripple Addresses | Hot wallets controlled by this gateway. Assets held by these accounts are not counted towards the capitalization. |
| results | Array of Arrays | The capitalization of the issuer/currency pair as an array of intervals. Each nested array has two values: a String (Date-Time) specifying the beginning of the interval, and a number representing the total units of the currency distributed through the network at the time. |
The list of gateway names and hot wallets is defined by the gateways.json file in the server tree. In the future, this may be expanded to use host-meta.
Market Traders
Return a list of accounts that participated in trading a specified currency exchange.
Request Format
The request includes the following body parameters:
| Field | Value | Description |
|---|---|---|
| base | Object (Currency Object) | (Optional) One of the currencies being exchanged. Required if counter is specified. |
| counter | Object (Currency Object) | (Optional) The other of the currencies being exchanged. Required if base is specified. |
| startTime | String (Date-Time) | (Optional) Retrieve information starting at this time. If omitted, use the period ending at the current time. |
| period | String | (Optional) One of the following values: 3d (three days), 7d (seven days), or 24h (24 hours). Defaults to 24h. |
| transactions | Boolean | (Optional) If true, include individual transactions in the response. Defaults to false. Ignored if format is csv. |
| format | String | (Optional) The Response Format to use: csv or json. If omitted, defaults to a CSV-like JSON array format. |
If both base and counter are omitted, the API combines the results from a hardcoded list of popular markets with XRP as the base currency.
Note: This method does not have an endTime parameter.
Response Format
The format of the response depends on the format and reduce parameters from the request. See Response Format for details. Examples of successful responses:
A successful result contains the following fields:
| Field | Type | Description |
|---|---|---|
| account | String (Account Address) | The account of the trader. |
| buy | Object | Object with baseVolume (volume of base currency bought), counterVolume (volume of counter currency used to buy the base currency), and count (number of buy transactions) fields describing the activity of this account. |
| sell | Object | Object with baseVolume (volume of base currency sold), counterVolume (volume of counter acquired by selling the base currency), and count (number of sell transactions) fields describing the activity of this account. |
| baseVolume | Number | The total amount of the base currency exchanged. |
| counterVolume | Number | The total amount of the counter currency exchanged. |
| count | Number | The number of exchanges this account performed. |
| transactions | Array | (Omitted unless the request specified transactions as true) Array of transactions sent that this account participated in. |
If transactions are included, each transaction is represented as an array with the following fields in order:
| Type | Description |
|---|---|
| String (Date-Time) | The approximate time this transaction occurred. |
| Number | The amount of the counter currency received for each unit of the base spent. |
| Number | The amount of base currency in this transaction. |
| Number | The amount of counter currency in this transaction. |
| String (Ripple Address) | One party to this transaction. |
| String (Ripple Address) | The other party to this transaction. |
| String (Transaction Hash) | The identifying hash for this transaction. (This may be null for very old transactions.) |
| Number | The sequence number of the ledger that included this transaction. |
Offers Exercised
Retrieve information about currency-exchange orders being exercised on the network, for a specific pair of currencies and timeframe.
The request includes the following body parameters:
| Field | Value | Description |
|---|---|---|
| base | Object (Currency Object) | One of the currencies being exchanged. |
| counter | Object (Currency Object) | The other of the currencies being exchanged. |
| startTime | String (Date-Time) | Retrieve information starting at this time. |
| endTime | String (Date-Time) | Retrieve information ending at this time. |
| timeIncrement | String | (Optional) Divide results into intervals of the specified length: year, month, day, hour, minute, or second. The value all collapses the results into just one interval. Defaults to all. |
| timeMultiple | Number | (Optional) Create larger intervals that are this many times the size of the timeIncrement (for example, 15-minute intervals). Defaults to 1. |
| descending | Boolean | (Optional) If true, return results in descending order. Defaults to false. |
| reduce | Boolean | (Optional) If false, include transactions individually instead of collapsing them into results over time. Defaults to true. Ignored if timeIncrement is provided. |
| limit | Number | (Optional) If reduce is false, this value defines the maximum number of transactions to return in one response. Use with offset to paginate results. Defaults to 500. |
| offset | Number | (Optional) If reduce is false, this value defines a number of transactions to skip before returning results. Use with limit to paginate results. Defaults to 0. |
| format | String | (Optional) The Response Format to use: csv or json. If omitted, defaults to a CSV-like JSON array format. |
Response Format
The format of the response depends on the format and reduce parameters from the request. See Response Format for details. Examples of successful responses:
If results are reduced (the default), then each result represents an interval of time, with the following attributes, in order:
| Field | Value | Description |
|---|---|---|
| startTime | String (Date-Time) | The start time of this interval. |
| baseVolume | Number | Total amount of the base currency traded in this interval. |
| counterVolume | Number | Total amount of the counter currency traded in this interval. |
| count | Number | Number of trades in this interval. |
| open | Number | Price of the first trade in this interval. |
| high | Number | Highest price traded in this interval. (Most counter currency received per unit of base currency spent.) |
| low | Number | Lowest price traded in this interval. (Least counter currency received per unit of base currency spent.) |
| close | Number | Price of the last trade in this interval. |
| vwap | Number | Volume weighted average price of trades in this interval. |
| openTime | String (Date-Time) | The time at which the first trade in this interval occurred. |
| closeTime | String (Date-Time) | The time at which the last trade in this interval occurred. |
| partial | Boolean | If true, this row may not include all trades in the interval due to the alignment of the requested time period. For example, a time interval of 1 minute was requested, but the end time for the range was 3:45:30. |
All prices are represented as the amount of the counter currency received for each unit of the base-currency spent.
The time of an exchange is defined as the close time of the ledger that contained the transaction exercising the exchange.
Note: The API omits intervals during which no exchanges occurred. This means that the rows may not be sequential. (They are in order, but with gaps for empty intervals.)
If the results are not reduced (the request used "reduce":false), then each result represents an individual transaction that caused a currency exchange, with the following attributes:
| Field | Value | Description |
|---|---|---|
| time | String (Date-Time) | The time this transaction occurred, as defined by the close time of the ledger that included it. |
| price | Number | The amount of the counter currency received for each unit of the base-currency spent in this trade. |
| baseAmount | Number | Total amount of the base currency spent in this trade. |
| counterAmount | Number | Total amount of the counter currency received in this trade. |
| account | String | The Ripple address of the account providing the base currency. |
| counterparty | String (Ripple Address) | The Ripple address of the account providing the counter currency. |
| tx_hash | String (Transaction Hash) | The identifying hash of the transaction where this transaction occurred. |
| ledgerIndex | Number | The sequence number of the ledger that included this transaction. |
Top Markets
Returns the total trade volume for a selection of the largest currency-exchange markets in the Ripple Network during a given time period.
The total volume is normalized in terms of XRP and then optionally converted to another specified currency.
Request Format
The request includes the following body parameters:
| Field | Value | Description |
|---|---|---|
| startTime | String (Date-Time) | Retrieve information from the interval containing or starting from this time. Defaults to 24 hours before the current time. |
| interval | String | Return results from an interval of this length. |
| exchange | Object (Currency Object) | (Optional) Represent the volume of each market in terms of this currency. Defaults to XRP. |
Response Format
An example of a successful response:
{
"rowkey": "trade_volume|week|20150105000000",
"components": [
{
"base": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"counter": {
"currency": "XRP"
},
"rate": 0.0004093940882798027,
"count": 12818,
"amount": 1058808.8475284327,
"convertedAmount": 1058808.8475284327
},
{
"base": {
"currency": "BTC",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"counter": {
"currency": "XRP"
},
"rate": 0.0000015089406113337684,
"count": 5038,
"amount": 1211.8976720489186,
"convertedAmount": 328802.69694533286
},
{
"base": {
"currency": "CNY",
"issuer": "rnuF96W4SZoCJmbHYBFoJZpR8eCaxNvekK"
},
"counter": {
"currency": "XRP"
},
"rate": 0.002517187670715517,
"count": 5792,
"amount": 1886016.212859644,
"convertedAmount": 306740.69197435805
},
{
"base": {
"currency": "CNY",
"issuer": "razqQKzJRdB4UxFPWf5NEpEG3WMkmwgcXA"
},
"counter": {
"currency": "XRP"
},
"rate": 0.002487380215448072,
"count": 7069,
"amount": 2631245.752126516,
"convertedAmount": 433072.6959400096
},
{
"base": {
"currency": "CNY",
"issuer": "rKiCet8SdvWxPXnAgYarFUXMh1zCPz432Y"
},
"counter": {
"currency": "XRP"
},
"rate": 0.0024999228710402563,
"count": 20660,
"amount": 1318591.835624731,
"convertedAmount": 215936.1429155409
},
{
"base": {
"currency": "USD",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"counter": {
"currency": "XRP"
},
"rate": 0.0003945533232038895,
"count": 33575,
"amount": 1480087.1064381741,
"convertedAmount": 1535759.2393204158
},
{
"base": {
"currency": "EUR",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"counter": {
"currency": "XRP"
},
"rate": 0.00033245421053307723,
"count": 13892,
"amount": 326411.42570749344,
"convertedAmount": 401952.82176561374
},
{
"base": {
"currency": "BTC",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"counter": {
"currency": "XRP"
},
"rate": 0.0000014787515510977754,
"count": 22939,
"amount": 5535.83428387394,
"convertedAmount": 1532602.165544437
},
{
"base": {
"currency": "BTC",
"issuer": "rJHygWcTLVpSXkowott6kzgZU6viQSVYM1"
},
"counter": {
"currency": "XRP"
},
"rate": 0.00002019256666183595,
"count": 4,
"amount": 0.00008287404598700001,
"convertedAmount": 0.0016802294164530685
},
{
"base": {
"currency": "JPY",
"issuer": "rMAz5ZnK73nyNUL4foAvaxdreczCkG3vA6"
},
"counter": {
"currency": "XRP"
},
"rate": 0.048446318835714555,
"count": 11387,
"amount": 90721573.94254778,
"convertedAmount": 766639.7972870923
},
{
"base": {
"currency": "JPY",
"issuer": "r94s8px6kSw1uZ1MV98dhSRTvc6VMPoPcN"
},
"counter": {
"currency": "XRP"
},
"rate": 0.049622732367643606,
"count": 7604,
"amount": 97770194.62368087,
"convertedAmount": 806617.0035207476
},
{
"base": {
"currency": "JPY",
"issuer": "rJRi8WW24gt9X85PHAxfWNPCizMMhqUQwg"
},
"counter": {
"currency": "XRP"
},
"rate": 0.04957853568065961,
"count": 650,
"amount": 21241310.716636248,
"convertedAmount": 175399.8361451728
},
{
"base": {
"currency": "KRW",
"issuer": "rUkMKjQitpgAM5WTGk79xpjT38DEJY283d"
},
"counter": {
"currency": "XRP"
},
"rate": 0.45875087906923134,
"count": 3309,
"amount": 643024533.754439,
"convertedAmount": 573841.8273378739
},
{
"base": {
"currency": "EUR",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"counter": {
"currency": "USD",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"rate": 0.00033245421053307723,
"count": 4408,
"amount": 89233.81725732498,
"convertedAmount": 109885.19953232592
},
{
"base": {
"currency": "BTC",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"counter": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"rate": 0.0000015089406113337684,
"count": 1135,
"amount": 308.8960869071788,
"convertedAmount": 83807.29561038432
},
{
"base": {
"currency": "BTC",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"counter": {
"currency": "USD",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"rate": 0.0000014787515510977754,
"count": 5705,
"amount": 1097.9447905182549,
"convertedAmount": 303967.29333071
},
{
"base": {
"currency": "BTC",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"counter": {
"currency": "BTC",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"rate": 0.0000015089406113337684,
"count": 1855,
"amount": 588.0555584971066,
"convertedAmount": 159546.6828982718
},
{
"base": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"counter": {
"currency": "USD",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"rate": 0.0004093940882798027,
"count": 3623,
"amount": 536607.4024021383,
"convertedAmount": 536607.4024021383
},
{
"base": {
"currency": "CNY",
"issuer": "rnuF96W4SZoCJmbHYBFoJZpR8eCaxNvekK"
},
"counter": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"rate": 0.002517187670715517,
"count": 871,
"amount": 426317.9599118283,
"convertedAmount": 69336.13037513298
},
{
"base": {
"currency": "CNY",
"issuer": "razqQKzJRdB4UxFPWf5NEpEG3WMkmwgcXA"
},
"counter": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"rate": 0.002487380215448072,
"count": 833,
"amount": 415914.584286911,
"convertedAmount": 68454.74245510166
},
{
"base": {
"currency": "JPY",
"issuer": "rMAz5ZnK73nyNUL4foAvaxdreczCkG3vA6"
},
"counter": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"rate": 0.048446318835714555,
"count": 441,
"amount": 2687850.8059423557,
"convertedAmount": 22713.59840285114
},
{
"base": {
"currency": "JPY",
"issuer": "rMAz5ZnK73nyNUL4foAvaxdreczCkG3vA6"
},
"counter": {
"currency": "USD",
"issuer": "rMwjYedjc7qqtKYVLiAccJSmCwih4LnE2q"
},
"rate": 0.048446318835714555,
"count": 5186,
"amount": 27619591.096972037,
"convertedAmount": 233398.48284757807
},
{
"base": {
"currency": "JPY",
"issuer": "rMAz5ZnK73nyNUL4foAvaxdreczCkG3vA6"
},
"counter": {
"currency": "CNY",
"issuer": "rnuF96W4SZoCJmbHYBFoJZpR8eCaxNvekK"
},
"rate": 0.048446318835714555,
"count": 1008,
"amount": 7269403.650447986,
"convertedAmount": 61429.86611439055
},
{
"base": {
"currency": "JPY",
"issuer": "rMAz5ZnK73nyNUL4foAvaxdreczCkG3vA6"
},
"counter": {
"currency": "JPY",
"issuer": "r94s8px6kSw1uZ1MV98dhSRTvc6VMPoPcN"
},
"rate": 0.048446318835714555,
"count": 2852,
"amount": 26542137.8118745,
"convertedAmount": 224293.4978679679
}
],
"count": 172654,
"endTime": "2015-01-12T00:00:00+00:00",
"exchange": {
"currency": "USD",
"issuer": "rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B"
},
"exchangeRate": 0.020233489275945527,
"startTime": "2015-01-05T00:00:00+00:00",
"total": 10009613.959742112
}
A successful result contains the following fields:
| Field | Type | Description |
|---|---|---|
| startTime | Object (Date-Time) | The starting time from the request. |
| endTime | Object (Date-Time) | The ending time from the request. |
| exchange | Object (Currency Object) | The currency from the request that is used to express the volume. |
| exchangeRate | Number | The amount of the exchange currency that can be bought for 1 XRP. |
| total | Number | The total volume traded across all markets, in terms of the exchange currency. |
| count | Number | The total number of trades in all the markets. |
| components | Array | The market volumes of each market in the list of top markets. |
Each member of the components array has the following fields:
| Field | Type | Description |
|---|---|---|
| base | Object (Currency Object) | One of the currencies that defines this market. |
| counter | Object (Currency Object) | The other currency that defines this market. |
| rate | Number | The amount of the exchange currency necessary to buy 1 unit of the base currency. |
| count | Number | The number of trades in this market during the requested time period. |
| amount | Number | Total amount of the base currency traded in this market during the requested time period. |
| convertedAmount | Number | Total amount of currency traded in this market during the requested time period, in terms of the exchange currency. |
Note: If there are no trades in a market during the requested period, the rate is defined as 0.
