git 테스트

sbkwgh 5ca8747559 Escape < 8 lat temu
config cacfe862c4 Add sessionSecret variable 8 lat temu
lib df0a8eea88 Try to fix socket.io bug - still doesn't work but code in place for what *should* work (i.e. reloading the session in socket.io when users sends login message 8 lat temu
migrations c8eb10feb1 Add migration for unique username attribute 8 lat temu
models c7e94d59ca Associate poll quesiton with thread and add test case constraints 8 lat temu
routes 07a56dbce8 Add hasVoted parameter 8 lat temu
test 07a56dbce8 Add hasVoted parameter 8 lat temu
.gitignore df0a8eea88 Try to fix socket.io bug - still doesn't work but code in place for what *should* work (i.e. reloading the session in socket.io when users sends login message 8 lat temu
LICENSE 2e15a2ca14 Create LICENSE 8 lat temu
README.md 5ca8747559 Escape < 8 lat temu
package.json df0a8eea88 Try to fix socket.io bug - still doesn't work but code in place for what *should* work (i.e. reloading the session in socket.io when users sends login message 8 lat temu
server.js 62ad392607 Add poll POST route and tests 8 lat temu

README.md

forum-backend

This is the backend (or 'api component') of the forum software to go along with the corresponding frontend project.

API Documentation

All API routes are prefixed /api/v1/

/admin_token

/

  • Method: POST
  • Response: { id: <integer>, token: <string> }
  • Notes: requires admin privileges

/ban

/

  • Method: GET
  • Data params:
    • message <string>
    • username: <string>
    • canCreateThreads <boolean>
    • canCreatePosts <boolean>
    • ipBanned <boolean>
  • Response: { id: <integer>, message: <string>, canCreateThreads: <boolean>, canCreatePosts: <boolean>, ipBanned: <boolean>, User: { id: <integer>, username: <string>, description: <null | string>, color: <string>, createdAt: <string> }
    • Notes: requires admin privileges