petarivanovv9/graphql-api-ts-ddd-clean-architecture
54.9
Adequate · 21 September 2026
658
lines of production code
TypeScript
primary language
4
measurements over time
What this system is
This system is a TypeScript-based GraphQL API server that manages user accounts and billing information. It exposes a unified GraphQL interface to query user and account details, as well as to manage card payment profiles. The architecture is modular, separating domain logic, data access, and GraphQL resolvers for both account and billing services.
Features
Add GraphQL schema and resolvers for account and user data
A new GraphQL module is introduced for the account module, defining a \Query.viewer\ field that returns the current user and a \User.account\ field that resolves to account details. The implementation uses the \tsyringe\ library for dependency injection to resolve the \AccountQueries\ service within the resolvers, providing a concrete API for fetching account information.
src/modules/account/gql · medium confidence
Add GraphQL schema and resolvers for card payment profile management
A new GraphQL module is introduced for the billing system, exposing a \cardPaymentProfiles\ field on the \Account\ type to retrieve associated profiles, and a \deleteCardPaymentProfile\ mutation to remove them. The resolvers are wired using dependency injection (tsyringe) to interact with domain-level query and mutation classes.
src/modules/billing/gql · high confidence
Add billing domain models for address and card payment profiles
Introduced new domain models for the billing module: an Address value object and a CardPaymentProfile entity. The Address class encapsulates location details (country, address, city, zip, etc.) with immutable properties, while the CardPaymentProfile entity manages cardholder name information with a unique identifier. These models provide the foundational data structures for processing billing information.
src/modules/billing/domain/models · high confidence
Add card payment profile repository and mapper
Introduced a new CardPaymentProfileMapper to transform external payment source data into internal domain models, and a corresponding CardPaymentProfileRepo that queries and maps these profiles by account email, while also providing a placeholder delete operation.
src/modules/billing/repositories · high confidence
Added account query and service implementations
The account module now includes a new AccountQueries class for retrieving account data using the transaction script pattern, and an AccountService class with a placeholder implementation for fetching accounts by company. These changes introduce the core domain logic for account retrieval and management within the account module.
src/modules/account/domain · high confidence
Added delete card payment profile mutation
A new mutation, DeleteCardPaymentProfile, has been added to the billing domain. This mutation allows users to delete a card payment profile by its ID, utilizing a container-scoped lifecycle for dependency injection.
src/modules/billing/domain/mutations · high confidence
Introduce Account module with DTOs and service layer
Added a new Account module containing TypeScript interfaces for UserDto and AccountDto, along with an AccountModule class that exposes getUserById and getAccountByCompany methods. The module integrates with an AccountService to retrieve account data by company, providing a structured way to fetch and map account-related information.
src/modules/account/api · high confidence
Introduce GraphQL schema and server entry point
The server now exposes a unified GraphQL API via Apollo Server on port 4000. The schema includes a \Query\ with a \viewer\ field returning a \User\ (with \id\, \name\, \email\, and \account\), and a \Mutation\ for \deleteCardPaymentProfile\. The \User\ type links to an \Account\ which contains \cardPaymentProfiles\ (each with \Address\ details). A \DeleteCardPaymentProfileInput\ and \DeleteCardPaymentProfilePayload\ are also defined. The server entry point (\src/index.ts\) merges resolvers from the \account\ and \billing\ modules and reads the generated schema (\src/schema.generated.graphql\) and TypeScript types (\src/resolvers.generated.ts\).
src · high confidence
Behavioural changes
Add GqlModule type definition
A new TypeScript file, src/modules/gqlModule.ts, has been added to define the GqlModule type, which includes a resolvers property of type GqlResolvers. This change introduces a new type definition for the GraphQL module, likely to support type-safe resolver integration.
src/modules · medium confidence
Added .keep files to preserve empty directories
Empty directories in the account repositories, billing API, and billing domain services modules now contain .keep files. This ensures these directories are tracked by version control and persist in the repository structure, preventing them from being lost or ignored by the build system.
src/modules/account/repositories, src/modules/billing/api, src/modules/billing/domain/services · high confidence
Automated GraphQL schema generation
A new build script has been added to automatically merge GraphQL type definitions from the src/modules directory and generate a consolidated schema file (schema.generated.graphql). This change introduces a new automated step in the build process that combines individual module schemas into a single output file, streamlining the schema management workflow.
scripts · high confidence
Test coverage
Added test infrastructure and utility helpers; Added unit tests for CardPaymentProfileQueries.
Dependencies
Initial project setup with TypeScript, GraphQL, and testing tooling
Added package.json and package-lock.json to establish the project's dependency graph. This introduces the runtime dependencies @apollo/server, graphql, reflect-metadata, and tsyringe, along with development tools including Jest, ESLint with Airbnb and Prettier configurations, GraphQL Codegen, and TypeScript 5.0.4. These dependencies enable a TypeScript-based GraphQL API with automated schema generation, linting, and testing capabilities.
(dependencies) · medium confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 55 → 55 (-0.3)
- Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.
Lenses
- Code Health 87 → 86 (-0.5)
- Architecture 69 → 69 (+0.0)
- Maturity 66 → 66 (+0.0)
- Readiness 36 → 39 (+2.2)
- Security 75 → 72 (-3.0)
Resolved (52)
- Coverage not included — suite not readable by the collector
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- …and 32 more
New (60)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Critical CVE: [GHSA redacted] (package-lock.json)
- Documentation: no contributor guidance (README.md)
- Documentation: no usage examples (README.md)
- End-of-life runtime: Node.js 18
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- High CVE: [GHSA redacted] (package-lock.json)
- …and 40 more
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
petarivanovv9/graphql-api-ts-ddd-clean-architecture was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 21 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit b50470329bed9eca27ab62558704330c839d91c0 — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-b84573e22831.