To execute the query, there must be at least 1 parameter, either the email or username of the account. When there are both email and username parameters at the same time, the account will be prioritized to search by email first. If there is no match by email, it will continue to search for accounts by username.
// Response Code "02". No token provided.// Return data:{"respCode": "02","user": null,"msg": "No token"}// Response Code "03". No email or username provided.// Return data:{"respCode": "03","user": null,"msg": "Search user require email or username parameter"}// Response Code "07". Account not found.// Return data:{"respCode": "07","user": null,"msg": "User not found"}
// Response Code "05". Token is invalid or has expired.// Return data:{"respCode": "05","user": null,"msg": "Invalid token || Token has expired"}
// Response Code "06". Your account is not authorized to perform the query.// Return data:{"respCode": "06","user": null,"msg": "Your account does not have permission"}
// Response Code "01". Wrong request method.// Return data:{"respCode": "01","user": null,"msg": "Request method should be GET"}
// Response Code "04". Server not able to authenticate your account.// Return data:{"respCode": "04","user": null,"msg": "Server not able to authenticate your account"}
Example
// Search for an account by email// GET:https://abc.hoola.vn/manage/api/users/search-user?token=sdhg23797sdbv9186jdvk58&email=abc@abc.com// Search for an account by username// GET:https://abc.hoola.vn/manage/api/users/search-user?token=sdhg23797sdbv9186jdvk58&username=abc// Search for an account by both email and username// GET:https://abc.hoola.vn/manage/api/users/search-user?token=sdhg23797sdbv9186jdvk58&email=abc@abc.com&username=abc