# AzurePublishingContext Constructors

- Package: [Aspire.Hosting.Azure](/reference/api/csharp/aspire.hosting.azure.md)
- Type: [AzurePublishingContext](/reference/api/csharp/aspire.hosting.azure/azurepublishingcontext.md)
- Kind: `Constructors`
- Members: `1`

Represents a context for publishing Azure bicep templates for a distributed application.

## AzurePublishingContext(string, AzureProvisioningOptions, IServiceProvider, ILogger, IReportingStep)

- Name: `Constructor(string, AzureProvisioningOptions, IServiceProvider, ILogger, IReportingStep)`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/cbc352350f1a9bafbaff10d14a2c8de4ac186a48/src/Aspire.Hosting.Azure/AzurePublishingContext.cs#L28-L74)

Represents a context for publishing Azure bicep templates for a distributed application.

```csharp
public sealed class AzurePublishingContext
{
    public AzurePublishingContext(
        string outputPath,
        AzureProvisioningOptions provisioningOptions,
        IServiceProvider serviceProvider,
        ILogger logger,
        IReportingStep reportingStep)
    {
        // ...
    }
}
```

## Parameters

- `outputPath` (`string`)
- `provisioningOptions` ([AzureProvisioningOptions](/reference/api/csharp/aspire.hosting.azure/azureprovisioningoptions.md))
- `serviceProvider` (`IServiceProvider`)
- `logger` (`ILogger`)
- `reportingStep` (`IReportingStep`)

## Remarks

This context facilitates the generation of bicep templates using the provided application model, publisher options, and execution context. It handles resource configuration and ensures that the bicep template is created in the specified output path.
