FETCH HIVE
Get StartedBook a Demo
  • 👋Welcome
  • Getting Started
    • Prompt Quick Start
    • Workflow Quick Start
  • Agent Quick Start
  • 💬Running Prompts
    • Run with API
  • 🚀Building Workflows
    • Workflow Steps
      • AI
        • Prompt
        • Agent
      • Web Research
        • Google Search
        • Google News
        • Bing Search
        • Exa Search
        • Exa Similar
        • Website Scrape
      • Utility
        • Call API
        • Format JSON
      • Files
        • Document Upload to Text
        • Document URL to Text
  • Testing and Iteration
  • Publishing and Versioning
  • Error Handling
  • 🚀Running Workflows
    • Run with API
  • Retrieve a Workflow
  • 🤖AGENTS
    • Build an Agent
    • Send a Message
    • API
      • Create an Agent
      • Retrieve an Agent
      • Delete an Agent
      • Chats
        • Retrieve a Chat
        • Create a Chat
        • Update a Chat
        • Delete a Chat
        • Clear Chat Messages
      • Messages
        • List Messages
  • 💾Datasets
    • Build a Dataset
    • Test a Dataset
    • API
      • Retrieve a Dataset
      • Create a Dataset
      • Update a Dataset
      • Delete a Dataset
      • Dataset Items
        • Retrieve a Dataset Item
        • Create a Dataset Item
        • Update a Dataset Item
        • Delete a Dataset Item
        • Regenerate a Dataset Item
  • 🏢Your Workspace
    • Brand Kit
  • Settings
  • Use your own API keys
  • Team Members
  • 🔍Monitoring
    • Credit Usage
    • Analytics
    • Log History
  • 📚Resources
    • Discord
    • Changelog
  • Roadmap
  • Book a Demo
  • Get in Contact
  • Security and Compliance
Powered by GitBook
On this page

Was this helpful?

  1. AGENTS

Send a Message

Send a message to a Fetch Hive agent via the API.

PreviousBuild an AgentNextAPI

Last updated 25 days ago

Was this helpful?

🤖

Send a message to an agent

post

Send a message to an agent

Authorizations
Body
user_idstringOptional
messagestringRequired
agentstringRequired
chatstringRequired
streamingbooleanRequired
Responses
200
Successful response
application/json
default
Error
application/json
post
POST /v1/agent/invoke HTTP/1.1
Host: api.fetchhive.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 204

{
  "user_id": "text",
  "message": "text",
  "agent": "text",
  "chat": "text",
  "streaming": true,
  "google_search": {
    "enabled": true,
    "depth": 1
  },
  "vector_search": {
    "enabled": true,
    "depth": 1
  },
  "history": {
    "enabled": true,
    "depth": 1
  }
}
{
  "content": "text",
  "duration": 1,
  "model": "text",
  "usage": {
    "prompt_tokens": 1,
    "completion_tokens": 1,
    "total_tokens": 1
  },
  "tool_responses": [
    {
      "tool_id": "text",
      "tool_type": "text",
      "tool_input": "text",
      "tool_observation": "text",
      "status": "text"
    }
  ]
}