Skip to content
Get started

Get analytics for current market state

GET/api/v1/analytics/market/state

Get analytics for current market state

ReturnsExpand Collapse
data: object { assets, borrower_account_active, borrower_active, 3 more }
assets: array of object { asset, lend_interest_paid }
asset: AssetSpec { id, group, group_key }

Provides a unique identifier for an asset for use throughout the Neptune API. IDs are unique across asset domains (contract tokens, native denoms, etc)

id: string
group: "native" or "token"
One of the following:
"native"
"token"
group_key: string
lend_interest_paid: string
borrower_account_active: number
formatuint64
minimum0
borrower_active: number
formatuint64
minimum0
flash_loan_volume_total: string
lender_active: number
formatuint64
minimum0
loans_originated: object { breakdown, total_value }

Analytics for accumulated value of originated loans

breakdown: array of object { asset, value }
asset: AssetSpec { id, group, group_key }

Provides a unique identifier for an asset for use throughout the Neptune API. IDs are unique across asset domains (contract tokens, native denoms, etc)

id: string
group: "native" or "token"
One of the following:
"native"
"token"
group_key: string
value: string or number
One of the following:
string
number
total_value: string or number
One of the following:
string
number
error: unknown

Error data. Guaranteed null for successful response.

status: number

HTTP status. Successful responses are guaranteed to be < 400. Conversely, error responses are guaranteed to be >= 400.

formatuint16
minimum0
maximum65535
status_text: string

HTTP status text

Get analytics for current market state

curl https://api-v2.nept.finance/api/v1/analytics/market/state
{
  "data": {
    "borrower_active": 1000,
    "borrower_account_active": 1200,
    "lender_active": 1300,
    "loans_originated": {
      "total_value": "8.04",
      "breakdown": [
        {
          "asset": {
            "id": "native;inj",
            "group": "native",
            "group_key": "inj"
          },
          "value": "8.04"
        }
      ]
    },
    "flash_loan_volume_total": "13270.54",
    "assets": [
      {
        "asset": {
          "id": "native;inj",
          "group": "native",
          "group_key": "inj"
        },
        "lend_interest_paid": "1853.23"
      }
    ]
  },
  "error": null,
  "status": 200,
  "status_text": "200 OK"
}
{
  "data": null,
  "error": {
    "kind": "internal",
    "scope": "server",
    "message": "An unexpected error occurred"
  },
  "status": 500,
  "status_text": "500 Internal Server Error"
}
Returns Examples
{
  "data": {
    "borrower_active": 1000,
    "borrower_account_active": 1200,
    "lender_active": 1300,
    "loans_originated": {
      "total_value": "8.04",
      "breakdown": [
        {
          "asset": {
            "id": "native;inj",
            "group": "native",
            "group_key": "inj"
          },
          "value": "8.04"
        }
      ]
    },
    "flash_loan_volume_total": "13270.54",
    "assets": [
      {
        "asset": {
          "id": "native;inj",
          "group": "native",
          "group_key": "inj"
        },
        "lend_interest_paid": "1853.23"
      }
    ]
  },
  "error": null,
  "status": 200,
  "status_text": "200 OK"
}
{
  "data": null,
  "error": {
    "kind": "internal",
    "scope": "server",
    "message": "An unexpected error occurred"
  },
  "status": 500,
  "status_text": "500 Internal Server Error"
}