Interface IAgentFactory

Namespace: System.Agents

Defines the contract for agent factories used to create and configure agents in the system. Implementations of this interface provide metadata and configuration logic required during agent setup.

Remarks

Implementations must handle agent creation lifecycle, including initial setup pages and capability validation. Integrates with Copilot Capability system for permission management and feature availability. Used by the agent framework to instantiate and configure new agent instances.

Methods

GetDefaultInitials

Returns the initials to be displayed on the icon triggering the agent setup.

procedure GetDefaultInitials(): Text[4]

Returns

Type Description
Text[4]

The initials.

GetFirstTimeSetupPageId

Returns the ID of the page that is used to configure the agent the first time.

procedure GetFirstTimeSetupPageId(): Integer

Returns

Type Description
Integer

The first time setup page ID.

Remarks

The source table of the page must contain a field named "User Security ID" of type Guid. This field is used by the runtime to provide the agent user ID when the page is opened.

ShowCanCreateAgent

Specifies whether the capability to create new agents should be shown in the UI.

procedure ShowCanCreateAgent(): Boolean

Returns

Type Description
Boolean

True if the agent creation capability should be shown in the UI, false otherwise.

Remarks

This does not prevent new agents from being created programmatically.

GetCopilotCapability

Returns the Copilot Capability value for the agent. The capability is used to determine whether agents of this type are allowed to run.

procedure GetCopilotCapability(): Enum "Copilot Capability"

Returns

Type Description
Enum System.AI."Copilot Capability"

The copilot capability value.

GetDefaultProfile

Get the agent default profile used when a new agent is created.

procedure GetDefaultProfile(var TempAllProfile: Record "All Profile" temporary)

Parameters

Name Type Description
TempAllProfile Table System.Reflection."All Profile"

The default profile.

GetDefaultAccessControls

Get the agent default access controls to be used when a new agent is created.

procedure GetDefaultAccessControls(var TempAccessControlBuffer: Record "Access Control Buffer" temporary)

Parameters

Name Type Description
TempAccessControlBuffer Table System.Security.AccessControl."Access Control Buffer"

The default access controls.

See also