# AgentEntityInfo Constructors

- Package: [Aspire.Hosting.AgentFramework.DevUI](/reference/api/csharp/aspire.hosting.agentframework.devui.md)
- Type: [AgentEntityInfo](/reference/api/csharp/aspire.hosting.agentframework.devui/agententityinfo.md)
- Kind: `Constructors`
- Members: `1`

Describes an AI agent exposed by an agent service backend, used for entity discovery in DevUI.

## AgentEntityInfo(string, string?)

- Name: `Constructor(string, string?)`

Describes an AI agent exposed by an agent service backend, used for entity discovery in DevUI.

```csharp
public record AgentEntityInfo
{
    public AgentEntityInfo(
        string Id,
        string? Description = null)
    {
        // ...
    }
}
```

## Parameters

- `Id` (`string`)
  The unique identifier for the agent, typically matching the name passed to `AddAIAgent`.
- `Description` (`string?`) `optional`
  A short description of the agent's capabilities.

## Remarks

When added via [AgentFrameworkBuilderExtensions.WithAgentService(IResourceBuilder<DevUIResource>, IResourceBuilder<TSource>, IReadOnlyList<AgentEntityInfo>, string?)](/reference/api/csharp/aspire.hosting.agentframework.devui/agentframeworkbuilderextensions/methods.md#withagentservice-iresourcebuilder-devuiresource-iresourcebuilder-tsource-ireadonlylist-agententityinfo-string), agent metadata is declared at the AppHost level so that the DevUI aggregator can build the entity listing without querying each backend's `/v1/entities` endpoint.

Agent services only need to expose the standard OpenAI Responses and Conversations API endpoints ( `MapOpenAIResponses` and `MapOpenAIConversations`), not a custom discovery endpoint.
