Create an Agent¶
This guide explains how to create new agents in RhinoAgents. You can create an agent from scratch or start with a pre-built template.
Overview¶
Creating an agent involves defining its identity, purpose, and initial configuration. Agents are created within a Organization and can optionally be assigned to a specific Workspace.
There are two primary ways to create an agent:
- Create from Scratch: Define a custom agent with a blank slate.
- Create from Template: Use a pre-configured template with existing workflows and nodes.
Method 1: Create Agent from Scratch¶
Use this method when you want to build a custom agent completely from the ground up.
Steps¶
- Navigate to the Agents section in your dashboard.
- Click the + Create Agent button.
- Fill in the required details (Name, etc.).
- (Optional) Assign to a Workspace.
- Click Create.
Configuration Fields¶
When creating an agent from scratch, the following fields are available:
| Field | Type | Required | Description |
|---|---|---|---|
| Name | String | Yes | A unique name for your agent. Must be a non-empty string. |
| Workspace | ID | No | The workspace to assign this agent to. Validates that the workspace exists. |
| Prompt | String | No | The system prompt or core instruction for the agent. |
| Status | String | No | Initial agent status. Defaults to inactive. |
| Collaborators | Array | No | List of user IDs who can collaborate on this agent. |
| Category | String | No | Agent category (e.g., ai-agents, chatbots). Defaults to ai-agents. |
| Chatbot Type | String | No | If category is chatbots, specifies type (e.g., general, sales). |
| Agent Type | String | No | Type of agent (e.g., general). Defaults to general. |
| Image | URL | No | URL for the agent's avatar or icon. |
Organization & Workspace
The agent is automatically linked to your Organization ID. If you provide a Workspace ID, the agent will be scoped to that specific workspace.
Method 2: Create Agent from Template¶
Templates allow you to start with a pre-configured agent, including predefined workflows, nodes, and settings.
Steps¶
- Navigate to the Templates library.
- Select a template that matches your use case.
- Click Use Template.
- Enter a name for your new agent.
- (Optional) Select a Workspace.
- Click Create.
How Templates Work¶
When you create an agent from a template:
- Agent Creation: A new agent is created with the template's query/prompt as the default.
- Workflow Generation: If the template contains nodes, a new workflow is automatically created and linked to the agent.
- Status: Defaults to
active(unless specified otherwise). - Workspace Inheritance: If a workspace is selected, both the agent and its generated workflow are assigned to that workspace.
Template Inheritance¶
The new agent inherits the following from the template: * Prompt/Query: The core instruction logic. * Nodes & Workflow: The processing steps (Triggers, Actions, Logic). * Metadata: Any additional template configuration.
API Reference¶
Create Agent Endpoint¶
POST /api/agents/create/:customerId
Body Parameters:
{
"name": "My Custom Agent",
"prompt": "You are a helpful assistant...",
"status": "active",
"workspaceId": "651234567890abcdef123456",
"collaborators": ["user_123", "user_456"],
"category": "ai-agents",
"image": "https://example.com/avatar.png"
}
Create from Template Endpoint¶
POST /api/agents/template/:customerId
Body Parameters:
{
"name": "Support Bot from Template",
"templateId": "template_987654321",
"workspaceId": "651234567890abcdef123456",
"status": "active"
}
Validation Rules¶
The system enforces several validation rules during creation:
- IDs:
customerId,workspaceId,organizationIdmust be valid MongoDB ObjectIds. - Name: Must be a non-empty string.
- Template: When using a template, the
templateIdmust exist in the system.
Next Steps¶
Once your agent is created: * Configure the Agent * Manage Integrations * Test with Simulator