Skip to content

Latest commit

 

History

History
119 lines (109 loc) · 4.6 KB

README.md

File metadata and controls

119 lines (109 loc) · 4.6 KB

Zola ~= Zalo

Documents

Requirements

Database

Diagram

Services

  1. Lạc Long Quân - Manage users, posts
    1. Postman
  2. Âu Cơ - Manage chats, messages,...

Relations

  • Users can only block diary from each other if they were a friend
  • Block message means block everything, including
    • Remove the friend relationship
    • Remove all likes, comments
  • Only friends can see each other posts, comments, likes

APIs

User

Post

Chat

  • get_conversation
  • delete_message
  • get_list_conversation
  • delete_conversation
  • TODO (data whatever)
    • Tạo connection || ws://localhost:12000/ws ||
    • Join room
      • type WsMessage struct {
          MsgID      string `json:"message_id"` // null
          Event      string `json:"event"`      // joinroom
          SenderID   string `json:"sender"`     // user-id
          ReceiverID string `json:"receiver"`   // receiver-id
          Created    string `json:"created"`    // time.Now.UnixMili()
          Content    string `json:"content"`    // null
        }
    • send message
      • type WsMessage struct {
          MsgID      string `json:"message_id"` // null
          Event      string `json:"event"`      // send
          SenderID   string `json:"sender"`     // user-id
          ReceiverID string `json:"receiver"`   // receiver-id
          Created    string `json:"created"`    // time.Now.UnixMili()
          Content    string `json:"content"`    // content
        }

More APIs

  • set_official_account
  • check_verify_code
  • del_saved_search
  • get_list_suggested_friends
  • get_verify_code
  • get_saved_search

Admin APIs