{"id":3949,"date":"2016-12-22T08:20:53","date_gmt":"2016-12-22T08:20:53","guid":{"rendered":"https:\/\/www.botreetechnologies.com\/blog\/?p=3949"},"modified":"2023-02-16T16:07:31","modified_gmt":"2023-02-16T10:37:31","slug":"auto-generate-rest-api-using-sailsjs","status":"publish","type":"post","link":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/","title":{"rendered":"Auto Generate REST API using SailsJS"},"content":{"rendered":"\n<p>Sails is a lightweight framework that sits on top of&nbsp;<a href=\"https:\/\/github.com\/expressjs\" target=\"_blank\" rel=\"noopener noreferrer\">Express<\/a>. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What is&nbsp;SailsJS?<\/h2>\n\n\n\n<p><a href=\"http:\/\/sailsjs.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">Sails<\/a>&nbsp;is one of the most popular&nbsp;<a href=\"https:\/\/en.wikipedia.org\/wiki\/Model%E2%80%93view%E2%80%93controller\" target=\"_blank\" rel=\"noopener noreferrer\">MVC<\/a>&nbsp;framework used to build NodeJS apps. And for those who are from&nbsp;<a href=\"http:\/\/rubyonrails.org\/\" target=\"_blank\" rel=\"noopener noreferrer\">Ruby on Rails<\/a>&nbsp;background will find SailsJS easy to use because of the directory structure is similar as any Rails app. Sails can be used to create Rest API&#8217;s, chat application, multiplayer games. etc. and many more. Just like Rails, it help to reduce boilerplate code.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Features<\/h3>\n\n\n\n<p>100% Javascript<\/p>\n\n\n\n<p>Compatible with MySQL, MongoDB, PostgreSQL, Redis etc.<\/p>\n\n\n\n<p>Auto-generate REST API<\/p>\n\n\n\n<p>Support Web sockets<\/p>\n\n\n\n<p>Follows&nbsp;<a href=\"https:\/\/en.wikipedia.org\/wiki\/Convention_over_configuration\" target=\"_blank\" rel=\"noopener noreferrer\">convention over configuration<\/a>&nbsp;policy<\/p>\n\n\n\n<p>and&nbsp;<a href=\"http:\/\/sailsjs.com\/features\" target=\"_blank\" rel=\"noopener noreferrer\">much more<\/a>.<\/p>\n\n\n\n<p>We can create REST API using simple commands in few minutes. Let see how it can be done.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Installation<\/h3>\n\n\n\n<p>First all you need to&nbsp;<a href=\"https:\/\/nodejs.org\/en\/download\/\" target=\"_blank\" rel=\"noopener noreferrer\">install NodeJS<\/a>&nbsp;on your machine.<\/p>\n\n\n\n<p>You can then install stable version of Sails using following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">npm install sails -g<\/pre>\n\n\n\n<p>Creating API<\/p>\n\n\n\n<p>Now lets create a Sails application<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sails new test_app<\/pre>\n\n\n\n<p>You should see following message in your console after the app is created successfully:<\/p>\n\n\n\n<p>info: Created a new Sails app &#8216;test_app&#8217;!<\/p>\n\n\n\n<p>Now move to the app directory.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">cd test_app\/<\/pre>\n\n\n\n<p>and start Sails server with following command<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sails lift<\/pre>\n\n\n\n<p>If everything goes right you will see following screen.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"604\" height=\"487\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/sails-lift.png\" alt=\"sails lift\" class=\"wp-image-13930\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/sails-lift.png 604w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/sails-lift-300x242.png 300w\" sizes=\"auto, (max-width: 604px) 100vw, 604px\" \/><\/figure>\n<\/div>\n\n\n<p>It uses port no&nbsp;1337&nbsp;as the default port.<\/p>\n\n\n\n<p>Visit&nbsp;<code>http:\/\/localhost:1337<\/code>&nbsp;in your browser to see the home page of your sails app.<\/p>\n\n\n\n<p>Now, lets create simple REST API for&nbsp;User&nbsp;model with attributes&nbsp;name&nbsp;and&nbsp;email.<\/p>\n\n\n\n<p>Run the following command in your console<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sails generate api users name email<\/pre>\n\n\n\n<p>This will create API with REST actions. Now when you start the server, you will have three options to choose(see attached).<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"749\" height=\"444\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/API-with-REST-actions.png\" alt=\"API with REST actions\" class=\"wp-image-13931\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/API-with-REST-actions.png 749w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/API-with-REST-actions-300x178.png 300w\" sizes=\"auto, (max-width: 749px) 100vw, 749px\" \/><\/figure>\n<\/div>\n\n\n<p>Choose&nbsp;2&nbsp;(i.e the alter option)&nbsp;and press enter. Now the REST API is ready to use! So easy!<\/p>\n\n\n\n<p>Following are the routes which we can use. It deals with&nbsp;<a href=\"http:\/\/www.json.org\/\" target=\"_blank\" rel=\"noopener noreferrer\">JSON<\/a>&nbsp;data.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>GET \/users<\/li>\n\n\n\n<li>GET \/users\/:id<\/li>\n\n\n\n<li>POST \/users<\/li>\n\n\n\n<li>PUT \/users\/:id<\/li>\n\n\n\n<li>DELETE \/users\/:id<\/li>\n<\/ul>\n\n\n\n<p>I would recommend to use&nbsp;<a href=\"https:\/\/www.getpostman.com\/docs\/introduction\" target=\"_blank\" rel=\"noopener noreferrer\">Postman<\/a>&nbsp;to test the API. Following screenshot shows how to send request to create a user by using the API.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"445\" src=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/Postman.png\" alt=\"Postman to test the API\" class=\"wp-image-13932\" srcset=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/Postman.png 800w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/Postman-300x167.png 300w, https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/12\/Postman-768x427.png 768w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/figure>\n\n\n\n<p>Now you can use this API anywhere you want!<\/p>\n\n\n\n<p>You can find introduction to SailsJS and some features in following video.<\/p>\n\n\n\n<p><iframe loading=\"lazy\" src=\"https:\/\/www.youtube.com\/embed\/GK-tFvpIR7c\" width=\"560\" height=\"315\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/p>\n\n\n\n<p>That&#8217;s it! Thanks for reading!<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">References<\/h3>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p><a title=\"http:\/\/sailsjs.com\/\" href=\"http:\/\/sailsjs.com\/\" target=\"_blank\" rel=\"nofollow noopener noreferrer\" data-href=\"http:\/\/sailsjs.com\/\"><b>Sails.js | Realtime MVC Framework for Node.js<\/b><br><i>Sails.js makes it easy to build custom, enterprise-grade Node.js apps. It is designed to resemble the MVC architecture&#8230;<\/i>sailsjs.com<\/a><\/p>\n<\/blockquote>\n\n\n\n<p><a href=\"https:\/\/www.botreetechnologies.com\/ruby-on-rails-development\" target=\"_blank\" rel=\"noopener noreferrer\"><strong>Click here for more details&#8230;<\/strong><\/a><\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<p>At <a href=\"https:\/\/www.botreetechnologies.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">BoTree Technologies<\/a>, we build enterprise applications with our RoR team of 25+ engineers.<\/p>\n\n\n\n<p>We also specialize in RPA, AI, Python, Django, JavaScript and ReactJS.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><a href=\"https:\/\/www.botreetechnologies.com\/contact\" target=\"_blank\" rel=\"noopener noreferrer\">Consulting is free<\/a> &#8211; let us help you grow!<\/h3>\n","protected":false},"excerpt":{"rendered":"<p>Sails is a lightweight framework that sits on top of&nbsp;Express&#8230;.<\/p>\n","protected":false},"author":9,"featured_media":13929,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[73,10],"tags":[],"class_list":["post-3949","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ruby-on-rails","category-technology"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.2 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Auto Generate REST API using SailsJS<\/title>\n<meta name=\"description\" content=\"Sails is a lightweight framework that sits on top of Express. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Auto Generate REST API using SailsJS\" \/>\n<meta property=\"og:description\" content=\"Sails is a lightweight framework that sits on top of Express. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\" \/>\n<meta property=\"og:site_name\" content=\"BoTree Technologies\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/BoTreeTechnologies\/\" \/>\n<meta property=\"article:published_time\" content=\"2016-12-22T08:20:53+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-02-16T10:37:31+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg\" \/>\n\t<meta property=\"og:image:width\" content=\"2000\" \/>\n\t<meta property=\"og:image:height\" content=\"1333\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Ankur Vyas\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@BoTreeTech\" \/>\n<meta name=\"twitter:site\" content=\"@BoTreeTech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Ankur Vyas\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\"},\"author\":{\"name\":\"Ankur Vyas\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/aa180b4d8d933949f15aba97d8d138a5\"},\"headline\":\"Auto Generate REST API using SailsJS\",\"datePublished\":\"2016-12-22T08:20:53+00:00\",\"dateModified\":\"2023-02-16T10:37:31+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\"},\"wordCount\":477,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg\",\"articleSection\":[\"Ruby on Rails\",\"Technology\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\",\"name\":\"Auto Generate REST API using SailsJS\",\"isPartOf\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg\",\"datePublished\":\"2016-12-22T08:20:53+00:00\",\"dateModified\":\"2023-02-16T10:37:31+00:00\",\"author\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/aa180b4d8d933949f15aba97d8d138a5\"},\"description\":\"Sails is a lightweight framework that sits on top of Express. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg\",\"contentUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg\",\"width\":2000,\"height\":1333,\"caption\":\"Auto Generate REST API using SailsJS\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.botreetechnologies.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Auto Generate REST API using SailsJS\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#website\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/\",\"name\":\"BoTree Technologies\",\"description\":\"Committed to inspire generation.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.botreetechnologies.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/aa180b4d8d933949f15aba97d8d138a5\",\"name\":\"Ankur Vyas\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/ankur-vyas-1-150x150.png\",\"url\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/ankur-vyas-1-150x150.png\",\"contentUrl\":\"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/ankur-vyas-1-150x150.png\",\"caption\":\"Ankur Vyas\"},\"description\":\"Ankur is a Ruby on Rails Developer and Practice Lead JavaScript. He loves Ruby, JavaScript, reading and writing blogs, problem-solving and taking ownership of work. Apart from coding he likes to listen to songs, gaming and traveling.\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Auto Generate REST API using SailsJS","description":"Sails is a lightweight framework that sits on top of Express. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/","og_locale":"en_US","og_type":"article","og_title":"Auto Generate REST API using SailsJS","og_description":"Sails is a lightweight framework that sits on top of Express. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.","og_url":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/","og_site_name":"BoTree Technologies","article_publisher":"https:\/\/www.facebook.com\/BoTreeTechnologies\/","article_published_time":"2016-12-22T08:20:53+00:00","article_modified_time":"2023-02-16T10:37:31+00:00","og_image":[{"width":2000,"height":1333,"url":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg","type":"image\/jpeg"}],"author":"Ankur Vyas","twitter_card":"summary_large_image","twitter_creator":"@BoTreeTech","twitter_site":"@BoTreeTech","twitter_misc":{"Written by":"Ankur Vyas","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#article","isPartOf":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/"},"author":{"name":"Ankur Vyas","@id":"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/aa180b4d8d933949f15aba97d8d138a5"},"headline":"Auto Generate REST API using SailsJS","datePublished":"2016-12-22T08:20:53+00:00","dateModified":"2023-02-16T10:37:31+00:00","mainEntityOfPage":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/"},"wordCount":477,"commentCount":0,"image":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage"},"thumbnailUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg","articleSection":["Ruby on Rails","Technology"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/","url":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/","name":"Auto Generate REST API using SailsJS","isPartOf":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage"},"image":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage"},"thumbnailUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg","datePublished":"2016-12-22T08:20:53+00:00","dateModified":"2023-02-16T10:37:31+00:00","author":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/aa180b4d8d933949f15aba97d8d138a5"},"description":"Sails is a lightweight framework that sits on top of Express. Its ensemble of small modules work together to provide simplicity, maintainability, and structural conventions to NodeJS apps.","breadcrumb":{"@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#primaryimage","url":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg","contentUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2016\/12\/sailsjs.jpeg","width":2000,"height":1333,"caption":"Auto Generate REST API using SailsJS"},{"@type":"BreadcrumbList","@id":"https:\/\/www.botreetechnologies.com\/blog\/auto-generate-rest-api-using-sailsjs\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.botreetechnologies.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Auto Generate REST API using SailsJS"}]},{"@type":"WebSite","@id":"https:\/\/www.botreetechnologies.com\/blog\/#website","url":"https:\/\/www.botreetechnologies.com\/blog\/","name":"BoTree Technologies","description":"Committed to inspire generation.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.botreetechnologies.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.botreetechnologies.com\/blog\/#\/schema\/person\/aa180b4d8d933949f15aba97d8d138a5","name":"Ankur Vyas","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/ankur-vyas-1-150x150.png","url":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/ankur-vyas-1-150x150.png","contentUrl":"https:\/\/www.botreetechnologies.com\/blog\/wp-content\/uploads\/2020\/10\/ankur-vyas-1-150x150.png","caption":"Ankur Vyas"},"description":"Ankur is a Ruby on Rails Developer and Practice Lead JavaScript. He loves Ruby, JavaScript, reading and writing blogs, problem-solving and taking ownership of work. Apart from coding he likes to listen to songs, gaming and traveling."}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/3949","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/comments?post=3949"}],"version-history":[{"count":2,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/3949\/revisions"}],"predecessor-version":[{"id":18624,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/3949\/revisions\/18624"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/media\/13929"}],"wp:attachment":[{"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/media?parent=3949"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/categories?post=3949"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.botreetechnologies.com\/blog\/wp-json\/wp\/v2\/tags?post=3949"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}