---
title: task
sidebarTitle: task
---

# `prefect.cli.task`

## Functions

### `serve` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/cli/task.py#L33" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>

```python
serve(entrypoints: Optional[list[str]] = typer.Argument(None, help='The paths to one or more tasks, in the form of `./path/to/file.py:task_func_name`.'), module: Optional[list[str]] = typer.Option(None, '--module', '-m', help='The module(s) to import the tasks from.'), limit: int = typer.Option(10, help='The maximum number of tasks that can be run concurrently. Defaults to 10.'))
```


Serve the provided tasks so that their runs may be submitted to and
executed in the engine.

**Args:**
- `entrypoints`: List of strings representing the paths to one or more
tasks. Each path should be in the format
`./path/to/file.py\:task_func_name`.
- `module`: The module(s) to import the task definitions from.
- `limit`: The maximum number of tasks that can be run concurrently. Defaults to 10.

