Event model
Every event follows this schema:Resources
Every event has a primary resource represented as a set of string key-value labels. Every resource must includeprefect.resource.id, a dot-delimited quasi-stable identifier like
prefect.flow-run.e3755d32-cec5-42ca-9bcd-af236e308ba6. Resources may also carry
prefect.resource.name and any number of additional labels.
Related resources
Events may include related resources that provide context about other objects involved. Each related resource carries all the same labels as a resource, plus a requiredprefect.resource.role label describing its relationship to the event (for example, flow,
deployment, work-pool, or tag).
Namespace conventions
Prefect uses dot-delimited event names with reserved prefixes for system-emitted events:
The
prefect.* and prefect-cloud.* namespaces are reserved for events emitted
by Prefect itself. Your own events can use any other namespace you like. For
example, acme.data-pipeline.completed or myteam.model.trained are perfectly
valid event names. See custom event grammar
for more on emitting your own events.