Getting Started with Spotify API with Visual Studio

I have personal project to understand the meaning of music through Azure Cognitive Services. In order to obtain music information, I use Spotify. Spotify is a music subscription services just like Amazon, Pandora, or Apple Music. Spotify has API that can be accessed through our application. On this post, I will overview the Spotify API and how to integrate it on Visual Studio 2019 Development environment. medianet_width = "600"; medianet_height = "250"; medianet_crid = "858385152"; medianet_versionId = "3111299"; Before we begin You should register and create Spotify account and activate your developer account here. You should also install visual studio 2019 here Our Mission On this mission, we will explore the Spotify API and will create skeleton project in Visual Studio. #1 Creating and Application on Spotify You can login to Developer Dashboard on Spotify. If you have trouble login, I suggest you use another browser like Opera, I have login issue with Edge / Internet Explorer. You will create an app to get client ID and Client Secret. After obtaining client ID & Secret, we can continue the look the documentation #2 Understanding the Spotify API features Let's visit the docs pages here. You can see that Spotify has several categories on their API platform. The Web API. Many analytics scenario can be obtained through this API. Playlists, recommended song, history, and many more. It is good API for your music and personalization need. Web Playback. This will developer create music player by using Spotify control. IOS, Android, and Widgets. This API will have specific features for the selected platform. For this article, I will choose the Web API and see the dynamic documentation through console. You can explore the API, through console. It uses JSON for the data format. #3 Creating Spotify Project On this step, I will use class library that will use the Spotify API. You can create any project in Visual Studio. You have two choices to consume Spotify API. The first choice is by using JSON Parser (just like Newton Soft). The second choice is using the API wrapper. We use the second choice on this article Open your NuGet Manager and Search Spotify I use Spotify Net by installing through NuGet #4 Let's Call the API We got some help from Spotify Net. It means we don't need to do REST API call. I create a class library project with SpotifyHelper class. The AccessToken can be obtained from here and click the Get Token. In real project, we will create a login to obtain the token. The codes will list top ten artist based on user. #5 Let's test the API I create the windows forms app. Creating a simple interface and call the class library I get my top ten artist that listened by the user  That's it! You can try by yourself and ping me for any questions. medianet_width = "600"; medianet_height = "250"; medianet_crid = "858385152"; medianet_versionId = "3111299";

Visual Studio 2019 Installation Tips

On this video, we show you how to install the Visual Studio 2019 in elegant and modern way. The five tips show you how to minimize the problem in the installation. Here are the tips Choose the installation package based on your needs (never install the entire package) Always consider to visit the individual package to see your needs Restart your Windows first and make sure the space is sufficient. If you have Visual Studio 2017, install Visual Studio 2019 first to make installation faster by utilizing the existing package. Choose download all then install, rather than download and install here are the Indonesian video.   //

Object Oriented Pillar Demonstration

On this video, we will discuss about the object oriented pillars. it includes polymorphism, inheritance, and encapsulation. This 15 minutes video will tell you the story by creating an application namely CarApp. You can download the codes here You can visit related material here //

Software Testing Tips for Your Software

Building a software is good but testing a software will be great. Today we will discuss what kind of basic testing that you need when you built a software. This article will discuss three fundamental testing that can be done with minimal effort to improve the quality of your software. Unit testing Actor: Developer Unit testing is fundamental test to understand the functionality of the software. The idea of unit testing is to test the method / procedure through a testing framework. Visual Studio 2017 or Visual Studio 2019 helps you through specific features such as: // Unit Test Framework. Visual Studio provides template to create unit test project with MSTest or other compatible framework. It will help you to create skeleton of the unit testing. Live unit test. After you build unit test, you can make visual studio run unit test automatically when codes changed. IntelliTest. IntelliTest help you to create unit test automatically based on several input and output. Although the unit test codes are not created, visual studio provides mechanism to save the tests and reuse later. Please visit further information in Unit Testing Scenario Acceptance Test Actor: Tester, Customer Acceptance test can be used to test the user story or usage scenario of the software. Acceptance test can be helped by the Azure DevOps test plan. You can use test manager to test your software based on usage scenario. You can read further information about Acceptance test through test suite, test plan, and test case. You can learn more at Azure DevOps lab by using Azure Test Performance and Load Test Actor: Tester Staring in Visual Studio 2015, you can do performance and load test by using your local machine or cloud test. You can record your web activity through coded ui test/test recording and then use performance test to simulate the usage of your web application. You can read how to do that here Are you have any other test that you will use to make sure your software great, drop it in a comment   //

Getting started with Microsoft Graph on Windows Form

This tutorial shows you how to create a Windows Form application that use Microsoft Graph. This tutorial is part of digital documentation of Office 365 Global Bootcamp 2018 in Indonesia. You can download the codes here. you can view the quick tutorial here

Understanding Continuous Integration on Visual Studio Online

Some introduction Visual Studio give you cool features namely continuous integration. It is not new feature, however on new roll up of visual studio system they really exposed in the new homepage of your project. Here are some scenario that you want to expect from continuous integration Automatically build your solution when any developer do the checkout and monitor it the result on integrated screen Automatically deploy your codes into the Azure when your codes is built Executing unit test when the codes is build by any of your developers Any many more please visit Getting started Here is the quick video for it. Enjoy

Five Reason to Choose ASP.NET Web Forms

On this short video, we will discuss about a technology overview when choosing ASP.NET web forms. At least there are five reasons why you should choose ASP.NET web forms such as the rapid development environment, drag-and-drop support, and many more. Please view the video!   And how about a consideration why you don't need to use web forms, just visit the comment and let's discuss //

Video: 3 Tips to Get Faster Update for Your Visual Studio

Today we will discuss about how to get faster update on your Visual Studio 2015. These tips save me about two hours

Beginner Tutorial for ASP.NET MVC

As a part, of our commitment to create a local video tutorial on Visual Studio Technology. We created a beginner tutorial for ASP.NET MVC with Visual Studio 2015. There are 8 videos on the plan. You can visit YouTube to join the Visual Studio Indonesia YouTube Page. Or enjoying the video below

Creating Workflow Application with Visual Studio 2013

worToday, we will create a simple workflow application. Workflow Application (simple states as WF app) is an application that use business process model as a foundation to create an application. If common application use the code logic, the workflow application use business process model or flowchart as a basic idea of execution. Although is like a verbose for some app, the idea to integrate between business process and application is a good idea to give out of the box alignment between IT solution with business process. Therefore, many Workflow app is dedicated to solve the enterprise issues like on line of business application, ERP, or SharePoint Collaboration portal. Let’s get started to create the codes. Preparation In order to follow the tutorial, you need Visual Studio 2013 Professional or Higher (We use Ultimate with update 4) Windows 7 or Higher (We use 8.1) Development Steps Create a new project in Visual Studio 2013, with Workflow template We give the project name SimpleWorkflowApp, you will have blank screen called Workflow1.xaml. We will create a simple workflow to validate a PKP need to become PKP or not We rename Workflow1.xaml as SimpleWorkflow.xaml Open the Toolbox and you will see a lot of control over there. We won’t discuss each control. Please refer to References for detail about this. On primitive tabs add Assign control, InvokeMethod, and WriteLine. You will drag and drop like the screen Please note that sequence is created automatically. You see a blue icon on the screen, it means that the WF has an error on it. Let’s fix our Workflow First, we need a variable to store any information that related with workflow. Select Sequence workflow (you will see a blue highlight when you select it). After that click variables, It’s located on the left bottom of the screen. And create a variable called turnoverCapital with type decimal. Assign and changes to statement into turnoverCapital and add codes Convert.ToDecimal(Console.ReadLine()) on enter C# expression On if statement give the condition when the tac payer need to be PKP. On this code,we will add  turnovercapital > 4800000000. After the confition we add two Writeline primitive method on each condition just like on a picture We build the code, and you will see several input ask you some numbers and if more than 4.8 Billion, the codes will said you need to be PKP (Pengusaha Kena Pajak) Download the codes You can download the codes here Workflow References

Topics Highlights

About @ridife

This blog will be dedicated to integrate a knowledge between academic and industry need in the Software Engineering, DevOps, Cloud Computing and Microsoft 365 platform. Enjoy this blog and let's get in touch in any social media.


Month List