PebblePad : API documentation

Course

Provides the methods for interacting with courses held in the Data Island. Each record has a unique Id that is provided by you and should to match those in your own systems.

Methods

Method HTTP request Description
Create POST https://v3.pebblepad.co.uk/api/1.1/di/Course/Create/ Adds a new Course to the Data Island.
Delete DELETE https://v3.pebblepad.co.uk/api/1.1/di/Course/Delete/ Deletes a Course from the Data Island.
Get GET https://v3.pebblepad.co.uk/api/1.1/di/Course/Get/{id} Gets a course from the Data Island.
GetAll GET https://v3.pebblepad.co.uk/api/1.1/di/Course/GetAll/ Gets all courses from the Data Island.
Update POST https://v3.pebblepad.co.uk/api/1.1/di/Course/Update/ Updates a Course in the Data Island.

Methods

Create

Adds a new Course to the Data Island.

Scope Required

admin_courses:c

Request

POST https://v3.pebblepad.co.uk/api/1.1/di/Course/Create/

Example request

POST api/1.1/di/Course/Create HTTP/1.1
Host: https://v3.pebblepad.co.uk/
Authorization: Bearer xxxxxxxxxxxxxxxx
{
  "id":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495",
  "title":"Artistic Design for the Digital Platform",
  "description":"For those with an artistic flare and a passion for innovating digital interface",
  "startdate":"2015-09-08T08:00:00.000Z",
  "enddate":"2016-05-21T21:00:00.000Z",
  "coursecode":"ART-DES-DIG",
  "alternativecode":"DIG-ART-DES",
  "instancecode":"DAD2015-2016",
  "academicyear":"2015/16",
  "studentstatus":"Enrolling",
  "modeofattendance":"Campus",
  "createatlasworkspace":true,
  "coursecategory":"Digital",
  "resourceid":"e4e2272b-5bfc-457b-95e1-77953854fe2a",
  "requirements":"Course requirements"
} 

Response

HTTP / 1.1 200 (OK)
"aa85e6f1-67d4-4892-9102-2ea2e7dd7495" 

Example error response

HTTP/1.1 400 (Bad Request)
{
  "errormessage":"Id for the given Course is already being used",
  "erroritem":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495"
} 

Delete

Deletes a Course from the Data Island.

Scope Required

admin_courses:d

Request

DELETE https://v3.pebblepad.co.uk/api/1.1/di/Course/Delete/

Example request

DELETE api/1.1/di/Course/Delete/aa85e6f1-67d4-4892-9102-2ea2e7dd7495 HTTP/1.1
Host: https://v3.pebblepad.co.uk/
Authorization: Bearer xxxxxxxxxxxxxxxx 

Response

HTTP / 1.1 200 (OK)
"aa85e6f1-67d4-4892-9102-2ea2e7dd7495" 

Example error response

HTTP/1.1 400 (Bad Request)
{
  "errormessage":"No Course was found with the given Id",
  "erroritem":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495"
} 

Get

Gets a course from the Data Island.

Scope Required

admin_courses:r

Request

GET https://v3.pebblepad.co.uk/api/1.1/di/Course/Get/{id}

Parameters

Parameter name Value Required Description
id string Yes Data Island Course Id

Example request

GET api/1.1/di/Course/Get/aa85e6f1-67d4-4892-9102-2ea2e7dd7495 HTTP/1.1
Host: https://v3.pebblepad.co.uk/
Authorization: Bearer xxxxxxxxxxxxxxxx 

Response

HTTP / 1.1 200 (OK)
{
  "id":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495",
  "title":"Artistic Design for the Digital Platform",
  "description":"For those with an artistic flare and a passion for innovating digital interface",
  "startdate":"2015-09-08T08:00:00.000Z",
  "enddate":"2016-05-21T21:00:00.000Z",
  "coursecode":"ART-DES-DIG",
  "alternativecode":"DIG-ART-DES",
  "instancecode":"DAD2015-2016",
  "academicyear":"2015/16",
  "studentstatus":"Enrolling",
  "modeofattendance":"Campus",
  "createatlasworkspace":true,
  "coursecategory":"Digital",
  "resourceid":"e4e2272b-5bfc-457b-95e1-77953854fe2a",
  "workspaceid":"b3249fd1-5bfc-457b-95e1-77953854fe2a",
  "requirements":"Course requirements"
} 

Example error response

HTTP/1.1 400 (Bad Request)
{
  "errormessage":"No Course was found with the given Id",
  "erroritem":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495"
} 

GetAll

Gets all courses from the Data Island.

Scope Required

admin_courses:r

Request

GET https://v3.pebblepad.co.uk/api/1.1/di/Course/GetAll/

Example request

GET api/1.1/di/Course/GetAll HTTP/1.1
Host: https://v3.pebblepad.co.uk/
Authorization: Bearer xxxxxxxxxxxxxxxx 

Response

HTTP / 1.1 200 (OK)
[
  {
    "id":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495",
    "title":"Artistic Design for the Digital Platform",
    "description":"For those with an artistic flare and a passion for innovating digital interface",
    "startdate":"2015-09-08T08:00:00.000Z",
    "enddate":"2016-05-21T21:00:00.000Z",
    "coursecode":"ART-DES-DIG",
    "alternativecode":"DIG-ART-DES",
    "instancecode":"DAD2015-2016",
    "academicyear":"2015/16",
    "studentstatus":"Enrolling",
    "modeofattendance":"Campus",
    "createatlasworkspace":true,
    "coursecategory":"Digital",
    "resourceid":"e4e2272b-5bfc-457b-95e1-77953854fe2a",
    "workspaceid":"b3249fd1-5bfc-457b-95e1-77953854fe2a",
    "requirements":"Course requirements for Course"
  },
  {
    "id":"dc4421e8-c096-447f-ad7a-e420e1bcc837",
    "title":"Designing for the Real World",
    "description":"This is for those who wanting to get into designing real world objects, like new cars, house utilities, and other tangible products of the real world.",
    "startdate":"2015-09-08T08:00:00.000Z",
    "enddate":"2016-05-21T21:00:00.000Z",
    "coursecode":"DES-TANG",
    "alternativecode":"DES-TANG-REAL",
    "instancecode":"DTR2015-2016",
    "academicyear":"2015/16",
    "studentstatus":"Full",
    "modeofattendance":"Campus",
    "createatlasworkspace":true,
    "coursecategory":"Design for Production",
    "resourceid":"f825c8c3-09e2-49f6-8b9b-9b1de38e1444",
    "workspaceid":"b6012bca-5bfc-457b-95e1-77953854fe2a",
    "requirements":"Course requirements"
  }
] 

Example error response

Update

Updates a Course in the Data Island.

Scope Required

admin_courses:u

Request

POST https://v3.pebblepad.co.uk/api/1.1/di/Course/Update/

Example request

POST api/1.1/di/Course/Update/aa85e6f1-67d4-4892-9102-2ea2e7dd7495 HTTP/1.1
Host: https://v3.pebblepad.co.uk/
Authorization: Bearer xxxxxxxxxxxxxxxx
{
  "id":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495",
  "title":"Artistic Design for the Digital Platform",
  "description":"For those with an artistic flare and a passion for innovating digital interface",
  "startdate":"2015-09-08T08:00:00.000Z",
  "enddate":"2016-05-21T21:00:00.000Z",
  "coursecode":"ART-DES-DIG",
  "alternativecode":"DIG-ART-DES",
  "instancecode":"DAD2015-2016",
  "academicyear":"2015/16",
  "studentstatus":"Enrolling",
  "modeofattendance":"Campus",
  "createatlasworkspace":true,
  "coursecategory":"Digital",
  "resourceid":"e4e2272b-5bfc-457b-95e1-77953854fe2a",
  "requirements":"Course requirements"
} 

Response

HTTP / 1.1 200 (OK)
"aa85e6f1-67d4-4892-9102-2ea2e7dd7495" 

Example error response

HTTP/1.1 400 (Bad Request)
{
  "errormessage":"No Course was found with the given Id",
  "erroritem":"aa85e6f1-67d4-4892-9102-2ea2e7dd7495"
}