be-elixir

Implement Elixir backend services with Phoenix, Ecto, and ExUnit.

Updated Mar 7, 2026
One-click install
npx skills add https://github.com/MassimilianoPili/agent-framework --skill be-elixir
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: be-elixir
Source: https://github.com/MassimilianoPili/agent-framework/tree/main/.claude/agents/be-elixir
Command: npx skills add https://github.com/MassimilianoPili/agent-framework --skill be-elixir

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill addresses the need for robust, idiomatic Elixir backend development, ensuring adherence to Phoenix and Ecto conventions for scalable and maintainable applications.

Core Features & Use Cases

  • Backend API Implementation: Develops contexts, Ecto schemas, and controllers for Elixir/Phoenix applications.
  • Test-Driven Development: Integrates ExUnit for comprehensive testing of business logic and API endpoints.
  • Use Case: Implement a new user authentication module in a Phoenix application, including Ecto schemas for user data, context functions for registration and login, and corresponding controller actions.

Quick Start

Use the be-elixir skill to implement the User CRUD API based on the provided OpenAPI contract.

Frequently Asked Questions about be-elixir

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement a Phoenix backend API from an OpenAPI contract?

To implement a Phoenix backend API, use this Skill to generate Ecto schemas, context modules, and controllers from an OpenAPI contract. It enforces contract-first principles, data validation via changesets, and idiomatic context-based design.

What is the best way to structure Elixir business logic in Phoenix?

The best way to structure Elixir business logic is using context-based design. Group related functions into dedicated context modules that interact with Ecto schemas, encapsulating data persistence and business rules away from the controller layer.

How do you test API endpoints and business logic in Elixir?

You test API endpoints and business logic in Elixir using ExUnit. Write comprehensive tests covering context functions and controller actions to validate changesets, data persistence, and OTP patterns for robust backend verification.

Does Ecto changeset validation work with Phoenix context modules?

Yes, Ecto changeset validation works seamlessly with Phoenix context modules. Context functions create and apply changesets to validate data before persistence, ensuring API endpoints receive structurally correct data and return appropriate validation errors.

When should I use OTP patterns in Elixir backend services?

Use OTP patterns in Elixir backend services when managing long-running processes, stateful GenServers, or supervision trees. They provide fault tolerance and scalability for background tasks and concurrent operations beyond standard request-response cycles.

Can I build scalable APIs without Phoenix using just Elixir?

While you can build APIs in pure Elixir, Phoenix provides essential conventions like Ecto for data persistence, context-based design, and controller structures. Developing without it requires manually building these scalable, maintainable architectural layers.