<?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>DEV Community: Suyash Joshi</title>
    <description>The latest articles on DEV Community by Suyash Joshi (@suyashjoshi).</description>
    <link>https://dev.to/suyashjoshi</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%2F873516%2F08de9107-e5e4-4783-9b3a-55b9de73372e.png</url>
      <title>DEV Community: Suyash Joshi</title>
      <link>https://dev.to/suyashjoshi</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/suyashjoshi"/>
    <language>en</language>
    <item>
      <title>5 ways that will help you become an Open Source Influencer and a Community Rockstar!</title>
      <dc:creator>Suyash Joshi</dc:creator>
      <pubDate>Thu, 30 Jun 2022 01:46:54 +0000</pubDate>
      <link>https://dev.to/suyashjoshi/5-ways-that-will-help-you-become-an-open-source-influencer-and-a-community-rockstar-1e49</link>
      <guid>https://dev.to/suyashjoshi/5-ways-that-will-help-you-become-an-open-source-influencer-and-a-community-rockstar-1e49</guid>
      <description>&lt;h4&gt;
  
  
  Have you ever wanted to become an influencer as an open-source developer?
&lt;/h4&gt;

&lt;p&gt;If yes, I invite you to follow the some of proven strategies listed below that will enable you to not only making a difference in the 'open source ecosystem' but also get recognized as an influencer while doing so!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--jG2yusI6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9eyrgq3ifmbup4wo6zki.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--jG2yusI6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9eyrgq3ifmbup4wo6zki.png" alt="Influencer decorative graphic" width="880" height="880"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Solve Problems others have
&lt;/h3&gt;

&lt;p&gt;In software development, we run into problems all the time and the first thing most people do is to search for them online. Consider sharing your knowledge with others by posting questions and answers on any of the following websites. These websites allow the individual with the best 'question' or 'answer' to earn points which oftentimes leads to recognition/rewards as well.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;StackExchange sites e.g &lt;a href="https://stackoverflow.com"&gt;StackOverflow&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.quora.com"&gt;Quora&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Community Developer Forums such as &lt;a href="https://developers.ringcentral.com/gamechangers"&gt;RingCentral's Game Changer program&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Educate to make Complex Simple
&lt;/h3&gt;

&lt;p&gt;There is a great demand for knowledge base articles such as 'how to' tutorials, best practice guides, tip/tricks, and screencast-based tutorials. A lot of such content already exists however often it's not up to date, lacks quality or simplicity. &lt;/p&gt;

&lt;p&gt;New and better ways of explaining technical concepts and ideas are always in demand by developers.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Personal or company blog&lt;/strong&gt; is always the best as it helps you and your company's brand showcase technical thought leadership.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Popular Tech Blogs&lt;/strong&gt; (&lt;a href="https://dev.to"&gt;Dev.to&lt;/a&gt;, &lt;a href="https://hackernoon.com"&gt;HackerNoon&lt;/a&gt;, &lt;a href="https://dzone.com"&gt;DZone&lt;/a&gt;, &lt;a href="https://www.smashingmagazine.com"&gt;Smashing Magazine&lt;/a&gt;, &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;, etc) are all looking for educational content.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;a href="https://www.youtube.com"&gt;YouTube&lt;/a&gt;, &lt;a href="https://www.twitch.tv"&gt;Twitch&lt;/a&gt;&lt;/strong&gt;: Live streaming with audience engagement or creating a series of short how-to videos make for great content that can be easily consumed on video platforms is a great way to share knowledge specially if you are not shy to showcase your personality on camera.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Organizer / Give Talks, Workshops&lt;/strong&gt;: Meetups, Conferences both virtual and in-person are always in need of speakers and often put our call for proposals that anyone with a decent idea can submit.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Books, Academic Journals&lt;/strong&gt;: If you enjoy doing deep research, consider writing books or submitting your work in academic journals such as those published by &lt;a href="https://www.acm.org/publications/authors/submissions"&gt;ACM&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. Contribute back to Open Source
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Open Source Contributions&lt;/strong&gt;: GitHub](&lt;a href="https://github.com"&gt;https://github.com&lt;/a&gt;) is a great place to show your open source projects, give back to your favorite projects and be recognized while doing so. Most projects can benefit at minimum by a nice README document which is up-to-date information on how to use it/build it, etc. No change is too small for a maintainer so consider sending pull requests to thank the contributors.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Author a library or tool&lt;/strong&gt; : If you enjoy writing code then consider packaging and releasing your code as a library or tool that can make a certain task easier for developers. You can publish them for your favorite language in places, Here are instructions for &lt;a href="https://docs.npmjs.com/packages-and-modules"&gt;npm&lt;/a&gt; and &lt;a href="https://medium.com/ringcentral-developers/publish-an-open-source-library-to-mavencentral-4c104652da8d"&gt;maven central&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  4. Be Passionate &amp;amp; Creative
&lt;/h3&gt;

&lt;p&gt;Don't be shy to share your authentic self. Being authentic is the best way to gain trust with your audience which means disclosing your biases, communicating passionately, etc.&lt;/p&gt;

&lt;p&gt;Developers often need to be inspired by technology, especially if it's "novel" or "complicated". Consider explain complicated topics it in creative ways such as demo videos, through-provoking tweets, infographics/doodles, comics, or even magic tricks. Social Media sites like Twitter, LinkedIn, and websites like Reddit and Hacker News are excellent places to share.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Mentor others
&lt;/h3&gt;

&lt;p&gt;One common myth around mentorships is that one has to be the  'the expert' to mentor, this is not true, you just need to care about others and know little bit more than the mentee to guide them down the right path. If you get an opportunity to mentor/teach in person that is also a great way to share knowledge, especially with new developers, and show them the rope and best practices. &lt;/p&gt;

&lt;p&gt;Finally remember to bring a great attitude to your work such as that of empathy and respect for the developers at large. &lt;/p&gt;

&lt;p&gt;Be persistent to share your knowledge even when you don't receive social media likes/shares as being able to deliver consistently is one sure-shot way of succeeding. Good luck in your journey :)&lt;/p&gt;

</description>
      <category>devrel</category>
      <category>influencer</category>
      <category>opensource</category>
      <category>career</category>
    </item>
    <item>
      <title>How to using JWT based Authentication with RingCentral APIs in a Spring Boot App</title>
      <dc:creator>Suyash Joshi</dc:creator>
      <pubDate>Wed, 22 Jun 2022 22:33:55 +0000</pubDate>
      <link>https://dev.to/suyashjoshi/how-to-using-jwt-based-authentication-with-ringcentral-apis-in-a-spring-boot-app-619</link>
      <guid>https://dev.to/suyashjoshi/how-to-using-jwt-based-authentication-with-ringcentral-apis-in-a-spring-boot-app-619</guid>
      <description>&lt;p&gt;Modern Java enterprise applications such as Spring Boot Java apps connect with multiple services (1st party, 2nd party, and 3rd party) all the time to deliver value to the enterprise users. &lt;/p&gt;

&lt;p&gt;One of the key concerns of an enterprise developer/architect is ensuring the integrity and security of the application and users, especially when they are using 3rd party services via REST APIs &amp;amp; SDKs. &lt;/p&gt;

&lt;p&gt;In this article, we will understand how to connect to RingCentral's open platform and authenticate against the same in a simple SpringBoot application using OAuth 2.0 Client Authentication with JWT Grant Type.&lt;/p&gt;

&lt;h2&gt;
  
  
  OAuth 2.0 JWT Grant Type Overview
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Authentication with JWT&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://datatracker.ietf.org/doc/html/rfc7519" rel="noopener noreferrer"&gt;JWT&lt;/a&gt; stands for JSON Web Token, which is essentially a JSON format that looks like an encoded string and carries secure information. This makes it ideal for performing authentication of users/developers that have signed up to use 3rd party APIs. Therefore, it becomes vital to secure JWT's in a safe place.&lt;/p&gt;

&lt;p&gt;JWT Credentials do not expire by default (however you can set them to time out if needed), they are immutable but can be revoked by the owner and are generally bound to the environment/application for which they're created.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Authorization with OAuth 2.0&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;JWT is often combined with OAuth 2.0, which is a popular protocol over HTTPS to authorize APIs, applications and users with access tokens rather than credentials. &lt;/p&gt;

&lt;p&gt;It is import realize that the JWTs are not used directly to call the API. Instead, a JWT is used in the process of obtaining an access token which is itself then used to call the API. This is why securing JWT token string in a safe place is of vital importance.&lt;/p&gt;

&lt;p&gt;For purpose of understanding these concepts,  I've created a sample SpringBoot application that you can clone from &lt;a href="https://github.com/suyashjoshi/ringcentral-springboot" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;. It incorporates the JWT Auth 2.0 flow using RingCentral's Java SDK. Follow the instructions in the project's README to install the pre-requisites and run the project.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;When should I use a JWT for authentication?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Using a JSON Web Token for app authentication is ideal in the following circumstances:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Backend Logic: There is no user interface through which to facilitate the OAuth auth token flow. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;No Expiration of Tokens: You need a way for users to grant access to their accounts using a credential that doesn't expire.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;No Refreshing of Tokens: You need a way to access an account that doesn't rely on token refreshing.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzdrlcwbj1nbq7driwj52.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzdrlcwbj1nbq7driwj52.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How does JWT work with OAuth 2.0 in SpringBoot App connected to RingCentral Platform?&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;The developer generates a JWT (JSON Web Token) from RingCentral. You can refer to &lt;a href="https://developers.ringcentral.com/guide/authentication/jwt/create-jwt" rel="noopener noreferrer"&gt;this guide&lt;/a&gt; for step-by-step instructions.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The developer provides the JWT Credential programmatically by calling the RingCentral platform - Auth API. Once successfully authenticated and authorized, the API responds with an "Access Token".&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The application then presents the "Access Token" to access resource server APIs, in this case, call various RingCentral Platform APIs for which the application has been granted permissions.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The API calls for performing OAuth via RingCentral platform services can be easily done by using RingCentral's Java SDK that can be downloaded from &lt;a href="https://search.maven.org/artifact/com.ringcentral/ringcentral" rel="noopener noreferrer"&gt;maven central&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The sample &lt;a href="https://github.com/suyashjoshi/ringcentral-springboot" rel="noopener noreferrer"&gt;Spring Boot App&lt;/a&gt; is kept simple so we can focus on two key classes - &lt;code&gt;AuthClient.java&lt;/code&gt; and &lt;code&gt;RingCentralController.java&lt;/code&gt; to see how the OAuth Flow with JWT works.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AuthClient.java&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@Component
public class AuthClient {

  // Credentials should be privately secured separately, in this demo app they are in 'application.properties' file
  private static String RINGCENTRAL_CLIENT_ID;
  private static String RINGCENTRAL_CLIENT_SECRET;
  private static String RINGCENTRAL_JWT;

  // Using RingCentra Sandbox URL, replace with the Production URL for Production Credentials
  private static String RINGCENTRAL_SERVER_URL = "https://platform.devtest.ringcentral.com";

  @Value("${rc.clientid}")
  private void setClientID(String id) {
    RINGCENTRAL_CLIENT_ID = id;
  }
  @Value("${rc.clientsecret}")
  private void setClientSecret(String secret) {
    RINGCENTRAL_CLIENT_SECRET = secret;
  }
  @Value("${rc.jwt}")
  private void setJWT(String jwt) {
    RINGCENTRAL_JWT = jwt;
  }

  public void AuthClient() {
    this.setClientID(RINGCENTRAL_CLIENT_ID);
    this.setClientSecret(RINGCENTRAL_CLIENT_SECRET);
    this.setJWT(RINGCENTRAL_JWT);
  }

  // Connect with RingCentral Platform and return the RestClient object
  public static RestClient authenticate() throws IOException, RestException {
    RestClient rc = new RestClient(RINGCENTRAL_CLIENT_ID, RINGCENTRAL_CLIENT_SECRET, RINGCENTRAL_SERVER_URL);
    rc.authorize(RINGCENTRAL_JWT);
    return rc;
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;RingCentralController.java&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;After having setup up Authentication and Authorization, we call the RingCentral Platform API to read the Account Status of the logged-in user.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@Controller
public class RingCentralController {

  @RequestMapping("/account")
  @ResponseBody
  public String getRCAccountInfo() {
    try {
      RestClient rc = AuthClient.authenticate();
      GetAccountInfoResponse result = rc.restapi().account().get();
      return result.status;
    } 
    catch (IOException | RestException e) {
      e.printStackTrace();
      return("Error Occured!");
    }
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Compile and Run the app &lt;strong&gt;./mvnw spring-boot:run&lt;/strong&gt; and then open your web browser to &lt;strong&gt;localhost:8080/account&lt;/strong&gt; to see the API result 'Confirmed' demonstrating a successful API Call. &lt;/p&gt;

&lt;p&gt;Hope this helped you understand how JWT &amp;amp; OAuth goes hand in hand in a Spring Boot, especially with the help of RingCentral Java SDK which makes it easy to perform authentication, authorization, and calling various platform APIs. &lt;/p&gt;

&lt;p&gt;If you have any questions, please feel free to comment, tweet, or open GitHub issues.&lt;/p&gt;

</description>
      <category>ringcentral</category>
      <category>java</category>
      <category>springboot</category>
      <category>security</category>
    </item>
  </channel>
</rss>
