Skip to content

Settings Page

siddharthakonakanchi edited this page Dec 5, 2017 · 5 revisions

Index

  1. Description
  2. API Calls
  3. Data Base Details

Description

Settings page enables user to modify the details like Email address, Name, Date of Birth , Location and Hometown

API

This Page contains two API calls in which one API called is made whenever the /settings pages is loaded here we have an AJAX call that populates the logged in user details from he database . We have another API call which takes the newly enterd field in the text box upon update click in the edit link.

Endpoint
  /updateDataupdateData
Method
POST  
Fields
Key Description Type Required
New Value Newly entered value corresponding to the edit feild String Yes
Response
Response

Status codes: 200,400,501
Example:
code: 200 OK

##Table Name: users

Table structure

Key Description Type Required
name User Name String Yes
email Email ID of the user String Yes
location Current location of the user String No
hometown Hometown of the user String No
language Language preferences String Yes
birthday Date of birth of user String Yes
gender Gender of user String No
bio Short biography about the user String No
password Encrypted password String Yes
Endpoint

/getUser

Method
GET  
Fields
Key Description Type Required
userid Four digit unique id generated for each user String Yes
Password New Password String Yes
Description

This API is used to fetch all the details of the user through a 4 digit unique id of the user. This API is called before page loading of the settings through AJAX

Response

Status codes: 200,400,501
Example:
code: 200 OK

##Table Name: users

Table structure

Key Description Type Required
name User Name String Yes
email Email ID of the user String Yes
location Current location of the user String No
hometown Hometown of the user String No
language Language preferences String Yes
birthday Date of birth of user String Yes
gender Gender of user String No
bio Short biography about the user String No
password Encrypted password String Yes

Clone this wiki locally