-
SOAP (Simple Object Access Protocol) and REST (Representational State Transfer) are two different types of web service protocols used for exchanging data between two systems. Here are some differences between the two:
Architecture
SOAP is an XML-based protocol that follows a strict messaging format and has a formal contract (WSDL) for defining the interface between the client and the server.
REST is an architectural style that uses HTTP methods (GET, POST, PUT, DELETE) to access and manipulate resources.
Data format:
SOAP messages are always XML-based and use a schema to define the structure of the data being transmitted.
RESTful APIs support multiple data formats including XML, JSON, YAML, and others.
Endpoint
In SOAP, each endpoint has a unique URL that is used to access the service.
In REST, each resource has a unique URL that is used to access it.
Performance
SOAP is considered to be slower and more complex than REST due to its use of XML and the additional processing required for parsing the messages.
REST is generally faster and simpler due to its lightweight nature and use of standard HTTP methods.
Security
SOAP has built-in security features such as WS-Security that provide a high level of security.
REST does not have built-in security features but relies on SSL/TLS encryption for secure communication.
In summary, SOAP is a more structured and formal protocol, while REST is a more flexible and lightweight approach to web services. The choice between the two largely depends on the specific requirements of the application being developed.
-
කවුරු හරි ඉන්නවද Bigcommerce site එකේ API එක්ක වැඩකරපු. මට දැනගන්න ඕනේ ඒකෙ store එකක ඉන්න customer කෙනෙක් වෙනම අපි හදන site එකකින් Authenticate වෙන්න සහ ඒ හදන site එකේ payment මේ Bigcommerce හරහා කරගන්න. එකේ සමහර තැන් ටිකක් තියනව දැන ගන්න.
-
-
Full Stack Developer (Spring Boot, Angular 2)
Job Description
Skill Sets Required:Javascript, PHP, HTML5, JQUERY, CSS, MYSQL, CSS3 WEBSITE DEVELOPMENT
Programming / Scripting Languages: Java 7, JavaScript, SQL, PL/SQL
J2EE Technologies: Spring Boot
UI Technologies: HTML5, CSS3, JavaScript, Bootstrap, Ajax, JSON
JavaScript Frameworks: Angular JS
Databases: MySQL 5.7, MS SQL
Versioning Tools: GitHub, SVN
Operating Systems: Windows,
Skills Required: JavaScript, Java, J2EE, HTML, MySQL -
-
Nest.png
Nowadays we use JavaScript not only for front-end applications but also for server-side applications with the help of node.js. There are lots of popular frameworks out there for node.js. Express is the most popular framework so far. but there are other frameworks like Meteor, Koa, Sails, Hapi, Loopback, etc. Nest.js is also a server-side node.js framework built by Kamil Mysliwiec and the community, In the past 2 years nest.js become the fastest-growing node.js technology, and currently, it has 35.9K GitHub stars.As I mentioned before Node.js (for the server-side) has plenty of great libraries, But none of them solves the main problem of architecture. Nest provides an out-of-the-box application architecture that allows developers and teams to create highly testable, scalable, loosely coupled, and easily maintainable applications. The architecture is heavily inspired by Angular.
What so special about this framework?
Nest JS is an open-source framework for building efficient, scalable Node.js server-side applications.
Built-in typescript support. (yet still enables developers to code in pure JavaScript).
Combines elements of Object-Oriented Programming, Functional Programming, and Reactive Programming.
Nest.js provides a similar kind of architecture to other server-side applications like .NET Core, Java Spring Boot, etc.
Under the hood, Nest makes use of robust HTTP Server frameworks like Express (the default) and optionally can be configured to use Fastify as well.
Let’s create a “Hello World” app with Nest JS.
First of all you need to install Node.js. Click here to download Node.js for your operating system.
Then You need Nest-CLI. This helps you to initialize and develop your applications. Open the command line and execute this command.
npm install -g @nestjs/cli Now you can generate a new project using this command. Replace “my-nest-project” with your project name. nest new my-nest-project Go to the project directory and execute the below command to start the application. npm run start:devThat's it, Now In your browser, open http://localhost:3000 to see a new application running. The app will automatically recompile and reload when you change any of the source files.
You can easily learn lots of things by referring to Nest JS documentation. The Nest JS documentation is well-maintained and contains a lot of information with real examples. https://docs.nestjs.com/
Read my original post on medium - https://dlbnprabath.medium.com/introduction-to-nest-js-a-progressive-node-js-framework-for-backend-acd76a018681
Happy Coding :)
-
-
-
Laravel walata payhere payment gateway checkout api eka integration karapu kenek innawada?
Mama mulinma checkout ekdi payhere checkout click karaham products data controller eken db eke payhere table ekata save karanawa, ita passe controller eken return redirect karanawa
//up more codes for db and etc $post = array( 'merchant_id' => '1213296', 'return_url' => 'http://kali/return', 'cancel_url' => 'http://kali/cancel', 'notify_url' => 'http://kali/notify', 'order_id' => 'ItemNo12345', 'items' => 'Door bell wireless', 'currency' => 'LKR', 'amount' => '1000', 'first_name' => 'Saman', 'last_name' => 'Perera', 'email' => '[email protected]', 'phone' => '0771234567', 'address' => 'No.1, Galle Road', 'city' => 'Colombo', 'country' => 'Sri Lanka' ); return redirect('https://sandbox.payhere.lk/pay/checkout')->with('post', $post);data db ekata gihilla sandbox url ekata redirect wenawa but sandbox ekedi man pass karana data mukut gahanne na merchant error enawa
payhere.jpeg
-
logo.jpg
image is taken from www.syncfusion.com
In the previous article, I explained the basics of .Net Core web API, How to create a project and run it using .Net CLI. You can read it here.
Today as I promised, we gonna take a look at the project files that we have given out of the box and what responsible for getting us the result we saw in the previous article.
Program.cs
program.png
“Program.cs” is the most important file. because it is the starting point of our application. It contains a method called Main. When we hit the “dotnet run” command in the CLI, it’s looking for the “Main ”method in the “Program.cs” class and executes it. In the “Main ”method, it’s calling another method called “CreateHostBuilder” which you can see below the Main method and this responsible for configuring the webserver which is “Kestral ” with some default configurations. The configurations are read from appSettings.json / appsettings.Development.json files and we also provide some additional configurations inside a class called “Startup”.
“Kestral” is an open-source cross-platform web server for Asp.Net Core.
appSettings.json / appsettings.Development.json
appSettings.png
We can give our application some configurations inside the “ appsettings.json” file or we can use “ appsettings.Development.json” for development mode.
Startup.cs
Startup.png
In the Startup class, we can see a constructer with configurations injected into that. So that we can read configurations we defined in appsettings.json.
There are another two methods called “ConfigureServices ”and “Configure”.
The “ConfigureServices ” method is our dependency injection container. We can create and add our own services to this. I’ll explain what is dependency injection and how to write our own services and add those into our application via dependency injection in another article.“Configure” is the place where we add middleware. I’ll also explain the use of middleware with another article.
Controllers
controller.png
There is a file called “WeatherForecastController.cs” in the controllers' folder. It is the default controller that comes with the .Net Core web API. What controllers does is, When we start our application it’s going to map all of our endpoints in our controllers so that our API knows where to send the request to.
launchsettings.json
launchsettings.png
There is another JSON file called “launchsettings.json”. When we start the application it also takes a look inside this file for any options. We have our application URL, environment variables, etc.
These are the main files you need to know. To understand these things I will guide you on how to create our own API endpoints and services in upcoming articles.
find me on medium - https://dlbnprabath.medium.com/
-
main.png
image from https://raygun.com/
This .Net Core Web API beginners guide is for the software engineering students, self-thought programmers, or anyone who wants to learn the basics of .Net Core Web API.
.Net Core is a free and opensource framework to develop applications for Windows, Mac, or Linux and It is the successor of the good old .Net Framework. Nowadays there are lots of programming languages and web frameworks to learn. So should I learn .Net Core? Is it worth it? Okay let’s see,
.Net Core is now cross-platform which means if you are using Windows, Linux, or Mac, you can simply develop and run the applications with.Net Core.
You can develop a wide variety of applications with .Net Core like REST APIs, web applications, mobile backends, IoT applications, etc.
Fully featured Development IDEs, tools such as visual studio can be used to develop desktop, cloud, and mobile applications. You can even use vs code :)
We can use C# for development. which is a great OOP language.
There are a lot more advanced features than this available with .Net Core. since this article is for beginners I’m not gonna go into that level. So enough intro right? Let’s do some coding.
First of all, you need to download and install the .Net Core SDK. Go to this link and download and install the latest .Net Core 3.1 SDK for your operating system.
Note that the next major release of .Net Core is gonna be .NET 5 and they are removing the Core name from the framework to avoid confusion with those using the .Net Framework which is currently on version 4 and .Net Core currently on version 5. Don’t think about this for now. I’ll explain this with a separate article. :)
.net web.png
We are using dotnet CLI to do all the things.
Now open the command line and type “dotnet — version”. If you successfully installed the .Net Core SDK it’ll show the installed version. If you're seeing this we’re good to go :)
dotnet -v.png
The code editor I’m using is vs code because it’s a cross-platform and an excellent editor. With some extensions installed, We can do lots of things with it. Download from here https://code.visualstudio.com/
For a better C# development experience install the C#, C# Extensions for vs code, and for our icons look better if you install material icon theme :)
mt icon ext.png c# ext2.png C# ext.png
Download the Postman client from this link to test the APIs.
Open your command line and create a new directory. mkdir hellowebapihellowebapi.png
Now go to the directory using the cd command like below.
cd hellowebapi Now let’s create the solution file and template for web API using dotnet CLI. dotnet new slnnew sln.png
If we don’t give any options sln will take the name of the folder which will be ok for our purpose.
dotnet new webapi -o APInewwebapi.png
Now we need to add the API project to our solution. let’s go ahead and do that.
dotnet sln add API/slnadd.png
Let’s open the project using vs code.openinvscode.png
It’ll take a few seconds to download dependencies. If you are using vs code a pop-up msg will appear to install the required assets. click yes.
buildrases.png
After that, we can run the project using dotnet CLI. Open the terminal in vs code using Ctrl + ~ on Windows and Cmd + `on a mac.
Cd into the API project and run the project using the below commands.
cd API dotnet rundotnetrun.png
Now you can see a project is running on https://localhost:5001
Now let’s check the default weather forecast endpoint with the postman.
First, we need to disable SSL in the postman. postmanssl.png
Then we can check the default endpoint
https://localhost:5001/WeatherForecastpostmanendpoint.png
Hola... Now we get the response is back from the server.
Wait a minute. I know what you’re thinking. If you’re an absolute beginner you may not have any idea what’s going on. This article is just to get started with the .net core web API. In part 02 I’ll explain what’s all this and what’s happening behind the scenes in detail. Until then feel free to play with this :)
Find my original article on medium: - https://medium.com/@dlbnprabath
-
Rapid Development Using Azure Spring Cloud
Webinar session hosted by Microsoft in partnership with PALO IT | 🔴 Live Recording -
මම API එකකින් response එක ගන්නවා. එකේන්, මේ පහල විධියට arrays 2ක් එක්ක response එක එනව.
routesOutput: [{origin_iata: "CMB", destination_iata: "IST",…}, {origin_iata: "CMB", destination_iata: "SAW",…}] 0: {origin_iata: "CMB", destination_iata: "IST",…} 1: {origin_iata: "CMB", destination_iata: "SAW",…} schedulesOutput: [{departure_iata: "CMB", arrival_iata: "MLE",…}, {departure_iata: "MLE", arrival_iata: "IST",…},…] 0: {departure_iata: "CMB", arrival_iata: "MLE",…} 1: {departure_iata: "MLE", arrival_iata: "IST",…}මේකේ, routesOutput කියන array එක ඇතුලේ weekly කියල තව array එකක් තියෙනව. ඒක ඇතුලේ flight_ids කියල එකක් තියෙනව. මේ පහල විධියට.
routesOutput[0].schedules.weekly[0].flights.flight_ids routesOutput: [{origin_iata: "CMB", destination_iata: "IST",…}, {origin_iata: "CMB", destination_iata: "SAW",…}] schedules: {updated: {}, weekly: [{routing_id: "159058258847310869390999", frquency: [1, 1, 0, 1, 1, 0, 1],…},…]} weekly: [{routing_id: "159058258847310869390999", frquency: [1, 1, 0, 1, 1, 0, 1],…},…] 0: {routing_id: "159058258847310869390999", frquency: [1, 1, 0, 1, 1, 0, 1],…} technical_stops: "MLE" flights: {flight_ids: ["159058258847310869501898", "159058258847310869627899"]} flight_ids: ["159058258847310869501898", "159058258847310869627899"] 0: "159058258847310869501898" 1: "159058258847310869627899"ඒ වගේම, schedulesOutput කියන array එක ඇතුලේත් flight_ids කියල තියේනව. මේ පහල විධියටම.
schedulesOutput[0].flights.flight_ids schedulesOutput: [{departure_iata: "CMB", arrival_iata: "MLE",…}, {departure_iata: "MLE", arrival_iata: "IST",…},…] 0: {departure_iata: "CMB", arrival_iata: "MLE",…} flights: [{flight_ids: "159058258847310869501898", operating_iata: "TK",…},…] 0: {flight_ids "159058258847310869501898", operating_iata: "TK",…} flight_ids: "159058258847310869501898":මම for loops පාවිච්චි කරල , ඒවා loop කරල, arrays 2ම එක සමාන flight_ids තියේන ඒවා අරගෙන, ඒවා එක array එකකට push කරා. නමුත්, routesOutput[0].schedules.weekly[0].flights.flight_ids[0] හා [1] එකම element එකකට push කරන්න තමයි මට ඕන.
මෙහම තමයි මට ලැබුනේ.
[ { "ori_sub_origin": "CMB", "ori_sub_desti": "MLE" }, { "desti_sub_origin": "MLE", "desti_sub_desti": "IST" }, ]මේ විධියටයි මට ඕන වෙන්නේ.
[ { "ori_sub_origin": "CMB", "ori_sub_desti": "MLE", "desti_sub_origin": "MLE", "desti_sub_desti": "IST" } ]මෙන්න මගේ කෝඩ් එක.
for(i = 0; i < routes_with_weekly.length; i++) { let test_one = routes_with_weekly[i].flights.flight_ids[0]; let test_one_desti = routes_with_weekly[i].flights.flight_ids[1]; for(j = 0; j < schedulesOutput_let.length; j++) { if(schedulesOutput_let[j].flights[j] != undefined) { let test_two = schedulesOutput_let[j].flights; for(v = 0; v < test_two.length; v++) { let test_three = test_two[v].flight_ids; if(test_one == test_three) { let ori_all_data = { "ori_sub_origin" : schedulesOutput_let[j].departure_iata, "ori_sub_desti" : schedulesOutput_let[j].arrival_iata }; all_data_arr.push(ori_all_data); // break; } } } } } //desti for(r = 0; r < routes_with_weekly.length; r++) { let test_one = routes_with_weekly[r].flights.flight_ids[1]; for(t = 0; t < schedulesOutput_let.length; t++) { if(schedulesOutput_let[t].flights[t] != undefined) { let test_two = schedulesOutput_let[t].flights; for(b = 0; b < test_two.length; b++) { let test_three = test_two[b].flight_ids; if(test_one == test_three) { let desti_all_data = { "desti_sub_origin" : schedulesOutput_let[t].departure_iata, "desti_sub_desti" : schedulesOutput_let[t].arrival_iata }; all_data_arr.push(desti_all_data); // break; } } } } } console.log(JSON.stringify(all_data_arr , null, 2)) -
-
මගේ repository එකක් තියෙනවා Bitbucket වල. cPanel තියෙන VPS එකක් එක්ක connect කරන්නේ කොහොමද automatically deploy වෙන්න.
දැනට repository එක SSH වලින් clone කරලා තියෙන්නේ cPanel එකේ. Local changes Bitbucket එකට push කරලා. cPanel SSH වලින් pull කරනවා.
Bitbucket වලට push කරහම cPanel එකට auto deploy වෙන්න ක්රමයක්?
-
-
10 Web Development YouTube Channels You Probably Didn't Know About
2582acfc-6a8c-4f4b-a7c0-6ce0f3b585bd-image.png
If you are a web developer who is constantly searching for tutorials on YouTube, you’ve definitely come across Traversy Media, Dev Ed, The Net Ninja and some other cool instructors creating awesome content for web developers. However, there are a few more you probably didn’t know about.
Of course, most of these channels may not presently be as popular as the ones mentioned above, but the content they create is truly informative. So, let’s have a look at some of these:
This channel by John Smilga features a whole bunch of high quality tutorials on various topics such as Bootstrap, CSS, React, ES6, etc. Instead of simply talking about the syntax, John actually walks you through the entire process of building projects using various web technologies.
Created by Dom, a web developer from Australia, the channel has 100s of awesome tutorials on technologies like JavaScript, Rust, PHP, CSS and many more. Make sure to check out the JavaScript playlist that has over 180 videos for beginners, intermediate and experts.
The channel has some great content related to HTML, CSS, JavaScript, SASS, React.js and Node.js to name a few. Jesse, the owner of the channel has the right teaching skills to make complicated concepts look simple. He also has a few 'Learn X in Y minutes' styled videos that are worth checking out.
Want to learn how to build a complete responsive website using Bootstrap? Drew Ryan has some amazing tutorials in store for you. You can also check out his premium courses on Udemy.
This is without a doubt, one of my go-to channels to learn React. Not just React, the channel has a lot of great content related to CSS, Vue.js, mongoDB, Node.js, etc. At the time of writing this post, the channel has over 180 thousand subscribers and definitely deserves a lot more than that.
If a CSS Ninja is what you aspire to be, ‘Online Tutorials’ is a channel you should be subscribing to right away. An interesting thing about the channel is that the tutorials contain no audio explanation. However, the instructor walks you through the entire project from scratch, ensuring that the pace is right, so that you are able to code along.
One of the best ways to move from being a JavaScript beginner to an intermediate is to build apps. If you are looking for code-along video tutorials on how to build fancy JavaScript apps, check out Code Explained. Apart from helping you build a To-do list, a budget app or a calculator, the instructor also show you how to create complex games such as the Flappy Bird, Ping Pong and Tetris.
If building JavaScript games is what excites you the most, this channel is sure to further add up to your excitement. Minesweeper, Tetris, Candy Crush, Pac Man and of course, the classic snake game, this channel can help you build all of these. Apart from games, the channel also has short videos on various concepts related to Vanilla JavaScript and React.js.
Apart from web development, the channel also has a good number of videos on how to design user interfaces in Adobe XD. Moreover, you can also find some beginner-friendly Photoshop tutorials on the channel.
Finally let's talk a bit about WordPress. If you've just got a client who urgently needs a website, WordPress comes at your rescue. However, if you haven't worked with WordPress before, a few tutorials can definitely help get started. On this channel, Tyler Moore shows you how to build beautiful looking WordPress websites step by step with no step skipped.
-
This topic is deleted!
• adi.justdev -
This topic is deleted!
• BuddhikaNelum