> ## Documentation Index
> Fetch the complete documentation index at: https://docs.blockworks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Privacy Flows and Balances

> Daily balance, deposits, withdrawals and net flow, in native units and USD, of one token in one privacy protocol (a shielded pool, mixer or privacy vault) on one chain, with deposit and withdrawal transfer counts. Each series is one protocol token, keyed by chain, token address and protocol.

One row per token held by a privacy protocol (a shielded pool, mixer or privacy vault) on one chain, keyed by chain, token address and protocol: the protocol, the token, the chain and the mapped project and network records. The id is the series key of the privacy-flows timeseries model.

| | |
| - | - |
| Access | Projects-dataset |
| Tabular model | `privacy-flows`: primary key `id` |
| Timeseries model | `privacy-flows`: intervals `1d`, series key `id` (Privacy Flow ID), series must be named (up to 20 per call) |

## Endpoints

> **[List Privacy Flows](https://docs.blockworks.com/api-reference/data-api/privacy/tabular-privacy-flows.md)**
>
> One page of rows with per-column filters, sorting and pagination.

> **[Batch Get Privacy Flow timeseries](https://docs.blockworks.com/api-reference/data-api/privacy/timeseries-privacy-flows.md)**
>
> Up to 20 series in one request, named by Privacy Flow ID in `series`.

> **[Get Privacy Flow timeseries](https://docs.blockworks.com/api-reference/data-api/privacy/timeseries-privacy-flows-by-id.md)**
>
> One series over a time window, keyed by its Privacy Flow ID.

## Metrics

10 metrics. Use the `Field` value in `selections`; every point starts with the timestamp and continues in this order.

| Field | Name | Type | Unit | Description |
| - | - | - | - | - |
| `balance` | Balance | float64 | | Token balance held by the protocol, in native units. |
| `balanceUSD` | Balance (USD) | float64 | | Token balance held by the protocol in USD. |
| `depositAmount` | Deposit Amount | float64 | | Tokens deposited into the protocol, in native units. |
| `depositAmountUSD` | Deposit Amount (USD) | float64 | | Tokens deposited into the protocol in USD. |
| `depositTransferCount` | Deposit Transfer Count | float64 | | Number of deposit transfers. |
| `withdrawalAmount` | Withdrawal Amount | float64 | | Tokens withdrawn from the protocol, in native units. |
| `withdrawalAmountUSD` | Withdrawal Amount (USD) | float64 | | Tokens withdrawn from the protocol in USD. |
| `withdrawalTransferCount` | Withdrawal Transfer Count | float64 | | Number of withdrawal transfers. |
| `netFlow` | Net Flow | float64 | | Deposits less withdrawals, in native units. |
| `netFlowUSD` | Net Flow (USD) | float64 | | Deposits less withdrawals in USD. |

## Columns

Use the `Field` value in `selections`, `sortBy`, and as the base of a filter parameter (`Field` plus one of its `Filters` suffixes).

| Field | Type | Filters | Sort | Description |
| - | - | - | - | - |
| `id` | string | `Eq`, `IsOneOf` | | The series key of the privacy-flows timeseries model, the chain, token address and privacy protocol id, joined with underscores. (primary key) |
| `name` | string | `Eq`, `IsOneOf`, `Contains` | default | The display name of the series, the protocol and token. |
| `slug` | string | `Eq`, `IsOneOf` | yes | The project's slug, the slug used for the same project across the API. |
| `chain` | string | `Eq`, `IsOneOf` | yes | The short name of the chain (ethereum, base, solana). |
| `tokenAddress` | string | `Eq`, `IsOneOf` | | The token contract address; native for the chain's own coin in Monero and Zcash shielded pools. |
| `protocolID` | string | `Eq`, `IsOneOf` | yes | The privacy protocol's identifier (tornado-cash, railgun, sapling). |
| `projectID` | string | `Eq`, `IsOneOf` | | The identifier of the project record; null when unmapped. |
| `networkID` | string | `Eq`, `IsOneOf` | | The chain's networkID in the blockchains model; null when unmapped. |
| `networkSlug` | string | `Eq`, `IsOneOf` | | The chain's slug in the blockchains model; null when unmapped. |

## Example

```bash curl theme={null}
curl "https://api.blockworks.com/query/timeseries/privacy-flows/1d/<id>?timeframe=7d&selections=balance,balanceUSD" \
  -H "X-Blockworks-API-Key: $BLOCKWORKS_API_KEY"
```

See [Get Privacy Flow timeseries](https://docs.blockworks.com/api-reference/data-api/privacy/timeseries-privacy-flows-by-id.md) for the response and the errors.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.