# Upload files to the integration

```
POST https://www.example.com/api/v2/privacy_requests/:id/integrations/:integration_id/files
```

## Request

### Path Parameters

**id** string required  
The unique identifier of the privacy request  
**Example:** `80edbafc-4ec6-45a0-b341-73080457890e`

**integration_id** string required  
The unique identifier of the integration to upload files  
**Example:** `7efa58a8-9b7d-4faf-8082-5f7f7f407db7`

### Header Parameters

**authorization** string required  
**Example:** `Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9`

- multipart/form-data
- Body
- Example (auto)

### Body array **required**
List of files to upload (multipart/form-data in format files[]=<your_file>).

* * *

Max upload limit of all files is 200 MB.

See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/MIME_types#multipartform-data

* * *

Example:

```bash
curl -X POST https://www.example.com/api/v2/privacy_requests/:id/integrations/:integration_id/files -H "Authorization: Bearer [KEY]" -F "files[]=@/example1.txt" -F "files[]=@/example2.txt"
```

## Responses

- 201
- 400
- 401
- 403
- 404

Files uploading complete

- application/json

- Schema
- Example (auto)

**Schema**

**message** string  
Message which contains count of uploaded files.  
**Example:** `2 files uploaded successfully.`

```json
{
  "message": "2 files uploaded successfully."
}
```

Bad Request
- application/json
- Schema
- Example (auto)

**Schema**

**error** string  
Detailed error message.

```json
{
  "error": "string"
}
```

Unauthorized
- application/json
- Schema
- Example (auto)

**Schema**

**error** string  
Detailed error message.

```json
{
  "error": "string"
}
```

Forbidden
- application/json
- Schema
- Example (auto)

**Schema**

**error** string  
Detailed error message.

```json
{
  "error": "string"
}
```

Not Found
- application/json
- Schema
- Example (auto)

**Schema**

**error** string  
Detailed error message.

```json
{
  "error": "string"
}
```

```plaintext

```

### CURL Example

```bash
curl -L -X POST 'https://www.example.com/api/v2/privacy_requests/:id/integrations/:integration_id/files' \
-H 'Content-Type: multipart/form-data' \
-H 'Accept: application/json' \
-d ''
```

## Parameters

**id** — path required

**integration_id** — path required

**authorization** — header required

**Body** required

```plaintext

```

**Need help?**  
If you have any questions, please reach out to your dedicated Account Manager or contact us at [support@datagrail.io](mailto:support@datagrail.io).

*Disclaimer: The information contained in this message does not constitute as legal advice. We would advise seeking professional counsel before acting on or interpreting any material.*
