lib.graphql-federation
Pothos federation helpers and subgraph schema export utilities
@lssm-tech/lib.graphql-federationbun add @lssm-tech/lib.graphql-federationManifest declarations describe the current workspace; they do not verify registry publication or runtime execution.
Package guide
Website: https://contractspec.io
Apollo Federation hosts require GraphQL ^16.14.2. Apollo Subgraph 2.15 does not support GraphQL 17; do not force that version through overrides.
Pothos federation helpers and subgraph schema export utilities.
What It Provides
- Layer: lib.
- Consumers: bundles with federated GraphQL.
- Related ContractSpec packages include
@lssm-tech/tool.bun,@lssm-tech/tool.typescript. - Related ContractSpec packages include
@lssm-tech/tool.bun,@lssm-tech/tool.typescript.
Installation
npm install @lssm-tech/lib.graphql-federation
or
bun add @lssm-tech/lib.graphql-federation
Usage
Import the root entrypoint from @lssm-tech/lib.graphql-federation, or choose a documented subpath when you only need one part of the package surface.
Architecture
src/index.tsis the root public barrel and package entrypoint.
Public Entry Points
- Export
.resolves through./src/index.ts.
Local Commands
bun run dev— contractspec-bun-build devbun run build— contractspec-bun-build buildbun run typecheck— tsgo --noEmitbun run publish:pkg— bun publish --tolerate-republish --ignore-scripts --verbosebun run publish:pkg:canary— bun publish:pkg --tag canarybun run clean— rm -rf distbun run prebuild— contractspec-bun-build prebuildbun run build:bundle— contractspec-bun-build transpilebun run build:types— contractspec-bun-build types
Recent Updates
- Replace eslint+prettier by biomejs to optimize speed.
Notes
- Federation directives must comply with the Apollo Federation spec; non-compliant changes break gateway composition.
- Depends on graphql-core — keep builder factory usage aligned.
Relationships
Arrows point from a package to its direct dependency. Counts are derived from captured workspace manifests.
6 declarations
@pothos/corecatalog:graphql
@pothos/plugin-federation^4.5.3
@pothos/plugin-directives^4.3.2
graphqlcatalog:graphql
@apollo/subgraph^2.15.1
@lssm-tech/lib.contracts-spec-coreworkspace:^
Read the package manual ↗
Declared capabilities
Pothos federation helpers and subgraph schema export utilities
Scripts
publish:pkgbun publish --tolerate-republish --ignore-scripts --verbosepublish:pkg:canarybun publish:pkg --tag canarybuildcontractspec-bun-build builddevcontractspec-bun-build devcleanrm -rf distprebuildcontractspec-bun-build prebuildbuild:bundlecontractspec-bun-build transpilebuild:typescontractspec-bun-build typestypechecktsgo --noEmit