I’m using Frame.io API V4 and have a custom metadata select field called “Status” (stored under Essentials).
When the Status value changes (e.g., from “In Progress” to “Approved”), I need to determine:
- Which user made the change
- When it was changed
Is this available via the V4 API?
Hi @Wuzza1122 ! You can create a webhook to listen for field changes. Since Status is an essential field, when creating a webhook, you’ll want to use the metadata.value.updated event. Note that webhooks apply to the whole workspace and cannot be specified for a specific field at this time. The webhook will trigger when any metadata field is updated, so you’ll have to check the payload for “Status”.
Here is what’s in the payload when a webhook is fired using metadata.value.updated:
{
"account":{
"id":"b35fe72e-7b65-42f2-b4cb-eac3021b98df"
},
"metadata":{
"field_definition_id":"3f03b4e1-7010-4f27-9076-51c7608176c8",
"field_name":"Status",
"field_type":"select",
"value":[
"Approved"
],
"value_id":[
"57748eba-d578-464c-92ec-fd31f6798466"
]
},
"project":{
"id":"cdde38e7-2564-4772-bdac-44dd556c1ff3"
},
"resource":{
"id":"9561543a-d5a7-4ab6-ae43-ce087ab67fa6",
"type":"file"
},
"type":"metadata.value.updated",
"user":{
"id":"6f1a90ca-68ee-43dc-a24a-adcc7b872ad2"
},
"workspace":{
"id":"3d27c095-c0ab-4cf2-bb59-e8d6507b0b35"
}
}
You can use user[“id”] to then make a call to look up that user. There’s no timestamp included in the webhook payload, but you can use the timestamp of when it was received.