๐Ÿ“ˆStats

This documentation provides details on the API endpoints available for Whirlprivacy.io, focusing on stats-related operations.

GET /stats/global - Global Statistics

Description:

This endpoint retrieves comprehensive global statistics related to the Whirl token.

Parameters:

No parameters are needed for this request.

Response:

{
  "activeUsers": "number",
  "totalTransactions": "number",
  "whirlToken": {
    "price": "number",
    "change": "number"
  }
}

Error Handling:

Error Name
Description

InvalidToken

The provided token is invalid or expired.

ServerError

An internal server error occurred.

Example Code:

GET /stats/tvl - Total Value Locked (TVL)

Description:

This endpoint retrieves the Total Value Locked (TVL) statistics, aggregated by a specified granularity.

Parameters:

Parameter
Type
Description

granularity

integer

The granularity level for data aggregation (e.g., 1 for daily).

Response:

Error Handling:

Error Name
Description

InvalidRequest

The request parameters are invalid.

ServerError

An internal server error occurred.

Example Code:

GET /stats/vol - Trading Volume

Description:

This endpoint retrieves trading volume statistics, broken down by the same granularity as specified in the request.

Parameters:

Parameter
Type
Description

granularity

integer

The granularity level for data aggregation (e.g., 1 for daily).

Response:

Error Handling:

Error Name
Description

InvalidRequest

The request parameters are invalid.

ServerError

An internal server error occurred.

Example Code:

GET /stats/tokens - Token Data

Description:

This endpoint retrieves detailed data about the Whirl token and other currencies.

Parameters:

No parameters are needed for this request.

Response:

Error Handling:

Error Name
Description

InvalidToken

The provided token is invalid or expired.

ServerError

An internal server error occurred.

Example Code:

Last updated