---
title: "Media"
description: "Documentation and guidance for building tools and integrations with the Disguise platform."
url: https://developer.disguise.one/api/service/media-reference/
---

# Media API

For a comprehensive guide on using these endpoints, see [here](/api/guide#media-api).

## GET list

### Summary

Lists all files in the given directory (recursive).

### URL

GET    /api/service/media/list

### Query Params

directory    string    

### Response

```json
{
  "status": {
    "code": 0,
    "message": "",
    "details": [
      {
        "type_url": "",
        "value": ""
      }
    ]
  },
  "files": [
    {
      "path": "",
      "size": "",
      "creationDate": "",
      "lastWriteDate": ""
    }
  ]
}
```

## POST provision

### Summary

Copies or downloads a file from a remote source to destinations on the local machine. Can be used to populate a Designer project with media files.

### URL

POST    /api/service/media/provision

### Request

```json
{
  "mediaPath": "",
  "localPath": [
    ""
  ],
  "uid": "",
  "transfers": [
    {
      "mediaPath": "",
      "uid": "",
      "localPath": [
        ""
      ]
    }
  ]
}
```

### Response

```json
{
  "status": {
    "code": 0,
    "message": "",
    "details": [
      {
        "type_url": "",
        "value": ""
      }
    ]
  },
  "result": [
    {
      "taskUid": "",
      "success": false,
      "errorMessage": {
        "mediaPath": "",
        "localPath": "",
        "message": ""
      },
      "taskType": "",
      "taskStatusStream": ""
    }
  ]
}
```

## POST remove

### Summary

Removes a file or folder from the local machine. Useful for cleaning up assets or directories within a Designer project. When Designer is running, it can automatically unlock files in the active project before deleting them, ensuring a smooth and error-free cleanup process.

### URL

POST    /api/service/media/remove

### Request

```json
{
  "path": ""
}
```

### Response

```json
{
  "status": {
    "code": 0,
    "message": "",
    "details": [
      {
        "type_url": "",
        "value": ""
      }
    ]
  },
  "taskUid": ""
}
```
