AnsweredAssumed Answered

Is there an API to download contents (not metadata) of a file from a given assignment?

Question asked by DJ Rao on Aug 25, 2015
Latest reply on May 9, 2018 by Gerald Q. Maguire

Hello,

 

I am looking for an API call to download contents (not metadata) of a given file from a given course & assignment. Here is an example of the call that I am trying (I have not included by access_token but I know that I am using the correct token) and I have tried various combinations of it

wget -O - "https://canvas.instructure.com/api/v1/courses/963251/assignments/3853506/submissions/4687618/files/36329176?access_token=..."

I am able to retrieve metadata about the file submitted to my course using the API:

wget -q -O - "https://canvas.instructure.com/api/v1/courses/963251/assignments/3853506/submissions/4687618?access_token=..."

The above call includes some URL to download; but that URL requires 2 re-directions and Javascript (implying a browser?) to download. I would like an API to download the contents of the file submitted to my course directly.

 

Any help to identify the API is greatly appreciated.

Outcomes