Evolve Your MDK App with Agentic AI using MCP Tools
This tutorial demonstrates how to enhance an existing MDK project created with agentic AI by using MCP tools to modify pages, add features, and generate supporting artifacts. You will also learn how to access MDK documentation and client APIs directly through the MCP-enabled IDE for faster, context-aware development.
Overview
You will learn
- How to enhance an existing MDK application using agentic AI
- How to access MDK documentation and Client APIs using MCP tools
Prerequisites
Steps
In this step, you will use the agent to ask project-aware questions about MDK. The agent responds in the context of your existing project, helping you understand Client APIs, implementation choices, and related documentation. You are free to ask the agent any questions related to MDK. To demonstrate this capability, the following steps use a concrete example from the generated project to explore a Client API and its documentation.
In the Cline window, copy and paste the following prompt into the input field and execute it.
ShellExplain this line. let result = clientAPI.actionResults.AppUpdate.data;
MDK The MCP client analyzes the code and provides a detailed breakdown of the statement.

MDK Generated responses may differ from the examples shown in this tutorial. Minor variations in code or output are expected.
In the Cline window, execute the following prompt:
ShellI want to allow business users to upload media files to the backend. However, I want to limit the file size to a maximum of 2 MB. Refer documentation and suggest how can I achieve this?The MCP client (Cline) recognizes that the MDK MCP server should be used and executes the request using the
mdk-docstool.
MDK The generated response includes examples showing how to restrict file size using a Form Cell Attachment control. It also generates a
READMEfile containing reference examples for different use cases.
MDK Generated responses may differ from the examples shown in this tutorial. Minor variations in code or output are expected.
You can also ask general conceptual questions, for example:
ShellHow does an offline app work on a mobile device?The MCP client provides a detailed explanation in the context of MDK offline applications.
In this step, you will use the agent to modify existing UI screens based on your requirements. You will change the main page layout from a classic list to a bottom bar container and reorder the Sales Orders list page to display more meaningful information.
In the Cline window, execute the following prompt:
ShellUpdate main page displaying all information in a bottom bar and include icons for each item. Remove com_sap.. , page caption and Sync options. Also re-generate the sales order list page displaying Order ID, Customer Name, price along with currency, style the status property (generate style classes if needed), and display the Date value in Date Time (DT) formatter. Once done, validate and deploy project.The MCP client generates the required updates, validates the project, and deploys it.

MDK Generated responses may differ from the examples shown in this tutorial. Minor variations in code or output are expected.
Ensure that you select the correct device platform tab above.
On the Main page, open the user menu and tap Check for Updates, When the New Version Available dialog appears, tap Now.

MDK Observe that the main page has been redesigned to use a bottom navigation layout, providing quick access to all defined entities.

MDK Tap Sales Orders to view the updated list page.

MDK
On the Main page, open the user menu and tap Check for Updates, When the New Version Available dialog appears, tap Now.

MDK Observe that the main page has been redesigned to use a bottom navigation layout, providing quick access to all defined entities.

MDK Tap Sales Orders to view the updated list page.

MDK
In this step, you will use the MCP agent to generate business logic that dynamically updates application data.
In the Cline window, execute the following prompt:
ShellInstead of just displaying text for the caption property (line 11) on the sales order list page, I want to additionally display the total number of sales orders. For example, Sales Orders (total count)
MDK The MCP client generates a MDK rule in JavaScript containing the required logic and binds it to the caption property. After validation, the project is automatically deployed. (Right-click
SalesOrderHeaders_List.pageto open it with text editor)
MDK Generated responses may differ from the examples shown in this tutorial. Minor variations in code or output are expected.
Ensure that you select the correct device platform tab above.
On the bottom navigation page, open the user menu and tap Check for Updates, When the New Version Available dialog appears, tap Now.

MDK Navigate to Sales Orders and verify that the total count appears in the page caption.

MDK
On the bottom navigation page, open the user menu and tap Check for Updates, When the New Version Available dialog appears, tap Now.

MDK Navigate to Sales Orders and verify that the total count appears in the page caption.

MDK
In this exercise, you enhanced an existing SAP MDK application using agentic AI powered by MCP tools. You learned how to interact with a project-aware agent to understand MDK Client APIs, explore documentation, and receive contextual guidance directly within the IDE. Using natural language prompts, you modified UI layouts, enhanced list pages, and implemented dynamic business logic.
With MCP-driven development, there are many opportunities to accelerate and simplify MDK application development. You are encouraged to apply these techniques in your own projects—experiment with different prompts, enhance additional features, and continue your MDK learning with agentic AI as your development companion.
Resources
Discussion
Share feedback on this tutorial or join the conversation in SAP Community.