Workflow Enrollment Date

contacts

#1

Does anyone know if the Workflow Enrollment Date is saved when enrolling a contact? Where can I access it through the Web API?


#2

Hi @aj.smith,

The date a contact is enrolled in a particular workflow isn’t stored in a contact property; instead, you can make a request to the current enrollment endpoint. The request takes a contact’s vid and returns the JSON for the workflows that the contact is currently enrolled in.


#3

Thanks Derek. I am using this endpoint in my project, but it does not contain the date that the contact was enrolled into the workflow. Hubspot’s website shows this information so I am assuming it is being stored somewhere. Is there an endpoint that would return this date?


#4

Hi @aj.smith,

I understand, thank you for clarifying! You can use the Log events endpoint to get a workflow’s log events. You can filter these events by type and/or vid to limit the results. In your case, you could make a request like this:

PUT https://api.hubspot.com/automation/v3/logevents/workflows/:workflowId/filter

With the following filter JSON:

{
“vid”: 34,
“types”: [
“ENROLLED”
]
}


#5

This is great stuff Derek, I didn’t realize that I can pull the timestamp from this. Thanks!