mirror of
https://github.com/roleypoly/roleypoly-v1.git
synced 2025-06-15 09:59:09 +00:00
add server list connection to discord
This commit is contained in:
parent
6840446cdf
commit
13cd3bd4a0
13 changed files with 138 additions and 34 deletions
14
Server/api/servers_test.js
Normal file
14
Server/api/servers_test.js
Normal file
|
@ -0,0 +1,14 @@
|
|||
module.exports = (R, $) => {
|
||||
R.get('/api/~/relevant-servers/:user', (ctx, next) => {
|
||||
// ctx.body = 'ok'
|
||||
const srv = $.discord.getRelevantServers(ctx.params.user)
|
||||
ctx.body = $.discord.presentableServers(srv, ctx.params.user)
|
||||
return
|
||||
})
|
||||
|
||||
R.get('/api/~/roles/:server', (ctx, next) => {
|
||||
// ctx.body = 'ok'
|
||||
ctx.body = $.discord.getRoles(ctx.params.server)
|
||||
return
|
||||
})
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue