META

Queries for managing users

updateUser

http://your.server/ramses/?updateUser

Logs in with a username and a (hashed) password.

Query attributes:

Reply content:

Empty

Reply body:

{
    "accepted": true,
    "query": "updateUser",
    "success": true,
    "message": "User \"Duduf\" updated.",
    "content": { }
}

updatePassword

http://your.server/ramses/?updatePassword

Changes the password of a specific user

Query attributes:

Tip

Your application / client should not send a clear password, but it should hash it first, even when using a secure/SSL connection.

Reply content:

Empty

Reply body:

{
    "accepted": true,
    "query": "updateUser",
    "success": true,
    "message": "User updated.",
    "content": { }
}

getUsers

http://your.server/ramses/?getUsers

Retrieves the list of all users.

Query attributes:

Reply content:

The server replies an array of user information. Each user is an object with the following attributes:

Reply body:

{
    "accepted": true,
    "query": "getUsers",
    "success": true,
    "message": "Users list retrieved.",
    "content":  [
        {
            "name": "Nicolas Dufresne",
            "shortName": "Duduf",
            "email": "big@boss.com",
            "uuid": "2d7d7e01-671c-11e7-a78f-4ccc6a288527",
            "folderPath": "/home/duduf",
            "role": "admin",
            "color": "#e3e3e3"
        },
        {
            "name": "J. Doh",
            "shortName": "User",
            "email": "",
            "uuid": "2d7d7e01-671c-11e7-a78f-4ccc6a288527",
            "folderPath": "/home/doe",
            "role": "standard",
            "color": "#674357"
        }
    ]
}

createUser

http://your.server/ramses/?createUser

Creates a new user in the database.

Query attributes:

Reply content:

Empty

Reply body:

{
    "accepted": true,
    "query": "createUser",
    "success": true,
    "message": "User created.",
    "content": { }
}

removeUser

http://your.server/ramses/?removeUser

Removes a user from the database.

Query attributes:

Reply content:

Empty

Reply body:

{
    "accepted": true,
    "query": "removeUser",
    "success": true,
    "message": "User 123 removed.",
    "content": { }
}