We have an integration between HubSpot and a e-signing tool that suddenly breaks when searching for a folder.
GET https://api.hubapi.com/files/v3/folders/search?name=Scrive%20Signed
Response: {“status”:“error”,“message”:“Invalid search query”,“correlationId”:“626354cd-9572-4575-a3d0-dfc5385625e4”,“category”:“VALIDATION_ERROR”}
It works in our test-environments, but for some customers it suddenly stopped working.
The customers have proper scopes to access file and folder.
Any ideas?
These are the scopes of a failing account that performs a search:
“oauth”,
“files”,
“crm.lists.read”,
“crm.objects.contacts.read”,
“crm.objects.contacts.write”,
“files.ui_hidden.read”,
“crm.schemas.custom.read”,
“crm.objects.companies.write”,
“crm.schemas.contacts.read”,
“crm.lists.write”,
“crm.objects.companies.read”,
“crm.objects.deals.read”,
“crm.objects.deals.write”,
“crm.schemas.companies.read”,
“crm.schemas.companies.write”,
“crm.schemas.contacts.write”,
“crm.schemas.deals.read”,
“crm.schemas.deals.write”,
“crm.objects.owners.read”,
“crm.objects.quotes.read”
The difference from an account that don’t fail is that the failing account have two more scopes:
“crm.lists.write” and “crm.lists.read”
Could that have something to do with this?
From my understanding, it looks like @GRajput’s suggestion may have been helpful here! If you’re still looking for assistance after looking into their insight on the matter, then I may suggest creating a new post highlighting the endpoint and what specific errors you’re seeing on you end.
Hi @SamTassey ,
Thanks for the reply, I’ve just follow @GRajput suggestion and still face the same problem, and also I’ve created the new post regarding this on this link
Are you able to confirm if your Headers reflect whats seen in the example requests here? Accounts Dashboard | HubSpot
Would you mind sharing an example request that failed? Once we have this, that should give our Community what they need to better assist!
"This endpoint /files/v3/folders/search does not support searching by name as a query parameter. The endpoint only accepts a structured search body (POST-style search), and passing ?name=… can result in a VALIDATION_ERROR in some portals, even if it previously appeared to work.
Older portals or internal routing sometimes tolerated unsupported query parameters. HubSpot has been tightening validation on Files APIs, so stricter portals now reject invalid query shapes. This is not a scopes or permission issue.
I hope this will help you out. Please mark it as Solution Accepted and upvote to help another Community member.
Thanks!
Use the POST search endpoint with a JSON body, not query params."