Documentation
¶
Overview ¶
internal/temporal/workflows/price_sync.go
Index ¶
- Constants
- func HubSpotDealSyncWorkflow(ctx workflow.Context, input models.HubSpotDealSyncWorkflowInput) error
- func HubSpotInvoiceSyncWorkflow(ctx workflow.Context, input models.HubSpotInvoiceSyncWorkflowInput) error
- func HubSpotQuoteSyncWorkflow(ctx workflow.Context, input models.HubSpotQuoteSyncWorkflowInput) error
- func PriceSyncWorkflow(ctx workflow.Context, in models.PriceSyncWorkflowInput) (*dto.SyncPlanPricesResponse, error)
- func TaskProcessingWorkflow(ctx workflow.Context, input models.TaskProcessingWorkflowInput) (*models.TaskProcessingWorkflowResult, error)
Constants ¶
const ( // Workflow name - must match the function name WorkflowHubSpotDealSync = "HubSpotDealSyncWorkflow" // Activity names - must match the registered method names ActivityCreateLineItems = "CreateLineItems" ActivityUpdateDealAmount = "UpdateDealAmount" )
const ( // Workflow name - must match the function name WorkflowHubSpotInvoiceSync = "HubSpotInvoiceSyncWorkflow" // Activity names - must match the registered method names ActivitySyncInvoiceToHubSpot = "SyncInvoiceToHubSpot" )
const ( // Workflow name - must match the function name WorkflowHubSpotQuoteSync = "HubSpotQuoteSyncWorkflow" // Activity name - must match the registered method name ActivityCreateQuoteAndLineItems = "CreateQuoteAndLineItems" )
const ( // Workflow name - must match the function name WorkflowPriceSync = "PriceSyncWorkflow" // Activity name - must match the registered method name (just "SyncPlanPrices") ActivitySyncPlanPrices = "SyncPlanPrices" )
const ( // Workflow name - must match the function name WorkflowTaskProcessing = "TaskProcessingWorkflow" // Activity names - must match the registered method names ActivityProcessTask = "ProcessTask" )
Variables ¶
This section is empty.
Functions ¶
func HubSpotDealSyncWorkflow ¶ added in v1.0.34
func HubSpotDealSyncWorkflow(ctx workflow.Context, input models.HubSpotDealSyncWorkflowInput) error
HubSpotDealSyncWorkflow orchestrates the HubSpot deal synchronization process Steps: 1. Create line items in HubSpot deal 2. Sleep for 10 seconds to allow HubSpot to recalculate ACV 3. Update deal amount with the calculated ACV
func HubSpotInvoiceSyncWorkflow ¶ added in v1.0.35
func HubSpotInvoiceSyncWorkflow(ctx workflow.Context, input models.HubSpotInvoiceSyncWorkflowInput) error
HubSpotInvoiceSyncWorkflow orchestrates the HubSpot invoice synchronization process Steps: 1. Sleep for 5 seconds to allow invoice to be committed to database 2. Sync invoice to HubSpot (create invoice, line items, associate to contact, update properties, set status)
func HubSpotQuoteSyncWorkflow ¶ added in v1.0.42
func HubSpotQuoteSyncWorkflow(ctx workflow.Context, input models.HubSpotQuoteSyncWorkflowInput) error
HubSpotQuoteSyncWorkflow orchestrates the HubSpot quote synchronization process Steps: 1. Create quote in HubSpot and attach line items
func PriceSyncWorkflow ¶ added in v1.0.23
func PriceSyncWorkflow(ctx workflow.Context, in models.PriceSyncWorkflowInput) (*dto.SyncPlanPricesResponse, error)
func TaskProcessingWorkflow ¶ added in v1.0.27
func TaskProcessingWorkflow(ctx workflow.Context, input models.TaskProcessingWorkflowInput) (*models.TaskProcessingWorkflowResult, error)
TaskProcessingWorkflow processes a task asynchronously
Types ¶
This section is empty.