---
title: "init(goal:alert:)"
framework: workoutkit
role: symbol
role_heading: Initializer
path: "workoutkit/workoutstep/init(goal:alert:)"
---

# init(goal:alert:)

Creates a new workout step with the provided goal and alerts.

## Declaration

```swift
init(goal: WorkoutGoal = .open, alert: (any WorkoutAlert)? = nil)
```

## Parameters

- `goal`: A goal that determines when the step ends.
- `alert`: Optional alerts used during the step.
