API Mashups - Final Push

Getting ready for Finals

For this semester I picked three classes focused on coding. The idea was, that by immersing myself into coding I would finally improve my skills. Unfortunately, after the midterms, I realized that my fast-track to coding was actually surrounding me by failures and frustration for not having good work to show. My reaction was to give up on coding and accept that I'm one of those "visual people", more attuned to shapes and colors than abstract logic. But, because of the classes, I can't quit without hurting my position at ITP and my pride. 

Watching Tutorials x Coding Practice

For two semesters now I've been watching hours and hours of videos on coding, but I haven't actually coded much. I filled two notebooks on coding practices, but I very few programs of my own to show; no even some copy-paste Frankenstein. Today a colleague said "stop watching videos", so I'll change my strategy. I'll still watch videos, but with the strict purpose of solving specific questions. 

The Giphy API exercise

In today's class we had to make something joining P5 with the Giphy API. My team failed to make it work, so I'll try one more time now, this time using the example the teacher provided.

This is the code she provided

/*
fFFGeIaOHgqGY0nOX4MNxqkkoXzbWx2p
api.giphy.com
http://api.giphy.com/v1/gifs/search?q=ryan+gosling&api_key=HERKEYWASHERE
*/

var api = 'http://api.giphy.com/v1/gifs/search';
var apiKey = '&api_key=HERKEYWASHERE;
var query = '?q=architecture';

function setup() {
  //createCanvas(400, 400);
  noCanvas();
  var url = api + query + apiKey;
  loadJSON(url, gotData)
}

function gotData(giphy) {
  for (var i = 0; i < giphy.data.length; i++) {
    createImg(giphy.data[i].images.preview_gif.url);
  }
}

Goal for the Giphy API 

I'll make an interface where the user can move randomly generated Giphy Stickers on the screen.