<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Hapugala Arachchige Chaheth Janidu Senevirathne</title>
    <description>The latest articles on DEV Community by Hapugala Arachchige Chaheth Janidu Senevirathne (@chahethsen12).</description>
    <link>https://dev.to/chahethsen12</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3824745%2Ff59e654e-c21d-41bf-ba97-89ec4994199b.jpeg</url>
      <title>DEV Community: Hapugala Arachchige Chaheth Janidu Senevirathne</title>
      <link>https://dev.to/chahethsen12</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/chahethsen12"/>
    <language>en</language>
    <item>
      <title>I Built and Deployed a REST API on WSO2 Choreo. Here's What Actually Happened.</title>
      <dc:creator>Hapugala Arachchige Chaheth Janidu Senevirathne</dc:creator>
      <pubDate>Sun, 15 Mar 2026 08:08:52 +0000</pubDate>
      <link>https://dev.to/chahethsen12/i-built-and-deployed-a-rest-api-on-wso2-choreo-heres-what-actually-happened-22l7</link>
      <guid>https://dev.to/chahethsen12/i-built-and-deployed-a-rest-api-on-wso2-choreo-heres-what-actually-happened-22l7</guid>
      <description>&lt;p&gt;I'd been hearing about WSO2 Choreo for a while but never actually tried it. Since I'm applying for the WSO2 Engineering internship, I figured the best way to understand what they build is to just use it. So I spent an afternoon building a URL shortener API with Ballerina and deploying it on Choreo. Not a tutorial. Just an honest first look.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Choreo?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Choreo is WSO2's cloud-native internal developer platform. You connect your GitHub repo, pick your language, and Choreo handles the build pipeline, deployment, and API gateway without you touching any of that manually. At least that's the pitch. I wanted to see if it actually worked that way.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What I Built&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A simple URL shortener API with two endpoints:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;POST /shorten&lt;/code&gt; takes a long URL and returns a short key&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;GET /resolve/{key}&lt;/code&gt; takes the key and returns the original URL&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I wrote it in Ballerina, which is WSO2's own programming language built for network-aware applications. I had zero experience with it going in.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Ballerina Part&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Coming from Python and Java, Ballerina felt familiar but a bit different. The service syntax is clean and readable:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;service / on new http:Listener(8080) {
    resource function post shorten(@http:Payload json body) returns json|error {
        string longUrl = check body.url;
        string key = uuid:createType1AsString().substring(0, 6);
        urlStore[key] = longUrl;
        return { "key": key, "short_url": "/resolve/" + key };
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;check&lt;/code&gt; keyword handles error propagation automatically. No try/catch everywhere. It took me a few minutes to get my head around it but once it clicked, I actually liked it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Deploying on Choreo&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This is where I was expecting things to break. They didn't. After pushing to GitHub, I connected the repo in Choreo, selected Ballerina as the build preset, and hit deploy. Choreo detected the project structure, built it, and gave me a live public endpoint in a few minutes. No Dockerfile. No Kubernetes config. It also generated an API test console automatically so I could hit the endpoints right in the browser.&lt;/p&gt;

&lt;p&gt;Both endpoints worked on the first try, which honestly surprised me.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does it actually work?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Yes. POST returns a key, GET resolves it back. Live and working.&lt;/p&gt;

&lt;p&gt;GitHub : &lt;a href="https://github.com/Chahethsen12/choreo-url-shortener" rel="noopener noreferrer"&gt;Click Here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What I took away&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Choreo removes a lot of deployment friction. Coming from manually wiring up Railway and Docker for my own projects, having the platform just figure it out was a different experience. I'm not sure I'd use it for everything, but for spinning up services quickly inside an organisation, it makes sense. I get the appeal now.&lt;/p&gt;

</description>
      <category>wso2</category>
      <category>ballerina</category>
      <category>choreo</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
