This repository will server as the backend server for the devdesk queue application
URL: /api/tickets
Returns an array of ticket objects.
Example:
[
{
"ticket_id": 1,
"status": "resolved",
"title": "problem1",
"description": "big problem",
"tried": "cry",
"student_id": 2,
"admin_id": 1,
"created_at": "2019-04-15 07:16:35",
"updated_at": "2019-04-15 07:16:35",
"categories": [
"Administration",
"ISA"
]
},
]
URL: /api/tickets
Payload: an object with the following properties.
Category can be a string from pre-selected list!
{
"title": "Please help", // string, max 256 chars, required
"description": "I need help", // string, required
"tried": "I tried this....", // string, optional
"category": "JavaScript I", // string, required
"student_id": 2, // integer, required
}
Returns: new ticket object.
URL: /api/tickets/:id
Payload: an object with the status and user_id property.
Valid status values are "inQueue", "opened", "resolved" strings.
{
status: "inQueue", // Required
user_id: 1 // Integer, Required
}
Returns: updated ticket object.