mozexmozexCommunityยท1 Agent Skills Included

anthropic-laravel

Laravel integration for Claude API calls and testing

Connects Laravel applications to the Claude API through a simple facade for messages, streaming, tool use, and batch processing. Removes manual client setup, config wiring, and boilerplate with a single install command and publishable configuration. Includes a testing fake to assert API requests without real network calls, plus guidance on streaming, citations, files, and token counting.
npx skills add mozex/anthropic-laravel --all -g -y
Available:

Tells your AI agent how the package is structured, which commands run tests and linting, and what coding conventions to follow when working in this repository.

All Skills in This Repository (1)

Pure Emerald Level Indicators

Frequently Asked Questions

FAQPage Schema
How 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โ†’