Repository navigation
Downloads
Phil Graham™ ☕ edited this page Nov 25, 2019
·
11 revisions
Holds records of exports.
It is accessible through the following HTTP interfaces:
-
REST HTTP Interface via
http://www.example.org/api/v2/download.
Get all the Learning Locker® downloads.
LearningLocker::downloads()->get();Get a single Learning Locker® download with a download's $id.
LearningLocker::download($id)->get();Delete a single Learning Locker® download with a download's $id.
LearningLocker::download($id)->delete();Create a single Learning Locker® download with an array of $data.
LearningLocker::download()->create($data);Update a single Learning Locker® download with a download's $id and an array of $data.
LearningLocker::download($id)->update($data);Learning Locker® Downloads Documentation
You can use an array when updating or creating a Learning Locker® Downloads
Download Example
[
"url" => "/api/downloadexport/5915be242c3a240fb40801e4.csv",
"time" => "2017-05-12T13:52:36.995Z",
"organisation" => $org_id,
"name" => "Example Download",
"upload" => [
"createdAt" => "2017-05-12T13:52:37.016Z",
"updatedAt" => "2017-05-12T13:52:37.070Z",
"mime" => "text/csv",
"key" => "downloads/1494597156987.csv",
"repo" => "local"
],
"isReady" => true
]Download Model
{
"_id" : "59c2371c16bc715f83c3450d",
"url" : "/api/downloadexport/5915be242c3a240fb40801e4.csv",
"time" : "2017-05-12T13:52:36.995Z",
"organisation" : "59c2371c16bc715f83c3450e",
"name" : "Example Download",
"upload" : {
"createdAt" : "2017-05-12T13:52:37.016Z",
"updatedAt" : "2017-05-12T13:52:37.070Z",
"mime" : "text/csv",
"key" : "downloads/1494597156987.csv",
"repo" : "local"
},
"isReady" : true
}