The API document names settings, routes and behaviour instead of entity, controller, options and interface types #302

Closed
opened 2026-11-05 11:01:36 -05:00 by claude · 0 comments
Owner
  • Priority: low
  • Agent: coder, then api-regen in the same PR
  • Depends on: #40, #41
  • Decisions: none

Why

#40 removed every *Service and *Repository class name from the OpenAPI text, the pattern its acceptance grep checks. The verifier of #40 found more internal type names that the grep cannot see. They mean nothing to an API caller and churn the snapshot when code is renamed, which is the same problem.

Kind Examples in src/angular/openapi/swagger.json About
*Entity DnsClientGroupEntity, DnsFilterListEntity, DhcpScopeEntity, DnsClientEntity, DhcpTagRuleEntity, TsigKeyEntity 25
*Controller FilterPatternPreviewController, ClientGroupsController, FilterListEntriesController, SmtpSettingsController, SelfUpdateController, AcmeSettingsController, TwoFactorController 25
Interfaces and other types IClusterConfigSyncApplier, IManagedServiceRegistry, IAcmeAccountStore, IDataProtector, SignedZoneCache, AuthoritativeZoneCache, DnsAccessControlRuleCache, ClusterSyncConflictResolver, ReloadableTlsCertificateProvider, DnsOverTlsListener 20
*Options PtrSyncOptions, CaaAutoManagementOptions, OidcSsoOptions, AdminLoginRateLimitOptions, TlsCertificateOptions, ZoneTransferOptions 40

What changes

  • Reword the XML docs behind the *Entity, *Controller, interface and cache hits to describe behaviour or name the route (GET /api/...), as #40 did. Doc text only, no API shape change.
  • *Options names: replace each with the setting the operator sees (its config path, such as DnsServer:PtrSync, or its NINLIL_* variable), so the text stays useful without a C# name.
  • Then regenerate the snapshot and client (AGENTS.md "Changing the REST API").

Acceptance

  • grep -oE "\b(I[A-Z][a-z]+[A-Za-z]*|[A-Z][a-z]+[A-Z][A-Za-z]*(Entity|Controller|Options|Cache|Handler|Provider|Resolver|Listener|Store|Applier|Aggregator|Registry|Registration))\b" src/angular/openapi/swagger.json lists no internal type names. Schema names of the API itself (request and response models) stay, and each other remaining hit is justified in the PR.
  • Only text changes in the snapshot diff.

Source

Verifier report on the #40/#41 branch (PR for feature/40-api-doc-no-class-names).

- **Priority:** low - **Agent:** coder, then api-regen in the same PR - **Depends on:** #40, #41 - **Decisions:** none ### Why #40 removed every `*Service` and `*Repository` class name from the OpenAPI text, the pattern its acceptance grep checks. The verifier of #40 found more internal type names that the grep cannot see. They mean nothing to an API caller and churn the snapshot when code is renamed, which is the same problem. | Kind | Examples in `src/angular/openapi/swagger.json` | About | |---|---|---| | `*Entity` | `DnsClientGroupEntity`, `DnsFilterListEntity`, `DhcpScopeEntity`, `DnsClientEntity`, `DhcpTagRuleEntity`, `TsigKeyEntity` | 25 | | `*Controller` | `FilterPatternPreviewController`, `ClientGroupsController`, `FilterListEntriesController`, `SmtpSettingsController`, `SelfUpdateController`, `AcmeSettingsController`, `TwoFactorController` | 25 | | Interfaces and other types | `IClusterConfigSyncApplier`, `IManagedServiceRegistry`, `IAcmeAccountStore`, `IDataProtector`, `SignedZoneCache`, `AuthoritativeZoneCache`, `DnsAccessControlRuleCache`, `ClusterSyncConflictResolver`, `ReloadableTlsCertificateProvider`, `DnsOverTlsListener` | 20 | | `*Options` | `PtrSyncOptions`, `CaaAutoManagementOptions`, `OidcSsoOptions`, `AdminLoginRateLimitOptions`, `TlsCertificateOptions`, `ZoneTransferOptions` | 40 | ### What changes - Reword the XML docs behind the `*Entity`, `*Controller`, interface and cache hits to describe behaviour or name the route (`GET /api/...`), as #40 did. Doc text only, no API shape change. - `*Options` names: replace each with the setting the operator sees (its config path, such as `DnsServer:PtrSync`, or its `NINLIL_*` variable), so the text stays useful without a C# name. - Then regenerate the snapshot and client (AGENTS.md "Changing the REST API"). ### Acceptance - [ ] `grep -oE "\b(I[A-Z][a-z]+[A-Za-z]*|[A-Z][a-z]+[A-Z][A-Za-z]*(Entity|Controller|Options|Cache|Handler|Provider|Resolver|Listener|Store|Applier|Aggregator|Registry|Registration))\b" src/angular/openapi/swagger.json` lists no internal type names. Schema names of the API itself (request and response models) stay, and each other remaining hit is justified in the PR. - [ ] Only text changes in the snapshot diff. ### Source Verifier report on the #40/#41 branch (PR for `feature/40-api-doc-no-class-names`).
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
lantea-one/ninlil#302
No description provided.