get

/v4/analytics/positions/by-identifier/{chainId}/{identifier}

Get positions by opportunity identifier

Fetch the latest position for every user in a given opportunity.

Response:
- data[indexingId]: Wrapped positions keyed by indexingId. Each positionGroup carries shared metadata (protocol, action, stateType, globalStates, tokens) and a positions map keyed by positionId. Each position entry carries its user field; multiple users may share the same indexingId positionGroup.
- latest is reported as of the indexing checkpoint: its (blockNumber, blockTimestamp) are advanced to how far indexing has completed (state unchanged through there), never beyond it — so the state is never presented as more current than what's indexed.
- globalStates (present when enrichment runs): at the positionGroup level it holds series descriptors only (type, indexingId). The value applied to a snapshot lives on that snapshot's own globalStates[key] = { blockTimestamp, value } — the series row at-or-before the snapshot's timestamp (carry-forward) — so each snapshot is self-describing.
- pagination.positionCount: Total number of position entries returned
- pagination.recipientsCount: Number of distinct user addresses across all positions

Examples:
- Latest positions: GET /v4/analytics/positions/by-identifier/1/0xPoolAddress

Path parameters

chainIdnumber | string
required
identifierstring
required

Query parameters

enrichPositionsboolean
required
default: false

Responses

200
Response for status 200
Schema
object
dataobject
required
Wrapped positions keyed by indexingId
paginationobject
required
positionCountnumber
required
Total number of position entries returned
recipientsCountnumber
required
Number of distinct user addresses in the response
Example
{
  "data": {},
  "pagination": {
    "positionCount": 0,
    "recipientsCount": 0
  }
}
get
https://analytics.merkl.xyz/v4/analytics/positions/by-identifier/{chainId}/{identifier}
Merkl Analytics API
curl -X GET "https://analytics.merkl.xyz/v4/analytics/positions/by-identifier/{chainId}/{identifier}"
Fill the required path parameters chainId, identifier to send.