/api/login/

This call allows the creation of login sessions. If unsuccessful, it will return the parameter that failed. If successful, a session will be created. Sessions are valid for 10 minutes. This can be changed by altering site.sessionTimeout in site.json.

When a session is created, the user profile is loaded into memory for ease of access. When the session is closed or any alterations are made to the user profile, the session json is written to the disc. This prevents any loss of data in the event of a hard shutdown. The previous record is backed up, the new record is json encoded, and written to disc. In the event of a corrupted json, the previous record automatically replaces the current record.

See session.h for more information.