In my last blog, I went into how you can seed your database from an external API. This is great for grabbing information from a source other than your own backend and is a pretty essential tool for building a lot of projects. However, what happens once you’ve pushed your new project onto Heroku? What if the information you seeded is constantly updating (stocks, weekly sales, etc)? Do you plan on resetting your database every single day so your site information stays current? I mean, sure you could, but in the grand scheme of things this is going to spell…

That’s it, that’s the blog.

Seeding is an ever-important task when you’re building out a backend in any language. Since my primary backend language is Ruby, and because Rails is just plain awesome, I want to detail the above picture a bit more and show you how you can seed your database with information from an external api with Ruby on Rails.

What you’ll need:


1. ‘rest-client’ — Our http/rest client gem for accessing the url for our external api via get request.

2. ‘dotenv-rails’ — Our gem that will help us hide our api key.

Don’t forget to do a fresh bundle install after adding these to…

Filters! They’re awesome! The practical uses of filters can be seen everywhere from a nice pour over coffee from your favorite cafe to the spam filter in your email. Filters also have their place in the world of audio engineering.

“I have filters on internets” — Former President George W. Bush

In my last blog, we went over the basics of the Web Audio API. We explored how audioContext() is essential to creating a sound. Then we connected our context to an oscillator and then to the sounds destination (our speakers). Now that we know that we have a sound…

Ever since I started to code I’ve wanted to learn about the browser’s Web Audio API. My long term goal is to create a full synthesizer with it, so give me a follow if you want to watch me on that journey.

I remember during my last few weeks at Flatiron School I was experimenting a bit with the Web Audio API and was able to create a sound in the browser. I want to show you how simple something like this can be.

The Web Audio API

According to MDN, the Web Audio API provides a powerful and versatile system for controlling audio…

I’ve been writing a whole lot of Ruby articles recently off the effort I made on a recent take home code challenge. Though I still have a lot of plans for my Ruby/Rails/Backend journey, I wanted to hop back where I left off picking away at Wes Bos’ JavaScript30. The exercise in week 17 of this course was a perfect way to get back into practicing some routine JavaScript.

In this exercise, we have a list of band names and as most are aware, lots of band names contain either the articles the (The Band), a (A Flock of Seagulls)…

Please stand by for a message from our sponsors.

Have you ever started a project with ‘rails new’ and not wanted to use your default version of ruby?

Moreover, you might have already begun work on a project to later find you need to change versions.

Now there’s no need to worry about such problems with…RVM! Also known as the Ruby Version Manager.

To Start

Just like little Timmy needs to start his day with a tall glass of milk, you should probably know which version of Ruby is currently your default version.

I’m sure your code will go big and strong…

In my recent article, I went over the differences between two very popular types of testing- Mocha and Jest. This time around I wanted to touch on RSpec, a testing suite for Ruby. Ruby on Rails is also my preferred backend, so I was more than happy to take on the task of learning a bit about RSpec for a recent interview.

My challenge was to create an API with custom endpoints and then build RSpec tests for each one of those endpoints. Lucky for me, my recent dive into the world of testing certainly helped, as the flow of…

“If I am a guilty man, my crime is in daring to believe that there’s a ruby gem for every situation, that the truth will pass in my rspec tests and that no one bug can live forever. I believe it still. Much as you try to bury the gems, the truth is out there.” -Coding Mulder, probably.

The Gem Files. (oooohOOOHooohOOÔÔÔOOO)

The Problem:

You have phone numbers as an attribute for a class, but users are able to input their phone numbers in whatever which way they want. …

When first getting started with programming in Rails, a new dev will learn about how classes are created implicitly with sequential ids. Sequential ids are nice because they’re easy on the eyes and it’s even easier to track stuff down within your json.

Sequential ids do have their drawbacks. Take this endpoint for example:


Following RESTful practices, this URL should bring us to a show page for the user with the id of 3. The largest issue here is how exposed our URI is. If our URLs have exposed URIs, it’s easier for people to access data and that’s…

Are you tired of getting this error in your Rails Applications?

Does not knowing what CORS is got you down?

Well, have a seat over there and let’s take a look at…


And how! Little Timmy.

To get an understanding of why we’re getting this error. It’s important to know what CORS is and what it does for our applications. For starters, CORS stands for Cross Origin Resource Sharing. …

Kevin Gleeson

Software Engineering Graduate from Flatiron School. Former expatriate and music teacher.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store