#38356·dolibarr

AI MCP Server and chat assistant

Author: sonikfCreated May 20, 2026Updated Sep 21, 2026

Hi community members and contributors

Mcp server and assistant is officially in core, see branch develop and v. 24.0.0, still in experimental mode though and a lot of work still needs to be done, but this mean plenty of time to be ready by v. 25.00!

For initial features and screenshots see https://github.com/Dolibarr/dolibarr/pull/37408 and https://github.com/Dolibarr/dolibarr/pull/37888 (to test add MAIN_FEATURES_LEVEL 2 in Other Setup)

Having no other way I'd like to use this issue as a call for collaboration.

Anyone willing to help/participate in any way(documentation, discussion, ideas, suggestions, feature requests, bug fixing, developing) please do so in comments and will be added here. Any dev having permission to modify this please do so freely. I'm here to facilitate, not to command and time permitting available to test or review just tag me @sonikf

My only request please make privacy orientated contributions!

kudos to community members @Pichinov-Jose for immediately fixing bugs and constantly adding features, @braito4 for adding new privacy orientated tools, @EchoLoGeek for UI|UX design (again thank you), @momodemo333 for MCP improvement and OAuth

Following list, in alphabetical order for now, is compiled from suggestions, my todo's, unfinished features i removed from my original pr and features i would like see added(nothing is written in stone though) and will act as a mini roadmap and issue/feature tracker. Of course i will update it asap with your own suggestions and feature requests.

@eldy we count on your guidance and since this was your wish please help prioritizing things to do and share your vision in making this true!



  • Agentic Workflows: move from single-tool execution to multi-step tool chaining (e.g., "Find Vendor A unpaid invoices -> Pay the oldest one"). To be implemented on the MCP Tasks extension (io.modelcontextprotocol/tasks: durable handles, tasks/get polling, tasks/update mid-flight input), with confirmation stops via the write-safety gate below

    • interim milestone: bounded loop (max N steps, read results fed back, every write stopping at the confirmation gate) @Pichinov-Jose
  • AI assistant page context awareness. This enables the system to execute context-specific actions—such as summarizing a filtered list of records, or analyzing dashboard trends #40380 @sonikf

    • Tab-aware intent. The documents tab already identifies its object. We need ECM/file read tools land so prompts like "what files does this have" and "attach this to that" work.
      • list_documents: files attached to a business object, metadata only, whitelisted elements @sonikf
    • Generative actions on context. Translate/summarize/draft against the viewed object ("summarize this proposal for the customer").
    • Linked-object awareness. "The order behind this invoice": traversing element_element from the context object, maybe through a get_linked_objects tool.
    • Richer list semantics. Sort order and column visibility in the list context, aggregate intents beyond sums (group by status, oldest N) all server computed.
    • Multi-object context. Comparing two cards (split view, or "compare this to invoice X") requires context to carry more than one anchor, the JSON shape already permits it.
    • Guided help ("how do I…"). Context turns the assistant into an in-app guide: "how do I create an invoice" answered with the actual click path from the page the user is on ("you are on the thirdparty card, use Create → Invoice, or ask me to create it for you").
  • Custom Prompts: User-configurable prompts for specific tasks The admin-side infrastructure already exists in ai/admin/custom_prompt.php (stores JSON in AI_CONFIGURATIONS_PROMPT). We need per-user saved prompts and a quick-insert UI in the chat.

  • Documentation: Tool Development Guide, Integration examples with different AI clients etc

  • More MCP tools

    • #38699 @braito4
    • #38700 @braito4
    • #39434 create_product tool (products/services) @Pichinov-Jose
    • #39856 MCP API bridge — tools derived from enabled REST API endpoints (read-only, explicit method whitelist + enrichment layer, flag AI_MCP_API_BRIDGE) @Pichinov-Jose
      • enrichment passes: thirdparties ,products, invoices ,categories` #40138 @sonikf
      • enrichment passes: proposals, tickets, projects, tasks, agendaevents, interventions, contracts, members, subscriptions, stockmovements, warehouses, expensereports #40311 @Pichinov-Jose
      • mechanism: whitelist engine, merge layer, auth bridge (shipped in #39856) @Pichinov-Jose
      • dynamic endpoint scan via dolGetModulesDirs() #40092 @momodemo333
      • Restler inline validation tags translated into JSON Schema #40437 @momodemo333
      • reuse Restler/swagger metadata instead of the docblock parser @momodemo333 measured-and-declined see here
      • a failing tool says why it failed #40480 @momodemo333
      • per-tool Dolibarr rights enforced on every MCP tool call #40520 @sonikf
      • CRUD/CSRF hardening ported to develop #40359 @Pichinov-Jose
      • get_product_details fatal on a removed Categorie method #40463 @sonikf
      • cache the generated tool definitions across requests #40565 @Pichinov-Jose
      • on-the-fly products get their supplier price line and a review category #40566 @Pichinov-Jose
      • no POST/PUT whitelisted until the write-safety gate lands (see spec-alignment section)
      • per-method module dependency: getStock needs Stock and throws a bare 403; not exposed today, so it bites only when whitelisted (the includestockdata parameter degrades silently and needs nothing)
      • admin toggle for AI_MCP_API_BRIDGE + lang keys in the tool access page @sonikf
      • multicompany entity switching in the auth bridge: Mcp-Entity header, validated against the caller's entity after authentication @sonikf
      • no bank, donation or holiday endpoints in the whitelist, though the REST classes exist @sonikf
  • MCP spec 2026-07-28 alignment

    • server/discover + per-request _meta protocolVersion/capabilities with UnsupportedProtocolVersionError, dual-stacked with the 2025-11-25 initialize handshake for legacy clients; resultType on all results; error-code audit (-32002-32602, keep out of reserved -32020..-32099) #40356 @sonikf
    • Mcp-Method/Mcp-Name header validation + HeaderMismatchError (enforcement point for Rate Limiting above) #40356 @sonikf
    • ttlMs/cacheScope on list/read results (delivers the wire half of Schema Caching above; cacheScope:"private" also serves per-user Custom Prompts and the GDPR requirement that intermediaries never cache business data)
      • server/discover still advertises cacheScope:"public": wrong since #40520 filters tools/list per caller, so an intermediary may not share it @sonikf
    • Drop the advertised logging capability (feature deprecated; we never emit notifications/message) #40356 @sonikf
    • Write-safety gate on the MRTR pattern (resultType:"input_required" + inputRequests + signed, expiring requestState) instead of a custom confirm flow: every write is gated, deletes included, before any POST/PUT is whitelisted in the API bridge @sonikf
    • callers authenticated as Dolibarr users instead of one shared service identity #40425 @momodemo333
    • OAuth series to target Client ID Metadata Documents (RFC 7591 Dynamic Client Registration now deprecated), RFC 9207 iss validation, issuer-keyed credentials @momodemo333
    • AI audit ledger (#38331 discussion): adopt the _meta OpenTelemetry conventions (traceparent/baggage) as the correlation ID across ledger events @braito4
    • Opportunity, no obligation: inputSchema now allows full JSON Schema 2020-12 — bridge enrichments can use real enums for params like invoice status
    • Headless identity: adopt the OAuth Client Credentials extension (io.modelcontextprotocol/oauth-client-credentials) as phase two of the OAuth series — machine clients bound to dedicated Dolibarr service users (per-integration, conscious rights; not a shared AI_MCP_USER_ID); required by Scheduled Tasks/Agentic Workflows which run with no user present; write-gate rule for M2M context: deny or pre-authorized scope, never auto-confirm @momodemo333
  • EU AI Act and GDPR responsibilities for developers and users #38331

    • Improve privacy guard (privacy_guard.class.php)

      • Salted Tokens #40472 @sonikf

      • extrafields flagged as personal data never sent to the provider #40490 @sonikf

      • mask the API key in logged provider URLs #40579 @Pichinov-Jose

      • Chunking & Memory Management (Performance) needed for summarisation

      • Tokenize products and services too if possible

    • AI events audit log proposed https://github.com/Dolibarr/dolibarr/issues/38356#issuecomment-4545582809 by @braito4

      • log confirmed tool executions into llx_ai_request_log #40559 @Pichinov-Jose
      • token usage and cost reporting in the request log #40581 @Pichinov-Jose
    • Force privacy settings to EU users maybe

    • Existing AI functionality does nor respect EU privacy laws

      • inline generation (knowledge records, email forms and templates, tickets, extrafield aiprompt, website pages, product descriptions, image generation) posts to ai/ajax/generate_content.php and calls Ai::generateContent() directly: no redaction even when AI_PRIVACY_REDACTION is on, and no request log. One endpoint to change, all surfaces inherit it @sonikf
      • per-task templates and page context for those same inline surfaces, on the generative router @sonikf
  • Hybrid MCP + RAG

  • Rate Limiting: basic IP/API-key throttling on the MCP entry point, keyed also on the spec-mandated Mcp-Method/Mcp-Name headers (spec 2026-07-28) so limits can be per-tool and enforceable by reverse proxies without body parsing — header validation lands in the spec-alignment PR below

  • Scheduled Tasks: ability to schedule recurring operations — protocol side via the MCP Tasks extension (shared with Agentic Workflows), execution side via Dolibarr cron; identity via the OAuth Client Credentials extension (service user per client); storage, executor, permission model for deferred execution still to design

  • Schema Caching: cache tool/prompt/resource definitions (needed by both the internal chat, which bypasses MCP wire, and the MCP server; urgency raised by the #40092 dynamic scan) and advertise the TTL on the wire via the ttlMs/cacheScope fields required by spec 2026-07-28; includes deterministic tools/list ordering — caching in #40565, the wire half still open, ordering already deterministic

  • Streaming: Server-Sent Events (SSE) for parse_intent.php to improve perceived latency DEPRECATED in mcp spec we should avoid using in internal assistant too

  • AI permisions/rights

    • #38312 @Pichinov-Jose
  • Tool access control #38668 @sonikf

  • UI|UX

    • Assistant popup overlay from top-toolbar icon #38311 @Pichinov-Jose
    • Confirmation handling + error messages #38625 @sonikf
    • AI Assistant Popover #38756 @EchoLoGeek
    • AI design #38789 @EchoLoGeek
    • #38828 @EchoLoGeek
    • #39877 @Pichinov-Jose
    • #39878 @Pichinov-Jose
    • #39898 @Pichinov-Jose
    • #40199 @sonikf
    • privacy and page-context improvements #40472 @sonikf
    • several attachments per message, HEIC photo support #40497 @Pichinov-Jose
    • attachment answers no longer capped at 4096 tokens #40505 @Pichinov-Jose
    • attachment max-files cap enforced server-side #40561 @Pichinov-Jose
    • session expiry reported instead of a cryptic JSON error #40560 @Pichinov-Jose
    • intent classifier knows receptions and shipments exist #40499 @Pichinov-Jose
    • classifier vocabulary for tickets, members, agenda, interventions, categories #40564 @Pichinov-Jose
    • pin past exchanges as opt-in context for follow-up questions #40569 @Pichinov-Jose
    • accented names rendered as raw HTML entities #40575 @Pichinov-Jose
    • Tools menu entry to reach the assistant full page #40578 @Pichinov-Jose