<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>DelphiDevelopment Archives - scmGalaxy</title>
	<atom:link href="https://www.scmgalaxy.com/tutorials/tag/delphidevelopment/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.scmgalaxy.com/tutorials/tag/delphidevelopment/</link>
	<description>A Platform for Software Engineers</description>
	<lastBuildDate>Sat, 21 Feb 2026 07:13:16 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1</generator>
	<item>
		<title>TMS XData: Rapid REST API Development Framework for Delphi Developers</title>
		<link>https://www.scmgalaxy.com/tutorials/tms-xdata-rapid-rest-api-development-framework-for-delphi-developers/</link>
					<comments>https://www.scmgalaxy.com/tutorials/tms-xdata-rapid-rest-api-development-framework-for-delphi-developers/#respond</comments>
		
		<dc:creator><![CDATA[Vijay K]]></dc:creator>
		<pubDate>Tue, 22 Apr 2025 07:37:07 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[DelphiBackend]]></category>
		<category><![CDATA[DelphiDevelopment]]></category>
		<category><![CDATA[DelphiRESTAPI]]></category>
		<category><![CDATA[LowCodeAPI]]></category>
		<category><![CDATA[PascalProgramming]]></category>
		<category><![CDATA[RADStudio]]></category>
		<category><![CDATA[RESTfulServices]]></category>
		<category><![CDATA[TMSBusinessTools]]></category>
		<category><![CDATA[TMSXData]]></category>
		<category><![CDATA[XDataFramework]]></category>
		<guid isPermaLink="false">https://www.scmgalaxy.com/tutorials/?p=12129</guid>

					<description><![CDATA[<p>#WhatIsTMSXData 1. What is TMS XData? TMS XData is a high-level framework developed by TMS Software that allows Delphi (and [&#8230;]</p>
<p>The post <a href="https://www.scmgalaxy.com/tutorials/tms-xdata-rapid-rest-api-development-framework-for-delphi-developers/">TMS XData: Rapid REST API Development Framework for Delphi Developers</a> appeared first on <a href="https://www.scmgalaxy.com/tutorials">scmGalaxy</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1024" height="566" src="https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-10-1024x566.png" alt="" class="wp-image-12130" srcset="https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-10-1024x566.png 1024w, https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-10-300x166.png 300w, https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-10-768x425.png 768w, https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-10.png 1242w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<h2 class="wp-block-heading"><strong>#WhatIsTMSXData</strong></h2>



<h3 class="wp-block-heading"><strong>1. What is TMS XData?</strong></h3>



<p class="wp-block-paragraph"><strong>TMS XData</strong> is a high-level framework developed by <strong>TMS Software</strong> that allows Delphi (and Lazarus/FPC) developers to <strong>build powerful, scalable REST/JSON web services</strong> with minimal code. It is part of the <strong>TMS Business Tools</strong> ecosystem and supports <strong>automatic ORM integration</strong>, <strong>Swagger/OpenAPI documentation</strong>, and seamless <strong>client/server communication</strong>.</p>



<p class="wp-block-paragraph">XData significantly reduces the boilerplate needed for exposing REST APIs and provides out-of-the-box features like:</p>



<ul class="wp-block-list">
<li>Declarative service design with Delphi interfaces</li>



<li>Built-in JWT token authentication</li>



<li>Automatic database CRUD with Aurelius ORM</li>



<li>Support for service contracts and OpenAPI docs</li>



<li>Compatibility with RAD Web applications using TMS Web Core</li>
</ul>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h2 class="wp-block-heading"><strong>#TMSXDataUseCases</strong></h2>



<figure class="wp-block-image size-full"><img decoding="async" width="972" height="503" src="https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-11.png" alt="" class="wp-image-12131" srcset="https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-11.png 972w, https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-11-300x155.png 300w, https://www.scmgalaxy.com/tutorials/wp-content/uploads/2025/04/image-11-768x397.png 768w" sizes="(max-width: 972px) 100vw, 972px" /></figure>



<h3 class="wp-block-heading"><strong>2. Major Use Cases of TMS XData</strong></h3>



<p class="wp-block-paragraph">TMS XData is used in various domains requiring RESTful communication and data-driven logic. Its primary use cases include:</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">🔄 <strong>2.1. Backend for Web &amp; Mobile Apps</strong></h3>



<p class="wp-block-paragraph">XData provides the backend logic for single-page web applications (SPA) built with <strong>TMS Web Core</strong>, <strong>React</strong>, <strong>Angular</strong>, or <strong>Flutter</strong> frontends. It handles database CRUD, business logic, and user authentication.</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">🛠️ <strong>2.2. Microservices Development</strong></h3>



<p class="wp-block-paragraph">Build microservices with minimal overhead, using XData to expose individual APIs that are scalable, stateless, and easily deployable.</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">🧾 <strong>2.3. Internal Tools &amp; Admin Panels</strong></h3>



<p class="wp-block-paragraph">Quickly create REST APIs that power internal dashboards, reporting tools, or administrative backends that consume and manage enterprise data.</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">🗄️ <strong>2.4. Database-Driven Applications</strong></h3>



<p class="wp-block-paragraph">When combined with <strong>TMS Aurelius</strong>, XData can auto-generate REST endpoints for entity models, making database-to-REST service creation seamless.</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">🔐 <strong>2.5. Secure RESTful APIs with Authentication</strong></h3>



<p class="wp-block-paragraph">XData supports various authentication mechanisms including <strong>JWT (JSON Web Tokens)</strong>, making it suitable for applications with secure login and role-based access controls.</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h2 class="wp-block-heading"><strong>#TMSXDataArchitecture</strong></h2>



<h3 class="wp-block-heading"><strong>3. How TMS XData Works – Architecture Overview</strong></h3>



<p class="wp-block-paragraph">TMS XData is designed with <strong>modularity, extensibility, and simplicity</strong> in mind. It abstracts REST API creation into a component-based architecture tightly integrated with Delphi&#8217;s object-oriented paradigm.</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">📐 <strong>Core Architectural Layers</strong></h3>



<h4 class="wp-block-heading">✅ <strong>A. Server Application Layer</strong></h4>



<ul class="wp-block-list">
<li>Built using Delphi.</li>



<li>Uses <strong>TXDataServerModule</strong> and <strong>TXDataService</strong> components.</li>



<li>Defines endpoints using <strong>interfaces</strong> decorated with <code>[ServiceContract]</code> and <code>[HttpGet]</code>, <code>[HttpPost]</code>, etc.</li>
</ul>



<h4 class="wp-block-heading">✅ <strong>B. HTTP REST Engine</strong></h4>



<ul class="wp-block-list">
<li>Leverages <strong>Sparkle</strong>, the HTTP engine by TMS, to receive and process HTTP requests.</li>



<li>Can run as a standalone app, Windows service, or ISAPI DLL.</li>
</ul>



<h4 class="wp-block-heading">✅ <strong>C. Database Layer</strong></h4>



<ul class="wp-block-list">
<li>Uses <strong>TMS Aurelius ORM</strong> to connect with FireDAC, UniDAC, SQLite, PostgreSQL, MSSQL, and others.</li>



<li>Automatic conversion of entities to REST services.</li>
</ul>



<h4 class="wp-block-heading">✅ <strong>D. Middleware Layer</strong></h4>



<ul class="wp-block-list">
<li>Handles authentication, CORS, logging, compression, and custom middleware through Sparkle units.</li>



<li>JWT middleware can be enabled with just a few lines of code.</li>
</ul>



<h4 class="wp-block-heading">✅ <strong>E. Documentation Layer</strong></h4>



<ul class="wp-block-list">
<li>Automatically generates <strong>OpenAPI (Swagger)</strong> JSON specs.</li>



<li>Easily integrated with Swagger UI for live documentation and testing.</li>
</ul>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h2 class="wp-block-heading"><strong>#TMSXDataWorkflow</strong></h2>



<h3 class="wp-block-heading"><strong>4. Basic Workflow of TMS XData</strong></h3>



<p class="wp-block-paragraph">Here’s a typical flow from concept to production when working with TMS XData:</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<ol class="wp-block-list">
<li><strong>Design Entities</strong>: Use TMS Aurelius to define data models.</li>



<li><strong>Create Service Interfaces</strong>: Define REST operations using interface-based services.</li>



<li><strong>Implement Services</strong>: Write your logic inside class implementations registered with XData.</li>



<li><strong>Configure Server</strong>: Drop <code>TXDataServerModule</code> on a form, link it with Sparkle, and configure endpoints.</li>



<li><strong>Test APIs</strong>: Use Swagger UI or Postman to test your APIs locally or remotely.</li>



<li><strong>Secure &amp; Deploy</strong>: Add authentication (JWT), configure deployment (e.g., Apache, IIS), and go live.</li>
</ol>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h2 class="wp-block-heading"><strong>#GettingStartedWithTMSXData</strong></h2>



<h3 class="wp-block-heading"><strong>5. Step-by-Step Getting Started Guide</strong></h3>



<p class="wp-block-paragraph">Here’s how to build your first REST API with XData in Delphi:</p>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">✅ <strong>Step 1: Install TMS XData</strong></h3>



<ol class="wp-block-list">
<li>Purchase or download from <a href="https://www.tmssoftware.com/site/xdata.asp">tmssoftware.com</a>.</li>



<li>Install <strong>TMS Business Tools Bundle</strong> (includes Aurelius, Sparkle, and XData).</li>
</ol>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">✅ <strong>Step 2: Create a New XData Server Project</strong></h3>



<ol class="wp-block-list">
<li>In Delphi, go to <strong>File &gt; New &gt; Other &gt; TMS XData Server Project</strong>.</li>



<li>Choose <strong>Sparkle Standalone Server</strong> or <strong>ISAPI DLL</strong>.</li>



<li>Delphi creates a form with <code>TXDataServerModule</code>, <code>THttpSysDispatcher</code>, and default Sparkle configuration.</li>
</ol>



<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">✅ <strong>Step 3: Define a Service Interface</strong></h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
type
  &#x5B;ServiceContract]
  IHelloService = interface(IInvokable)
    &#x5B;&#039;{12345678-ABCD-4321-DCBA-87654321ABCD}&#039;]

    &#x5B;HttpGet] function SayHello(Name: string): string;
  end;

</pre></div>


<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">✅ <strong>Step 4: Implement the Interface</strong></h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
type
  &#x5B;ServiceImplementation]
  THelloService = class(TInterfacedObject, IHelloService)
  public
    function SayHello(Name: string): string;
  end;

function THelloService.SayHello(Name: string): string;
begin
  Result := &#039;Hello, &#039; + Name + &#039;!&#039;;
end;

</pre></div>


<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">✅ <strong>Step 5: Register and Run the Server</strong></h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
initialization
  RegisterServiceType(THelloService);

</pre></div>


<p class="wp-block-paragraph">Run the server. Your API is now accessible at:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
GET http://localhost:2001/tms/xdata/IHelloService/SayHello?Name=John

</pre></div>


<hr class="wp-block-separator has-alpha-channel-opacity">



<h3 class="wp-block-heading">✅ <strong>Step 6: Enable Swagger Documentation</strong></h3>



<ol class="wp-block-list">
<li>Drop <code>TXDataSwaggerModule</code> on the form.</li>



<li>Point your browser to:</li>
</ol>



<p class="wp-block-paragraph"></p>
<p>The post <a href="https://www.scmgalaxy.com/tutorials/tms-xdata-rapid-rest-api-development-framework-for-delphi-developers/">TMS XData: Rapid REST API Development Framework for Delphi Developers</a> appeared first on <a href="https://www.scmgalaxy.com/tutorials">scmGalaxy</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.scmgalaxy.com/tutorials/tms-xdata-rapid-rest-api-development-framework-for-delphi-developers/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
