# Een gegenereerd mediabestand downloaden (anoniem)

**API:** Model API

**Endpoint:** `GET /api/v1/media/{file_id}`

Streamt het gegenereerde video- of afbeeldingsbestand. Dit endpoint is anoniem: de authenticatie is de HMAC-signatuur in de URL. Gebruik altijd de volledige URL die in de outputs-array van de taak wordt geretourneerd; stel exp/sig niet zelf samen. Ondersteunt Range-verzoeken om te hervatten. Media wordt verwijderd of ongeldig gemaakt wanneer de signatuur of de upstream-TTL verloopt.

## Base URL

- `https://openapi.felo.ai` — Productie

## Authentication

No authentication required — this endpoint is anonymous.

## Parameters

| Name | In | Required | Type | Description |
| --- | --- | --- | --- | --- |
| `file_id` | path | yes | string, (uuid) | Ondertekend bestands-ID uit een output-URL van een taak. |
| `exp` | query | yes | integer, (int64) | Vervaldatum van de signatuur (unixseconden), uit de output-URL. |
| `sig` | query | yes | string | HMAC-signatuur, uit de output-URL. |

## Responses

### 200 — Mediabestand

**application/octet-stream**

Schema: string, (binary)

```json
{
  "type": "string",
  "format": "binary"
}
```

**video/mp4**

Schema: string, (binary)

```json
{
  "type": "string",
  "format": "binary"
}
```

### 400 — Ongeldig verzoek (bijv. een willekeurige ?url= is niet toegestaan)

**application/json**

Schema: `GenerationError` (`#/components/schemas/GenerationError`)

### 403 — Ongeldige of verlopen signatuur

**application/json**

Schema: `GenerationError` (`#/components/schemas/GenerationError`)

### 404 — Onbekend mediabestand

**application/json**

Schema: `GenerationError` (`#/components/schemas/GenerationError`)

### 410 — Media is verlopen of upstream is niet meer beschikbaar

**application/json**

Schema: `GenerationError` (`#/components/schemas/GenerationError`)

### 429 — Snelheidslimiet bereikt voor dit bestand

**application/json**

Schema: `GenerationError` (`#/components/schemas/GenerationError`)

### 502 — Ophalen van upstream-media mislukt

**application/json**

Schema: `GenerationError` (`#/components/schemas/GenerationError`)

## Schema definitions

### GenerationError

`#/components/schemas/GenerationError`

```json
{
  "type": "object",
  "description": "OpenAI-compatibele foutenvelop.",
  "properties": {
    "error": {
      "type": "object",
      "required": [
        "message",
        "type"
      ],
      "properties": {
        "message": {
          "type": "string"
        },
        "type": {
          "type": "string",
          "enum": [
            "invalid_request_error",
            "server_error"
          ]
        },
        "param": {
          "type": "string",
          "nullable": true
        },
        "code": {
          "type": "string"
        }
      }
    }
  }
}
```
