# LibTmux.ConfirmBeforeRequest.ToCommand

- **Module:** LibTmux
- **Package:** LibTmux
- **Language:** C#
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-dotnet/blob/cf34b255c896d19a97e7d7fabea58609c916012d/src/LibTmux/Requests/ConfirmBeforeRequest.cs#L46
- **Page:** https://libtmux.org/en/csharp/latest/reference/libtmux-confirmbeforerequest-tocommand/

```
LibTmux.ConfirmBeforeRequest.ToCommand(server: Server) -> TmuxCommand
```

Returns a confirmation request as one tmux command.

Naming the accepting key, and defaulting to yes, arrived in tmux 3.4,
so the server decides whether the built command carries them.

## Parameters

- `server` (`Server`): The server the confirmation is shown on.

## Returns

The command, ready to add to a <see cref="TmuxChain" />.

## Raises

- [`ArgumentNullException`](https://learn.microsoft.com/dotnet/api/system.argumentnullexception): <paramref name="server" /> is null.
