<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Utkarsh Singh</title>
    <description>The latest articles on Forem by Utkarsh Singh (@utkarshsingh99).</description>
    <link>https://forem.com/utkarshsingh99</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F419183%2F8f2f77f9-3832-4ec8-894c-567112e9b41c.jpeg</url>
      <title>Forem: Utkarsh Singh</title>
      <link>https://forem.com/utkarshsingh99</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/utkarshsingh99"/>
    <language>en</language>
    <item>
      <title>DrawPI - Building an API in minutes</title>
      <dc:creator>Utkarsh Singh</dc:creator>
      <pubDate>Sun, 05 Jul 2020 22:27:35 +0000</pubDate>
      <link>https://forem.com/utkarshsingh99/drawpi-building-an-api-in-minutes-44a9</link>
      <guid>https://forem.com/utkarshsingh99/drawpi-building-an-api-in-minutes-44a9</guid>
      <description>&lt;p&gt;Build a good design, materialize a great idea, you still need data to play with your product.&lt;br&gt;
Collect as much as data as you want, you still need to send it back to the client in a systematic, secure manner.&lt;br&gt;
What do you call this systematic, secure manner? APIs.&lt;/p&gt;

&lt;p&gt;You are most probably aware of the concepts of an API. You're just wondering how can you build an API in 2 minutes when there are literally 1000+ courses over the internet teaching the intricacies of building it through code that takes hours?!&lt;/p&gt;

&lt;p&gt;Well, the short answer is: you design, we code. All you have to do is Create, Define, Declare.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create a project.&lt;/li&gt;
&lt;li&gt;Define a model (a simple database).&lt;/li&gt;
&lt;li&gt;Declare your endpoints.
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--WJfhZbGs--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/53qtlbz4ydhaiadi47jm.png" alt="Alt Text"&gt;
Have a look at the Create page here. This single screen outscores the manual process of code writing for APIs.  The right pane focuses on building each endpoint, while the left defines the properties for the entire API. Let's look at each component of the page in detail. &lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Creating a Project
&lt;/h3&gt;

&lt;p&gt;A Project is equivalent to an API. When you create a project:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;A domain for the API in the form of &amp;lt;your-username&amp;gt;-&amp;lt;projectname&amp;gt;.drawpi.com is created. This means your API is now hosted before you even began writing code or declared an endpoint.&lt;/li&gt;
&lt;li&gt;A database for the project is created.&lt;/li&gt;
&lt;li&gt;A project folder at DrawPI servers is created to add the automatically generated code as you design endpoints.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Creating a Collection
&lt;/h3&gt;

&lt;p&gt;Collections modularize your API. Nothing affects the functionality of your API through this. This is just to assort endpoints into certain categories so they become easy to manage at the back-end, and easy to understand while developing the front-end.&lt;/p&gt;

&lt;h3&gt;
  
  
  Building a Model
&lt;/h3&gt;

&lt;p&gt;Models is an informal term for your Database. At present, DrawPI supports only MySQL databases, so you can only define an SQL schema. (We are expanding and soon will be back with an option to choose MongoDB too, hence the name Models).&lt;br&gt;
When you create a model, it is basically a table in your projects database. You can define all attributes for your model here.&lt;br&gt;
Isn't it high time the world found a way to build databases without going into the dark terminal or a .sql file?&lt;/p&gt;

&lt;h3&gt;
  
  
  Creating an Endpoint
&lt;/h3&gt;

&lt;p&gt;Here's the most amazing part. Creation of an endpoint. Now, a disclaimer first. Designing your endpoint may not enable you to design extremely complex enterprise-level APIs, but if you are smart enough, you can use the Condition Block to build endpoints that you need for your projects.&lt;br&gt;
So let's first try to understand what happens in the code of an endpoint. &lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--M6OoHPhZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/4ygdfbz2zm4mfpav2d6n.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--M6OoHPhZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/4ygdfbz2zm4mfpav2d6n.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;We define an endpoint.&lt;/li&gt;
&lt;li&gt;Some data is sent along with the request by the client.&lt;/li&gt;
&lt;li&gt;We perform some manipulations in the database, or perform a query.&lt;/li&gt;
&lt;li&gt;Return a relevant data item or part of it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is the natural basic flow of an API for most projects.&lt;br&gt;
The data that endpoints require is used from the data attached with the request object coming in. &lt;strong&gt;req.body, req.params, req.query&lt;/strong&gt;, you might have heard of these objects if you are a back-end developer, which are used as payload in POST requests, &lt;strong&gt;/, /endpoint?key=&lt;/strong&gt; respectively.&lt;br&gt;
We need to expect this data in our endpoint code first. That's what we do in the Query and Request Block.&lt;/p&gt;

&lt;p&gt;Next up, is the Condition Block. This defines what you shall do with the data. Basically, the code to run after an endpoint request is made by a client is generated based on the structure of the operations in this block. Using this block requires a separate blog post of itself, but let me tell you the basic operations here.&lt;br&gt;
DrawPI currently supports CRUD operations. This means, you can use the Condition Block to perform any Create, Read, Update, or Delete Operations in your database.&lt;br&gt;
All this can be done just by choosing the operation, and choosing the data which needs to be updated.&lt;br&gt;
This is all you do to build an endpoint, the platform writes the code, and deploys it as soon as you click on 'Launch Endpoint', everything within seconds.&lt;/p&gt;

&lt;p&gt;Given this process of building an API, how long do you think it would take you to build yours?&lt;br&gt;
2 minutes? 5 minutes? 15 minutes? We don't expect you to spend more time than that on our Create Page anyway.&lt;/p&gt;

&lt;p&gt;And that, is how you can build your API in just under 2 minutes!&lt;br&gt;
Head over to drawpi.com to witness the revolution.&lt;/p&gt;

&lt;h3&gt;
  
  
  Who is DrawPI for?
&lt;/h3&gt;

&lt;p&gt;Even though DrawPI is a project that could revolutionize back-end development, it is still in development. This means, you could benefit by making APIs if:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your project is a simple one with a few DB tables and endpoints.&lt;/li&gt;
&lt;li&gt;You are a front-end developer who wants to see their Android/iOS/Web App project with something more functional than dummy data.&lt;/li&gt;
&lt;li&gt;You want to build a complex back-end, BUT wished that the plain basic setup code and trivial endpoints could write themselves.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I want to stress on the 3rd customer a little here. DrawPI could be used as a customized boilerplate for any bigger project which is too complex for this platform.&lt;br&gt;
Let's say, I need to build a complex Library System that uses heavy security add-ons like authorization headers, session tokens and cookies - features not currently supported by DrawPI. I will need to write code manually for these.&lt;br&gt;
But, I could build models and define basic endpoints like getting info about a student, about a specific book, querying books in a specific category, etc. using DrawPI tools, and export the code to build on manually. Just imagine how much time a back-end developer saves by simply getting the setup done and trivial endpoints built. &lt;/p&gt;

</description>
      <category>devops</category>
      <category>api</category>
      <category>javascript</category>
      <category>node</category>
    </item>
    <item>
      <title>Meet Jarvis Workspace Manager</title>
      <dc:creator>Utkarsh Singh</dc:creator>
      <pubDate>Tue, 30 Jun 2020 12:49:06 +0000</pubDate>
      <link>https://forem.com/utkarshsingh99/meet-jarvis-workspace-manager-5ag4</link>
      <guid>https://forem.com/utkarshsingh99/meet-jarvis-workspace-manager-5ag4</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--INrRkDau--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/lst398v5p577m9xi86y7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--INrRkDau--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/lst398v5p577m9xi86y7.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
Are you the kind of person who inevitably has to work on multiple tabs due to the complexity of your work?&lt;br&gt;
We have all been there. You are researching about something, or building something, or doing any other task on your browser, and you end up opening at least 4 tabs if the task is simple, 10/12 tabs if the task is tough, or sometimes tabs you're too afraid to even count!&lt;br&gt;
You know what opening so many tabs creates?&lt;br&gt;
&lt;strong&gt;Chaos&lt;/strong&gt;.&lt;br&gt;
Yes, after a certain point, you don't even remember exactly on which tab is the information you looked at recently. You know everything that's going to help you is right in front of you, but you don't know where exactly.&lt;br&gt;
And if a time comes when you have to disconnect from the work in progress, and maybe call the day or start working on some other thing, you are too much afraid to close these tabs.&lt;br&gt;
Eventually, you start doing all the tasks on the same window, and mixing everything, or you open a new window and never really close anything.&lt;br&gt;
One of these things is bad for your productivity while the other is bad for your memory.&lt;br&gt;
A solution to get rid of this problem is saving Browser Workspaces.&lt;/p&gt;

&lt;p&gt;There are many browser extensions, both in Chrome and Firefox that allow you to save a group of tabs as 'Workspaces'.&lt;/p&gt;

&lt;p&gt;If you're a Chrome user, I suggest you use the following extension:&lt;br&gt;
&lt;a href="https://chrome.google.com/webstore/detail/workspace-launcher/nenchifcjkmfahicbjgpinmklenpfiih"&gt;Workspace Launcher&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;During my time as a Chrome user, this extension really helped me to remain organized while doing multiple tasks.&lt;br&gt;
Then I moved to Firefox, and (I guess) due to my poor searching skills, I couldn't find this kind of extension for Firefox. This gave me an opportunity to build my own extension! I could customize how it looked and overcome all the shortcomings I felt as a user in the Chrome extension that I used!&lt;br&gt;
A week of learning and coding, and I was ready with my own Jarvis Workspace Manager!&lt;/p&gt;

&lt;h3&gt;
  
  
  The Jarvis-like Interface
&lt;/h3&gt;

&lt;p&gt;Now, if you have read my previous blogs, you might know that I'm a huge fan of Iron Man.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--98HX9RKp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/km0mcarbu2hfv3kg105d.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--98HX9RKp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/km0mcarbu2hfv3kg105d.gif" alt="Yeah, that's my home screen"&gt;&lt;/a&gt;&lt;br&gt;
Yeah, that's my home screen&lt;br&gt;
By the way, here's how to do this to your PC if you're wondering: &lt;a href="https://www.thegoodindian.in/2020/03/how-to-turn-ubuntu-into-jarvis.html"&gt;Jarvis, we love you 3000&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Anyway, so it was only fitting that I come up with an extension which makes it look like a JARVIS Interface is managing my Workspaces too!&lt;br&gt;
So what do I need to achieve this? If I'm omitting the AI-enabled voice of JARVIS, then simply, a dark interface with a bluish green hue for the text and elements.&lt;br&gt;
So that's what I did.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--nLCcx6K4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/hfanv1kuun2x81gnie44.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--nLCcx6K4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/hfanv1kuun2x81gnie44.png" alt="My current Workspaces in Firefox"&gt;&lt;/a&gt;&lt;br&gt;
My current Workspaces in Firefox&lt;br&gt;
So this is how it looks. Feel free to stalk your way in to what I do with my life. It'll also give you a better idea to know what kind of tab groups you should save as Workspaces.&lt;/p&gt;

&lt;h3&gt;
  
  
  Save tabs with just one click
&lt;/h3&gt;

&lt;p&gt;In the Chrome extension that I used before, I had to manually enter all URLs that I wanted to be saved as a Workspace. That was a real pain if I had more than 5 tabs open!&lt;br&gt;
So I made an enhancement:&lt;br&gt;
&lt;strong&gt;All your open tabs are saved as one Workspace and you can carry on with your work seamlessly by one single click on the Extension icon!&lt;/strong&gt;.&lt;br&gt;
Of course, you can still add all the tabs manually too (the hard way), but I don't use that feature even though I had a good time coding it!&lt;/p&gt;

&lt;h3&gt;
  
  
  Having a map of your best links
&lt;/h3&gt;

&lt;p&gt;If you save Workspaces for all your important tasks, you have an organized list of all your best important links in the new tab page automatically.&lt;br&gt;
It's not necessary to open the entire set of all the tabs every time. Sometimes we just need to go to one of the links. &lt;br&gt;
All such possible links will be right in front of you the whole time. &lt;br&gt;
So you won't be just replacing your Mozilla default startup page with an extension's, it would rather be an improvement over the existing one.&lt;/p&gt;

&lt;h3&gt;
  
  
  Developer Support
&lt;/h3&gt;

&lt;p&gt;Another good reason for its usage is that you know the developer who can solve the bugs for you and bring out new features on your informal request!&lt;br&gt;
&lt;a href="https://github.com/utkarshsingh99/Workspace-Manager"&gt;Github Repo&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;So all the best and I hope you use a Workspace Manager extension to organize your work, because believe it or not, you need it!&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>css</category>
      <category>management</category>
    </item>
  </channel>
</rss>
