curl --request POST \
--url http://localhost:5000/api/assignment/submit \
--header 'Content-Type: application/json' \
--data '{
"assignmentId": "64b8f1a2c3d4e5f678905678",
"studentId": "64b8f1a2c3d4e5f678901234",
"fileUrl": "https://storage.example.com/submissions/essay-final.pdf",
"submittedAt": "2026-03-18T14:30:00.000Z"
}'
{
"_id": "64d0b4c8e3f2a1b096785432",
"assignmentId": "64b8f1a2c3d4e5f678905678",
"studentId": "64b8f1a2c3d4e5f678901234",
"fileUrl": "https://storage.example.com/submissions/essay-final.pdf",
"submittedAt": "2026-03-18T14:30:00.000Z",
"__v": 0
}
Submit a student assignment with a file URL and timestamp.
curl --request POST \
--url http://localhost:5000/api/assignment/submit \
--header 'Content-Type: application/json' \
--data '{
"assignmentId": "64b8f1a2c3d4e5f678905678",
"studentId": "64b8f1a2c3d4e5f678901234",
"fileUrl": "https://storage.example.com/submissions/essay-final.pdf",
"submittedAt": "2026-03-18T14:30:00.000Z"
}'
{
"_id": "64d0b4c8e3f2a1b096785432",
"assignmentId": "64b8f1a2c3d4e5f678905678",
"studentId": "64b8f1a2c3d4e5f678901234",
"fileUrl": "https://storage.example.com/submissions/essay-final.pdf",
"submittedAt": "2026-03-18T14:30:00.000Z",
"__v": 0
}
Creates a new assignment submission record. Pass the assignment and student identifiers, a URL pointing to the submitted file, and the submission timestamp.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/praveenarya123/sps-backend/llms.txt
Use this file to discover all available pages before exploring further.
2026-03-18T14:30:00.000Z).submittedAt to the current timestamp by using new Date().toISOString() in JavaScript or datetime.utcnow().isoformat() in Python. This ensures the recorded time accurately reflects when the submission was made.curl --request POST \
--url http://localhost:5000/api/assignment/submit \
--header 'Content-Type: application/json' \
--data '{
"assignmentId": "64b8f1a2c3d4e5f678905678",
"studentId": "64b8f1a2c3d4e5f678901234",
"fileUrl": "https://storage.example.com/submissions/essay-final.pdf",
"submittedAt": "2026-03-18T14:30:00.000Z"
}'
{
"_id": "64d0b4c8e3f2a1b096785432",
"assignmentId": "64b8f1a2c3d4e5f678905678",
"studentId": "64b8f1a2c3d4e5f678901234",
"fileUrl": "https://storage.example.com/submissions/essay-final.pdf",
"submittedAt": "2026-03-18T14:30:00.000Z",
"__v": 0
}