Resource Collection Objects
Field | Name | Description | Type | Required |
---|---|---|---|---|
Id | id | The Schoology Id of the collection | integer | |
Title | title | The title the collection | string | |
Uid | User Id | The owner of the collection | integer | |
Default Collection | is_default |
|
{0,1,2} | |
Shared Users | shared_users | The number of users this collection is shared with | integer | |
Realm | realm | The realm the collection is in | string | |
Realm ID | realm_id | The realm id of the collection | integer | |
Realm Link | realm_link | A URL to the realm that owns the collection | string |
Resource Collections are containers for Resource Templates.
Operations - collections
list
List a users Collections
Path |
|
Return |
A object containing a list of collection fields |
create
Create a Collection
Path |
|
Content |
An object containing collection fields JSON{ "title": "The title the collection" }XML <body> <title>The title the collection</title> </body> |
Return |
A object containing a list of collection fields JSON{ "id": 5825417, "title": "New Collection", "shared_users": 0, "is_default": 0, "uid": 48289, "links": { "self": "http:\/\/..." } }XML <?xml version="1.0" encoding="utf-8" ?> <result> <id>5825417</id> <title>New Collection</title> <shared_users>0</shared_users> <is_default>0</is_default> <uid>48289</uid> <links> <self>http:\/\/...</self> </links> </result> |
Operations - collections/[collection_id]
list
Get a single Collection
Path |
|
Return |
An object containing collection fields { "id": 5825417, "title": "New Collection", "shared_users": 1, "is_default": 0, "uid": 48289 }XML <?xml version="1.0" encoding="utf-8" ?> <result> <id>5825417</id> <title>New Collection</title> <shared_users>1</shared_users> <is_default>0</is_default> <uid>48289</uid> </result> |
edit
Edit a Collection
Path |
|
Content |
An object containing collection fields JSON{ "title": "The updated title" }XML <body> <title>The updated title</title> </body> |
delete
Delete a Collection
Path |
|
Resource Template Objects
Field | Name | Description | Type | Required |
---|---|---|---|---|
Id | id | The Schoology Id of the template | integer | |
Title | title | The title the template. Note that documents do not require a title. | string | true |
Uid | User Id | The creator of the template | integer | |
Resource Notes | resource_notes | Resource notes that can be attached to the actual template | string | |
Folder Id | folder_id | The resource folder this item is in. | integer | |
Collection Id | collection_id | The Collection this item is contained in | integer | |
Template type | type | The type of template this template item is. Note that we only support assignment, discussion, page, and document creation currently. | {assessment, assignment, discussion, page, album, document, folder} | true |
Template Fields | template_fields | Fields specific to this template type. | object |
Operations - collections/[collection_id]/resources
Operations - [realm]/[realm_id]/resources
list
List a collection's resources. Note: Realm resource collections are only available for groups and schools
Path |
|
Return |
An object containing the parent collection in the 'parent' attribute and a list of resource templates for the requested folder in the 'resources' attribute |
Notes | Pass an optional Pass an optional { "resources": [ { "id": 5825423, "title": "YouTube", "type": "document", "resource_notes": "", "collection_id": 5825417, "uid": 48289, "last_updated": 1389717511, "created": 1389717511, "template_fields": { "document_type": "link" }, "folder_id": 0 } ], "total": 1, "links": { "self": "http:\/\/...?start=0&limit=20" } }XML <?xml version="1.0" encoding="utf-8" ?> <result> <resources> <id>5825423</id> <title>YouTube</title> <type>document</type> <resource_notes /> <collection_id>5825417</collection_id> <uid>48289</uid> <last_updated>1389717511</last_updated> <created>1389717511</created> <template_fields> <document_type>link</document_type> </template_fields> <folder_id>0</folder_id> </resources> <total>1</total> <links> <self>http:\/\/...?start=0&limit=20</self> </links> </result> |
create
Create a Template in the specified collection. Note: Realm resource collections are only available for groups and schools
Path |
|
Content |
An object containing template fields An example document template post might be: JSON{ "title": "A handy search engine", "type": "document", "resource_notes": "a few notes", "attachments": [ { "url": "www.google.com" } ] }XML <body> <title>A handy search engine</title> <type>document</type> <resource_notes>a few notes</resource_notes> <attachments> <url>www.google.com</url> </attachments> </body> |
Return |
An object containing template fields |
Resource Type Specific Fields
Template Fields : Page
Field | Name | Description | Type | Required |
---|---|---|---|---|
Body | body | The content of the resource Page | string | |
Template Fields : Discussion
Field | Name | Description | Type | Required |
---|---|---|---|---|
Body | body | The description of the discussion | string | |
Template Fields : assignment
Field | Name | Description | Type | Required |
---|---|---|---|---|
Body | body | The description of the assignment | string | |
Max Points | max_points | The max number of points for this assignment | integer | |
Template Fields : assessment
Field | Name | Description | Type | Required |
---|---|---|---|---|
Body | body | The description of the assignment | string | |
Max Points | max_points | The max number of points for this assignment | integer | |
Template Fields : Document
Note to create a document you need to send in an attachment with it like you do for any other content type that supports attachments. See here.
Field | Name | Description | Type | Required |
---|---|---|---|---|
Document Type | document_type | The type of content attached to this item {file,link,video,embed} | string | |