# TraceSpanKind

> Tracon documentation. Tracon is a .NET package family that adds a control
> plane on Microsoft Agent Framework, published as NuGet packages that run
> inside your own ASP.NET Core application.
>
> Page: https://tracon.dev/api/tracon.tracespankind/
> Summary: TraceSpanKind: A span's OpenTelemetry kind. Values are stored in the database as smallint; the numbers are stable.

<div class="api-provenance">Namespace Tracon · Assembly <code>Tracon.Abstractions.dll</code></div>

A span's OpenTelemetry kind. Values are stored in the database as
`smallint`; the numbers are stable.

```csharp
[JsonConverter(typeof(JsonStringEnumConverter<TraceSpanKind>))]
public enum TraceSpanKind
```

## Fields

`Client = 2` 

The span making an outgoing call.

`Consumer = 4` 

The span consuming a message.

`Internal = 0` 

An internal operation. The default.

`Producer = 3` 

The span producing a message.

`Server = 1` 

The span handling an incoming request.

## Remarks

Follows `Diagnostics.ActivityKind`'s order exactly. We
carry our own enum because `Tracon.Abstractions` must not leak the
`System.Diagnostics.DiagnosticSource` type into its public surface.
