Skip to main content
POST
/
v1
/
evm
/
flash-loans
/
prints
curl -X POST "https://api.blockdb.io/v1/evm/flash-loans/prints" \
  -H "Authorization: Bearer $BLOCKDB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "chain_id": 1,
  "from_block": 19000000,
  "to_block": 19000100,
  "limit": 50
}'
{
  "meta": {
    "chain_id": 1,
    "request_window": {
      "from_block": 19000000,
      "to_block": 19000100,
      "from_timestamp": null,
      "to_timestamp": null
    },
    "resolved_window": {
      "from_block": 19000000,
      "to_block": 19000100,
      "from_timestamp": null,
      "to_timestamp": null
    },
    "filters": {
      "pool_uids": [],
      "flash_loan_source_addresses": [],
      "token_addresses": [],
      "limit": 50,
      "cursor": null
    }
  },
  "data": [
    {
      "block_number": 19000050,
      "block_time": "2025-11-11T10:00:00Z",
      "tx_index": 12,
      "log_index": 3,
      "pool_uid": "88e6a0c2ddd26feeb64f039a2c41296fcb3f5640000000000000000000000000",
      "exchange_id": 1,
      "type_id": 201,
      "flash_loan_source": "88e6a0c2ddd26feeb64f039a2c41296fcb3f564",
      "token": "c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
      "amount_borrowed_raw": "1000000000000000000",
      "amount_borrowed": "1",
      "amount_repaid_raw": "1003000000000000000",
      "amount_repaid": "1.003",
      "fee_amount_raw": "3000000000000000",
      "fee_amount": "0.003",
      "_tracing_id": "0305c0ffee000000000000000000000000000000000000000000000000000001",
      "_parent_tracing_ids": [
        "0103c0ffee000000000000000000000000000000000000000000000000000001"
      ],
      "_created_at": "2025-11-11T10:00:05Z",
      "_updated_at": "2025-11-11T10:00:05Z"
    }
  ],
  "cursor": null,
  "page_count": 1
}

Overview

  • Dataset ID: 0305 - Flash Loan Prints
  • Description: One row per borrowed token per on-chain flash loan event (V2-style flash swap, V3 Flash event, Balancer V2 Vault, etc.). pool_uid is NULL for vault-level events not tied to a single pool.
  • CSV Sample: Download
  • JSON Sample: Download

Parameters

chain_id
number
required
Target EVM network. See the Chain enumeration.

Range filters (mutually exclusive)

from_block
number
Starting block number (inclusive). Use with to_block.
to_block
number
Ending block number (inclusive). Use with from_block.
from_timestamp
string
Starting timestamp (ISO-8601). Use with to_timestamp.
to_timestamp
string
Ending timestamp (ISO-8601). Use with from_timestamp.
Provide either a block range or a time range or direct selectors (pool_uids, flash_loan_source_addresses, and/or token_addresses).
Do not mix block and timestamp ranges. Invalid combinations return HTTP 400.

Direct selectors

pool_uids
string[]
Filter to pool UIDs (32-byte hex, no 0x). Omitted or null pool_uid rows (vault-level) require other selectors if you need them.
flash_loan_source_addresses
string[]
Emitter contracts (20-byte hex, no 0x): pool or vault that emitted the event.
token_addresses
string[]
Borrowed token addresses (20-byte hex, no 0x).

Pagination

limit
number
default:"250"
Recommended default 250; maximum 1000 to stay under ~10 MB responses.
cursor
string
Opaque pagination cursor from a previous response.

Decimals-Adjusted Amounts

include_adjusted_amounts
boolean
default:"false"
Off by default. When set to true, the response includes data.amount_borrowed, data.amount_repaid, and data.fee_amount (decimals-adjusted, may be null) alongside the raw integer fields. Enabling it adds a per-request ERC-20 decimals lookup (extra join) that increases latency, so it is opt-in; when omitted or false, those fields are returned as null and only the always-present *_raw fields are populated.

Response fields

Meta

meta
object
Echo of request metadata applied to the response.
meta.chain_id
number
EVM chain ID echoed from the request.
meta.request_window
object
Pure echo of the window you sent (from_block/to_block/from_timestamp/to_timestamp); unset bounds are null.
meta.resolved_window
object | null
The concrete window the query actually executed against, after resolving the request. For a block range on a time-bucketed endpoint (OHLC/VWAP/VWAP-aggregate/fiat VWAP), from_timestamp/to_timestamp hold the resolved timestamp window (and from_block/to_block echo your request). For a time range on a block-keyed endpoint, from_block/to_block hold the resolved block range (and the timestamps echo your request). null for selector-only requests (no window). No extra database work is done — these are the values the query already computed.
meta.resolved_window.from_block
number | null
Resolved/echoed start block of the executed window.
meta.resolved_window.to_block
number | null
Resolved/echoed end block of the executed window.
meta.resolved_window.from_timestamp
string | null
Resolved/echoed start timestamp (ISO-8601) of the executed window.
meta.resolved_window.to_timestamp
string | null
Resolved/echoed end timestamp (ISO-8601) of the executed window.
meta.filters
object
Echo of selectors and pagination from the request.

Data

data
object[]
Flash loan print records matching the request.
data.block_number
number
Block height of the event.
data.block_time
string
UTC timestamp of the block.
data.tx_index
number
Transaction index within the block.
data.log_index
number
Log index within the transaction.
data.pool_uid
string | null
32-byte internal pool id (hex), or null for vault-level flash loans.
data.exchange_id
number | null
Present when pool_uid is set; otherwise null.
data.type_id
number | null
Pool type id when pool_uid is set; otherwise null.
data.flash_loan_source
string
20-byte address of the contract that emitted the event (hex, no 0x).
data.token
string
20-byte ERC-20 token borrowed in this row (hex, no 0x).
data.amount_borrowed_raw
string
Raw amount borrowed as a uint256 integer in the borrowed token’s smallest denomination. String-encoded.
data.amount_borrowed
string | null
Decimals-adjusted form of amount_borrowed_raw (resolved against token). null when decimals are unknown or include_adjusted_amounts=false.
data.amount_repaid_raw
string
Raw amount repaid (borrowed + fee) as a uint256 integer in the borrowed token’s smallest denomination.
data.amount_repaid
string | null
Decimals-adjusted form of amount_repaid_raw. Same null semantics as amount_borrowed.
data.fee_amount_raw
string
Raw fee: amount_repaid_raw − amount_borrowed_raw, in the borrowed token’s smallest denomination.
data.fee_amount
string | null
Decimals-adjusted form of fee_amount_raw. Same null semantics as amount_borrowed.
data._tracing_id
string
Row tracing id (hex, no 0x).
data._parent_tracing_ids
string[]
Parent tracing ids.
data._created_at
string
Record creation timestamp (ISO-8601).
data._updated_at
string
Record last update timestamp (ISO-8601).

Envelope

cursor
string | null
Pagination cursor.
page_count
number
Number of rows in data.
curl -X POST "https://api.blockdb.io/v1/evm/flash-loans/prints" \
  -H "Authorization: Bearer $BLOCKDB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "chain_id": 1,
  "from_block": 19000000,
  "to_block": 19000100,
  "limit": 50
}'
{
  "meta": {
    "chain_id": 1,
    "request_window": {
      "from_block": 19000000,
      "to_block": 19000100,
      "from_timestamp": null,
      "to_timestamp": null
    },
    "resolved_window": {
      "from_block": 19000000,
      "to_block": 19000100,
      "from_timestamp": null,
      "to_timestamp": null
    },
    "filters": {
      "pool_uids": [],
      "flash_loan_source_addresses": [],
      "token_addresses": [],
      "limit": 50,
      "cursor": null
    }
  },
  "data": [
    {
      "block_number": 19000050,
      "block_time": "2025-11-11T10:00:00Z",
      "tx_index": 12,
      "log_index": 3,
      "pool_uid": "88e6a0c2ddd26feeb64f039a2c41296fcb3f5640000000000000000000000000",
      "exchange_id": 1,
      "type_id": 201,
      "flash_loan_source": "88e6a0c2ddd26feeb64f039a2c41296fcb3f564",
      "token": "c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
      "amount_borrowed_raw": "1000000000000000000",
      "amount_borrowed": "1",
      "amount_repaid_raw": "1003000000000000000",
      "amount_repaid": "1.003",
      "fee_amount_raw": "3000000000000000",
      "fee_amount": "0.003",
      "_tracing_id": "0305c0ffee000000000000000000000000000000000000000000000000000001",
      "_parent_tracing_ids": [
        "0103c0ffee000000000000000000000000000000000000000000000000000001"
      ],
      "_created_at": "2025-11-11T10:00:05Z",
      "_updated_at": "2025-11-11T10:00:05Z"
    }
  ],
  "cursor": null,
  "page_count": 1
}
Last modified on May 29, 2026