Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,7 @@
"integrations/crewai",
"integrations/camelai",
"integrations/praison",
"integrations/neuron-ai",
"integrations/dify",
"integrations/langflow",
"integrations/flowise",
Expand Down
Binary file added images/integrations/neuron-ai.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
15 changes: 15 additions & 0 deletions integrations.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,21 @@ Use Firecrawl as a loader, reader, or tool inside your agent code.
>
Scrape data from the web with the Firecrawl tool
</Card>
<Card
title="Neuron AI"
icon={
<img
src="/images/integrations/neuron-ai.png"
alt="Neuron AI"
width="24"
height="24"
style={{ objectFit: "contain" }}
/>
}
href="/integrations/neuron-ai"
>
Give PHP agents web search and page reading
</Card>
</CardGroup>

## Visual AI builders
Expand Down
81 changes: 81 additions & 0 deletions integrations/neuron-ai.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
---
title: "Neuron AI"
description: "Search the web and read pages as Markdown from Neuron AI agents in PHP"
og:title: "Neuron AI | Firecrawl"
og:description: "Give Neuron AI agents web search and page reading with the Firecrawl toolkit"
---

<Note>
**Official Neuron AI docs:** [docs.neuron-ai.dev/agent/tools](https://docs.neuron-ai.dev/agent/tools)

Give PHP agents web search and page reading through Firecrawl
</Note>

## Overview

[Neuron AI](https://neuron-ai.dev) is an agentic framework for PHP. It ships a Firecrawl toolkit, so a Neuron agent can search the web and read any page as clean Markdown during a run.

## Quick start

1. Install Neuron AI 4.1.3 or later:

```bash
composer require neuron-core/neuron-ai:^4.1.3
```

2. Get an API key from your [Firecrawl dashboard](https://www.firecrawl.dev/app/api-keys) and set it as `FIRECRAWL_API_KEY`
3. Add the toolkit to your agent:

```php
namespace App\Neuron;

use NeuronAI\Agent\Agent;
use NeuronAI\Tools\Toolkits\Firecrawl\FirecrawlToolkit;

class ResearchAgent extends Agent
{
...

protected function tools(): array
{
return [
FirecrawlToolkit::make(
key: getenv('FIRECRAWL_API_KEY')
),
];
}
}
```

## Tools

| Tool | Name the agent sees | What it does |
|------|---------------------|--------------|
| `FirecrawlSearchTool` | `web_search` | Searches the web, or news when the agent asks for it, with an optional time range |
| `FirecrawlScrapeTool` | `url_reader` | Returns the main content of a page as Markdown |

You can also add either tool on its own, for example `FirecrawlSearchTool::make(key: getenv('FIRECRAWL_API_KEY'))`.

## Get page content with each search result

By default a search returns the title, URL and description of each result. Pass `scrapeOptions` and each result also carries the full page as Markdown, so the agent does not need a second call to read it:

```php
use NeuronAI\Tools\Toolkits\Firecrawl\FirecrawlSearchTool;

FirecrawlSearchTool::make(key: getenv('FIRECRAWL_API_KEY'))->withOptions([
'limit' => 5,
'scrapeOptions' => [
'formats' => ['markdown'],
'onlyMainContent' => true,
],
]);
```

`withOptions()` replaces the defaults and accepts any [search parameter](/api-reference/endpoint/search). The search query always comes from the agent.

## Resources

- [Neuron AI tools and toolkits](https://docs.neuron-ai.dev/agent/tools)
- [Firecrawl search docs](/features/search)
- [Firecrawl scrape docs](/features/scrape)
Loading