Skip to main content
GET
/
v1
/
aggregations
/
{aggregation_id}
Get aggregation
curl --request GET \
  --url https://api.privy.io/v1/aggregations/{aggregation_id} \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'privy-app-id: <privy-app-id>'
{
  "name": "<string>",
  "method": "eth_signTransaction",
  "metric": {
    "field": "<string>",
    "field_source": "<string>",
    "function": "sum",
    "abi": [
      {
        "type": "function",
        "name": "<string>",
        "inputs": [
          {
            "type": "<string>",
            "name": "<string>",
            "components": [
              {}
            ],
            "indexed": true,
            "internalType": "<string>"
          }
        ],
        "outputs": [
          {
            "type": "<string>",
            "name": "<string>",
            "components": [
              {}
            ],
            "indexed": true,
            "internalType": "<string>"
          }
        ],
        "stateMutability": "pure",
        "anonymous": true
      }
    ]
  },
  "window": {
    "type": "rolling",
    "seconds": 131400
  },
  "id": "<string>",
  "created_at": 123,
  "owner_id": "<string>",
  "conditions": [],
  "group_by": []
}

Authorizations

Authorization
string
header
required

Basic Auth header with your app ID as the username and your app secret as the password.

Headers

privy-app-id
string
required

ID of your Privy app.

Path Parameters

aggregation_id
string
required
Minimum string length: 1

Response

200 - application/json

Requested aggregation object.

An aggregation that measures and tracks metrics over a period of time.

name
string
required

The name of the aggregation.

Required string length: 1 - 255
method
enum<string>
required

The RPC method this aggregation applies to.

Available options:
eth_signTransaction,
eth_signUserOperation
metric
AggregationMetric · object
required

The metric configuration for an aggregation, defining what field/field_source to measure and the aggregation function to apply.

window
AggregationWindow · object
required

The time window configuration for an aggregation.

id
string
required

Unique ID of the aggregation.

created_at
number
required

Unix timestamp of when the aggregation was created in milliseconds.

owner_id
string | null
required

The key quorum ID of the owner of the aggregation.

conditions
object[]

Optional conditions to filter events before aggregation.

Maximum array length: 100
group_by
AggregationGroupBy · object[]

Optional grouping configuration for bucketing metrics.

Maximum array length: 2