Library Organizer is a complete suite of tools designed to help users manage their personal or professional libraries. It hosts a variety of features:
In this document, you will find both a user guide, for normal users to learn the software, and a REST API, for developers to utilize.
You will need to have a MySql database setup, as well as Go and npm. First, initialize the database using /dev/create_database.sql. Then, edit /dev/libraries.env with your sql credentials and database information.
Pull down https://github.com/jakekausler/LibraryOrganizerReact and build application. Move the files from the /build folder in LibraryOrganizerReact to the /web folder in this application.
Source the /dev/libraries.env file, and then build and run the application.
When you first load the Library Organizer site, you will be brought to a page where you can either login to your account or register for an account. Click the appropriate button to continue to the site.
If you do not have an account, you will need to register for an account. Click the register button and enter your desired username, email address, first and last name, and password. If the information provided is valid, your account will be created and you will be redirected to the main site. An empty default library is automatically created for you.
If you do have an account, click the log in button and enter your username and password. You will be redirected to the main site.
If you have forgotten your password, you may click the log in button, then the forgot password button. Enter the email you used to create your account. An email with instructions on how to reset your password will be sent to you.
At the core of Library Organizer are libraries. Libraries hold books and shelves on which those books can be displayed. In the settings dialog (accessed by pressing the gear button on the top right of the screen) there are various ways you may manipulate your libraries.
NOTE: You must click the save button at the bottom of the settings dialog in order for your library changes to be saved. NOTE: If you delete a library, all of its books will be deleted as well.
A user may have as many libraries as he or she desires, but must have at least one. In the settings dialog, you may create, rename, and delete your libraries. To create a library, click the plus button at the bottom of the dialog. To rename a library, simply change the library name in the text input near the top of the dialog. To delete a library, click the trash can beside the library's name. Remember that if you delete a library, all of its books will be deleted as well.
You may grant permission for other users to view, check out from, or edit your libraries. To do so, use the appropriate search box to search for a user, and click on them to add them to the corresponding permission group. You may search by name, username, or email address.
User settings are default settings used when creating shelves. These are found in the settings dialog (accessed by pressing the gear button on the top right of the screen), in the second and third tabs, respectively.
The possible shelf settings, with their value types, are as follows. See the Value Types section of this guide for more information. Setting | Value Type |
---|---|
TODO | TODO |
The possible book settings, with their value types, are as follows. See the Value Types section of this guide for more information. Setting | Value Type |
---|---|
TODO | TODO |
You can open the filters menu by clicking the filter button located in the top left of the screen on the grid view. This will allow you to change which books displayed in the grid. There are several options:
To quickly navigate pages, you can press the left and right buttons at the top of the screen.
You may add books to or edit books in any library you own or have permission to edit. There are various ways to add or edit books.
The book editor is a dialog that contains input fields for a book. The main fields and their values are as follows. See the Value Types section of this guide for more information.
Field | Value Type | Tab | Description |
---|---|---|---|
Title | String | 1 | The title of the book. Required |
Subtitle | String | 1 | The subtitle of the book. |
Series | String | 1 | The series the book is a part of. Suggestions will appear with possible series as you type. |
Volume | Number | 1 | The series volume of the book. Required. Zero is the empty volume. |
Publisher | String | 2 | The publisher of the book. Suggestions will appear with possible publishers as you type. |
City | String | 2 | The city where the book was published. Suggestions will appear with possible cities as you type. |
State | String | 2 | The state where the book was published. Suggestions will appear with possible states as you type. |
Country | String | 2 | The country where the book was published. Suggestions will appear with possible countries as you type. |
Originally Published | Year | 2 | The year in which the book was originally published. Required. 0000 is the empty year. |
Edition Published | Year | 2 | The year in which this edition of the book was published. Required. 0000 is the empty year. |
ISBN | ISBN | 2 | The ISBN of the book. |
Edition | Non-Negative Integer | 2 | The edition of the book. Required. Zero is the empty edition. |
Lexile | Lexile | 2 | The Lexile of the book. Required. 0L is the empty lexile. |
Dewey | Dewey | 2 | The dewey of the book. Required. 000 is the empty dewey. |
Format | String | 2 | The binding of the book. |
Pages | Non-Negative Integer | 2 | The number of pages in the book. Required. Zero is the empty number of pages. |
Width | Non-Negative Integer | 2 | The width of the book in millimeters. Required. Zero is the empty width. |
Height | Non-Negative Integer | 2 | The height of the book in millimeters. Required. Zero is the empty height. |
Depth | Non-Negative Integer | 2 | The depth of the book in millimeters. Required. Zero is the empty depth. |
Weight | Non-Negative Number | 2 | The weight of the book in ounces. Required. Zero is the empty weight. |
Primary Language | String | 2 | The main language in which the book is written. |
Secondary Language | String | 2 | The secondary language in which the book is written. |
Original Language | String | 2 | The original language in which the book is written. |
Owned | Checkbox | 2 | Whether or not the book is owned. If not owned, it is on the wish list. |
Read | Checkbox | 2 | Whether or not the book has been read by the library owner. |
Reference | Checkbox | 2 | Whether or not the book is considered reference by the library owner. |
Reading | Checkbox | 2 | Whether or not the book is being read by the library owner. |
Shipping | Checkbox | 2 | Whether or not the book is being shipped. |
There is also a section on the first tab for adding and editing the contributors for a book. A contributor is added by filling in its fields and pressing the plus button. To edit an existing contributor, press the pencil button and fill in its fields, then click the save button. To remove an existing contributor, press the trash button.
Field | Value Type | Description |
---|---|---|
First Name | String | The first name of the contributor |
Middle Names | String | The middle names of the contributor, separated by spaces |
Last Name | String | The last name of the contributor |
Role | String | The role the contributor had for the book, for instance "Author" or "Editor" |
Finally, there is a section on the first tab for adding, changing, editing, and removing a book's image and spine color. An image may be added or changed in two ways: 1) By pressing the paste button and typing in an image url, or 2) By pressing the upload button and uploading an image. To remove an image, press the trash button. An image may also be cropped or rotated by pressing the pencil button.
When a book is saved, its spine color is automatically set based on the most prominant color in the image. To override this, you may click the spine color button and choose a new color. To go back to the automatically calculated color, click the default button in the color chooser.
To add a book from scratch, click the plus button at the top of the grid view. Any field which has a user setting will be automatically filled in.
To add a book from isbn, click the barcode button at the top of the grid view. Enter the isbn number and press enter. A list of possible matches will appear. Click on the one you would like to add and a book editor will appear with information gathered from that isbn.
To add a book from an existing book, click on the book you would like to duplicate in either the library or grid view, then click on the copy button in the book view dialog. An editor menu will appear with the book's information.
To edit an existing book, click on the book you would like to edit and then click the pencil button. An editor menu will appear with the book's information.
TODO
If you have permission to check out from a library, you may check out books (and also return them). Any book you have checked out will display as checked out to you and will not be available for others to check out.
To check out a book, click on the book you would like to check out from either the grid or library view. Then click the cart button. Upon confirming that you would like to check out the book, it will now be listed as a book you have checked out.
To check out a book, click on the book you would like to check in from either the grid or library view. Then click the cart button. Upon confirming that you would like to check in the book, it will no longer be listed as a book you have checked out.
You may export or import books in a csv format. There are various options for exporting books and special considerations that must be made when importing books.
TODO
TODO
TODO
The library view (accessed by using the second button at the top of the screen) shows a physical representation of a library. It is based on case and book measurements.
To change the current library, click the filter button in the top left of the screen. To move around in the library, use the scroll bars at the right and bottom of the screen.
TODO
There are three types of information that can be edited for a library: The cases, breaks, and details.
A library is made of book cases. Each book case has the following fields that may be edited. See the Value Types section for more details.
Field | Value Type | Description |
---|---|---|
Case Width | Positive Integer | This is the width of the shelf from end to end, not including the sides (so, from inside edge to inside edge) |
Number of Shelves | Positive Integer | The number of shelves on this case. This is the number of locations that books may be placed, so it should include the bottom of the case. |
Padding Left/Right | Positive Integer | This is the minimum amount of space that should be left on either side of a shelf to make up for measurements that were too small. The more accurate that you are in your measurements, the less padding that is needed. |
Shelf Height | Positive Integer | The height, from the top of one shelf to the bottom of the next, of a shelf gap. This does not include the actual shelf height. |
Spacer Size | Positive Integer | The thickness of the sides/shelves of a case. This is how thick the "outline" of the case and its shelves will be. |
Cases may also be moved up or down by using the respective buttons, or deleted using the trash button of the corresponding case. To add a new shelf, click the plus button at the bottom of the dialog.
There are two types of breaks that a library may include:
In addition to these types of breaks, breaks can be of a specific value type:
To add a break, press the plus button at the bottom of the dialog. To remove a break, press the trash can on the corresponding break.
There are two other features of a library that may be edited:
The statistics menu can be accessed by clicking the third button on the top of the screen. To change which libraries are being used to calculate the statistics, click the filter button in the top left of the screen. Only owned books are used in the calculations. There are several types of statistics, grouped into various categories:
There are several fields that require a specific value type. The different value types are described here:
Books /books
GET /books
PUT /books
POST /books
DELETE /books
PUT /books/checkout
PUT /books/checkin
GET /books/books
GET /books/contributors
POST /books/books
GET /books/:bookid/ratings
GET /books/:bookid/reviews
POST /books/:bookid/ratings
POST /books/:bookid/reviews
Information /information
GET /information/statistics
GET /information/dimensions
GET /information/publishers
GET /information/cities
GET /information/states
GET /information/countries
GET /information/formats
GET /information/roles
GET /information/series
GET /information/languages
GET /information/deweys
Libraries /libraries
GET /libaries
GET /libraries/owned
PUT /libraries/owned
GET /libraries/:libraryid/cases
PUT /libraries/:libraryid/cases
GET /libraries/:libraryid/breaks
PUT /libraries/:libraryid/breaks
GET /libraries/:libraryid/series
PUT /libraries/:libraryid/series
GET /libraries/:libraryid/sort
PUT /libraries/:libraryid/sort
Settings /settings
GET /settings
PUT /settings
GET /settings/:setting
Users /users
GET /users
POST /users/login
POST /users
POST /users/logout
PUT /users/password
GET /users/password/:token
GET /users/username
GET /books
PUT /books
POST /books
DELETE /books
PUT /books/checkout
PUT /books/checkin
GET /books/books
GET /books/contributors
POST /books/books
GET /books/:bookid/ratings
GET /books/:bookid/reviews
POST /books/:bookid/ratings
POST /books/:bookid/reviews
Action
Returns an array of books.
Method
GET
URL
/books
URL Params
none
URL Arguments (?)
sortmethod
: Primary method of sorting. One of dewey
, series
, lexile
, author
, or title
.numbertoget
: Number of books for pagination purposes.page
: Page of books to get.fromdewey
: Starting dewey of the results, inclusive.todewey
: Ending dewey of the results, inclusivetext
: Filter text, used for searching titles, subtitles, and seriesisread
: Whether or not the book is read by the library owner. One of yes
, no
, or both
.isreference
: Whether or not the book is considered reference by the library owner. One of yes
, no
, or both
.isowned
: Whether or not the book is owned by the library owner. One of yes
, no
, or both
.isreading
: Whether or not the book is being read by the library owner. One of yes
, no
, or both
.isshipping
: Whether or not the book is shipping to the library owner. One of yes
, no
, or both
.isloaned
: Whether or not the book is checked out. One of yes
, no
, or both
.libraryids
: A comma separated list of library ids from which to include books.Data Params
none
Success Response
* **Error Response**
```json
Action
Saves a book.
Method
PUT
URL
/books
URL Params
none
URL Arguments (?)
none
Data Params
{
"bookid": "12345",
"title": "Sample Title",
"subtitle": "Sample Subtitle",
"originallypublished": "2006-01-02T15:04:05Z07:00",
"publisher": {
"id": "12345",
"publisher": "Sample Publishing House",
"city": "New York",
"state": "New York",
"country": "USA",
"parentcompany": "Sample Parent Publishing House"
},
"isread": true,
"isreference": true,
"isowned": true,
"isbn": "123456789012X",
"loanee": {
"id": 123,
"username": "testuser",
"first": "Jane",
"last": "Smith",
"fullname": "Jane Smith",
"email": "jsmith@test.com",
"iconurl": "/res/userimages/123.jpg"
},
"dewey": "FIC",
"pages": 0,
"width": 0,
"height": 0,
"depth": 0,
"weight": 0.0,
"primarylanguage": "English",
"secondarylanguage": "Klingon",
"originallanguage": "English",
"series": "Sample Series",
"volume": 0.0,
"format": "Paperback",
"edition": 1,
"isreading": true,
"isshipping": true,
"imageurl": "/res/bookimages/12345.jpg",
"spinecolor": "##123456",
"cheapestnew": 0.01,
"cheapestused": 0.01,
"editionpublished": "2006-01-02T15:04:05Z07:00",
"contributors": [{
"id": "1234",
"name": {
"first": "John",
"middles": "J;Kimily",
"last": "Smith"
},
"role": "Author"
}],
"library": {
"id": 12345,
"name": "default",
"permissions": 7,
"owner": "123"
}
}
Success Response
* **Error Response**
```json
Action
Adds a book.
Method
POST
URL
/books
URL Params
none
URL Arguments (?)
none
Data Params
{
"bookid": "12345",
"title": "Sample Title",
"subtitle": "Sample Subtitle",
"originallypublished": "2006-01-02T15:04:05Z07:00",
"publisher": {
"id": "12345",
"publisher": "Sample Publishing House",
"city": "New York",
"state": "New York",
"country": "USA",
"parentcompany": "Sample Parent Publishing House"
},
"isread": true,
"isreference": true,
"isowned": true,
"isbn": "123456789012X",
"loanee": {
"id": 123,
"username": "testuser",
"first": "Jane",
"last": "Smith",
"fullname": "Jane Smith",
"email": "jsmith@test.com",
"iconurl": "/res/userimages/123.jpg"
},
"dewey": "FIC",
"pages": 0,
"width": 0,
"height": 0,
"depth": 0,
"weight": 0.0,
"primarylanguage": "English",
"secondarylanguage": "Klingon",
"originallanguage": "English",
"series": "Sample Series",
"volume": 0.0,
"format": "Paperback",
"edition": 1,
"isreading": true,
"isshipping": true,
"imageurl": "/res/bookimages/12345.jpg",
"spinecolor": "##123456",
"cheapestnew": 0.01,
"cheapestused": 0.01,
"editionpublished": "2006-01-02T15:04:05Z07:00",
"contributors": [{
"id": "1234",
"name": {
"first": "John",
"middles": "J;Kimily",
"last": "Smith"
},
"role": "Author"
}],
"library": {
"id": 12345,
"name": "default",
"permissions": 7,
"owner": "123"
}
}
Success Response
* **Error Response**
```json
Action
Deletes a book.
Method
DELETE
URL
/books
URL Params
none
URL Arguments (?)
none
Data Params
Book Id:
12345
Success Response
* **Error Response**
```json
Action
Checks out a book.
Method
PUT
URL
/books/checkout
URL Params
none
URL Arguments (?)
none
Data Params
Book Id:
12345
Success Response
* **Error Response**
```json
Action
Checks in a book.
Method
PUT
URL
/books/checkin
URL Params
none
URL Arguments (?)
none
Data Params
Book Id:
12345
Success Response
* **Error Response**
```json
Action
Exports a csv of book data.
Method
GET
URL
/books/books
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Exports a csv of contributors
Method
GET
URL
/books/contributors
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Imports books from a csv to a library. The column headers should match the database fields names, with the exception of publisher and contributors. Publisher should be split into four columns: "publisher", "city", "state", "country". Contributors should be in a single column, with the header "contributors". They should be written as follows: "lastName[, firstName middleName1 middleName2... middleNameN]: role", with different contributors separated by a single semicolon and omitting first and middle names as needed.
Method
POST
URL
/books/books
URL Params
none
URL Arguments (?)
none
Data Params
Form Data:
csv file
Success Response
* **Error Response**
```json
Action
Get the ratings for a book and its best guest matches.
Method
GET
URL
/books/:bookid/ratings
URL Params
:bookid
Id of the book to get ratings from
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Add or replace a rating for a book.
Method
PUT
URL
/books/:bookid/ratings
URL Params
:bookid
Id of the book to get ratings from
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the reviews for a book and its best guest matches.
Method
GET
URL
/books/:bookid/reviews
URL Params
:bookid
Id of the book to get reviews from
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Add or replace a review for a book.
Method
PUT
URL
/books/:bookid/reviews
URL Params
:bookid
Id of the book to get reviews from
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
GET /information/statistics
GET /information/dimensions
GET /information/publishers
GET /information/cities
GET /information/states
GET /information/countries
GET /information/formats
GET /information/roles
GET /information/series
GET /information/languages
GET /information/deweys
Action
Get a set of statistics.
Method
GET
URL
/information/statistics
URL Params
none
URL Arguments (?)
type
: One of generalbycounts
, generalbypages
, generalbysize
, publishersbooksperparent
, publisherstopchildren
, publisherstoplocations
, series
, languagesprimary
, languagessecondary
, languagesoriginal
, deweys
, formats
, contributorstop
, contributorsperrole
, datesoriginal
, datespublication
libraryids
: A comma separated list of library ids from which the statistics are calculatedData Params
none
Success Response
* **Error Response**
```json
Action
Get a set of dimensions.
Method
GET
URL
/information/dimensions
URL Params
none
URL Arguments (?)
none
Data Params
Library Ids:
123,124,125
Success Response
* **Error Response**
```json
Action
Get a the set of publishers.
Method
GET
URL
/information/publishers
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of cities.
Method
GET
URL
/information/cities
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of states.
Method
GET
URL
/information/states
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of countries.
Method
GET
URL
/information/countries
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of formats.
Method
GET
URL
/information/formats
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of contributor roles.
Method
GET
URL
/information/roles
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of series.
Method
GET
URL
/information/series
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of languages
Method
GET
URL
/information/languages
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the set of deweys
Method
GET
URL
/information/deweys
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
GET /libaries
GET /libraries/owned
PUT /libraries/owned
GET /libraries/:libraryid/cases
PUT /libraries/:libraryid/cases
GET /libraries/:libraryid/breaks
POST /libraries/:libraryid/breaks
PUT /libraries/:libraryid/breaks
DELETE /libraries/:libraryid/breaks
GET /libraries/:libraryid/series
PUT /libraries/:libraryid/series
GET /libraries/:libraryid/sort
PUT /libraries/:libraryid/sort
Action
Get a list of libraries with which the user has permission to do something.
Method
GET
URL
/libraries
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the libraries which the user owns and the user who can do something with them.
Method
GET
URL
/libraries/owned
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Saves the libraries the user owns and the users who can do something with them.
Method
PUT
URL
/libraries/owned
URL Params
none
URL Arguments (?)
none
Data Params
[{
"id": 123,
"name": "default",
"user": [{
"id": 1234,
"username": "janedoe",
"firstname": "Jane",
"lastname": "Doe",
"fullname": "Jane Doe",
"email": "jdoe@test.com",
"iconurl": "/res/usericons/1234.jpg",
"permission": "7"
}]
}]
Success Response
* **Error Response**
```json
Action
Get the cases in a library.
Method
GET
URL
/libraries/:libraryid/cases
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
sortmethod
One of DEWEY
, SERIES
, or TITLE
Data Params
none
Success Response
* **Error Response**
```json
Action
Save the cases in a library.
Method
PUT
URL
/libraries/:libraryid/cases
URL Params
none
URL Arguments (?)
none
Data Params
{
"editedcases": [{
"id": 1233,
"casenumber": 1,
"numberofshelves": 5,
"shelfheight": 300,
"width": 500,
"paddingright": 10,
"paddingleft": 10,
"spacerheight": 12
}],
"toremoveids": [
1234,
1235
]
}
Success Response
* **Error Response**
```json
Action
Get the breaks for a library.
Method
GET
URL
/libraries/:libraryid/breaks
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Update the breaks in a library.
Method
PUT
URL
/libraries/:libraryid/breaks
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
none
Data Params
[{
"libraryid": 1234,
"valuetype": "ID",
"value": "12345",
"breaktype": "SHELF"
}]
Success Response
* **Error Response**
```json
Action
Get the series that should be sorted primarily on volume, instead of author.
Method
GET
URL
/libraries/:libraryid/series
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Set the series that should be sorted primarily on volume, instead of author.
Method
PUT
URL
/libraries/:libraryid/series
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the sort method of a library.
Method
GET
URL
/libraries/:libraryid/sort
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Set the sort method of a library. One of "dewey", "title", or "series"
Method
PUT
URL
/libraries/:libraryid/sort
URL Params
:libraryid
The id of the selected library
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
GET /settings
PUT /settings
GET /settings/:setting
Action
Get the user's settings. If nothing is set for a setting, return the default.
Method
GET
URL
/settings
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
[{
"name": "width",
"value": "500",
"valuetype": "nonnegativeinteger",
"group": "BOOK",
"possiblevalues": []
}]
Error Response
### Save Settings
* **Action**
`Save the user's settings.`
* **Method**
`PUT`
* **URL**
`/settings`
* **URL Params**
`none`
* **URL Arguments (?)**
`none`
* **Data Params**
```json
"group": "Book",
"name": "IsOwned",
"value": "true",
"valuetype": "select",
"possiblevalues": [
"true",
"false"
]
* **Error Response**
```json
Action
Get a single user setting.
Method
GET
URL
/settings/:setting
URL Params
none
URL Arguments (?) ``
Data Params
Setting Name
Width
Success Response
settingvalue
Error Response
## Users
* Get Users `GET /users`
* Login `POST /users/login`
* Register `POST /users`
* Logout `POST /users/logout`
* Send Password Reset `PUT /users/password`
* Finish Password Reset `GET /users/password/:token`
* Get Username `GET /users/username`
### Get Users
* **Action**
`Get the users in a library.`
* **Method**
`GET`
* **URL**
`/users`
* **URL Params**
`none`
* **URL Arguments (?)**
`none`
* **Data Params**
`none`
* **Success Response**
```json
[{
"id": 1234,
"username": "janedoe",
"first": "Jane",
"last": "Doe",
"fullname": "Jane Doe",
"email": "jdoe@test.com",
"iconurl": "/res/usericons/1234.jpg"
}]
### Login
* **Action**
`Log a user in to the system.`
* **Method**
`POST`
* **URL**
`/users/login`
* **URL Params**
`none`
* **URL Arguments (?)**
`none`
* **Data Params**
Form Data
* `username`
* `password`
* **Success Response**
Redirect to main page
* **Error Response**
```json
Action
Register a user in to the system.
Method
POST
URL
/users
URL Params
none
URL Arguments (?)
none
Data Params
username
email
firstname
lastname
password
Success Response Redirect to main page
Error Response
### Logout
* **Action**
`Log a user out of the system.`
* **Method**
`POST`
* **URL**
`/users/logout`
* **URL Params**
`none`
* **URL Arguments (?)**
`none`
* **Data Params**
`none`
* **Success Response**
Redirect to unregistered page
* **Error Response**
```json
Action
Send a password reset request to the user's email.
Method
PUT
URL
/users/reset
URL Params
none
URL Arguments (?)
none
Data Params
email
Success Response
* **Error Response**
```json
Action
Complete a password reset request.
Method
GET
URL
/users/reset/:token
URL Params
:token
The token to lookup for the reset
URL Arguments (?)
none
Data Params
none
Success Response
* **Error Response**
```json
Action
Get the user's username.
Method
GET
URL
/users/username
URL Params
none
URL Arguments (?)
none
Data Params
none
Success Response
username
Error Response