Example Flow
Custom webhook deployments accept the request and process it asynchronously. If the orchestrator needs the result, have the Duckie agent call a custom tool configured with a fixed callback API and a correlation ID rather than expecting the webhook response to include the final answer.When to Use This Pattern
Use Duckie as an external subagent when:- You already have a primary orchestration agent outside Duckie.
- Duckie should own a narrow support capability, not the whole customer journey. For the Duckie-native version of this pattern, see Sub-Agents.
- The task benefits from Duckie knowledge search, runbooks, guidelines, guardrails, or support tools.
- Your orchestrator can continue after receiving an async callback from Duckie.
- Search internal support docs and return a sourced answer.
- Classify a customer request into your support taxonomy.
- Summarize a ticket, conversation, or account record.
- Draft a customer-facing response for the orchestrator to review or send.
- Check policy eligibility and return a recommendation.
What to Build
Request Shape
Send the task to a Duckie custom webhook as JSON.
Keep the webhook payload focused. Do not include secrets, credentials, API keys, or unnecessary sensitive data.
Agent Setup
Create an autonomous agent with a narrow name and description, such as External Knowledge Search Agent. Example instructions:Callback Tool
Create a custom tool that posts the result back to your orchestrator API.
Use a fixed callback endpoint. Pass task IDs, customer IDs, or routing keys as parameters instead of letting the agent choose a destination URL.
Result Shape
The callback response to your orchestrator can look like this:Testing
- Create the webhook deployment in Testing mode.
- Send a representative task payload with a correlation ID.
- Open Analyze > Runs and verify the message, metadata, searched knowledge, and tool calls.
- Confirm your callback API receives one result for the task.
- Test missing context, low-confidence answers, and callback failures before switching the deployment to Live.
Related Docs
Custom Webhooks
Trigger Duckie from your orchestration system.
Custom Tools
Send the subagent result back to your API.
Autonomous Agents
Configure the focused Duckie agent.
Run History
Review the Duckie run, tool calls, and callback result.
Designing Agent Systems
Place this pattern inside a larger agent architecture.
Single Agents vs Sub-Agents
Compare internal delegation with external orchestration.