HubSpot Files V2 (Independent Publisher) (Preview)

With the easy-to-use HubSpot CRM, you'll never have to manually update reports or wonder how your team is tracking toward quotas. Get a real-time view of your entire sales pipeline on a visual dashboard. HubSpot CRM will automatically organize, enrich, and track each contact in a tidy timeline.

This connector is available in the following products and regions:

Service Class Regions
Logic Apps Standard All Logic Apps regions except the following:
     -   Azure Government regions
     -   Azure China regions
     -   US Department of Defense (DoD)
Contact
Name Troy Taylor
URL https://www.hitachisolutions.com
Email ttaylor@hitachisolutions.com
Connector Metadata
Publisher Troy Taylor
Website https://www.hubspot.com/
Privacy policy https://legal.hubspot.com/privacy-policy
Categories Content and Files;Sales and CRM

Creating a connection

The connector supports the following authentication types:

Default Parameters for creating connection. All regions Not shareable

Default

Applicable: All regions

Parameters for creating connection.

This is not shareable connection. If the power app is shared with another user, another user will be prompted to create new connection explicitly.

Name Type Description Required
Access Token (in the form 'Bearer YOUR_TOKEN') securestring The Access Token (in the form 'Bearer YOUR_TOKEN') for this api True

Throttling Limits

Name Calls Renewal Period
API calls per connection 100 60 seconds

Actions

Check folder update

Check status of folder update. Folder updates happen asynchronously.

Check import status

Check the status of requested import.

Create folder

Creates a folder.

Delete file

Delete file by ID.

Delete file for GDRP

Deletes a file for GDRP.

Delete folder

Delete folder by ID.

Generate link

Generates signed URL that allows temporary access to a private file.

Get file

Retrieve a file by ID.

Get file by path

Retrieve the file by the path address.

Get folder

Get folder by ID.

Import file asynchronously

Asynchronously imports the file at the given URL into the file manager.

Search files

Search through files in the file manager. Does not display hidden or archived files.

Search folders

Search for folders. Does not contain hidden or archived folders.

Update file

Replaces existing file data with new file data. Can be used to change image content without having to upload a new file and update all references.

Update file properties

Update properties of file by ID.

Update folder properties

Update properties of folder by given ID. This action happens asynchronously and will update all of the folder's children as well.

Upload file

Upload a single file with content specified in request body.

Check folder update

Check status of folder update. Folder updates happen asynchronously.

Parameters

Name Key Required Type Description
Task ID
taskId True string

TaskId of folder update.

Returns

FolderActionResponse
FolderActionResponse

Check import status

Check the status of requested import.

Parameters

Name Key Required Type Description
Task ID
taskId True string

Import by URL task ID.

Returns

FileActionResponse
FileActionResponse

Create folder

Creates a folder.

Parameters

Name Key Required Type Description
Parent Folder ID
parentFolderId string

FolderId of the parent of the created folder. If not specified, the folder will be created at the root level. parentFolderId and parentFolderPath cannot be set at the same time.

Parent Path
parentPath string

Path of the parent of the created folder. If not specified the folder will be created at the root level. parentFolderPath and parentFolderId cannot be set at the same time.

Name
name True string

Desired name for the folder.

Returns

Folder
Folder

Delete file

Delete file by ID.

Parameters

Name Key Required Type Description
File ID
fileId True string

FileId to delete.

Delete file for GDRP

Deletes a file for GDRP.

Parameters

Name Key Required Type Description
File ID
fileId True string

ID of file to GDPR delete.

Delete folder

Delete folder by ID.

Parameters

Name Key Required Type Description
Folder ID
folderId True string

ID of folder to delete.

Generates signed URL that allows temporary access to a private file.

Parameters

Name Key Required Type Description
File ID
fileId True string

ID of file.

Size
size string

For image files. This will resize the image to the desired size before sharing. Does not affect the original file, just the file served by this signed URL.

Expiration
expirationSeconds integer

How long in seconds the link will provide access to the file.

Upscale
upscale boolean

If size is provided, this will upscale the image to fit the size dimensions.

Returns

Signed Url object with optional ancillary metadata of requested file.

SignedUrl
SignedUrl

Get file

Retrieve a file by ID.

Parameters

Name Key Required Type Description
File ID
fileId True string

ID of the desired file.

Properties
properties string

The properties.

Returns

File.

File
File

Get file by path

Retrieve the file by the path address.

Parameters

Name Key Required Type Description
Path
path True string

The path.

Properties
properties array

The properties.

Returns

FileStat
FileStat

Get folder

Get folder by ID.

Parameters

Name Key Required Type Description
Folder ID
folderId True string

ID of desired folder.

Properties
properties array

Properties to set on returned folder.

Returns

Folder
Folder

Import file asynchronously

Asynchronously imports the file at the given URL into the file manager.

Parameters

Name Key Required Type Description
Folder Path
folderPath string

One of folderPath or folderId is required. Destination folder path for the uploaded file. If the folder path does not exist, there will be an attempt to create the folder path.

Access1
access True string

PUBLIC_INDEXABLE: File is publicly accessible by anyone who has the URL. Search engines can index the file. PUBLIC_NOT_INDEXABLE: File is publicly accessible by anyone who has the URL. Search engines can't index the file. PRIVATE: File is NOT publicly accessible. Requires a signed URL to see content. Search engines can't index the file.

DuplicateValidationScope
duplicateValidationScope string

ENTIRE_PORTAL: Look for a duplicate file in the entire account. EXACT_FOLDER: Look for a duplicate file in the provided folder.

Name
name string

Name to give the resulting file in the file manager.

DuplicateValidationStrategy
duplicateValidationStrategy string

NONE: Do not run any duplicate validation. REJECT: Reject the upload if a duplicate is found. RETURN_EXISTING: If a duplicate file is found, do not upload a new file and return the found duplicate instead.

TTL
ttl string

Time to live. If specified the file will be deleted after the given time frame. If left unset, the file will exist indefinitely.

Overwrite
overwrite boolean

If true, will overwrite existing file if one with the same name and extension exists in the given folder. The overwritten file will be deleted and the uploaded file will take its place with a new ID. If unset or set as false, the new file's name will be updated to prevent colliding with existing file if one exists with the same path, name, and extension

URL
url True string

URL to download the new file from.

Folder ID
folderId string

One of folderId or folderPath is required. Destination folderId for the uploaded file.

Returns

Information on the task that has been started, and where to check it's status.

ImportFromUrlTaskLocator
ImportFromUrlTaskLocator

Search files

Search through files in the file manager. Does not display hidden or archived files.

Parameters

Name Key Required Type Description
Properties
properties array

Desired file properties in the return object.

After
after string

The maximum offset of items for a given search is 10000. Narrow your search down if you are reaching this limit.

Before
before string

The before.

Limit
limit integer

Number of items to return. Maximum limit is 100.

Sort
sort array

Sort files by a given field.

ID
id string

Search files by given ID.

Created At
createdAt string

Search files by time of creation.

Created At LTE
createdAtLte string

The created at time less than or equal.

Created At GTE
createdAtGte string

The created at greater than or equal.

Updated At
updatedAt string

Search files by time of latest updated.

Updated At LTE
updatedAtLte string

The updated at later than or equal.

Updated At GTE
updatedAtGte string

The updated at greater than or equal.

Name
name string

Search for files containing the given name.

Path
path string

Search files by path.

Parent Folder ID
parentFolderId integer

Search files within given folderId.

Size
size integer

Query by file size.

Height
height integer

Search files by height of image or video.

Width
width integer

Search files by width of image or video.

Encoding
encoding string

Search files with specified encoding.

Type
type string

Filter by provided file type.

Extension
extension string

Search files by given extension.

URL
url string

Search for given URL.

Is Usable In Content
isUsableInContent boolean

If true shows files that have been marked to be used in new content. It false shows files that should not be used in new content.

Allow Anonymous Access
allowsAnonymousAccess boolean

If 'true' will show private files; if 'false' will show public files.

Returns

Collections of files.

CollectionResponseFile
CollectionResponseFile

Search folders

Search for folders. Does not contain hidden or archived folders.

Parameters

Name Key Required Type Description
Properties
properties array

Properties that should be included in the returned folders.

After
after string

The maximum offset of items for a given search is 10000. Narrow your search down if you are reaching this limit.

Before
before string

The before.

Limit
limit integer

Limit of results to return. Max limit is 100.

Sort
sort array

Sort results by given property. For example -name sorts by name field descending, name sorts by name field ascending.

ID
id string

Search folder by given ID.

Created At
createdAt string

Search for folders with the given creation timestamp.

Created At LTE
createdAtLte string

The created at time less than or equal.

Created At GTE
createdAtGte string

The created at greater than or equal.

Updated At
updatedAt string

Search for folder at given update timestamp.

Updated At LTE
updatedAtLte string

The updated at later than or equal.

Updated At GTE
updatedAtGte string

The updated at greater than or equal.

Name
name string

Search for folders containing the specified name.

Path
path string

Search for folders by path.

Parent Folder ID
parentFolderId integer

Search for folders with the given parent folderId.

Returns

CollectionResponseFolder
CollectionResponseFolder

Update file

Replaces existing file data with new file data. Can be used to change image content without having to upload a new file and update all references.

Parameters

Name Key Required Type Description
File ID
fileId True string

ID of the desired file.

File
file file

File data that will replace existing file in the file manager.

Character Set
charsetHunch string

Character set of given file data.

Options
options string

JSON String representing FileReplaceOptions.

Returns

File.

File
File

Update file properties

Update properties of file by ID.

Parameters

Name Key Required Type Description
File ID
fileId True string

ID of file to update.

Access2
access string

NONE: Do not run any duplicate validation. REJECT: Reject the upload if a duplicate is found. RETURN_EXISTING: If a duplicate file is found, do not upload a new file and return the found duplicate instead.

Parent Folder ID
parentFolderId string

FolderId where the file should be moved to. folderId and folderPath parameters cannot be set at the same time.

Name
name string

New name for the file.

Parent Folder Path
parentFolderPath string

Folder path where the file should be moved to. folderId and folderPath parameters cannot be set at the same time.

Is Usable In Context
isUsableInContent boolean

Mark whether the file should be used in new content or not.

Expires At
expiresAt integer

When expires at.

Returns

File.

File
File

Update folder properties

Update properties of folder by given ID. This action happens asynchronously and will update all of the folder's children as well.

Parameters

Name Key Required Type Description
Parent Folder ID
parentFolderId integer

New parent folderId. If changed, the folder and all it's children will be moved into the specified folder. parentFolderId and parentFolderPath cannot be specified at the same time.

Name
name string

New name. If specified the folder's name and fullPath will change. All children of the folder will be updated accordingly.

ID
id True string

ID of the folder to change.

Returns

Information on the task that has been started, and where to check it's status.

FolderUpdateTaskLocator
FolderUpdateTaskLocator

Upload file

Upload a single file with content specified in request body.

Parameters

Name Key Required Type Description
File
file True file

File to be uploaded.

Folder ID
folderId string

Either 'folderId' or 'folderPath' is required. folderId is the ID of the folder the file will be uploaded to.

Folder Path
folderPath string

Either 'folderPath' or 'folderId' is required. This field represents the destination folder path for the uploaded file. If a path doesn't exist, the system will try to create one.

File Name
fileName True string

Desired name for the uploaded file.

Character Set
charsetHunch string

Character set of the uploaded file.

Access Options
options.access True string

Access level for the uploaded file.

TTL Options
options.ttl integer

Time to live for the uploaded file.

Returns

File.

File
File

Definitions

StandardError

Name Path Type Description
Subcategory
subCategory object

The subcategory.

Context
context object

The context.

Links
links object

The links.

ID
id string

The identifier.

Category
category string

The category.

Message
message string

The message.

Errors
errors array of ErrorDetail

The errors.

Status
status string

The status.

FolderActionResponse

Name Path Type Description
Folder
result Folder
Completed At
completedAt string

When the requested changes have been completed.

Number of Errors
numErrors integer

Number of errors resulting from the requested changes.

Requested At
requestedAt string

Timestamp representing when the task was requested.

Started At
startedAt string

Timestamp representing when the task was started at.

Links
links object

Link to check the status of the task.

Errors
errors array of StandardError

Detailed errors resulting from the task.

Task ID
taskId string

ID of the task.

Status
status Status

Current status of the task.

Paging

Name Path Type Description
NextPage
next NextPage
PreviousPage
prev PreviousPage

Folder

Name Path Type Description
Created At
createdAt string

Timestamp of folder creation.

Archived At
archivedAt string

Timestamp of folder deletion.

Archived
archived boolean

Marks whether the folder is deleted or not.

Path
path string

Path of the folder in the file manager.

Parent Folder ID
parentFolderId string

ID of the parent folder.

Name
name string

Name of the folder.

ID
id string

ID of the folder.

Updated At
updatedAt string

Timestamp of the latest update to the folder.

CollectionResponseFile

Collections of files.

Name Path Type Description
Paging
paging Paging
results
results array of File

ErrorDetail

Name Path Type Description
Subcategory
subCategory string

A specific category that contains more specific detail about the error.

Code
code string

The status code associated with the error detail.

Description
in string

The name of the field or parameter in which the error was found.

Context
context object

Context about the error condition.

Message
message string

A human readable message describing the error along with remediation steps where appropriate.

FileActionResponse

Name Path Type Description
File
result File

File.

Completed At
completedAt string

Time of completion of task.

Number of Errors
numErrors integer

Number of errors resulting from the task.

Requested At
requestedAt string

Timestamp of when the task was requested.

Started At
startedAt string

Timestamp of when the task was started.

Links
links object

Link to check the status of the requested task.

Errors
errors array of StandardError

Descriptive error messages.

Task ID
taskId string

ID of the requested task.

Status
status Status

Current status of the task.

CollectionResponseFolder

Name Path Type Description
Paging
paging Paging
results
results array of Folder

FileStat

Name Path Type Description
File
file File

File.

Folder
folder Folder

SignedUrl

Signed Url object with optional ancillary metadata of requested file.

Name Path Type Description
Extension
extension string

Extension of the requested file.

Size
size integer

Size in bytes of the requested file.

Name
name string

Name of the requested file.

Width
width integer

For image and video files. The width of the file.

Type
type string

Type of the file. Can be IMG, DOCUMENT, AUDIO, MOVIE, or OTHER.

Expires At
expiresAt string

Timestamp of when the URL will no longer grant access to the file.

URL
url string

Signed URL with access to the specified file. Anyone with this URL will be able to access the file until it expires.

Height
height integer

For image and video files. The height of the file.

PreviousPage

Name Path Type Description
Before
before string

The before.

Link
link string

The link.

ImportFromUrlTaskLocator

Information on the task that has been started, and where to check it's status.

Name Path Type Description
Links
links object

Links for where to check information related to the task. The status link gives the URL for where to check the status of the task.

ID
id string

ID of the task.

File

File.

Name Path Type Description
Extension
extension string

Extension of the file. ex: .jpg, .png, .gif, .pdf, etc.

Access
access Access

File access. Can be PUBLIC_INDEXABLE, PUBLIC_NOT_INDEXABLE, PRIVATE.

Parent Folder ID
parentFolderId string

ID of the folder the file is in.

Encoding
encoding string

Encoding of the file.

Type
type string

Type of the file. Can be IMG, DOCUMENT, AUDIO, MOVIE, or OTHER.

Is Usable In Context
isUsableInContent boolean

Previously "archived". Indicates if the file should be used when creating new content like web pages.

URL
url string

URL of the given file. This URL can change depending on the domain settings of the account. Will use the select file hosting domain.

Expires At
expiresAt integer

When expires at.

Created At
createdAt string

Creation time of the file object.

Archived At
archivedAt string

Deletion time of the file object.

Archived
archived boolean

If the file is deleted.

Path
path string

Path of the file in the file manager.

Size
size integer

Size of the file in bytes.

Name
name string

Name of the file.

Width
width integer

For image and video files, the width of the content.

ID
id string

File ID.

Default Hosting URL
defaultHostingUrl string

Default hosting URL of the file. This will use one of HubSpot's provided URLs to serve the file.

Updated At
updatedAt string

Timestamp of the latest update to the file.

Height
height integer

For image and video files, the height of the content.

NextPage

Name Path Type Description
Link
link string

The link.

After
after string

The after.

FolderUpdateTaskLocator

Information on the task that has been started, and where to check it's status.

Name Path Type Description
Links
links object

Links for where to check information related to the task. The status link gives the URL for where to check the status of the task.

ID
id string

ID of the task.

Access

File access. Can be PUBLIC_INDEXABLE, PUBLIC_NOT_INDEXABLE, PRIVATE.

File access. Can be PUBLIC_INDEXABLE, PUBLIC_NOT_INDEXABLE, PRIVATE.

Access
string

Status

Current status of the task.

Current status of the task.

Status
string