<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Pankaj Badi on Medium]]></title>
        <description><![CDATA[Stories by Pankaj Badi on Medium]]></description>
        <link>https://medium.com/@itspankaj?source=rss-363c3a1e3c73------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*oiDf_G8sXeXv80QS</url>
            <title>Stories by Pankaj Badi on Medium</title>
            <link>https://medium.com/@itspankaj?source=rss-363c3a1e3c73------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 28 Nov 2026 17:15:42 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@itspankaj/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Connect Backend(MuleSoft) with Frontend(HTML /CSS)]]></title>
            <link>https://itspankaj.medium.com/connect-backend-mulesoft-with-frontend-html-css-7c423ee60ed5?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/7c423ee60ed5</guid>
            <category><![CDATA[mule4]]></category>
            <category><![CDATA[css]]></category>
            <category><![CDATA[html]]></category>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[male-community]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Thu, 07 Aug 2025 17:48:36 GMT</pubDate>
            <atom:updated>2025-09-21T13:31:45.204Z</atom:updated>
            <content:encoded><![CDATA[<p>To build a full-stack web application, you often need to connect a <strong>frontend UI (built with HTML/CSS)</strong> to a <strong>backend API (developed in MuleSoft)</strong>. This connection allows your frontend to send or retrieve data from the backend system.</p><ol><li>Create a simple <strong>HTTP Listener flow</strong> in Anypoint Studio.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*20Hqh2czHyccg81aBu4jGQ.png" /></figure><p>2. I have taken Transform message and just sending the payload in JSON format.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PwayGvUfQ1uRjUQ_NhnHbg.png" /></figure><p>3. When I run the application locally , I receive a <strong>200 OK response.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VMWnfRjdr6hbpQVzZHIMZQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*G9qSIWbtyYK39tzcuT6j1g.png" /></figure><p>4. Now, I deployed my application in runtime manager.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XbvdbSV9osohnfrbJ55bmg.png" /></figure><p>5. I am using HTML/CSS as a front end technology.</p><p>6. Now copy our backend api url of mulesoft from runtime manager and paste in the front end code.</p><p>(<a href="https://frontendapi-h1mzh2.5sc6y6-3.usa-e2.cloudhub.io/response"><strong>https://frontendapi-h1mzh2.5sc6y6-3.usa-e2.cloudhub.io/response</strong></a>)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3cE2ga1KW1OYRaHoJjn_NQ.png" /></figure><p>7. HTML/CSS code.</p><p><strong>&lt;!DOCTYPE html&gt;<br>&lt;html lang=”en”&gt;<br>&lt;head&gt;<br> &lt;meta charset=”UTF-8&quot; /&gt;<br> &lt;title&gt;Employee Submission&lt;/title&gt;<br> &lt;style&gt;<br> body {<br> font-family: Arial, sans-serif;<br> background-color: #f0f2f5;<br> padding: 30px;<br> }<br> form {<br> background: #fff;<br> padding: 20px;<br> border-radius: 8px;<br> width: 320px;<br> box-shadow: 0 4px 10px rgba(0,0,0,0.1);<br> margin: auto;<br> }<br> h2 {<br> text-align: center;<br> color: #333;<br> }<br> label {<br> display: block;<br> margin-top: 10px;<br> font-weight: bold;<br> }<br> input {<br> width: 100%;<br> padding: 8px;<br> margin-top: 4px;<br> box-sizing: border-box;<br> }<br> button {<br> margin-top: 15px;<br> width: 100%;<br> padding: 10px;<br> background: #007bff;<br> color: #fff;<br> border: none;<br> border-radius: 4px;<br> cursor: pointer;<br> }<br> #response {<br> margin-top: 20px;<br> text-align: center;<br> color: green;<br> font-weight: bold;<br> }<br> &lt;/style&gt;<br>&lt;/head&gt;<br>&lt;body&gt;</strong></p><p><strong>&lt;form id=”dataForm”&gt;<br> &lt;h2&gt;Submit Project Info&lt;/h2&gt;</strong></p><p><strong>&lt;label for=”name”&gt;Name&lt;/label&gt;<br> &lt;input type=”text” id=”name” required&gt;</strong></p><p><strong>&lt;label for=”billing”&gt;Billing&lt;/label&gt;<br> &lt;input type=”text” id=”billing” required&gt;</strong></p><p><strong>&lt;label for=”hours”&gt;Hours&lt;/label&gt;<br> &lt;input type=”text” id=”hours” required&gt;<br> <br> &lt;label for=”project”&gt;Project&lt;/label&gt;<br> &lt;input type=”text” id=”project” required&gt;</strong></p><p><strong>&lt;button type=”submit”&gt;Submit&lt;/button&gt;<br> &lt;div id=”response”&gt;&lt;/div&gt;<br> &lt;/form&gt;</strong></p><p><strong>&lt;script&gt;<br> document.getElementById(‘dataForm’).addEventListener(‘submit’, function(e) {<br> e.preventDefault();</strong></p><p><strong>const payload = {<br> name: document.getElementById(‘name’).value,<br> billing: document.getElementById(‘billing’).value,<br> hours: document.getElementById(‘hours’).value,<br> project: document.getElementById(‘project’).value<br> };</strong></p><p><strong>fetch(‘</strong><a href="https://frontendapi-h1mzh2.5sc6y6-3.usa-e2.cloudhub.io/response&#39;"><strong>https://frontendapi-h1mzh2.5sc6y6-3.usa-e2.cloudhub.io/response&#39;</strong></a><strong>, {<br> method: ‘POST’,<br> headers: { ‘Content-Type’: ‘application/json’ },<br> body: JSON.stringify(payload)<br> })<br> .then(response =&gt; response.text())<br> .then(data =&gt; {<br> document.getElementById(‘response’).innerText = data;<br> })<br> .catch(error =&gt; {<br> document.getElementById(‘response’).innerText = “Error: “ + error;<br> });<br> });<br> &lt;/script&gt;</strong></p><p><strong>&lt;/body&gt;<br>&lt;/html&gt;</strong></p><p>8. lets open html code in the web browser, The UI will look like below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jSkUtVNRyu11ocHrWzunhQ.png" /></figure><p>When I submit the form , I am getting error “<strong>Error: TypeError: NetworkError when attempting to fetch resource</strong>”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZHT97ksstCTrksjUNjnEGQ.png" /></figure><p>9. Now let focus on this error why we are getting this type of error fom point no 8, As we are connecting backend api in front end technology and browser is restrict.</p><p>10. Let see what is CROS (Cross-Origin Resource Sharing).</p><p>CROS is a <strong>browser security feature</strong> that <strong>prevents</strong> a web page from making <strong>requests to a different domain (origin)</strong> than the one that served the web page, <strong>unless the server explicitly allows it</strong>.</p><p>These are <strong>different ports</strong>, so the browser sees them as <strong>different origins</strong>. This is a <strong>cross-origin request</strong>, and it will be <strong>blocked by default</strong> unless the backend (MuleSoft) includes proper <strong>CROS headers</strong>.</p><p>11. We have two options</p><p><strong>Option 1:</strong></p><p>Pass the below headers in mulesoft.</p><p><strong>“Access-Control-Allow-Origin” : “*”,<br> “Access-Control-Allow-Methods” : “GET, POST, PUT, DELETE, OPTIONS’,<br> “Access-Control-Allow-Headers” : “Content-Type, Authorization”</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OwDvFuLR2fGbznfL76Y_yA.png" /></figure><p>Now, when you pass this header and deploy your application in cloud hub and follow the above step 7 then you will get response as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-joTOGFqe69cqzpa6hLQ7A.png" /></figure><p><strong>Option 2:</strong></p><p>In the listner connector make Listener interceptors as Edit inline and cros interceptors as Edit inline and add plus symbol and make Add public resources as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/882/1*OqOh3tGqDpCaY4uBKwJW3Q.png" /></figure><p>Now, when you pass this header and deploy your application in cloud hub and follow the above step 7 then you will get response as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ogTr2wrHUDSspwdjWRYFxQ.png" /></figure><p><strong>Conclusion:</strong></p><p>By following above steps you can connect your Backend(MuleSoft) api with any Front end technology.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7c423ee60ed5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[EDI (X12) in Mule 4]]></title>
            <link>https://itspankaj.medium.com/edi-x12-in-mule-4-eecbbd442584?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/eecbbd442584</guid>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[connector]]></category>
            <category><![CDATA[mule4]]></category>
            <category><![CDATA[postman]]></category>
            <category><![CDATA[x12]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Wed, 18 Oct 2023 14:23:31 GMT</pubDate>
            <atom:updated>2023-11-06T15:19:53.239Z</atom:updated>
            <content:encoded><![CDATA[<p>How we can write EDI message using “<strong>X12 Write</strong>” connector in mule 4.</p><ol><li><strong>EDI</strong>: EDI (Electronic Data Interchange) segments are the individual units of data in an EDI message. They are used to represent specific pieces of information within an electronic document. EDI messages are composed of segments, and each segment has a unique identifier called a segment tag or code. Segments are further divided into elements, which contain the actual data values.</li><li>Here is the basic structure of an EDI segment:</li></ol><p><strong>SegmentTag&lt;Element1&gt;Data1&lt;Element2&gt;Data2&lt;…&gt;&lt;ElementN&gt;DataN</strong></p><p>3.<strong> Segment Tag</strong>: It identifies the type of information the segment contains. For example, “N1” is often used for the name and address information of a party involved in the transaction.</p><p>4. <strong>Element</strong>: Each segment is divided into elements. Elements are the individual pieces of data within a segment. For example, within an “N1” segment, the first element might represent the party’s name, and the second element might represent the party’s identification number.</p><p>5. <strong>Data</strong>: This is the actual value of the element.</p><p>6. Segments are delimited by specific characters, such as the asterisk (*) or the tilde (~) depending on the EDI standard being used (like ANSI X12, EDIFACT, etc.). The structure of segments and the specific segment codes used can vary based on the industry and the type of transaction being conducted.</p><p>7. <strong>X12 EDI Connector in MuleSoft</strong></p><p>The Connector is utilized to change over X12 messages to and from Data Weave-perfect portrayals utilizing records and maps. These are the accessible X12 variants 003010, 003020, 003030, 003040, 003050, 003060, 003070, 004010, 004020, 004030, 004040, 004050, 004060, 005010, 005020, 005030, 005040, 005050, and 006020 are bolstered with provided pattern definitions for all standard exchange sets.</p><p>8. <strong>Parts of an X12 :</strong></p><p><strong>ISA (Interchange Control Header)</strong>: The ISA segment marks the beginning of the interchange of EDI data between parties. It contains information about the sender and receiver of the EDI data, as well as date, time, and control information.</p><p><strong>GS (Functional Group Header)</strong>: The GS segment is used to indicate the start of a functional group of related transactions. A functional group typically contains a collection of individual transactions that are related, such as a group of purchase orders or invoices.</p><p><strong>ST (Transaction Set Header):</strong> The ST segment marks the beginning of a specific transaction set within a functional group. It identifies the type of document being transmitted, such as a purchase order or an invoice.</p><p><strong>SE (Transaction Set Trailer):</strong> The SE segment marks the end of a specific transaction set. It contains a control number that indicates the number of segments in the transaction set.</p><p><strong>GE (Functional Group Trailer):</strong> The GE segment marks the end of a functional group. It contains a control number indicating the number of transaction sets in the functional group.</p><p><strong>IEA (Interchange Control Trailer):</strong> The IEA segment marks the end of the interchange of EDI data. It contains a control number indicating the number of functional groups in the interchange.</p><p>9. Transaction sets that are defined by the ANSI X12 EDI standard. Each transaction set has a unique purpose and format, allowing for the electronic exchange of specific types of business documents between trading partners. Here’s what each of these transaction sets represents:</p><p><strong><em>835 </em></strong><em>Health Care Claim payment or advice.</em></p><p><strong><em>837 </em></strong><em>: Health Care Claim.</em></p><p><strong><em>834 </em></strong><em>: Benefits Enrollment and Maintenance.</em></p><p><strong><em>820</em></strong><em>: Payroll Deducted Premium Payment for Insurances.</em></p><p><strong><em>270</em></strong><em>: Health Care or Benefits Inquiry.</em></p><p><strong><em>271</em></strong><em>: Health Care Eligibility or Benefits Response.</em></p><p><strong><em>276</em></strong><em>: Health Care Claim Status Inquiry</em></p><p><strong><em>277</em></strong><em>: Health Care Claim Status Response.</em></p><p><strong><em>278</em></strong><em>: Health Care Service Review Information.</em></p><p><strong><em>Use Case:</em></strong></p><p><strong>To implement EDI-<em>834 : Benefits Enrollment and Maintenance using EDI(X12) Write Connector.</em></strong></p><p><strong><em>Solution:</em></strong></p><p>10. How <strong>EDI(X12) Connectors </strong>works in <strong>MuleSof</strong>t: Let’s verify step by step.</p><p><strong>a.</strong> <em>Create new project in Anypoint Studio in Mule 4.</em></p><p><strong>b.</strong> <em>Configure the listener and set the path for your project as show in screenshot.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_TveTkJGFezaIcOghsENCA.png" /></figure><p><strong><em>c.</em></strong> <em>In the palette and search X12 EDI, Try looking for it in Exchange in the studio (give the </em><strong><em>Anypoint Platform</em></strong><em> credentials for login) and type X12 and search it.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/823/1*EPM67IiWX7QJweY9QkNa9g.png" /></figure><p><strong>d.</strong> <em>In Package Explorer, All the dependencies and jars of X12 are added. I am using version “</em><strong><em>004050</em></strong><em>” and “</em><strong><em>834.esl</em></strong><em>” as per the use case.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/233/1*EXUBKu0RETRHBJMWK5eqQw.png" /></figure><p><strong>e.</strong> <em>In this we have two files one is </em><strong><em>basedefs.esl</em></strong><em> file and other is </em><strong><em>834.esl</em></strong><em> file.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Mvjm_YUKU3QqZ4sFqEL3sg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mXIYJB3gmhqVy3FsgUMzdQ.png" /></figure><p><strong>f.</strong> <em>In the </em><strong><em>834.esl file</em></strong><em>: We have </em><strong><em>heading, details </em></strong><em>and in some files we have </em><strong><em>summary</em></strong><em> also which is in “</em><strong><em>849.esl</em></strong><em>”. If not just ignore it I just has given this point to understand. In this Usage are “</em><strong><em>M</em></strong><em>” is M</em><strong><em>andatory, “O” is Optional and count “&gt;1” then take array </em></strong><em>and if</em><strong><em> count:2 then also take array. C</em></strong><em>heck the position of that segment that is very important for example.</em></p><p><strong>heading:</strong></p><ul><li><em>{ idRef: ‘</em><strong><em>BGN</em></strong><em>’, position: ‘</em><strong><em>0200</em></strong><em>’, usage: M }, In the Transform Message we have to create like this </em><strong><em>“0200_BGN”</em></strong><em>.</em></li></ul><p><strong>g.</strong> In the <strong>basedefs </strong>file check the ‘BGN’ as we are refers to “<strong>834.esl</strong>” file.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*l_YoxVXQwHxtOukgBmaLRw.png" /></figure><p>In the above screenshot or basedefs.esl file.</p><p><strong><em>{ idRef: ‘353’, usage: M }, { idRef: ‘127’, usage: M }, { idRef: ‘373’, usage: M }.</em></strong></p><p>In this all three segments are Mandatory. Create the the structure in Transform Message as below.</p><p><strong><em>“0200_BGN”: {</em></strong></p><p><strong><em>BGN01: “00” ,</em></strong></p><p><strong><em>BGN02: “9”,</em></strong></p><p><strong><em>BGN03: payload.Reciever_date as Date</em></strong></p><p><strong><em>},</em></strong></p><p><strong>h. </strong><em>In this Transform Message, Either you can used </em><strong><em>Delimiters: “*&gt;U~” </em></strong><em>or in Write configuration we have following things.</em></p><p><em>In write connectors in that </em><strong><em>Batch</em></strong><em> tab by default it have.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*rWfO3HUpwOmG9vPeqZZPNA.png" /></figure><p><em>In write connector, There is </em><strong><em>Identify</em></strong><em> tab.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/622/1*whs3X0nQTDRs3I6D5L5WUA.png" /></figure><p><strong>i. </strong><em>Run your project.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TUTvR_QqjZLPYRbCBbentg.png" /></figure><p><strong>j.</strong> P<em>ass the body in the postman and hit the request.</em></p><p><em>{</em></p><p><em>“Billing_Country”: “USA”,</em></p><p><em>“Billing_Ci”: “TX”,</em></p><p><em>“Billing_State”: “UM”,</em></p><p><em>“AccountNumber”: “4”,</em></p><p><em>“Reciever_date”: “2023–10–18T18:25:43–05:00”,</em></p><p><em>“Billing_Count”: “fg”,</em></p><p><em>“Billing_City”: “ug”,</em></p><p><em>“Billing_Sta”: “mau”,</em></p><p><em>“Account_Number”: “21”,</em></p><p><em>“Name_person”: “sd”</em></p><p><em>}</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AD88EiCTEFNtBzzdZw69ag.png" /></figure><p><strong>k.</strong> Please find the code in the <a href="https://github.com/pankajbadi-07/EDI/tree/dev">Git Repo</a>.</p><p><strong>l.</strong> <em>EDI Errors and Solution</em><strong><em>: I have face below types of error and find the solution for it.</em></strong><br><br><strong>1.</strong> <em>”Errors in write operation: missing required value ‘1000_Loop’ at index 4&quot;</em></p><p><strong><em>Solution:</em></strong><em> The tag was under heading in the “834.esl” file. So, I have change it.</em></p><p><strong>2.</strong> <em>”Errors in write operation: effective length 7 is greater than 3 for value N101 for segment N1 at segment position 4&quot;</em></p><p><strong><em>Solution:</em></strong><em> I have to change the length of the payload as its saying the size 3. Initially.<br>I taken value of Billing_Country is 7. After that payload.Billing_Country I have change to value which I have to set 3</em>.</p><p>3. “Errors in write operation: missing required value ‘0700_N1’ at index 4”</p><p>take the position of “834.esl” file.</p><p><strong>Solution:</strong> Always check the position in “.esl” file it is very important.</p><p><strong>Conclusion:</strong></p><p>By following above steps you can create messages in EDI.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eecbbd442584" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to add special character ($) in RAML in Mule 4]]></title>
            <link>https://itspankaj.medium.com/how-to-add-special-character-in-raml-in-mule-4-9b2b5daeccbc?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/9b2b5daeccbc</guid>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[raml]]></category>
            <category><![CDATA[mule]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Wed, 22 Mar 2023 09:03:14 GMT</pubDate>
            <atom:updated>2023-03-22T09:08:39.258Z</atom:updated>
            <content:encoded><![CDATA[<p>How to add special character in RAML in mule 4 using Any-point platform and studio</p><ol><li>This article helps you how to add special character ($) in RAML by below step by step.</li><li>Login to Any point platform (<a href="https://anypoint.mulesoft.com/">https://anypoint.mulesoft.com/</a>)</li><li>Go to Design Center and you can be able to see create button as below.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/285/1*nCG-7hucaLhlOhSu5rnXag.png" /></figure><p>4. In this RAML we are writing as per standard. In this we just taken 1 endpoint and uri-parameter and write the example in the Example folder.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/459/1*aCdORDs3gF2gqt8sgpqiyw.png" /></figure><p>5. RAML example as below mentioned.</p><p><strong><em>/pankaj/{pankajid}/$metadata:</em></strong></p><p><strong><em>get:</em></strong></p><p><strong><em>description: the employee data</em></strong></p><p><strong><em>responses:</em></strong></p><p><strong><em>200:</em></strong></p><p><strong><em>body:</em></strong></p><p><strong><em>application/xml:</em></strong></p><p><strong><em>example: !include /Example/file.xml</em></strong></p><p>6. In the RAML I am able to get endpoint as /pankaj and in this we have uri-parameter and special character $.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/383/1*0skocCbFC1EjkgPDP1h3uw.png" /></figure><p>7. When we hit this endpoint in the any point platform we get below error</p><p><strong><em>&quot;message”: “Error validating the base uri for the path: /pankaj/1/$metadata. Resource path contains invalid characters. [$]”</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/345/1*8MMdmxJL0NKx7QYYOf5-Zw.png" /></figure><p>error stating that we can&#39;t add any character as its showing invalid character error.</p><p>8. Now, just published the API in Any-point Exchange which will be like this in below screenshot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/881/1*7iHa542yh55i6o-sHrO1ag.png" /></figure><p>9. Now just go to studio and create new project and import your api which is published in design center of platform.</p><p>10. In step 7, we see that whenever we hit our endpoint, we get an error stating that invalid character ($) is not allowed.</p><p>11. Now go to studio and right click on your project and deploy to cloud hub.</p><p>12. We can be able to see our Mule application in Runtime Manager in any point platform.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3pEldOjmcWg7_ogxFgzmqg.png" /></figure><p>13. Now hit the url in the cloud hub for the below link.</p><p><a href="http://testdemoproject.us-e2.cloudhub.io/api/pankaj/1/$metadata"><strong>http://testdemoproject.us-e2.cloudhub.io/api/pankaj/1/$metadata</strong></a></p><p>14. Please find the response from the above url and below screenshot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/957/1*QKydJQztXpnbkP050a8WRg.png" /></figure><p><strong>Conclusion</strong>:</p><p>Using above steps, you can be able to write the special character in the RAML in MuleSoft.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9b2b5daeccbc" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Custom Message in HL7 in MuleSoft]]></title>
            <link>https://itspankaj.medium.com/custom-message-in-hl7-in-mulesoft-7e6f9cbb788b?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/7e6f9cbb788b</guid>
            <category><![CDATA[mule]]></category>
            <category><![CDATA[mulesoft-professional]]></category>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[hl7-integration]]></category>
            <category><![CDATA[hl7-messaging]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Mon, 02 Jan 2023 16:56:45 GMT</pubDate>
            <atom:updated>2023-02-07T13:29:05.089Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>How we can create the custom message in HL7 with “Write Operation” in MuleSoft</strong></p><p><strong>Introduction:</strong></p><ol><li>The main HL7 standards are: HL7 , the most widely used messaging standard for exchange of patient care and clinical information. It is a database query language that enables healthcare providers to send messages requesting and containing health data.</li><li>Health Level Seven (HL7) is a standard for exchanging information between medical information systems. It is widely deployed and covers the exchange of information in several functional domains. It is very important and crucial to achieve interoperability in healthcare.</li></ol><p><strong>Use Case:</strong></p><p>To implement custom message in MuleSoft using HL7 connector. So, this article help you create custom message.</p><p><strong>Solution:</strong></p><ol><li>How we can create the below message in HL7</li></ol><p>MSH|^~\&amp;|OPTIFLEX|||MGH|20230102|||0|P</p><p>EVN|EVN|Pankaj</p><p>PID|1||12||Pankaj Badi</p><p>now, you can able to see the segments like “MSH, EVN and PID”.</p><p>2. lets go step by step.</p><p>3. In mule application you can able to see 2 files are created that is<strong> basedef.esl</strong> and <strong>esl</strong> file in the path in <strong>src/main/resources</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*e2fU6SYV9A02btfR3H6h7g.png" /></figure><p>4. let see how we can create the 2 files as below.</p><p>5. In the above message, the segments are <strong>MSH,EVN,PID</strong>. So, create <strong>DFT_P03.esl</strong> with segments with the position as below in the screenshot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/779/1*pDMVSChsElntw5_q-Z2yIg.png" /></figure><p>6. you can able to see color part is the segment with the position. In this we have usage is either “<strong>M</strong>” or “<strong>O</strong>” that mean it is “<strong>Mandatory</strong>” or “<strong>Optional</strong>”.</p><p>7. In the <strong>basedef_hpg_DFT_PO3.esl</strong> the segments are</p><p><strong>id: MSH , id: EVN, id: PID</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/780/1*I4mR8XhYmU4zmPNem2qVfg.png" /></figure><p>8. This below segments state that</p><ul><li>{ idRef: ‘ID’, name: ‘Character Set’, usage: O, count: ‘&gt;1’ } , usage is O that is Optional and count &gt;1 so that is array.</li><li>- { idRef: ‘ID’, name: ‘Character Set’, usage: M, count: ‘&gt;1’ } , usage is M that is Mandatory and count &gt;1 so that is array.</li><li>Few things help out you while creating the custom message in HL7.</li><li><strong>1 and unbounded</strong> means → <strong>mandatory but array</strong>.</li><li><strong>0 and unbounded</strong> means → <strong>Optional but array</strong>.</li></ul><p>9. you able to find HL7 connector in the search in exchange.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*ScGeybXooJ2VwueoxyCvxw.png" /></figure><p>ones you add the HL7 jar you can able to see the HL7 schemas-jar.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/285/1*9Y-OJYfD_ZY5eMieYpwY3A.png" /></figure><p>10. The mule have the basedef.esl by default. Now , we can create the custom message according to our use case . I am writing <strong>basedef.esl</strong> and <strong>esl</strong> file. The structure you can create accordingly to use case.</p><p>11. The input structure message we write in json structure we need for HL7 <strong>write operation</strong> to convert the message in <strong>HL7 format</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/834/1*WnXpGb8kFC9gZcwUDq_bkw.png" /></figure><p>12. HL7 configuration is as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/605/1*xyHcuDrJz-jLMhzTOqy6kQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/612/1*rs26ZwtZg_6_fL2ZYPRm9Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rIVkKV-tLKd9wIppOgveDQ.png" /></figure><p>13. Find the below screenshot of the postman.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/850/1*vtqEOIJmzlvAtxUyECo_zA.png" /></figure><p><strong>14. </strong>Please find the code in the <a href="https://github.com/pankajbadi-07/HL7/tree/master">GIT </a>repo.</p><p><strong>Conclusion:</strong></p><p>By following above steps you can create <strong>custom message in HL7</strong>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7e6f9cbb788b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CRLF and LF in MuleSoft]]></title>
            <link>https://itspankaj.medium.com/crlf-and-lf-in-mulesoft-4c953f697b44?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/4c953f697b44</guid>
            <category><![CDATA[notepad-plus-plus]]></category>
            <category><![CDATA[mule]]></category>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[mule4]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Sat, 13 Aug 2022 14:14:40 GMT</pubDate>
            <atom:updated>2022-08-13T14:19:16.445Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>How we can acheive CRLF and LF using MuleSoft in Notepad ++</strong></p><p><strong>CRLF:</strong> The term CRLF refers to <strong>Carriage Return (ASCII 13, \r ) Line Feed (ASCII 10, \n )</strong>. They’re used to note the termination of a line, however, dealt with differently in today’s popular Operating Systems.</p><p><strong>LF:</strong> Line Feed (\n, 0x0A in hexadecimal, 10 in decimal) — moves the cursor down to the next line without returning to the beginning of the line.</p><p><strong>Use-Case:</strong></p><ol><li>When we write a particular file in any location in our local system using <strong>MuleSoft</strong> and open in notepad ++.</li><li>So, when we open a file in notepadd ++. There is show all character in Notepadd ++ where you can see either <strong>CRLF </strong>or<strong> LF</strong>.</li><li><strong>Example</strong>: Suppose in file There are <strong>100</strong> records first <strong>99</strong> records should come as <strong>CRLF</strong> and last record as <strong>LF</strong>.</li><li>In mule pallete take<strong> Write</strong> Connector and give the<strong> </strong>configuration <strong>path</strong> and in <strong>write mode</strong> should be<strong> APPEND</strong> according to use case.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/601/1*oIQeb6cGLOBfES2PcvGWmQ.png" /></figure><p>5. How we can acheive <strong>CRLF and LF in MuleSoft</strong>. So take TM and write logic as below.</p><p><strong>output application/csv separator=”|” ,lineSeparator= “\r\n”</strong></p><p>6. Take <strong>Set Payload</strong> Connector and give<strong> MIME Type text/plain</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/724/1*6HwkBqdED_P9VMB7Enwj5Q.png" /></figure><p>7. Now, take TM and write the logic as below.</p><p><strong>((payload)[0 to -3] ) ++ “\n”</strong></p><p>8. In this logic [0 to -3] in this <strong>“\r\n”</strong> in initially I am deleting this in the TM and then, just doing appending the value<strong> “\n”</strong> in the next TM.</p><p>9. In <strong>Postman</strong>, Just sending the body in the <strong>JSON Format</strong> in <strong>POST</strong> Method done the configuration accordingly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*KqOLs4W54Dt81v657t6kUg.png" /></figure><p>10. Now, <strong>File</strong> is written to the <strong>particular location in the local system</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/966/1*GyGjtQCGXY5i-n_0I1rmfg.png" /></figure><p>11. Open the file with notepadd ++ and click on show all character. The highlight part is show as below in screenshot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yy4QT3Wwl3bVbq8LgKBSTw.png" /></figure><p>12. The Final Output or response using MuleSot in the notepadd ++ looks in the below screenshot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Yc7XbRQD4VrsVKl7sNmuKg.png" /></figure><p><strong>Conclusion:</strong></p><p><strong>By using above ssteps in MuleSoft we can achive CRLF and LF in MuleSoft.</strong></p><p><strong>References:</strong></p><ol><li><a href="https://docs.mulesoft.com/general/"><strong>https://docs.mulesoft.com/general/</strong></a></li><li><a href="https://developer.mozilla.org/en-US/docs/Glossary/CRLF"><strong>https://developer.mozilla.org/en-US/docs/Glossary/CRLF</strong></a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4c953f697b44" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Creation of an Object in Salesforces]]></title>
            <link>https://itspankaj.medium.com/creation-of-an-object-in-salesforces-33c4c6e7399c?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/33c4c6e7399c</guid>
            <category><![CDATA[mule]]></category>
            <category><![CDATA[salesforce]]></category>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[salesforce-admin]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Sun, 17 Jul 2022 14:33:04 GMT</pubDate>
            <atom:updated>2022-07-17T15:13:06.082Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>create object in Salesforces</strong></p><p>Introduction: <strong>Salesforce is a leading CRM (Customer Relationship Management) software which is served form cloud</strong>. It has more than 800 applications to support various features like generating new leads, acquiring new leads, increasing sales and closing the deals.</p><ol><li>How we can create objects in Salesforces.</li><li>Login to your salesforces accouny.</li></ol><p>3. Once you are able to see the Salesforces dashboard.</p><p>4. Go to setup in that you can search <strong>Object</strong>.</p><p>5.While,Creating an object you are able to find <strong>Custom Object</strong> and we have <strong>Data Types</strong> where you can able to find <strong>Text</strong> and <strong>Auto Number</strong>.</p><p>6.In Custom Object you can find the New Custom Object in the below screenshot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1018/1*JsyBS21n4tkRX_cDlcjB_w.png" /></figure><p>7. In this below screenshot the explanation is step by step</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1y0j_RYWgRCAV1NmAmDKPA.png" /></figure><p>8. In the Label you can create which object you want and in the Plural Label you can give the same object name just end with ‘s’.In Object Name you can give object name which you want to create an in Description you can mention some details about the object. In my use case I am using Employee Details.</p><p>9.In Context-Sensitive Help Setting there are two choices for you either Open the Standard or using Visualforce page. I am using Standard.</p><p>10. In Optional Features you have some checkbox that is an option but you can checklist those boxes.</p><p>11. Allow Reports: In this the Report is able to generate for these objects.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7I_JCtvwMZiIb-AP9RdRjw.png" /></figure><p>12. In above screenshot you can able to see <strong>Save</strong> and<strong> Save &amp; New</strong>. In Save you can <strong>save</strong> the object and in <strong>new &amp; save </strong>you can save and can create new <strong>Objects</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*K173GgJp6t2tCuRuoQdYKQ.png" /></figure><p>13. In Add Profiles you can see the drop down list Default On.</p><p>14. Objects is created in Salesforces Dashboard. In this screenshot APIName dataSample__c</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IBuRoUpAiYXeR9vwdtksYQ.png" /></figure><p>15. In Salesforces, Relationships are created by creating custom relationship fields on an object<strong>.</strong></p><p>16. In Salesforces, we have Standard and Custom object.</p><p><strong>Standard</strong> Objects in Salesforce represent the Objects that the Salesforce Platform has already created for the customers.</p><p><strong>Custom</strong> Objects are the Objects in Salesforce that are created by the users according to their requirements.</p><p>17.How,we can integrate MuleSoft and Salesforces. In MuleSoft we have to take <strong>Create</strong> Connector from MuleSoft Pallete.</p><p>18. Create Configuration give username,password and security token to enter in the system. we get security token with our register email id which we define while login Salesforces Account.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/811/1*gYUsLOEJfcXATTiuJfUA3Q.png" /></figure><p>19. Highligh color part Test Connection is succesful and Security token I got from my mail id which is register with salesfoces account.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/944/1*vwELrJl3AD-SmrOUirLEKg.png" /></figure><p>20. In the below screenshot. In <strong>Create</strong> connector you able to find properties in that <strong>Type: dataSample(dataSample__c)</strong> which we create in the salesforces.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NFG9Ojdx5v9Lm6uyXHG5hg.png" /></figure><p><strong>Conclusion:</strong></p><p>In <strong>Salesforces,</strong> its offers. you Salesforce <strong>Objects</strong> and the steps required to create <strong>Custom Objects</strong> in Salesforce which help out you in MuleSoft Integration<strong>.</strong></p><p><strong>References:</strong></p><ul><li><a href="https://trailhead.salesforce.com/?&amp;sfdc_modal=trailhead-welcome&amp;gclid=CjwKCAjw5s6WBhA4EiwACGncZYvqHnOm8HJuUXA7LBK6r-G3Ic_P9P7RmI_qZQ8Xn7hpz4492rWaYRoC4UwQAvD_BwE&amp;gclsrc=aw.ds">Trailhead | The fun way to learn</a></li><li><a href="https://login.salesforce.com/?locale=in">Login | Salesforce</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=33c4c6e7399c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MuleSoft Overview]]></title>
            <link>https://itspankaj.medium.com/mulesoft-overview-4e6d04c63cbb?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e6d04c63cbb</guid>
            <category><![CDATA[mule]]></category>
            <category><![CDATA[mulesoft-esb]]></category>
            <category><![CDATA[mulesoft]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Wed, 20 Apr 2022 09:35:10 GMT</pubDate>
            <atom:updated>2022-04-20T09:35:10.651Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Basic of the MuleSoft and Tools needed on your local system while running any mule project.</strong></p><ol><li><strong>Meet Max from Mule.</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/957/0*4CQ6SnDs7zGy5PV_" /></figure><p><strong>2. Salesforce Completes Acquisition of MuleSoft.</strong></p><p><strong>3. With MuleSoft, Salesforce now provides one of the world’s leading platforms for building application networks that connect enterprise apps, data and devices across any cloud and on-premise — whether they connect with Salesforce or not.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/0*f-WOayCk4jRdRIwD" /></figure><p><strong>4. MuleSoft’s Anypoint Platform will also be part of Salesforce Integration Cloud, which will enable all enterprises to surface their data — regardless of where it resides — to deliver intelligent, connected customer experiences across all channels and touchpoints.</strong></p><p><strong><em>5. </em>Leading companies, including Coca-Cola, Barclays and Unilever, rely on MuleSoft to change and innovate faster, deliver differentiated customer experiences, and increase operational efficiency.</strong></p><p><strong>6. Need Account for MuleSoft Training , Any point Platform and Dataweave link.</strong></p><p><a href="https://anypoint.mulesoft.com/login/"><strong>https://anypoint.mulesoft.com/login/</strong></a></p><p><a href="https://training.mulesoft.com/"><strong>https://training.mulesoft.com/</strong></a></p><p><a href="https://developer.mulesoft.com/learn/dataweave/"><strong>https://developer.mulesoft.com/learn/dataweave/</strong></a></p><p><strong>— Here you can write the dataweave logic for any structure.</strong></p><p><strong>7. What is API Led Connectivity?</strong></p><p><strong>System API:</strong></p><p><strong>System APIs that can understand the modern system’s language, then they can communicate by exchanging data. All MuleSoft APIs are organized in the network and are assigned different roles</strong></p><p><strong>Process API:</strong></p><p><strong>Process APIs are responsible for processing the extracted data and performing some logic</strong></p><p><strong>Experiences API:</strong></p><p><strong>Experience APIs deal with formatting the data to be presented to different media devices like desktops, mobiles, apps etc.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/954/0*VmpJ3lvBSxEr0dh6" /></figure><p><strong>8. Tools needed on your Local System</strong></p><p><strong>Java 8 version or above: Download the java.</strong></p><p><strong>MuleSoft has Mule 3 and Mule 4 in the studio.</strong></p><p><strong>Anypoint Studio: Download the studio from the below link.</strong></p><p><a href="https://www.mulesoft.com/lp/dl/studio"><strong>https://www.mulesoft.com/lp/dl/studio</strong></a></p><p><strong>Postman : Download the postman to send the request and get the response while running the project on your local.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/956/0*QjizSRki2lo23zso" /></figure><p><strong>9. Anypoint Studio?</strong></p><p><strong>Any point Studio: To design your APIs on your local with the help of the studio.</strong></p><p><strong>It is open source so you can download that as well.</strong></p><p><strong>deploy your APIs to Any point Platform using the studio.</strong></p><p><strong>Lots of connectors are available from Mule Pallet.</strong></p><p><strong>if you want to add few more than you can take from the search exchange option in the studio.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/961/0*nInfffPTlnEXe6qw" /></figure><p><strong>10. Anypoint Platform?</strong></p><ul><li><strong>MuleSoft’s Anypoint Platform is a unified, single solution for iPaaS and a full life-cycle API management. The Anypoint Platform consists of the following major components:</strong></li></ul><p><strong>Anypoint Security,</strong></p><p><strong>Anypoint Design center,</strong></p><p><strong>Anypoint Management center,</strong></p><p><strong>Anypoint Exchange,</strong></p><p><strong>Runtime engine &amp; services</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/959/0*ETirYNUEmE55hz1A" /></figure><p><strong>11. Dataweave in MuleSoft?</strong></p><p><strong>We write the dataweave in MuleSoft for doing Transformation in Transform Message.</strong></p><p><strong>There are so many function we can use accordingly our use case and requirement.</strong></p><p><strong>By using dataweave we can write data in any format like JSON,XML,CSV and many more.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/0*NBXona5ompqxcpt6" /></figure><p><strong>12. On-premise and CloudHub deployment?</strong></p><p><strong>Anypoint Platform is the same product whether a customer uses Cloudhub or installs on their private Cloud. Note though that the Anypoint Platform Private Cloud Edition (PCE) set up is typically 6 months behind in terms of product releases.</strong></p><p><strong>The two key parts of the product, Control and Runtime Plane, are in different locations depending on the chose deployment option. The Control Plane can only be customer-managed when opting for a PCE deployment model.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/886/0*_GJqLN61WHwqKnW5" /></figure><p><strong>Conclusion:</strong></p><p><strong>Overview steps to setup the Anypoint Studio and Anypoint Platform in the MuleSoft.</strong></p><p><strong>References:</strong></p><ol><li><a href="https://anypoint.mulesoft.com/login/"><strong>https://anypoint.mulesoft.com/login/</strong></a></li><li><a href="https://www.mulesoft.com/lp/dl/studio"><strong>https://www.mulesoft.com/lp/dl/studio</strong></a><strong>.</strong></li><li><a href="https://training.mulesoft.com/"><strong>https://training.mulesoft.com/</strong></a></li><li><a href="https://developer.mulesoft.com/learn/dataweave/"><strong>https://developer.mulesoft.com/learn/dataweave/</strong></a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e6d04c63cbb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Publish JSON Logger on Exchange]]></title>
            <link>https://itspankaj.medium.com/publish-json-logger-on-exchange-715934a8374e?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/715934a8374e</guid>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[mulechain]]></category>
            <category><![CDATA[mule-esb]]></category>
            <category><![CDATA[mule]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Thu, 14 Apr 2022 14:07:40 GMT</pubDate>
            <atom:updated>2022-05-05T15:05:31.648Z</atom:updated>
            <content:encoded><![CDATA[<p>How to published JSON logger on Anypoint Exchange</p><p><strong>JSON Logger:</strong></p><p>As the name suggests, the JSON logger prints the JSON format logs, which can be helpful <strong>when logging into any external log analytics tool such as ELK or Splunk</strong>.</p><p><strong>JSON Logger connector</strong> looks like below in Anypoint Exchange.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VXdXiVHWOOwpAH1w69KvAg.png" /></figure><p><strong>Use Case:</strong></p><ol><li>For any project if we are using a JSON logger it will be helpful for logging purposes to see the logs for any API which we implement.</li><li>Make a clone of the JSON logger from the repository below mentioned in the reference.</li><li>From the json-logger open the<strong> pom </strong>with any editor from the below screenshot.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*s8O6FqX6JYRsioI-f2V9pA.png" /></figure><p>4. In the <strong>pom</strong> file you will get <strong>&lt;groupId&gt;organizationId&lt;/groupId&gt;</strong> tag.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iVhZqNrgpX5_dRsq7a8p2A.png" /></figure><p>5. If you see the color part is<strong> </strong>your<strong> organization-Id</strong>,which you will get in Anypoint platform as mentioned in the below step.</p><p><strong>Anypoint Platform -&gt; Management Center -&gt; Access Management -&gt; Organisation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cb0shzKebm8sVqv_UMKS6g.png" /></figure><p>6. The tags you have to use as mentioned below.</p><p>7.</p><p><strong>&lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;<br> &lt;groupId&gt;&lt;/groupId&gt;<br> &lt;artifactId&gt;json-logger&lt;/artifactId&gt;<br> &lt;version&gt;2.0.1&lt;/version&gt;<br> &lt;packaging&gt;mule-extension&lt;/packaging&gt;<br> &lt;name&gt;JSON Logger — Mule 4&lt;/name&gt;</strong></p><p>8.</p><p><strong>&lt;distributionManagement&gt;<br> &lt;! — Target Anypoint Organization Repository →<br> &lt;repository&gt;<br> &lt;id&gt;Exchange2&lt;/id&gt;<br> &lt;name&gt;Exchange2 Repository&lt;/name&gt;<br> &lt;url&gt;</strong><a href="https://maven.anypoint.mulesoft.com/api/v2/organizations/7c63b543-fbe9-4c06-b113-6dcc66f9e02c/maven"><strong>https://maven.anypoint.mulesoft.com/api/v2/organizations/organisationId/maven</strong></a><strong>&lt;/url&gt;<br> &lt;layout&gt;default&lt;/layout&gt;<br> &lt;/repository&gt;<br> &lt;/distributionManagement&gt;</strong></p><p>9.</p><p><strong>&lt;repositories&gt;<br> &lt;! — Shared Mule Services Repository →<br> &lt;repository&gt;<br> &lt;id&gt;Exchange2&lt;/id&gt;<br> &lt;name&gt;Exchange2 Repository&lt;/name&gt;<br> &lt;url&gt;</strong><a href="https://maven.anypoint.mulesoft.com/api/v2/organizations/7c63b543-fbe9-4c06-b113-6dcc66f9e02c/maven"><strong>https://maven.anypoint.mulesoft.com/api/v2/organizations/organisationId/maven</strong></a><strong>&lt;/url&gt;<br> &lt;layout&gt;default&lt;/layout&gt;<br> &lt;/repository&gt;<br> &lt;/repositories&gt;</strong></p><p>10. In your <strong>.m2</strong> folder you have to create the <strong>setting.xml</strong> file.</p><p>11. The below screenshot you see we have to write in the same manner.</p><p>&lt;?xml version=”1.0&quot; encoding=”UTF-8&quot;?&gt;<br>&lt;settings xmlns=”<a href="http://maven.apache.org/SETTINGS/1.0.0">http://maven.apache.org/SETTINGS/1.0.0</a>&quot;<br> xmlns:xsi=”<a href="http://www.w3.org/2001/XMLSchema-instance">http://www.w3.org/2001/XMLSchema-instance</a>&quot;<br> xsi:schemaLocation=”<a href="http://maven.apache.org/SETTINGS/1.0.0">http://maven.apache.org/SETTINGS/1.0.0</a><br> <a href="http://maven.apache.org/xsd/settings-1.0.0.xsd">http://maven.apache.org/xsd/settings-1.0.0.xsd</a>&quot;&gt;<br> &lt;servers&gt;<br> &lt;server&gt;<br> &lt;id&gt;Exchange2&lt;/id&gt;<br> &lt;username&gt;pankaj07&lt;/username&gt;<br> &lt;password&gt;Pankaj@22&lt;/password&gt;<br> &lt;/server&gt;<br> &lt;/servers&gt;<br> &lt;/settings&gt;</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/653/1*7alp8qnlRDLX0G_fJNdEJg.png" /></figure><p>12. In the setting.xml file write the<strong>&lt;settings&gt;</strong> tag. if you miss it then it will throw an error.</p><p>13. Now, go to the path below as show.</p><p><strong>json-logger-mule-4.x\json-logger-mule-4.x\template-files</strong></p><p>14. In the<strong> template-files</strong> you are able to see in the <strong>settings</strong> file we have the tags as below mentioned.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/961/1*W4ppTqnfJhiC4eSjL9AeMA.png" /></figure><p><strong>&lt;server&gt;<br> &lt;id&gt;MuleRepository&lt;/id&gt;<br> &lt;! — Provided by Support →<br> &lt;username&gt;username&lt;/username&gt;<br> &lt;password&gt;password&lt;/password&gt;<br> &lt;/server&gt;<br> &lt;! — Customer Exchange Repository →<br>&lt;! — &lt;server&gt;<br> &lt;id&gt;Exchange2&lt;/id&gt;<br> &lt;! — NOTE: In order to be able to publish assets to exchange, this user will need Exchange Contributor Role <br> &lt;username&gt;username&lt;/username&gt;<br> &lt;password&gt;password&lt;/password&gt;<br> &lt;/server&gt; →<br> &lt;server&gt;<br>&lt;id&gt;Exchange2&lt;/id&gt;<br>&lt;! — NOTE: In order to be able to publish assets to exchange, this user will need Exchange Contributor Role →<br>&lt;username&gt;username&lt;/username&gt;<br>&lt;password&gt;password&lt;/password&gt;</strong></p><p><strong>&lt;/server&gt;</strong></p><p>15. Once we done all the changes as mentioned above steps then open the <strong>cmd</strong> and write <strong>mvn clean deploy</strong>.</p><p>16. Below are some screenshot of your JSON logger build successfully.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LtyIsybOLRIqpiPB_w1OhQ.png" /></figure><p>17. In the below image you will see JSON logger <strong>BUILD SUCCESS</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VcW3G24h8L7F6hdaOxd2hQ.png" /></figure><p>18. Now, go to Anypoint Exchange and click on the JSON Connector. you are able to see the different tabs on it as shown below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bkh07kIHr0cAeoCpvewbYA.png" /></figure><p>19. In <strong>Dependency Snippets</strong> you are able to find the different tabs.</p><p><strong>Maven as below:</strong></p><p><strong>&lt;dependency&gt; &lt;groupId&gt;7c63b543-fbe9–4c06-b113–6dcc66f9e02c&lt;/groupId&gt; &lt;artifactId&gt;json-logger&lt;/artifactId&gt; &lt;version&gt;2.0.1&lt;/version&gt; &lt;classifier&gt;mule-plugin&lt;/classifier&gt; &lt;/dependency&gt;</strong></p><p><strong>Gradle as below:</strong></p><pre><strong>compile group: &#39;7c63b543-fbe9-4c06-b113-6dcc66f9e02c&#39;, name: &#39;json-logger&#39;, version: &#39;2.0.1&#39;, classifier: &#39;mule-plugin&#39;</strong></pre><p><strong>SBT as below:</strong></p><p><strong>libraryDependencies += “7c63b543-fbe9–4c06-b113–6dcc66f9e02c” % “json-logger” % “2.0.1” classifier “mule-plugin”</strong></p><p>20. Now add the <strong>maven dependency</strong> of your project in the pom.xml as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/532/1*xzc8Y3KO5tQW1DHT1helVg.png" /></figure><p>21. If you are building any API you don’t have to and <strong>search in Exchange</strong> and <strong>search for that connector</strong> you have just add the <strong>dependency in the pom.xml</strong> and the<strong> connector</strong> will able to see in <strong>your mule palette</strong> as shown below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/352/1*YfCW-qDmG9mMkikpvRI4xQ.png" /></figure><p>22. Below is the Data that was logged using JSON Logger.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/605/1*hXy2KLQXMR4kBeNNVcdcng.png" /></figure><p>22. The biggest benefit of logging in JSON is that <strong>it has a structured format</strong>. This makes it possible to analyze application logs just like Big Data. It’s not just readable, but a database that can be queried for each and every field.</p><p><strong>Conclusion:</strong></p><p><strong>By using JSON logger, we can logging into any external log analytics tool such as ELK or Splunk.</strong></p><p><strong>References:</strong></p><ol><li><strong>Clone Repo:</strong></li></ol><p><a href="https://github.com/mulesoft-consulting/json-logger/tree/mule-4.x/json-logger">json-logger/json-logger at mule-4.x · mulesoft-consulting/json-logger</a></p><p>2. <a href="https://anypoint.mulesoft.com/"><strong>https://anypoint.mulesoft.com/</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=715934a8374e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Insertion of the Image in Database using MuleSoft]]></title>
            <link>https://itspankaj.medium.com/how-to-insert-image-in-database-using-mulesoft-6ddf2e447f6f?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/6ddf2e447f6f</guid>
            <category><![CDATA[mulesoft-esb]]></category>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[mulesoft-training]]></category>
            <category><![CDATA[mule]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Tue, 22 Mar 2022 08:50:43 GMT</pubDate>
            <atom:updated>2022-04-08T12:57:03.370Z</atom:updated>
            <content:encoded><![CDATA[<p>we can insert any image of any size and any format in any database using MuleSoft</p><ol><li>Use Case: To read any image file from the FTP location and insert into the <strong>MySQL</strong> Workbench Database.</li><li>Download the <strong>MySQL</strong> <strong>workbench</strong> and defined the schema according to the requirements.</li><li>We are going to insert the image into database. So,take the <strong>field</strong> name as <strong>Image</strong> and the <strong>datatype </strong>as <strong>BLOB.</strong></li><li>Please find the below screen shot of MySQL workbench.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/972/1*XUf4TKuUzBJWH8nEICgcMQ.png" /></figure><p>5. We are going to insert the Emp_Id , EMP_Name , Image in database using the MuleSoft.</p><p>6. Take Listener and do the configuration accordingly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/124/1*1r-a-_fwWxZfWxINTnAl2Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/602/1*PNhGn3ONBJKSD157-PbpYQ.png" /></figure><p>7. In the <strong>POST</strong> Method from the postman just pass the body as input for the<strong> two fields, </strong>which we defined in Database.</p><p>8. Pass the body in <strong>JSON Format</strong> as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/539/1*Ew57aGtwymhs7W3zjnQX8w.png" /></figure><p>9. In theMuleSoft, Take Transform Message and passed the variables as <strong>Emp_Id </strong>and <strong>Emp_Name</strong>.</p><p>10. Read the Image file from the location. So, before reading any image you can use file(<strong>Read File</strong>)connector and configure the path accordingly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/132/1*V3ZXA3kM2t0hDihHPvZrNA.png" /></figure><p>11. <strong>Configuration for Read File</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/608/1*_D81bQik4IziqbrYtKEVdg.png" /></figure><p>If you see below is the location and read the image file from particular path.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/653/1*d_vUAoarqG98OTbq7bbcKA.png" /></figure><p>12. The image format is <strong>PNG</strong> File.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HVPa8f6mBLuZgcAKcX2TuQ.png" /></figure><p>13. Now, take the <strong>INSERT</strong> connector from Mule palette and configure accordingly it.</p><p>14. Install <strong>MYSQL Workbench</strong> on your local system or you can use any <strong>Cloud Database</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/602/1*2NnGfOzOhcGH0CH5kfcbZg.png" /></figure><p>15. Make <strong>INSERT</strong> query in the<strong> MuleSoft</strong> accordingly we do in the <strong>Database</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/723/1*7pd-83zWMsXeo_Bqlwvnug.png" /></figure><p>16. The records of Employee and Image will be insert in the database.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/796/1*wMlfUuTXMd1wS76Y0rcm_w.png" /></figure><p>17. In the database the 3rd records is inserted successfully and you can see the Image as <strong>BLOB </strong>after that you can follow the steps.</p><p>Right click on <strong>BLOB → open value in Editor → there you able to get 3 </strong>option such as Binary, Text and Image</p><p>Click on<strong> Image.</strong></p><p>18. find the below image that we are call in MuleSoft and it is Successfully inserted in Database<strong>.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/780/1*puE2ZUuHcoqrxHnegq7UXQ.png" /></figure><p>19. The response in the Postman.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*vmPcBveLsbXC_XKwBDu2wA.png" /></figure><p><strong>Conclusion:</strong></p><p><strong>By using MuleSoft we can insert any Image in any Database System.</strong></p><p><strong>References:</strong></p><ol><li><a href="https://docs.mulesoft.com/general/">https://docs.mulesoft.com/general/</a></li></ol><p>2. To download the MYSQL</p><p><a href="https://dev.mysql.com/downloads/workbench/">https://dev.mysql.com/downloads/workbench/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6ddf2e447f6f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Installation Steps for Mule 3 and Mule 4 Studio]]></title>
            <link>https://itspankaj.medium.com/installation-steps-for-mule-3-and-mule-4-studio-242b330e9dbc?source=rss-363c3a1e3c73------2</link>
            <guid isPermaLink="false">https://medium.com/p/242b330e9dbc</guid>
            <category><![CDATA[mulesoft]]></category>
            <category><![CDATA[mule]]></category>
            <category><![CDATA[mulesoft-esb]]></category>
            <dc:creator><![CDATA[Pankaj Badi]]></dc:creator>
            <pubDate>Thu, 10 Mar 2022 13:31:19 GMT</pubDate>
            <atom:updated>2022-03-10T13:31:19.348Z</atom:updated>
            <content:encoded><![CDATA[<p>Basic of the MuleSoft while downloading the Mule 3 and Mule 4 Anypoint Studio.</p><p>1. I have to install Mule 3 and Mule 4 in my local machine.</p><p>2. So, The first thing we have to download the java version and that should be 8 or above to work both studio in our local system.</p><p>3. Initially, I have download the java version and when I check on my cmd it shows the java version like this.</p><p><strong>C:\Users\a810789&gt;java -version</strong></p><p><strong>java version “1.8.0_321”</strong></p><p><strong>Java(TM) SE Runtime Environment (build 1.8.0_321-b07)</strong></p><p><strong>Java HotSpot(TM) Client VM (build 25.321-b07, mixed mode)</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/677/1*5tfSvkYgZi40U9AqIwj-EQ.png" /></figure><p>4. If you observed the Client is VM. So, while running the mule 4 its running but mule 3 is not running.</p><p>5. please find the below screen shot its throwing me an error.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/403/1*jNyCfV4y5X-daOwmLxqUVA.png" /></figure><p>6. So, I uninstall the java version and install the java 8 version in my system from the below link.</p><p><a href="https://www.java.com/en/download/manual.jsp">https://www.java.com/en/download/manual.jsp</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TVhdLV8keelXIh5d4BXSsg.png" /></figure><p>7. I have downloaded the java version as per the system configuration that is 64 bit.</p><p>8. When I run my java in the cmd.</p><p><strong>C:\Users\a810789&gt;java -version<br>java version “1.8.0_321”<br>Java(TM) SE Runtime Environment (build 1.8.0_321-b07)<br>Java HotSpot(TM) 64-Bit Server VM (build 25.321-b07, mixed mode)</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/581/1*EsWrJrQj_BNh9Bj1xgnq4g.png" /></figure><p>9. Both Mule 3 and Mule 4 Anypoint Studio is working fine now.</p><p>10. Please find the below screenshot for Mule 3 Anypoint studio.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6xDZlAMS0vSC5wy_jjZHkg.png" /></figure><p>11.Please find the below screenshot for Mule 4 Anypoint studio.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Nno6KoJhMNGDIxWDhiHT8A.png" /></figure><p><strong>Conclusion:</strong></p><p>By doing the following above step and proper version of <strong>java 8 or above</strong> you can run Mule 3 and 4 on your local system.</p><p><strong>References:</strong></p><ul><li><a href="https://www.java.com/en/download/manual.jsp">Download Java</a></li><li><a href="https://docs.mulesoft.com/general/">MuleSoft Documentation</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=242b330e9dbc" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>