Skip to content
Docs
Esc
↑↓navigate↵open⌘Jpreview

Trading by window.

Answers the pool’s trading summed over each window, shortest first. A window longer than the pool’s life is unavailable.

GET/v1/pools/{chain}/{protocol}/{variant}/{deployment}/{poolKey}/stats
Path parameters
chainstringrequired

The pool's chain by its slug, for example base.

Allowed:solanaethereumbaserobinhoodbscarchyperevm
protocolstringrequired

The protocol, for example uniswap.

min length 1 · max length 32
variantstringrequired

The protocol version or pool type, for example v3.

min length 1 · max length 32
deploymentstringrequired

The deployment of the variant on the chain.

min length 1 · max length 64
poolKeystringrequired

The pool's address, id or account within its deployment.

min length 1 · max length 96
Responses
200

Success.

windowsobject[]required
min items 3 · max items 3
Show properties
Array of object
windowstringrequired
Allowed:5m1h24h
priceChangePercentPercentValuerequired

A percent (5 means 5%), measured.

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
swapsobjectrequired

A value with its state: exact, stale (older than its freshness bound), provisional (one source), disputed (two sources disagree) or unavailable (no value, with a reason).

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueobjectrequired
Show properties
totalintegerrequired

A count of items.

min 0 · max 9007199254740991
buysintegerrequired

A count of items.

min 0 · max 9007199254740991
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueobjectrequired
Show properties
totalintegerrequired

A count of items.

min 0 · max 9007199254740991
buysintegerrequired

A count of items.

min 0 · max 9007199254740991
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueobjectrequired
Show properties
totalintegerrequired

A count of items.

min 0 · max 9007199254740991
buysintegerrequired

A count of items.

min 0 · max 9007199254740991
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
volumeUsdUsdValuerequired

A US-dollar figure, measured.

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
netFlowUsdUsdValuerequired

What buys took out of the pool less what sells put in, in US dollars: positive when buyers led.

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
volatilityPercentPercentValuerequired

A percent (5 means 5%), measured.

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
activeTvlUsdUsdValuerequired

The liquidity within 2% of the price, in US dollars.

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueDecimalrequired

An exact decimal number as text; never a binary float (IEEE 754).

max length 80 · matches ^-?[0-9]+(?:\.[0-9]+)?$
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
traders24hobjectrequired

Distinct traders of the last day, as a range (an exact count has low equal to high); unavailable where the source does not say who swapped.

Show properties
One of:
object
statusstringrequired

Current and from a trusted read.

valueobjectrequired
Show properties
lowintegerrequired

A count of items.

min 0 · max 9007199254740991
highintegerrequired

A count of items.

min 0 · max 9007199254740991
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Older than its freshness bound; shown with its age.

valueobjectrequired
Show properties
lowintegerrequired

A count of items.

min 0 · max 9007199254740991
highintegerrequired

A count of items.

min 0 · max 9007199254740991
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

Resting on one source, not yet confirmed.

valueobjectrequired
Show properties
lowintegerrequired

A count of items.

min 0 · max 9007199254740991
highintegerrequired

A count of items.

min 0 · max 9007199254740991
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
sourcestringrequired

The source the value rests on.

min length 1 · max length 40
object
statusstringrequired

Two sources disagree; both values are given.

valuesany[]required

The two values that disagree, each with its source.

min items 2 · max items 2
observedAtintegerrequired

When the value was read, in Unix seconds.

min 0 · max 9007199254740991
object
statusstringrequired

No value; never shown as zero.

reasonstringrequired

Why there is no value; it is never zero.

min length 1 · max length 200
asOfintegerrequired

A point in time: Unix time in whole seconds, UTC.

min 0 · max 9007199254740991
400

Invalid input; errors names the fields.

typestring<uri-reference>required

A URI reference naming the problem type; about:blank when only the status says it.

max length 200
titlestringrequired

A short summary of the problem type, the same for every occurrence.

max length 200
statusintegerrequired

The HTTP status code of this answer.

min 400 · max 599
detailstring

What went wrong this time, for a person to read.

max length 500
instancestring<uri-reference>

A URI reference of this occurrence, quoted to support.

max length 200
codestringrequired

What a client branches on, stable across releases.

matches ^[a-z][a-z0-9_]{0,63}$
retryAfterSecondsinteger

Seconds to wait before asking again, on 429 and 503; the Retry-After header agrees.

max 9007199254740991
errorsobject[]

The fields that were refused, on 400.

max items 50
Show properties
Array of object
fieldstringrequired

The refused field, as a JSON path into the request.

max length 200
codestringrequired

Why it was refused, stable across releases.

max length 64
messagestring

The reason, for a person to read.

max length 200
404

Not found, or not yours.

typestring<uri-reference>required

A URI reference naming the problem type; about:blank when only the status says it.

max length 200
titlestringrequired

A short summary of the problem type, the same for every occurrence.

max length 200
statusintegerrequired

The HTTP status code of this answer.

min 400 · max 599
detailstring

What went wrong this time, for a person to read.

max length 500
instancestring<uri-reference>

A URI reference of this occurrence, quoted to support.

max length 200
codestringrequired

What a client branches on, stable across releases.

matches ^[a-z][a-z0-9_]{0,63}$
retryAfterSecondsinteger

Seconds to wait before asking again, on 429 and 503; the Retry-After header agrees.

max 9007199254740991
errorsobject[]

The fields that were refused, on 400.

max items 50
Show properties
Array of object
fieldstringrequired

The refused field, as a JSON path into the request.

max length 200
codestringrequired

Why it was refused, stable across releases.

max length 64
messagestring

The reason, for a person to read.

max length 200
429

Too many requests; retryAfterSeconds says when to ask again.

typestring<uri-reference>required

A URI reference naming the problem type; about:blank when only the status says it.

max length 200
titlestringrequired

A short summary of the problem type, the same for every occurrence.

max length 200
statusintegerrequired

The HTTP status code of this answer.

min 400 · max 599
detailstring

What went wrong this time, for a person to read.

max length 500
instancestring<uri-reference>

A URI reference of this occurrence, quoted to support.

max length 200
codestringrequired

What a client branches on, stable across releases.

matches ^[a-z][a-z0-9_]{0,63}$
retryAfterSecondsinteger

Seconds to wait before asking again, on 429 and 503; the Retry-After header agrees.

max 9007199254740991
errorsobject[]

The fields that were refused, on 400.

max items 50
Show properties
Array of object
fieldstringrequired

The refused field, as a JSON path into the request.

max length 200
codestringrequired

Why it was refused, stable across releases.

max length 64
messagestring

The reason, for a person to read.

max length 200
500

Server error.

typestring<uri-reference>required

A URI reference naming the problem type; about:blank when only the status says it.

max length 200
titlestringrequired

A short summary of the problem type, the same for every occurrence.

max length 200
statusintegerrequired

The HTTP status code of this answer.

min 400 · max 599
detailstring

What went wrong this time, for a person to read.

max length 500
instancestring<uri-reference>

A URI reference of this occurrence, quoted to support.

max length 200
codestringrequired

What a client branches on, stable across releases.

matches ^[a-z][a-z0-9_]{0,63}$
retryAfterSecondsinteger

Seconds to wait before asking again, on 429 and 503; the Retry-After header agrees.

max 9007199254740991
errorsobject[]

The fields that were refused, on 400.

max items 50
Show properties
Array of object
fieldstringrequired

The refused field, as a JSON path into the request.

max length 200
codestringrequired

Why it was refused, stable across releases.

max length 64
messagestring

The reason, for a person to read.

max length 200
Try it
Server
Parameters
Request
curl -X GET 'https://api.lpinvictus.com/v1/pools/base/string/string/string/string/stats' \
  -H 'Accept: application/json'
Response
{
  "windows": [
    {
      "window": "5m",
      "priceChangePercent": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      },
      "swaps": {
        "status": "exact",
        "value": {
          "total": 0,
          "buys": 0
        },
        "observedAt": 1793145600
      },
      "volumeUsd": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      },
      "netFlowUsd": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      }
    },
    {
      "window": "5m",
      "priceChangePercent": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      },
      "swaps": {
        "status": "exact",
        "value": {
          "total": 0,
          "buys": 0
        },
        "observedAt": 1793145600
      },
      "volumeUsd": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      },
      "netFlowUsd": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      }
    },
    {
      "window": "5m",
      "priceChangePercent": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      },
      "swaps": {
        "status": "exact",
        "value": {
          "total": 0,
          "buys": 0
        },
        "observedAt": 1793145600
      },
      "volumeUsd": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      },
      "netFlowUsd": {
        "status": "exact",
        "value": "1234.56",
        "observedAt": 1793145600
      }
    }
  ],
  "volatilityPercent": {
    "status": "exact",
    "value": "1234.56",
    "observedAt": 1793145600
  },
  "activeTvlUsd": {
    "status": "exact",
    "value": "1234.56",
    "observedAt": 1793145600
  },
  "traders24h": {
    "status": "exact",
    "value": {
      "low": 0,
      "high": 0
    },
    "observedAt": 1793145600
  },
  "asOf": 1793145600
}

Was this page helpful?