Node:js : Building Rest Apis with Sails.js
4.6 (23 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
3,132 students enrolled
Wishlisted Wishlist

Please confirm that you want to add Node:js : Building Rest Apis with Sails.js to your Wishlist.

Add to Wishlist

Node:js : Building Rest Apis with Sails.js

A complete guide to building rest apis with Sails.js,Node.js and Mongodb
4.6 (23 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
3,132 students enrolled
Created by Haider malik
Last updated 8/2017
Current price: $15 Original price: $100 Discount: 85% off
6 hours left at this price!
30-Day Money-Back Guarantee
  • 2 hours on-demand video
  • 3 Articles
  • 20 Supplemental Resources
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
What Will I Learn?
  • Create Rest Api in Sails.js
  • Understand Polices and middlewares in Sails.js
  • Understand JWT Authentication
  • CRUD(Create,Read,Update,Delete) in Sails.js
  • How to use Mongodb with Sails.js
  • How to use Mysql with Sails.js
View Curriculum
  • A Mac or Pc
  • Basic knowledge of Javascript is Important
  • Basic knowledge of Node.js will be helpful

Learn how to build an api with Sails.js and Node.js

This course will include topics on

  • What Sails.js is and why should you use sails.js to build server side app
  • Why should you use sails.js rather than express.js
  • How sails.js is built on the top of express.js
  • How to build routes in sails.js
  • What middlewares and polices are in sails.js and how to use them
  • Understand Sails.js by debugging the App
  • What controllers are in sails.js and how to use them
  • How to use services in sails.js 
  • What are blueprints in sails.js, How to quickly generate rest api in sails.js
  • Understanding Jwt Authentication
  • How to perform CRUD operation in sails.js
  • How to connect sails.js app to mongodb
  • How to connect sails.js app to mysql

Students should have the basic knowledge of Node.js . If you know express.js ,I would highly recommend you to take this course because Sails.js is built on the top of express.js

Who is the target audience?
  • Programmers looking to learn Node.js
  • Developers who have some experience in Express.js
  • Developers who have researched Sails.js but have had trouble understanding some concepts
Students Who Viewed This Course Also Viewed
Curriculum For This Course
47 Lectures
Introduction to Sails.js
5 Lectures 06:01

Learn what Sails.js is and why it's become popular framework in Node.js

Preview 01:32

Installing Node.js

Learn how to install Sails.js on your machine

Preview 00:44

Create your first sails.js application

Creating Sails Project

Understand the directory or folder structure of sails.js .How sails.js organized app structure

Understanding App structure
Understanding sails blueprints
4 Lectures 08:17

Learn how blueprints work in sails.js. How quickly you can generate rest api

Preview 00:32

Learn the concept of Restful routes in sails.js

Restful Routes

By default sails has enabled shortcut routes. You will learn how to use shortcut routes

Shortcut Routes

Learn what are action routes and how to use in sails.js app

Action Routes
Connecting Sails app to database
4 Lectures 09:07

Learn how to install mongodb on your machine

Installing Mongodb

RoboMongo is a GUI tool to manage mongodb database. You will learn how to install RoboMongo on your machine

Installing RoboMongo

Learn how to use mongodb with sails.js app

Connecting Sails To Mongodb

If you want to use mysql database. you can also connect mysql with sails.js

Connecting Sails To Mysql
Building models
7 Lectures 10:54

Understand the schema diagram of our demo app


Learn to create first model in sails.js

Preview 02:13

Installing Sails Autoreload hook

Creating Category model

Creating User model

You will learn how to add relationship between models.I will teach you one to many relationship in sails.js

Adding Relationship With User and Post

CRUD(Create,Read,Update,Delete) in Sails.js
11 Lectures 44:29

Learn how to define routes in sails.js app. You will learn how to add controller action against each route

Setting Up Routes

Learn how to use callbacks in sails.js

Creating New Category with Callback Way

Creating new Post with Callback Way

If you like promises, you can also use promises in sails.js.

Creating Post and Category With Promises Way

Learn how to avoid callback hell by using async.js. Async.js is a third party library

Creating Post and Category With Async.js

Learn how to setup debugging in Webstorm. I will also teach you some tips and tricks to debug sails.js app

Preview 02:31

Learn how to use Async/await in sails.js. Async/await is a new way to write asynchronous code in node.js

Creating Post and Category with Async/Await

Learn how to get single record from database

Get single Post

Learn how to get multiple records from database

Get all Posts

Learn how to delete record in database

Delete Post

Learn how to update record in database

Update Post
Adding jwt Authentication
13 Lectures 47:56

Learn how to setup routes and controller actions for authentication

Creating AuthController and Routes

You will be able to create a new user in database

Signup User

Learn how to encrypt user password field. I will teach you how to create new service in sails.js

Add Encrypted Password

Remove Password from Response

Learn how to login a user to his existing account

Login user

Learn how to compare the existing password with current password

Compare User Password

Learn how to generate jwt token by using external third party npm package

Generating token for User

Learn what policies and middlewares are in sails.js.How policies work in sails.js

Polices in Sails.js

Learn how to verify the token which provided by the user

Verify Jwt Token

Learn to create first policy in sails.js

Create isAuthenticated Policy

Learn how to apply policies to routes. How to restrict routes and adding role based authentication

Apply isAuthenticated Policy

Understand how policy work under the hood in sails.js

Preview 03:13

Refactor User in Create Post
Bonus Lecture
3 Lectures 00:14

90% Discount: Build Rest Apis Development Using Loopback

Free Content on Youtube Channel
About the Instructor
Haider malik
4.0 Average rating
70 Reviews
5,584 Students
2 Courses
Freelance fullstack Javascript developer

Haider Malik is the founder of fullstackhour. He is a full-stack Javascript developer. He is passionate about everything JavaScript, and he loves exploring new libraries.

He’s had extensive experience developing software and working with teams to improve how software is developed to meet business objectives.Although his primary focus is on outcomes, implementation often includes technical competency