[HubSpot] "Something went wrong" for all commands except "List communications"
Extension
https://www.raycast.com/harisvsulaiman/hubspot
Description
Error:
TypeError: Cannot read properties of null (reading 'value')
lk:index.js:6:32649
index.js:6:32496
at Array.map (<anonymous>)
pi:index.js:6:32489
Full back trace was too long. Gist here: https://gist.githubusercontent.com/scoop/2847b096d01f59aab66e8fd25c2cd238/raw/32f397322f135a2d00b54f4a14907211653bfee5/gistfile1.txt
Steps To Reproduce
- Created Private App
- Configured Access Token in Extension
- Ran any command (I don't even get to specify a search string for "Search contacts" for example)
- The only command that works and lists content is the "List communications" command.

We're on a CRM Hub Professional plan, the instance is set to German in case that changes anything. I have not seen any change in API behavior with our other integrations though.
Current Behaviour
HubSpot results are shown
Expected Behaviour
An error message is shown. Happy to help troubleshoot this with dev builds etc.
Thank you for opening this issue!
🔔 @harisvsulaiman @pernielsentikaer you might want to have a look.
PS: You can close this issue once resolved by posting @raycastbot close this issue.
@harisvsulaiman do you have a clue here?
@pernielsentikaer I'm a bit busy right now. I'll take a look at it soon
This issue has been automatically marked as stale because it did not have any recent activity.
It will be closed if no further activity occurs in the next 10 days to keep our backlog clean 😊
This issue has been automatically closed due to inactivity.
Feel free to comment in the thread when you're ready to continue working on it 🙂
You can also catch us in Slack if you want to discuss this.
I found the root cause. I had a call in my HubSpot instance originating from a Zoom meeting. This particular call didn't have a number associated with it. To safeguard against this situation you can use the following patch in your extension:
commit 703225a39c9d11e6d1979dc9b2b2de436fdcbf43
Author: Patrick Lenz <[email protected]>
Date: Wed Sep 27 14:14:04 2023 +0200
Safeguard calls without a phone number
diff --git a/src/calls.tsx b/src/calls.tsx
index 5934da7..506927e 100644
--- a/src/calls.tsx
+++ b/src/calls.tsx
@@ -29,7 +29,7 @@ export default function Command() {
<List.Item.Detail.Metadata.Label title="Title" text={hs_call_title} />
<List.Item.Detail.Metadata.Label title="Status" text={hs_call_status} />
<List.Item.Detail.Metadata.Label title="Created" text={new Date(createdate).toLocaleString()} />
- <List.Item.Detail.Metadata.Label title="To Number" text={hs_call_to_number} />
+ <List.Item.Detail.Metadata.Label title="To Number" text={hs_call_to_number || ''} />
</List.Item.Detail.Metadata>
}
/>
@scoop Can you submit a pr?
@scoop Can you submit a pr?
Done. https://github.com/raycast/extensions/pull/8594