> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.videogen.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.videogen.io/_mcp/server.

# Import a file from a link

POST https://api.videogen.io/v1/files/import-url
Content-Type: application/json

Starts importing a video from a public link (a video page or a direct video URL) into your files. Returns immediately with a file import id. Poll `GET /v1/files/imports/{fileImportId}` until `status` is `succeeded`, then use `fileId` anywhere a video file id is accepted, such as `POST /v1/workflows/video-to-video`. Videos up to 10 minutes long can be imported. Only import media you have the rights to use.

Reference: https://docs.videogen.io/rest-api-reference/files/create-file-url-import

## Authentication

- `Authorization` header (bearer token, required) — API key from [app.videogen.io/api](https://app.videogen.io/api). The full key is only shown once when you create it.

## Request

### Body (application/json)

This endpoint expects a CreateFileUrlImportRequest.

- `url` (string, required) — Public `http://` or `https://` link to a video page or a video file. Private, login-only, and DRM-protected videos cannot be imported.

## Response

### 202

File import accepted.

- `fileImportId` (string, required) — Opaque file import id (e.g. `vg_fimp_...`). Poll `GET /v1/files/imports/{fileImportId}` for completion.

## Examples

**Request**

```json
{
  "url": "string"
}
```

**Response**

```json
{
  "fileImportId": "string"
}
```

**SDK Code**

```python
import requests

url = "https://api.videogen.io/v1/files/import-url"

payload = { "url": "string" }
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```