phoenixlisted
Install: claude install-skill FortiumPartners/ensemble
# Phoenix Framework Skill - Quick Reference
**Version**: 1.0.0 | **Last Updated**: 2025-10-22 | **Agent**: backend-developer
Quick reference for Phoenix and Elixir development patterns. For comprehensive documentation, see REFERENCE.md.
---
## Table of Contents
1. [Phoenix API Development](#phoenix-api-development)
2. [OTP Patterns](#otp-patterns)
3. [Phoenix LiveView](#phoenix-liveview)
4. [Ecto Database Operations](#ecto-database-operations)
5. [Phoenix Channels](#phoenix-channels)
6. [Background Jobs (Oban)](#background-jobs-oban)
7. [Production Deployment](#production-deployment)
8. [Testing with ExUnit](#testing-with-exunit)
9. [Security Best Practices](#security-best-practices)
10. [Performance Optimization](#performance-optimization)
---
## Phoenix API Development
### RESTful Controller Pattern
```elixir
defmodule MyAppWeb.PostController do
use MyAppWeb, :controller
alias MyApp.Blog
alias MyApp.Blog.Post
# List all posts
def index(conn, _params) do
posts = Blog.list_posts()
render(conn, "index.json", posts: posts)
end
# Show single post
def show(conn, %{"id" => id}) do
post = Blog.get_post!(id)
render(conn, "show.json", post: post)
end
# Create post
def create(conn, %{"post" => post_params}) do
case Blog.create_post(post_params) do
{:ok, post} ->
conn
|> put_status(:created)
|> render("show.json", post: post)
{:error, changeset} ->
conn
|> put_status(:unprocessable