For Developers
Files Overview
A File is a type of resource that represents a file uploaded to a source system. Files can be associated with Assignments, Announcements, Pages, or Submissions - all via Attachments. Files can also be uploaded directly to a Class or a Module.
Currently, Edlink primarily supports reading existing file attachments. The ability to create or update file attachments via the API may be supported in future releases.
Properties
Property | Type | Description |
---|---|---|
id | string | The UUID for the object. |
created_date | Date | When the object was first seen by Edlink. |
updated_date | Date | When the object was last changed in Edlink. |
type | AttachmentType | The type of the attachment, always file . |
title | string | The title of the file. |
description | string | A description of the file. |
url | string | The URL to the file. |
size | number | The size of the file in bytes. |
thumbnail_url | string | A URL to a thumbnail image of the file. |
share_mode | DriveFileAttachmentShareMode | How the file is shared with students (e.g., view, edit, copy). Only applicable for certain providers like Google Drive. |
JSON Example
{
"id": "00000000-0000-0000-0000-000000000000",
"created_date": "2023-01-01T12:00:00.000Z",
"updated_date": "2023-01-01T12:00:00.000Z",
"type": "file",
"title": "Lesson Plan - Week 1",
"description": "Detailed lesson plan for the first week of classes.",
"url": "https://example.com/files/lesson_plan_week1.pdf",
"size": 102400,
"thumbnail_url": "https://example.com/thumbnails/lesson_plan_week1.png",
"share_mode": "view"
}
File Share Modes
The share_mode
property indicates how the file is shared with students. This property is only revelant for certain providers like Google Classroom, and it can have the following values:
Value | Description |
---|---|
view | Allows students to view the file. |
edit | Allows students to edit the file. |
copy | Makes a copy of the file for each student. |