Query parameters
ParameterDescription
objectId
string
optionalObject Id is required
objectType
string
optionalObject Type is optional. For Hubspot value must be one of CONTACT, TICKET, COMPANY, DEAL. Required to list Hubspot attachments.
Header parameters
ParameterDescription
Authorization
string
optionalReplace the API_Key placeholder with your actual API key.

Request body

{
  "resource": "{{resource-id}}",
  "resourceType": "folder",
  "source": "HUBSPOT",
  "objectType": "CONTACT",
  "objectId": "51"
}

Example request

curl --request GET \
     --url 'https://api.cloudfiles.io/v1/attachments?objectId=string&objectType=string' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --header 'authorization: Bearer API_Key' \
     --data '"{\n  \"resource\": \"{{resource-id}}\",\n  \"resourceType\": \"folder\",\n  \"source\": \"HUBSPOT\",\n  \"objectType\": \"CONTACT\",\n  \"objectId\": \"51\"\n}"'
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
myHeaders.append("authorization", "Bearer API_Key");

var raw = JSON.stringify("{\n  \"resource\": \"{{resource-id}}\",\n  \"resourceType\": \"folder\",\n  \"source\": \"HUBSPOT\",\n  \"objectType\": \"CONTACT\",\n  \"objectId\": \"51\"\n}");

var requestOptions = {
   method: 'GET',
   headers: myHeaders,
   body: raw,
   redirect: 'follow'
};

fetch("https://api.cloudfiles.io/v1/attachments?objectId=string&objectType=string", requestOptions)
   .then(response => response.text())
   .then(result => console.log(result))
   .catch(error => console.log('error', error));
require "uri"
require "json"
require "net/http"

url = URI("https://api.cloudfiles.io/v1/attachments?objectId=string&objectType=string")

https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true

request = Net::HTTP::Get.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
request["authorization"] = "Bearer API_Key"
request.body = JSON.dump("{\n  \"resource\": \"{{resource-id}}\",\n  \"resourceType\": \"folder\",\n  \"source\": \"HUBSPOT\",\n  \"objectType\": \"CONTACT\",\n  \"objectId\": \"51\"\n}")

response = https.request(request)
puts response.read_body
import requests
import json

url = "https://api.cloudfiles.io/v1/attachments?objectId=string&objectType=string"

payload = json.dumps("{\n  \"resource\": \"{{resource-id}}\",\n  \"resourceType\": \"folder\",\n  \"source\": \"HUBSPOT\",\n  \"objectType\": \"CONTACT\",\n  \"objectId\": \"51\"\n}")
headers = {
   'accept': 'application/json',
   'content-type': 'application/json',
   'authorization': 'Bearer API_Key'
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)

Response body

[
  {
    "id": "att_123",
    "type": "external",
    "objectId": "deal_456",
    "objectType": "hubspot_deal",
    "createdAt": "2026-07-05T10:00:00Z",
    "createdBy": "usr_1"
  },
  {
    "id": "att_124",
    "type": "internal",
    "objectId": "fld_789",
    "objectType": "folder",
    "createdAt": "2026-07-06T11:00:00Z",
    "createdBy": "usr_2"
  }
]