flowstate-epic-flowstate-community-epicdm-flowstate-ai-gateway
Package-local agent skill for @epicdm/flowstate-ai-gateway.
Tags
Publisher
Versions
1 version published — latest: 0.1.0
- 0.1.0publishedInvalid Date
Skill
flowstate-ai-gateway Package Skill
Package: @epicdm/flowstate-ai-gateway
Repository: epic-flowstate-community
Path: packages/flowstate-ai-gateway
Version: 0.1.0
Use this published Dojo skill as the package-level entrypoint. For detailed workflows, use the package-local skills listed below.
Primary Package Workflow
FlowState AI Gateway Deployment Integration
Use this skill for deploying or wiring the runtime gateway.
Source Map
docker/Dockerfile.ai-gateway: image build.docker/docker-compose.ai.ymland compose templates: service env and network exposure.packages/gateway-routes/src/routes.ts: Kong exposure.packages/flowstate-cli/src/cli-commands/agent/ai-usage.ts: CLI usage client.src/server.tsandsrc/config.ts: runtime env behavior.
Deployment Model
- The service listens in-container and should not expose the LLM proxy directly on a host port.
- Host/operator access to
/usageand/healthzshould go through Kong when deployed. - Sidecars use service-network URLs to send LLM traffic.
- Runtime env controls provider selection, credentials, ledger path, budgets, identity HMAC, and payload audit.
Guardrails
- Do not expose
/v1/messages,/v1/chat/completions, or/v1/responsesas a public unauthenticated proxy. - Keep
/usageand/healthzexposure aligned with Kong route policy. - Do not put API keys or HMAC secrets in generated files that are intended for commit.
- Coordinate compose env changes with CLI instance templates and gateway routes.
Verification
yarn nx build @epicdm/flowstate-ai-gateway
yarn workspace @epicdm/flowstate-ai-gateway typecheck
For deployment changes, run the smallest local compose/smoke path that exercises the changed wiring.
Package Skill Inventory
Skill Inventory: @epicdm/flowstate-ai-gateway
Package path: packages/flowstate-ai-gateway.
Skillset
| Skill | Use When | Main Source Evidence |
|---|---|---|
flowstate-ai-gateway | Choosing the right runtime gateway workflow or preserving public/service boundaries | package.json, src/index.ts, src/app.ts, src/server.ts, src/config.ts |
flowstate-ai-gateway-provider-routing | Changing provider env matrix, route guards, OpenAI/Anthropic routing, Cloudflare URL/key behavior, per-agent routing headers | src/app.ts, src/config.ts, src/server.ts, src/key-resolver.ts |
flowstate-ai-gateway-usage-budget-ledger | Changing /usage, budget modes, SQLite ledger, payload audit, or rollups | src/app.ts, src/sqlite-store.ts, core budget/audit imports |
flowstate-ai-gateway-trusted-identity | Changing signed FlowState headers, HMAC verification, or enforce-mode identity requirements | src/app.ts, core metadata headers |
flowstate-ai-gateway-deployment-integration | Changing Docker, compose, Kong route exposure, sidecar usage, or runtime env | docker/Dockerfile.ai-gateway, compose files, gateway-routes, CLI usage client |
flowstate-ai-gateway-testing | Selecting focused tests and safe app construction patterns | src/__tests__, buildApp, SqliteLedgerStore, core test helpers |
Composition Notes
- Use
flowstate-ai-gateway-provider-routingtogether withflowstate-ai-gateway-trusted-identityfor per-agent OpenAI routing. - Use
flowstate-ai-gateway-usage-budget-ledgerbefore changing budget enforcement or/usage. - Use
flowstate-ai-gateway-deployment-integrationbefore changing exposed routes or host ports.
Publication Readiness
Status: drafted, pending verification.
Before Dojo publication, rebuild package Dojo artifacts from this reviewed skillset.
Review Gate
Package Skill Review: @epicdm/flowstate-ai-gateway
Package path: packages/flowstate-ai-gateway.
Review Result
Status: drafted, source-backed, verified with one package-script lint blocker, pending publication.
The skillset is workflow-shaped around app/runtime operation, provider routing, usage/budget ledger behavior, trusted identity, deployment integration, and focused tests.
Checks
- Source review: completed from package review agent output, package metadata, root exports, app/config/server/key resolver/sqlite store files, Docker/Kong/CLI references, tests, and generated artifact drift.
- Skill inventory: completed.
- Skill files: completed.
- Verification: completed.
- Generated Dojo replacement: pending.
- Cloud Dojo publication: pending.
Verification Commands
Commands run:
yarn nx build @epicdm/flowstate-ai-gateway
yarn nx test @epicdm/flowstate-ai-gateway
yarn workspace @epicdm/flowstate-ai-gateway typecheck
yarn workspace @epicdm/flowstate-ai-gateway lint
yarn nx build @epicdm/flowstate-ai-gateway-core
Results:
- Skill file ASCII scan passed.
- Tests passed: 3 suites, 59 tests; Jest reported an open-handle warning after completion.
- Typecheck passed.
- Nx build passed for
flowstate-ai-gatewayand dependencyflowstate-ai-gateway-core; Nx Cloud reported the existing unconnected-workspace 401. - Lint did not run because the package script resolved
eslintas missing:command not found: eslint.
Publication Gate
Do not publish existing .flowstate/dojo artifacts until they are rebuilt from reviewed package skills.
Usage
Start with this skill to understand the package purpose, then use the package-local focused skills for specific workflows. Keep this Dojo version aligned with packages/flowstate-ai-gateway/package.json. Do not treat generated feature lists as lessons; use workflow evidence from CODE-REVIEW.md, SKILL-INVENTORY.md, and REVIEW.md.
Install
Run this in your project to install via CLI:
fscloud dojo skill install flowstate-epic-flowstate-community-epicdm-flowstate-ai-gateway --target <target> --out ./skillsReplace <target> with your agent target identifier. See the CLI docs for details.