Repository navigation
docs(ai): AI with Leantime section, with a tested Keycloak SSO walkthrough - #66
Merged
Merged
Conversation
…rough - Overview: AI helping you run Leantime, and AI working in Leantime (MCP). - Working with AI assistants: giving the assistant the real docs (.md pages), what never to paste, how to check answers, a starter prompt. - Glossary of hosting, Docker, configuration and sign-in terms. - Keycloak single sign-on with Leantime's built-in OIDC, carried out end to end by an AI assistant on Leantime 3.14.0 + Keycloak 26.8.2 (Docker): exact Keycloak 26 labels, PKCE, the two errors it hit (issuer mismatch, unverified email) with fixes, LEAN_OIDC_AUTO_DISCOVER for one-machine tests, the mobile app note (needs AdvancedAuth) and prompts to use. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FGYRyhyPHQyrtvsu5aawzi
There was a problem hiding this comment.
🟡 Changes recommended
The Keycloak guide requires PKCE on versions that do not support it, risking sign-in failures, while the glossary incorrectly equates API key service accounts with personal user identities.
2 open issues
What changed in this PR
Adds an AI with Leantime documentation section covering AI-assisted administration and connecting assistants to Leantime through MCP.
Changes:
- Introduces guidance on sharing documentation, protecting secrets, and checking AI-generated advice.
- Adds a beginner glossary and a Keycloak OIDC walkthrough with troubleshooting and assistant prompts.
- Groups the new pages and existing MCP guide in the sidebar.
| File | Description |
|---|---|
ai/working-with-ai.md |
Practical guidance for using AI assistants safely and checking their answers. |
ai/README.md |
Overview linking AI-assisted administration and MCP integration. |
ai/keycloak-sso.md |
Keycloak setup steps, troubleshooting, and AI prompts. |
ai/glossary.md |
Plain-language definitions for hosting, configuration, and authentication. |
_sidebar.md |
Adds the AI section and links to its guides and MCP documentation. |
Review effort: Balanced
|
|
||
| **Two-factor authentication (2FA).** A second step at login, usually a code from an authenticator app. | ||
|
|
||
| **API key** / **personal access token.** A long secret that lets a script or AI assistant use Leantime's API in your name. Treat it like a password. |
|
|
||
| - **Time:** about 30 minutes | ||
| - **Level:** Some experience. You can edit Leantime's settings and you have an administrator account in Keycloak. | ||
| - **You need:** Leantime 3.13 or later, a Keycloak server, and access to Leantime's `.env` file (or its Docker environment). |
…for PKCE) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FGYRyhyPHQyrtvsu5aawzi
Leantime trims it from both LEAN_OIDC_PROVIDER_URL and the token's iss before comparing (Oidc::trimTrailingSlash), matching #60. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FGYRyhyPHQyrtvsu5aawzi
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Adds an AI with Leantime section (
ai/) and puts the MCP guide under it in the sidebar.ai/README.md(overview)ai/working-with-ai.md.mdversion), what never to paste, how to check its answers, a starter promptai/glossary.mdai/keycloak-sso.mdHow the Keycloak guide was tested
An AI assistant (Claude Code) set it up from scratch on Leantime 3.14.0 and Keycloak 26.8.2 in Docker, through Keycloak's admin screens. It ended with a Keycloak user signed in to Leantime and given an account as Editor (role 20,
source = oidc). Every Keycloak label in the guide is the one on screen in 26.8.It hit two real errors, both now in the guide with their fixes:
The received provider … does not match the local setting …:LEAN_OIDC_PROVIDER_URLmust equal the token's issuer exactly. On one machine this needsLEAN_OIDC_AUTO_DISCOVER, a setting that exists in core (Environment.php) but isn't inconfig/sample.envor the auth docs.Your identity provider reports that the email address of your account is not verified.: Keycloak users need Email verified.It also confirmed PKCE works with Keycloak's Require PKCE on, and that Keycloak returns
Invalid parameter: redirect_urifor a wrong callback.Mobile app: core OIDC brokers mobile sign-in only when AdvancedAuth is enabled (
Oidc/Controllers/Login.php:50). The guide says so; Keycloak needs nothing extra.Follow-ups
LEAN_OIDC_AUTO_DISCOVERtoconfig/sample.envand the authentication page. docs(auth): correct the OIDC and LDAP guides against the code #60 is open on that page, so I didn't touch it here..mdaddresses on the current site.🤖 Generated with Claude Code
https://claude.ai/code/session_01FGYRyhyPHQyrtvsu5aawzi