# PipelineStepContext Properties

- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Type: [PipelineStepContext](/reference/api/csharp/aspire.hosting/pipelinestepcontext.md)
- Kind: `Properties`
- Members: `8`

Provides contextual information for a specific pipeline step execution.

## CancellationToken

- Name: `CancellationToken`
- Modifiers: `get`
- Returns: `CancellationToken`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs#L57)

Gets the cancellation token for the pipeline operation.

```csharp
public CancellationToken CancellationToken { get; }
```

## ExecutionContext

- Name: `ExecutionContext`
- Modifiers: `get`
- Returns: [DistributedApplicationExecutionContext](/reference/api/csharp/aspire.hosting/distributedapplicationexecutioncontext.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs#L42)

Gets the execution context for the distributed application.

```csharp
public DistributedApplicationExecutionContext ExecutionContext { get; }
```

## Logger

- Name: `Logger`
- Modifiers: `get`
- Returns: `ILogger`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs#L52)

Gets the logger for pipeline operations that writes to both the pipeline logger and the step logger.

```csharp
public ILogger Logger { get; }
```

## Model

- Name: `Model`
- Modifiers: `get`
- Returns: [DistributedApplicationModel](/reference/api/csharp/aspire.hosting/distributedapplicationmodel.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs#L37)

Gets the distributed application model to be deployed.

```csharp
public DistributedApplicationModel Model { get; }
```

## PipelineContext

- Name: `PipelineContext`
- Modifiers: `get; init`
- Returns: [PipelineContext](/reference/api/csharp/aspire.hosting/pipelinecontext.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs)

Gets the pipeline context shared across all steps.

```csharp
public PipelineContext PipelineContext { get; init; }
```

## ReportingStep

- Name: `ReportingStep`
- Modifiers: `get; init`
- Returns: [IReportingStep](/reference/api/csharp/aspire.hosting/ireportingstep.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs)

Gets the publishing step associated with this specific step execution.

```csharp
public IReportingStep ReportingStep { get; init; }
```

## Services

- Name: `Services`
- Modifiers: `get`
- Returns: `IServiceProvider`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs#L47)

Gets the service provider for dependency resolution.

```csharp
public IServiceProvider Services { get; }
```

## Summary

- Name: `Summary`
- Modifiers: `get`
- Returns: [PipelineSummary](/reference/api/csharp/aspire.hosting/pipelinesummary.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Pipelines/PipelineStepContext.cs#L74)

Gets the pipeline summary that steps can add information to. The summary will be displayed to users after pipeline execution completes.

```csharp
public PipelineSummary Summary { get; }
```

## Remarks

Pipeline steps can add key-value pairs to the summary to provide useful information about the pipeline execution, such as deployment targets, resource names, URLs, etc.

## Examples

```csharp
// In a pipeline step
context.Summary.Add("☁️ Target", "Azure");
context.Summary.Add("📦 Resource Group", "rg-myapp");
```
