> For the complete documentation index, see [llms.txt](https://docs.enclaive.cloud/enclaive-multi-cloud-platform/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.enclaive.cloud/enclaive-multi-cloud-platform/developers/api/client-api/support/hubspot-files.md).

# Hubspot Files

In the "HubSpot Files" section, you can find an endpoint that allows users to add files when creating support tickets. This functionality simplifies the process of attaching relevant files or documents to tickets, facilitating effective communication with the support team.

## Create

<mark style="color:green;">`POST`</mark> `{{BASE_URL}}/upload`

Attach a file to a specific ticket.

#### Headers

| Name                                            | Type   | Description  |
| ----------------------------------------------- | ------ | ------------ |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer Token |

#### Request Body

| Name                                   | Type   | Description         |
| -------------------------------------- | ------ | ------------------- |
| data<mark style="color:red;">\*</mark> | Binary | png, jpeg, bmp, pdf |

{% tabs %}
{% tab title="200: OK " %}

```json
{
    "id": 84694440637,
    "portal_id": 139689106,
    "name": "John Doe.1699281451244",
    "size": 6808,
    "height": 192,
    "width": 192,
    "encoding": "png",
    "type": "IMG",
    "extension": "png",
    "cloud_key": "hubfs/139689106/enclaive/ticket_attachments/6548a41138406c14db33b606/Igor%20Solonskiy.1699281451244.png",
    "s3_url": "https://cdn1.hubspotusercontent-eu1.net/hubfs/139689106/enclaive/ticket_attachments/6548a41138406c14db33b606/Igor%20Solonskiy.1699281451244.png",
    "friendly_url": "https://139689106.fs1.hubspotusercontent-eu1.net/hubfs/139689106/enclaive/ticket_attachments/6548a41138406c14db33b606/Igor%20Solonskiy.1699281451244.png",
    "meta": {
        "allows_anonymous_access": false,
        "expires_at": 1707230251688,
        "indexable": false
    },
    "created": 1699281451735,
    "updated": 1699281451735,
    "deleted_at": 0,
    "folder_id": 84694440636,
    "hidden": false,
    "archived": false,
    "created_by": 27669242,
    "deleted_by": null,
    "replaceable": true,
    "default_hosting_url": "https://139689106.fs1.hubspotusercontent-eu1.net/hubfs/139689106/enclaive/ticket_attachments/6548a41138406c14db33b606/Igor%20Solonskiy.1699281451244.png",
    "teams": [],
    "title": "John Doe.1699281451244",
    "is_indexable": false,
    "cloud_key_hash": "508fe7a6c2df81964213d44fc8b0f84c",
    "url": "https://139689106.fs1.hubspotusercontent-eu1.net/hubfs/139689106/enclaive/ticket_attachments/6548a41138406c14db33b606/Igor%20Solonskiy.1699281451244.png",
    "cdn_purge_embargo_time": null,
    "file_hash": "2686e04af3687d090a4077b591cb30c7"
}
```

{% endtab %}
{% endtabs %}
