POST
/
files
/
v3
/
files
Upload file
curl --request POST \
  --url https://api.hubapi.com/files/v3/files \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form 'folderId=<string>' \
  --form 'folderPath=<string>' \
  --form 'fileName=<string>' \
  --form 'charsetHunch=<string>' \
  --form 'options=<string>' \
  --form file=@example-file
{
  "extension": "<string>",
  "access": "PUBLIC_INDEXABLE",
  "parentFolderId": "<string>",
  "sourceGroup": "<string>",
  "fileMd5": "<string>",
  "encoding": "<string>",
  "type": "<string>",
  "isUsableInContent": true,
  "url": "<string>",
  "expiresAt": 123,
  "createdAt": "2023-11-07T05:31:56Z",
  "archivedAt": "2023-11-07T05:31:56Z",
  "path": "<string>",
  "archived": true,
  "size": 123,
  "name": "<string>",
  "width": 123,
  "id": "<string>",
  "defaultHostingUrl": "<string>",
  "updatedAt": "2023-11-07T05:31:56Z",
  "height": 123
}
Supported products
Requires one of the following products or higher.
Marketing HubMarketing HubFree
Sales HubSales HubFree
Service HubService HubFree
Content HubContent HubStarter

Required Scopes

This API requires one of the following scopes:
  • files

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

multipart/form-data

Response

201
application/json

successful operation

File