The OpenAPI document declares the ApiToken authentication scheme, and its SSO example and login description are corrected #464

Merged
claude merged 7 commits from feature/447-api-document-token-scheme into develop 2026-11-14 11:02:12 -05:00
Owner

Closes #447
Closes #461

The API document declares the ApiToken scheme (#447). /swagger/v1/swagger.json lists ApiToken beside Bearer, as an apiKey in the Authorization header, and offers the two as alternatives. In Swagger UI's Authorize dialog a user types the word ApiToken, a space and the token. The description holds no angle-bracket placeholder, because Swagger UI renders descriptions as Markdown and drops such text; a test guards that.

Two texts in the document (#461). The SSO settings examples use the display name "Single Sign-On" (the option's default, and the value the wiki uses) instead of a product name. The login description says a 423 is answered only for an account with lockout enabled and a stored lockout end date in the future, which nothing in the API sets.

Docs. README "REST API" and the wiki page pages/docs/rest-api.md explain both Authorize fields and that only one is filled: with both filled Swagger UI sends the API token field's value.

Snapshot and client. Regenerated and committed together, apart from the backend commits. Every generated service method gains a credential lookup for ApiToken beside the one for Bearer. The console configures no credentials and sets its Authorization header in its interceptor, which runs after the generated code, so its requests are unchanged.

Checked. A verifier ran the scheme on a private instance (ApiToken <token> 200, the raw token 401, Bearer 200), compared the served document with the snapshot, traced the client, and rejected the first version for the placeholder that Swagger UI dropped; that and its smaller findings are fixed in the last three commits. Build: 0 warnings. Ninlil.Web.Tests: 2358 of 2358 with a built console. Console: lint and format clean, 1721 of 1721 tests. Link check: 0 problems.

Follow-ups filed as #463 (XML list tags in two descriptions, per-operation security requirements, a note on the generated client's ApiToken default).

🤖 Generated with Claude Code

https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK

Closes #447 Closes #461 **The API document declares the `ApiToken` scheme (#447).** `/swagger/v1/swagger.json` lists `ApiToken` beside `Bearer`, as an `apiKey` in the `Authorization` header, and offers the two as alternatives. In Swagger UI's Authorize dialog a user types the word `ApiToken`, a space and the token. The description holds no angle-bracket placeholder, because Swagger UI renders descriptions as Markdown and drops such text; a test guards that. **Two texts in the document (#461).** The SSO settings examples use the display name "Single Sign-On" (the option's default, and the value the wiki uses) instead of a product name. The login description says a 423 is answered only for an account with lockout enabled and a stored lockout end date in the future, which nothing in the API sets. **Docs.** README "REST API" and the wiki page `pages/docs/rest-api.md` explain both Authorize fields and that only one is filled: with both filled Swagger UI sends the API token field's value. **Snapshot and client.** Regenerated and committed together, apart from the backend commits. Every generated service method gains a credential lookup for `ApiToken` beside the one for `Bearer`. The console configures no credentials and sets its `Authorization` header in its interceptor, which runs after the generated code, so its requests are unchanged. **Checked.** A verifier ran the scheme on a private instance (`ApiToken <token>` 200, the raw token 401, Bearer 200), compared the served document with the snapshot, traced the client, and rejected the first version for the placeholder that Swagger UI dropped; that and its smaller findings are fixed in the last three commits. Build: 0 warnings. `Ninlil.Web.Tests`: 2358 of 2358 with a built console. Console: lint and format clean, 1721 of 1721 tests. Link check: 0 problems. Follow-ups filed as #463 (XML list tags in two descriptions, per-operation security requirements, a note on the generated client's `ApiToken` default). 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Closes #447

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Closes #461

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Refs #447

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Refs #447

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Refs #447
Refs #461

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
Refs #447

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
The OpenAPI snapshot and Angular API client now include the ApiToken scheme and the neutral SSO example label
All checks were successful
Build / Compute Version (pull_request) Has been skipped
Build / Test .NET on Windows (pull_request) Has been skipped
Build / Windows Test Gate (pull_request) Has been skipped
Build / Test Admin Console (pull_request) Successful in -1m4s
Build / Lint and Script Tests (pull_request) Successful in -2m2s
Build / Test .NET (pull_request) Successful in 3m2s
Build / Stage Draft Release (pull_request) Has been skipped
Build / Pack and Push NuGet Packages (common) (pull_request) Has been skipped
Build / Pack and Push NuGet Packages (dhcp) (pull_request) Has been skipped
Build / Pack and Push NuGet Packages (dns-core) (pull_request) Has been skipped
Build / Pack and Push NuGet Packages (dns-server) (pull_request) Has been skipped
Build / Build Binary (linux-amd64) (pull_request) Has been skipped
Build / Build Binary (linux-arm64) (pull_request) Has been skipped
Build / Build Binary (macos-amd64) (pull_request) Has been skipped
Build / Build Binary (macos-arm64) (pull_request) Has been skipped
Build / Build Binary (windows-amd64) (pull_request) Has been skipped
Build / Build Arch Linux Packages (pull_request) Has been skipped
Build / Build and Test Deb and RPM Packages (pull_request) Has been skipped
Build / Build and Push Image (pull_request) Has been skipped
Build / Smoke Test the Windows Binary (pull_request) Has been skipped
Build / Publish Release (pull_request) Has been skipped
Build / Pipeline (pull_request) Successful in 0s
0ced4fd0d1
Closes #447
Closes #461

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK
claude merged commit 6b457618bb into develop 2026-11-14 11:02:12 -05:00
claude deleted branch feature/447-api-document-token-scheme 2026-11-14 11:02:12 -05:00
Sign in to join this conversation.
No reviewers
No milestone
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.

Dependencies

No dependencies set

Reference
lantea-one/ninlil!464
No description provided.