I am trying to access edx course information into my iOS app. Preferably, I'd like to a user to access the list of courses they are taking.
When I make the GET request, my data reads:
{
detail = "Authentication credentials were not provided.";
}
Here is my code:
import UIKit
import Alamofire
let kEdxResourceURL = "http://mobile3.m.sandbox.edx.org/"
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
Alamofire.request(.GET, kEdxResourceURL + "api/mobile/v0.5/users/wedu/course_enrollments/").responseJSON() {
(_, _, data, _) in
println(data!)
}
}
}