Pearson
Always Learning

This API returns the binary data of the original file that was uploaded to create an Web Content Upload content item. This is a versatile feature that allows for other types of content, such as a packet of HTML or a PDF file. When a teacher uploads a zip file of HTML content, LearningStudio unzips it and creates a simple HTML version of it for display in the user interface. You can retrieve the data that is displayed in the user interface with the HTML Content API or use this API to get the original zip file.



Supported Roles and Authentication Protocols

Type Supported Values
Authentication Protocols OAuth 2.0
Valid for Roles (OAuth 2): Professor, Teaching Assistant, Student

API Request

API Endpoints

HTTP Verbs and URIs

    GET /courses/{courseId}/webContentUploads/{contentItemId}/originalDocument
  • Retrieves the binary content for a Web Content Upload item.

Parameters

Name Description Valid Values
{courseId} LearningStudio Course ID. Numeric ID issued by LearningStudio. Note this API does not support course overloads.
{contentItemId} ID of the Content Item. Numeric ID issued by LearningStudio

Query String Parameters

No Query String Parameters are supported.

Request Body

None

API Response

Response Header

This API returns the standard HTTP Status Codes used by the LearningStudio APIs. In addition, it also sends a Content-Type HTTP header, which is set to the appropriate MIME type of the original file, for example, application/octet-stream.

Response Body

The response will be binary content. You will need to capture this data and save it or process it as appropriate.

Examples

Request

Endpoint

    GET /courses/123456/webContentUploads/12345678/originalDocument

Response

HTTP Headers (Partial)

    Content-Type: application/octet-stream

Body

        {The content of the the file being served.}
 

2690 reads
Always Learning
Pearson