# `PgFlow.Migrations.Versions.V01`
[🔗](https://github.com/agoodway/pgflow/blob/v0.1.0/lib/pgflow/migrations/versions/v01.ex#L1)

PgFlow extensions migration version 1.

Creates PostgreSQL functions in the `pgflow` schema for:

## Read Functions
- `get_flow_input(uuid)` - Get flow run input data
- `flow_exists(text)` - Check if flow exists
- `get_step_output(uuid, text)` - Get step output

## Write Functions
- `register_worker(uuid, text, text)` - Register or heartbeat a worker
- `mark_worker_stopped(uuid)` - Mark worker as stopped
- `recover_stalled_tasks(double precision)` - Recover stalled tasks and reset visibility

# `down`

```elixir
@spec down(keyword()) :: :ok
```

Rolls back this version's migration by executing the down SQL file.

# `up`

```elixir
@spec up(keyword()) :: :ok
```

Applies this version's migration by executing the up SQL file.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
