HubSpot technical integration guide
For HubSpot administrators, security reviewers and IT — how both Revial HubSpot apps authenticate, API consumption, the call-analysis pipeline, failure behaviour and auditing.
This guide describes what Revial does inside your HubSpot account, so you can approve, configure and later audit the integration. For connecting see Connecting Revial to HubSpot; for every property read and written, and each app's scopes, see What Revial syncs with HubSpot.
1. What you are approving
Revial uses two separate HubSpot apps, each with its own client ID, token and scopes:
| Property | HubSpot CRM app | HubSpot Calls app |
|---|---|---|
| Purpose | Sync CRM records; write summaries, mapped properties and deals | Analyse calls logged in HubSpot |
| APIs | CRM v3 objects, search, pipelines, properties; v4 associations | CRM v3 calls and owners; calling extensions transcripts |
| Protocol | OAuth 2.0 authorisation code | OAuth 2.0 authorisation code |
| Access model | Delegated — acts as the installing user | Delegated — acts as the installing user |
| Writes to HubSpot | Yes (see the data page, section 9) | None today |
2. What your admin has to do
| Situation | What to do |
|---|---|
| Your account restricts app installs | Have a user with install rights connect |
| You want a dedicated integration user | Create it with the visibility Revial should have, and connect as that user |
| You use call analysis | Connect the Calls app and map owners to Revial users |
| You want Revial to write properties | Create them in HubSpot, then map them in Revial |
Webhook subscriptions for the Calls app are configured once in Revial's HubSpot app; there is nothing to set up in your account.
3. Authentication and token model
Both apps use the same endpoints:
| Property | Value |
|---|---|
| Authorise | https://app.hubspot.com/oauth/authorize |
| Token | https://api.hubapi.com/oauth/v1/token |
| Token check | https://api.hubapi.com/oauth/v1/access-tokens/{token} — records portal ID, user ID and user email |
| Revoke | DELETE https://api.hubapi.com/oauth/v1/refresh-tokens/{token} |
| PKCE | Not used |
| Access token lifetime | 30 minutes; a new refresh token is returned on each refresh |
State. A random state, valid for five minutes and bound to the Revial user;
the callback re-checks the user's admin role. The Calls app consumes its state
before continuing, so each state can be used only once.
Storage. Access and refresh tokens are encrypted at rest (AES-256-GCM) and never sent to the browser.
Refresh failures. A 401 or invalid_grant is permanent. For the CRM app the
connection is marked as needing re-authorisation and an organisation admin is
notified; the hourly sync skips it. For the Calls app, queued calls for that
connection are dropped until it is reconnected.
Who may connect on the Revial side. An organisation owner or admin on a plan with the CRM integration; rate-limited. One CRM app connection and one Calls app connection per organisation. A portal can be connected to only one organisation's Calls app.
4. The installing user
Everything happens as the installing user. Records that user cannot see do not reach Revial, and notes and deals Revial creates are created by that user's token. Which HubSpot roles may install apps is set in your HubSpot account.
5. Sync cadence and API consumption (CRM app)
- Cadence: roughly every hour, starting immediately after connecting.
- First sync: list API, 100 records per page, up to 50,000 per object type.
- Later syncs: search API filtered by last-modified date, 100 per page (HubSpot caps search results at 10,000 per query).
- Activities: up to 3,000 per sync; a larger backlog continues on later syncs from where it stopped.
- Associations: batch reads of 100 for activities; one request per changed deal.
- Deletions: only deleted (archived) deals are detected and removed.
- Rate limiting: about 3 requests per second per worker. 429 responses wait
for
Retry-After(2 seconds if absent) and 5xx responses back off exponentially, up to 3 retries; requests time out after 30 seconds. - Per run: 5 pages per job run, continuing automatically.
6. The call-analysis pipeline (Calls app)
- Webhook — HubSpot notifies Revial when a call is created or its recording
link changes. Revial verifies the
X-HubSpot-Signature-v3HMAC with the app secret and rejects requests older than five minutes. Events for unknown portals are ignored. - Queue — each call is queued; a lock per portal and call ID ensures it is processed once.
- Owner check — calls with no owner, or an unmapped or excluded owner, are skipped.
- Recording — Revial fetches the recording (up to 500 MB, 10-minute timeout, HTTPS only; the token is sent only to HubSpot hosts) or, where the recording is not fetchable, HubSpot's own transcript. Which source works is remembered per portal.
- Storage and transcription — recordings are stored in Revial's EU storage and deleted after 365 days. Where an organisation has recordings deleted as soon as the transcript exists, the audio is removed at that point instead. Audio is transcribed by Revial's transcription provider, which deletes its copy after processing.
- Meeting — a Revial meeting is created for the mapped user and analysed.
If a recording is not attached yet, the call is retried a few times and then dropped without creating a meeting. Such a call leaves no trace in Revial — if a call you expected to be analysed never appears, contact support.
7. Field mappings (CRM app)
Admins map Revial summary fields and custom extraction fields to properties on
contacts, companies, deals and meetings under Organization → CRM Settings →
Property Mapping. Properties are listed with the crm.schemas.*.read scopes.
Conversion and overwrite rules are on the data page, section 9.3.
8. Meeting-to-CRM matching
First match wins: direct IDs on the meeting; the open deal it is already linked to; attendee emails → contacts → their deals (scored); company by website or email domain; company by name. Scoring favours open deals, the attendee being the primary contact, other attendees on the deal, title similarity, later stages and recency. Closed deals are excluded; free-email domains are ignored for company matching.
9. Security, limits and failure behaviour
- Separate apps: call analysis can be granted without CRM write access, and vice versa.
- Secrets: tokens encrypted at rest; only connection status is exposed to the browser.
- Webhook integrity: signature v3 with a five-minute replay window.
- Recording download safety: redirect and private-address checks on every hop.
- Data storage: synced records and raw API responses are stored in Revial and deleted when the CRM app is disconnected.
10. Auditing and disconnecting
In HubSpot: Connected apps in your account settings lists both Revial apps and lets you uninstall them; records Revial creates show the installing user.
Disconnecting the CRM app in Revial deletes Revial's synced copy, tokens and field mappings. It does not revoke the token — uninstall the app in HubSpot to end the grant.
Disconnecting the Calls app in Revial revokes the refresh token in HubSpot, removes owner mappings and ignores further webhooks from the portal. Meetings already created, and stored recordings until their 365-day expiry, remain.
11. Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
| Records missing after sync | Installing user's visibility | Connect as a user who sees them |
| "CRM: Authentication expired" | App uninstalled or access revoked | Connect again |
| Calls not analysed | Owner not mapped, call has no owner, or no recording yet | Map the owner; check the call has a recording |
| "Failed to connect HubSpot Calls" | Portal already connected to another organisation, or sign-in failed | Contact support |
| Calls card shows an error | Calls token revoked | Reconnect |
| Deleted company still in Revial | Only deal deletions are detected | Expected |
What Revial syncs with HubSpot
For your HubSpot administrator and whoever reviews the integration's data access — every HubSpot field Revial reads, everything it writes back, and what is deliberately left out.
Connecting Revial to Pipedrive
For your Pipedrive administrator and whoever signs off on the integration's data access — who authorises, scopes, what Revial reads and writes, and what it deliberately does not do.