User
Login
Login to the service, if the user is login for the first time, the system will automatically register the account.
Path:
/api/v1/user/login
Method:
Post
Content-type:
Json
Parameters:
application<json object> application informationid<string> app idsecret<string> app secret
device<json object> device information used by usertype<string> device type. eg: iPhone, android, web, windowsid<string> device unique identity string
email(optional) <json object> login option - emailaddress<string> email addresscode<string> login verification code
phone(optional) <json object> login option - phonenumber<string> phone numbercode<string> login verification code
oauth(optional) <json object> login option - third-party loginplatform<string> which platform user selected, eg: googleusername<string> username in selected platformtoken<string> access token given by the selected platform
Response:
code<int> response codemessage<string> response messagedata<json object> response datauser_id<string> user idaccess_key<string> EDDSA private key, used to sign user's request
Logout
Logout from the service
Path:
/api/v1/user/logout
Method:
Post
Content-type:
Json
Parameters:
user_id<string> user iddevice<json object> login devicetype<string> device type. eg: iPhone, android, web, windowsid<string> device unique identity string
access_key<string> key returned by login api
Response:
code<int> response code, 0 means successmessage<string> response message
Last updated