DEV Community

Cover image for Connect Codex to an Existing Business System with MCP
Uncle Pushui
Uncle Pushui

Posted on

Connect Codex to an Existing Business System with MCP

In this demo, a single Codex conversation goes from an empty student roster to a student profile with a photo and a training record with two scores. You can open Cabloy Admin to see what was saved.

The demo uses the student training example built into CabloyJS. A student is the master record, each training record is a first-level detail, and each subject score is a second-level detail. Cabloy already models those relationships. Codex can work with them through the Model Context Protocol (MCP) without a separate ontology for the agent.

Run the student training workflow

Look up students and create a record

Start with a read-only request in a new chat.

Please list all students.

The connected development instance returns zero students. In the same chat, ask Codex to create one.

Please create a new student. Name: Musk.

Codex asks for the mobile number and training stage because Cabloy requires both. In the demo, I enter the test number 123456789011 and select Progress Track. When Codex presents the proposed write, I review the values and click Allow once. Codex then returns a link to the new record in Cabloy Admin.

Codex asks for approval to create Musk’s record with the test mobile number and training stage

Attach a photo to the same student

Attach a photo in the same chat and send the next request.

Please add a photo for this student.

Codex prepares a square crop and asks for approval to upload the image. After the upload and update, reopening the student profile shows the photo attached to the record.

The uploaded square profile photo on the student record in Cabloy Admin

Record the training and verify both scores

This student attended the “Full-Stack Development” training, scoring 98 points in “Backend Development” and 90 points in “Frontend Development.”

“This student” refers to Musk, whose record we just created. I review the proposed update and approve it once. Then, in Cabloy Admin, I open Musk’s Student Training Records and select Full-Stack Development. The detail table shows 98 for Backend Development and 90 for Frontend Development, both under the same training record.

The saved training record in Cabloy Admin shows Backend Development at 98 and Frontend Development at 90

Connect Codex to Cabloy Admin

Copy the configuration prompt

With the Cabloy Basic development environment set up, run this command from the project root.

npm run dev
Enter fullscreen mode Exit fullscreen mode

Open http://localhost:7102/ and go to Admin → Account Settings → MCP quick start. Under Configure the MCP Server, click Copy prompt. In this local setup, the prompt points to http://localhost:7102/mcp/admin.

The Cabloy Admin MCP quick start page with the generated configuration and Copy prompt button

Authenticate the MCP server

Paste the prompt into Codex. It requests the Cabloy Skills and the Admin MCP server configuration. In the recording, Codex finds both already in place, but its live connection check fails. I then open Settings → Plugins → MCPs and click Authenticate beside the Cabloy Admin server.

The MCPs tab in Codex settings with the Authenticate button next to the Cabloy server

In the browser, review the application, the Cabloy Admin resource, and the available access scopes. For this workflow, select a scope that allows the required writes and click Approve. Once the browser shows Authentication complete, return to Codex, start a new chat, and ask it to list the students. The browser authorization grants access to the server, while Allow once in the recording approves a specific tool call.

How Cabloy reuses the existing business model

Cabloy exposes selected Vona Controller Actions as MCP tools, so the tools use the existing API contracts, validation, and business permissions. Cabloy’s Skills guide the agent through steps such as looking up a record, making an authorized change, and returning a link to the saved record. The student, training records, and subject scores stay in Cabloy, where the team can verify them in the same Admin interface. Cabloy project and MCP integration

Top comments (0)