Skip to content
This repository was archived by the owner on Oct 5, 2024. It is now read-only.

API Compliance #13

Closed
nosehad opened this issue Feb 20, 2024 · 2 comments
Closed

API Compliance #13

nosehad opened this issue Feb 20, 2024 · 2 comments
Assignees
Labels

Comments

@nosehad
Copy link
Collaborator

nosehad commented Feb 20, 2024

Please Add:

  • real name field for new user
  • check method to see if email is already present in system
  • same thing for user name
@nosehad
Copy link
Collaborator Author

nosehad commented Feb 20, 2024

Ensure API allows for following methods to be implemented:

/*
 * returns true if email already belongs to a username
 */
function /* :bool */ email_present(email) {
    return false;
}

/*
 * returns true if username was already taken
 */
function /* :bool */ uname_present(uname) {
    return false;
}

/*
 * registers a new user to the system; API automatically grants a session cookie
 * returns false if data contains illegal/suspicious content (or script/HTML tags) and was blocked by the server
 * IP will be lifetime blocked from frontend service
 */
function /* :bool */ register_user(email, passwd, uname, real_name, persistent /* (remember user?) */) {
    return true;
}

/*
 * automatically grants a session cookie
 * returns false on invalid credentials 
 */
function /* :bool */ login_user(email, passwd, persistent) {
    return true;
}

/*
 * automatically grants a session cookie
 * returns false on invalid token 
 */
function /* :bool */ login_userWithGoogle(oAuthClientToken) {
    return true;
}

@TheRedScreen64
Copy link
Owner

Everything is implemented now

TheRedScreen64 added a commit that referenced this issue Feb 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants