GetAgent
The GetAgent action retrieves information about the current Agent. The current Agent is the one you are currently working in the context of. For example, if you use GetAgent in any Skill of My Receptionist Agent, you will get this specific agent information.
GetAgent(
field: str
)
Where:
- field: Literal["id", "title", "description", "name"]
Example 1 (No Field)
A basic example with no GetAgent field strings returning the agent's name. In this case, the agent is named Mike.
{{set(name="agent_", value=GetAgent())}}
{{SendMessage(message=agent_)}}
Mike
Example 2 (Specific Field)
This example of the GetAgent action specifies a specific field to return. In this case, the agent's title is Hotel Receptionist. Only one field can be specified at a time.
{{set(name="agent_", value=GetAgent(field="title"))}}
{{SendMessage(message=agent_)}}
Hotel Receptionist
Updated 6 months ago