Add bruno api docs

This commit is contained in:
Ean Milligan 2025-04-26 15:47:34 -04:00
parent 1240bff99c
commit 94f2073ce9
25 changed files with 290 additions and 0 deletions

View File

@ -0,0 +1,17 @@
meta {
name: Ban Channel
type: http
seq: 1
}
put {
url: http://localhost:8166/api/channel/ban?user=[discord-user-id]&a=[discord-user-id]&channel=[discord-channel-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
channel: [discord-channel-id]
}

View File

@ -0,0 +1,17 @@
meta {
name: Unban Channel
type: http
seq: 2
}
put {
url: http://localhost:8166/api/channel/unban?user=[discord-user-id]&a=[discord-user-id]&channel=[discord-channel-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
channel: [discord-channel-id]
}

View File

@ -0,0 +1,3 @@
meta {
name: Channel Management [Admin]
}

View File

@ -0,0 +1,16 @@
meta {
name: Activate API Key
type: http
seq: 2
}
put {
url: http://localhost:8166/api/key/activate?user=[discord-user-id]&a=[discord-user-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
}

View File

@ -0,0 +1,16 @@
meta {
name: Ban API Key
type: http
seq: 4
}
put {
url: http://localhost:8166/api/key/ban?user=[discord-user-id]&a=[discord-user-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
}

View File

@ -0,0 +1,16 @@
meta {
name: Deactivate API Key
type: http
seq: 3
}
put {
url: http://localhost:8166/api/key/deactivate?user=[discord-user-id]&a=[discord-user-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
}

View File

@ -0,0 +1,16 @@
meta {
name: Generate API Key
type: http
seq: 1
}
get {
url: http://localhost:8166/api/key?user=[discord-user-id]&a=[discord-user-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
}

View File

@ -0,0 +1,16 @@
meta {
name: Unban API Key
type: http
seq: 5
}
put {
url: http://localhost:8166/api/key/unban?user=[discord-user-id]&a=[discord-user-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
a: [discord-user-id]
}

View File

@ -0,0 +1,3 @@
meta {
name: Key Management [Admin]
}

View File

@ -0,0 +1,3 @@
meta {
name: Admin Requests
}

View File

@ -0,0 +1,16 @@
meta {
name: Activate Channel
type: http
seq: 3
}
put {
url: http://localhost:8166/api/channel/activate?user=[discord-user-id]&channel=[discord-channel-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
channel: [discord-channel-id]
}

View File

@ -0,0 +1,16 @@
meta {
name: Add Channel
type: http
seq: 2
}
post {
url: http://localhost:8166/api/channel/add?user=[discord-user-id]&channel=[discord-channel-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
channel: [discord-channel-id]
}

View File

@ -0,0 +1,16 @@
meta {
name: Deactivate Channel
type: http
seq: 4
}
put {
url: http://localhost:8166/api/channel/deactivate?user=[discord-user-id]&channel=[discord-channel-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
channel: [discord-channel-id]
}

View File

@ -0,0 +1,15 @@
meta {
name: Get Channels
type: http
seq: 1
}
get {
url: http://localhost:8166/api/channel?user=[discord-user-id]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
}

View File

@ -0,0 +1,3 @@
meta {
name: Channel Management
}

View File

@ -0,0 +1,17 @@
meta {
name: Delete API Key
type: http
seq: 1
}
delete {
url: http://localhost:8166/api/key/delete?user=[discord-user-id]&email=[email-address]&code=[optional:delete-code]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
email: [email-address]
code: [optional:delete-code]
}

View File

@ -0,0 +1,3 @@
meta {
name: Key Management
}

View File

@ -0,0 +1,26 @@
meta {
name: Roll Dice
type: http
seq: 1
}
get {
url: http://localhost:8166/api/roll?user=[discord-user-id]&channel=[discord-channel-id]&rollstr=[artificer-roll-cmd]&documentation=All items below are optional. Flags do not need values.&nd=[no-details-flag]&snd=[super-no-details-flag]&s=[spoiler-results-flag]&m=[max-roll-flag, cannot be used with n flag]&n=[nominal-roll-flag, cannot be used with m flag]&gms=[csv-of-discord-user-ids-to-be-dmed-results]&o=[order-rolls, must be a or d]&c=[count-flag]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
channel: [discord-channel-id]
rollstr: [artificer-roll-cmd]
documentation: All items below are optional. Flags do not need values.
nd: [no-details-flag]
snd: [super-no-details-flag]
s: [spoiler-results-flag]
m: [max-roll-flag, cannot be used with n flag]
n: [nominal-roll-flag, cannot be used with m flag]
gms: [csv-of-discord-user-ids-to-be-dmed-results]
o: [order-rolls, must be a or d]
c: [count-flag]
}

View File

@ -0,0 +1,3 @@
meta {
name: Roll Requests
}

View File

@ -0,0 +1,7 @@
meta {
name: Authenticated
}
headers {
X-Api-Key: [YOUR-API-KEY-HERE]
}

View File

@ -0,0 +1,11 @@
meta {
name: Get Heatmap Image
type: http
seq: 2
}
get {
url: http://localhost:8166/api/heatmap.png
body: none
auth: inherit
}

View File

@ -0,0 +1,16 @@
meta {
name: Request API Key
type: http
seq: 1
}
get {
url: http://localhost:8166/api/key?user=[discord-user-id]&email=[email-address]
body: none
auth: inherit
}
params:query {
user: [discord-user-id]
email: [email-address]
}

View File

@ -0,0 +1,3 @@
meta {
name: Unauthenticated
}

12
.bruno/bruno.json Normal file
View File

@ -0,0 +1,12 @@
{
"version": "1",
"name": "The Artificer API",
"type": "collection",
"ignore": [
".git"
],
"presets": {
"requestType": "http",
"requestUrl": "http://localhost:8166/api"
}
}

3
.bruno/collection.bru Normal file
View File

@ -0,0 +1,3 @@
auth {
mode: none
}