> ## Documentation Index
> Fetch the complete documentation index at: https://anaconda.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# prj.publish_event

Publish an event from a project flow.

```python theme={null}
prj.publish_event(name, payload=None)
```

Publish an event to trigger flows decorated with `@project_trigger`.

Parameter

Type

Description

`name`

str

Event name (must match the `event=` in a `@project_trigger`)

`payload`

dict

JSON-serializable payload

Events are namespaced as `prj.{project}.{branch}.{name}`, so events published on one branch only trigger flows deployed on the same branch.

```python theme={null}
self.prj.publish_event("model_trained", payload={"accuracy": 0.95})
```
