Skip to content
shenfeng edited this page Apr 19, 2013 · 11 revisions

For all request except the login, add the access_token to the request header

People

POST /api/v1/login

  • email: user email,
  • password: user password

or

  • provider: like weibo, qq
  • id_in_provider: id
  • name: name in provider

=>

   id: 1,
   access_token: "sdfdsfsdfsdfsdf" // a random token 
}

Get user info /api/v1/users/:id

=>

{
    email: "[email protected]",
    qq: 386297760,
    interested_fields: "html5, bakcend, bigdata",
    work: "None",
    photo: "/user/pic/1212.jpg",
    follow: false
}

Get friends GET /api/v1/friends

=>

[{
    email: "[email protected]",
    qq: 386297760,
    interested_fields: "html5, bakcend, bigdata",
    work: "None",
    photo: "/user/pic/1212.jpg",
    follow: false
},
{
    email: "[email protected]",
    qq: 386297760,
    interested_fields: "html5, bakcend, bigdata",
    work: "None",
    photo: "/user/pic/1212.jpg",
    follow: false
},
]

Follow somebody POST /api/v1/follow

  • user_id: the user id to follow

Get events GET /api/v1/events/

  • start : start time, in milliseconds, default to 1 week ago.
  • end: end time, in milliseconds, default to now.
  • city: like beijing, Null means all.

My events /api/v1/my-events

Clone this wiki locally