Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(hubspot): Add new attributes to hubspot integration model #2662

Merged
merged 6 commits into from
Oct 9, 2024

Conversation

brunomiguelpinto
Copy link
Contributor

@brunomiguelpinto brunomiguelpinto commented Oct 4, 2024

Context

The goal of this change is the deployment of custom properties and objects in HubSpot when a new integration is created via Lago. Specifically, we need to create the necessary fields for both native HubSpot objects (Companies and Contacts) and create custom objects (Subscriptions and Invoices) in the user's HubSpot account.

Description

This PR introduces a new job, SyncCustomObjectsAndPropertiesJob, which orchestrates the setup of custom objects and property synchronization in HubSpot when a new integration is created via Lago. The job does not handle sending the actual records, and this will be addressed in a future PR.

version control has been implemented to track the deployment state of these objects and properties. This allows us to know what has been deployed and to trigger a sync when sending new records if the schema has been updated.

@brunomiguelpinto brunomiguelpinto force-pushed the feat-sync-hubspot-custom-objects branch 3 times, most recently from f5b3686 to 4d9cf97 Compare October 4, 2024 18:12
@brunomiguelpinto brunomiguelpinto marked this pull request as ready for review October 4, 2024 19:06
@ivannovosad ivannovosad force-pushed the feat-sync-hubspot-custom-objects branch 3 times, most recently from 5d692a4 to 375e743 Compare October 9, 2024 06:36
Copy link
Contributor

@ivannovosad ivannovosad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving this now, but lets discuss some refactoring ideas later:
We can move DeployPropertiesService and DeployObjectService (for multiple types) under Aggregator namespace since they all extend Integrations::Aggregator::BaseService

@ivannovosad ivannovosad force-pushed the feat-sync-hubspot-custom-objects branch from 375e743 to eead777 Compare October 9, 2024 08:11
@ivannovosad ivannovosad merged commit f02d6fe into main Oct 9, 2024
6 checks passed
@ivannovosad ivannovosad deleted the feat-sync-hubspot-custom-objects branch October 9, 2024 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants