# TerminalContext

- Kind: `class`
- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Version: `13.6.0`
- Namespace: `Aspire.Hosting`
- Target framework: `net10.0`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/f4c27f2d43ddc1cacd0dd083b30d1fea1cee7a62/src/Aspire.Hosting/IInteractionService.cs)

Provides cancellation to the work callback of a terminal interaction.

## Definition

```csharp
namespace Aspire.Hosting;

public sealed class TerminalContext
{
    // ...
}
```

## Constructors

- [TerminalContext](/reference/api/csharp/aspire.hosting/terminalcontext/constructors.md#constructor)

## Properties

- [CancellationToken](/reference/api/csharp/aspire.hosting/terminalcontext/properties.md#cancellationtoken) : `CancellationToken` `get; init` -- Gets the token signaled when the user requests cancellation or the interaction is externally canceled.
