# AtsDiagnostic Methods

- Package: [Aspire.TypeSystem](/reference/api/csharp/aspire.typesystem.md)
- Type: [AtsDiagnostic](/reference/api/csharp/aspire.typesystem/atsdiagnostic.md)
- Kind: `Methods`
- Members: `3`

Represents a diagnostic message from the ATS capability scanner.

## Error(string, string?)

- Name: `Error(string, string?)`
- Modifiers: `static`
- Returns: [AtsDiagnostic](/reference/api/csharp/aspire.typesystem/atsdiagnostic.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.TypeSystem/AtsCapabilityInfo.cs#L162)

Creates an error diagnostic.

```csharp
public sealed class AtsDiagnostic
{
    public static AtsDiagnostic Error(
        string message,
        string? location = null)
    {
        // ...
    }
}
```

## Parameters

- `message` (`string`)
- `location` (`string?`) `optional`

## Info(string, string?)

- Name: `Info(string, string?)`
- Modifiers: `static`
- Returns: [AtsDiagnostic](/reference/api/csharp/aspire.typesystem/atsdiagnostic.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.TypeSystem/AtsCapabilityInfo.cs#L174)

Creates an info diagnostic (verbose output shown with --debug).

```csharp
public sealed class AtsDiagnostic
{
    public static AtsDiagnostic Info(
        string message,
        string? location = null)
    {
        // ...
    }
}
```

## Parameters

- `message` (`string`)
- `location` (`string?`) `optional`

## Warning(string, string?)

- Name: `Warning(string, string?)`
- Modifiers: `static`
- Returns: [AtsDiagnostic](/reference/api/csharp/aspire.typesystem/atsdiagnostic.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.TypeSystem/AtsCapabilityInfo.cs#L168)

Creates a warning diagnostic.

```csharp
public sealed class AtsDiagnostic
{
    public static AtsDiagnostic Warning(
        string message,
        string? location = null)
    {
        // ...
    }
}
```

## Parameters

- `message` (`string`)
- `location` (`string?`) `optional`
