anthropic-laravel
Laravel integration for Claude API calls and testing
All Skills in This Repository (1)
Pure Emerald Level IndicatorsFrequently Asked Questions
FAQPage SchemaHow to install anthropic-laravel?โผ
Run `npx skills add mozex/anthropic-laravel --all -g -y` in your terminal to install this skill globally for your AI coding agent.
How to call the Claude API from Laravel?โผ
Use the Anthropic facade: `Anthropic::messages()->create([...])` with your model, max_tokens, and messages array. The service provider handles client setup automatically.
How to test Laravel code that calls Claude?โผ
Use `Anthropic::fake()` to swap the real client with a fake, queue fake responses, then assert exactly which requests were sent with `Anthropic::assertSent()`.
Does it support streaming and tool use?โผ
Yes. It covers streaming responses, function calling, extended thinking, web search, code execution, citations, files, and batch processing through the same facade.
What PHP and Laravel versions are required?โผ
The package requires PHP 8.2 or higher and works with Laravel 11 or 12.
Related Repositories in Software Engineering
View All in Software Engineeringโopenclaw
Run a personal AI assistant across your devices and chat apps
superpowers
Gives coding agents a disciplined workflow from idea to merged code
react
AI agent skills for building, testing, and porting React core