Developer documentation
Plug anything into your MADATA workspace
Every <workspace>.madata.app workspace opens two
doors: an MCP server for AI assistants, and a
data API for your own code. Both read and write your
business data with your permissions.
The MCP server exposes more than 200 ready made business tools (KPIs, sales, accounting, payroll, journal entries…) to Claude, ChatGPT, Gemini or Mistral Le Chat. The data API exposes the raw models of the workspace to your code. Every call runs with the permissions of the connected user.
MCP server
An AI assistant acts on the workspace in a few clicks, with no code. One single address, you pick the workspace when signing in.
The MCP server ›Data API
Your program reads and writes the models of the workspace: contacts, quotations, invoices, stock, journal entries. XML-RPC or JSON-RPC.
The data API ›01Quick start
With an AI assistant, there is no key to paste. In Claude, ChatGPT, Le Chat or Claude Code, add an MCP server at this address, sign in to MADATA, pick the workspace, then authorize:
https://mcp.madata.africa/mcp
The steps for each assistant are in Connect an assistant.
With your code (scripts, Gemini CLI, Cursor, VS Code), use an MCP key and the workspace address:
- Create a key. In the MADATA portal, open
Mia → MCP tab → Create a key. It starts with
mia_and is shown only once. Restricted to the owner and the MADATA administrators of the workspace. Details. - Get the workspace address. It looks like
https://<workspace>.madata.app/mia/mcp. - Call it. A JSON-RPC
POSTwith theAuthorization: Bearerheader:
curl -s https://<workspace>.madata.app/mia/mcp \
-H "Authorization: Bearer mia_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}'
02What the MCP server can do
The catalog holds 204 tools (100 read, 104 write). The list actually visible depends on the installed modules, the user's permissions and the scope of the connection.
| Family | Examples |
|---|---|
| KPIs | get_kpi, get_cash_flow, get_crm_kpi, get_revenue_forecast |
| Business reads | search_sales, search_invoices, get_stock_card, query_records |
| Accounting | get_balance_sheet, prepare_vat_return, export_accounting, create_journal_entry |
| Writes | create_quotation, create_customer_invoice, register_payment, action_record |
| HR & payroll | create_payslip, validate_batch, send_payslip, generate_social_declaration |
| Budgets | get_budget_status, check_budget_availability, adjust_budget |
| Business apps | get_hotel_today, search_appointments, get_unpaid_rents, fleet_action |
| Communication | send_email, prepare_whatsapp_message, send_payment_followups |
The server also exposes 4 resources
(mia://kpi/current…) and 8 prompts
ready to use. Full list: Tool catalog.
03The data API, in a minute
When the ready made tool is no longer enough, the data API gives access to the models themselves. Same permissions, full control, and its own API key.
import xmlrpc.client
URL, DB, KEY = "https://<workspace>.madata.app", "prod_<workspace>", "your-key"
uid = xmlrpc.client.ServerProxy(f"{URL}/xmlrpc/2/common").authenticate(
DB, "[email protected]", KEY, {})
models = xmlrpc.client.ServerProxy(f"{URL}/xmlrpc/2/object")
customers = models.execute_kw(DB, uid, KEY, 'res.partner', 'search_read',
[[['customer_rank', '>', 0]]],
{'fields': ['name', 'email'], 'limit': 10})
Next: The data API, Authentication, Reading, Writing, Recipes.
04Conventions
- AI assistants
https://mcp.madata.africa/mcp: the same address for all, over OAuth 2.1.- Your code
https://<workspace>.madata.app/mia/mcp: one per workspace, withAuthorization: Bearer mia_….- Language
- Error messages and tool descriptions are in French.
- Name
- The platform is called MADATA.
A connection never elevates permissions: every call runs as the real user, with their native rights. Billed resources (users, companies, points of sale, apps) stay read-only: manage them in the portal.
05Support
Something missing, a tool misbehaving? Contact support from your client area, under My tickets, with the tool name and the time of the call: every call is logged.