FlexPriceのディレクトリ構成や依存関係、主要な処理フローを資料に沿って把握し、変更の影響範囲や設計上の注意点を調べるスキルです。
- FlexPriceの構成を把握したいとき
- 機能の呼び出し経路を追いたいとき
- リファクタリングの影響を調べたいとき
ローカルAPIに認証情報付きのHTTPリクエストを送り、疎通確認からエンドポイント別の結果整理まで進めるQAスキルです。
Master HTTP QA: chains devenv then interactive API key / X-Environment-ID then real curls. Shards suites to parallel workers. Trigger: apitest, api test, curl localhost, QA local API.
実行スコア 未検証
インストール方法を見るローカルAPIに対するHTTP QAを、環境確認から結果整理まで段階的に進めます。まずdevenvで起動状態や接続先を確認し、必要に応じてAPIキーやX-Environment-IDなどを対話形式で受け取ります。その後、curlでヘルスチェックやエンドポイントへのリクエストを行い、HTTPステータスコードと短いレスポンスを記録します。多数の独立したエンドポイントを調べる場合は、安定した接続先と認証条件を共有したうえで担当を分け、結果をまとめます。
ローカルでAPIを開発していて、実際のHTTP応答を確かめたいときに向いています。認証が必要なルートの疎通確認や、複数のAPIを段階的に調べる作業にも使えます。読み取り専用の確認から、作成・変更を伴う試験まで、範囲を整理して進められます。
APIキーなどの認証情報を対話形式で扱います。秘密情報を文章やリポジトリに記録せず、本番環境へのリクエストには明示的な確認が必要です。環境準備にdevenvを使います。
この紹介文は、公開されている SKILL.md をもとに AI(OpenAI Codex)が作成しました。正確な仕様は下の原文を確認してください。
インストールする前に、エージェントに与えられる指示の中身を確認できます。
apitest — API QA (master)This skill acts as master in a master / worker pattern for large workloads: it plans, sequences, holds secrets policy, merges outcomes. Delegate narrow, independent slabs to worker runs (parallel Cursor agents or separate chat tasks) — never fork without a stable BASE_URL, mode, and credential contract.
Always compose devenv for infra + deployment mode before HTTP unless endpoints are confirmed up.
devenv phase — user intent (host API / consumer / temporal_worker / local / full compose), .env* hygiene, MAX_ROUNDS verify loop GREEN.http://127.0.0.1:8080; path prefix /v1 (see CLAUDE.md/AGENTS.md — no trailing slash on base).Ask explicitly, one bundle at a time:
| # | Prompt | Stored as (concept) |
|---|---|---|
| 1 | API key value for x-api-key header (often local sk_local_flexprice_test_key)? | $FLEXPRICE_TEST_API_KEY |
| 2 | X-Environment-ID GUID if authenticated routes scope to an environment (internal/types/header.go)? | $FLEXPRICE_TEST_ENV_ID |
| 3 | Any bearer JWT flow instead/in addition? Rare for pure api-key dashboards. | $AUTH_HEADER literal |
| 4 | Alternate HOST (staging/tunnel)? | $BASE_URL override |
Operational rule: Prefer shell:
read -rs FLEXPRICE_TEST_API_KEY && export FLEXPRICE_TEST_API_KEY && export BASE_URL=http://127.0.0.1:8080 && …
Never paste full keys back in assistant prose — confirm present/absent/length fingerprint only.
# Health (normally unauthenticated outer router — GET /health is root router; swagger says /v1 base for API)
curl -sfS "${BASE_URL:-http://127.0.0.1:8080}/health" | head -c 200 || echo FAIL
# Private v1 example skeleton
curl -sfS "${BASE_URL:-http://127.0.0.1:8080}/v1/some/route" \
-H "x-api-key: ${FLEXPRICE_TEST_API_KEY}" \
${FLEXPRICE_TEST_ENV_ID:+-H "X-Environment-ID: ${FLEXPRICE_TEST_ENV_ID}" } \
-H "Accept: application/json"
Adapt routes from docs/swagger/ (swagger-3-0.json / handler paths in internal/api/router.go).
Verb matrix: -f curls fail on 4xx/5xx — toggle -w '\n%{http_code}\n' when debugging semantics.
Large bodies: --data-binary @file.json plus -H 'Content-Type: application/json'.
Tick mentally as Orchestrator:
[A] Requirement intake — verbs (GET invoice? POST event?), tenancy surface, destructive vs readonly
[B] Compose **devenv** — mode + infra + verify loop GREEN
[C] Credential interactive gather — §1 vars exported in user shell orchestrator echoes
[D] Smoke ladder — health → simplest GET → progressively complex POST
[E] Record actual HTTP codes + trimmed JSON excerpts (truncate >2KB bodies)
[F] Tear-down optional — advise user Ctrl-C server / docker stop if ephemeral
Consumer mode caveat: consumer / ingestion-only modes expose few/no HTTP tests meaningful — steer user to api or local for REST probes while consumer runs sibling process.
When splitting is justified:
> ~8 independent endpoints without shared mutable side-effect ordering.Orchestrator tasks:
| Task | Responsibility |
|---|---|
Publish immutable contract snippet snippet to workers: BASE_URL, header list (names only — keys via env mirror), forbid schema drift | |
| Freeze ordering dependencies (eg create-customer-before-subscription DAG) | |
| Merge JSON pass/fail report table |
Worker tasks:
| Task | Responsibility |
|---|---|
| Single tag / subdomain file list bounded | |
curls only — readonly repos if parallel (readonly Cursor agent mode preferred) | |
| Return compact stdout block + stray stderr |
Mechanism hints (implementation-agnostic wording for Cursor stacks):
Workers pull infra state from devenv completion note (BASE_URL GREEN).
Anti-pattern:** workers independently restart docker / rewrite .env — Orchestrator only.
| Tier | Scope | Typical duration cue |
|---|---|---|
| T0 Smoke | /health, one cheap GET /v1/... | minutes |
| T1 Tagged | All GET list endpoints user lists | tens of minutes sequential |
| T2 Mutation | Creates + compensating deletes/idempotency | document cleanup |
| T3 Replay | Event pipelines / delayed ClickHouse eventual — mark observe async |
| Observation | Hypothesis ladder |
|---|---|
401 / 403 | key / rbac / missing env header / provider mismatch (.env docker vs host hosts) |
404 route | Forgot /v1 prefix vs mount |
| hangs | infra not READY — rerun devenv §Verification |
5xx | logs docker compose logs flexprice-api hybrid OR stdout process |
Attach Correlation: request IDs from logging middleware (internal/rest/middleware).
Pure HTTP probes cannot finalize Metering completeness — annotate defer validation (ClickHouse/dashboard) referencing docs/FLOWS/event-processing.md.
Temporal heavy flows: optionally poll Temporal UI human step — mark automate-later.
| Role | Skill |
|---|---|
| Bring-up / env | devenv |
go test | godev |
| Architecture | arch + docs/FLOWS/* |
The master orchestrator stance: keep this file thin on endpoint enumeration (Swagger is source) — prioritize interaction contract + safety + parallelism rules.
まだレビューはありません。使ってみた感想をお寄せください。
ログインなしで書き込めます。使ってみた感想、質問、動かなかった環境などを気軽にどうぞ。
まだコメントはありません。最初のコメントを書いてみませんか。
FlexPriceのディレクトリ構成や依存関係、主要な処理フローを資料に沿って把握し、変更の影響範囲や設計上の注意点を調べるスキルです。
Docker ComposeやMakefileを使ったFlexPriceの開発環境の起動・停止、Kafka UIの追加、サービスログの確認を案内します。
コード変更が各階層のAGENTS.mdに反映されているかを確認し、差分に応じた更新内容の作成と同期状態の管理を支援します。
環境変数とDocker Composeを確認し、ローカル実行とRDSなどの共有サービスを組み合わせた開発環境の準備や起動方法を案内します。
GitHub CLIでプルリクエストやIssueを確認し、チェックの失敗ログを調べるほか、変更内容を整理してプルリクエストを作成します。
Goのコード整形、静的チェック、競合状態を調べるテスト、プロジェクトのテスト実行を順に進め、変更したコードの確認を支援します。