> ## Documentation Index
> Fetch the complete documentation index at: https://germeytechnology-docs-remove-4o-image-nav.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# API di Query delle Attività WebExtrator

> WebExtrator Web Render & Extract 集成指南 - Ace Data Cloud

`POST https://api.acedata.cloud/webextrator/tasks` (**gratuito**)

Consulta le attività storiche di tipo `render` / `extract` (conservate per 7 giorni).

## Query Singola

```json theme={null}
{
  "action": "retrieve",
  "id": "550e8400-e29b-41d4-a716-446655440000"
}
```

Oppure tramite `trace_id`:

```json theme={null}
{
  "action": "retrieve",
  "trace_id": "550e8400-e29b-41d4-a716-446655440001"
}
```

Restituisce un singolo oggetto attività (inclusi i campi `request` / `response` / `started_at` / `finished_at` ecc.).

## Query in Batch

```json theme={null}
{
  "action": "retrieve_batch",
  "ids": ["...", "..."],
  "limit": 12,
  "offset": 0
}
```

Oppure con `trace_ids`, oppure senza passarne nessuno per paginare e recuperare la cronologia delle proprie attività.

Risposta:

```json theme={null}
{
  "items": [ { /* task */ }, ... ],
  "count": 2
}
```

## Definizione dei Campi

| Campo                                    | Descrizione                                                                     |
| ---------------------------------------- | ------------------------------------------------------------------------------- |
| `id` / `task_id`                         | ID univoco dell’attività                                                        |
| `trace_id`                               | ID della catena di chiamate (allineato con PlatformGateway / CLS)               |
| `type`                                   | `render` o `extract`                                                            |
| `request`                                | Corpo della richiesta originale                                                 |
| `response`                               | Risultato del rendering / estrazione (come il campo `data` nella risposta sync) |
| `started_at` / `finished_at` / `elapsed` | Timestamp e durata (in secondi)                                                 |

> Questa API è gratuita e non conteggiata nel consumo.
