Encore ts backend engineering
Skill meyverick/agy-skills/skills/encore-ts-backend-engineering
A collection of elite, modular, and validated AI agent skills and system rules for Google Antigravity.
npx -y skills add meyverick/agy-skills --skill encore-ts-backend-engineeringAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Engineers type-safe backend microservices using Encore.ts. Use when orchestrating declarative architectures and infrastructure-from-code topologies.
SKILL.md
2.6 KB, as published. Nobody here has run it
Encore.ts Backend Engineering
This skill manages the creation of distributed, type-safe backends using Encore.ts. It enforces strict Infrastructure-from-Code (IfC) paradigms, ensuring that architecture and deployment topologies are inferred directly from TypeScript code.
When to Use
- Use when creating new backend services or RPC endpoints using Encore.ts.
- Use when defining declarative infrastructure (Databases, Pub/Sub, Cron jobs).
- NOT for modifying traditional Express.js or NestJS APIs.
Core Process
Phase 1: API Endpoint Definition
- Define API contracts directly via exported functions wrapped in
api(). - Ensure request/response schemas are heavily typed with explicit interfaces.
- Do not write manual OpenAPI schemas; Encore infers them from the TypeScript AST.
Phase 2: Declarative Infrastructure
Never manually provision databases or queues in an external console or IaC tool (like Terraform) if Encore supports it natively.
- Use
import { SQLDatabase } from "encore.dev/storage/sqldb"for databases. - Use
import { Topic, Subscription } from "encore.dev/pubsub"for event-driven boundaries. - Ensure all resources are bound directly to the code that utilizes them.
Phase 3: Service Communication
- Services must communicate via strictly typed, native function calls (e.g.,
serviceA.endpointB()). - Do not hardcode URLs or manual
fetchcalls to communicate between internal Encore services.
Common Rationalizations
| Rationalization | Reality |
|---|---|
| "I'll just define the Postgres database manually in AWS." | Encore's Infrastructure-from-Code automatically handles local, testing, and production provisioning. Manual IaC splits the truth. |
| "I'll write an Express middleware for this validation." | Encore handles request validation at the compile-time schema level. Standard middleware paradigms often bypass these guarantees. |
Red Flags
- Manual HTTP
fetchrequests pointing to internal cluster services. - Creating resources in cloud consoles instead of utilizing
encore.dev/storage/sqldb. - Hand-written OpenAPI/Swagger definitions.
Verification
Before finalizing the Encore service, verify:
- All APIs are wrapped in the
api()directive with strict TypeScript interfaces. - Infrastructure (DBs, PubSub) is defined natively within the code.
- Internal service calls utilize type-safe direct imports, not manual HTTP routing.
Gives 0 of the 12 instructions most data backend skills give
Counted across 229 of the 229 authors here whose files we hold, read 2026-08-06
- separate business logic into service layersin 22 of 229, across 15 files
- select only needed database columnsin 20 of 229, across 13 files
- retry failures with exponential backoffin 20 of 229, across 13 files
- abstract data access into repository classesin 19 of 229, across 12 files
- Use centralized error handlersin 17 of 229, across 10 files
- Use AsNoTracking for read-only queriesin 16 of 229, across 4 files
- Implement structured loggingin 15 of 229, across 4 files
- Use async/await for all I/O operationsin 15 of 229, across 3 files
- use resource-based URLs for REST APIsin 15 of 229, across 9 files
- Use dependency injection for all servicesin 14 of 229, across 2 files
- Invalidate cache on data updatesin 13 of 229, across 9 files
- Use a dependency injection containerin 12 of 229, across 4 files
Said here and by no other author read
- define API contracts using exported api functions
- type request and response schemas with explicit interfaces
- use Encore storage modules for databases
- use Encore pubsub modules for event-driven systems
- bind infrastructure resources directly to using code
- call internal services via native typed function calls
Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once.