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

# Frameworks

> List and retrieve EU regulatory frameworks with the Rust SDK.

## Methods

```rust theme={null}
// List frameworks (paginated)
client.frameworks.list(page: Option<u32>, per_page: Option<u32>)
    -> Result<Page<Framework>, Law4DevsError>

// Get a framework by slug
client.frameworks.get(slug: &str)
    -> Result<FrameworkDetail, Law4DevsError>

// Auto-paginate all frameworks
client.frameworks.iter(per_page: u32)
    -> impl Stream<Item = Result<Framework, Law4DevsError>>
```

***

## List Frameworks

```rust theme={null}
let page = client.frameworks.list(None, None).await?;
println!("{} frameworks", page.meta.total);

for fw in &page.data {
    println!("{} — {}", fw.slug, fw.name);
}
```

With pagination:

```rust theme={null}
let page = client.frameworks.list(Some(1), Some(10)).await?;
```

***

## Get a Framework

```rust theme={null}
let gdpr = client.frameworks.get("gdpr").await?;
println!("{}: {} articles", gdpr.name, gdpr.article_count);
```

***

## Auto-Paginate

```rust theme={null}
use futures::StreamExt;

let mut stream = Box::pin(client.frameworks.iter(20));
while let Some(result) = stream.next().await {
    let fw = result?;
    println!("{}", fw.name);
}
```

***

## `Framework` Fields

| Field           | Type             | Description                       |
| --------------- | ---------------- | --------------------------------- |
| `id`            | `u32`            | Internal ID                       |
| `slug`          | `String`         | URL-safe identifier (e.g. `gdpr`) |
| `name`          | `String`         | Full name                         |
| `short_name`    | `String`         | Abbreviated name                  |
| `celex_number`  | `String`         | EUR-Lex CELEX number              |
| `description`   | `Option<String>` | Short description                 |
| `is_active`     | `bool`           | Whether actively maintained       |
| `status`        | `String`         | `active` or `superseded`          |
| `article_count` | `u32`            | Number of scraped articles        |
| `recital_count` | `u32`            | Number of scraped recitals        |

***

## `FrameworkDetail` Additional Fields

| Field               | Type            | Description                     |
| ------------------- | --------------- | ------------------------------- |
| `eurlex_url`        | `String`        | Link to original EUR-Lex source |
| `requirement_count` | `u32`           | Total requirements              |
| `annex_count`       | `u32`           | Total annexes                   |
| `tag_count`         | `u32`           | Number of associated tags       |
| `coverage`          | `Option<Value>` | Scrape coverage statistics      |
