Skip to content

http server with json api, written on scala + akka + spraycan + sprayjson

License

Notifications You must be signed in to change notification settings

Ymatigoosa/protectedchat-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

protectedchat-server

Server API

Requests

{
  "mode": "registration",
  "nickname": "?",
  "pw": "?"
}

{
  "mode": "authorisation",
  "nickname": "?",
  "pw": "?",
  "p2pip": "?"
}

{
  "mode": "logout",
  "token": "?"
}

{
  "mode": "getip",
  "token": "?",
  "nickname": "?"
}

{
  "mode": "addfriend",
  "token": "?",
  "nickname": "?"
}

{
  "mode": "removefriend",
  "token": "?",
  "nickname": "?"
}

{
  "mode": "getfriends",
  "token": "?"
}

{
  "mode": "update",
  "token": "?"
}

Replies

{
  "status": "registered",
  "nickname": "?"
}

{
  "status": "authorised",
  "nickname": "?",
  "token": "?"
}

{
  "status": "logouted",
  "nickname": "?"
}

{
  "status": "ip",
  "nickname": "?",
  "ip": "?"
}

{
  "status": "friendadded",
  "owner": "?",
  "friend": "?"
}

{
  "status": "friendremoved",
  "owner": "?",
  "friend": "?"
}

{
  "status": "friendlist",
  "nickname": "?",
  "list": "?"
}

{
  "status": "updated",
  "nickname": "?"
}

{
  "status": "error", // You can check http response code when error for additional info
  "errormsg": "?"    // for example code 400 - Bad request
}

About

http server with json api, written on scala + akka + spraycan + sprayjson

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages