<?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: Jack Histon</title>
    <description>The latest articles on DEV Community by Jack Histon (@jackhiston).</description>
    <link>https://dev.to/jackhiston</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%2F64169%2F91b0a2a2-9203-42fa-b29b-18f68e5a1d74.jpg</url>
      <title>DEV Community: Jack Histon</title>
      <link>https://dev.to/jackhiston</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jackhiston"/>
    <language>en</language>
    <item>
      <title>5 Ways To Interact With Your Flickr Photos Using The Flickr API</title>
      <dc:creator>Jack Histon</dc:creator>
      <pubDate>Fri, 01 Jun 2018 18:27:48 +0000</pubDate>
      <link>https://dev.to/jackhiston/5-ways-to-interact-with-your-flickr-photos-using-the-flickr-api-2lb0</link>
      <guid>https://dev.to/jackhiston/5-ways-to-interact-with-your-flickr-photos-using-the-flickr-api-2lb0</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.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%2Fapdjg8kw9guayxeq8dzm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.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%2Fapdjg8kw9guayxeq8dzm.png" alt="Flickr logo" width="800" height="400"&gt;&lt;/a&gt;&lt;br&gt;
image source - &lt;a href="https://pixabay.com/en/flickr-logo-brand-yahoo-internet-881367/" rel="noopener noreferrer"&gt;https://pixabay.com/en/flickr-logo-brand-yahoo-internet-881367/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A large supply of image data can be useful when it comes to many different software applications. In machine learning, training a program how to recognise an object in an image can be a hard problem to solve without training material. Flickr can become this training material. The Flickr API is a brilliant way to tap into image data.&lt;/p&gt;

&lt;p&gt;To interact with the Flickr API, you will first need an API key. The api key can be generated by following the guide found here: &lt;a href="https://www.flickr.com/services/api/misc.api_keys.html" rel="noopener noreferrer"&gt;https://www.flickr.com/services/api/misc.api_keys.html&lt;/a&gt;. For a bunch of useful resources discussing the Flickr API, see this wiki page: &lt;a href="https://cloudinary.com/visualweb/display/IMMC/Flickr+API" rel="noopener noreferrer"&gt;https://cloudinary.com/visualweb/display/IMMC/Flickr+API&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;In this article, I will describe five ways in which the Flickr API can be beneficial to your software application. To keep things simple, I will use the curl command in my examples.&lt;/p&gt;

&lt;h1&gt;
  
  
  Searching for Photos
&lt;/h1&gt;

&lt;p&gt;The main reason why you would want to interact with Flickr is to find images. Therefore, the most basic way to interact with Flickr API is by searching for photos. An image can be found by curling the follow url:&lt;/p&gt;

&lt;p&gt;curl &lt;a href="https://api.flickr.com/services/rest/?method=flickr.photos.search&amp;amp;api_key=" rel="noopener noreferrer"&gt;https://api.flickr.com/services/rest/?method=flickr.photos.search&amp;amp;api_key=&lt;/a&gt;&amp;amp;text=test&amp;amp;format=rest&lt;/p&gt;

&lt;p&gt;Replacing  with your own api key that you will have created from the introduction in this article.  This will return you a list of photos in xml format that has a title, description, or tag with the value “test” in it. You can then find image data using the photo id in the response. &lt;/p&gt;

&lt;p&gt;There are many filter options to choose from other than just text. To find out more ways to use each endpoint, visit the &lt;a href="https://www.flickr.com/services/api/" rel="noopener noreferrer"&gt;official documentation&lt;/a&gt;.&lt;/p&gt;

&lt;h1&gt;
  
  
  Getting Popular Photos
&lt;/h1&gt;

&lt;p&gt;Another great way to interact with the Flickr API is by popularity of photo. The Flickr API can provide you with image data that is currently trending on their website, out of the box. This can be useful if you have software applications that require users to be kept up to date on certain images, etc.&lt;/p&gt;

&lt;p&gt;curl &lt;a href="https://api.flickr.com/services/rest/?method=flickr.photos.getPopular&amp;amp;api_key=" rel="noopener noreferrer"&gt;https://api.flickr.com/services/rest/?method=flickr.photos.getPopular&amp;amp;api_key=&lt;/a&gt;&amp;amp;format=rest&lt;/p&gt;

&lt;h1&gt;
  
  
  Adding Photo Comments
&lt;/h1&gt;

&lt;p&gt;Sometimes your software application might want to scan the vast volumes of data that Flickr has to offer. On other times, you might want to add or remove content. The next one I thought was interesting because it allows you to add metadata around your photos in the form of comments. Given a photo identifier, you can comment on any photo you want:&lt;/p&gt;

&lt;p&gt;curl &lt;a href="https://api.flickr.com/services/rest/?method=flickr.photos.comments.addComment&amp;amp;api_key=" rel="noopener noreferrer"&gt;https://api.flickr.com/services/rest/?method=flickr.photos.comments.addComment&amp;amp;api_key=&lt;/a&gt;&amp;amp;photo_id=1&amp;amp;comment_text=test+comment&amp;amp;format=rest&lt;/p&gt;

&lt;p&gt;This command will allow us to add a comment of “test comment” on the photo with id of 1. This can be great if your software application has to interact with user photos in real-time.&lt;/p&gt;

&lt;h1&gt;
  
  
  Geo-location Data
&lt;/h1&gt;

&lt;p&gt;Sometimes you need to get access to all of the locations that you have taken photos on Flickr. This can be useful if you want to produce a picture map, where all your photos are juxtaposed onto a map of the earth.&lt;/p&gt;

&lt;p&gt;curl &lt;a href="https://api.flickr.com/services/rest/?method=flickr.photos.getWithGeoData&amp;amp;api_key=" rel="noopener noreferrer"&gt;https://api.flickr.com/services/rest/?method=flickr.photos.getWithGeoData&amp;amp;api_key=&lt;/a&gt;&amp;amp;format=rest&lt;/p&gt;

&lt;h1&gt;
  
  
  Retrieving Gallery Photos
&lt;/h1&gt;

&lt;p&gt;Another way you can interact with your photos on Flickr API is through the use of galleries. A machine learning application could spend time being trained to understand how to categorise images of animals. After it has categorised them, the application can then add each individual photo into galleries. This is an example of how an application can be used to sort images into specific topics. &lt;/p&gt;

&lt;p&gt;To list all the categories created by a user, you can use the following command:&lt;/p&gt;

&lt;p&gt;curl &lt;a href="https://api.flickr.com/services/rest/?method=flickr.galleries.getList&amp;amp;api_key=" rel="noopener noreferrer"&gt;https://api.flickr.com/services/rest/?method=flickr.galleries.getList&amp;amp;api_key=&lt;/a&gt;&amp;amp;user_id=1&amp;amp;format=rest&lt;/p&gt;

&lt;h1&gt;
  
  
  Conclusion
&lt;/h1&gt;

&lt;p&gt;In this article, I have given you five different ways in which you can interact with the Flickr API for manipulating photo data. I hope you now see the versatility in the Flickr API, and what it can be used for to help you in building an application with rich imagery.&lt;/p&gt;

&lt;p&gt;Sources of data are the currency of the internet. Data is what makes Google’s business model work, it is how machine’s can learn. Using something like the Flickr API can open your application up to a world of knowledge that can help your application be sophisticated and user-friendly.&lt;/p&gt;

</description>
      <category>flicr</category>
      <category>api</category>
    </item>
    <item>
      <title>JavaScript Error Reporting Best Practices</title>
      <dc:creator>Jack Histon</dc:creator>
      <pubDate>Sun, 25 Mar 2018 16:20:27 +0000</pubDate>
      <link>https://dev.to/jackhiston/javascript-error-reporting-best-practices-20mi</link>
      <guid>https://dev.to/jackhiston/javascript-error-reporting-best-practices-20mi</guid>
      <description>&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F93p01zkqtra52lj255mi.jpg" 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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F93p01zkqtra52lj255mi.jpg" alt="JavaScript Logo"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Introduction
&lt;/h1&gt;

&lt;p&gt;Any application written in a modern day programming language will be prone to software errors. When an application is written in JavaScript, there is a chance of unexpected behaviour through human error. A developer is not perfect. He will at times make mistakes that can lead to bugs. When a system has an error, you need some way of recording what happened. To achieve this takes purposeful work towards logging and reporting bugs that arise within your application. &lt;/p&gt;

&lt;p&gt;When code executes on a client-side browser, it is difficult to collate and report errors on their machine. If you have code that is client-side, then how do we collect remote client information onto an internal system? How do we organise such information? And how do we yield significant results without being overwhelmed by false-positives?&lt;/p&gt;

&lt;p&gt;Within this article, I will provide you with the best practices to achieve an error reporting system that helps you figure these questions out. I will provide the best practices that can help you with your JavaScript error reporting.&lt;/p&gt;

&lt;h1&gt;
  
  
  Log Errors to The Server
&lt;/h1&gt;

&lt;p&gt;I may have hinted in my introduction that the key to JavaScript error reporting is to be able to retrieve that data from a client’s browser, and store it within an internal server of our own. Tools that can help you retrieve this information are software such as &lt;a href="https://sentry.io/welcome/" rel="noopener noreferrer"&gt;Sentry&lt;/a&gt;, &lt;a href="https://www.bugsnag.com/platforms/javascript/" rel="noopener noreferrer"&gt;Bugsnag&lt;/a&gt;, and &lt;a href="https://trackjs.com/" rel="noopener noreferrer"&gt;TrackJS&lt;/a&gt;. This article will not go into how to use these tools, but they are the bread and butter in being able to deal with client-side errors, without rolling your own solution.&lt;/p&gt;

&lt;p&gt;The most important thing when it comes to JavaScript error reporting is to be able to log all your errors into a central server that you control. This will allow you to take further action on such data, enabling you to report and learn from it.&lt;/p&gt;

&lt;h1&gt;
  
  
  Signal Vs. Noise
&lt;/h1&gt;

&lt;p&gt;When using error reporting tools, it is important to calibrate them correctly. You must consider the level at which you want to log, either debug, informational, or error levels. If you decide to log at debug level, then this will give you the most amount of information that can be understood about a JavaScript application. It sounds like a great idea to have more information because wouldn’t that mean you can make a more informed decision on what are problem areas? and what your focus should be for the next feature iteration?&lt;/p&gt;

&lt;p&gt;The problem with fine-tuning your logging to debug level, is that you can suffer from information overload. It becomes harder to see the wood through the trees, that is, you have no idea what the true problems your clients are facing from a day-to-day basis when working with your application. If you reduce the amount of noise received from client browsers, then it will allow you to diagnose real errors swiftly.&lt;/p&gt;

&lt;h1&gt;
  
  
  Use Contextual Data
&lt;/h1&gt;

&lt;p&gt;When logging errors from a client’s browser, or from JavaScript running server-side, you need to understand the context in which an error occurs. What was the current CPU usage? Was the box running out of memory? Was there a high network latency?&lt;/p&gt;

&lt;p&gt;These are the basic questions you should ask yourself when an initial diagnosis is performed. If an error is reported without a stack trace or environmental data, then it becomes harder to understand how to reproduce the error and fix it. There can also be specific metrics like what does the current memory heap look like? What are the current values of the variables in the current context in code? &lt;/p&gt;

&lt;p&gt;All these questions matter when trying to understand how to fix bugs, and not fix the wrong problem.&lt;/p&gt;

&lt;h1&gt;
  
  
  Source Maps For Error Tracking
&lt;/h1&gt;

&lt;p&gt;JavaScript looks completely different when working locally in a development environment, and when the code runs in production. If JavaScript is deployed into a production scenario, then minifying and bundling are steps followed to improve application performance by reducing the JavaScript code footprint. Unfortunately, these processes uglify the JavaScript, which means that the code is no longer human-readable.&lt;/p&gt;

&lt;p&gt;If you want to collect data around resources available or save the current code version that was ran on the deployed environment, then you will have to make this code human-readable. This is where &lt;a href="https://blog.rapid7.com/2017/05/24/what-are-javascript-source-maps/" rel="noopener noreferrer"&gt;source maps&lt;/a&gt; are useful. A source map can convert the uglified JavaScript into human-readable JavaScript; a very important step when understanding the context of an error.&lt;/p&gt;

&lt;h1&gt;
  
  
  Conclusion
&lt;/h1&gt;

&lt;p&gt;Client-side browsers are somewhat of a black box. It can be hard to understand how a user interacts with your application, and how you can improve your application to make it easier for them. The introduction of JavaScript error reporting into your application can work wonders in narrowing this knowledge gap. Why rely on users manually reporting bugs, when you can automate the process?&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>errorreporting</category>
    </item>
    <item>
      <title>5 Useful APIs You Should Know About</title>
      <dc:creator>Jack Histon</dc:creator>
      <pubDate>Sun, 25 Mar 2018 15:54:46 +0000</pubDate>
      <link>https://dev.to/jackhiston/5-useful-apis-you-should-know-about-583f</link>
      <guid>https://dev.to/jackhiston/5-useful-apis-you-should-know-about-583f</guid>
      <description>&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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fuq9r00t221lssl4s54dg.jpg" 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%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fuq9r00t221lssl4s54dg.jpg" alt="NASA Logo"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;When it comes to software development at scale, there are always APIs that support your application. Recipe applications, image recognition software, lexical analysis systems, mobile applications, and more, all need APIs that allow them to interact with the world around them. The data that APIs provide, as well as ubiquitous access through mediums such as the internet, make them invaluable towards kick-starting your applications.&lt;/p&gt;

&lt;p&gt;Within this article, I will explore five software APIs that I find to be fun, interesting, but above all useful in a variety of software applications. I have tried to choose APIs that differ in use cases to provide an understanding of the diversity APIs provide. I will show APIs that provide samples of domain data, perform computation on a set of inputs, and even APIs that perform image recognition to provide situational metadata.&lt;/p&gt;

&lt;h1&gt;
  
  
  Intellexer API
&lt;/h1&gt;

&lt;p&gt;Natural language processing is one of the key features that a lot of software applications utilise today. Since the advent of the internet, there has been an explosion in the amount of information available to software. Analysis of this information is hard, and to understand the key components and the semantics of the information is a software project in itself.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://www.intellexer.com/intellexer_api.html" rel="noopener noreferrer"&gt;Intellexer API&lt;/a&gt; allows us to analyse, summarise, and spell check. When working with textual information, it can be a valuable asset. Building your own natural language processor is hard. Having a pre-built API will save you months of man-hours.&lt;/p&gt;

&lt;h1&gt;
  
  
  Google Contacts API
&lt;/h1&gt;

&lt;p&gt;Social networks have taken over the world. The likes of Facebook and Twitter have become the staple diet of a lot of social media addicts. One key aspect they try and tailor into their platforms, is the integration with 3rd party data to increase their outreach.&lt;/p&gt;

&lt;p&gt;One key aspect of this is the recommendation to add your own contacts to the platform. contact APIs such as &lt;a href="https://developers.google.com/google-apps/contacts/v3/" rel="noopener noreferrer"&gt;Google Contacts API&lt;/a&gt;, and Contact APIs in general, such as the one by &lt;a href="https://www.lusha.co/api" rel="noopener noreferrer"&gt;Lusha&lt;/a&gt;, come with a defined way to interact with sensitive data.&lt;/p&gt;

&lt;p&gt;You can use this data to augment data that can allow you to streamline user experiences, keep information up to date, and to create a more personal feel to your applications. Lusha can allow you to enrich your contact data, giving you more contextual information that can be useful in domains such as sales. Lusha removes the need for you to scrape your own data together for businesses that are accessible through the internet.&lt;/p&gt;

&lt;h1&gt;
  
  
  Face++
&lt;/h1&gt;

&lt;p&gt;There are APIs out there that are not only for information retrieval, but also for processing data that can provide further metadata. Image recognition software is a hot topic within the software industry. Technology such as smile recognition, and the famous SnapChat mobile application, utilise the ability to analyse captured images in real-time.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://www.faceplusplus.com/" rel="noopener noreferrer"&gt;Face++ API&lt;/a&gt; provides this technology out of the box. Face++ allows you to analyse images of faces to let you perform actions such as face similarity, 3D facial animation, and even recognise age and ethnicity.&lt;/p&gt;

&lt;h1&gt;
  
  
  Food API
&lt;/h1&gt;

&lt;p&gt;The cooking industry is gigantic. Due to everyone having the necessity to prepare food, it comes at no surprise that cooking applications have taken off like a storm. However, for an application about cooking to be useful, there needs to be a variety of food and recipes to draw from.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://spoonacular.com/food-api" rel="noopener noreferrer"&gt;Spoonacular Food API&lt;/a&gt; allows you to search for food, recipes, and ingredients. All you need to create an application all about cooking in the kitchen.&lt;/p&gt;

&lt;h1&gt;
  
  
  NASA API
&lt;/h1&gt;

&lt;p&gt;As we have discussed, there are APIs that provide input processing, metadata, image manipulation, and even a catalogue to use. There are also APIs that have been developed that are primarily for the spread of information; The NASA API is one such API.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://api.nasa.gov/" rel="noopener noreferrer"&gt;NASA API&lt;/a&gt; allows you to download imagery and data about a variety of topics. From aerospace, earth science, and data results from experiments conducted by NASA. With this data you can develop applications that can further your development with such things as data mining, or use it within data fusion to provide further accuracy within your own scientific applications.&lt;/p&gt;

&lt;h1&gt;
  
  
  Conclusion
&lt;/h1&gt;

&lt;p&gt;The goal of this article was to open your mind to the many possible APIs that are out there which can facilitate your application. When it comes to developing software, you should err on the side of implementing the least amount of code possible. &lt;/p&gt;

&lt;p&gt;Try and use 3rd party APIs that have already been thoroughly tested, and which have thousands of dedicated man-hours. This will ensure that you achieve feature completion quicker, without needing an initial phase to get your application providing value. Can you think of an API that will help you with development of your software application?&lt;/p&gt;

</description>
      <category>api</category>
      <category>lusha</category>
      <category>softwaredevelopment</category>
    </item>
  </channel>
</rss>
