with one click
api-test-writer
Use when writing API tests in apps/api/tests/
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Use when writing API tests in apps/api/tests/
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
Record browser-based feature demos as GIFs via Playwright and optionally document them in docs/features/index.md. Trigger with "Demo <feature>" or "Demo and Document <feature>".
Use when creating service modules in apps/api/skillhub/services/
Use when implementing division-based access control on any endpoint
Use when adding services to docker-compose.yml or creating Dockerfiles
Use when implementing error handling across the API, frontend, or MCP server
Use when creating new Flask blueprints in apps/api/skillhub_flask/blueprints/
| name | api-test-writer |
| description | Use when writing API tests in apps/api/tests/ |
import pytest
from skillhub_flask.app import create_app
@pytest.fixture
def app(db_session):
app = create_app(testing=True, session_factory=lambda: db_session)
yield app
@pytest.fixture
def client(app):
return app.test_client()
@pytest.fixture
def auth_headers():
token = create_test_jwt(user_id="test-uuid", division="engineering-org")
return {"Authorization": f"Bearer {token}"}
def test_list_skills(client, auth_headers):
response = client.get("/api/v1/skills", headers=auth_headers)
assert response.status_code == 200
data = response.get_json()
assert "items" in data
assert "total" in data
def test_unauthorized_returns_401(client):
response = client.get("/api/v1/users/me")
assert response.status_code == 401
def test_division_enforcement(client, auth_headers_wrong_division):
response = client.post("/api/v1/skills/restricted-skill/install",
headers=auth_headers_wrong_division)
assert response.status_code == 403
mise run test:api:coverage — fails if < 80%.
apps/api/tests/apps/api/tests/conftest.pyapps/api/pyproject.toml