login_session

login_session Logs in a session. Returns a structure containing info about the login operation.

Format:

 login_session(session,username,password)

Parameters:

Parameter Type Description
session cloudsession The session to affect. this is a "cloudsession" object
username user string id of the user
password string entered password

Returned Value:

Type Description
structure with components :
Component Type Description
logged_inbooleansays if login was successful or not
login_errorstringset if login failed. gives the error message
user_namestringset if login succeeded. name of the user
user_emailstringset set if login succeeded and there is a user email (if any)
user_organizationstringset if login succeeded and there is a: string name of the user's organization i.e. company
user_idstringset if login succeeded. id of the user
user_typestringset if login succeeded. type of the user
user_is_adminbooleanset if login succeeded. true if the logged in user is an admin. false otherwise

Examples

info = login_session(session,username,password)