# LibTmux.Server.Chain

- **Module:** LibTmux.Server
- **Package:** LibTmux
- **Language:** .NET
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-dotnet/blob/6656a563ec9e07ab52e0c3ac96f7704fc94cc0c0/src/LibTmux/Server.Chaining.cs#L17
- **Page:** https://libtmux.org/reference/dotnet/libtmux-server-chain/

```
LibTmux.Server.Chain() -> TmuxChain
```

Begins a chain that runs its commands in one tmux invocation.

This is the batched counterpart to the one-shot methods. Which one is
in use is visible where the call starts rather than in an option, and
nothing runs until the chain is executed.

## Returns

An empty chain bound to this server.

## Raises

- `InvalidOperationException` — The handle has no connection.
