summaryrefslogtreecommitdiff
path: root/internal/api/model/admin.go
AgeCommit message (Collapse)AuthorFiles
2023-11-27[feature] Add `/api/v1/admin/debug/apurl` endpoint (#2359)Libravatar tobi1
2023-09-12[feature] Allow admins to expire remote public keys; refetch expired keys on ↵Libravatar tobi1
demand (#2183)
2023-09-04[feature] Store admin actions in the db, prevent conflicting actions (#2167)Libravatar tobi1
2023-08-19[feature] Instance rules (#2125)Libravatar f0x521
* init instance rules database model, admin api * expose instance rules in public instance api * public /api/v1/instance/rules route * GET ruleById * createRule route * createRule auth check * updateRule * deleteRule * list rules on about page * ruleGet auth * add about page ids for anchors * process and store adding violated rules to reports * admin api models for instance rules * instance rule edit frontend * change rule inputs to textareas * database fixes after rebase (#2124) * remove unused imports * fix db migration column name * fix tests * fix more tests * fix postgres error with wrongly used Ident * add some tests, fiddle with rule model a bit, fix postgres migration * swagger docs --------- Co-authored-by: tsmethurst <tobi.smethurst@protonmail.com>
2023-03-14[feature] Allow admins to send test emails (#1620)Libravatar tobi1
* [feature] Allow admins to send test emails * implement unwrap on new error type * add + use gtserror types * GoToSocial Email Test -> GoToSocial Test Email * add + use getInstance db call * removed unused "unknown" error type
2023-03-12[chore] Improve copyright header handling (#1608)Libravatar Daenney1
* [chore] Remove years from all license headers Years or year ranges aren't required in license headers. Many projects have removed them in recent years and it avoids a bit of yearly toil. In many cases our copyright claim was also a bit dodgy since we added the 2021-2023 header to files created after 2021 but you can't claim copyright into the past that way. * [chore] Add license header check This ensures a license header is always added to any new file. This avoids maintainers/reviewers needing to remember to check for and ask for it in case a contribution doesn't include it. * [chore] Add missing license headers * [chore] Further updates to license header * Use the more common // indentend comment format * Remove the hack we had for the linter now that we use the // format * Add SPDX license identifier
2023-02-20[bugfix] Fix account roles (#1542)Libravatar tobi1
* Change account role from string to object * Update tests * small fixes + swagger docs --------- Co-authored-by: zowhoey <11893985+zowhoey@users.noreply.github.com>
2023-01-25[feature] Implement reports admin API so admins can view + close reports (#1378)Libravatar tobi1
* add admin report api endpoints + tests * [chore] remove funky duplicate attachment in testrig
2023-01-23[feature] Implement `/api/v1/reports` endpoints on client API (#1330)Libravatar tobi1
* start adding report client api * route + test reports get * start report create endpoint * you can create reports now babyy * stub account report processor * add single reportGet endpoint * fix test * add more filtering params to /api/v1/reports GET * update swagger * use marshalIndent in tests * add + test missing Link info
2023-01-05[chore] Update/add license headers for 2023 (#1304)Libravatar tobi1
2022-10-12[feature] Add `/api/v1/admin/custom_emojis` endpoint (#902)Libravatar tobi1
* add admin emojis get path + model + docs * stub admin emojis get processor function * add id + disabled fields to admin emoji * add emoji -> api admin emoji converter * tidy up a bit * add GetEmojis function * finish up get emojis function * order by shortcodedomain * ASC * tidy up + explain * update to allow paging * make admin emojis pageable * fix mixed case paging * normalize emoji queries a bit better * test emoji get paging * make limit optional * fix incorrect path in media cleanup tests * i have bad coder syndrome * don't trimspace * rename -> GetUseableEmojis * wrap emoji query in subquery avoid selecting more than we need * fix a bit of sillyness teehee * fix subquery postgres woes
2022-05-15[feature] Media cleanup endpoint (#560)Libravatar Sashanoraa1
Adds an admin endpoint to trigger a remote media cleanup. Fixed #348 Signed-off-by: Sashanoraa <sasha@noraa.gay>
2022-03-19[feature] Admin account actions (#432)Libravatar tobi1
* add accountAction to the admin API * model admin account action * add admin account action to the processor * add migration for new AdminAccountActions table * fix accounts admin path * Update swagger docs
2021-12-20Extend license notices to 2022 (#354)Libravatar tobi1
2021-08-02Frodo swaggins (#126)Libravatar Tobi Smethurst1
* more swagger fun * document a whole bunch more stuff * more swagger yayyyyyyy * progress + go fmt
2021-05-08Ap (#14)Libravatar Tobi Smethurst1
Big restructuring and initial work on activitypub