Returning papers by HTTPS PUT

Added by Matthew Leingang about 9 years ago

Hello again,

I love the feature that AMC can email graded papers back to the students. But my university's learning management system provides a file exchange system that I prefer to use.

Currently I have a script which uploads each file with a call to `curl -T <file> <URL>`. This makes an HTTPS PUT request. In order to do this automatically via AMC, I was thinking of writing a python or perl script that behaved like `sendmail` but instead of sending the mail, extracted the file and then did the uploading. I'm assuming with the proper libraries this process would be pretty straightforward, though not automatic. There are some extra variables which I assume I could pass to this script in the "sendmail path" preferences field.

Before I embark on this subproject I thought I would ask if this problem has been solved before, or if you have any other advice.


Replies (2)

RE: Returning papers by HTTPS PUT - Added by Alexis Bienvenüe about 9 years ago

What are the requirements for the filename and URL?
You can use AMC to get the right filename, and then PUT all files to the same URL, or to an URL containing the student ID?
Perhaps this is easier to write a script working from the cr/corrections/pdf directory directly, without trying to behave as sendmail?

RE: Returning papers by HTTPS PUT - Added by Matthew Leingang about 9 years ago

Right now I'm using several scripts that work from the cr/corrections/pdf directory, and on the exported CSV file. But now that you mention it seems I could take one step out the workflow by exporting all needed info into the filename and splitting it up.

(1-2/2)