Expand description
Contains HTTP Handlers that directly receive and respond to requests to the server.
Structs§
- Delete
QrCode Request - Edit
QrCode Request - Form
Creation Request - Form
GetRequest - Form
GetResponse - GetQr
Code Request - GetQr
Code Response - List
QrCodes Response - NewQr
Code Request - Registration
Request
Enums§
- Application
Error - Error derived while handling an HTTP request
Functions§
- delete_
qr_ code - get(/qr_code/delete?id={ID}) edits a QR code with the relevant information
- edit_
qr_ code - get(/qr_code/edit?id={ID}&generation_data={DATA}&slug={SLUG}) edits a QR code with the relevant information
- get_
form - get(form) runs an SQL query on a provided form id and returns a JSON object of the fields
- get_
qr_ code_ data - get(qr_code?slug={SLUG}) runs a sample SQL query and checks if the user is logged in
- health_
check - Get(/health_check) returns a 200 to indicate the application is running
- json_
response - Creates an HTTP response with a JSON body constructed from any serializable input
- list_
forms - get(form/list) runs an SQL query to retrieve all the forms belonging to the user who sent the request
- list_
qr_ codes - get(/qr_codes) lists QR codes assosciated with a given user
- login
- Get(/login) attempts to log a user in, and if successful returns a JWT token
- logout
- Get(/logout) logs a user out if they are currently logged in
- register
- store_
form - post(form/store) runs an SQL query to store a new form and all its associated fields
- store_
qr_ code - get(/qr_code/store?generation_data={DATA}&slug={SLUG}) stores a QR code with the relevant information
- who_
am_ i
Type Aliases§
- Application
Response - Alias used for all HTTP responses. Uses custom
ApplicationError
error handler.