Commit graph

58 commits

Author SHA1 Message Date
45a1f45055
Fix role ordering (#789)
* fix role order in picker

* one of these sorts will flip it omg

* fix role list

* revert forced role sort in api
2023-05-28 11:15:44 -04:00
dc1e7718bc remove bot, force role order 2023-05-28 09:47:19 -04:00
677d91b17b this literally doesn't fail locally, removing tests. 2023-05-22 00:31:20 -04:00
5f7f4c05a5 something is wrong with CI :( 2023-05-22 00:25:24 -04:00
15db46c1b2 something is wrong with CI :( 2023-05-22 00:19:56 -04:00
dc1a65941f update ulid-worker 2023-05-22 00:14:10 -04:00
f7e1c32626 lower guild cache time to 15 minutes 2023-05-22 00:05:40 -04:00
dec4aa9619 Revert "flip role order"
This reverts commit 175144cc7a.
2023-02-19 11:45:30 -05:00
175144cc7a flip role order 2023-02-18 15:07:30 -05:00
0e4a228f1b chore: remove legacy import -- fix tests, remove old code 2022-09-01 09:28:09 -04:00
c909b01767 chore: remove legacy import 2022-09-01 08:55:24 -04:00
b427907f34 fix(api): remove prompt=none temporarily -- tests 2022-07-26 13:04:24 -04:00
25107951de fix(api): remove prompt=none temporarily 2022-07-26 12:45:04 -04:00
f5fb729ce7 port bot to rust, upgrade response, and cut away some of the tf cruft 2022-02-06 19:16:08 -05:00
5aa5a6ae1c add /pick-role and /remove-role, refactor responses 2022-02-04 21:21:32 -05:00
0836d548b2 add an instant cache refresh to the editor 2022-02-04 11:59:11 -05:00
68b2b7323b fix tests, add /roleypoly and /pickable-roles handlers 2022-02-04 11:16:18 -05:00
5c5258ef5e add /roleypoly and /pickable-roles slash commands, fix framework issues 2022-02-04 01:37:14 -05:00
fd7ed13e9d fix tests as output types changed a little 2022-02-03 22:59:32 -05:00
544ef1b2f0 fix interactions, apparently cfw doesn't speak Buffer 2022-02-03 22:57:37 -05:00
7007cfea9d add a test for when attemptLegacyImport encounters an error 2022-02-02 13:57:00 -05:00
c7bfed8bae attemptLegacyImport should not break the entire request when it fails 2022-02-02 13:52:01 -05:00
b3f9f57035 forcibly bump api code so it'll deploy 2022-02-01 00:41:35 -05:00
b24f3fd00a normalize auth/callback redirect url 2022-01-31 23:50:05 -05:00
1cb04c8b5a update login flow to prevent session leakage 2022-01-31 23:32:41 -05:00
be826b613e fix typo on auth/callback redirect 2022-01-31 21:51:15 -05:00
3291f9aacc
big overhaul (#474)
* miniflare init

* feat(api): add tests

* chore: more tests, almost 100%

* add sessions/state spec

* add majority of routes and datapaths, start on interactions

* nevermind, no interactions

* nevermind x2, tweetnacl is bad but SubtleCrypto has what we need apparently

* simplify interactions verify

* add brute force interactions tests

* every primary path API route is refactored!

* automatically import from legacy, or die trying.

* check that we only fetch legacy once, ever

* remove old-src, same some historic pieces

* remove interactions & worker-utils package, update misc/types

* update some packages we don't need specific pinning for anymore

* update web references to API routes since they all changed

* fix all linting issues, upgrade most packages

* fix tests, divorce enzyme where-ever possible

* update web, fix integration issues

* pre-build api

* fix tests

* move api pretest to api package.json instead of CI

* remove interactions from terraform, fix deploy side configs

* update to tf 1.1.4

* prevent double writes to worker in GCS, port to newer GCP auth workflow

* fix api.tf var refs, upgrade node action

* change to curl-based script upload for worker script due to terraform provider limitations

* oh no, cloudflare freaked out :(
2022-01-31 20:35:22 -05:00
dac2af43a2 fix(api): disable access control 2021-08-13 08:52:44 -04:00
d5acea4abb fix: missing tools on a composable handler 2021-08-07 18:05:34 -04:00
26bc74bcbc fix(interactions): add async responses 2021-08-07 18:00:20 -04:00
285e23c0ed fix(bot-join): fix commands scope 2021-08-01 20:56:06 -04:00
066f68ffef
feat: Slash Commands (#337)
* feat: add discord interactions worker

* feat(interactions): update CI/CD and terraform to add interactions

* chore: fix lint issues

* chore: fix build & emulation

* fix(interactions): deployment + handler

* chore: remove worker-dist via gitignore

* feat: add /pickable-roles and /pick-role basis

* feat: add pick, remove, and update the general /roleypoly command

* fix: lint missing Member import
2021-08-01 20:26:47 -04:00
dde05c402e add feature flag stuff
Signed-off-by: Katalina Okano <git@kat.cafe>
2021-07-27 23:03:00 -04:00
3f45153b66 feat: add access control 2021-07-18 02:12:30 -04:00
b150462f2b fix(api): remove references to x-create-roleypoly-data 2021-07-17 19:43:21 -04:00
d52508a046 feat(api): update-roles will report x-audit-log-reason to discord
Signed-off-by: Katalina Okano <git@kat.cafe>
2021-07-17 19:22:16 -04:00
824fee0703 refactor(api): Abstract discord API base url to config.ts
Signed-off-by: Katalina Okano <git@kat.cafe>
2021-07-17 19:21:38 -04:00
31ea2e2183 refactor(api): asEditor instead of copy-pasted admin/manager/root check 2021-07-17 19:07:10 -04:00
acc604f83f
feat: add audit logging via webhook (#309)
* feat: add audit logging via webhook

* addd missing auditLogWebhook values in various places
2021-07-13 23:01:25 -04:00
4d18c0da1e chore(get-picker-data): comment a TODO for __no_cache ratelimit 2021-07-09 07:06:24 -05:00
ab3f718e6d
Feat/editor as preview (#294)
* try editor as preview

* add databinding for editor actions and message

* add actions, reordering base interactions

* add drag and drop ordering for categoriers

* category skeleton

* fix linting issues

* add role list and add button, non-functional

* bump packages

* add role search prototype

* yarn.lock sync

* fix lint

* remove cfw-emulator bin
2021-07-08 16:51:00 -05:00
7d681d69d6
Feat/editor category pass2 (#290)
* feat(design-system): add editor skeletons

* use css media queries rather than JS media queries

* init remake

* feat: add basis of toggle atom

* finish toggle

* use pointer cursor with toggle

* sync

* feat: add server message in editor

* cleanup storybook

* add short editor item and data model for categories

* chore: fix build by moving jest version downward

* chore: remove old category editor

* chore: fix EditorCategoryShort index

* add editor wiring and styling updates

* fix linting issues
2021-07-05 12:18:40 -05:00
a37d481b18 chore: downgrade ts-loader because webpack 4 2021-06-30 08:39:07 -04:00
10e095656f chore: update codestyle due to prettier/rule updates 2021-06-30 08:02:36 -04:00
ccff2684ad chore: bump packages 2021-06-30 07:37:35 -04:00
9ee7fb4878 chore: update npm packages 2021-03-24 05:31:49 -04:00
a4fd37d71c
feat(api): add rate-limiting and /clear-guild-cache (#198) 2021-03-23 22:14:33 -04:00
00ac3ef87a feat(api): /login-bounce adds &prompt=none to skip user interaction 2021-03-21 22:26:59 -04:00
117c73a8a1 fix(api): sync from legacy used wrong type of data 2021-03-21 22:10:27 -04:00
bfc96b0750
feat(api): add /sync-from-legacy route (#192)
* feat(api): add /sync-from-legacy route

* chore: remove extraneous dockerfile

* chore: remove extraneous dockerfile build

* chore: remove extraneous dockerfile build matrix
2021-03-22 16:54:33 -04:00