Hello, I'm working on integration with service called Jog.ai and right now I'm preparing a feature that will allow to fetch calls made using HubSpot and create easily readable transcripts using them.
To get a list of calls we use
GET /engagements/v1/engagements/recent/modified or
GET /engagements/v1/engagements/paged, it's not very convenient, because there are no filtering, so all types of engagements are returned (not just calls), but I can live with that.
We want to limit calls that are fetched to only those that were made by particular user which installed integration. My problem is that those endpoints return all calls that were made in a HubSpot portal. There is no direct way to filter those that belong or were made by particular user.
However, I see a correlation between data returned by following endpoints:
GET /oauth/v1/access-tokens/:token - only way that I know, to identify user,
user_id is probably what I need
GET /owners/v2/owners/ - I'm planning to exchange
user_id for an
ownerId using this endpoint, I've noticed that
remoteId corresponds with user ids returned by token information endpoint.
GET /engagements/v1/engagements/paged - knowing
ownerId I can filter results
Do you think it's a good way to go? If yes, I have couple of questions:
- I don't know if
ownerIdis prone to be changed or I can store it in my database to use it later?
- I have no idea if user will always have corresponding
GET /owners/v2/owners/be empty?
remoteListmust be of type
- Maybe it would be better to use
user_idwhen looking for
emailsmust be unique for a portal?
- I don't know if I can rely on
owner_idin engagement? Is it possible to have engagement with empty
- Any plans for adding filtering on engagements list?
I'm asking for your expertise. I hope with your help I will be able to deliver new and exciting integration that you might find useful.