Harvard-ATG/HarvardCards — pull request #53 by arthurian (2014-04-29 15:48:50+00:00)
Title: Feature/card deck api

This PR lays the groundwork for calling the backend API from JS and in particular from model objects. Two configuration options are passed to the API object through requirejs's config option:

- **apiRoot**: This is the location of the root endpoint of the API (i.e. /api)
- **apiKey**: This is the key needed to access the API.

Currently we do not have a full API system setup that requires an API key, but I anticipate that we will, and so we should use our own API the way others would. For now, the **apiKey** is ignored, but we can easily modify the API object to include it in all requests. The **apiRoot** is necessary because this path may vary depending on the host configuration (i.e. shared hosting) and versioning (instead of /api, it might be /api/v2 in the future).