arm-agent-base-type-child-resources
@azure-tools/typespec-azure-resource-manager/arm-agent-base-type-child-resourcesResources decorated with @azureBaseType for the Agent base type must have both a Conversation and a Response child resource.
Resources decorated with @azureBaseType for the Agent base type must have both a Conversation and a Response child resource.
Impact
Section titled “Impact”- Area: API, SDK
Agent base types must correctly model their child resources; violations can misrepresent the resource for emitters and tooling.
❌ Incorrect
Section titled “❌ Incorrect”@armProviderNamespacenamespace Microsoft.Contoso;
model MyAgentProperties is Azure.ResourceManager.BaseTypes.Agents.AgentPropertiesPlatform { ...DefaultProvisioningStateProperty;}
@azureBaseType(#{ baseType: BaseType.Agent, version: "2024-06-01" })model MyAgent is TrackedResource<MyAgentProperties> { ...ResourceNameParameter<MyAgent>;}✅ Correct
Section titled “✅ Correct”@armProviderNamespacenamespace Microsoft.Contoso;
model MyAgentProperties is Azure.ResourceManager.BaseTypes.Agents.AgentPropertiesPlatform { ...DefaultProvisioningStateProperty;}
model MyAgent is Agent<MyAgentProperties> { ...ResourceNameParameter<MyAgent>;}
model MyConversationProperties is Azure.ResourceManager.BaseTypes.Agents.ConversationProperties;
model MyConversation is AgentConversation<MyConversationProperties, MyAgent> { ...ResourceNameParameter<MyConversation>;}
model MyResponseProperties is Azure.ResourceManager.BaseTypes.Agents.ResponseProperties;
model MyResponse is AgentResponse<MyResponseProperties, MyAgent> { ...ResourceNameParameter<MyResponse>;}Suppression
Section titled “Suppression”Suppress only when required to match an existing API; otherwise use the standard agent base type patterns.