Skip to content

Commit c7fc37b

Browse files
committed
Improve Clio server_info reference
1 parent e637346 commit c7fc37b

File tree

1 file changed

+14
-7
lines changed

1 file changed

+14
-7
lines changed

docs/references/http-websocket-apis/public-api-methods/clio-methods/server_info-clio.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,13 @@ labels:
77
- Core Server
88
---
99
# server_info
10+
1011
[[Source]](https://github.com/XRPLF/clio/blob/master/src/rpc/handlers/ServerInfo.cpp "Source")
1112

1213
The `server_info` command asks the [Clio server](../../../../concepts/networks-and-servers/the-clio-server.md) for a human-readable version of various information about the Clio server being queried. For `rippled` servers, see [`server_info` (`rippled`)](../server-info-methods/server_info.md) instead. {% badge href="https://github.com/XRPLF/clio/releases/tag/1.0.0" %}New in: Clio v1.0.0{% /badge %}
1314

14-
1515
## Request Format
16+
1617
An example of the request format:
1718

1819
{% tabs %}
@@ -569,12 +570,7 @@ The `info` object may have some arrangement of the following fields:
569570
|:------------------------------------|:----------------|:---------------------|
570571
| `complete_ledgers` | String | Range expression indicating the sequence numbers of the ledger versions the local `rippled` has in its database. This may be a disjoint sequence such as `24900901-24900984,24901116-24901158`. If the server does not have any complete ledgers (for example, it recently started syncing with the network), this is the string `empty`. |
571572
| `counters` | Object | _(May be omitted)_ Stats on API calls handled since server startup. This is present only if the client connects to the Clio server over `localhost`.
572-
| `rpc` | Object | _(May be omitted)_ Stats on each API call handled by the Clio server since startup. Since this is nested within the `counters` object, this is also present only if the client connects to the Clio server over `localhost`. |
573-
| `rpc.*.started` | Number | Number of API calls of this type that the Clio server has started processing since startup. |
574-
| `rpc.*.finished` | Number | Number of API calls of this type that the Clio server has finished processing since startup. |
575-
| `rpc.*.errored` | Number | Number of API calls of this type that have resulted in some sort of error since startup. |
576-
| `rpc.*.forwarded` | Number | Number of API calls of this type that the Clio server has forwarded to a `rippled` P2P server since startup. |
577-
| `rpc.*.duration_us` | Number | The total number of microseconds spent processing API calls of this type since startup. |
573+
| `rpc` | Object | _(May be omitted)_ Stats on each API call handled by the Clio server since startup. Since this is nested within the `counters` object, this is also present only if the client connects to the Clio server over `localhost`. The rpc object is a map of API method names to [API Stats Objects](#api-stats-objects). |
578574
| `subscriptions` | Object | _(May be omitted)_ Number of current subscribers for each stream type. Since this is nested within the `counters` object, this is also present only if the client connects to the Clio server over `localhost`. |
579575
| `subscriptions.ledger` | | |
580576
| `subscriptions.transactions` | | |
@@ -619,6 +615,17 @@ The `info` object may have some arrangement of the following fields:
619615
| `validated` | Boolean | When true, this indicates that the response uses a ledger version that has been validated by consensus. In Clio, this is always true as Clio stores and returns validated ledger data. If a request was forwarded to `rippled` and the server returns current data, a missing or false value indicates that this ledger's data is not final. |
620616
| `status` | String | Returns the status of the API request: `success` when the request completes successfully. |
621617

618+
### API Stats Objects
619+
620+
An API Stats object provides key metrics for every API call handled by the Clio server since startup. It includes the following fields:
621+
622+
| `Field` | Type | Description |
623+
| :------------ | :----- | :----------------------------------------------------------------------------------------------------------- |
624+
| `started` | Number | Number of API calls of this type that the Clio server has started processing since startup. |
625+
| `finished` | Number | Number of API calls of this type that the Clio server has finished processing since startup. |
626+
| `errored` | Number | Number of API calls of this type that have resulted in some sort of error since startup. |
627+
| `forwarded` | Number | Number of API calls of this type that the Clio server has forwarded to a `rippled` P2P server since startup. |
628+
| `duration_us` | Number | The total number of microseconds spent processing API calls of this type since startup. |
622629

623630
## Possible Errors
624631

0 commit comments

Comments
 (0)