Skip to main content
GET
/
accounts
/
{account_id}
/
activities
List Activities
curl --request GET \
  --url https://api.example.com/accounts/{account_id}/activities

List Activities

Returns the activity history for a sub-account. Activities represent on-chain operations like supplies, withdrawals, and transfers. See Activities & Events for the full activity definition.

Request

GET /accounts/:account_id/activities

Path parameters

ParameterTypeDescription
account_idstringThe sub-account ID

Examples

curl https://prime-api.legend.xyz/accounts/acc_2o0yiljtp378/activities \
  -H "Authorization: Bearer $LEGEND_QUERY_KEY"
Response
{
  "activities": [
    {
      "id": 1,
      "status": "completed",
      "quark_intent": {
        "id": 7,
        "mercator_version": "1.2.0",
        "intent_type": "supply",
        "intent": {
          "amount": "1000000",
          "token": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
          "comet": "0xb125E6687d4313864e53df431d5425969c15Eb2F",
          "chain_id": 8453
        }
      },
      "executions": [
        {
          "execution_type": "transaction",
          "chain_id": 8453,
          "transaction_hash": "0xabc123...def456",
          "status": "executed",
          "executed_at": "2025-06-15T10:30:15Z",
          "reverted_at": null,
          "actions": [
            {
              "action_type": "COMET_SUPPLY",
              "expected_values": {
                "amount": 1000000,
                "asset_symbol": "USDC",
                "chain_id": 8453,
                "comet": "0xb125E6687d4313864e53df431d5425969c15Eb2F",
                "price": "0.9998",
                "token": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"
              },
              "observed_values": {
                "amount": 1000000,
                "asset_symbol": "USDC",
                "chain_id": 8453,
                "comet": "0xb125E6687d4313864e53df431d5425969c15Eb2F",
                "price": "0.9998",
                "token": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"
              }
            }
          ]
        }
      ]
    }
  ]
}

Response fields

FieldTypeDescription
activitiesarrayList of activity objects, newest first
activities[].idintegerActivity ID
activities[].statusstringStatus: "pending", "completed", "failed"
activities[].quark_intentobject?The original intent that created this activity (if applicable)
activities[].executionsarrayList of on-chain executions that make up the activity

Errors

StatusCodeDescription
404account_not_foundAccount doesn’t exist